@quadrel-enterprise-ui/framework 21.12.10 → 21.12.12
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,13 +1,14 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Directive, InjectionToken, inject, ElementRef, HostBinding, Input, ViewEncapsulation, Component, Injectable, Injector, HostListener, ChangeDetectionStrategy, ChangeDetectorRef, ViewChild, NgModule, EventEmitter, Output, Renderer2, Pipe, ViewContainerRef, NO_ERRORS_SCHEMA,
|
|
2
|
+
import { Directive, InjectionToken, inject, ElementRef, HostBinding, Input, ViewEncapsulation, Component, Injectable, Injector, DestroyRef, HostListener, ChangeDetectionStrategy, ChangeDetectorRef, ViewChild, NgModule, EventEmitter, Output, Renderer2, Pipe, ViewContainerRef, NO_ERRORS_SCHEMA, SecurityContext, NgZone, ViewChildren, afterNextRender, forwardRef, QueryList, ContentChildren, ContentChild, afterEveryRender, reflectComponentType, isDevMode, TemplateRef, CUSTOM_ELEMENTS_SCHEMA, provideAppInitializer } from '@angular/core';
|
|
3
3
|
import { Dialog, DialogRef, DIALOG_DATA, DialogModule } from '@angular/cdk/dialog';
|
|
4
4
|
import { quadrelIcons } from '@quadrel-enterprise-ui/icons';
|
|
5
5
|
export { quadrelIconNames } from '@quadrel-enterprise-ui/icons';
|
|
6
|
-
import { BehaviorSubject, pairwise, fromEvent, combineLatest, concat, map as map$1, Subject, throwError, of, ReplaySubject, merge, isObservable, NEVER, Observable, EMPTY, shareReplay,
|
|
7
|
-
import { map, startWith, take, debounceTime,
|
|
6
|
+
import { BehaviorSubject, pairwise, fromEvent, combineLatest, concat, map as map$1, Subject, throwError, of, ReplaySubject, merge, isObservable, NEVER, Observable, EMPTY, shareReplay, distinctUntilChanged as distinctUntilChanged$1, debounce, timer, switchMap as switchMap$1, asyncScheduler, Subscription, startWith as startWith$1, filter as filter$1, debounceTime as debounceTime$1, firstValueFrom, take as take$1, tap as tap$1, from, delay, defer, throwIfEmpty, EmptyError, queueScheduler, concatMap as concatMap$1, exhaustMap, takeUntil as takeUntil$1, finalize, forkJoin, delayWhen, combineLatestWith, withLatestFrom as withLatestFrom$1, async } from 'rxjs';
|
|
7
|
+
import { map, startWith, take, debounceTime, filter, catchError, distinctUntilChanged, switchMap, concatMap, skip, throttleTime, tap, takeUntil, auditTime, withLatestFrom, first, observeOn, pairwise as pairwise$1, mergeMap } from 'rxjs/operators';
|
|
8
8
|
import { v4 } from 'uuid';
|
|
9
9
|
import * as i2 from '@ngx-translate/core';
|
|
10
10
|
import { TranslateService, TranslateModule } from '@ngx-translate/core';
|
|
11
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
11
12
|
import * as i1$3 from '@angular/router';
|
|
12
13
|
import { Router, ActivationEnd, RouterModule, ActivatedRoute, NavigationEnd, NavigationCancel, NavigationError, NavigationStart } from '@angular/router';
|
|
13
14
|
import * as i1 from '@angular/cdk/drag-drop';
|
|
@@ -19,7 +20,6 @@ import * as i1$2 from '@angular/forms';
|
|
|
19
20
|
import { NG_VALUE_ACCESSOR, FormsModule, UntypedFormControl, UntypedFormArray, UntypedFormGroup, ControlContainer, FormControlDirective, AbstractControl, UntypedFormBuilder, Validators, FormControl, ReactiveFormsModule, NgForm, FormGroupDirective, FormArray, FormGroup, FormBuilder } from '@angular/forms';
|
|
20
21
|
import { ComponentPortal } from '@angular/cdk/portal';
|
|
21
22
|
import { OverlayPositionBuilder, Overlay } from '@angular/cdk/overlay';
|
|
22
|
-
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
23
23
|
import { EventSourcePolyfill } from 'event-source-polyfill';
|
|
24
24
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
25
25
|
import * as i1$4 from '@angular/cdk/a11y';
|
|
@@ -448,11 +448,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
448
448
|
// @ts-strict-ignore
|
|
449
449
|
class QdDesktopNotificationsService {
|
|
450
450
|
injector = inject(Injector);
|
|
451
|
+
_destroyRef = inject(DestroyRef);
|
|
451
452
|
desktopNotifications = [];
|
|
452
453
|
translateService;
|
|
453
454
|
constructor() {
|
|
454
455
|
const injector = this.injector;
|
|
455
|
-
setTimeout(() => (this.translateService = injector.get(TranslateService)));
|
|
456
|
+
const translateServiceLookup = setTimeout(() => (this.translateService = injector.get(TranslateService)));
|
|
457
|
+
this._destroyRef.onDestroy(() => clearTimeout(translateServiceLookup));
|
|
456
458
|
}
|
|
457
459
|
open(notification) {
|
|
458
460
|
const desktopNotification = this.openDesktopNotificationIfPermitted(notification);
|
|
@@ -1346,7 +1348,7 @@ class QdDialogComponent {
|
|
|
1346
1348
|
hasSections;
|
|
1347
1349
|
hasInfoBanner;
|
|
1348
1350
|
isMobile = false;
|
|
1349
|
-
|
|
1351
|
+
_destroyRef = inject(DestroyRef);
|
|
1350
1352
|
_pageDialogCanCloseFn = null;
|
|
1351
1353
|
_isConfirmingClose = false;
|
|
1352
1354
|
get isFullWidth() {
|
|
@@ -1357,12 +1359,12 @@ class QdDialogComponent {
|
|
|
1357
1359
|
}
|
|
1358
1360
|
ngOnInit() {
|
|
1359
1361
|
this.config = this.dialogRef.config;
|
|
1360
|
-
this.dialogService.pageDialogCanClose$.pipe(
|
|
1362
|
+
this.dialogService.pageDialogCanClose$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(entry => {
|
|
1361
1363
|
this._pageDialogCanCloseFn = entry?.owner === this.dialogRef ? entry.fn : null;
|
|
1362
1364
|
});
|
|
1363
1365
|
this.breakpointService
|
|
1364
1366
|
.isViewportBelow('md')
|
|
1365
|
-
.pipe(
|
|
1367
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
1366
1368
|
.subscribe(isMobile => (this.isMobile = isMobile));
|
|
1367
1369
|
this.bindEscToClose();
|
|
1368
1370
|
}
|
|
@@ -1379,8 +1381,6 @@ class QdDialogComponent {
|
|
|
1379
1381
|
}
|
|
1380
1382
|
ngOnDestroy() {
|
|
1381
1383
|
this.dialogService.clearPageDialogCanClose(this.dialogRef);
|
|
1382
|
-
this._destroyed$.next();
|
|
1383
|
-
this._destroyed$.complete();
|
|
1384
1384
|
}
|
|
1385
1385
|
close() {
|
|
1386
1386
|
if (this.isFullWidth && this._pageDialogCanCloseFn)
|
|
@@ -1435,7 +1435,7 @@ class QdDialogComponent {
|
|
|
1435
1435
|
}
|
|
1436
1436
|
bindEscToClose() {
|
|
1437
1437
|
this.dialogRef.keydownEvents
|
|
1438
|
-
.pipe(
|
|
1438
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter((e) => e.key === 'Escape' && !e.defaultPrevented))
|
|
1439
1439
|
.subscribe(e => {
|
|
1440
1440
|
e.preventDefault();
|
|
1441
1441
|
this.close();
|
|
@@ -5366,14 +5366,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
5366
5366
|
|
|
5367
5367
|
class QdBreadcrumbsService {
|
|
5368
5368
|
router = inject(Router);
|
|
5369
|
+
_destroyRef = inject(DestroyRef);
|
|
5369
5370
|
breadcrumbsSubject = new ReplaySubject(1);
|
|
5370
|
-
destroyed$ = new Subject();
|
|
5371
5371
|
outlet = 'primary';
|
|
5372
5372
|
breadcrumbs$ = this.breadcrumbsSubject.asObservable();
|
|
5373
5373
|
url$ = this.breadcrumbsSubject.pipe(map(breadcrumbs => breadcrumbs[breadcrumbs.length - 1]?.url || ''));
|
|
5374
5374
|
initialize() {
|
|
5375
5375
|
this.getOutletRouteSnapshot$()
|
|
5376
|
-
.pipe(map(snapshot => this.getSnapshotPathHierarchy(snapshot)))
|
|
5376
|
+
.pipe(map(snapshot => this.getSnapshotPathHierarchy(snapshot)), takeUntilDestroyed(this._destroyRef))
|
|
5377
5377
|
.subscribe(snapshotPathHierarchy => {
|
|
5378
5378
|
let urlParts = [];
|
|
5379
5379
|
this.breadcrumbsSubject.next(snapshotPathHierarchy.map(snapshot => {
|
|
@@ -5386,10 +5386,6 @@ class QdBreadcrumbsService {
|
|
|
5386
5386
|
}));
|
|
5387
5387
|
});
|
|
5388
5388
|
}
|
|
5389
|
-
ngOnDestroy() {
|
|
5390
|
-
this.destroyed$.next();
|
|
5391
|
-
this.destroyed$.complete();
|
|
5392
|
-
}
|
|
5393
5389
|
getOutletRouteSnapshot$() {
|
|
5394
5390
|
return this.router.events.pipe(filter(event => event instanceof ActivationEnd), map(event => event.snapshot), filter(snapshot => snapshot.outlet === this.outlet));
|
|
5395
5391
|
}
|
|
@@ -5774,6 +5770,7 @@ class QdDataFacetsChipTruncatedTooltipComponent {
|
|
|
5774
5770
|
changeDetectorRef = inject(ChangeDetectorRef);
|
|
5775
5771
|
translateService = inject(TranslateService);
|
|
5776
5772
|
elementService = inject(QdElementService);
|
|
5773
|
+
_destroyRef = inject(DestroyRef);
|
|
5777
5774
|
truncatedChips;
|
|
5778
5775
|
i18n;
|
|
5779
5776
|
columnOptions;
|
|
@@ -5783,7 +5780,6 @@ class QdDataFacetsChipTruncatedTooltipComponent {
|
|
|
5783
5780
|
}
|
|
5784
5781
|
closable = false;
|
|
5785
5782
|
changesSubject = new Subject();
|
|
5786
|
-
adjustWidthSubscription;
|
|
5787
5783
|
ngOnChanges(changes) {
|
|
5788
5784
|
if (changes['truncatedChips']?.isFirstChange() === false ||
|
|
5789
5785
|
changes['i18n']?.isFirstChange() === false ||
|
|
@@ -5791,9 +5787,6 @@ class QdDataFacetsChipTruncatedTooltipComponent {
|
|
|
5791
5787
|
this.changesSubject.next();
|
|
5792
5788
|
}
|
|
5793
5789
|
}
|
|
5794
|
-
ngOnDestroy() {
|
|
5795
|
-
this.adjustWidthSubscription?.unsubscribe();
|
|
5796
|
-
}
|
|
5797
5790
|
ngOnInit() {
|
|
5798
5791
|
this.setElementMaxWidth(TOOLTIP_MIN_MAX_WIDTH);
|
|
5799
5792
|
this.element.style.visibility = 'hidden';
|
|
@@ -5803,8 +5796,8 @@ class QdDataFacetsChipTruncatedTooltipComponent {
|
|
|
5803
5796
|
this.adjustWidthToFitInViewport();
|
|
5804
5797
|
this.element.style.visibility = 'visible';
|
|
5805
5798
|
}, 1);
|
|
5806
|
-
|
|
5807
|
-
.pipe(debounceTime(100))
|
|
5799
|
+
merge(this.changesSubject, this.translateService.onLangChange, fromEvent(window, 'resize'))
|
|
5800
|
+
.pipe(debounceTime(100), takeUntilDestroyed(this._destroyRef))
|
|
5808
5801
|
.subscribe(() => this.adjustWidthToFitInViewport());
|
|
5809
5802
|
}
|
|
5810
5803
|
close() {
|
|
@@ -5882,13 +5875,13 @@ class QdDataFacetsChipTruncatedIndicatorComponent {
|
|
|
5882
5875
|
hostRef = inject(ElementRef);
|
|
5883
5876
|
overlayPositionBuilder = inject(OverlayPositionBuilder);
|
|
5884
5877
|
overlay = inject(Overlay);
|
|
5878
|
+
_destroyRef = inject(DestroyRef);
|
|
5885
5879
|
truncatedChips = [];
|
|
5886
5880
|
i18n;
|
|
5887
5881
|
columnOptions;
|
|
5888
5882
|
hostElement;
|
|
5889
5883
|
overlayRef;
|
|
5890
5884
|
showEvents = ['mouseenter', 'mousemove'];
|
|
5891
|
-
showTooltipSubscription;
|
|
5892
5885
|
hideTooltipSubscription;
|
|
5893
5886
|
tooltipComponent;
|
|
5894
5887
|
constructor() {
|
|
@@ -5912,12 +5905,12 @@ class QdDataFacetsChipTruncatedIndicatorComponent {
|
|
|
5912
5905
|
}
|
|
5913
5906
|
}
|
|
5914
5907
|
ngOnDestroy() {
|
|
5915
|
-
this.showTooltipSubscription?.unsubscribe();
|
|
5916
|
-
this.hideTooltipSubscription?.unsubscribe();
|
|
5917
5908
|
this.hideTooltip();
|
|
5918
5909
|
}
|
|
5919
5910
|
subscribeShowTooltip() {
|
|
5920
|
-
|
|
5911
|
+
merge(...this.showEvents.map(event => fromEvent(this.hostElement, event)), ...this.showEvents.map(event => fromEvent(this.overlayRef.hostElement, event)))
|
|
5912
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
5913
|
+
.subscribe(() => {
|
|
5921
5914
|
this.hideTooltipSubscription?.unsubscribe();
|
|
5922
5915
|
this.subscribeHideTooltip();
|
|
5923
5916
|
this.showTooltip();
|
|
@@ -5939,7 +5932,7 @@ class QdDataFacetsChipTruncatedIndicatorComponent {
|
|
|
5939
5932
|
}
|
|
5940
5933
|
subscribeHideTooltip() {
|
|
5941
5934
|
this.hideTooltipSubscription = merge(fromEvent(this.hostElement, 'mouseleave'), fromEvent(this.overlayRef.hostElement, 'mouseleave'))
|
|
5942
|
-
.pipe(debounceTime(HIDE_DELAY))
|
|
5935
|
+
.pipe(debounceTime(HIDE_DELAY), takeUntilDestroyed(this._destroyRef))
|
|
5943
5936
|
.subscribe(() => this.hideTooltip());
|
|
5944
5937
|
}
|
|
5945
5938
|
hideTooltip() {
|
|
@@ -6047,12 +6040,12 @@ class QdDataFacetsCurrencyComponent {
|
|
|
6047
6040
|
config;
|
|
6048
6041
|
data = 0;
|
|
6049
6042
|
testId;
|
|
6050
|
-
|
|
6043
|
+
_destroyRef = inject(DestroyRef);
|
|
6051
6044
|
_currencySubject = new ReplaySubject(1);
|
|
6052
6045
|
currency$ = this._currencySubject.asObservable();
|
|
6053
6046
|
constructor() {
|
|
6054
6047
|
this.translateService?.onLangChange
|
|
6055
|
-
.pipe(
|
|
6048
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
6056
6049
|
.subscribe((event) => this.setCurrency(event.lang));
|
|
6057
6050
|
}
|
|
6058
6051
|
ngOnInit() {
|
|
@@ -6061,9 +6054,6 @@ class QdDataFacetsCurrencyComponent {
|
|
|
6061
6054
|
ngOnChanges() {
|
|
6062
6055
|
this.setCurrency();
|
|
6063
6056
|
}
|
|
6064
|
-
ngOnDestroy() {
|
|
6065
|
-
this._destroyed$.complete();
|
|
6066
|
-
}
|
|
6067
6057
|
setCurrency(lang) {
|
|
6068
6058
|
const currency = this.getCurrency(lang || this.translateService?.currentLang || this.translateService?.defaultLang || navigator.language);
|
|
6069
6059
|
this._currencySubject.next(currency);
|
|
@@ -6130,7 +6120,7 @@ class QdDataFacetsDateComponent {
|
|
|
6130
6120
|
config;
|
|
6131
6121
|
data;
|
|
6132
6122
|
testId;
|
|
6133
|
-
|
|
6123
|
+
_destroyRef = inject(DestroyRef);
|
|
6134
6124
|
_locale;
|
|
6135
6125
|
_displayedDateSubject = new ReplaySubject(1);
|
|
6136
6126
|
displayedDate$ = this._displayedDateSubject.asObservable();
|
|
@@ -6139,7 +6129,7 @@ class QdDataFacetsDateComponent {
|
|
|
6139
6129
|
}
|
|
6140
6130
|
constructor() {
|
|
6141
6131
|
this.translateService?.onLangChange
|
|
6142
|
-
.pipe(
|
|
6132
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
6143
6133
|
.subscribe((event) => this.setDisplayedDate(event.lang));
|
|
6144
6134
|
}
|
|
6145
6135
|
ngOnInit() {
|
|
@@ -6148,9 +6138,6 @@ class QdDataFacetsDateComponent {
|
|
|
6148
6138
|
ngOnChanges() {
|
|
6149
6139
|
this.setDisplayedDate();
|
|
6150
6140
|
}
|
|
6151
|
-
ngOnDestroy() {
|
|
6152
|
-
this._destroyed$.complete();
|
|
6153
|
-
}
|
|
6154
6141
|
setDisplayedDate(locale) {
|
|
6155
6142
|
this._locale =
|
|
6156
6143
|
locale || this.translateService?.currentLang || this.translateService?.defaultLang || navigator.language;
|
|
@@ -7337,7 +7324,7 @@ class QdNumberInputService {
|
|
|
7337
7324
|
_decimalSeparator;
|
|
7338
7325
|
_groupSeparator;
|
|
7339
7326
|
localeService = inject(QdLocaleService, { optional: true });
|
|
7340
|
-
|
|
7327
|
+
_destroyRef = inject(DestroyRef);
|
|
7341
7328
|
ambiguityHintKeyDot = 'i18n.qd.input.number.ambiguousHint.dot';
|
|
7342
7329
|
ambiguityHintKeyComma = 'i18n.qd.input.number.ambiguousHint.comma';
|
|
7343
7330
|
invalidCharactersErrorKeyComma = 'i18n.qd.input.number.invalidCharacters.comma';
|
|
@@ -7353,7 +7340,7 @@ class QdNumberInputService {
|
|
|
7353
7340
|
}
|
|
7354
7341
|
constructor() {
|
|
7355
7342
|
if (this.localeService) {
|
|
7356
|
-
this.localeService.locale$.pipe(takeUntilDestroyed(this.
|
|
7343
|
+
this.localeService.locale$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(locale => {
|
|
7357
7344
|
this.detectSeparatorsForLocale(locale);
|
|
7358
7345
|
});
|
|
7359
7346
|
}
|
|
@@ -9896,7 +9883,7 @@ class QdCheckboxChipsComponent {
|
|
|
9896
9883
|
options;
|
|
9897
9884
|
isLabelDisabled;
|
|
9898
9885
|
isHintDisabled;
|
|
9899
|
-
|
|
9886
|
+
_destroyRef = inject(DestroyRef);
|
|
9900
9887
|
_onChange = () => { };
|
|
9901
9888
|
_onTouch = () => { };
|
|
9902
9889
|
ngOnInit() {
|
|
@@ -9912,18 +9899,21 @@ class QdCheckboxChipsComponent {
|
|
|
9912
9899
|
console.warn('Quadrel Framework | QdCheckboxChips - Missing FormControlName directive from host element of the component.');
|
|
9913
9900
|
}
|
|
9914
9901
|
}
|
|
9915
|
-
this.
|
|
9916
|
-
|
|
9917
|
-
|
|
9918
|
-
this.
|
|
9902
|
+
this.actionEmitterService.hintEventEmitter$
|
|
9903
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
9904
|
+
.subscribe(() => this.clickHint.emit());
|
|
9905
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
9906
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
9907
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
9908
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
9909
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
9910
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
9911
|
+
this.initOpModeSubscription();
|
|
9919
9912
|
}
|
|
9920
9913
|
ngOnChanges(changes) {
|
|
9921
9914
|
if (changes['config'])
|
|
9922
9915
|
this.updateConfiguration();
|
|
9923
9916
|
}
|
|
9924
|
-
ngOnDestroy() {
|
|
9925
|
-
this._subs.unsubscribe();
|
|
9926
|
-
}
|
|
9927
9917
|
registerOnChange(fn) {
|
|
9928
9918
|
this._onChange = fn;
|
|
9929
9919
|
}
|
|
@@ -9960,7 +9950,10 @@ class QdCheckboxChipsComponent {
|
|
|
9960
9950
|
initOpModeSubscription() {
|
|
9961
9951
|
if (!this.eventBrokerService)
|
|
9962
9952
|
return;
|
|
9963
|
-
|
|
9953
|
+
this.eventBrokerService
|
|
9954
|
+
.consume('operation_mode_changed')
|
|
9955
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
9956
|
+
.subscribe(topic => {
|
|
9964
9957
|
if (typeof this.config.viewonly === 'boolean')
|
|
9965
9958
|
return;
|
|
9966
9959
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -10408,7 +10401,7 @@ class QdCheckboxesComponent {
|
|
|
10408
10401
|
control;
|
|
10409
10402
|
_onChange = () => { };
|
|
10410
10403
|
_onTouch = () => { };
|
|
10411
|
-
|
|
10404
|
+
_destroyRef = inject(DestroyRef);
|
|
10412
10405
|
get hasHint() {
|
|
10413
10406
|
return this.config.hint && this.config.hint.i18n && !this.config.hint.disabled;
|
|
10414
10407
|
}
|
|
@@ -10437,10 +10430,16 @@ class QdCheckboxesComponent {
|
|
|
10437
10430
|
this.checkboxesService.setCheckboxesList(this.options);
|
|
10438
10431
|
this.checkboxesService.fillCheckboxesListWithDefaults(this.values);
|
|
10439
10432
|
this.setCheckboxesData();
|
|
10440
|
-
this.
|
|
10441
|
-
|
|
10442
|
-
|
|
10443
|
-
this.
|
|
10433
|
+
this.actionEmitterService.hintEventEmitter$
|
|
10434
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
10435
|
+
.subscribe(() => this.clickHint.emit());
|
|
10436
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
10437
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
10438
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
10439
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
10440
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
10441
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
10442
|
+
this.initOpModeSubscription();
|
|
10444
10443
|
}
|
|
10445
10444
|
ngOnChanges(changes) {
|
|
10446
10445
|
if (changes['config']) {
|
|
@@ -10450,9 +10449,6 @@ class QdCheckboxesComponent {
|
|
|
10450
10449
|
}
|
|
10451
10450
|
}
|
|
10452
10451
|
}
|
|
10453
|
-
ngOnDestroy() {
|
|
10454
|
-
this._subs.unsubscribe();
|
|
10455
|
-
}
|
|
10456
10452
|
registerOnChange(fn) {
|
|
10457
10453
|
this._onChange = fn;
|
|
10458
10454
|
}
|
|
@@ -10532,7 +10528,10 @@ class QdCheckboxesComponent {
|
|
|
10532
10528
|
initOpModeSubscription() {
|
|
10533
10529
|
if (!this.eventBrokerService)
|
|
10534
10530
|
return;
|
|
10535
|
-
|
|
10531
|
+
this.eventBrokerService
|
|
10532
|
+
.consume('operation_mode_changed')
|
|
10533
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
10534
|
+
.subscribe(topic => {
|
|
10536
10535
|
if (typeof this.config.viewonly === 'boolean')
|
|
10537
10536
|
return;
|
|
10538
10537
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -11363,7 +11362,7 @@ class QdFormOptionsService {
|
|
|
11363
11362
|
_requestState = new BehaviorSubject(QdFormOptionsRequestState.IDLE);
|
|
11364
11363
|
_optionsResolved = new Subject();
|
|
11365
11364
|
_resolver = null;
|
|
11366
|
-
|
|
11365
|
+
_destroyRef = inject(DestroyRef);
|
|
11367
11366
|
_lastLoadedValue = null;
|
|
11368
11367
|
_excludedValues = new Set();
|
|
11369
11368
|
_config = null;
|
|
@@ -11377,10 +11376,6 @@ class QdFormOptionsService {
|
|
|
11377
11376
|
constructor() {
|
|
11378
11377
|
this.publishLatestResolvedOptions();
|
|
11379
11378
|
}
|
|
11380
|
-
ngOnDestroy() {
|
|
11381
|
-
this._destroyed$.next(true);
|
|
11382
|
-
this._destroyed$.complete();
|
|
11383
|
-
}
|
|
11384
11379
|
initialize(config) {
|
|
11385
11380
|
this._config = config;
|
|
11386
11381
|
this.resolverRegistry.initialize(config.optionsResolverName);
|
|
@@ -11433,7 +11428,7 @@ class QdFormOptionsService {
|
|
|
11433
11428
|
if (dependsOnControls.length === 0)
|
|
11434
11429
|
return;
|
|
11435
11430
|
this._dependsOnSubscription = merge(...dependsOnControls.map(control => control.valueChanges.pipe(startWith(control.value), distinctUntilChanged(qdIsDeepEqual), skip(1))))
|
|
11436
|
-
.pipe(
|
|
11431
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
11437
11432
|
.subscribe(() => this.reloadAfterDependencyChange());
|
|
11438
11433
|
}
|
|
11439
11434
|
logWarningIfDependsOnWithoutFormGroup() {
|
|
@@ -11470,7 +11465,7 @@ class QdFormOptionsService {
|
|
|
11470
11465
|
})), switchMap$1(({ value, dependencies }) => this._resolver.resolve(value, dependencies).pipe(take(1), map((options) => ({ options, dependencies })), catchError(() => {
|
|
11471
11466
|
this._requestState.next(QdFormOptionsRequestState.ERROR);
|
|
11472
11467
|
return EMPTY;
|
|
11473
|
-
}))),
|
|
11468
|
+
}))), takeUntilDestroyed(this._destroyRef))
|
|
11474
11469
|
.subscribe(({ options, dependencies }) => {
|
|
11475
11470
|
this._options.next(options);
|
|
11476
11471
|
this._requestState.next(QdFormOptionsRequestState.SUCCESS);
|
|
@@ -11843,7 +11838,7 @@ class QdDropdownComponent {
|
|
|
11843
11838
|
control;
|
|
11844
11839
|
_value = null;
|
|
11845
11840
|
_selectedOption = null;
|
|
11846
|
-
|
|
11841
|
+
_destroyRef = inject(DestroyRef);
|
|
11847
11842
|
_onChange = () => { };
|
|
11848
11843
|
_onTouch = () => { };
|
|
11849
11844
|
filterInput;
|
|
@@ -11887,7 +11882,7 @@ class QdDropdownComponent {
|
|
|
11887
11882
|
if (!this.id)
|
|
11888
11883
|
this.id = v4();
|
|
11889
11884
|
this.optionsService.optionsResolved$
|
|
11890
|
-
.pipe(takeUntilDestroyed())
|
|
11885
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
11891
11886
|
.subscribe(resolvedEvent => this.optionsResolved.emit(resolvedEvent));
|
|
11892
11887
|
}
|
|
11893
11888
|
ngOnInit() {
|
|
@@ -11896,10 +11891,16 @@ class QdDropdownComponent {
|
|
|
11896
11891
|
this.loadOptionsForCurrentConfig();
|
|
11897
11892
|
this.resolveControl();
|
|
11898
11893
|
this.updateSelectedOption(this.value);
|
|
11899
|
-
this.
|
|
11900
|
-
|
|
11901
|
-
|
|
11902
|
-
this.
|
|
11894
|
+
this.actionEmitterService.hintEventEmitter$
|
|
11895
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
11896
|
+
.subscribe(() => this.clickHint.emit());
|
|
11897
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
11898
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
11899
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
11900
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
11901
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
11902
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
11903
|
+
this.initOpModeSubscription();
|
|
11903
11904
|
}
|
|
11904
11905
|
ngOnChanges(changes) {
|
|
11905
11906
|
if (changes.config) {
|
|
@@ -11910,7 +11911,6 @@ class QdDropdownComponent {
|
|
|
11910
11911
|
}
|
|
11911
11912
|
ngOnDestroy() {
|
|
11912
11913
|
this.optionsService.reset();
|
|
11913
|
-
this._subs.unsubscribe();
|
|
11914
11914
|
}
|
|
11915
11915
|
focus() {
|
|
11916
11916
|
this.box.nativeElement.focus();
|
|
@@ -12039,7 +12039,10 @@ class QdDropdownComponent {
|
|
|
12039
12039
|
initOpModeSubscription() {
|
|
12040
12040
|
if (!this.eventBrokerService)
|
|
12041
12041
|
return;
|
|
12042
|
-
|
|
12042
|
+
this.eventBrokerService
|
|
12043
|
+
.consume('operation_mode_changed')
|
|
12044
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
12045
|
+
.subscribe(topic => {
|
|
12043
12046
|
if (typeof this.config?.viewonly === 'boolean')
|
|
12044
12047
|
return;
|
|
12045
12048
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -12589,7 +12592,7 @@ class QdInputComponent {
|
|
|
12589
12592
|
_value = { value: '' };
|
|
12590
12593
|
_displayValue = '';
|
|
12591
12594
|
control;
|
|
12592
|
-
|
|
12595
|
+
_destroyRef = inject(DestroyRef);
|
|
12593
12596
|
_filteredOptions = [];
|
|
12594
12597
|
_optionsResolver = null;
|
|
12595
12598
|
_isUserTyped = false;
|
|
@@ -12658,10 +12661,16 @@ class QdInputComponent {
|
|
|
12658
12661
|
console.error('Quadrel Framework | QdInput - Please use either decimal or numeric when using QdInputType number.');
|
|
12659
12662
|
this.writeValue(this.value ?? getValue(this.config));
|
|
12660
12663
|
this.normalizeInitialControlValueIfNeeded();
|
|
12661
|
-
this.
|
|
12662
|
-
|
|
12663
|
-
|
|
12664
|
-
this.
|
|
12664
|
+
this.actionEmitterService.hintEventEmitter$
|
|
12665
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
12666
|
+
.subscribe(() => this.clickHint.emit());
|
|
12667
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
12668
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
12669
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
12670
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
12671
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
12672
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
12673
|
+
this.initOpModeSubscription();
|
|
12665
12674
|
}
|
|
12666
12675
|
ngOnChanges(changes) {
|
|
12667
12676
|
if (changes['config']) {
|
|
@@ -12673,9 +12682,6 @@ class QdInputComponent {
|
|
|
12673
12682
|
if (changes['value'])
|
|
12674
12683
|
this.writeValue(this.value);
|
|
12675
12684
|
}
|
|
12676
|
-
ngOnDestroy() {
|
|
12677
|
-
this._subs.unsubscribe();
|
|
12678
|
-
}
|
|
12679
12685
|
registerOnChange(fn) {
|
|
12680
12686
|
const fnString = fn.toString();
|
|
12681
12687
|
if (fnString.includes('_noControlError') || fnString.includes('validateControlPresenceOnChange'))
|
|
@@ -12825,13 +12831,15 @@ class QdInputComponent {
|
|
|
12825
12831
|
this.hasOptions = this.optionsService.hasOptions();
|
|
12826
12832
|
}
|
|
12827
12833
|
subscribeToOptions() {
|
|
12828
|
-
this.
|
|
12829
|
-
|
|
12834
|
+
this.optionsService.filteredOptions$
|
|
12835
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
12836
|
+
.subscribe(options => (this._filteredOptions = options));
|
|
12837
|
+
this.optionsService.optionsResolved$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(event => {
|
|
12830
12838
|
this.optionsResolved.emit(event);
|
|
12831
12839
|
const currentOption = event.options.find(option => option.value === this._value.value);
|
|
12832
12840
|
if (currentOption)
|
|
12833
12841
|
this.handleOptionSelected(currentOption);
|
|
12834
|
-
})
|
|
12842
|
+
});
|
|
12835
12843
|
}
|
|
12836
12844
|
loadOptionsForTypedValue(value) {
|
|
12837
12845
|
if (!this.hasOptions)
|
|
@@ -12863,7 +12871,10 @@ class QdInputComponent {
|
|
|
12863
12871
|
initOpModeSubscription() {
|
|
12864
12872
|
if (!this.eventBrokerService)
|
|
12865
12873
|
return;
|
|
12866
|
-
|
|
12874
|
+
this.eventBrokerService
|
|
12875
|
+
.consume('operation_mode_changed')
|
|
12876
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
12877
|
+
.subscribe(topic => {
|
|
12867
12878
|
if (typeof this.config.viewonly === 'boolean')
|
|
12868
12879
|
return;
|
|
12869
12880
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -13146,7 +13157,7 @@ class QdDatepickerComponent {
|
|
|
13146
13157
|
_boundDisabledDates;
|
|
13147
13158
|
_boundDisabledTimes;
|
|
13148
13159
|
_boundDateTimeValidation;
|
|
13149
|
-
|
|
13160
|
+
_destroyRef = inject(DestroyRef);
|
|
13150
13161
|
_onChange = () => { };
|
|
13151
13162
|
_onTouched = () => { };
|
|
13152
13163
|
ngOnInit() {
|
|
@@ -13157,7 +13168,7 @@ class QdDatepickerComponent {
|
|
|
13157
13168
|
this.updateConfiguration();
|
|
13158
13169
|
this.updateDisplayedDate();
|
|
13159
13170
|
this.updateDisplayedDateTime();
|
|
13160
|
-
this.
|
|
13171
|
+
this.initOpModeSubscription();
|
|
13161
13172
|
}
|
|
13162
13173
|
ngOnChanges(changes) {
|
|
13163
13174
|
if (changes.config) {
|
|
@@ -13169,9 +13180,6 @@ class QdDatepickerComponent {
|
|
|
13169
13180
|
this.rebindDisabledTimesValidatorIfChanged();
|
|
13170
13181
|
this.rebindDateTimeValidatorIfChanged();
|
|
13171
13182
|
}
|
|
13172
|
-
ngOnDestroy() {
|
|
13173
|
-
this._subs.unsubscribe();
|
|
13174
|
-
}
|
|
13175
13183
|
registerOnChange(fn) {
|
|
13176
13184
|
this._onChange = fn;
|
|
13177
13185
|
}
|
|
@@ -13302,14 +13310,20 @@ class QdDatepickerComponent {
|
|
|
13302
13310
|
this.popover?.close();
|
|
13303
13311
|
}
|
|
13304
13312
|
subscribeToLanguageChange() {
|
|
13305
|
-
this.
|
|
13306
|
-
.pipe(tap(({ lang }) => (this.language = lang)), tap(() => this.control.updateValueAndValidity()))
|
|
13307
|
-
.subscribe()
|
|
13313
|
+
this.translateService.onLangChange
|
|
13314
|
+
.pipe(tap(({ lang }) => (this.language = lang)), tap(() => this.control.updateValueAndValidity()), takeUntilDestroyed(this._destroyRef))
|
|
13315
|
+
.subscribe();
|
|
13308
13316
|
}
|
|
13309
13317
|
subscribeToActionEmitterEvents() {
|
|
13310
|
-
this.
|
|
13311
|
-
|
|
13312
|
-
|
|
13318
|
+
this.actionEmitterService.hintEventEmitter$
|
|
13319
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13320
|
+
.subscribe(() => this.clickHint.emit());
|
|
13321
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
13322
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13323
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
13324
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
13325
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13326
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
13313
13327
|
}
|
|
13314
13328
|
initControl() {
|
|
13315
13329
|
if (!this.controlContainer) {
|
|
@@ -13455,7 +13469,10 @@ class QdDatepickerComponent {
|
|
|
13455
13469
|
initOpModeSubscription() {
|
|
13456
13470
|
if (!this.eventBrokerService)
|
|
13457
13471
|
return;
|
|
13458
|
-
|
|
13472
|
+
this.eventBrokerService
|
|
13473
|
+
.consume('operation_mode_changed')
|
|
13474
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13475
|
+
.subscribe(topic => {
|
|
13459
13476
|
if (typeof this.config.viewonly === 'boolean')
|
|
13460
13477
|
return;
|
|
13461
13478
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -13769,7 +13786,7 @@ class QdFileUploadComponent {
|
|
|
13769
13786
|
_value = null;
|
|
13770
13787
|
_state = QdUploadState.IDLE;
|
|
13771
13788
|
_uploadSubscription;
|
|
13772
|
-
|
|
13789
|
+
_destroyRef = inject(DestroyRef);
|
|
13773
13790
|
_onChange = () => { };
|
|
13774
13791
|
_onTouched = () => { };
|
|
13775
13792
|
get isDisabled() {
|
|
@@ -13800,18 +13817,20 @@ class QdFileUploadComponent {
|
|
|
13800
13817
|
return this.control?.errors ?? null;
|
|
13801
13818
|
}
|
|
13802
13819
|
constructor() {
|
|
13803
|
-
this.
|
|
13804
|
-
|
|
13805
|
-
|
|
13820
|
+
this.actionEmitterService.hintEventEmitter$
|
|
13821
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13822
|
+
.subscribe(() => this.clickHint.emit());
|
|
13823
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
13824
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13825
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
13826
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
13827
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13828
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
13806
13829
|
}
|
|
13807
13830
|
ngOnInit() {
|
|
13808
13831
|
if (this.controlContainer && this.formControlName)
|
|
13809
13832
|
this.control = this.controlContainer.control?.get(this.formControlName) ?? null;
|
|
13810
13833
|
}
|
|
13811
|
-
ngOnDestroy() {
|
|
13812
|
-
this._uploadSubscription?.unsubscribe();
|
|
13813
|
-
this._actionSubscriptions.unsubscribe();
|
|
13814
|
-
}
|
|
13815
13834
|
writeValue(file) {
|
|
13816
13835
|
this._value = file;
|
|
13817
13836
|
this.file = file;
|
|
@@ -13860,7 +13879,10 @@ class QdFileUploadComponent {
|
|
|
13860
13879
|
this.fileSelected.emit(file);
|
|
13861
13880
|
}
|
|
13862
13881
|
subscribeToUpload(file) {
|
|
13863
|
-
this._uploadSubscription = this.uploadService
|
|
13882
|
+
this._uploadSubscription = this.uploadService
|
|
13883
|
+
.upload(file)
|
|
13884
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
13885
|
+
.subscribe({
|
|
13864
13886
|
next: ({ progress }) => {
|
|
13865
13887
|
this.uploadProgress$.next(progress);
|
|
13866
13888
|
if (progress >= 100) {
|
|
@@ -14536,7 +14558,7 @@ class QdMultiInputComponent {
|
|
|
14536
14558
|
_values = [];
|
|
14537
14559
|
_formArrayName = '';
|
|
14538
14560
|
_onDisabledChange;
|
|
14539
|
-
|
|
14561
|
+
_destroyRef = inject(DestroyRef);
|
|
14540
14562
|
_resizeObserver;
|
|
14541
14563
|
_onChange = () => { };
|
|
14542
14564
|
_onTouch = () => { };
|
|
@@ -14546,11 +14568,11 @@ class QdMultiInputComponent {
|
|
|
14546
14568
|
constructor() {
|
|
14547
14569
|
if (!this.id)
|
|
14548
14570
|
this.id = v4();
|
|
14549
|
-
this.optionsService.filteredOptions$.pipe(takeUntilDestroyed()).subscribe(list => {
|
|
14571
|
+
this.optionsService.filteredOptions$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(list => {
|
|
14550
14572
|
this.optionsListForView = list;
|
|
14551
14573
|
this.changeDetectorRef.markForCheck();
|
|
14552
14574
|
});
|
|
14553
|
-
this.multiInputService.selectedItems$.pipe(takeUntilDestroyed()).subscribe(items => {
|
|
14575
|
+
this.multiInputService.selectedItems$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(items => {
|
|
14554
14576
|
this.optionsService.setExcludedValues(items.map(item => item.value).filter((value) => value != null));
|
|
14555
14577
|
});
|
|
14556
14578
|
}
|
|
@@ -14559,10 +14581,16 @@ class QdMultiInputComponent {
|
|
|
14559
14581
|
this.multiInputService.setOptionsList(this.options);
|
|
14560
14582
|
this.multiInputService.setSelectedItems(this.values);
|
|
14561
14583
|
this.optionsService.initialize({ options: this.options });
|
|
14562
|
-
this.
|
|
14563
|
-
|
|
14564
|
-
|
|
14565
|
-
this.
|
|
14584
|
+
this.actionEmitterService.hintEventEmitter$
|
|
14585
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
14586
|
+
.subscribe(() => this.clickHint.emit());
|
|
14587
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
14588
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
14589
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
14590
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
14591
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
14592
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
14593
|
+
this.initOpModeSubscription();
|
|
14566
14594
|
if (!this.controlContainer)
|
|
14567
14595
|
return;
|
|
14568
14596
|
if (this.formArrayName) {
|
|
@@ -14575,14 +14603,14 @@ class QdMultiInputComponent {
|
|
|
14575
14603
|
console.warn('Quadrel Framework | QdMultiInput - The control bound via [formArrayName] must be a QdFormArray.');
|
|
14576
14604
|
return;
|
|
14577
14605
|
}
|
|
14578
|
-
|
|
14606
|
+
formArray.valueChanges.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(value => {
|
|
14579
14607
|
this.multiInputService.setSelectedItems(value);
|
|
14580
14608
|
this.valuesChange.emit(value);
|
|
14581
14609
|
this.changeDetectorRef.markForCheck();
|
|
14582
|
-
})
|
|
14583
|
-
|
|
14610
|
+
});
|
|
14611
|
+
formArray.statusChanges.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => {
|
|
14584
14612
|
this.changeDetectorRef.markForCheck();
|
|
14585
|
-
})
|
|
14613
|
+
});
|
|
14586
14614
|
this.formArray = formArray;
|
|
14587
14615
|
this.multiInputService.setSelectedItems(formArray.value);
|
|
14588
14616
|
this.disabled = formArray.disabled;
|
|
@@ -14606,7 +14634,6 @@ class QdMultiInputComponent {
|
|
|
14606
14634
|
}
|
|
14607
14635
|
ngOnDestroy() {
|
|
14608
14636
|
this.clickOutside = () => { };
|
|
14609
|
-
this._subs?.unsubscribe();
|
|
14610
14637
|
this._resizeObserver?.disconnect();
|
|
14611
14638
|
if (this.formArray && this._onDisabledChange)
|
|
14612
14639
|
this.formArray._unregisterOnDisabledChange(this._onDisabledChange);
|
|
@@ -14793,7 +14820,10 @@ class QdMultiInputComponent {
|
|
|
14793
14820
|
initOpModeSubscription() {
|
|
14794
14821
|
if (!this.eventBrokerService)
|
|
14795
14822
|
return;
|
|
14796
|
-
|
|
14823
|
+
this.eventBrokerService
|
|
14824
|
+
.consume('operation_mode_changed')
|
|
14825
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
14826
|
+
.subscribe(topic => {
|
|
14797
14827
|
if (typeof this.config.viewonly === 'boolean')
|
|
14798
14828
|
return;
|
|
14799
14829
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -15099,9 +15129,8 @@ class QdPinCodeComponent {
|
|
|
15099
15129
|
iterable = Array;
|
|
15100
15130
|
blurCurrent;
|
|
15101
15131
|
control;
|
|
15102
|
-
_actionEmitterServiceSubscription = new Subscription();
|
|
15103
15132
|
_inputs = [];
|
|
15104
|
-
|
|
15133
|
+
_destroyRef = inject(DestroyRef);
|
|
15105
15134
|
_onChange = () => { };
|
|
15106
15135
|
_onTouch = () => { };
|
|
15107
15136
|
get firstEmptyIndex() {
|
|
@@ -15130,10 +15159,16 @@ class QdPinCodeComponent {
|
|
|
15130
15159
|
console.warn('Quadrel Framework | QdPinCode - Missing FormControlName directive from host element of the component.');
|
|
15131
15160
|
}
|
|
15132
15161
|
}
|
|
15133
|
-
this.
|
|
15134
|
-
|
|
15135
|
-
|
|
15136
|
-
this.
|
|
15162
|
+
this.actionEmitterService.hintEventEmitter$
|
|
15163
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15164
|
+
.subscribe(() => this.clickHint.emit());
|
|
15165
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
15166
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15167
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
15168
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
15169
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15170
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
15171
|
+
this.initOpModeSubscription();
|
|
15137
15172
|
}
|
|
15138
15173
|
ngAfterViewInit() {
|
|
15139
15174
|
this.getInputs();
|
|
@@ -15150,9 +15185,6 @@ class QdPinCodeComponent {
|
|
|
15150
15185
|
}
|
|
15151
15186
|
}
|
|
15152
15187
|
}
|
|
15153
|
-
ngOnDestroy() {
|
|
15154
|
-
this._actionEmitterServiceSubscription?.unsubscribe();
|
|
15155
|
-
}
|
|
15156
15188
|
registerOnChange(fn) {
|
|
15157
15189
|
this._onChange = fn;
|
|
15158
15190
|
}
|
|
@@ -15346,7 +15378,10 @@ class QdPinCodeComponent {
|
|
|
15346
15378
|
initOpModeSubscription() {
|
|
15347
15379
|
if (!this.eventBrokerService)
|
|
15348
15380
|
return;
|
|
15349
|
-
|
|
15381
|
+
this.eventBrokerService
|
|
15382
|
+
.consume('operation_mode_changed')
|
|
15383
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15384
|
+
.subscribe(topic => {
|
|
15350
15385
|
if (typeof this.config.viewonly === 'boolean')
|
|
15351
15386
|
return;
|
|
15352
15387
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -15594,7 +15629,7 @@ class QdRadioButtonsComponent {
|
|
|
15594
15629
|
filterRadioButtons = '';
|
|
15595
15630
|
radioButtonsListForView;
|
|
15596
15631
|
control;
|
|
15597
|
-
|
|
15632
|
+
_destroyRef = inject(DestroyRef);
|
|
15598
15633
|
_onChange = () => { };
|
|
15599
15634
|
_onTouch = () => { };
|
|
15600
15635
|
constructor() {
|
|
@@ -15612,19 +15647,22 @@ class QdRadioButtonsComponent {
|
|
|
15612
15647
|
}
|
|
15613
15648
|
}
|
|
15614
15649
|
this.initRadioButtonList();
|
|
15615
|
-
this.
|
|
15616
|
-
|
|
15617
|
-
|
|
15618
|
-
this.
|
|
15650
|
+
this.actionEmitterService.hintEventEmitter$
|
|
15651
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15652
|
+
.subscribe(() => this.clickHint.emit());
|
|
15653
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
15654
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15655
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
15656
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
15657
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15658
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
15659
|
+
this.initOpModeSubscription();
|
|
15619
15660
|
}
|
|
15620
15661
|
ngOnChanges(changes) {
|
|
15621
15662
|
if (changes['config']) {
|
|
15622
15663
|
this.updateConfiguration();
|
|
15623
15664
|
}
|
|
15624
15665
|
}
|
|
15625
|
-
ngOnDestroy() {
|
|
15626
|
-
this._subs.unsubscribe();
|
|
15627
|
-
}
|
|
15628
15666
|
registerOnChange(fn) {
|
|
15629
15667
|
this._onChange = fn;
|
|
15630
15668
|
}
|
|
@@ -15683,7 +15721,10 @@ class QdRadioButtonsComponent {
|
|
|
15683
15721
|
initOpModeSubscription() {
|
|
15684
15722
|
if (!this.eventBrokerService)
|
|
15685
15723
|
return;
|
|
15686
|
-
|
|
15724
|
+
this.eventBrokerService
|
|
15725
|
+
.consume('operation_mode_changed')
|
|
15726
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
15727
|
+
.subscribe(topic => {
|
|
15687
15728
|
if (typeof this.config.viewonly === 'boolean')
|
|
15688
15729
|
return;
|
|
15689
15730
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -16062,7 +16103,7 @@ class QdRichtextComponent {
|
|
|
16062
16103
|
['underline', 'strike'],
|
|
16063
16104
|
['ordered_list', 'bullet_list']
|
|
16064
16105
|
];
|
|
16065
|
-
|
|
16106
|
+
_destroyRef = inject(DestroyRef);
|
|
16066
16107
|
_onChanged = () => { };
|
|
16067
16108
|
_onTouched = () => { };
|
|
16068
16109
|
constructor() {
|
|
@@ -16077,13 +16118,18 @@ class QdRichtextComponent {
|
|
|
16077
16118
|
console.warn('Quadrel Framework | QdSwitches - Missing FormControlName directive from host element of the component.');
|
|
16078
16119
|
}
|
|
16079
16120
|
}
|
|
16080
|
-
this.
|
|
16081
|
-
|
|
16082
|
-
|
|
16121
|
+
this.actionEmitterService.hintEventEmitter$
|
|
16122
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16123
|
+
.subscribe(() => this.clickHint.emit());
|
|
16124
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
16125
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16126
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
16127
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
16128
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16129
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
16083
16130
|
}
|
|
16084
16131
|
ngOnDestroy() {
|
|
16085
16132
|
this.editor.destroy();
|
|
16086
|
-
this._subs.unsubscribe();
|
|
16087
16133
|
}
|
|
16088
16134
|
get maxLength() {
|
|
16089
16135
|
return this.control instanceof QdFormControl ? this.control.getMaxLengthOrUndefined() : undefined;
|
|
@@ -16863,7 +16909,7 @@ class QdSwitchesComponent {
|
|
|
16863
16909
|
options;
|
|
16864
16910
|
switchesValues;
|
|
16865
16911
|
switchesInputs;
|
|
16866
|
-
|
|
16912
|
+
_destroyRef = inject(DestroyRef);
|
|
16867
16913
|
_onChange = () => { };
|
|
16868
16914
|
_onTouch = () => { };
|
|
16869
16915
|
constructor() {
|
|
@@ -16882,18 +16928,21 @@ class QdSwitchesComponent {
|
|
|
16882
16928
|
this.switchesService.setList(this.options);
|
|
16883
16929
|
this.switchesService.fillListWithDefaults(this.values);
|
|
16884
16930
|
this.setData();
|
|
16885
|
-
this.
|
|
16886
|
-
|
|
16887
|
-
|
|
16888
|
-
this.
|
|
16931
|
+
this.actionEmitterService.hintEventEmitter$
|
|
16932
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16933
|
+
.subscribe(() => this.clickHint.emit());
|
|
16934
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
16935
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16936
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
16937
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
16938
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16939
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
16940
|
+
this.initOpModeSubscription();
|
|
16889
16941
|
}
|
|
16890
16942
|
ngOnChanges(changes) {
|
|
16891
16943
|
if (changes['config'])
|
|
16892
16944
|
this.updateConfiguration();
|
|
16893
16945
|
}
|
|
16894
|
-
ngOnDestroy() {
|
|
16895
|
-
this._subs.unsubscribe();
|
|
16896
|
-
}
|
|
16897
16946
|
registerOnChange(fn) {
|
|
16898
16947
|
this._onChange = fn;
|
|
16899
16948
|
}
|
|
@@ -16942,7 +16991,10 @@ class QdSwitchesComponent {
|
|
|
16942
16991
|
initOpModeSubscription() {
|
|
16943
16992
|
if (!this.eventBrokerService)
|
|
16944
16993
|
return;
|
|
16945
|
-
|
|
16994
|
+
this.eventBrokerService
|
|
16995
|
+
.consume('operation_mode_changed')
|
|
16996
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
16997
|
+
.subscribe(topic => {
|
|
16946
16998
|
if (typeof this.config.viewonly === 'boolean')
|
|
16947
16999
|
return;
|
|
16948
17000
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -17116,7 +17168,7 @@ class QdTextareaComponent {
|
|
|
17116
17168
|
hint;
|
|
17117
17169
|
rows;
|
|
17118
17170
|
valueForView;
|
|
17119
|
-
|
|
17171
|
+
_destroyRef = inject(DestroyRef);
|
|
17120
17172
|
_onChange = () => { };
|
|
17121
17173
|
_onTouch = () => { };
|
|
17122
17174
|
get hasError() {
|
|
@@ -17158,19 +17210,22 @@ class QdTextareaComponent {
|
|
|
17158
17210
|
}
|
|
17159
17211
|
}
|
|
17160
17212
|
this.valueForView = this.value || getValue(this.config);
|
|
17161
|
-
this.
|
|
17162
|
-
|
|
17163
|
-
|
|
17164
|
-
this.
|
|
17213
|
+
this.actionEmitterService.hintEventEmitter$
|
|
17214
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
17215
|
+
.subscribe(() => this.clickHint.emit());
|
|
17216
|
+
this.actionEmitterService.readonlyEventEmitter$
|
|
17217
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
17218
|
+
.subscribe(() => this.clickReadonly.emit());
|
|
17219
|
+
this.actionEmitterService.viewonlyEventEmitter$
|
|
17220
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
17221
|
+
.subscribe(() => this.clickViewonly.emit());
|
|
17222
|
+
this.initOpModeSubscription();
|
|
17165
17223
|
}
|
|
17166
17224
|
ngOnChanges(changes) {
|
|
17167
17225
|
if (changes.config) {
|
|
17168
17226
|
this.updateConfiguration();
|
|
17169
17227
|
}
|
|
17170
17228
|
}
|
|
17171
|
-
ngOnDestroy() {
|
|
17172
|
-
this._subs.unsubscribe();
|
|
17173
|
-
}
|
|
17174
17229
|
registerOnChange(fn) {
|
|
17175
17230
|
this._onChange = fn;
|
|
17176
17231
|
}
|
|
@@ -17213,7 +17268,10 @@ class QdTextareaComponent {
|
|
|
17213
17268
|
initOpModeSubscription() {
|
|
17214
17269
|
if (!this.eventBrokerService)
|
|
17215
17270
|
return;
|
|
17216
|
-
|
|
17271
|
+
this.eventBrokerService
|
|
17272
|
+
.consume('operation_mode_changed')
|
|
17273
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
17274
|
+
.subscribe(topic => {
|
|
17217
17275
|
if (typeof this.config.viewonly === 'boolean')
|
|
17218
17276
|
return;
|
|
17219
17277
|
this.viewonly = getViewonly(this.config, topic.payload.isViewonly);
|
|
@@ -18003,22 +18061,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
18003
18061
|
*/
|
|
18004
18062
|
class QdNotificationsComponent {
|
|
18005
18063
|
notificationService = inject(QdNotificationsService);
|
|
18064
|
+
_destroyRef = inject(DestroyRef);
|
|
18006
18065
|
notifications;
|
|
18007
18066
|
/**
|
|
18008
18067
|
* The context can be assigned to control the positioning of the notifications.
|
|
18009
18068
|
*/
|
|
18010
18069
|
context = 'qdPanel';
|
|
18011
|
-
_destroyed$ = new Subject();
|
|
18012
18070
|
ngOnInit() {
|
|
18013
18071
|
this.notificationService
|
|
18014
18072
|
.getNotificationsForContext(this.context)
|
|
18015
|
-
.pipe(
|
|
18073
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
18016
18074
|
.subscribe(notifications => (this.notifications = notifications));
|
|
18017
18075
|
}
|
|
18018
|
-
ngOnDestroy() {
|
|
18019
|
-
this._destroyed$.next();
|
|
18020
|
-
this._destroyed$.complete();
|
|
18021
|
-
}
|
|
18022
18076
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdNotificationsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
18023
18077
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: QdNotificationsComponent, isStandalone: false, selector: "qd-notifications", inputs: { context: "context" }, ngImport: i0, template: "@for (notification of notifications; track notification) {\n<qd-notification [notification]=\"notification\"></qd-notification>\n}\n", styles: [".panel-type-control qd-notifications{display:block;width:100%;padding:1rem 1.5rem}.panel-type-info qd-notifications .qd-notification{background:#fff}qd-notifications qd-notification+qd-notification{margin-top:1rem}\n"], dependencies: [{ kind: "component", type: QdNotificationComponent, selector: "qd-notification", inputs: ["state", "notification"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
18024
18078
|
}
|
|
@@ -18081,14 +18135,12 @@ class QdNotificationsSnackbarListenerDirective {
|
|
|
18081
18135
|
overlayPositionBuilder = inject(OverlayPositionBuilder);
|
|
18082
18136
|
safeBottomOffset$ = inject(QD_SAFE_BOTTOM_OFFSET);
|
|
18083
18137
|
_overlayRef;
|
|
18084
|
-
|
|
18138
|
+
_destroyRef = inject(DestroyRef);
|
|
18085
18139
|
ngOnInit() {
|
|
18086
18140
|
this.initOverlay();
|
|
18087
18141
|
}
|
|
18088
18142
|
ngOnDestroy() {
|
|
18089
18143
|
this._overlayRef?.dispose();
|
|
18090
|
-
this._destroyed$.next();
|
|
18091
|
-
this._destroyed$.complete();
|
|
18092
18144
|
}
|
|
18093
18145
|
initOverlay() {
|
|
18094
18146
|
if (!this.hostRef)
|
|
@@ -18123,7 +18175,7 @@ class QdNotificationsSnackbarListenerDirective {
|
|
|
18123
18175
|
*/
|
|
18124
18176
|
observeNotificationsToStayOnTop(host) {
|
|
18125
18177
|
this.snackbarService.notifications$
|
|
18126
|
-
.pipe(startWith$1([]), pairwise(), filter$1(([before, after]) => after.length > before.length),
|
|
18178
|
+
.pipe(startWith$1([]), pairwise(), filter$1(([before, after]) => after.length > before.length), takeUntilDestroyed(this._destroyRef))
|
|
18127
18179
|
.subscribe(() => this.raiseToTopLayer(host));
|
|
18128
18180
|
}
|
|
18129
18181
|
raiseToTopLayer(host) {
|
|
@@ -18135,7 +18187,7 @@ class QdNotificationsSnackbarListenerDirective {
|
|
|
18135
18187
|
}
|
|
18136
18188
|
observeSafeBottomOffset(strategy) {
|
|
18137
18189
|
this.safeBottomOffset$
|
|
18138
|
-
.pipe(startWith$1(0), distinctUntilChanged$1(), debounceTime$1(250),
|
|
18190
|
+
.pipe(startWith$1(0), distinctUntilChanged$1(), debounceTime$1(250), takeUntilDestroyed(this._destroyRef))
|
|
18139
18191
|
.subscribe(safeBottomOffset => {
|
|
18140
18192
|
strategy.withPositions(this.bottomRightPositions(safeBottomOffset));
|
|
18141
18193
|
this._overlayRef.updatePosition();
|
|
@@ -18705,9 +18757,9 @@ class QdGridAutoFillService {
|
|
|
18705
18757
|
gridService = inject(QdGridService);
|
|
18706
18758
|
breakpointService = inject(QdBreakpointService);
|
|
18707
18759
|
changeDetectorRef = inject(ChangeDetectorRef);
|
|
18760
|
+
_destroyRef = inject(DestroyRef);
|
|
18708
18761
|
_columnsDirective;
|
|
18709
18762
|
_columnElements;
|
|
18710
|
-
_destroyed$ = new Subject();
|
|
18711
18763
|
get columnsDirectiveElement() {
|
|
18712
18764
|
return this._columnsDirective.element;
|
|
18713
18765
|
}
|
|
@@ -18719,10 +18771,6 @@ class QdGridAutoFillService {
|
|
|
18719
18771
|
this.fillRemainingWidthWhenBreakpointIsCrossed();
|
|
18720
18772
|
}
|
|
18721
18773
|
}
|
|
18722
|
-
destroy() {
|
|
18723
|
-
this._destroyed$.next();
|
|
18724
|
-
this._destroyed$.complete();
|
|
18725
|
-
}
|
|
18726
18774
|
async waitForColspansToBeApplied() {
|
|
18727
18775
|
return Promise.all([
|
|
18728
18776
|
firstValueFrom(this._columnsDirective.columnsNum$),
|
|
@@ -18743,7 +18791,7 @@ class QdGridAutoFillService {
|
|
|
18743
18791
|
fillRemainingWidthWhenBreakpointIsCrossed() {
|
|
18744
18792
|
this.breakpointService
|
|
18745
18793
|
.getMatchingBreakpoint()
|
|
18746
|
-
.pipe(
|
|
18794
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
18747
18795
|
.subscribe(this.fillRemainingWidth.bind(this));
|
|
18748
18796
|
}
|
|
18749
18797
|
async fillRemainingWidth(breakpoint) {
|
|
@@ -18900,9 +18948,6 @@ class QdColumnsDirective {
|
|
|
18900
18948
|
async ngAfterViewInit() {
|
|
18901
18949
|
await this.gridAutoFillService.initialize(this);
|
|
18902
18950
|
}
|
|
18903
|
-
ngOnDestroy() {
|
|
18904
|
-
this.gridAutoFillService.destroy();
|
|
18905
|
-
}
|
|
18906
18951
|
static getQdColumnsGridSize(element) {
|
|
18907
18952
|
const result = /qd-columns-(\d+)/.exec(element.className);
|
|
18908
18953
|
if (result && result[1]) {
|
|
@@ -19519,20 +19564,16 @@ class QdContactCardMenuComponent {
|
|
|
19519
19564
|
this._actionsSubject.next(actions);
|
|
19520
19565
|
}
|
|
19521
19566
|
testId = 'contact-card-menu';
|
|
19522
|
-
|
|
19567
|
+
_destroyRef = inject(DestroyRef);
|
|
19523
19568
|
_actionsSubject = new BehaviorSubject([]);
|
|
19524
19569
|
_operationModeSubject = new BehaviorSubject(undefined);
|
|
19525
19570
|
actions$ = combineLatest([
|
|
19526
19571
|
this._actionsSubject,
|
|
19527
19572
|
this._operationModeSubject
|
|
19528
|
-
]).pipe(
|
|
19573
|
+
]).pipe(takeUntilDestroyed(this._destroyRef), map(([actions, operationMode]) => this.getActionsFilteredByOperationMode(actions, operationMode)), map(actions => actions.filter(action => !this.isHidden(action))), map(actions => actions.map(action => ({ ...action, isDisabled: this.isDisabled(action) }))));
|
|
19529
19574
|
ngOnInit() {
|
|
19530
19575
|
this.syncPageOperationMode();
|
|
19531
19576
|
}
|
|
19532
|
-
ngOnDestroy() {
|
|
19533
|
-
this._destroyed$.next();
|
|
19534
|
-
this._destroyed$.complete();
|
|
19535
|
-
}
|
|
19536
19577
|
isDisabled(action) {
|
|
19537
19578
|
const { isDisabled } = action;
|
|
19538
19579
|
return (typeof isDisabled === 'function' ? isDisabled(this.contactData) : isDisabled) ?? false;
|
|
@@ -19543,7 +19584,7 @@ class QdContactCardMenuComponent {
|
|
|
19543
19584
|
}
|
|
19544
19585
|
syncPageOperationMode() {
|
|
19545
19586
|
if (this.pageStoreService) {
|
|
19546
|
-
this.pageStoreService.isViewonly$.pipe(
|
|
19587
|
+
this.pageStoreService.isViewonly$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(viewonly => {
|
|
19547
19588
|
this._operationModeSubject.next(viewonly ? 'view' : 'edit');
|
|
19548
19589
|
});
|
|
19549
19590
|
}
|
|
@@ -20131,6 +20172,7 @@ class QdDialogConfirmationComponent {
|
|
|
20131
20172
|
qdNotificationService = inject(QdNotificationsService);
|
|
20132
20173
|
dialogRef = inject(DialogRef);
|
|
20133
20174
|
snackbarService = inject(QdSnackbarService);
|
|
20175
|
+
_destroyRef = inject(DestroyRef);
|
|
20134
20176
|
/**
|
|
20135
20177
|
* The configuration object of the QdDialogConfirm component.
|
|
20136
20178
|
*/
|
|
@@ -20143,7 +20185,6 @@ class QdDialogConfirmationComponent {
|
|
|
20143
20185
|
notificationContext = 'confirm-modal';
|
|
20144
20186
|
confirmChecked = [];
|
|
20145
20187
|
checkboxConfig;
|
|
20146
|
-
_confirmSubscription = new Subscription();
|
|
20147
20188
|
get isLoading() {
|
|
20148
20189
|
return this.dialogService.isConfirmationLoading;
|
|
20149
20190
|
}
|
|
@@ -20164,10 +20205,10 @@ class QdDialogConfirmationComponent {
|
|
|
20164
20205
|
}
|
|
20165
20206
|
ngOnInit() {
|
|
20166
20207
|
this.snackbarService.pause();
|
|
20167
|
-
this.
|
|
20208
|
+
this.dialogRef?.closed.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => {
|
|
20168
20209
|
this.dialogService.resetConfirmation();
|
|
20169
20210
|
this.qdNotificationService.removeAll(this.notificationContext);
|
|
20170
|
-
})
|
|
20211
|
+
});
|
|
20171
20212
|
this.checkboxConfig = {
|
|
20172
20213
|
options: [
|
|
20173
20214
|
{
|
|
@@ -20181,7 +20222,6 @@ class QdDialogConfirmationComponent {
|
|
|
20181
20222
|
this.snackbarService.resume();
|
|
20182
20223
|
this.qdNotificationService.removeAll(this.notificationContext);
|
|
20183
20224
|
this.dialogService.resetConfirmation();
|
|
20184
|
-
this._confirmSubscription.unsubscribe();
|
|
20185
20225
|
}
|
|
20186
20226
|
close() {
|
|
20187
20227
|
this.dialogRef?.close();
|
|
@@ -20192,10 +20232,13 @@ class QdDialogConfirmationComponent {
|
|
|
20192
20232
|
return;
|
|
20193
20233
|
}
|
|
20194
20234
|
this.dialogService.startConfirmation();
|
|
20195
|
-
this.
|
|
20235
|
+
this.confirmationResolver
|
|
20236
|
+
.resolve()
|
|
20237
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
20238
|
+
.subscribe({
|
|
20196
20239
|
next: () => this.handleSuccess(),
|
|
20197
20240
|
error: errors => this.handleError(errors)
|
|
20198
|
-
})
|
|
20241
|
+
});
|
|
20199
20242
|
}
|
|
20200
20243
|
submit() {
|
|
20201
20244
|
this.dialogRef?.close(this.dialogService.confirmationState);
|
|
@@ -20267,7 +20310,7 @@ class QdPendingChangesGuardDirective {
|
|
|
20267
20310
|
formGroupDirective = inject(FormGroupDirective, { optional: true });
|
|
20268
20311
|
dialogRef = inject(DialogRef, { optional: true });
|
|
20269
20312
|
changeGuard = inject(QdDialogChangeGuardService);
|
|
20270
|
-
|
|
20313
|
+
_destroyRef = inject(DestroyRef);
|
|
20271
20314
|
initialValue;
|
|
20272
20315
|
formGroup;
|
|
20273
20316
|
constructor() {
|
|
@@ -20280,13 +20323,12 @@ class QdPendingChangesGuardDirective {
|
|
|
20280
20323
|
if (this.formGroup) {
|
|
20281
20324
|
this.initialValue = { ...this.formGroup.value };
|
|
20282
20325
|
this.updateStatus();
|
|
20283
|
-
this.
|
|
20326
|
+
this.formGroup.valueChanges.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => {
|
|
20284
20327
|
this.updateStatus();
|
|
20285
20328
|
});
|
|
20286
20329
|
}
|
|
20287
20330
|
}
|
|
20288
20331
|
ngOnDestroy() {
|
|
20289
|
-
this.statusSubscription?.unsubscribe();
|
|
20290
20332
|
this.reportPendingChanges(false);
|
|
20291
20333
|
}
|
|
20292
20334
|
updateStatus() {
|
|
@@ -20681,7 +20723,7 @@ class QdFileCollectorDialogItemProgressComponent {
|
|
|
20681
20723
|
return this.testId;
|
|
20682
20724
|
}
|
|
20683
20725
|
_uploadStateSubject = new BehaviorSubject(QdUploadProgressState.STARTING);
|
|
20684
|
-
|
|
20726
|
+
_destroyRef = inject(DestroyRef);
|
|
20685
20727
|
uploadState$ = this._uploadStateSubject.asObservable();
|
|
20686
20728
|
changeUploadStateFinishingToSuccessDelay = 1000;
|
|
20687
20729
|
ngOnInit() {
|
|
@@ -20690,14 +20732,11 @@ class QdFileCollectorDialogItemProgressComponent {
|
|
|
20690
20732
|
}
|
|
20691
20733
|
changeUploadStateFinishingToSuccessAfterDelay() {
|
|
20692
20734
|
this.uploadState$
|
|
20693
|
-
.pipe(switchMap$1(uploadState => uploadState === QdUploadProgressState.FINISHING ? timer(this.changeUploadStateFinishingToSuccessDelay) : NEVER),
|
|
20735
|
+
.pipe(switchMap$1(uploadState => uploadState === QdUploadProgressState.FINISHING ? timer(this.changeUploadStateFinishingToSuccessDelay) : NEVER), takeUntilDestroyed(this._destroyRef))
|
|
20694
20736
|
.subscribe(() => {
|
|
20695
20737
|
this._uploadStateSubject.next(QdUploadProgressState.SUCCESS);
|
|
20696
20738
|
});
|
|
20697
20739
|
}
|
|
20698
|
-
ngOnDestroy() {
|
|
20699
|
-
this._destroyed$.complete();
|
|
20700
|
-
}
|
|
20701
20740
|
ngOnChanges(changes) {
|
|
20702
20741
|
if ((changes['progress'] && !changes['progress'].firstChange) ||
|
|
20703
20742
|
(changes['error'] && !changes['error'].firstChange)) {
|
|
@@ -20822,7 +20861,7 @@ class QdFileCollectorDialogComponent {
|
|
|
20822
20861
|
fileCollectorService = inject(QdFileCollectorService, { skipSelf: true });
|
|
20823
20862
|
dialogFileCollectorService = inject(QdFileCollectorService);
|
|
20824
20863
|
dialogRef = inject(DialogRef);
|
|
20825
|
-
|
|
20864
|
+
_destroyRef = inject(DestroyRef);
|
|
20826
20865
|
selectedFile = null;
|
|
20827
20866
|
form;
|
|
20828
20867
|
isSaving = false;
|
|
@@ -20852,7 +20891,7 @@ class QdFileCollectorDialogComponent {
|
|
|
20852
20891
|
}
|
|
20853
20892
|
constructor() {
|
|
20854
20893
|
this.dialogFileCollectorService.config = this.fileCollectorService.config;
|
|
20855
|
-
this.dialogRef.keydownEvents.pipe(takeUntilDestroyed(this.
|
|
20894
|
+
this.dialogRef.keydownEvents.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(event => {
|
|
20856
20895
|
if (this.isSaving && event.key === 'Escape')
|
|
20857
20896
|
event.preventDefault();
|
|
20858
20897
|
});
|
|
@@ -21527,6 +21566,7 @@ class QdFileCollectorComponent {
|
|
|
21527
21566
|
dialogService = inject(QdDialogService);
|
|
21528
21567
|
viewContainerRef = inject(ViewContainerRef);
|
|
21529
21568
|
_changeDetectorRef = inject(ChangeDetectorRef);
|
|
21569
|
+
_destroyRef = inject(DestroyRef);
|
|
21530
21570
|
/**
|
|
21531
21571
|
* Configuration settings for the file collector.
|
|
21532
21572
|
*/
|
|
@@ -21536,7 +21576,6 @@ class QdFileCollectorComponent {
|
|
|
21536
21576
|
*/
|
|
21537
21577
|
testId = 'file-collector';
|
|
21538
21578
|
fileInput;
|
|
21539
|
-
_subscriptions = new Subscription();
|
|
21540
21579
|
_viewonly$ = new BehaviorSubject(false);
|
|
21541
21580
|
get fileUploads() {
|
|
21542
21581
|
return this.fileCollectorService.fileUploads;
|
|
@@ -21551,7 +21590,9 @@ class QdFileCollectorComponent {
|
|
|
21551
21590
|
this.initializeConfig(this.config);
|
|
21552
21591
|
this.initViewMode();
|
|
21553
21592
|
if (this.sectionActionService) {
|
|
21554
|
-
this.
|
|
21593
|
+
this.sectionActionService.action$
|
|
21594
|
+
.pipe(filter(type => type === 'addNew'), takeUntilDestroyed(this._destroyRef))
|
|
21595
|
+
.subscribe(() => this.clickFileInput());
|
|
21555
21596
|
}
|
|
21556
21597
|
}
|
|
21557
21598
|
ngOnChanges(changes) {
|
|
@@ -21559,9 +21600,6 @@ class QdFileCollectorComponent {
|
|
|
21559
21600
|
this.initializeConfig(this.config);
|
|
21560
21601
|
}
|
|
21561
21602
|
}
|
|
21562
|
-
ngOnDestroy() {
|
|
21563
|
-
this._subscriptions.unsubscribe();
|
|
21564
|
-
}
|
|
21565
21603
|
handleFiles(event) {
|
|
21566
21604
|
const dialogRef = this.dialogService.open(QdFileCollectorDialogComponent, {
|
|
21567
21605
|
dialogSize: QdDialogSize.Default,
|
|
@@ -21618,9 +21656,10 @@ class QdFileCollectorComponent {
|
|
|
21618
21656
|
return;
|
|
21619
21657
|
}
|
|
21620
21658
|
if (this.eventBroker)
|
|
21621
|
-
this.
|
|
21659
|
+
this.eventBroker
|
|
21622
21660
|
.consume('operation_mode_changed')
|
|
21623
|
-
.
|
|
21661
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
21662
|
+
.subscribe(({ payload }) => this._viewonly$.next(payload.isViewonly));
|
|
21624
21663
|
}
|
|
21625
21664
|
isConfigConsistentWithAllowedFileTypes(config) {
|
|
21626
21665
|
return (qdIsDeepEqual(config.allowedMimeTypes, this.fileTypeService.getMimeTypes(config.allowedFileTypes)) &&
|
|
@@ -21712,18 +21751,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
21712
21751
|
|
|
21713
21752
|
class LocaleDatePipe {
|
|
21714
21753
|
translateService = inject(TranslateService);
|
|
21754
|
+
_destroyRef = inject(DestroyRef);
|
|
21715
21755
|
currentLanguage = new ReplaySubject(1);
|
|
21716
|
-
sub;
|
|
21717
21756
|
constructor() {
|
|
21718
21757
|
const translateService = this.translateService;
|
|
21719
21758
|
this.currentLanguage.next(translateService.currentLang);
|
|
21720
|
-
this.
|
|
21759
|
+
this.translateService.onLangChange
|
|
21760
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
21761
|
+
.subscribe((event) => {
|
|
21721
21762
|
this.currentLanguage.next(event.lang);
|
|
21722
21763
|
});
|
|
21723
21764
|
}
|
|
21724
|
-
ngOnDestroy() {
|
|
21725
|
-
this.sub?.unsubscribe();
|
|
21726
|
-
}
|
|
21727
21765
|
formatDate(timestamp, lang = 'de', isDateTime = false, isTimePlaceholderSelected = false) {
|
|
21728
21766
|
const dateObj = QdDateAdapter.parseStoredDate(timestamp);
|
|
21729
21767
|
if (!dateObj)
|
|
@@ -22449,20 +22487,16 @@ class QdFilterItemBooleanComponent {
|
|
|
22449
22487
|
}
|
|
22450
22488
|
itemData;
|
|
22451
22489
|
active;
|
|
22452
|
-
|
|
22490
|
+
_destroyRef = inject(DestroyRef);
|
|
22453
22491
|
ngOnInit() {
|
|
22454
22492
|
this.filterService
|
|
22455
22493
|
.getItemById$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22456
|
-
.pipe(
|
|
22494
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
22457
22495
|
.subscribe(item => {
|
|
22458
22496
|
this.itemData = `${this.filterId}_${this.categoryIndex}_${this.itemIndex}_${item.item}`;
|
|
22459
22497
|
this.active = item.active;
|
|
22460
22498
|
});
|
|
22461
22499
|
}
|
|
22462
|
-
ngOnDestroy() {
|
|
22463
|
-
this._destroyed$.next();
|
|
22464
|
-
this._destroyed$.complete();
|
|
22465
|
-
}
|
|
22466
22500
|
clickToggle(value) {
|
|
22467
22501
|
this.filterService.setItemIsActive(this.filterId, this.categoryIndex, this.itemIndex, value === this.itemData);
|
|
22468
22502
|
}
|
|
@@ -22531,30 +22565,26 @@ class QdFilterItemFreeTextComponent {
|
|
|
22531
22565
|
item;
|
|
22532
22566
|
i18n;
|
|
22533
22567
|
inputValue = '';
|
|
22534
|
-
|
|
22568
|
+
_destroyRef = inject(DestroyRef);
|
|
22535
22569
|
get value() {
|
|
22536
22570
|
return (this.item && this.item.item) || '';
|
|
22537
22571
|
}
|
|
22538
22572
|
ngOnInit() {
|
|
22539
22573
|
this.filterService
|
|
22540
22574
|
.getCategoryById$(this.filterId, this.categoryIndex)
|
|
22541
|
-
.pipe(
|
|
22575
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
22542
22576
|
.subscribe(category => {
|
|
22543
22577
|
this.i18n = category.i18n;
|
|
22544
22578
|
});
|
|
22545
22579
|
this.filterService
|
|
22546
22580
|
.getItemById$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22547
|
-
.pipe(
|
|
22581
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
22548
22582
|
.subscribe(item => {
|
|
22549
22583
|
if ((item?.item ?? '') !== this.inputValue)
|
|
22550
22584
|
this.inputValue = '';
|
|
22551
22585
|
this.item = item;
|
|
22552
22586
|
});
|
|
22553
22587
|
}
|
|
22554
|
-
ngOnDestroy() {
|
|
22555
|
-
this._destroyed$.next();
|
|
22556
|
-
this._destroyed$.complete();
|
|
22557
|
-
}
|
|
22558
22588
|
handleValueChange(value) {
|
|
22559
22589
|
this.inputValue = value;
|
|
22560
22590
|
if (!this.isInstantFiltering && value !== '') {
|
|
@@ -22660,15 +22690,11 @@ class QdFilterItemDateComponent {
|
|
|
22660
22690
|
datepicker;
|
|
22661
22691
|
datepickerConfig = { viewonly: false };
|
|
22662
22692
|
item;
|
|
22663
|
-
|
|
22693
|
+
_destroyRef = inject(DestroyRef);
|
|
22664
22694
|
ngOnInit() {
|
|
22665
22695
|
this.datepickerConfig = { ...this.timePickerConfig, viewonly: false };
|
|
22666
22696
|
this.subscribeGetItem();
|
|
22667
22697
|
}
|
|
22668
|
-
ngOnDestroy() {
|
|
22669
|
-
this._destroyed$.next();
|
|
22670
|
-
this._destroyed$.complete();
|
|
22671
|
-
}
|
|
22672
22698
|
handleDateChange(date) {
|
|
22673
22699
|
if (date)
|
|
22674
22700
|
this.filterService.updateItem(this.filterId, this.categoryIndex, this.itemIndex, date.toISOString());
|
|
@@ -22682,7 +22708,7 @@ class QdFilterItemDateComponent {
|
|
|
22682
22708
|
subscribeGetItem() {
|
|
22683
22709
|
this.filterService
|
|
22684
22710
|
.getItemById$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22685
|
-
.pipe(
|
|
22711
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter(item => item !== undefined), tap(item => (this.item = QdDateAdapter.parseStoredDate(item.item))))
|
|
22686
22712
|
.subscribe();
|
|
22687
22713
|
}
|
|
22688
22714
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdFilterItemDateComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -22723,7 +22749,6 @@ class QdFilterItemDateCategoryComponent {
|
|
|
22723
22749
|
item$;
|
|
22724
22750
|
itemIndex = 0;
|
|
22725
22751
|
timePlaceholderSelected = true;
|
|
22726
|
-
_destroyed$ = new Subject();
|
|
22727
22752
|
ngOnInit() {
|
|
22728
22753
|
this.setCategoryI18n();
|
|
22729
22754
|
this.setItem();
|
|
@@ -22771,7 +22796,7 @@ class QdFilterItemDateRangeComponent {
|
|
|
22771
22796
|
clickTimePlaceholder = new EventEmitter();
|
|
22772
22797
|
item;
|
|
22773
22798
|
config = { disabledDates: [], viewonly: false };
|
|
22774
|
-
|
|
22799
|
+
_destroyRef = inject(DestroyRef);
|
|
22775
22800
|
get itemClassName() {
|
|
22776
22801
|
return `qd-filter__item-date-range qd-filter__item-date-range--${this.itemIndex}`;
|
|
22777
22802
|
}
|
|
@@ -22793,10 +22818,6 @@ class QdFilterItemDateRangeComponent {
|
|
|
22793
22818
|
this.subscribeMinMaxDate();
|
|
22794
22819
|
this.config = { ...this.config, timePicker: this.timePickerConfig };
|
|
22795
22820
|
}
|
|
22796
|
-
ngOnDestroy() {
|
|
22797
|
-
this._destroyed$.next();
|
|
22798
|
-
this._destroyed$.complete();
|
|
22799
|
-
}
|
|
22800
22821
|
handleDateChange(date) {
|
|
22801
22822
|
if (date)
|
|
22802
22823
|
this.filterService.updateItem(this.filterId, this.categoryIndex, this.itemIndex, date.toISOString());
|
|
@@ -22807,17 +22828,17 @@ class QdFilterItemDateRangeComponent {
|
|
|
22807
22828
|
subscribeGetItem() {
|
|
22808
22829
|
this.filterService
|
|
22809
22830
|
.getItemById$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22810
|
-
.pipe(
|
|
22831
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter(item => item !== undefined), tap(item => (this.item = QdDateAdapter.parseStoredDate(item.item))))
|
|
22811
22832
|
.subscribe();
|
|
22812
22833
|
}
|
|
22813
22834
|
subscribeMinMaxDate() {
|
|
22814
22835
|
this.filterService
|
|
22815
22836
|
.getMinDate$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22816
|
-
.pipe(
|
|
22837
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(minDate => this.updateDisabledDates(minDate, 'to')))
|
|
22817
22838
|
.subscribe();
|
|
22818
22839
|
this.filterService
|
|
22819
22840
|
.getMaxDate$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22820
|
-
.pipe(
|
|
22841
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(maxDate => this.updateDisabledDates(maxDate, 'from')))
|
|
22821
22842
|
.subscribe();
|
|
22822
22843
|
}
|
|
22823
22844
|
updateDisabledDates(date, targetProperty) {
|
|
@@ -22959,11 +22980,11 @@ class QdFilterItemMultiSelectComponent {
|
|
|
22959
22980
|
onMouseDown(event) {
|
|
22960
22981
|
event.preventDefault();
|
|
22961
22982
|
}
|
|
22962
|
-
|
|
22983
|
+
_destroyRef = inject(DestroyRef);
|
|
22963
22984
|
ngOnInit() {
|
|
22964
22985
|
this.filterService
|
|
22965
22986
|
.getItemById$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
22966
|
-
.pipe(
|
|
22987
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter(item => !!item))
|
|
22967
22988
|
.subscribe(item => {
|
|
22968
22989
|
this.item = item.item;
|
|
22969
22990
|
this.i18n = item.i18n;
|
|
@@ -22973,8 +22994,6 @@ class QdFilterItemMultiSelectComponent {
|
|
|
22973
22994
|
}
|
|
22974
22995
|
ngOnDestroy() {
|
|
22975
22996
|
this.category?.unregisterOption(this);
|
|
22976
|
-
this._destroyed$.next();
|
|
22977
|
-
this._destroyed$.complete();
|
|
22978
22997
|
}
|
|
22979
22998
|
setActiveStyles() {
|
|
22980
22999
|
this.isActive = true;
|
|
@@ -23063,12 +23082,12 @@ class QdFilterItemSingleSelectComponent {
|
|
|
23063
23082
|
event.preventDefault();
|
|
23064
23083
|
this.focus();
|
|
23065
23084
|
}
|
|
23066
|
-
|
|
23085
|
+
_destroyRef = inject(DestroyRef);
|
|
23067
23086
|
ngOnInit() {
|
|
23068
23087
|
this.setTabbable(false);
|
|
23069
23088
|
this.filterService
|
|
23070
23089
|
.getItemById$(this.filterId, this.categoryIndex, this.itemIndex)
|
|
23071
|
-
.pipe(
|
|
23090
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter(item => !!item))
|
|
23072
23091
|
.subscribe(item => {
|
|
23073
23092
|
this.item = item.item;
|
|
23074
23093
|
this.i18n = item.i18n;
|
|
@@ -23078,8 +23097,6 @@ class QdFilterItemSingleSelectComponent {
|
|
|
23078
23097
|
}
|
|
23079
23098
|
ngOnDestroy() {
|
|
23080
23099
|
this.category?.unregisterOption(this);
|
|
23081
|
-
this._destroyed$.next();
|
|
23082
|
-
this._destroyed$.complete();
|
|
23083
23100
|
}
|
|
23084
23101
|
setActiveStyles() {
|
|
23085
23102
|
this.isActive = true;
|
|
@@ -23921,6 +23938,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
23921
23938
|
|
|
23922
23939
|
class QdDependentFiltersService {
|
|
23923
23940
|
filterService = inject(QdFilterService);
|
|
23941
|
+
_destroyRef = inject(DestroyRef);
|
|
23924
23942
|
_filterComponent;
|
|
23925
23943
|
_subscription;
|
|
23926
23944
|
get filterData() {
|
|
@@ -23936,7 +23954,9 @@ class QdDependentFiltersService {
|
|
|
23936
23954
|
this._filterComponent = filterComponent;
|
|
23937
23955
|
this.getDependentCategories().forEach(dependentCategory => {
|
|
23938
23956
|
const dependentCategoryIndex = this.categories.indexOf(dependentCategory);
|
|
23939
|
-
const subscription = this.resolveItemsWhenDependsOnCategoriesChange(dependentCategory)
|
|
23957
|
+
const subscription = this.resolveItemsWhenDependsOnCategoriesChange(dependentCategory)
|
|
23958
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
23959
|
+
.subscribe((filterItems) => {
|
|
23940
23960
|
this.filterService.updateCategoryItems(this.filterId, dependentCategoryIndex, filterItems);
|
|
23941
23961
|
});
|
|
23942
23962
|
if (!this._subscription)
|
|
@@ -23945,10 +23965,10 @@ class QdDependentFiltersService {
|
|
|
23945
23965
|
});
|
|
23946
23966
|
}
|
|
23947
23967
|
reinitialize() {
|
|
23948
|
-
this.
|
|
23968
|
+
this.cancelItemResolution();
|
|
23949
23969
|
this.initialize(this._filterComponent);
|
|
23950
23970
|
}
|
|
23951
|
-
|
|
23971
|
+
cancelItemResolution() {
|
|
23952
23972
|
this._subscription?.unsubscribe();
|
|
23953
23973
|
delete this._subscription;
|
|
23954
23974
|
}
|
|
@@ -24105,6 +24125,7 @@ class QdFilterComponent {
|
|
|
24105
24125
|
filterService = inject(QdFilterService);
|
|
24106
24126
|
filterRouterConnectorService = inject(QdFilterRouterConnectorService);
|
|
24107
24127
|
dependentFiltersService = inject(QdDependentFiltersService);
|
|
24128
|
+
_destroyRef = inject(DestroyRef);
|
|
24108
24129
|
/**
|
|
24109
24130
|
* The configuration of the filter
|
|
24110
24131
|
*/
|
|
@@ -24140,10 +24161,6 @@ class QdFilterComponent {
|
|
|
24140
24161
|
disableFilterButton$;
|
|
24141
24162
|
disableResetButton$;
|
|
24142
24163
|
filterId;
|
|
24143
|
-
_queryStringSubscription;
|
|
24144
|
-
_postBodySubscription;
|
|
24145
|
-
_emitOutputsSubscription;
|
|
24146
|
-
_filterValueSubscription;
|
|
24147
24164
|
_filterDataSubject = new BehaviorSubject(undefined);
|
|
24148
24165
|
_isApplyDisabledWhileUnchangedSubject = new BehaviorSubject(false);
|
|
24149
24166
|
_hasPreselectionSubject = new ReplaySubject(1);
|
|
@@ -24186,11 +24203,6 @@ class QdFilterComponent {
|
|
|
24186
24203
|
}
|
|
24187
24204
|
}
|
|
24188
24205
|
ngOnDestroy() {
|
|
24189
|
-
this.dependentFiltersService.destroy();
|
|
24190
|
-
this._queryStringSubscription?.unsubscribe();
|
|
24191
|
-
this._postBodySubscription?.unsubscribe();
|
|
24192
|
-
this._emitOutputsSubscription?.unsubscribe();
|
|
24193
|
-
this._filterValueSubscription?.unsubscribe();
|
|
24194
24206
|
/* the ReplaySubjects would cause an initial emission of the outputs if the component is reinitialized
|
|
24195
24207
|
* (when navigating back for example). ReplaySubjects are used here because the subscription of the section
|
|
24196
24208
|
* is delayed in the integrated solution with the qdConnectToFilter directive. */
|
|
@@ -24254,22 +24266,26 @@ class QdFilterComponent {
|
|
|
24254
24266
|
this._isApplyDisabledWhileUnchangedSubject
|
|
24255
24267
|
]).pipe(map(([hasActive, currentPostBody, applied, isApplyDisabledWhileUnchanged]) => !hasActive || (isApplyDisabledWhileUnchanged && this.isUnchangedSince(currentPostBody, applied))));
|
|
24256
24268
|
this.initResetButtonActivation();
|
|
24257
|
-
this.
|
|
24269
|
+
this.filterService
|
|
24258
24270
|
.getQueryString$(this.filterId)
|
|
24271
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
24259
24272
|
.subscribe(queryString => this.queryStringOutput.emit(queryString));
|
|
24260
|
-
this.
|
|
24273
|
+
this.filterService
|
|
24261
24274
|
.getPostBody$(this.filterId)
|
|
24275
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
24262
24276
|
.subscribe(postBody => this.postBodyOutput.emit(postBody));
|
|
24263
24277
|
this.hasPreselection = hasActiveCategory(this.filterData?.categories);
|
|
24264
|
-
|
|
24278
|
+
merge(this.hasPreselectionAfterRouterConnection$.pipe(filter(hasPreselection => hasPreselection || this.filterData?.emitOutputsInitially)), this.allFiltersRemoved$)
|
|
24279
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
24280
|
+
.subscribe(() => {
|
|
24265
24281
|
this.emitOutputs();
|
|
24266
24282
|
});
|
|
24267
|
-
this.
|
|
24283
|
+
this.filterService
|
|
24268
24284
|
.getCurrentPostBody(this.filterId)
|
|
24269
24285
|
.pipe(distinctUntilChanged(qdIsDeepEqual), tap$1(() => {
|
|
24270
24286
|
if (this.isInstantFiltering)
|
|
24271
24287
|
this.emitOutputs();
|
|
24272
|
-
}))
|
|
24288
|
+
}), takeUntilDestroyed(this._destroyRef))
|
|
24273
24289
|
.subscribe(filterValue => this.valueChange.emit(filterValue));
|
|
24274
24290
|
this.initializeDependentFiltersService();
|
|
24275
24291
|
}
|
|
@@ -25345,18 +25361,16 @@ class QdOverflowFitDirective {
|
|
|
25345
25361
|
host = inject(ElementRef);
|
|
25346
25362
|
overflowFit = inject(QdOverflowFitService);
|
|
25347
25363
|
changeDetectorRef = inject(ChangeDetectorRef);
|
|
25348
|
-
|
|
25364
|
+
_destroyRef = inject(DestroyRef);
|
|
25349
25365
|
ngAfterViewInit() {
|
|
25350
25366
|
const indicator = this.host.nativeElement.querySelector(':scope > [data-fit-measure]');
|
|
25351
25367
|
if (!indicator)
|
|
25352
25368
|
return;
|
|
25353
|
-
this.
|
|
25369
|
+
this.overflowFit
|
|
25354
25370
|
.observe(this.rowElements(indicator))
|
|
25371
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
25355
25372
|
.subscribe(count => this.applyCount(count));
|
|
25356
25373
|
}
|
|
25357
|
-
ngOnDestroy() {
|
|
25358
|
-
this._subscription?.unsubscribe();
|
|
25359
|
-
}
|
|
25360
25374
|
isHidden(index) {
|
|
25361
25375
|
return index >= this.visibleCount;
|
|
25362
25376
|
}
|
|
@@ -25790,7 +25804,7 @@ class QdSearchComponent {
|
|
|
25790
25804
|
_configDataSubject = new BehaviorSubject({});
|
|
25791
25805
|
_search = '';
|
|
25792
25806
|
_preSelect = '';
|
|
25793
|
-
|
|
25807
|
+
_destroyRef = inject(DestroyRef);
|
|
25794
25808
|
_searchConnectedWithRouterSubject = new ReplaySubject(1);
|
|
25795
25809
|
_searchConnectedWithRouter$ = this._searchConnectedWithRouterSubject.asObservable();
|
|
25796
25810
|
get inputConfig() {
|
|
@@ -25858,7 +25872,7 @@ class QdSearchComponent {
|
|
|
25858
25872
|
});
|
|
25859
25873
|
this.searchRouterConnectorService
|
|
25860
25874
|
.connectSearchWithRouter(this)
|
|
25861
|
-
.pipe(
|
|
25875
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
25862
25876
|
.subscribe(() => this._searchConnectedWithRouterSubject.next());
|
|
25863
25877
|
}
|
|
25864
25878
|
waitForConfigData() {
|
|
@@ -25874,10 +25888,6 @@ class QdSearchComponent {
|
|
|
25874
25888
|
}
|
|
25875
25889
|
}
|
|
25876
25890
|
}
|
|
25877
|
-
ngOnDestroy() {
|
|
25878
|
-
this._destroyed$.next();
|
|
25879
|
-
this._destroyed$.complete();
|
|
25880
|
-
}
|
|
25881
25891
|
handleDelete() {
|
|
25882
25892
|
this.handleClear();
|
|
25883
25893
|
this.searchService.setSearchValues(this.search, this.preSelect);
|
|
@@ -26483,6 +26493,7 @@ class QdTableFillingWidthService {
|
|
|
26483
26493
|
tableStoreService = inject(QdTableStoreService);
|
|
26484
26494
|
zone = inject(NgZone);
|
|
26485
26495
|
injector = inject(Injector);
|
|
26496
|
+
_destroyRef = inject(DestroyRef);
|
|
26486
26497
|
renderRef;
|
|
26487
26498
|
tableComponentElement;
|
|
26488
26499
|
tableConfig;
|
|
@@ -26494,7 +26505,7 @@ class QdTableFillingWidthService {
|
|
|
26494
26505
|
tableWidth$ = new BehaviorSubject(0);
|
|
26495
26506
|
tableNumberOfColumns$ = new BehaviorSubject(0);
|
|
26496
26507
|
appliedWidth;
|
|
26497
|
-
|
|
26508
|
+
_stopWatching$ = new Subject();
|
|
26498
26509
|
get whichColumnFillsWidth() {
|
|
26499
26510
|
return this.tableConfig?.whichColumnFillsWidth || WHICH_COLUMN_FILLS_WIDTH_DEFAULT;
|
|
26500
26511
|
}
|
|
@@ -26507,7 +26518,7 @@ class QdTableFillingWidthService {
|
|
|
26507
26518
|
if (this.whichColumnFillsWidth === 'none')
|
|
26508
26519
|
return;
|
|
26509
26520
|
combineLatest([this.observeTableWidth(), this.observeTableData(), this.observeTableNumberOfColumns()])
|
|
26510
|
-
.pipe(debounceTime(DEBOUNCE_TIME), takeUntil(this.
|
|
26521
|
+
.pipe(debounceTime(DEBOUNCE_TIME), takeUntil(this._stopWatching$), takeUntilDestroyed(this._destroyRef))
|
|
26511
26522
|
.subscribe(() => this.fillRemainingWidth());
|
|
26512
26523
|
}
|
|
26513
26524
|
/**
|
|
@@ -26518,7 +26529,10 @@ class QdTableFillingWidthService {
|
|
|
26518
26529
|
this.reinitialize();
|
|
26519
26530
|
}
|
|
26520
26531
|
/**
|
|
26521
|
-
* Stops watching the table
|
|
26532
|
+
* Stops watching the table right away and disconnects the observers.
|
|
26533
|
+
*
|
|
26534
|
+
* The owner calls it in its destroy hook, before it resets the table store.
|
|
26535
|
+
* The watch also ends when the owner is destroyed, but only after its destroy hooks.
|
|
26522
26536
|
*/
|
|
26523
26537
|
destroy() {
|
|
26524
26538
|
this.clearSubscriptions();
|
|
@@ -26628,11 +26642,11 @@ class QdTableFillingWidthService {
|
|
|
26628
26642
|
const tableData$ = new ReplaySubject(1);
|
|
26629
26643
|
this.tableStoreService
|
|
26630
26644
|
.tableDataEntries$()
|
|
26631
|
-
.pipe(take(1), takeUntil(this.
|
|
26645
|
+
.pipe(take(1), takeUntil(this._stopWatching$), takeUntilDestroyed(this._destroyRef))
|
|
26632
26646
|
.subscribe(data => tableData$.next(data));
|
|
26633
26647
|
this.tableStoreService
|
|
26634
26648
|
.tableDataEntries$()
|
|
26635
|
-
.pipe(skip(1), takeUntil(this.
|
|
26649
|
+
.pipe(skip(1), takeUntil(this._stopWatching$), takeUntilDestroyed(this._destroyRef))
|
|
26636
26650
|
.subscribe(data => {
|
|
26637
26651
|
this.renderRef?.destroy();
|
|
26638
26652
|
this.renderRef = afterNextRender(() => this.zone.runOutsideAngular(() => tableData$.next(data)), {
|
|
@@ -26647,7 +26661,7 @@ class QdTableFillingWidthService {
|
|
|
26647
26661
|
this.initialize(this.tableComponentElement, this.tableConfig);
|
|
26648
26662
|
}
|
|
26649
26663
|
clearSubscriptions() {
|
|
26650
|
-
this.
|
|
26664
|
+
this._stopWatching$.next();
|
|
26651
26665
|
this.renderRef?.destroy();
|
|
26652
26666
|
this.pauseObservers();
|
|
26653
26667
|
}
|
|
@@ -27028,7 +27042,7 @@ class QdTableResolverService {
|
|
|
27028
27042
|
tableStoreService = inject(QdTableStoreService);
|
|
27029
27043
|
translateService = inject(TranslateService);
|
|
27030
27044
|
actionResultService = inject(QdTableExternalActionResultService);
|
|
27031
|
-
|
|
27045
|
+
_destroyRef = inject(DestroyRef);
|
|
27032
27046
|
_refreshSubscription;
|
|
27033
27047
|
_hasPagination = true;
|
|
27034
27048
|
_isNavigatingToValidPage = false;
|
|
@@ -27036,10 +27050,6 @@ class QdTableResolverService {
|
|
|
27036
27050
|
constructor() {
|
|
27037
27051
|
this.subscribeToExternalRefresh();
|
|
27038
27052
|
}
|
|
27039
|
-
ngOnDestroy() {
|
|
27040
|
-
this._destroyed$.next(null);
|
|
27041
|
-
this._destroyed$.complete();
|
|
27042
|
-
}
|
|
27043
27053
|
init(refreshOnLanguageChange, hasPagination = true) {
|
|
27044
27054
|
const resolver = this.tableDataResolver;
|
|
27045
27055
|
if (!resolver)
|
|
@@ -27049,7 +27059,7 @@ class QdTableResolverService {
|
|
|
27049
27059
|
this.subscribeToLangChanges();
|
|
27050
27060
|
this.tableStoreService
|
|
27051
27061
|
.selectDataResolutionCriteria$()
|
|
27052
|
-
.pipe(distinctUntilChanged(qdIsDeepEqual), filter((resolutionCriteria) => !!resolutionCriteria && this.shouldDataBeResolved(resolutionCriteria)), map(resolutionCriteria => this.buildCriteriaParams(resolutionCriteria)), switchMap$1(resolutionParams => this.resolveAndApply(resolver, resolutionParams)),
|
|
27062
|
+
.pipe(distinctUntilChanged(qdIsDeepEqual), filter((resolutionCriteria) => !!resolutionCriteria && this.shouldDataBeResolved(resolutionCriteria)), map(resolutionCriteria => this.buildCriteriaParams(resolutionCriteria)), switchMap$1(resolutionParams => this.resolveAndApply(resolver, resolutionParams)), takeUntilDestroyed(this._destroyRef))
|
|
27053
27063
|
.subscribe();
|
|
27054
27064
|
}
|
|
27055
27065
|
refresh(resolverOptions = {}) {
|
|
@@ -27060,11 +27070,11 @@ class QdTableResolverService {
|
|
|
27060
27070
|
this._refreshSubscription?.unsubscribe();
|
|
27061
27071
|
this._refreshSubscription = this.tableStoreService
|
|
27062
27072
|
.selectDataResolutionCriteria$()
|
|
27063
|
-
.pipe(filter((criteria) => !!criteria), take$1(1), filter(criteria => !this.isAwaitingConnectors(criteria)), switchMap$1(resolutionCriteria => this.resolveAndApply(resolver, this.buildRefreshParams(resolutionCriteria, pageIndex))),
|
|
27073
|
+
.pipe(filter((criteria) => !!criteria), take$1(1), filter(criteria => !this.isAwaitingConnectors(criteria)), switchMap$1(resolutionCriteria => this.resolveAndApply(resolver, this.buildRefreshParams(resolutionCriteria, pageIndex))), takeUntilDestroyed(this._destroyRef))
|
|
27064
27074
|
.subscribe();
|
|
27065
27075
|
}
|
|
27066
27076
|
subscribeToLangChanges() {
|
|
27067
|
-
this.translateService.onLangChange.pipe(
|
|
27077
|
+
this.translateService.onLangChange.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => this.refresh());
|
|
27068
27078
|
}
|
|
27069
27079
|
shouldDataBeResolved(criteria) {
|
|
27070
27080
|
if (this.isAwaitingConnectors(criteria))
|
|
@@ -27078,7 +27088,7 @@ class QdTableResolverService {
|
|
|
27078
27088
|
}
|
|
27079
27089
|
subscribeToExternalRefresh() {
|
|
27080
27090
|
this.actionResultService.actionSuccess$
|
|
27081
|
-
.pipe(
|
|
27091
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
27082
27092
|
.subscribe(pageIndex => this.refresh({ pageIndex }));
|
|
27083
27093
|
}
|
|
27084
27094
|
buildCriteriaParams({ tableParams, connectorParams }) {
|
|
@@ -27241,6 +27251,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
27241
27251
|
// @ts-strict-ignore
|
|
27242
27252
|
class QdTableRowSelectionService {
|
|
27243
27253
|
tableStoreService = inject(QdTableStoreService);
|
|
27254
|
+
_destroyRef = inject(DestroyRef);
|
|
27244
27255
|
_config;
|
|
27245
27256
|
_visibleRowsSubscription;
|
|
27246
27257
|
set config(config) {
|
|
@@ -27249,11 +27260,9 @@ class QdTableRowSelectionService {
|
|
|
27249
27260
|
this._visibleRowsSubscription?.unsubscribe();
|
|
27250
27261
|
this._visibleRowsSubscription = this.tableStoreService
|
|
27251
27262
|
.tableDataEntries$()
|
|
27263
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
27252
27264
|
.subscribe(rows => this.refreshCacheForVisibleRows(rows));
|
|
27253
27265
|
}
|
|
27254
|
-
ngOnDestroy() {
|
|
27255
|
-
this._visibleRowsSubscription?.unsubscribe();
|
|
27256
|
-
}
|
|
27257
27266
|
get tableId() {
|
|
27258
27267
|
return this.tableStoreService.tableId;
|
|
27259
27268
|
}
|
|
@@ -27628,19 +27637,15 @@ class QdTablePaginatorPageSizeDirective {
|
|
|
27628
27637
|
tableDataResolver = inject(QD_TABLE_DATA_RESOLVER_TOKEN, { optional: true });
|
|
27629
27638
|
elementRef = inject(ElementRef);
|
|
27630
27639
|
tableStoreService = inject(QdTableStoreService);
|
|
27640
|
+
_destroyRef = inject(DestroyRef);
|
|
27631
27641
|
qdTablePaginatorPageSize;
|
|
27632
|
-
_destroyed$ = new Subject();
|
|
27633
27642
|
ngOnInit() {
|
|
27634
27643
|
if (this.tableDataResolver) {
|
|
27635
27644
|
fromEvent(this.elementRef.nativeElement, 'click')
|
|
27636
|
-
.pipe(
|
|
27645
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter(() => !this.qdTablePaginatorPageSize.disabled), tap(() => this.tableStoreService.setPageSize(this.qdTablePaginatorPageSize.value)))
|
|
27637
27646
|
.subscribe();
|
|
27638
27647
|
}
|
|
27639
27648
|
}
|
|
27640
|
-
ngOnDestroy() {
|
|
27641
|
-
this._destroyed$.next(null);
|
|
27642
|
-
this._destroyed$.complete();
|
|
27643
|
-
}
|
|
27644
27649
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdTablePaginatorPageSizeDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
27645
27650
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.17", type: QdTablePaginatorPageSizeDirective, isStandalone: false, selector: "[qdTablePaginatorPageSize]", inputs: { qdTablePaginatorPageSize: "qdTablePaginatorPageSize" }, ngImport: i0 });
|
|
27646
27651
|
}
|
|
@@ -27668,7 +27673,6 @@ class QdTablePaginatorPageSizeComponent {
|
|
|
27668
27673
|
selectionDirection = 'up';
|
|
27669
27674
|
pageSize$;
|
|
27670
27675
|
totalCount$;
|
|
27671
|
-
_destroyed$ = new Subject();
|
|
27672
27676
|
get pageSizes$() {
|
|
27673
27677
|
return combineLatest([this.pageSize$, this.totalCount$]).pipe(map(([currentPageSize, totalCount]) => this.pageSizes
|
|
27674
27678
|
.slice(0, this.pageSizes.findIndex(pageSize => pageSize >= totalCount) + 1 || this.pageSizes.length)
|
|
@@ -27684,9 +27688,6 @@ class QdTablePaginatorPageSizeComponent {
|
|
|
27684
27688
|
this.pageSize$ = this.tableStoreService.pageSize$();
|
|
27685
27689
|
this.totalCount$ = this.tableStoreService.totalCount$();
|
|
27686
27690
|
}
|
|
27687
|
-
ngOnDestroy() {
|
|
27688
|
-
this._destroyed$.complete();
|
|
27689
|
-
}
|
|
27690
27691
|
toggleSelection() {
|
|
27691
27692
|
if (!this.selectionOpened) {
|
|
27692
27693
|
this.openSelection();
|
|
@@ -27751,6 +27752,7 @@ class QdTablePaginatorComponent {
|
|
|
27751
27752
|
tableStoreService = inject(QdTableStoreService);
|
|
27752
27753
|
routerConnector = inject(QdTablePaginationRouterConnectorService);
|
|
27753
27754
|
scrollAnchorService = inject(QdTableScrollAnchorService, { optional: true });
|
|
27755
|
+
_destroyRef = inject(DestroyRef);
|
|
27754
27756
|
/**
|
|
27755
27757
|
* @description Configuration Model for Qd-Table.
|
|
27756
27758
|
*/
|
|
@@ -27769,7 +27771,6 @@ class QdTablePaginatorComponent {
|
|
|
27769
27771
|
totalCount$;
|
|
27770
27772
|
selectedRowsCount$;
|
|
27771
27773
|
pageNav = QdPaginatorDirection;
|
|
27772
|
-
_destroyed$ = new Subject();
|
|
27773
27774
|
get pageSizes() {
|
|
27774
27775
|
if (typeof this.config?.pagination !== 'object')
|
|
27775
27776
|
return [];
|
|
@@ -27789,10 +27790,6 @@ class QdTablePaginatorComponent {
|
|
|
27789
27790
|
if (this.isConfigValid())
|
|
27790
27791
|
this.startPagination();
|
|
27791
27792
|
}
|
|
27792
|
-
ngOnDestroy() {
|
|
27793
|
-
this._destroyed$.next(null);
|
|
27794
|
-
this._destroyed$.complete();
|
|
27795
|
-
}
|
|
27796
27793
|
/**
|
|
27797
27794
|
* @description Whether this paginator should sync its state with the URL. Reads
|
|
27798
27795
|
* `pagination.connectWithRouter` (default `false` — URL sync is opt-in and
|
|
@@ -27832,7 +27829,7 @@ class QdTablePaginatorComponent {
|
|
|
27832
27829
|
return;
|
|
27833
27830
|
this.tableStoreService
|
|
27834
27831
|
.table$()
|
|
27835
|
-
.pipe(
|
|
27832
|
+
.pipe(takeUntilDestroyed(this._destroyRef), take$1(1), tap(table => this.applyPageParams(direction, table)))
|
|
27836
27833
|
.subscribe();
|
|
27837
27834
|
}
|
|
27838
27835
|
applyPageParams(direction, table) {
|
|
@@ -27862,7 +27859,7 @@ class QdTablePaginatorComponent {
|
|
|
27862
27859
|
}
|
|
27863
27860
|
this.routerConnector
|
|
27864
27861
|
.connectPaginationWithRouter(this, this.tableStoreService)
|
|
27865
|
-
.pipe(
|
|
27862
|
+
.pipe(takeUntilDestroyed(this._destroyRef), take$1(1))
|
|
27866
27863
|
.subscribe(connected => {
|
|
27867
27864
|
if (!connected)
|
|
27868
27865
|
this.initPagination();
|
|
@@ -28075,7 +28072,7 @@ class QdTableRowActionsSecondaryMenuComponent {
|
|
|
28075
28072
|
actionsService = inject(QdTableSecondaryActionsService);
|
|
28076
28073
|
tableStore = inject(QdTableStoreService);
|
|
28077
28074
|
eventBroker = inject(QdEventBrokerService, { optional: true });
|
|
28078
|
-
|
|
28075
|
+
_destroyRef = inject(DestroyRef);
|
|
28079
28076
|
rowIndex;
|
|
28080
28077
|
rowData;
|
|
28081
28078
|
actions;
|
|
@@ -28111,7 +28108,6 @@ class QdTableRowActionsSecondaryMenuComponent {
|
|
|
28111
28108
|
this.evaluate(true);
|
|
28112
28109
|
}
|
|
28113
28110
|
ngOnDestroy() {
|
|
28114
|
-
this.forgetAll();
|
|
28115
28111
|
this._states$.next(new Map());
|
|
28116
28112
|
}
|
|
28117
28113
|
onActionClick(type) {
|
|
@@ -28129,7 +28125,7 @@ class QdTableRowActionsSecondaryMenuComponent {
|
|
|
28129
28125
|
this._operationMode$ ??= this.eventBroker?.consume('operation_mode_changed');
|
|
28130
28126
|
let isReplaying = true;
|
|
28131
28127
|
this._viewModeSubscription = this._operationMode$
|
|
28132
|
-
?.pipe(takeUntilDestroyed(this.
|
|
28128
|
+
?.pipe(takeUntilDestroyed(this._destroyRef))
|
|
28133
28129
|
.subscribe(({ payload }) => {
|
|
28134
28130
|
this._isViewonly = payload.isViewonly;
|
|
28135
28131
|
if (!isReplaying)
|
|
@@ -28228,7 +28224,7 @@ class QdTableRowActionsSecondaryMenuComponent {
|
|
|
28228
28224
|
this.forget(key);
|
|
28229
28225
|
this._resolutions.set(key, resolution);
|
|
28230
28226
|
resolution.subscription = availability$
|
|
28231
|
-
.pipe(map(value => this.validate(type, configKey, value)), catchError(error => of(this.reportError(type, configKey, { kind: 'emitted', text: 'emitted an error.', cause: error }))))
|
|
28227
|
+
.pipe(map(value => this.validate(type, configKey, value)), catchError(error => of(this.reportError(type, configKey, { kind: 'emitted', text: 'emitted an error.', cause: error }))), takeUntilDestroyed(this._destroyRef))
|
|
28232
28228
|
.subscribe(state => this.update(key, resolution, state));
|
|
28233
28229
|
}
|
|
28234
28230
|
update(key, resolution, state) {
|
|
@@ -28464,23 +28460,19 @@ class QdTableBodyComponent {
|
|
|
28464
28460
|
tableStoreService = inject(QdTableStoreService);
|
|
28465
28461
|
resolverService = inject(QdTableResolverService);
|
|
28466
28462
|
cdr = inject(ChangeDetectorRef);
|
|
28467
|
-
|
|
28463
|
+
_destroyRef = inject(DestroyRef);
|
|
28468
28464
|
config;
|
|
28469
28465
|
data;
|
|
28470
28466
|
testId;
|
|
28471
28467
|
isLoading$;
|
|
28472
28468
|
highlightedRowIdentifier;
|
|
28473
28469
|
trackByRowIdentifier = (rowIndex, rowData) => resolveRowIdentifier(rowData, rowIndex, this.config.trackRowBy);
|
|
28474
|
-
_primaryActionRefreshSubscription;
|
|
28475
28470
|
constructor() {
|
|
28476
28471
|
this.isLoading$ = this.tableStoreService.selectIsLoading$().pipe(debounceTime$1(400));
|
|
28477
28472
|
}
|
|
28478
28473
|
ngOnInit() {
|
|
28479
28474
|
this.initHighlight();
|
|
28480
28475
|
}
|
|
28481
|
-
ngOnDestroy() {
|
|
28482
|
-
this._primaryActionRefreshSubscription?.unsubscribe();
|
|
28483
|
-
}
|
|
28484
28476
|
isLastVisitedRow(rowData, rowIndex) {
|
|
28485
28477
|
if (this.highlightedRowIdentifier === undefined)
|
|
28486
28478
|
return false;
|
|
@@ -28496,9 +28488,7 @@ class QdTableBodyComponent {
|
|
|
28496
28488
|
if (!this.config.primaryAction?.refresh?.isEnabled)
|
|
28497
28489
|
return;
|
|
28498
28490
|
if (result instanceof Observable) {
|
|
28499
|
-
this.
|
|
28500
|
-
.pipe(take(1))
|
|
28501
|
-
.subscribe(success => success && !this.destroyRef.destroyed && this.triggerRefresh());
|
|
28491
|
+
result.pipe(take(1), takeUntilDestroyed(this._destroyRef)).subscribe(success => success && this.triggerRefresh());
|
|
28502
28492
|
return;
|
|
28503
28493
|
}
|
|
28504
28494
|
this.triggerRefresh();
|
|
@@ -28586,6 +28576,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
28586
28576
|
const MULTI_SORT = false;
|
|
28587
28577
|
class QdTableSortComponent {
|
|
28588
28578
|
tableStoreService = inject(QdTableStoreService);
|
|
28579
|
+
_destroyRef = inject(DestroyRef);
|
|
28589
28580
|
isSortable = false;
|
|
28590
28581
|
config;
|
|
28591
28582
|
column;
|
|
@@ -28594,7 +28585,6 @@ class QdTableSortComponent {
|
|
|
28594
28585
|
isActive = false;
|
|
28595
28586
|
showAsc$;
|
|
28596
28587
|
showDesc$;
|
|
28597
|
-
_isActiveSubscription = new Subscription();
|
|
28598
28588
|
_direction = QdSortDirection.NONE;
|
|
28599
28589
|
_multiSort = MULTI_SORT;
|
|
28600
28590
|
get direction() {
|
|
@@ -28613,9 +28603,6 @@ class QdTableSortComponent {
|
|
|
28613
28603
|
this.setShowAsc();
|
|
28614
28604
|
this.setShowDesc();
|
|
28615
28605
|
}
|
|
28616
|
-
ngOnDestroy() {
|
|
28617
|
-
this._isActiveSubscription.unsubscribe(); // takeUntil(_$destroyed) does not prevent call of selector projector
|
|
28618
|
-
}
|
|
28619
28606
|
getOpacity() {
|
|
28620
28607
|
return this.isSortable && !this.isActive ? '.5' : '1';
|
|
28621
28608
|
}
|
|
@@ -28638,12 +28625,12 @@ class QdTableSortComponent {
|
|
|
28638
28625
|
this.direction = this.config?.direction || QdSortDirection.NONE;
|
|
28639
28626
|
}
|
|
28640
28627
|
subscribeIsActive() {
|
|
28641
|
-
this.
|
|
28628
|
+
this.tableStoreService
|
|
28642
28629
|
.columnSortDirection$(this.column)
|
|
28643
28630
|
.pipe(filter(() => this.isSortable), tap(direction => (this.isActive = direction !== QdSortDirection.NONE)), tap(() => {
|
|
28644
28631
|
if (!this.isActive && !this._multiSort)
|
|
28645
28632
|
this.direction = QdSortDirection.NONE;
|
|
28646
|
-
}))
|
|
28633
|
+
}), takeUntilDestroyed(this._destroyRef))
|
|
28647
28634
|
.subscribe();
|
|
28648
28635
|
}
|
|
28649
28636
|
updateSortDirection() {
|
|
@@ -28891,7 +28878,7 @@ class QdTableComponent {
|
|
|
28891
28878
|
resolverService = inject(QdTableResolverService);
|
|
28892
28879
|
confirmationDialogService = inject(QdConfirmationDialogOpenerService);
|
|
28893
28880
|
sortRouterConnector = inject(QdTableSortRouterConnectorService);
|
|
28894
|
-
|
|
28881
|
+
_destroyRef = inject(DestroyRef);
|
|
28895
28882
|
/**
|
|
28896
28883
|
* Configuration of the table. The generic type specifies the column definition. <br />
|
|
28897
28884
|
* Required. Without a config, the table throws an error on init and shows nothing. <br />
|
|
@@ -28978,11 +28965,6 @@ class QdTableComponent {
|
|
|
28978
28965
|
hasEmptyStateView$;
|
|
28979
28966
|
table$;
|
|
28980
28967
|
_data = [];
|
|
28981
|
-
_recentSecondaryActionsSubscription;
|
|
28982
|
-
_rowSelectionServiceSubscription;
|
|
28983
|
-
_emptyStateActionServiceSubscription;
|
|
28984
|
-
_breakpointSubscription;
|
|
28985
|
-
_pushEventsSubscription;
|
|
28986
28968
|
_refreshSubscription;
|
|
28987
28969
|
_deselectAllSubscription;
|
|
28988
28970
|
_connectors = [];
|
|
@@ -29041,13 +29023,6 @@ class QdTableComponent {
|
|
|
29041
29023
|
this.tableStoreService.resetConnectorStates();
|
|
29042
29024
|
this.fillingWidthService.destroy();
|
|
29043
29025
|
this.scrollAnchorService.destroy();
|
|
29044
|
-
this._recentSecondaryActionsSubscription?.unsubscribe();
|
|
29045
|
-
this._rowSelectionServiceSubscription?.unsubscribe();
|
|
29046
|
-
this._emptyStateActionServiceSubscription?.unsubscribe();
|
|
29047
|
-
this._breakpointSubscription?.unsubscribe();
|
|
29048
|
-
this._pushEventsSubscription?.unsubscribe();
|
|
29049
|
-
this._refreshSubscription?.unsubscribe();
|
|
29050
|
-
this._deselectAllSubscription?.unsubscribe();
|
|
29051
29026
|
if (!this.config.uid || this.config.refreshOnPushEvent)
|
|
29052
29027
|
this.tableStoreService.deleteTableState();
|
|
29053
29028
|
}
|
|
@@ -29073,7 +29048,10 @@ class QdTableComponent {
|
|
|
29073
29048
|
}
|
|
29074
29049
|
initializeResponsiveRowService() {
|
|
29075
29050
|
this.responsiveRowService.config = this.config;
|
|
29076
|
-
this.
|
|
29051
|
+
this.breakpointService
|
|
29052
|
+
.getMatchingBreakpoint()
|
|
29053
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
29054
|
+
.subscribe(breakpoint => {
|
|
29077
29055
|
this.responsiveRowService.currentBreakpoint = breakpoint;
|
|
29078
29056
|
});
|
|
29079
29057
|
}
|
|
@@ -29093,14 +29071,16 @@ class QdTableComponent {
|
|
|
29093
29071
|
this.fillingWidthService.updateTableConfig(this.config);
|
|
29094
29072
|
}
|
|
29095
29073
|
initializeEmptyStateService() {
|
|
29096
|
-
this.
|
|
29074
|
+
this.emptyStateService.emptyStateAction$
|
|
29075
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
29076
|
+
.subscribe(() => this.emptyStateActionOutput.emit());
|
|
29097
29077
|
}
|
|
29098
29078
|
initializeEmptyStateView() {
|
|
29099
29079
|
this.hasEmptyStateView$ = this.hasData$.pipe(map(hasData => !hasData && !!this.config.emptyStateView && !this.config.emptyStateView.disabled));
|
|
29100
29080
|
}
|
|
29101
29081
|
initializeRowSelectionService() {
|
|
29102
29082
|
this.rowSelectionService.config = this.config;
|
|
29103
|
-
this.
|
|
29083
|
+
this.rowSelectionService.selectedRows$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(selectedRows => {
|
|
29104
29084
|
this.selectedRowsOutput.emit(selectedRows);
|
|
29105
29085
|
this.config.selection?.handler?.(selectedRows);
|
|
29106
29086
|
});
|
|
@@ -29111,7 +29091,9 @@ class QdTableComponent {
|
|
|
29111
29091
|
}
|
|
29112
29092
|
subscribeToDeselectAll(ignoresReplayedValue = false) {
|
|
29113
29093
|
let isSubscribing = ignoresReplayedValue;
|
|
29114
|
-
this._deselectAllSubscription = this.config.selection?.deselectAll
|
|
29094
|
+
this._deselectAllSubscription = this.config.selection?.deselectAll$
|
|
29095
|
+
?.pipe(takeUntilDestroyed(this._destroyRef))
|
|
29096
|
+
.subscribe(() => {
|
|
29115
29097
|
if (!isSubscribing)
|
|
29116
29098
|
this.rowSelectionService.clearAll();
|
|
29117
29099
|
});
|
|
@@ -29128,9 +29110,9 @@ class QdTableComponent {
|
|
|
29128
29110
|
}
|
|
29129
29111
|
}
|
|
29130
29112
|
initializeSecondaryActionsService() {
|
|
29131
|
-
this.
|
|
29113
|
+
this.tableStoreService
|
|
29132
29114
|
.recentSecondaryAction$()
|
|
29133
|
-
.pipe(switchMap(recentAction => this.whenSecondaryActionAvailable$(recentAction)))
|
|
29115
|
+
.pipe(switchMap(recentAction => this.whenSecondaryActionAvailable$(recentAction)), takeUntilDestroyed(this._destroyRef))
|
|
29134
29116
|
.subscribe(recentAction => {
|
|
29135
29117
|
this.secondaryActionOutput.emit(recentAction);
|
|
29136
29118
|
const action = this.config.secondaryActions?.find(a => a.type === recentAction.type);
|
|
@@ -29177,7 +29159,7 @@ class QdTableComponent {
|
|
|
29177
29159
|
const pushEventsService = this.pushEventsService;
|
|
29178
29160
|
const events = [...(this.config?.refreshingEvents || []), 'RESOURCE_UPDATED'];
|
|
29179
29161
|
const combinedEvents$ = merge(...events.map(eventName => pushEventsService.observe(eventName)));
|
|
29180
|
-
|
|
29162
|
+
combinedEvents$
|
|
29181
29163
|
.pipe(filter(messageEvent => {
|
|
29182
29164
|
try {
|
|
29183
29165
|
const data = JSON.parse(messageEvent.data);
|
|
@@ -29190,22 +29172,22 @@ class QdTableComponent {
|
|
|
29190
29172
|
}), catchError(error => {
|
|
29191
29173
|
console.error('Quadrel Framework | QdTable - Error in event stream:', error);
|
|
29192
29174
|
return NEVER;
|
|
29193
|
-
}))
|
|
29175
|
+
}), takeUntilDestroyed(this._destroyRef))
|
|
29194
29176
|
.subscribe(() => this.triggerRefresh());
|
|
29195
29177
|
}
|
|
29196
29178
|
processSecondaryActionRefresh(result, refreshConfig) {
|
|
29197
29179
|
if (result instanceof Observable) {
|
|
29198
29180
|
result
|
|
29199
29181
|
.pipe(take(1))
|
|
29200
|
-
.subscribe(success => success && !this.
|
|
29182
|
+
.subscribe(success => success && !this._destroyRef.destroyed && this.triggerRefresh(refreshConfig.page));
|
|
29201
29183
|
return;
|
|
29202
29184
|
}
|
|
29203
|
-
if (!this.
|
|
29185
|
+
if (!this._destroyRef.destroyed)
|
|
29204
29186
|
this.triggerRefresh(refreshConfig.page);
|
|
29205
29187
|
}
|
|
29206
29188
|
initRefresh(ignoresReplayedValue = false) {
|
|
29207
29189
|
let isSubscribing = ignoresReplayedValue;
|
|
29208
|
-
this._refreshSubscription = this.config.refresh?.subscribe(value => {
|
|
29190
|
+
this._refreshSubscription = this.config.refresh?.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(value => {
|
|
29209
29191
|
if (!isSubscribing)
|
|
29210
29192
|
this.triggerRefresh(value);
|
|
29211
29193
|
});
|
|
@@ -29415,13 +29397,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
29415
29397
|
class QdConnectorTableContextDirective {
|
|
29416
29398
|
tableComponent = inject(QdTableComponent, { host: true });
|
|
29417
29399
|
contextService = inject(QdContextService);
|
|
29418
|
-
|
|
29400
|
+
_destroyRef = inject(DestroyRef);
|
|
29419
29401
|
constructor() {
|
|
29420
29402
|
this.tableComponent.registerConnector('context');
|
|
29421
29403
|
}
|
|
29422
29404
|
ngOnInit() {
|
|
29423
29405
|
this.contextService.values$
|
|
29424
|
-
.pipe(
|
|
29406
|
+
.pipe(takeUntilDestroyed(this._destroyRef), map$1(values => ({
|
|
29425
29407
|
...values.reduce((previous, current) => ({
|
|
29426
29408
|
...previous,
|
|
29427
29409
|
[current.contextId]: current.value
|
|
@@ -29429,10 +29411,6 @@ class QdConnectorTableContextDirective {
|
|
|
29429
29411
|
})), tap$1(context => this.tableComponent.updateFromConnector('context', { context })))
|
|
29430
29412
|
.subscribe();
|
|
29431
29413
|
}
|
|
29432
|
-
ngOnDestroy() {
|
|
29433
|
-
this.destroyed.next(true);
|
|
29434
|
-
this.destroyed.complete();
|
|
29435
|
-
}
|
|
29436
29414
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdConnectorTableContextDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
29437
29415
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.17", type: QdConnectorTableContextDirective, isStandalone: false, selector: "qd-table[qdConnectToContext]", ngImport: i0 });
|
|
29438
29416
|
}
|
|
@@ -29500,7 +29478,7 @@ class QdConnectorTableFilterDirective {
|
|
|
29500
29478
|
*/
|
|
29501
29479
|
qdConnectToFilter;
|
|
29502
29480
|
filterComponent;
|
|
29503
|
-
|
|
29481
|
+
_destroyRef = inject(DestroyRef);
|
|
29504
29482
|
constructor() {
|
|
29505
29483
|
const toolbarComponentsService = this.toolbarComponentsService;
|
|
29506
29484
|
if (!toolbarComponentsService)
|
|
@@ -29517,10 +29495,6 @@ class QdConnectorTableFilterDirective {
|
|
|
29517
29495
|
this.filterComponent.updateFilterConfig({ ...this.qdConnectToFilter, emitOutputsInitially: true });
|
|
29518
29496
|
}
|
|
29519
29497
|
}
|
|
29520
|
-
ngOnDestroy() {
|
|
29521
|
-
this._destroyed$.next();
|
|
29522
|
-
this._destroyed$.complete();
|
|
29523
|
-
}
|
|
29524
29498
|
setFilterComponent() {
|
|
29525
29499
|
this.filterComponent = this.toolbarComponentsService.getComponent(QdFilterComponent);
|
|
29526
29500
|
}
|
|
@@ -29533,7 +29507,7 @@ class QdConnectorTableFilterDirective {
|
|
|
29533
29507
|
subscribeToFilterChanges() {
|
|
29534
29508
|
this.filterComponent
|
|
29535
29509
|
.getFilterChanges$()
|
|
29536
|
-
.pipe(
|
|
29510
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(filterChange => {
|
|
29537
29511
|
this.tableComponent.updateFromConnector('filter', { filter: filterChange });
|
|
29538
29512
|
}))
|
|
29539
29513
|
.subscribe();
|
|
@@ -29617,12 +29591,12 @@ class QdConnectorTableManualRefreshDirective {
|
|
|
29617
29591
|
tableComponent = inject(QdTableComponent, { host: true });
|
|
29618
29592
|
manualRefreshService = inject(QdSectionManualRefreshService, { optional: true });
|
|
29619
29593
|
tableDataResolver = inject(QD_TABLE_DATA_RESOLVER_TOKEN, { optional: true });
|
|
29620
|
-
|
|
29594
|
+
_destroyRef = inject(DestroyRef);
|
|
29621
29595
|
constructor() {
|
|
29622
29596
|
if (!this.manualRefreshService)
|
|
29623
29597
|
throw new Error('Quadrel Framework | QdConnectorTableManualRefresh - Please use this directive only within <qd-section>.');
|
|
29624
29598
|
const manualRefreshService = this.manualRefreshService;
|
|
29625
|
-
this.
|
|
29599
|
+
this._destroyRef.onDestroy(() => manualRefreshService.disableManualRefresh());
|
|
29626
29600
|
}
|
|
29627
29601
|
ngOnInit() {
|
|
29628
29602
|
if (!this.tableDataResolver) {
|
|
@@ -29633,10 +29607,10 @@ class QdConnectorTableManualRefreshDirective {
|
|
|
29633
29607
|
manualRefreshService.enableManualRefresh();
|
|
29634
29608
|
this.tableComponent
|
|
29635
29609
|
.selectIsLoadingForConnector$()
|
|
29636
|
-
.pipe(takeUntilDestroyed(this.
|
|
29610
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
29637
29611
|
.subscribe(isLoading => manualRefreshService.setManualRefreshBlocked(isLoading));
|
|
29638
29612
|
manualRefreshService.manualRefreshRequested$
|
|
29639
|
-
.pipe(takeUntilDestroyed(this.
|
|
29613
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
29640
29614
|
.subscribe(() => this.tableComponent.refreshFromConnector());
|
|
29641
29615
|
}
|
|
29642
29616
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdConnectorTableManualRefreshDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
@@ -29690,7 +29664,7 @@ class QdConnectorTableSearchDirective {
|
|
|
29690
29664
|
*/
|
|
29691
29665
|
qdConnectToSearch;
|
|
29692
29666
|
searchComponent;
|
|
29693
|
-
|
|
29667
|
+
_destroyRef = inject(DestroyRef);
|
|
29694
29668
|
constructor() {
|
|
29695
29669
|
const toolbarComponentsService = this.toolbarComponentsService;
|
|
29696
29670
|
if (!toolbarComponentsService)
|
|
@@ -29704,10 +29678,6 @@ class QdConnectorTableSearchDirective {
|
|
|
29704
29678
|
});
|
|
29705
29679
|
this.subscribeToSearchChanges();
|
|
29706
29680
|
}
|
|
29707
|
-
ngOnDestroy() {
|
|
29708
|
-
this._destroy$.next();
|
|
29709
|
-
this._destroy$.complete();
|
|
29710
|
-
}
|
|
29711
29681
|
setSearchComponent() {
|
|
29712
29682
|
this.searchComponent = this.toolbarComponentsService.getComponent(QdSearchComponent);
|
|
29713
29683
|
}
|
|
@@ -29719,7 +29689,7 @@ class QdConnectorTableSearchDirective {
|
|
|
29719
29689
|
subscribeToSearchChanges() {
|
|
29720
29690
|
this.searchComponent
|
|
29721
29691
|
.getSearchChanges$()
|
|
29722
|
-
.pipe(
|
|
29692
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(searchChange => this.tableComponent.updateFromConnector('search', { search: searchChange })))
|
|
29723
29693
|
.subscribe();
|
|
29724
29694
|
}
|
|
29725
29695
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdConnectorTableSearchDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
@@ -29815,6 +29785,7 @@ class QdSectionToolbarActionComponent {
|
|
|
29815
29785
|
changeDetectorRef = inject(ChangeDetectorRef);
|
|
29816
29786
|
breakpointService = inject(QdBreakpointService);
|
|
29817
29787
|
eventBroker = inject(QdEventBrokerService, { optional: true });
|
|
29788
|
+
_destroyRef = inject(DestroyRef);
|
|
29818
29789
|
set config(config) {
|
|
29819
29790
|
this._config = config;
|
|
29820
29791
|
this.validateConfig();
|
|
@@ -29825,19 +29796,14 @@ class QdSectionToolbarActionComponent {
|
|
|
29825
29796
|
groupedActionsMenu$;
|
|
29826
29797
|
_config = {};
|
|
29827
29798
|
_viewonly$ = new BehaviorSubject(false);
|
|
29828
|
-
_destroy$ = new Subject();
|
|
29829
29799
|
ngOnInit() {
|
|
29830
29800
|
this.initViewMode();
|
|
29831
29801
|
this.initActionStreams();
|
|
29832
29802
|
}
|
|
29833
|
-
ngOnDestroy() {
|
|
29834
|
-
this._destroy$.next();
|
|
29835
|
-
this._destroy$.complete();
|
|
29836
|
-
}
|
|
29837
29803
|
initViewMode() {
|
|
29838
29804
|
this.eventBroker
|
|
29839
29805
|
?.consume('operation_mode_changed')
|
|
29840
|
-
.pipe(
|
|
29806
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
29841
29807
|
.subscribe(({ payload }) => {
|
|
29842
29808
|
this._viewonly$.next(payload.isViewonly);
|
|
29843
29809
|
this.changeDetectorRef.markForCheck();
|
|
@@ -30092,6 +30058,7 @@ class QdSectionComponent {
|
|
|
30092
30058
|
filterService = inject(QdFilterService);
|
|
30093
30059
|
elementRef = inject(ElementRef);
|
|
30094
30060
|
cdr = inject(ChangeDetectorRef);
|
|
30061
|
+
_destroyRef = inject(DestroyRef);
|
|
30095
30062
|
/**
|
|
30096
30063
|
* The configuration of the section.
|
|
30097
30064
|
*/
|
|
@@ -30143,9 +30110,6 @@ class QdSectionComponent {
|
|
|
30143
30110
|
this.subscribeForOutputs();
|
|
30144
30111
|
}
|
|
30145
30112
|
}
|
|
30146
|
-
ngOnDestroy() {
|
|
30147
|
-
this.unsubscribeOutputSubscriptions();
|
|
30148
|
-
}
|
|
30149
30113
|
subscribeForOutputs() {
|
|
30150
30114
|
this.subscribeForSearchOutputs();
|
|
30151
30115
|
this.subscribeForActionOutput();
|
|
@@ -30154,11 +30118,17 @@ class QdSectionComponent {
|
|
|
30154
30118
|
subscribeForSearchOutputs() {
|
|
30155
30119
|
if (!this.config.search)
|
|
30156
30120
|
return;
|
|
30157
|
-
this._outputSubscriptions.push(this.searchService.searchQueryString
|
|
30158
|
-
|
|
30121
|
+
this._outputSubscriptions.push(this.searchService.searchQueryString$
|
|
30122
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30123
|
+
.subscribe(queryString => this.searchQueryStringOutput.emit(queryString)));
|
|
30124
|
+
this._outputSubscriptions.push(this.searchService.searchPostBody$
|
|
30125
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30126
|
+
.subscribe(postBody => this.searchPostBodyOutput.emit(postBody)));
|
|
30159
30127
|
}
|
|
30160
30128
|
subscribeForActionOutput() {
|
|
30161
|
-
this._outputSubscriptions.push(this.actionService.action
|
|
30129
|
+
this._outputSubscriptions.push(this.actionService.action$
|
|
30130
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30131
|
+
.subscribe((type) => this.actionOutput.emit(type || null)));
|
|
30162
30132
|
}
|
|
30163
30133
|
subscribeForFilterOutputs() {
|
|
30164
30134
|
if (!this.config.filter)
|
|
@@ -30167,12 +30137,15 @@ class QdSectionComponent {
|
|
|
30167
30137
|
this.config.filter.uid = v4();
|
|
30168
30138
|
this._outputSubscriptions.push(this.filterService
|
|
30169
30139
|
.getQueryString$(this.config.filter.uid)
|
|
30140
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30170
30141
|
.subscribe(queryString => this.filterQueryStringOutput.emit(queryString)));
|
|
30171
30142
|
this._outputSubscriptions.push(this.filterService
|
|
30172
30143
|
.getPostBody$(this.config.filter.uid)
|
|
30144
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30173
30145
|
.subscribe(postBody => this.filterPostBodyOutput.emit(postBody)));
|
|
30174
30146
|
this._outputSubscriptions.push(this.filterService
|
|
30175
30147
|
.getCurrentPostBody(this.config.filter.uid)
|
|
30148
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30176
30149
|
.subscribe(filterValue => this.filterValueChangeOutput.emit(filterValue)));
|
|
30177
30150
|
}
|
|
30178
30151
|
unsubscribeOutputSubscriptions() {
|
|
@@ -30915,7 +30888,7 @@ class QdTreeRowActionsSecondaryMenuComponent {
|
|
|
30915
30888
|
_i18ns$ = new BehaviorSubject(undefined);
|
|
30916
30889
|
_secondaryActionsConfig$ = new BehaviorSubject([]);
|
|
30917
30890
|
_viewonly$ = new BehaviorSubject(false);
|
|
30918
|
-
|
|
30891
|
+
_destroyRef = inject(DestroyRef);
|
|
30919
30892
|
actions$ = combineLatest([
|
|
30920
30893
|
this._i18ns$,
|
|
30921
30894
|
this._secondaryActionsConfig$,
|
|
@@ -30939,10 +30912,6 @@ class QdTreeRowActionsSecondaryMenuComponent {
|
|
|
30939
30912
|
this._secondaryActionsConfig$.next(this.config.secondaryActions ?? []);
|
|
30940
30913
|
this.initViewMode();
|
|
30941
30914
|
}
|
|
30942
|
-
ngOnDestroy() {
|
|
30943
|
-
this._destroy$.next();
|
|
30944
|
-
this._destroy$.complete();
|
|
30945
|
-
}
|
|
30946
30915
|
handleSecondaryAction(type, index, isHidden) {
|
|
30947
30916
|
if (isHidden)
|
|
30948
30917
|
return;
|
|
@@ -30959,7 +30928,7 @@ class QdTreeRowActionsSecondaryMenuComponent {
|
|
|
30959
30928
|
}
|
|
30960
30929
|
this.eventBroker
|
|
30961
30930
|
?.consume('operation_mode_changed')
|
|
30962
|
-
.pipe(
|
|
30931
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
30963
30932
|
.subscribe(({ payload }) => this._viewonly$.next(payload.isViewonly));
|
|
30964
30933
|
}
|
|
30965
30934
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdTreeRowActionsSecondaryMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -31183,6 +31152,7 @@ class QdTreeComponent {
|
|
|
31183
31152
|
responsiveRowService = inject(QdTableResponsiveRowService);
|
|
31184
31153
|
fillingWidthService = inject(QdTableFillingWidthService);
|
|
31185
31154
|
breakpointService = inject(QdBreakpointService);
|
|
31155
|
+
_destroyRef = inject(DestroyRef);
|
|
31186
31156
|
/**
|
|
31187
31157
|
* Configuration of the tree table. The generic type specifies the column definition. <br />
|
|
31188
31158
|
*
|
|
@@ -31255,9 +31225,6 @@ class QdTreeComponent {
|
|
|
31255
31225
|
hasData$;
|
|
31256
31226
|
hasEmptyStateView$;
|
|
31257
31227
|
_table$;
|
|
31258
|
-
_breakpointSubscription;
|
|
31259
|
-
_emptyStateActionServiceSubscription;
|
|
31260
|
-
_recentSecondaryActionsSubscription;
|
|
31261
31228
|
get whichColumnFillsWidth() {
|
|
31262
31229
|
return this.fillingWidthService.whichColumnFillsWidth;
|
|
31263
31230
|
}
|
|
@@ -31286,9 +31253,6 @@ class QdTreeComponent {
|
|
|
31286
31253
|
ngOnDestroy() {
|
|
31287
31254
|
this.tableStoreService.updateTableStateRecentSecondaryAction(undefined);
|
|
31288
31255
|
this.fillingWidthService.destroy();
|
|
31289
|
-
this._emptyStateActionServiceSubscription?.unsubscribe();
|
|
31290
|
-
this._breakpointSubscription?.unsubscribe();
|
|
31291
|
-
this._recentSecondaryActionsSubscription?.unsubscribe();
|
|
31292
31256
|
}
|
|
31293
31257
|
validateConfig() {
|
|
31294
31258
|
if (!this.config.i18ns) {
|
|
@@ -31310,7 +31274,10 @@ class QdTreeComponent {
|
|
|
31310
31274
|
}
|
|
31311
31275
|
initializeResponsiveRowService() {
|
|
31312
31276
|
this.responsiveRowService.config = this.config;
|
|
31313
|
-
this.
|
|
31277
|
+
this.breakpointService
|
|
31278
|
+
.getMatchingBreakpoint()
|
|
31279
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
31280
|
+
.subscribe(breakpoint => {
|
|
31314
31281
|
this.responsiveRowService.currentBreakpoint = breakpoint;
|
|
31315
31282
|
});
|
|
31316
31283
|
}
|
|
@@ -31319,7 +31286,9 @@ class QdTreeComponent {
|
|
|
31319
31286
|
}
|
|
31320
31287
|
initializeEmptyStateService() {
|
|
31321
31288
|
this.emptyStateService.i18ns = this.config.i18ns;
|
|
31322
|
-
this.
|
|
31289
|
+
this.emptyStateService.emptyStateAction$
|
|
31290
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
31291
|
+
.subscribe(() => this.emptyStateActionOutput.emit());
|
|
31323
31292
|
}
|
|
31324
31293
|
checkForChanges(changes, key) {
|
|
31325
31294
|
return (changes[key] &&
|
|
@@ -31327,8 +31296,9 @@ class QdTreeComponent {
|
|
|
31327
31296
|
JSON.stringify(changes[key].previousValue) !== JSON.stringify(changes[key].currentValue));
|
|
31328
31297
|
}
|
|
31329
31298
|
initializeSecondaryActions() {
|
|
31330
|
-
this.
|
|
31299
|
+
this.tableStoreService
|
|
31331
31300
|
.recentSecondaryAction$()
|
|
31301
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
31332
31302
|
.subscribe(recentAction => {
|
|
31333
31303
|
if (!recentAction)
|
|
31334
31304
|
return;
|
|
@@ -32311,7 +32281,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
32311
32281
|
|
|
32312
32282
|
class QdPageCommitActionExecutor {
|
|
32313
32283
|
static execute(action, values, context) {
|
|
32314
|
-
const { formGroupManager, navigationInterceptor,
|
|
32284
|
+
const { formGroupManager, navigationInterceptor, destroyRef, onAfterSnapshot, scheduleFrameworkRebuildStop } = context;
|
|
32315
32285
|
const captured = formGroupManager.createCurrentValuesSnapshot();
|
|
32316
32286
|
let result$;
|
|
32317
32287
|
navigationInterceptor.executeWithBypass(() => {
|
|
@@ -32339,7 +32309,7 @@ class QdPageCommitActionExecutor {
|
|
|
32339
32309
|
});
|
|
32340
32310
|
};
|
|
32341
32311
|
if (result$) {
|
|
32342
|
-
result$.pipe(take(1),
|
|
32312
|
+
result$.pipe(take(1), takeUntilDestroyed(destroyRef)).subscribe({
|
|
32343
32313
|
next: ok => {
|
|
32344
32314
|
if (ok)
|
|
32345
32315
|
applySuccess();
|
|
@@ -32400,6 +32370,7 @@ class QdPageCommitActionExecutor {
|
|
|
32400
32370
|
* - No structural information is stored in the snapshot, only data.
|
|
32401
32371
|
*/
|
|
32402
32372
|
class QdFormGroupManagerService {
|
|
32373
|
+
_destroyRef = inject(DestroyRef);
|
|
32403
32374
|
_formGroups = new Map();
|
|
32404
32375
|
_formGroupsSnapshot = new Map();
|
|
32405
32376
|
_knownControlInstances = new Map();
|
|
@@ -32584,7 +32555,9 @@ class QdFormGroupManagerService {
|
|
|
32584
32555
|
this._frameworkRebuildSub?.unsubscribe();
|
|
32585
32556
|
const valueStreams = Array.from(this._formGroups.values()).map(fg => fg.valueChanges);
|
|
32586
32557
|
if (valueStreams.length)
|
|
32587
|
-
this._frameworkRebuildSub = merge(...valueStreams)
|
|
32558
|
+
this._frameworkRebuildSub = merge(...valueStreams)
|
|
32559
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
32560
|
+
.subscribe(() => this.adoptFrameworkRebuild());
|
|
32588
32561
|
this.adoptFrameworkRebuild();
|
|
32589
32562
|
}
|
|
32590
32563
|
/**
|
|
@@ -32823,7 +32796,7 @@ class QdPageNavigationInterceptorService {
|
|
|
32823
32796
|
router = inject(Router);
|
|
32824
32797
|
formGroupManager = inject(QdFormGroupManagerService);
|
|
32825
32798
|
confirmationDialog = inject(QdConfirmationDialogOpenerService);
|
|
32826
|
-
|
|
32799
|
+
_destroyRef = inject(DestroyRef);
|
|
32827
32800
|
_deactivate$ = new Subject();
|
|
32828
32801
|
/**
|
|
32829
32802
|
* Guards the re-dispatched navigation issued after the user confirms discard. While the dialog
|
|
@@ -32840,8 +32813,6 @@ class QdPageNavigationInterceptorService {
|
|
|
32840
32813
|
_confirmationMessage;
|
|
32841
32814
|
ngOnDestroy() {
|
|
32842
32815
|
this._confirmedTargetUrl = undefined;
|
|
32843
|
-
this._destroy$.next();
|
|
32844
|
-
this._destroy$.complete();
|
|
32845
32816
|
this._deactivate$.complete();
|
|
32846
32817
|
}
|
|
32847
32818
|
/**
|
|
@@ -32878,7 +32849,7 @@ class QdPageNavigationInterceptorService {
|
|
|
32878
32849
|
}
|
|
32879
32850
|
listenForUnsavedNavigationAttempts() {
|
|
32880
32851
|
this.router.events
|
|
32881
|
-
.pipe(filter$1((event) => event instanceof NavigationStart), filter$1(() => !this._bypassInterception), filter$1(event => this.shouldIntercept(event)), concatMap$1(event => this.checkForPendingChanges(event)), filter$1(({ hasChanges }) => hasChanges), exhaustMap(({ event }) => this.cancelNavigationAndConfirm(event)), filter$1(({ confirmed }) => confirmed), takeUntil$1(this._deactivate$),
|
|
32852
|
+
.pipe(filter$1((event) => event instanceof NavigationStart), filter$1(() => !this._bypassInterception), filter$1(event => this.shouldIntercept(event)), concatMap$1(event => this.checkForPendingChanges(event)), filter$1(({ hasChanges }) => hasChanges), exhaustMap(({ event }) => this.cancelNavigationAndConfirm(event)), filter$1(({ confirmed }) => confirmed), takeUntil$1(this._deactivate$), takeUntilDestroyed(this._destroyRef))
|
|
32882
32853
|
.subscribe(({ targetUrl }) => this.navigateToConfirmedTarget(targetUrl));
|
|
32883
32854
|
}
|
|
32884
32855
|
shouldIntercept(event) {
|
|
@@ -32978,6 +32949,7 @@ class QdPageObjectHeaderComponent {
|
|
|
32978
32949
|
resolverTriggerService = inject(QdResolverTriggerService);
|
|
32979
32950
|
injector = inject(Injector);
|
|
32980
32951
|
pageStoreService = inject(QdPageStoreService);
|
|
32952
|
+
_destroyRef = inject(DestroyRef);
|
|
32981
32953
|
_pageObjectDataSubject = new BehaviorSubject({});
|
|
32982
32954
|
_isLoadingSubject = new BehaviorSubject(false);
|
|
32983
32955
|
_customActionsSubject = new BehaviorSubject({ actions: [] });
|
|
@@ -32985,7 +32957,6 @@ class QdPageObjectHeaderComponent {
|
|
|
32985
32957
|
_metadataSub;
|
|
32986
32958
|
_pendingMetadata = {};
|
|
32987
32959
|
_metadataStreamTypeWarned = false;
|
|
32988
|
-
_destroyed$ = new Subject();
|
|
32989
32960
|
_availableContexts = 0;
|
|
32990
32961
|
pageObjectData$ = this._pageObjectDataSubject.asObservable();
|
|
32991
32962
|
isLoading$ = this._isLoadingSubject.asObservable().pipe(debounceTime(400));
|
|
@@ -33025,7 +32996,7 @@ class QdPageObjectHeaderComponent {
|
|
|
33025
32996
|
return undefined;
|
|
33026
32997
|
}
|
|
33027
32998
|
get isInspectAndViewMode$() {
|
|
33028
|
-
return this.pageStoreService.isViewonly$.pipe(
|
|
32999
|
+
return this.pageStoreService.isViewonly$.pipe(takeUntilDestroyed(this._destroyRef), map(isView => this.config.pageType === 'inspect' && isView));
|
|
33029
33000
|
}
|
|
33030
33001
|
get isCreate() {
|
|
33031
33002
|
return this.config.pageType === 'create';
|
|
@@ -33086,8 +33057,6 @@ class QdPageObjectHeaderComponent {
|
|
|
33086
33057
|
}
|
|
33087
33058
|
ngOnDestroy() {
|
|
33088
33059
|
this.pageStoreService.toggleViewonly(false);
|
|
33089
|
-
this._destroyed$.next();
|
|
33090
|
-
this._destroyed$.complete();
|
|
33091
33060
|
}
|
|
33092
33061
|
updateMetadata(metadata) {
|
|
33093
33062
|
this._pendingMetadata = { ...this._pendingMetadata, ...metadata };
|
|
@@ -33126,7 +33095,7 @@ class QdPageObjectHeaderComponent {
|
|
|
33126
33095
|
QdPageCommitActionExecutor.execute(saveAction, this.formGroupManagerService.getAllValues(), {
|
|
33127
33096
|
formGroupManager: this.formGroupManagerService,
|
|
33128
33097
|
navigationInterceptor: this.navigationInterceptor,
|
|
33129
|
-
|
|
33098
|
+
destroyRef: this._destroyRef,
|
|
33130
33099
|
onAfterSnapshot: () => {
|
|
33131
33100
|
this.formGroupManagerService.cancelPendingAsyncValidation();
|
|
33132
33101
|
this.pageStoreService.toggleViewonly(true);
|
|
@@ -33157,10 +33126,10 @@ class QdPageObjectHeaderComponent {
|
|
|
33157
33126
|
setupResolverTrigger(resolver) {
|
|
33158
33127
|
this.resolverTriggerService
|
|
33159
33128
|
.shouldTriggerResolver(resolver.config?.triggerOn ?? 'pathParamsChange')
|
|
33160
|
-
.pipe(
|
|
33129
|
+
.pipe(filter(shouldTrigger => shouldTrigger), tap(() => this._isLoadingSubject.next(true)), switchMap$1(() => resolver.resolve()), tap(objectData => {
|
|
33161
33130
|
this._pageObjectDataSubject.next({ ...objectData, ...this._pendingMetadata });
|
|
33162
33131
|
this._pendingMetadata = {};
|
|
33163
|
-
}), tap(() => this._isLoadingSubject.next(false)), tap(() => this.formGroupManagerService.updateSavedSnapshotFromCurrentValues()))
|
|
33132
|
+
}), tap(() => this._isLoadingSubject.next(false)), tap(() => this.formGroupManagerService.updateSavedSnapshotFromCurrentValues()), takeUntilDestroyed(this._destroyRef))
|
|
33164
33133
|
.subscribe();
|
|
33165
33134
|
}
|
|
33166
33135
|
initContexts() {
|
|
@@ -33177,7 +33146,7 @@ class QdPageObjectHeaderComponent {
|
|
|
33177
33146
|
selection: selection?.value ?? []
|
|
33178
33147
|
}))));
|
|
33179
33148
|
this.contexts$
|
|
33180
|
-
.pipe(
|
|
33149
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(contexts => (this._availableContexts = contexts.length)))
|
|
33181
33150
|
.subscribe();
|
|
33182
33151
|
}
|
|
33183
33152
|
updateCustomActions() {
|
|
@@ -33197,7 +33166,9 @@ class QdPageObjectHeaderComponent {
|
|
|
33197
33166
|
if (!metadata$)
|
|
33198
33167
|
return;
|
|
33199
33168
|
this.warnOnNonReplayMetadataStream(metadata$);
|
|
33200
|
-
this._metadataSub = metadata
|
|
33169
|
+
this._metadataSub = metadata$
|
|
33170
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33171
|
+
.subscribe(partial => this.updateMetadata(partial));
|
|
33201
33172
|
}
|
|
33202
33173
|
warnOnNonReplayMetadataStream(metadata$) {
|
|
33203
33174
|
if (!isDevMode() || this._metadataStreamTypeWarned)
|
|
@@ -33214,7 +33185,7 @@ class QdPageObjectHeaderComponent {
|
|
|
33214
33185
|
subscribeToViewOnlyMode() {
|
|
33215
33186
|
this._customActionsSub?.unsubscribe();
|
|
33216
33187
|
this._customActionsSub = this.pageStoreService.isViewonly$
|
|
33217
|
-
.pipe(
|
|
33188
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33218
33189
|
.subscribe(isViewonly => {
|
|
33219
33190
|
const mode = isViewonly ? 'view' : 'edit';
|
|
33220
33191
|
const config = this.config.pageTypeConfig;
|
|
@@ -33238,7 +33209,7 @@ class QdPageObjectHeaderComponent {
|
|
|
33238
33209
|
const cancelConfig = this.config.pageTypeConfig?.cancel;
|
|
33239
33210
|
this.confirmationDialogService
|
|
33240
33211
|
.showDiscardConfirmDialog(cancelConfig?.confirmationMessage, this.testId + '-cancel-confirmation')
|
|
33241
|
-
.pipe(
|
|
33212
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33242
33213
|
.subscribe(confirmed => {
|
|
33243
33214
|
if (confirmed) {
|
|
33244
33215
|
cancelConfig?.handler?.();
|
|
@@ -33449,6 +33420,7 @@ class QdPageStepperComponent extends CdkStepper {
|
|
|
33449
33420
|
router = inject(Router);
|
|
33450
33421
|
dialog = inject(QdDialogService);
|
|
33451
33422
|
pageService = inject(QdPageStoreService);
|
|
33423
|
+
_destroyRef = inject(DestroyRef);
|
|
33452
33424
|
/**
|
|
33453
33425
|
* Configuration of QdPageStepperComponent.
|
|
33454
33426
|
*
|
|
@@ -33467,7 +33439,6 @@ class QdPageStepperComponent extends CdkStepper {
|
|
|
33467
33439
|
steps = new QueryList();
|
|
33468
33440
|
selectedStepValid$;
|
|
33469
33441
|
allStepsValid$;
|
|
33470
|
-
_destroyed$ = new Subject();
|
|
33471
33442
|
isGoingToNextStep = false;
|
|
33472
33443
|
get hasPageFooter() {
|
|
33473
33444
|
return !!this.footerService;
|
|
@@ -33484,7 +33455,9 @@ class QdPageStepperComponent extends CdkStepper {
|
|
|
33484
33455
|
throw new Error('Quadrel Framework | QdPageStepper - When using <qd-page-stepper> inside <qd-page>, don\'t use the "submit" and "cancel" attributes. Instead, use the QdPageConfig.');
|
|
33485
33456
|
}
|
|
33486
33457
|
if (this.footerService) {
|
|
33487
|
-
this.selectedIndexChange
|
|
33458
|
+
this.selectedIndexChange
|
|
33459
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33460
|
+
.subscribe(() => this.updateFooterActionsVisibility());
|
|
33488
33461
|
}
|
|
33489
33462
|
this.selectedStepValid$ = this.isSelectedStepValid$();
|
|
33490
33463
|
this.allStepsValid$ = this.areAllStepsValid$();
|
|
@@ -33502,12 +33475,7 @@ class QdPageStepperComponent extends CdkStepper {
|
|
|
33502
33475
|
this.updateFooterActionsVisibility();
|
|
33503
33476
|
}
|
|
33504
33477
|
// Mark component for change detection whenever the content children query changes
|
|
33505
|
-
this.steps.changes.pipe(
|
|
33506
|
-
}
|
|
33507
|
-
ngOnDestroy() {
|
|
33508
|
-
super.ngOnDestroy();
|
|
33509
|
-
this._destroyed$.next(null);
|
|
33510
|
-
this._destroyed$.complete();
|
|
33478
|
+
this.steps.changes.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => this._stateChanged());
|
|
33511
33479
|
}
|
|
33512
33480
|
handleClickHeader(step, clickedIndex) {
|
|
33513
33481
|
if (this.selectedIndex === clickedIndex)
|
|
@@ -33572,7 +33540,7 @@ class QdPageStepperComponent extends CdkStepper {
|
|
|
33572
33540
|
dialogSize: QdDialogSize.Small,
|
|
33573
33541
|
title: { i18n: 'i18n.qd.stepper.cancel.dialog.title' }
|
|
33574
33542
|
})
|
|
33575
|
-
.closed.pipe(
|
|
33543
|
+
.closed.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33576
33544
|
.subscribe(confirmed => {
|
|
33577
33545
|
if (confirmed) {
|
|
33578
33546
|
const handler = this.pageService.getConfig()?.pageTypeConfig?.cancel?.handler ||
|
|
@@ -33680,10 +33648,10 @@ class QdPageStepperComponent extends CdkStepper {
|
|
|
33680
33648
|
}
|
|
33681
33649
|
updateFooterActionsDisabledState() {
|
|
33682
33650
|
this.isSelectedStepValid$()
|
|
33683
|
-
.pipe(
|
|
33651
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33684
33652
|
.subscribe(isValid => this.footerService.updateActions([{ actionKey: 'next', partialAction: { isDisabled: !isValid } }]));
|
|
33685
33653
|
this.areAllStepsValid$()
|
|
33686
|
-
.pipe(
|
|
33654
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
33687
33655
|
.subscribe(isValid => this.footerService.updateActions([{ actionKey: 'submit', partialAction: { isDisabled: !isValid } }]));
|
|
33688
33656
|
}
|
|
33689
33657
|
blockCdkInput(inputName) {
|
|
@@ -34265,7 +34233,7 @@ class QdPageTabsComponent {
|
|
|
34265
34233
|
pageStoreService = inject(QdPageStoreService);
|
|
34266
34234
|
routerConnector = inject(QdPageTabsRouterConnectorService);
|
|
34267
34235
|
_changeDetectorRef = inject(ChangeDetectorRef);
|
|
34268
|
-
|
|
34236
|
+
_destroyRef = inject(DestroyRef);
|
|
34269
34237
|
static _idCounter = 0;
|
|
34270
34238
|
_id = QdPageTabsComponent._idCounter++;
|
|
34271
34239
|
get hasPageFooter() {
|
|
@@ -34322,7 +34290,7 @@ class QdPageTabsComponent {
|
|
|
34322
34290
|
}
|
|
34323
34291
|
ngOnInit() {
|
|
34324
34292
|
this.linear = false;
|
|
34325
|
-
this.pageStoreService.isViewonly$.pipe(takeUntilDestroyed(this.
|
|
34293
|
+
this.pageStoreService.isViewonly$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(v => {
|
|
34326
34294
|
this._viewonly = v;
|
|
34327
34295
|
this._stateChanged();
|
|
34328
34296
|
});
|
|
@@ -34333,7 +34301,7 @@ class QdPageTabsComponent {
|
|
|
34333
34301
|
.forEach(inputName => this.blockCdkInput(inputName));
|
|
34334
34302
|
}
|
|
34335
34303
|
ngAfterContentInit() {
|
|
34336
|
-
this._tabs.changes.pipe(takeUntilDestroyed(this.
|
|
34304
|
+
this._tabs.changes.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(() => this._stateChanged());
|
|
34337
34305
|
}
|
|
34338
34306
|
ngAfterViewInit() {
|
|
34339
34307
|
setTimeout(() => {
|
|
@@ -34385,7 +34353,7 @@ class QdPageTabsComponent {
|
|
|
34385
34353
|
this.selectFirstNotDisabledTab();
|
|
34386
34354
|
}
|
|
34387
34355
|
configureBookmarkableTabs() {
|
|
34388
|
-
this.routerConnector.connectTabsWithRouter(this).pipe(takeUntilDestroyed(this.
|
|
34356
|
+
this.routerConnector.connectTabsWithRouter(this).pipe(takeUntilDestroyed(this._destroyRef)).subscribe();
|
|
34389
34357
|
}
|
|
34390
34358
|
isTabSelectable(index) {
|
|
34391
34359
|
const tab = this._tabs.get(index);
|
|
@@ -34435,15 +34403,11 @@ class QdPageSubmitActionService {
|
|
|
34435
34403
|
formGroupManagerService = inject(QdFormGroupManagerService);
|
|
34436
34404
|
navigationInterceptor = inject(QdPageNavigationInterceptorService);
|
|
34437
34405
|
injector = inject(Injector);
|
|
34406
|
+
_destroyRef = inject(DestroyRef);
|
|
34438
34407
|
_labelI18n = 'i18n.qd.page.footer.submit';
|
|
34439
34408
|
_submitAction;
|
|
34440
34409
|
_isVisible = true;
|
|
34441
|
-
_destroyed$ = new Subject();
|
|
34442
34410
|
_cancelTrackFormValidity$ = new Subject();
|
|
34443
|
-
ngOnDestroy() {
|
|
34444
|
-
this._destroyed$.next(null);
|
|
34445
|
-
this._destroyed$.complete();
|
|
34446
|
-
}
|
|
34447
34411
|
setSubmitActionForInspect(pageTypeConfig, isVisible) {
|
|
34448
34412
|
if (!pageTypeConfig?.submit)
|
|
34449
34413
|
return;
|
|
@@ -34478,7 +34442,7 @@ class QdPageSubmitActionService {
|
|
|
34478
34442
|
QdPageCommitActionExecutor.execute(action, values, {
|
|
34479
34443
|
formGroupManager: this.formGroupManagerService,
|
|
34480
34444
|
navigationInterceptor: this.navigationInterceptor,
|
|
34481
|
-
|
|
34445
|
+
destroyRef: this._destroyRef,
|
|
34482
34446
|
scheduleFrameworkRebuildStop: () => afterNextRender(() => this.formGroupManagerService.stopAdoptingFrameworkRebuild(), { injector: this.injector })
|
|
34483
34447
|
});
|
|
34484
34448
|
}
|
|
@@ -34486,7 +34450,7 @@ class QdPageSubmitActionService {
|
|
|
34486
34450
|
this._cancelTrackFormValidity$.next();
|
|
34487
34451
|
this.formGroupManagerService
|
|
34488
34452
|
.$areFormGroupsValid()
|
|
34489
|
-
.pipe(takeUntil(this._cancelTrackFormValidity$),
|
|
34453
|
+
.pipe(takeUntil(this._cancelTrackFormValidity$), takeUntilDestroyed(this._destroyRef), distinctUntilChanged())
|
|
34490
34454
|
.subscribe(isValid => this.updateSubmitButtonState(isValid));
|
|
34491
34455
|
}
|
|
34492
34456
|
updateSubmitButtonState(isValid) {
|
|
@@ -34974,6 +34938,7 @@ class QdPageComponent {
|
|
|
34974
34938
|
navigationInterceptor = inject(QdPageNavigationInterceptorService);
|
|
34975
34939
|
injector = inject(Injector);
|
|
34976
34940
|
confirmationDialogService = inject(QdConfirmationDialogOpenerService);
|
|
34941
|
+
_destroyRef = inject(DestroyRef);
|
|
34977
34942
|
/**
|
|
34978
34943
|
* This property defines the configuration for the QdPage component, including the page type,
|
|
34979
34944
|
* title, and specific configurations for each type of page.
|
|
@@ -34998,7 +34963,6 @@ class QdPageComponent {
|
|
|
34998
34963
|
isFooterVisible;
|
|
34999
34964
|
projectionGuardMessage = 'Quadrel Framework | QdPage - This content is not supported. Please use the [qdSectionAdapter] directive for custom content projection.';
|
|
35000
34965
|
_isInitialized = false;
|
|
35001
|
-
_destroyed$ = new Subject();
|
|
35002
34966
|
_cancelSubmitValidation$ = new Subject();
|
|
35003
34967
|
get isControlPanelVisible() {
|
|
35004
34968
|
return this.controlPanel !== undefined && this.controlPanel.config?.isHidden !== true;
|
|
@@ -35014,7 +34978,7 @@ class QdPageComponent {
|
|
|
35014
34978
|
}
|
|
35015
34979
|
constructor() {
|
|
35016
34980
|
this.footerHasContent$ = this.footerService.footerHasContent$;
|
|
35017
|
-
this.footerHasContent$.pipe(
|
|
34981
|
+
this.footerHasContent$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(isVisible => {
|
|
35018
34982
|
this.isFooterVisible = isVisible;
|
|
35019
34983
|
this.bottomOffset$?.next(isVisible ? SAFE_BOTTOM_OFFSET_PX : 0);
|
|
35020
34984
|
});
|
|
@@ -35047,7 +35011,7 @@ class QdPageComponent {
|
|
|
35047
35011
|
this.initSaveDraftFooterAction(this.config.pageTypeConfig.saveDraft);
|
|
35048
35012
|
if (this.config.pageType === 'inspect')
|
|
35049
35013
|
this.pageStoreService.isViewonly$
|
|
35050
|
-
.pipe(
|
|
35014
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
35051
35015
|
.subscribe(isViewonly => this.updateInspectPageOperationMode(this.config.pageTypeConfig, isViewonly ? 'view' : 'edit'));
|
|
35052
35016
|
this.setupPageDialogCloseContract();
|
|
35053
35017
|
this._isInitialized = true;
|
|
@@ -35055,8 +35019,6 @@ class QdPageComponent {
|
|
|
35055
35019
|
ngOnDestroy() {
|
|
35056
35020
|
this.dialogRef && this.dialog.clearPageDialogCanClose(this.dialogRef);
|
|
35057
35021
|
this.bottomOffset$?.next(0);
|
|
35058
|
-
this._destroyed$.next();
|
|
35059
|
-
this._destroyed$.complete();
|
|
35060
35022
|
}
|
|
35061
35023
|
discardUnsavedChanges() {
|
|
35062
35024
|
this.formGroupManagerService.restoreFormGroupsFromSnapshot();
|
|
@@ -35089,7 +35051,7 @@ class QdPageComponent {
|
|
|
35089
35051
|
handleCancelActionWithFormChanges() {
|
|
35090
35052
|
this.formGroupManagerService
|
|
35091
35053
|
.$hasValuesChanged()
|
|
35092
|
-
.pipe(
|
|
35054
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
35093
35055
|
.subscribe(hasChanged => {
|
|
35094
35056
|
this.footerService.updateActions([
|
|
35095
35057
|
{
|
|
@@ -35143,7 +35105,7 @@ class QdPageComponent {
|
|
|
35143
35105
|
QdPageCommitActionExecutor.execute(action, values, {
|
|
35144
35106
|
formGroupManager: this.formGroupManagerService,
|
|
35145
35107
|
navigationInterceptor: this.navigationInterceptor,
|
|
35146
|
-
|
|
35108
|
+
destroyRef: this._destroyRef,
|
|
35147
35109
|
scheduleFrameworkRebuildStop: () => afterNextRender(() => this.formGroupManagerService.stopAdoptingFrameworkRebuild(), {
|
|
35148
35110
|
injector: this.injector
|
|
35149
35111
|
})
|
|
@@ -35154,7 +35116,7 @@ class QdPageComponent {
|
|
|
35154
35116
|
const cancelConfig = this.config.pageTypeConfig?.cancel;
|
|
35155
35117
|
this.confirmationDialogService
|
|
35156
35118
|
.showDiscardConfirmDialog(cancelConfig?.confirmationMessage, this.testId + '-cancel-confirmation')
|
|
35157
|
-
.pipe(filter$1(result => result),
|
|
35119
|
+
.pipe(filter$1(result => result), takeUntilDestroyed(this._destroyRef))
|
|
35158
35120
|
.subscribe(() => {
|
|
35159
35121
|
this.formGroupManagerService.restoreFormGroupsFromSnapshot();
|
|
35160
35122
|
cancelConfig?.handler?.();
|
|
@@ -35164,7 +35126,7 @@ class QdPageComponent {
|
|
|
35164
35126
|
this._cancelSubmitValidation$.next();
|
|
35165
35127
|
this.formGroupManagerService
|
|
35166
35128
|
.$areFormGroupsValid()
|
|
35167
|
-
.pipe(takeUntil(this._cancelSubmitValidation$),
|
|
35129
|
+
.pipe(takeUntil(this._cancelSubmitValidation$), takeUntilDestroyed(this._destroyRef), tap(isValid => {
|
|
35168
35130
|
const submitDisabledInfoText = this.config.pageTypeConfig?.submit?.disabledInfo;
|
|
35169
35131
|
this.footerService.updateActions([
|
|
35170
35132
|
{
|
|
@@ -35642,6 +35604,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
35642
35604
|
*/
|
|
35643
35605
|
class QdPanelSectionComponent {
|
|
35644
35606
|
actionService = inject(QdPanelSectionActionService);
|
|
35607
|
+
_destroyRef = inject(DestroyRef);
|
|
35645
35608
|
/**
|
|
35646
35609
|
* The configuration of the panel section.
|
|
35647
35610
|
*/
|
|
@@ -35656,13 +35619,9 @@ class QdPanelSectionComponent {
|
|
|
35656
35619
|
statusPairsList;
|
|
35657
35620
|
tableList;
|
|
35658
35621
|
paragraphList;
|
|
35659
|
-
_actionOutputSubscription;
|
|
35660
35622
|
ngOnInit() {
|
|
35661
35623
|
this.subscribeForActionOutput();
|
|
35662
35624
|
}
|
|
35663
|
-
ngOnDestroy() {
|
|
35664
|
-
this._actionOutputSubscription.unsubscribe();
|
|
35665
|
-
}
|
|
35666
35625
|
hasActions() {
|
|
35667
35626
|
if (!this.config.actions)
|
|
35668
35627
|
return false;
|
|
@@ -35675,7 +35634,7 @@ class QdPanelSectionComponent {
|
|
|
35675
35634
|
this.paragraphList.length > 0);
|
|
35676
35635
|
}
|
|
35677
35636
|
subscribeForActionOutput() {
|
|
35678
|
-
this.
|
|
35637
|
+
this.actionService.action$.pipe(takeUntilDestroyed(this._destroyRef)).subscribe((type) => {
|
|
35679
35638
|
this.actionOutput.emit(type);
|
|
35680
35639
|
});
|
|
35681
35640
|
}
|
|
@@ -36177,7 +36136,7 @@ class QdShellServiceNavigationComponent {
|
|
|
36177
36136
|
return this.config.pamsAppId;
|
|
36178
36137
|
}
|
|
36179
36138
|
_config;
|
|
36180
|
-
|
|
36139
|
+
_destroyRef = inject(DestroyRef);
|
|
36181
36140
|
_attributesHaveBeenSet$ = new ReplaySubject(1);
|
|
36182
36141
|
localeService = inject(QdLocaleService);
|
|
36183
36142
|
ngOnInit() {
|
|
@@ -36199,7 +36158,7 @@ class QdShellServiceNavigationComponent {
|
|
|
36199
36158
|
setLanguageFromUrlAfterNavigation() {
|
|
36200
36159
|
this.languageFromUrlService
|
|
36201
36160
|
.getLanguageFromUrl()
|
|
36202
|
-
.pipe(delayWhen(() => this._attributesHaveBeenSet$), filter(languageFromUrl => this.languageList.includes(languageFromUrl)),
|
|
36161
|
+
.pipe(delayWhen(() => this._attributesHaveBeenSet$), filter(languageFromUrl => this.languageList.includes(languageFromUrl)), takeUntilDestroyed(this._destroyRef))
|
|
36203
36162
|
.subscribe(languageFromUrl => {
|
|
36204
36163
|
this.serviceNavigationService.config.defaultLanguage = languageFromUrl;
|
|
36205
36164
|
this.translateService.setDefaultLang(languageFromUrl);
|
|
@@ -36218,9 +36177,6 @@ class QdShellServiceNavigationComponent {
|
|
|
36218
36177
|
this.passConfig(changes['config'].currentValue);
|
|
36219
36178
|
}
|
|
36220
36179
|
}
|
|
36221
|
-
ngOnDestroy() {
|
|
36222
|
-
this._destroyed$.complete();
|
|
36223
|
-
}
|
|
36224
36180
|
handleLanguageChange($event) {
|
|
36225
36181
|
this.localeService.setServiceNavigationLanguage($event.detail);
|
|
36226
36182
|
this.useLanguage($event.detail);
|
|
@@ -36240,7 +36196,7 @@ class QdShellServiceNavigationComponent {
|
|
|
36240
36196
|
setAttributesForServiceNavigation() {
|
|
36241
36197
|
this.serviceNavigationService
|
|
36242
36198
|
.getMappedAttributes$()
|
|
36243
|
-
.pipe(
|
|
36199
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(attributes => {
|
|
36244
36200
|
if (!attributes)
|
|
36245
36201
|
return;
|
|
36246
36202
|
Object.keys(attributes).forEach(attribute => {
|
|
@@ -36488,6 +36444,7 @@ class QdShellHeaderComponent {
|
|
|
36488
36444
|
shellLeftService = inject(QdShellLeftService);
|
|
36489
36445
|
shellRightService = inject(QdShellRightService);
|
|
36490
36446
|
breakpointService = inject(QdBreakpointService);
|
|
36447
|
+
_destroyRef = inject(DestroyRef);
|
|
36491
36448
|
/**
|
|
36492
36449
|
* @description The configuration of the shell.
|
|
36493
36450
|
*/
|
|
@@ -36538,8 +36495,6 @@ class QdShellHeaderComponent {
|
|
|
36538
36495
|
_hub = inject(QdRouterQueryParamHubService);
|
|
36539
36496
|
_restoresAddress = false;
|
|
36540
36497
|
_routeParams;
|
|
36541
|
-
_routeParamsSubscription;
|
|
36542
|
-
_breakpointSubscription;
|
|
36543
36498
|
constructor() {
|
|
36544
36499
|
const navigationService = this.navigationService;
|
|
36545
36500
|
const shellLeftService = this.shellLeftService;
|
|
@@ -36550,10 +36505,14 @@ class QdShellHeaderComponent {
|
|
|
36550
36505
|
previousHref = previousHref(routeComponentInstance);
|
|
36551
36506
|
return isObservable(previousHref) ? previousHref.pipe(take(1)) : of(previousHref);
|
|
36552
36507
|
}), tap(previousHref => (this._previousHref = previousHref)), map(previousHref => previousHref !== undefined));
|
|
36553
|
-
|
|
36508
|
+
navigationService
|
|
36554
36509
|
.getRouteParams$()
|
|
36510
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
36555
36511
|
.subscribe(routeParams => (this._routeParams = routeParams));
|
|
36556
|
-
this.
|
|
36512
|
+
this.breakpointService
|
|
36513
|
+
.getMatchingBreakpoint()
|
|
36514
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
36515
|
+
.subscribe(breakpoint => {
|
|
36557
36516
|
this.isServiceNavigationOpened = breakpoint !== 'xs';
|
|
36558
36517
|
});
|
|
36559
36518
|
this.logoIconDisplayed$ = this.backLinkDisplayed$.pipe(map(backLinkDisplayed => !backLinkDisplayed));
|
|
@@ -36617,9 +36576,6 @@ class QdShellHeaderComponent {
|
|
|
36617
36576
|
toggleServiceNavigation() {
|
|
36618
36577
|
this.isServiceNavigationOpened = !this.isServiceNavigationOpened;
|
|
36619
36578
|
}
|
|
36620
|
-
ngOnDestroy() {
|
|
36621
|
-
this._routeParamsSubscription.unsubscribe();
|
|
36622
|
-
}
|
|
36623
36579
|
async = async;
|
|
36624
36580
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdShellHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
36625
36581
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: QdShellHeaderComponent, isStandalone: false, selector: "[qd-shell-header]", inputs: { config: "config", isMinimized: "isMinimized", isCommentsUsed: "isCommentsUsed", hasComments: "hasComments" }, outputs: { menuIconChange: "menuIconChange" }, host: { properties: { "class.minimized": "this.minimized", "class.sticky": "this.sticky", "class.expanded": "this.expanded" }, classAttribute: "qd-shell-header" }, ngImport: i0, template: "<qd-shell-header-banner cdkDrag cdkDragLockAxis=\"x\" cdkDragBoundary=\"header\"></qd-shell-header-banner>\n\n@if (hasNavigation$ | async) {\n<qd-icon\n [icon]=\"(isNavigationPinned$ | async) ? 'timesLarge' : 'menu'\"\n class=\"toggle-navigation\"\n data-test-id=\"navigation-toggle\"\n (click)=\"togglePinnedNavigation()\"\n></qd-icon>\n} @if (backLinkDisplayed$ | async) {\n<button class=\"back-link\" (click)=\"handleBackClick()\" tabindex=\"0\">\n <qd-icon class=\"back-link-icon\" icon=\"arrowLeft\"></qd-icon>\n</button>\n} @if (logoIconDisplayed$ | async) {\n<qd-icon class=\"logo-icon\" [icon]=\"isMinimized ? 'coatCh' : 'logo'\"></qd-icon>\n} @if (config?.illustration) {\n<span class=\"illustration\" [class.minimized]=\"isMinimized\">\n <img [src]=\"config.illustration.url\" />\n</span>\n} @if (config.title) {\n<span class=\"title\">\n {{ config.title.i18n | translate }}\n</span>\n} @if (config.hasSearch) {\n<qd-shell-header-search></qd-shell-header-search>\n} @if (config.toolbar) {\n<qd-shell-toolbar [config]=\"config.toolbar\"></qd-shell-toolbar>\n} @if (!config.serviceNavigation?.isDisabled && config.serviceNavigation) {\n<qd-icon\n [icon]=\"isServiceNavigationOpened ? 'timesLarge' : 'menu'\"\n data-test-id=\"service-navigation-toggle\"\n [ngClass]=\"{\n 'toggle-service-navigation': true,\n expanded: true\n }\"\n (click)=\"toggleServiceNavigation()\"\n></qd-icon>\n} @if (!config.serviceNavigation?.isDisabled && config.serviceNavigation) {\n<qd-shell-service-navigation\n [config]=\"config.serviceNavigation\"\n [ngClass]=\"{ expanded: !isServiceNavigationOpened }\"\n></qd-shell-service-navigation>\n} @if (isCommentsUsed) {\n<qd-icon\n icon=\"chat\"\n data-test-id=\"comments-toggle\"\n [ngClass]=\"{\n 'toggle-comments': true,\n 'has-comments': hasComments,\n 'is-opened': isCommentsOpened$ | async\n }\"\n (click)=\"toggleComments()\"\n></qd-icon>\n} @if (hasNotificationsToggle$ | async) {\n<qd-icon\n icon=\"notification\"\n data-test-id=\"notification-toggle\"\n [ngClass]=\"{\n 'toggle-notification': true,\n 'has-notifications': hasNotifications$ | async,\n 'is-opened': isNotificationsOpened$ | async\n }\"\n (click)=\"toggleNotifications()\"\n></qd-icon>\n}\n", styles: [":host{display:flex;flex-wrap:wrap;align-content:center;align-items:center;align-self:start;justify-content:space-between;padding:.5rem 1rem .5rem 0;border-bottom:.3125rem solid rgb(220,0,24);background-color:#fff;grid-area:header}:host.sticky{position:sticky;z-index:998;top:0}@media(max-width:599.98px){:host{height:3.75rem;align-content:flex-start}:host.expanded{height:auto}}@media(min-width:960px){:host{height:5.9375rem;padding:0 .75rem 0 0}:host.minimized{height:4.0625rem}}:host .toggle-navigation{padding:1.9375rem .625rem 1.9375rem .8125rem;margin-right:0;cursor:pointer;font-size:1.5rem}@media(min-width:960px){:host .toggle-navigation{border-right:.0625rem solid rgb(213,213,213)}}:host.minimized .toggle-navigation{padding:1rem .625rem 1rem .8125rem}@media(min-width:960px){:host .logo-icon{border-right:.0625rem solid rgb(213,213,213)}}:host .logo-icon.qd-icon-logo{padding-right:1.5rem;margin:1rem 1.5rem 1rem 0}@media(min-width:960px){:host .logo-icon.qd-icon-logo{padding:.9375rem .8125rem;margin-right:1.5rem}}:host .logo-icon.qd-icon-logo svg{overflow:visible}:host .logo-icon.qd-icon-ch-logo{margin-left:1rem;font-size:2rem}@media(min-width:960px){:host .logo-icon.qd-icon-ch-logo{padding:.75rem .8125rem;margin-right:1.5rem;margin-left:0}}:host .logo-icon:not(.qd-icon-logo) svg{display:none}:host .back-link{padding:0;border-right:.0625rem solid rgb(213,213,213);background-color:transparent;color:#979797;font-size:1.625rem}@media(min-width:960px){:host .back-link{padding:.875rem .8125rem;margin-right:1.5rem}}:host .back-link-icon{width:2rem;opacity:.8}:host .back-link:hover{color:#757575;opacity:1}:host .back-link:hover .back-link-icon{opacity:1}:host .illustration{width:4rem;height:4rem;margin-right:.625rem}:host .illustration img{max-width:100%}:host .illustration.minimized{width:2rem;height:2rem;margin-right:.3125rem}:host .title{overflow:hidden;flex-grow:1;font-size:1.25rem;font-weight:500;text-align:center;text-overflow:ellipsis;white-space:nowrap}@media(min-width:960px){:host .title{text-align:start}}:host .toggle-notification,:host .toggle-comments,:host .toggle-service-navigation{position:relative;margin-left:.625rem;cursor:pointer;font-size:1.25rem}:host .toggle-notification.has-notifications:after,:host .toggle-notification.has-comments:after,:host .toggle-comments.has-notifications:after,:host .toggle-comments.has-comments:after,:host .toggle-service-navigation.has-notifications:after,:host .toggle-service-navigation.has-comments:after{position:absolute;top:.125rem;right:0;display:inline-block;width:.5625rem;height:.5625rem;border:rgb(255,255,255) .125rem solid;border-radius:100%;background-color:red;content:\"\"}:host .toggle-notification.is-opened:before,:host .toggle-comments.is-opened:before,:host .toggle-service-navigation.is-opened:before{position:absolute;z-index:-10;display:block;width:2rem;height:2rem;border-radius:50%;background:#e5e5e5;content:\"\";transform:translate(-.4375rem,-.3125rem)}:host .toggle-notification.expanded,:host .toggle-comments.expanded,:host .toggle-service-navigation.expanded{visibility:collapse}@media(max-width:599.98px){:host .toggle-notification.expanded,:host .toggle-comments.expanded,:host .toggle-service-navigation.expanded{visibility:visible}}\n"], dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "component", type: QdIconComponent, selector: "qd-icon", inputs: ["icon", "status"] }, { kind: "component", type: QdShellServiceNavigationComponent, selector: "qd-shell-service-navigation", inputs: ["config"] }, { kind: "component", type: QdShellHeaderBannerComponent, selector: "qd-shell-header-banner" }, { kind: "component", type: QdShellHeaderSearchComponent, selector: "qd-shell-header-search" }, { kind: "component", type: QdShellToolbarComponent, selector: "qd-shell-toolbar", inputs: ["config"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }] });
|
|
@@ -36713,12 +36669,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
36713
36669
|
class QdShellNotificationComponent {
|
|
36714
36670
|
notificationService = inject(QdNotificationsService);
|
|
36715
36671
|
translateService = inject(TranslateService, { optional: true });
|
|
36672
|
+
_destroyRef = inject(DestroyRef);
|
|
36716
36673
|
/**
|
|
36717
36674
|
* Configuration of a notification.
|
|
36718
36675
|
*/
|
|
36719
36676
|
notification;
|
|
36720
36677
|
displayedDate;
|
|
36721
|
-
_destroyed$ = new Subject();
|
|
36722
36678
|
_effectiveState = 'critical';
|
|
36723
36679
|
get typeClassName() {
|
|
36724
36680
|
return `qd-notification qd-notification-${this.getState()}`;
|
|
@@ -36727,7 +36683,9 @@ class QdShellNotificationComponent {
|
|
|
36727
36683
|
return !this.notification?.disableClose;
|
|
36728
36684
|
}
|
|
36729
36685
|
constructor() {
|
|
36730
|
-
this.translateService?.onLangChange
|
|
36686
|
+
this.translateService?.onLangChange
|
|
36687
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
36688
|
+
.subscribe((event) => {
|
|
36731
36689
|
this.setDisplayedDate(event.lang);
|
|
36732
36690
|
});
|
|
36733
36691
|
}
|
|
@@ -36755,10 +36713,6 @@ class QdShellNotificationComponent {
|
|
|
36755
36713
|
isToday(date) {
|
|
36756
36714
|
return new Date(date).setHours(0, 0, 0, 0) === new Date().setHours(0, 0, 0, 0);
|
|
36757
36715
|
}
|
|
36758
|
-
ngOnDestroy() {
|
|
36759
|
-
this._destroyed$.next();
|
|
36760
|
-
this._destroyed$.complete();
|
|
36761
|
-
}
|
|
36762
36716
|
getState() {
|
|
36763
36717
|
return this._effectiveState;
|
|
36764
36718
|
}
|
|
@@ -36829,6 +36783,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
36829
36783
|
class QdShellRightComponent {
|
|
36830
36784
|
headerMinimizationService = inject(QdShellHeaderMinimizationService);
|
|
36831
36785
|
navigationService = inject(QdNavigationService);
|
|
36786
|
+
_destroyRef = inject(DestroyRef);
|
|
36832
36787
|
config;
|
|
36833
36788
|
get headerMinimized() {
|
|
36834
36789
|
return this.isHeaderMinimized;
|
|
@@ -36838,25 +36793,20 @@ class QdShellRightComponent {
|
|
|
36838
36793
|
}
|
|
36839
36794
|
isHeaderMinimized;
|
|
36840
36795
|
isHome;
|
|
36841
|
-
_destroyed$ = new Subject();
|
|
36842
36796
|
ngOnInit() {
|
|
36843
36797
|
this.headerMinimizationService
|
|
36844
36798
|
.isHeaderMinimized$()
|
|
36845
|
-
.pipe(
|
|
36799
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
36846
36800
|
.subscribe(isHeaderMinimized => {
|
|
36847
36801
|
this.isHeaderMinimized = isHeaderMinimized;
|
|
36848
36802
|
});
|
|
36849
36803
|
this.navigationService
|
|
36850
36804
|
.isHome$()
|
|
36851
|
-
.pipe(
|
|
36805
|
+
.pipe(takeUntilDestroyed(this._destroyRef))
|
|
36852
36806
|
.subscribe(isHome => {
|
|
36853
36807
|
this.isHome = isHome;
|
|
36854
36808
|
});
|
|
36855
36809
|
}
|
|
36856
|
-
ngOnDestroy() {
|
|
36857
|
-
this._destroyed$.next();
|
|
36858
|
-
this._destroyed$.complete();
|
|
36859
|
-
}
|
|
36860
36810
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdShellRightComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
36861
36811
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.17", type: QdShellRightComponent, isStandalone: false, selector: "[qd-shell-right]", inputs: { config: "config" }, host: { properties: { "class.header-minimized": "this.headerMinimized", "class.has-footer": "this.hasFooter" } }, ngImport: i0, template: "<div class=\"shell-right\">\n <qd-shell-right-toolbar [config]=\"config\"></qd-shell-right-toolbar>\n <div class=\"shell-right-content\">\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [":host{position:relative;height:100%}:host .shell-right{position:fixed;z-index:1500;display:flex;overflow:auto;width:18.75rem;height:calc(100% - 5.9375rem);flex-direction:column;border-left:.0625rem solid rgb(213,213,213);background:#fff;transform:translate(-100%)}:host .shell-right-content{padding:1rem}:host:not(.header-minimized).has-footer .shell-right{height:calc(100% - 8.4375rem)}:host.header-minimized:not(.has-footer) .shell-right{height:calc(100% - 4.0625rem)}:host.header-minimized.has-footer .shell-right{height:calc(100% - 6.5625rem)}\n"], dependencies: [{ kind: "component", type: QdShellRightToolbarComponent, selector: "qd-shell-right-toolbar", inputs: ["config"] }] });
|
|
36862
36812
|
}
|
|
@@ -37162,7 +37112,7 @@ class QdShellComponent {
|
|
|
37162
37112
|
isMinimized$;
|
|
37163
37113
|
isHome$;
|
|
37164
37114
|
_config = DEFAULT_SHELL_CONFIG;
|
|
37165
|
-
|
|
37115
|
+
_destroyRef = inject(DestroyRef);
|
|
37166
37116
|
get isFaded$() {
|
|
37167
37117
|
return combineLatest([
|
|
37168
37118
|
this.isNavigationRolledOver$,
|
|
@@ -37193,16 +37143,13 @@ class QdShellComponent {
|
|
|
37193
37143
|
}
|
|
37194
37144
|
closeShellRightIfCommentsDisappear() {
|
|
37195
37145
|
// e.g. if comments where opened on detail page but are not shown on overview page, close after navigation
|
|
37196
|
-
this.commentsComponent.changes.pipe(
|
|
37146
|
+
this.commentsComponent.changes.pipe(takeUntilDestroyed(this._destroyRef)).subscribe(async (commentsComponent) => {
|
|
37197
37147
|
const shellRightOpen = await firstValueFrom(this.shellRightService.open$);
|
|
37198
37148
|
if (commentsComponent.length === 0 && this.shellHeaderComponent.isCommentsDisplayed && shellRightOpen) {
|
|
37199
37149
|
this.shellRightService.toggleOpen();
|
|
37200
37150
|
}
|
|
37201
37151
|
});
|
|
37202
37152
|
}
|
|
37203
|
-
ngOnDestroy() {
|
|
37204
|
-
this._destroy$.complete();
|
|
37205
|
-
}
|
|
37206
37153
|
handleRouterOutletActivation(routeComponentInstance) {
|
|
37207
37154
|
this.navigationService.updateRouteComponentInstance(routeComponentInstance);
|
|
37208
37155
|
}
|
|
@@ -37213,10 +37160,10 @@ class QdShellComponent {
|
|
|
37213
37160
|
}
|
|
37214
37161
|
subscribeToSearchService() {
|
|
37215
37162
|
this.searchService.searchQueryString$
|
|
37216
|
-
.pipe(
|
|
37163
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(queryString => this.searchQueryStringOutput.emit(queryString)))
|
|
37217
37164
|
.subscribe();
|
|
37218
37165
|
this.searchService.searchPostBody$
|
|
37219
|
-
.pipe(
|
|
37166
|
+
.pipe(takeUntilDestroyed(this._destroyRef), tap(postBody => this.searchPostBodyOutput.emit(postBody)))
|
|
37220
37167
|
.subscribe();
|
|
37221
37168
|
}
|
|
37222
37169
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdShellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -37751,7 +37698,6 @@ class QdPageStepComponent extends CdkStep {
|
|
|
37751
37698
|
* The stepper only moves on to the next step when this form is valid. Optional steps skip this check.
|
|
37752
37699
|
*/
|
|
37753
37700
|
stepControl;
|
|
37754
|
-
_destroyed$ = new Subject();
|
|
37755
37701
|
constructor() {
|
|
37756
37702
|
const stepper = inject(QdPageStepperComponent);
|
|
37757
37703
|
const stepperOptions = inject(STEPPER_GLOBAL_OPTIONS, { optional: true });
|
|
@@ -37768,9 +37714,6 @@ class QdPageStepComponent extends CdkStep {
|
|
|
37768
37714
|
.filter(input => changes[input])
|
|
37769
37715
|
.forEach(input => this.blockCdkInput(input));
|
|
37770
37716
|
}
|
|
37771
|
-
ngOnDestroy() {
|
|
37772
|
-
this._destroyed$.complete();
|
|
37773
|
-
}
|
|
37774
37717
|
blockCdkInput(inputName) {
|
|
37775
37718
|
throw new Error(`Quadrel Framework | QdPageStep - The use of the "${inputName}" attribute is not permitted. Please use QdPageStepConfig instead.`);
|
|
37776
37719
|
}
|
|
@@ -38128,6 +38071,7 @@ class QdQuickEditComponent {
|
|
|
38128
38071
|
changeDetectorRef = inject(ChangeDetectorRef);
|
|
38129
38072
|
controlContainer = inject(ControlContainer, { optional: true, self: true });
|
|
38130
38073
|
confirmationDialogService = inject(QdConfirmationDialogOpenerService);
|
|
38074
|
+
_destroyRef = inject(DestroyRef);
|
|
38131
38075
|
/**
|
|
38132
38076
|
* Configuration of the QuickEdit. The generic type names the columns.
|
|
38133
38077
|
*
|
|
@@ -38196,7 +38140,6 @@ class QdQuickEditComponent {
|
|
|
38196
38140
|
viewonly$ = of(false);
|
|
38197
38141
|
actions$;
|
|
38198
38142
|
hasVisibleActions$;
|
|
38199
|
-
_destroyed$ = new Subject();
|
|
38200
38143
|
_pageViewonly$;
|
|
38201
38144
|
get control() {
|
|
38202
38145
|
return (this.controlContainer?.control ?? this.quickEditFormGroup.get('rows'));
|
|
@@ -38248,10 +38191,6 @@ class QdQuickEditComponent {
|
|
|
38248
38191
|
this.initActionsStream();
|
|
38249
38192
|
}
|
|
38250
38193
|
}
|
|
38251
|
-
ngOnDestroy() {
|
|
38252
|
-
this._destroyed$.next();
|
|
38253
|
-
this._destroyed$.complete();
|
|
38254
|
-
}
|
|
38255
38194
|
/**
|
|
38256
38195
|
* Whether a secondary action is disabled for one row.
|
|
38257
38196
|
* Resolves the `isDisabled` of the action, which may be a flag or a function of the row.
|
|
@@ -38352,7 +38291,7 @@ class QdQuickEditComponent {
|
|
|
38352
38291
|
initCreating() {
|
|
38353
38292
|
if (this.sectionActionService)
|
|
38354
38293
|
this.sectionActionService.action$
|
|
38355
|
-
.pipe(
|
|
38294
|
+
.pipe(takeUntilDestroyed(this._destroyRef), filter$1(type => type === 'addNew'))
|
|
38356
38295
|
.subscribe(() => this.createRow());
|
|
38357
38296
|
}
|
|
38358
38297
|
createFormGroupRow(row) {
|
|
@@ -38398,7 +38337,7 @@ class QdQuickEditComponent {
|
|
|
38398
38337
|
initManualChangeDetectionForControlReset() {
|
|
38399
38338
|
if (!this.isFormControl)
|
|
38400
38339
|
return;
|
|
38401
|
-
this.controlContainer.control.valueChanges.pipe(
|
|
38340
|
+
this.controlContainer.control.valueChanges.pipe(takeUntilDestroyed(this._destroyRef), tap(() => this.changeDetectorRef.detectChanges())).subscribe();
|
|
38402
38341
|
}
|
|
38403
38342
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.17", ngImport: i0, type: QdQuickEditComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
38404
38343
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.17", type: QdQuickEditComponent, isStandalone: false, selector: "qd-quick-edit", inputs: { config: "config", data: "data", testId: ["data-test-id", "testId"] }, outputs: { formGroupChange: "formGroupChange", addNewClicked: "addNewClicked" }, viewQueries: [{ propertyName: "customForDirective", first: true, predicate: QdCustomForDirective, descendants: true }, { propertyName: "focusables", predicate: QdFocusableDirective, descendants: true }], usesOnChanges: true, ngImport: i0, template: "@if (showStandaloneCreate) {\n<div class=\"editable-actions\">\n <button qdButton qdButtonGhost icon=\"plus\" (click)=\"createRow()\" [data-test-id]=\"testId + '-button-add-new'\">\n {{ config.standaloneCreateLabel?.i18n ?? \"i18n.qd.quick.edit.createButtonLabel\" | translate }}\n </button>\n</div>\n}\n\n<div class=\"table\" [formGroup]=\"control\">\n @if (!config.canAdd || templateData.length > 0 || config.emptyStateView) {\n <div class=\"table-header\">\n <div class=\"table-row\">\n @for (header of visibleColumns; track header) {\n <div class=\"table-cell\">\n {{ header?.i18n | translate }}\n <qd-tooltip-icon [tooltip]=\"header?.tooltip\"></qd-tooltip-icon>\n </div>\n } @if (hasVisibleActions$ | async) {\n <div class=\"table-cell actions-column\">\n <button class=\"menu-button\">\n <qd-icon icon=\"overflowMenuHorizontal\"></qd-icon>\n </button>\n </div>\n }\n </div>\n </div>\n }\n <div class=\"table-body\">\n <div\n class=\"table-row\"\n *qdCustomFor=\"let row of templateData; let rowIndex = index; toggler: togglerDrawing\"\n [formGroupName]=\"rowIndex\"\n [attr.data-test-id]=\"testId + '-row-' + rowIndex\"\n >\n @for (column of visibleColumns; track trackByColumnName($index, column)) {\n <div class=\"table-cell\">\n @if (column.type === 'enum') {\n <qd-dropdown\n [config]=\"{\n filter: column.filter,\n options: column.options,\n placeholder: column.placeholder,\n placeholderPrefix: column.placeholderPrefix,\n viewonly: (viewonly$ | async) === true || !column.isEditable(row, column.name)\n }\"\n [data-test-id]=\"column.name + rowIndex\"\n [dense]=\"true\"\n [formControl]=\"$any(control.controls[rowIndex])?.controls[column.name]\"\n qdFocusable\n class=\"dropdown\"\n >\n </qd-dropdown>\n } @else { @if ($any(control.controls[rowIndex])?.controls[column.name]) {\n <qd-input\n [data-test-id]=\"column.name + rowIndex\"\n [formControlName]=\"column.name\"\n [config]=\"{\n inputType: column.type === 'integer' ? 'number' : 'text',\n viewonly: (viewonly$ | async) === true || !column.isEditable(row, column.name)\n }\"\n qdFocusable\n ></qd-input>\n } }\n </div>\n } @if (hasVisibleActions$ | async) {\n <td class=\"table-cell actions\" [attr.data-test-id]=\"testId + '-cell-inline-actions'\">\n <button\n type=\"button\"\n [qdPopoverOnClick]=\"menu\"\n [qdPopoverCloseStrategy]=\"'onEveryClick'\"\n [qdPopoverStopPropagation]=\"true\"\n class=\"menu-button\"\n data-test=\"secondary-actions-toggler\"\n >\n <qd-icon icon=\"overflowMenuHorizontal\"></qd-icon>\n </button>\n <ng-template #menu>\n @for (secondaryAction of actions$ | async; track secondaryAction) {\n <button\n class=\"secondary-actions\"\n [ngClass]=\"{ disabled: isActionDisabled(secondaryAction, row) }\"\n [attr.disabled]=\"isActionDisabled(secondaryAction, row) || null\"\n (click)=\"handleSecondaryAction(secondaryAction, rowIndex)\"\n >\n {{ secondaryAction.label.i18n | translate }}\n </button>\n } @if (canAdd && (viewonly$ | async) === false) {\n <button class=\"secondary-actions\" (click)=\"removeRow(rowIndex)\">\n {{ \"i18n.qd.quick.edit.removeButtonLabel\" | translate }}\n </button>\n }\n </ng-template>\n </td>\n }\n </div>\n </div>\n @if (config.emptyStateView && !config.emptyStateView.disabled && templateData.length === 0) {\n <div class=\"empty-body\">\n <p>{{ config.emptyStateView.i18n | translate }}</p>\n </div>\n }\n</div>\n", styles: [".table{display:flex;width:100%;flex-direction:column;margin:1.25rem auto;background-color:#fff;font-size:.875rem}.table ::ng-deep .qd-input-input{margin-bottom:0!important}.table-header .table-row{padding-top:.125rem;padding-bottom:.125rem;background-color:#e5e5e5;font-weight:700}.table-header .table-row .actions-column{visibility:hidden}.table-header,.table-body{display:flex;flex-direction:column}.table-row{display:flex;flex-direction:row;padding:.25rem 1rem;border-bottom:.0625rem solid rgb(213,213,213);gap:1rem}.table-row ::ng-deep qd-form-label{display:none!important}.table-row ::ng-deep qd-input{min-width:0;margin-bottom:0!important}.table-body .table-row:hover{background-color:#f5f5f5}.table-cell{display:flex;min-width:0;height:2.3125rem;flex:1;align-items:center;text-align:left}.table-cell:has(.qd-input-error),.table-cell:has(.qd-dropdown-error){height:auto;align-items:flex-start}.table-cell:has(.qd-input-character-counter){height:auto;align-items:flex-start}.table-cell:has(.qd-input-character-counter) ::ng-deep qd-input{position:relative}.table-cell:has(.qd-input-character-counter) ::ng-deep qd-input .qd-input-character-counter{position:absolute;right:.25rem;bottom:.125rem;font-size:.625rem;line-height:1;pointer-events:none}.table-cell.actions,.table-cell.actions-column{min-width:auto;flex:0 0 auto}.table-row:last-child{border-bottom:none}.editable-actions{display:flex;justify-content:flex-end;margin-right:.625rem;gap:.625rem}.menu-button{display:flex;padding:0 .625rem 0 .375rem;background:unset;color:#454545;font-size:2rem;vertical-align:middle}.menu-button:hover,.menu-button:focus{color:#000;outline:0!important}.secondary-actions{display:block;width:100%;min-height:2rem;padding:0 1rem;background:#fff0;font-size:.75rem;text-align:left}.secondary-actions:hover{background-color:#f2f7fa}.secondary-actions.disabled{color:#b4b4b4;cursor:not-allowed}.secondary-actions.disabled:hover{background-color:#fff0}.dropdown{width:100%;min-width:0}.empty-body{padding:1.5rem;background:#fff}.empty-body p{margin:0 0 .5rem}\n"], dependencies: [{ kind: "component", type: QdButtonComponent, selector: "button[qdButton], a[qdButton]", inputs: ["disabled", "color", "icon", "data-test-id", "additionalInfo"] }, { kind: "directive", type: QdButtonGhostDirective, selector: "button[qdButtonGhost], a[qdButtonGhost]" }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: QdDropdownComponent, selector: "qd-dropdown", inputs: ["value", "id", "formControlName", "config", "data-test-id", "qdPopoverMaxHeight", "dense"], outputs: ["valueChange", "enterClick", "dropdownOpened", "clickHint", "clickReadonly", "clickViewonly", "optionsResolved"] }, { kind: "component", type: QdInputComponent, selector: "qd-input", inputs: ["formControlName", "value", "config", "isError", "data-test-id"], outputs: ["valueChange", "enterClick", "clickClear", "clickHint", "clickReadonly", "clickViewonly", "optionsResolved"] }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1$2.FormGroupName, selector: "[formGroupName]", inputs: ["formGroupName"] }, { kind: "component", type: QdIconComponent, selector: "qd-icon", inputs: ["icon", "status"] }, { kind: "directive", type: QdPopoverOnClickDirective, selector: "[qdPopoverOnClick]", inputs: ["qdPopoverOnClick", "qdPopoverPlacement", "qdPopoverOffsetX", "qdPopoverOffsetY", "qdPopoverCloseStrategy", "qdPopoverDisabled", "qdPopoverStopPropagation", "qdPopoverBackgroundColor", "qdPopoverMaxHeight", "qdPopoverMinWidth", "qdPopoverMaxWidth", "qdPopoverAutoSize", "qdPopoverEnableKeyControl", "qdPopoverRestoreFocus", "qdPopoverFlipIntoViewport"], outputs: ["opened", "closed"], exportAs: ["qdPopoverOnClick"] }, { kind: "directive", type: QdFocusableDirective, selector: "[qdFocusable]" }, { kind: "component", type: QdTooltipIconComponent, selector: "qd-tooltip-icon", inputs: ["tooltip"] }, { kind: "directive", type: QdCustomForDirective, selector: "[qdCustomFor]", inputs: ["qdCustomForOf", "qdCustomForToggler"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|