@one-paragon/angular-utilities 0.0.32 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/action-state/action-state-spinner/action-state-spinner.component.d.ts +12 -0
- package/action-state/action-state-ui/action-state-ui.module.d.ts +9 -0
- package/action-state/index.d.ts +4 -0
- package/action-state/ngrx-ext/ngrx-ext.module.d.ts +8 -0
- package/action-state/ngrx.d.ts +31 -0
- package/esm2020/action-state/action-state-spinner/action-state-spinner.component.mjs +23 -0
- package/esm2020/action-state/action-state-ui/action-state-ui.module.mjs +30 -0
- package/esm2020/action-state/index.mjs +8 -0
- package/esm2020/action-state/ngrx-ext/ngrx-ext.module.mjs +25 -0
- package/esm2020/action-state/ngrx.mjs +42 -0
- package/esm2020/public-api.mjs +2 -1
- package/esm2020/rxjs/rxjs-operators.mjs +14 -3
- package/esm2020/table-builder/classes/data-filter.mjs +6 -2
- package/esm2020/table-builder/components/column-builder/column-builder.component.mjs +23 -9
- package/esm2020/table-builder/components/initialization-component/initialization-component.mjs +11 -30
- package/esm2020/table-builder/interfaces/report-def.mjs +1 -1
- package/esm2020/table-builder/services/table-template-service.mjs +5 -5
- package/esm2020/table-builder/services/transform-creator.mjs +27 -10
- package/esm2020/utilities/directives/conditional-classes.directive.mjs +36 -0
- package/esm2020/utilities/index.mjs +2 -1
- package/esm2020/utilities/module.mjs +8 -3
- package/fesm2015/one-paragon-angular-utilities.mjs +841 -677
- package/fesm2015/one-paragon-angular-utilities.mjs.map +1 -1
- package/fesm2020/one-paragon-angular-utilities.mjs +847 -677
- package/fesm2020/one-paragon-angular-utilities.mjs.map +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
- package/rxjs/rxjs-operators.d.ts +1 -0
- package/table-builder/components/column-builder/column-builder.component.d.ts +3 -1
- package/table-builder/components/initialization-component/initialization-component.d.ts +2 -7
- package/table-builder/interfaces/report-def.d.ts +9 -6
- package/table-builder/services/transform-creator.d.ts +3 -1
- package/utilities/directives/conditional-classes.directive.d.ts +14 -0
- package/utilities/index.d.ts +1 -0
- package/utilities/module.d.ts +2 -1
|
@@ -1,25 +1,29 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Directive, Input, NgModule, Injectable, InjectionToken, Pipe,
|
|
3
|
-
import { shareReplay, switchAll, map, filter, tap, catchError, startWith, switchMap, mergeMap, pluck,
|
|
2
|
+
import { Directive, Input, NgModule, Injectable, InjectionToken, Pipe, HostListener, Component, EventEmitter, Output, ContentChildren, Inject, ChangeDetectionStrategy, ViewChild, Injector, ElementRef, Optional } from '@angular/core';
|
|
3
|
+
import { shareReplay, switchAll, map, filter, tap, catchError, startWith, switchMap, mergeMap, pluck, last, takeUntil, distinctUntilKeyChanged, delay as delay$1, distinct, first as first$1, distinctUntilChanged, withLatestFrom, mergeAll, scan as scan$1 } from 'rxjs/operators';
|
|
4
4
|
import * as i2$2 from 'rxjs';
|
|
5
|
-
import { Subject, isObservable, of, ReplaySubject,
|
|
5
|
+
import { Subject, isObservable, of, ReplaySubject, filter as filter$1, first, map as map$1, Observable, combineLatest, Subscription, startWith as startWith$1, pairwise, concatMap, merge, delay, switchMap as switchMap$1, scan, fromEvent, asyncScheduler, tap as tap$1, BehaviorSubject, takeUntil as takeUntil$1, from } from 'rxjs';
|
|
6
6
|
import { ComponentStore } from '@ngrx/component-store';
|
|
7
7
|
import * as i3$2 from '@angular/material/table';
|
|
8
8
|
import { MatColumnDef, MatTableDataSource, MatTable, MatTableModule, MatRowDef } from '@angular/material/table';
|
|
9
9
|
import { SelectionModel } from '@angular/cdk/collections';
|
|
10
10
|
import * as _ from 'lodash';
|
|
11
|
-
import { flatten, merge, sumBy, orderBy, cloneDeep } from 'lodash';
|
|
12
|
-
import * as
|
|
11
|
+
import { flatten, merge as merge$1, sumBy, orderBy, cloneDeep } from 'lodash';
|
|
12
|
+
import * as i12 from '@angular/cdk/drag-drop';
|
|
13
13
|
import { moveItemInArray, CDK_DROP_LIST, CdkDropList, transferArrayItem, DragDropModule } from '@angular/cdk/drag-drop';
|
|
14
|
-
import * as i1 from '@angular/common';
|
|
14
|
+
import * as i1$1 from '@angular/common';
|
|
15
15
|
import { CommonModule, DatePipe, CurrencyPipe } from '@angular/common';
|
|
16
|
+
import * as i1 from '@angular/material/dialog';
|
|
17
|
+
import { MatDialogModule } from '@angular/material/dialog';
|
|
18
|
+
import * as i4$4 from '@angular/material/slide-toggle';
|
|
19
|
+
import { MatSlideToggle, MatSlideToggleModule } from '@angular/material/slide-toggle';
|
|
16
20
|
import { v4 } from 'uuid';
|
|
17
21
|
import update from 'immutability-helper';
|
|
18
22
|
import * as i4 from '@angular/material/icon';
|
|
19
23
|
import { MatIconModule } from '@angular/material/icon';
|
|
20
24
|
import * as i4$1 from '@angular/router';
|
|
21
25
|
import { RouterModule } from '@angular/router';
|
|
22
|
-
import * as i1$
|
|
26
|
+
import * as i1$2 from '@angular/material/sort';
|
|
23
27
|
import { MatSortModule, MatSort } from '@angular/material/sort';
|
|
24
28
|
import * as i4$2 from '@angular/material/menu';
|
|
25
29
|
import { MatMenuTrigger, MatMenuModule } from '@angular/material/menu';
|
|
@@ -36,13 +40,13 @@ import * as i8 from '@angular/material/datepicker';
|
|
|
36
40
|
import { MatDatepickerModule } from '@angular/material/datepicker';
|
|
37
41
|
import * as i4$3 from '@angular/material/input';
|
|
38
42
|
import { MatInputModule } from '@angular/material/input';
|
|
39
|
-
import * as
|
|
43
|
+
import * as i8$1 from '@angular/material/tooltip';
|
|
40
44
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
41
45
|
import * as i7$1 from '@ngrx/component';
|
|
42
46
|
import { ReactiveComponentModule } from '@ngrx/component';
|
|
43
47
|
import * as i2 from '@angular/material/paginator';
|
|
44
48
|
import { MatPaginator, MatPaginatorModule } from '@angular/material/paginator';
|
|
45
|
-
import * as i1$
|
|
49
|
+
import * as i1$3 from '@angular/cdk/table';
|
|
46
50
|
import * as i2$1 from '@angular/material/card';
|
|
47
51
|
import { MatCardModule } from '@angular/material/card';
|
|
48
52
|
import * as i6$1 from '@angular/material/select';
|
|
@@ -51,15 +55,12 @@ import * as i6$2 from '@angular/material/core';
|
|
|
51
55
|
import { MatNativeDateModule } from '@angular/material/core';
|
|
52
56
|
import { MatAutocompleteModule } from '@angular/material/autocomplete';
|
|
53
57
|
import { MatBadgeModule } from '@angular/material/badge';
|
|
54
|
-
import * as i1$3 from '@angular/material/dialog';
|
|
55
|
-
import { MatDialogModule } from '@angular/material/dialog';
|
|
56
58
|
import { MatExpansionModule } from '@angular/material/expansion';
|
|
57
59
|
import { MatGridListModule } from '@angular/material/grid-list';
|
|
58
60
|
import { MatListModule } from '@angular/material/list';
|
|
61
|
+
import * as i1$5 from '@angular/material/progress-spinner';
|
|
59
62
|
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
60
63
|
import { MatSidenavModule } from '@angular/material/sidenav';
|
|
61
|
-
import * as i4$4 from '@angular/material/slide-toggle';
|
|
62
|
-
import { MatSlideToggleModule, MatSlideToggle } from '@angular/material/slide-toggle';
|
|
63
64
|
import { MatSnackBarModule } from '@angular/material/snack-bar';
|
|
64
65
|
import { MatStepperModule } from '@angular/material/stepper';
|
|
65
66
|
import { MatTabsModule } from '@angular/material/tabs';
|
|
@@ -68,9 +69,10 @@ import * as i6$3 from '@angular/material/chips';
|
|
|
68
69
|
import { MatChipsModule } from '@angular/material/chips';
|
|
69
70
|
import * as i7$2 from '@angular/material/button-toggle';
|
|
70
71
|
import * as i3$3 from '@ngrx/store';
|
|
71
|
-
import { createSelector, createAction, props, select, createReducer, on, StoreModule } from '@ngrx/store';
|
|
72
|
+
import { createSelector, createAction, props, select, createReducer, on, StoreModule, createFeatureSelector } from '@ngrx/store';
|
|
72
73
|
import * as i1$4 from '@ngrx/effects';
|
|
73
74
|
import { createEffect, ofType, concatLatestFrom, EffectsModule } from '@ngrx/effects';
|
|
75
|
+
import { createEntityAdapter } from '@ngrx/entity';
|
|
74
76
|
|
|
75
77
|
var HttpRequestStatus;
|
|
76
78
|
(function (HttpRequestStatus) {
|
|
@@ -519,10 +521,10 @@ var ArrayStyle;
|
|
|
519
521
|
})(ArrayStyle || (ArrayStyle = {}));
|
|
520
522
|
|
|
521
523
|
const onceWhen = (predicate) => (src) => {
|
|
522
|
-
return src.pipe(filter(predicate), first());
|
|
524
|
+
return src.pipe(filter$1(predicate), first());
|
|
523
525
|
};
|
|
524
|
-
const mapArray = (mapFunc) => (source) => source.pipe(map(src => src.map(mapFunc)));
|
|
525
|
-
const filterArray = (filterFunc) => (source) => source.pipe(map(src => src.filter(filterFunc)));
|
|
526
|
+
const mapArray = (mapFunc) => (source) => source.pipe(map$1(src => src.map(mapFunc)));
|
|
527
|
+
const filterArray = (filterFunc) => (source) => source.pipe(map$1(src => src.filter(filterFunc)));
|
|
526
528
|
function onWait(val) {
|
|
527
529
|
return (source) => {
|
|
528
530
|
return new Observable(subscriber => {
|
|
@@ -541,7 +543,7 @@ function onWait(val) {
|
|
|
541
543
|
};
|
|
542
544
|
}
|
|
543
545
|
const combineArrays = (sources) => {
|
|
544
|
-
return combineLatest(sources.map(src => src.pipe(onWait([])))).pipe(map(res => flatten(res)));
|
|
546
|
+
return combineLatest(sources.map(src => src.pipe(onWait([])))).pipe(map$1(res => flatten(res)));
|
|
545
547
|
};
|
|
546
548
|
function switchOff(switchSource, defaultState = true) {
|
|
547
549
|
return (source) => {
|
|
@@ -586,12 +588,24 @@ function skipOneWhen(skipper) {
|
|
|
586
588
|
}
|
|
587
589
|
function previousAndCurrent(startingValue) {
|
|
588
590
|
return (source) => {
|
|
589
|
-
return source.pipe(startWith(startingValue), pairwise());
|
|
591
|
+
return source.pipe(startWith$1(startingValue), pairwise());
|
|
590
592
|
};
|
|
591
593
|
}
|
|
592
594
|
function notNull() {
|
|
593
595
|
return (source) => {
|
|
594
|
-
return source.pipe(filter((o) => !!o));
|
|
596
|
+
return source.pipe(filter$1((o) => !!o));
|
|
597
|
+
};
|
|
598
|
+
}
|
|
599
|
+
function delayOn(predicate, delayTime) {
|
|
600
|
+
return (src) => {
|
|
601
|
+
return src.pipe(concatMap(r => {
|
|
602
|
+
if (predicate(r)) {
|
|
603
|
+
return merge(of({ r }), of(null).pipe(delay(delayTime))).pipe(notNull(), map$1(d => d.r));
|
|
604
|
+
}
|
|
605
|
+
else {
|
|
606
|
+
return of(r);
|
|
607
|
+
}
|
|
608
|
+
}));
|
|
595
609
|
};
|
|
596
610
|
}
|
|
597
611
|
|
|
@@ -615,147 +629,644 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
615
629
|
args: [{ name: 'phone' }]
|
|
616
630
|
}] });
|
|
617
631
|
|
|
618
|
-
|
|
619
|
-
|
|
632
|
+
class PreventEnterDirective {
|
|
633
|
+
onKeyDown() {
|
|
634
|
+
return false;
|
|
635
|
+
}
|
|
620
636
|
}
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
637
|
+
PreventEnterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: PreventEnterDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
638
|
+
PreventEnterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: PreventEnterDirective, selector: "preventEnter", host: { listeners: { "keydown.enter": "onKeyDown($event)" } }, ngImport: i0 });
|
|
639
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: PreventEnterDirective, decorators: [{
|
|
640
|
+
type: Directive,
|
|
641
|
+
args: [{
|
|
642
|
+
selector: 'preventEnter'
|
|
643
|
+
}]
|
|
644
|
+
}], propDecorators: { onKeyDown: [{
|
|
645
|
+
type: HostListener,
|
|
646
|
+
args: ['keydown.enter', ['$event']]
|
|
647
|
+
}] } });
|
|
648
|
+
|
|
649
|
+
class StopPropagationDirective {
|
|
650
|
+
onClick(event) {
|
|
651
|
+
event.stopPropagation();
|
|
627
652
|
}
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
if (metaData.transform) {
|
|
631
|
-
if (isPipe(metaData.transform)) {
|
|
632
|
-
return metaData.transform.transform;
|
|
633
|
-
}
|
|
634
|
-
return metaData.transform;
|
|
635
|
-
}
|
|
636
|
-
if (this.config.transformers && this.config.transformers[metaData.fieldType]) {
|
|
637
|
-
return this.config.transformers[metaData.fieldType];
|
|
638
|
-
}
|
|
639
|
-
switch (metaData.fieldType) {
|
|
640
|
-
case FieldType.Date:
|
|
641
|
-
const dateFormat = (_d = (_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.dateFormat) !== null && _b !== void 0 ? _b : (_c = this.config.defaultSettings) === null || _c === void 0 ? void 0 : _c.dateFormat) !== null && _d !== void 0 ? _d : 'shortDate';
|
|
642
|
-
return (value) => this.datePipe.transform(value, dateFormat);
|
|
643
|
-
case FieldType.Currency:
|
|
644
|
-
return this.currencyPipe.transform;
|
|
645
|
-
case FieldType.PhoneNumber:
|
|
646
|
-
return this.phonePipe.transform;
|
|
647
|
-
}
|
|
648
|
-
return (value) => value;
|
|
653
|
+
onMousedown(event) {
|
|
654
|
+
event.stopPropagation();
|
|
649
655
|
}
|
|
650
656
|
}
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type:
|
|
654
|
-
type:
|
|
657
|
+
StopPropagationDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StopPropagationDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
658
|
+
StopPropagationDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: StopPropagationDirective, selector: "[stop-propagation]", host: { listeners: { "click": "onClick($event)", "mousedown": "onMousedown($event)" } }, ngImport: i0 });
|
|
659
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StopPropagationDirective, decorators: [{
|
|
660
|
+
type: Directive,
|
|
655
661
|
args: [{
|
|
656
|
-
|
|
662
|
+
selector: "[stop-propagation]"
|
|
657
663
|
}]
|
|
658
|
-
}],
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
+
}], propDecorators: { onClick: [{
|
|
665
|
+
type: HostListener,
|
|
666
|
+
args: ["click", ["$event"]]
|
|
667
|
+
}], onMousedown: [{
|
|
668
|
+
type: HostListener,
|
|
669
|
+
args: ["mousedown", ["$event"]]
|
|
670
|
+
}] } });
|
|
664
671
|
|
|
665
|
-
class
|
|
666
|
-
constructor(
|
|
667
|
-
this.
|
|
668
|
-
this.
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
672
|
+
class AutoFocusDirective {
|
|
673
|
+
constructor(elementRef) {
|
|
674
|
+
this.elementRef = elementRef;
|
|
675
|
+
this.autoFocus = true;
|
|
676
|
+
}
|
|
677
|
+
ngAfterViewInit() {
|
|
678
|
+
if (this.autoFocus) {
|
|
679
|
+
setTimeout(() => {
|
|
680
|
+
this.elementRef.nativeElement.focus();
|
|
681
|
+
});
|
|
674
682
|
}
|
|
675
683
|
}
|
|
676
684
|
}
|
|
677
|
-
|
|
685
|
+
AutoFocusDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: AutoFocusDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
686
|
+
AutoFocusDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: AutoFocusDirective, selector: "[autoFocus]", inputs: { autoFocus: "autoFocus" }, ngImport: i0 });
|
|
687
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: AutoFocusDirective, decorators: [{
|
|
688
|
+
type: Directive,
|
|
689
|
+
args: [{
|
|
690
|
+
selector: '[autoFocus]'
|
|
691
|
+
}]
|
|
692
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { autoFocus: [{
|
|
693
|
+
type: Input
|
|
694
|
+
}] } });
|
|
695
|
+
|
|
696
|
+
class ClickSubjectDirective extends Subject {
|
|
678
697
|
constructor() {
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
this.
|
|
683
|
-
this.hideSort = false;
|
|
684
|
-
this.collapse = false;
|
|
685
|
-
this.showTitleWhenCollapsed = true;
|
|
698
|
+
super();
|
|
699
|
+
}
|
|
700
|
+
set clickSubject(val) {
|
|
701
|
+
this._val = val;
|
|
686
702
|
}
|
|
687
703
|
}
|
|
688
|
-
|
|
704
|
+
ClickSubjectDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickSubjectDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
705
|
+
ClickSubjectDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: ClickSubjectDirective, selector: "[clickSubject]", inputs: { clickSubject: "clickSubject" }, host: { listeners: { "click": "next(this._val)" } }, exportAs: ["clickSubject"], usesInheritance: true, ngImport: i0 });
|
|
706
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickSubjectDirective, decorators: [{
|
|
707
|
+
type: Directive,
|
|
708
|
+
args: [{
|
|
709
|
+
selector: '[clickSubject]',
|
|
710
|
+
exportAs: 'clickSubject',
|
|
711
|
+
host: {
|
|
712
|
+
'(click)': 'next(this._val)'
|
|
713
|
+
}
|
|
714
|
+
}]
|
|
715
|
+
}], ctorParameters: function () { return []; }, propDecorators: { clickSubject: [{
|
|
716
|
+
type: Input,
|
|
717
|
+
args: ['clickSubject']
|
|
718
|
+
}] } });
|
|
719
|
+
|
|
720
|
+
class ClickEmitterDirective extends Subject {
|
|
689
721
|
constructor() {
|
|
690
|
-
|
|
722
|
+
super();
|
|
691
723
|
}
|
|
692
724
|
}
|
|
693
|
-
|
|
725
|
+
ClickEmitterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickEmitterDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
726
|
+
ClickEmitterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: ClickEmitterDirective, selector: "[clickEmitter]", host: { listeners: { "click": "next(true)" } }, exportAs: ["clickEmitter"], usesInheritance: true, ngImport: i0 });
|
|
727
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickEmitterDirective, decorators: [{
|
|
728
|
+
type: Directive,
|
|
729
|
+
args: [{
|
|
730
|
+
selector: '[clickEmitter]',
|
|
731
|
+
exportAs: 'clickEmitter',
|
|
732
|
+
host: {
|
|
733
|
+
'(click)': 'next(true)'
|
|
734
|
+
}
|
|
735
|
+
}]
|
|
736
|
+
}], ctorParameters: function () { return []; } });
|
|
737
|
+
|
|
738
|
+
class DialogService {
|
|
694
739
|
constructor() {
|
|
695
|
-
this.
|
|
696
|
-
this.noHeader = false;
|
|
740
|
+
this.allOpenAppDialogs = [];
|
|
697
741
|
}
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
this.
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
this.collapseFooter = (_d = (_c = tableSettings.footerSettings) === null || _c === void 0 ? void 0 : _c.collapse) !== null && _d !== void 0 ? _d : tableSettings.collapseFooter;
|
|
707
|
-
}
|
|
742
|
+
addDialogRef(ref) {
|
|
743
|
+
this.allOpenAppDialogs.push(ref);
|
|
744
|
+
}
|
|
745
|
+
removeDialogRef(ref) {
|
|
746
|
+
this.allOpenAppDialogs = this.allOpenAppDialogs.filter(rf => ref.id !== rf.id);
|
|
747
|
+
}
|
|
748
|
+
closeAllAppDialogs() {
|
|
749
|
+
this.allOpenAppDialogs.forEach(ref => ref.close());
|
|
708
750
|
}
|
|
709
751
|
}
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
752
|
+
DialogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
753
|
+
DialogService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogService, providedIn: 'root' });
|
|
754
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogService, decorators: [{
|
|
755
|
+
type: Injectable,
|
|
756
|
+
args: [{
|
|
757
|
+
providedIn: 'root'
|
|
758
|
+
}]
|
|
759
|
+
}] });
|
|
760
|
+
|
|
761
|
+
class DialogWrapper {
|
|
762
|
+
constructor(vcr) {
|
|
763
|
+
this.vcr = vcr;
|
|
764
|
+
this.viewEmbeded = false;
|
|
765
|
+
this.viewContext = {
|
|
766
|
+
close: () => { },
|
|
767
|
+
};
|
|
768
|
+
}
|
|
769
|
+
set template(tmpl) {
|
|
770
|
+
if (this.viewEmbeded) {
|
|
771
|
+
this.vcr.clear();
|
|
729
772
|
}
|
|
773
|
+
this.viewEmbeded = true;
|
|
774
|
+
this.vcr.createEmbeddedView(tmpl, this.viewContext);
|
|
775
|
+
}
|
|
776
|
+
set close(closeMethod) {
|
|
777
|
+
this.viewContext.close = closeMethod;
|
|
778
|
+
}
|
|
779
|
+
set data(value) {
|
|
780
|
+
this.viewContext.$implicit = value;
|
|
781
|
+
this.viewContext.opDialog = value;
|
|
730
782
|
}
|
|
731
783
|
}
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
(
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
}
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
filters: {},
|
|
744
|
-
hiddenKeys: [],
|
|
745
|
-
sorted: [],
|
|
746
|
-
userDefined: { order: {}, widths: {}, table: {} },
|
|
747
|
-
persistedTableSettings: new PesrsistedTableSettings(),
|
|
748
|
-
notPersisitedTableSettings: new NotPersisitedTableSettings(),
|
|
749
|
-
pageSize: 10,
|
|
784
|
+
DialogWrapper.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogWrapper, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
785
|
+
DialogWrapper.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: DialogWrapper, selector: "app-dialog-content", ngImport: i0, template: ``, isInline: true });
|
|
786
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogWrapper, decorators: [{
|
|
787
|
+
type: Component,
|
|
788
|
+
args: [{
|
|
789
|
+
selector: 'app-dialog-content',
|
|
790
|
+
template: ``
|
|
791
|
+
}]
|
|
792
|
+
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; } });
|
|
793
|
+
const defaultDialogConfig = {
|
|
794
|
+
maxHeight: '95vh'
|
|
750
795
|
};
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
796
|
+
class DialogDirective {
|
|
797
|
+
constructor(templateRef, dialog, service) {
|
|
798
|
+
this.templateRef = templateRef;
|
|
799
|
+
this.dialog = dialog;
|
|
800
|
+
this.service = service;
|
|
801
|
+
this.opDialogClosed = new EventEmitter();
|
|
802
|
+
this._dialogConfig = defaultDialogConfig;
|
|
803
|
+
this._data = new Subject();
|
|
804
|
+
this.subscription = this._data.pipe(switchAll()).subscribe(d => {
|
|
805
|
+
if (d) {
|
|
806
|
+
this.opDialogConfig.data = d;
|
|
807
|
+
this.setDialogState(true);
|
|
808
|
+
}
|
|
809
|
+
else {
|
|
810
|
+
this.setDialogState(false);
|
|
811
|
+
}
|
|
812
|
+
});
|
|
813
|
+
}
|
|
814
|
+
set opDialogConfig(config) {
|
|
815
|
+
this._dialogConfig = Object.assign(Object.assign({}, defaultDialogConfig), config);
|
|
816
|
+
}
|
|
817
|
+
get opDialogConfig() {
|
|
818
|
+
return this._dialogConfig;
|
|
819
|
+
}
|
|
820
|
+
set state(open_close) {
|
|
821
|
+
this._data.next(open_close);
|
|
822
|
+
}
|
|
823
|
+
close() {
|
|
824
|
+
var _a;
|
|
825
|
+
(_a = this.dialogRef) === null || _a === void 0 ? void 0 : _a.close();
|
|
826
|
+
}
|
|
827
|
+
initDialog() {
|
|
828
|
+
if (this.nativeElement) {
|
|
829
|
+
const rect = this.nativeElement.getBoundingClientRect();
|
|
830
|
+
const position = { left: `${rect.left}px`, top: `${rect.bottom - 50}px` };
|
|
831
|
+
this.opDialogConfig = Object.assign(Object.assign({}, this.opDialogConfig), { position });
|
|
832
|
+
}
|
|
833
|
+
this.dialogRef = this.dialog.open(DialogWrapper, this.opDialogConfig);
|
|
834
|
+
this.componentWrapper = this.dialogRef.componentInstance;
|
|
835
|
+
this.componentWrapper.close = () => { var _a; return (_a = this.dialogRef) === null || _a === void 0 ? void 0 : _a.close(); };
|
|
836
|
+
this.componentWrapper.data = this.opDialogConfig.data;
|
|
837
|
+
this.componentWrapper.template = this.templateRef;
|
|
838
|
+
if (!this.opDialogConfig.disableClose) {
|
|
839
|
+
this.service.addDialogRef(this.dialogRef);
|
|
840
|
+
}
|
|
841
|
+
const sub = this.dialogRef.afterClosed().subscribe(() => {
|
|
842
|
+
this.opDialogClosed.emit(true);
|
|
843
|
+
this.service.removeDialogRef(this.dialogRef);
|
|
844
|
+
this.dialogRef = undefined;
|
|
845
|
+
sub.unsubscribe();
|
|
846
|
+
});
|
|
847
|
+
}
|
|
848
|
+
setDialogState(open) {
|
|
849
|
+
if (open) {
|
|
850
|
+
if (!this.dialogRef) {
|
|
851
|
+
this.initDialog();
|
|
852
|
+
}
|
|
853
|
+
else {
|
|
854
|
+
this.componentWrapper.data = this.opDialogConfig.data;
|
|
855
|
+
}
|
|
856
|
+
}
|
|
857
|
+
else if (!open && this.dialogRef) {
|
|
858
|
+
this.dialogRef.close();
|
|
859
|
+
}
|
|
860
|
+
}
|
|
861
|
+
ngOnDestroy() {
|
|
862
|
+
if (this.subscription) {
|
|
863
|
+
this.subscription.unsubscribe();
|
|
864
|
+
}
|
|
865
|
+
}
|
|
866
|
+
static ngTemplateContextGuard(dir, ctx) {
|
|
867
|
+
return true;
|
|
868
|
+
}
|
|
869
|
+
}
|
|
870
|
+
DialogDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogDirective, deps: [{ token: i0.TemplateRef }, { token: i1.MatDialog }, { token: DialogService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
871
|
+
DialogDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: DialogDirective, selector: "[opDialog]", inputs: { opDialogConfig: "opDialogConfig", state: ["opDialog", "state"], nativeElement: ["opDialogOrigin", "nativeElement"] }, outputs: { opDialogClosed: "opDialogClosed" }, ngImport: i0 });
|
|
872
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogDirective, decorators: [{
|
|
873
|
+
type: Directive,
|
|
874
|
+
args: [{ selector: '[opDialog]' }]
|
|
875
|
+
}], ctorParameters: function () { return [{ type: i0.TemplateRef }, { type: i1.MatDialog }, { type: DialogService }]; }, propDecorators: { opDialogClosed: [{
|
|
876
|
+
type: Output
|
|
877
|
+
}], opDialogConfig: [{
|
|
878
|
+
type: Input
|
|
879
|
+
}], state: [{
|
|
880
|
+
type: Input,
|
|
881
|
+
args: ['opDialog']
|
|
882
|
+
}], nativeElement: [{
|
|
883
|
+
type: Input,
|
|
884
|
+
args: ['opDialogOrigin']
|
|
885
|
+
}] } });
|
|
886
|
+
|
|
887
|
+
class StylerDirective {
|
|
888
|
+
constructor(el) {
|
|
889
|
+
this.el = el;
|
|
890
|
+
}
|
|
891
|
+
set styler(styles) {
|
|
892
|
+
if (styles) {
|
|
893
|
+
Object.keys(styles).forEach(style => {
|
|
894
|
+
this.el.nativeElement.style[style] = styles[style];
|
|
895
|
+
});
|
|
896
|
+
}
|
|
897
|
+
}
|
|
898
|
+
;
|
|
899
|
+
}
|
|
900
|
+
StylerDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StylerDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
901
|
+
StylerDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: StylerDirective, selector: "[styler]", inputs: { styler: "styler" }, ngImport: i0 });
|
|
902
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StylerDirective, decorators: [{
|
|
903
|
+
type: Directive,
|
|
904
|
+
args: [{
|
|
905
|
+
selector: '[styler]',
|
|
906
|
+
}]
|
|
907
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { styler: [{
|
|
908
|
+
type: Input
|
|
909
|
+
}] } });
|
|
910
|
+
|
|
911
|
+
class MatSlideToggleGroupDirective {
|
|
912
|
+
constructor() {
|
|
913
|
+
this.allowMultiple = false;
|
|
914
|
+
this._ready = new ReplaySubject(1);
|
|
915
|
+
}
|
|
916
|
+
set toggles(val) {
|
|
917
|
+
this._toggles = val;
|
|
918
|
+
this._ready.next(true);
|
|
919
|
+
}
|
|
920
|
+
get valueEmitter() {
|
|
921
|
+
return this._ready.pipe(switchMap$1(_ => this.getObs()));
|
|
922
|
+
}
|
|
923
|
+
getInitValue() {
|
|
924
|
+
const startValue = this._toggles.reduce((prev, cur) => {
|
|
925
|
+
if (!cur.name) {
|
|
926
|
+
throw new Error('toggle must have the name attribute set');
|
|
927
|
+
}
|
|
928
|
+
prev[cur.name] = cur.checked;
|
|
929
|
+
return prev;
|
|
930
|
+
}, {});
|
|
931
|
+
return startValue;
|
|
932
|
+
}
|
|
933
|
+
getObs() {
|
|
934
|
+
var toggleChanges = merge(...this._toggles.map(toggle => toggle.change));
|
|
935
|
+
const startValue = this.getInitValue();
|
|
936
|
+
return toggleChanges.pipe(scan((prev, cur) => {
|
|
937
|
+
const toggleName = cur.source.name;
|
|
938
|
+
const newVal = Object.assign(Object.assign({}, prev), { [toggleName]: cur.checked });
|
|
939
|
+
if (cur.checked && !this.allowMultiple) {
|
|
940
|
+
Object.keys(prev)
|
|
941
|
+
.filter(key => key !== toggleName && prev[key])
|
|
942
|
+
.forEach(key => {
|
|
943
|
+
newVal[key] = false;
|
|
944
|
+
this._toggles.find(toggle => toggle.name === key).toggle();
|
|
945
|
+
});
|
|
946
|
+
}
|
|
947
|
+
return newVal;
|
|
948
|
+
}, startValue), startWith$1(startValue));
|
|
949
|
+
}
|
|
950
|
+
}
|
|
951
|
+
MatSlideToggleGroupDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: MatSlideToggleGroupDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
952
|
+
MatSlideToggleGroupDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: MatSlideToggleGroupDirective, selector: "[opMatSlideToggleGroup]", inputs: { allowMultiple: "allowMultiple" }, outputs: { valueEmitter: "valueEmitter" }, queries: [{ propertyName: "toggles", predicate: MatSlideToggle }], ngImport: i0 });
|
|
953
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: MatSlideToggleGroupDirective, decorators: [{
|
|
954
|
+
type: Directive,
|
|
955
|
+
args: [{ selector: '[opMatSlideToggleGroup]', }]
|
|
956
|
+
}], propDecorators: { allowMultiple: [{
|
|
957
|
+
type: Input
|
|
958
|
+
}], toggles: [{
|
|
959
|
+
type: ContentChildren,
|
|
960
|
+
args: [MatSlideToggle]
|
|
961
|
+
}], valueEmitter: [{
|
|
962
|
+
type: Output
|
|
963
|
+
}] } });
|
|
964
|
+
|
|
965
|
+
class FunctionPipe {
|
|
966
|
+
transform(func, ...args) {
|
|
967
|
+
if (typeof func === 'string') {
|
|
968
|
+
const [instance, ...tail] = args;
|
|
969
|
+
const method = instance[func].bind(instance);
|
|
970
|
+
return method(...tail);
|
|
971
|
+
}
|
|
972
|
+
return func(...args);
|
|
973
|
+
}
|
|
974
|
+
}
|
|
975
|
+
FunctionPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FunctionPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
976
|
+
FunctionPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FunctionPipe, name: "func" });
|
|
977
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FunctionPipe, decorators: [{
|
|
978
|
+
type: Pipe,
|
|
979
|
+
args: [{
|
|
980
|
+
name: 'func'
|
|
981
|
+
}]
|
|
982
|
+
}] });
|
|
983
|
+
|
|
984
|
+
class SpaceCasePipe {
|
|
985
|
+
transform(value) {
|
|
986
|
+
return spaceCase(value);
|
|
987
|
+
}
|
|
988
|
+
}
|
|
989
|
+
SpaceCasePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SpaceCasePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
990
|
+
SpaceCasePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SpaceCasePipe, name: "spaceCase" });
|
|
991
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SpaceCasePipe, decorators: [{
|
|
992
|
+
type: Pipe,
|
|
993
|
+
args: [{ name: 'spaceCase' }]
|
|
994
|
+
}] });
|
|
995
|
+
/**
|
|
996
|
+
* Adds a space before uppercase letters that either
|
|
997
|
+
* 1. follows a lowercase letter or digit
|
|
998
|
+
* 2. or precedes a lowercase letter and follows an alpha-numeric character
|
|
999
|
+
*
|
|
1000
|
+
* Uppercases the first digit
|
|
1001
|
+
*
|
|
1002
|
+
* Turns underscores into spaces
|
|
1003
|
+
*/
|
|
1004
|
+
function spaceCase(value) {
|
|
1005
|
+
return value === null || value === void 0 ? void 0 : value.replace(/(?<=[a-z0-9])([A-Z])|(?<=[a-zA-Z0-9])([A-Z])(?=[a-z])|_/g, ' $1$2').replace(/^./, str => str.toUpperCase());
|
|
1006
|
+
}
|
|
1007
|
+
|
|
1008
|
+
class ConditionalClassesDirective {
|
|
1009
|
+
constructor(el, renderer) {
|
|
1010
|
+
this.el = el;
|
|
1011
|
+
this.renderer = renderer;
|
|
1012
|
+
this.classesApplied = [];
|
|
1013
|
+
this.el.nativeElement.style.backgroundColor = 'yellow';
|
|
1014
|
+
}
|
|
1015
|
+
ngOnChanges(changes) {
|
|
1016
|
+
let toApply = [];
|
|
1017
|
+
if (this.classes) {
|
|
1018
|
+
toApply = Object.keys(this.classes)
|
|
1019
|
+
.filter(key => this.classes[key](this.element));
|
|
1020
|
+
}
|
|
1021
|
+
var classesNotYetApplied = toApply.filter(c => !this.classesApplied.includes(c));
|
|
1022
|
+
var classesToRemove = this.classesApplied.filter(c => !toApply.includes(c));
|
|
1023
|
+
classesToRemove.forEach(c => this.renderer.removeClass(this.el.nativeElement, c));
|
|
1024
|
+
classesNotYetApplied.forEach(c => this.renderer.addClass(this.el.nativeElement, c));
|
|
1025
|
+
this.classesApplied = toApply;
|
|
1026
|
+
}
|
|
1027
|
+
}
|
|
1028
|
+
ConditionalClassesDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ConditionalClassesDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
|
|
1029
|
+
ConditionalClassesDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: ConditionalClassesDirective, selector: "[conditionalClasses]", inputs: { element: "element", classes: ["conditionalClasses", "classes"] }, usesOnChanges: true, ngImport: i0 });
|
|
1030
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ConditionalClassesDirective, decorators: [{
|
|
1031
|
+
type: Directive,
|
|
1032
|
+
args: [{
|
|
1033
|
+
selector: '[conditionalClasses]'
|
|
1034
|
+
}]
|
|
1035
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }]; }, propDecorators: { element: [{
|
|
1036
|
+
type: Input
|
|
1037
|
+
}], classes: [{
|
|
1038
|
+
type: Input,
|
|
1039
|
+
args: ['conditionalClasses']
|
|
1040
|
+
}] } });
|
|
1041
|
+
|
|
1042
|
+
class UtilitiesModule {
|
|
1043
|
+
}
|
|
1044
|
+
UtilitiesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1045
|
+
UtilitiesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, declarations: [SpaceCasePipe,
|
|
1046
|
+
PhoneNumberPipe,
|
|
1047
|
+
FunctionPipe,
|
|
1048
|
+
StopPropagationDirective,
|
|
1049
|
+
StylerDirective,
|
|
1050
|
+
PreventEnterDirective,
|
|
1051
|
+
AutoFocusDirective,
|
|
1052
|
+
ClickSubjectDirective,
|
|
1053
|
+
ClickEmitterDirective,
|
|
1054
|
+
DialogDirective,
|
|
1055
|
+
MatSlideToggleGroupDirective,
|
|
1056
|
+
ConditionalClassesDirective], exports: [StopPropagationDirective,
|
|
1057
|
+
PreventEnterDirective,
|
|
1058
|
+
SpaceCasePipe,
|
|
1059
|
+
PhoneNumberPipe,
|
|
1060
|
+
FunctionPipe,
|
|
1061
|
+
StopPropagationDirective,
|
|
1062
|
+
StylerDirective,
|
|
1063
|
+
PreventEnterDirective,
|
|
1064
|
+
AutoFocusDirective,
|
|
1065
|
+
ClickSubjectDirective,
|
|
1066
|
+
ClickEmitterDirective,
|
|
1067
|
+
DialogDirective,
|
|
1068
|
+
MatSlideToggleGroupDirective,
|
|
1069
|
+
ConditionalClassesDirective] });
|
|
1070
|
+
UtilitiesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, providers: [
|
|
1071
|
+
DialogService
|
|
1072
|
+
], imports: [[]] });
|
|
1073
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, decorators: [{
|
|
1074
|
+
type: NgModule,
|
|
1075
|
+
args: [{
|
|
1076
|
+
imports: [],
|
|
1077
|
+
exports: [
|
|
1078
|
+
StopPropagationDirective,
|
|
1079
|
+
PreventEnterDirective,
|
|
1080
|
+
SpaceCasePipe,
|
|
1081
|
+
PhoneNumberPipe,
|
|
1082
|
+
FunctionPipe,
|
|
1083
|
+
StopPropagationDirective,
|
|
1084
|
+
StylerDirective,
|
|
1085
|
+
PreventEnterDirective,
|
|
1086
|
+
AutoFocusDirective,
|
|
1087
|
+
ClickSubjectDirective,
|
|
1088
|
+
ClickEmitterDirective,
|
|
1089
|
+
DialogDirective,
|
|
1090
|
+
MatSlideToggleGroupDirective,
|
|
1091
|
+
ConditionalClassesDirective,
|
|
1092
|
+
],
|
|
1093
|
+
declarations: [
|
|
1094
|
+
SpaceCasePipe,
|
|
1095
|
+
PhoneNumberPipe,
|
|
1096
|
+
FunctionPipe,
|
|
1097
|
+
StopPropagationDirective,
|
|
1098
|
+
StylerDirective,
|
|
1099
|
+
PreventEnterDirective,
|
|
1100
|
+
AutoFocusDirective,
|
|
1101
|
+
ClickSubjectDirective,
|
|
1102
|
+
ClickEmitterDirective,
|
|
1103
|
+
DialogDirective,
|
|
1104
|
+
MatSlideToggleGroupDirective,
|
|
1105
|
+
ConditionalClassesDirective,
|
|
1106
|
+
],
|
|
1107
|
+
providers: [
|
|
1108
|
+
DialogService
|
|
1109
|
+
]
|
|
1110
|
+
}]
|
|
1111
|
+
}] });
|
|
1112
|
+
|
|
1113
|
+
function isPipe(o) {
|
|
1114
|
+
return typeof (o.transform) === 'function';
|
|
1115
|
+
}
|
|
1116
|
+
class TransformCreator {
|
|
1117
|
+
constructor(datePipe, currencyPipe, phonePipe, casePipe, config) {
|
|
1118
|
+
this.datePipe = datePipe;
|
|
1119
|
+
this.currencyPipe = currencyPipe;
|
|
1120
|
+
this.phonePipe = phonePipe;
|
|
1121
|
+
this.casePipe = casePipe;
|
|
1122
|
+
this.config = config;
|
|
1123
|
+
}
|
|
1124
|
+
createTransformer(metaData) {
|
|
1125
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
1126
|
+
if (metaData.transform) {
|
|
1127
|
+
if (isPipe(metaData.transform)) {
|
|
1128
|
+
return (value) => metaData.transform.transform(value[metaData.key]);
|
|
1129
|
+
}
|
|
1130
|
+
return metaData.transform;
|
|
1131
|
+
}
|
|
1132
|
+
if (this.config.transformers && this.config.transformers[metaData.fieldType]) {
|
|
1133
|
+
return this.config.transformers[metaData.fieldType];
|
|
1134
|
+
}
|
|
1135
|
+
switch (metaData.fieldType) {
|
|
1136
|
+
case FieldType.Date:
|
|
1137
|
+
const dateFormat = (_d = (_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.dateFormat) !== null && _b !== void 0 ? _b : (_c = this.config.defaultSettings) === null || _c === void 0 ? void 0 : _c.dateFormat) !== null && _d !== void 0 ? _d : 'shortDate';
|
|
1138
|
+
return (value) => this.datePipe.transform(value[metaData.key], dateFormat);
|
|
1139
|
+
case FieldType.Currency:
|
|
1140
|
+
return (value) => this.currencyPipe.transform(value[metaData.key]);
|
|
1141
|
+
case FieldType.PhoneNumber:
|
|
1142
|
+
return (value) => this.phonePipe.transform(value[metaData.key]);
|
|
1143
|
+
case FieldType.Enum:
|
|
1144
|
+
return (value) => { var _a; return this.casePipe.transform((_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.enumMap[value[metaData.key]]); };
|
|
1145
|
+
case FieldType.Boolean:
|
|
1146
|
+
let forTrue = 'check';
|
|
1147
|
+
let forFalse = '';
|
|
1148
|
+
if ((_f = (_e = metaData.additional) === null || _e === void 0 ? void 0 : _e.boolean) === null || _f === void 0 ? void 0 : _f.forTrue) {
|
|
1149
|
+
forTrue = metaData === null || metaData === void 0 ? void 0 : metaData.additional.boolean.forTrue.icon;
|
|
1150
|
+
}
|
|
1151
|
+
if (((_h = (_g = metaData.additional) === null || _g === void 0 ? void 0 : _g.boolean) === null || _h === void 0 ? void 0 : _h.showForFalse) === true) {
|
|
1152
|
+
forFalse = 'clear';
|
|
1153
|
+
}
|
|
1154
|
+
else if ((_l = (_k = (_j = metaData.additional) === null || _j === void 0 ? void 0 : _j.boolean) === null || _k === void 0 ? void 0 : _k.showForFalse) === null || _l === void 0 ? void 0 : _l.icon) {
|
|
1155
|
+
forFalse = (_p = (_o = (_m = metaData.additional) === null || _m === void 0 ? void 0 : _m.boolean) === null || _o === void 0 ? void 0 : _o.showForFalse) === null || _p === void 0 ? void 0 : _p.icon;
|
|
1156
|
+
}
|
|
1157
|
+
return (value) => value[metaData.key] ? forTrue : forFalse;
|
|
1158
|
+
}
|
|
1159
|
+
return (value) => value[metaData.key];
|
|
1160
|
+
}
|
|
1161
|
+
}
|
|
1162
|
+
TransformCreator.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: TransformCreator, deps: [{ token: i1$1.DatePipe }, { token: i1$1.CurrencyPipe }, { token: PhoneNumberPipe }, { token: SpaceCasePipe }, { token: TableBuilderConfigToken }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1163
|
+
TransformCreator.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: TransformCreator, providedIn: 'root' });
|
|
1164
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: TransformCreator, decorators: [{
|
|
1165
|
+
type: Injectable,
|
|
1166
|
+
args: [{
|
|
1167
|
+
providedIn: 'root',
|
|
1168
|
+
}]
|
|
1169
|
+
}], ctorParameters: function () {
|
|
1170
|
+
return [{ type: i1$1.DatePipe }, { type: i1$1.CurrencyPipe }, { type: PhoneNumberPipe }, { type: SpaceCasePipe }, { type: undefined, decorators: [{
|
|
1171
|
+
type: Inject,
|
|
1172
|
+
args: [TableBuilderConfigToken]
|
|
1173
|
+
}] }];
|
|
1174
|
+
} });
|
|
1175
|
+
|
|
1176
|
+
class GeneralTableSettings {
|
|
1177
|
+
constructor(settings) {
|
|
1178
|
+
this.headerSettings = new TableWrapperHeaderSettings();
|
|
1179
|
+
this.footerSettings = new TableWrapperFooterSettings();
|
|
1180
|
+
this.columnHeaderSettings = new TableColumnHeaderSettings();
|
|
1181
|
+
if (settings) {
|
|
1182
|
+
merge$1(this.headerSettings, settings.headerSettings);
|
|
1183
|
+
merge$1(this.footerSettings, settings.footerSettings);
|
|
1184
|
+
merge$1(this.columnHeaderSettings, settings.columnHeaderSettings);
|
|
1185
|
+
}
|
|
1186
|
+
}
|
|
1187
|
+
}
|
|
1188
|
+
class TableWrapperHeaderSettings {
|
|
1189
|
+
constructor() {
|
|
1190
|
+
this.hideExport = false;
|
|
1191
|
+
this.hideFilter = false;
|
|
1192
|
+
this.hideColumnSettings = false;
|
|
1193
|
+
this.hideHeader = false;
|
|
1194
|
+
this.hideSort = false;
|
|
1195
|
+
this.collapse = false;
|
|
1196
|
+
this.showTitleWhenCollapsed = true;
|
|
1197
|
+
}
|
|
1198
|
+
}
|
|
1199
|
+
class TableWrapperFooterSettings {
|
|
1200
|
+
constructor() {
|
|
1201
|
+
this.collapse = false;
|
|
1202
|
+
}
|
|
1203
|
+
}
|
|
1204
|
+
class TableColumnHeaderSettings {
|
|
1205
|
+
constructor() {
|
|
1206
|
+
this.noFilters = false;
|
|
1207
|
+
this.noHeader = false;
|
|
1208
|
+
}
|
|
1209
|
+
}
|
|
1210
|
+
class PesrsistedTableSettings {
|
|
1211
|
+
constructor(tableSettings) {
|
|
1212
|
+
var _a, _b, _c, _d;
|
|
1213
|
+
this.collapseHeader = false;
|
|
1214
|
+
this.collapseFooter = false;
|
|
1215
|
+
if (tableSettings) {
|
|
1216
|
+
this.collapseHeader = (_b = (_a = tableSettings.headerSettings) === null || _a === void 0 ? void 0 : _a.collapse) !== null && _b !== void 0 ? _b : tableSettings.collapseHeader;
|
|
1217
|
+
this.collapseFooter = (_d = (_c = tableSettings.footerSettings) === null || _c === void 0 ? void 0 : _c.collapse) !== null && _d !== void 0 ? _d : tableSettings.collapseFooter;
|
|
1218
|
+
}
|
|
1219
|
+
}
|
|
1220
|
+
}
|
|
1221
|
+
class NotPersisitedTableSettings {
|
|
1222
|
+
constructor(tableSettings) {
|
|
1223
|
+
this.hideExport = true;
|
|
1224
|
+
this.hideFilter = true;
|
|
1225
|
+
this.hideColumnSettings = true;
|
|
1226
|
+
this.hideSort = true;
|
|
1227
|
+
this.showTitleWhenHeaderCollapsed = true;
|
|
1228
|
+
this.hideHeader = true;
|
|
1229
|
+
this.hideColumnHeaderFilters = true;
|
|
1230
|
+
this.hideColumnHeader = true;
|
|
1231
|
+
if (tableSettings) {
|
|
1232
|
+
this.hideExport = tableSettings.headerSettings.hideExport;
|
|
1233
|
+
this.hideColumnSettings = tableSettings.headerSettings.hideColumnSettings;
|
|
1234
|
+
this.hideFilter = tableSettings.headerSettings.hideFilter;
|
|
1235
|
+
this.hideSort = tableSettings.headerSettings.hideSort;
|
|
1236
|
+
this.showTitleWhenHeaderCollapsed = tableSettings.headerSettings.showTitleWhenCollapsed;
|
|
1237
|
+
this.hideHeader = tableSettings.headerSettings.hideHeader;
|
|
1238
|
+
this.hideColumnHeaderFilters = tableSettings.columnHeaderSettings.noFilters;
|
|
1239
|
+
this.hideColumnHeader = tableSettings.columnHeaderSettings.noHeader;
|
|
1240
|
+
}
|
|
1241
|
+
}
|
|
1242
|
+
}
|
|
1243
|
+
|
|
1244
|
+
var InitializationState;
|
|
1245
|
+
(function (InitializationState) {
|
|
1246
|
+
InitializationState[InitializationState["Created"] = 0] = "Created";
|
|
1247
|
+
InitializationState[InitializationState["MetaDataLoaded"] = 1] = "MetaDataLoaded";
|
|
1248
|
+
InitializationState[InitializationState["LoadedFromStore"] = 2] = "LoadedFromStore";
|
|
1249
|
+
InitializationState[InitializationState["Ready"] = 3] = "Ready";
|
|
1250
|
+
})(InitializationState || (InitializationState = {}));
|
|
1251
|
+
const defaultTableState = {
|
|
1252
|
+
initializationState: InitializationState.Created,
|
|
1253
|
+
metaData: {},
|
|
1254
|
+
filters: {},
|
|
1255
|
+
hiddenKeys: [],
|
|
1256
|
+
sorted: [],
|
|
1257
|
+
userDefined: { order: {}, widths: {}, table: {} },
|
|
1258
|
+
persistedTableSettings: new PesrsistedTableSettings(),
|
|
1259
|
+
notPersisitedTableSettings: new NotPersisitedTableSettings(),
|
|
1260
|
+
pageSize: 10,
|
|
1261
|
+
};
|
|
1262
|
+
|
|
1263
|
+
var FilterType;
|
|
1264
|
+
(function (FilterType) {
|
|
1265
|
+
FilterType["NumberEquals"] = "Equals";
|
|
1266
|
+
FilterType["NumberNotEqual"] = "Does Not Equal";
|
|
1267
|
+
FilterType["NumberGreaterThan"] = "Greater Than";
|
|
1268
|
+
FilterType["NumberLessThan"] = "Less Than";
|
|
1269
|
+
FilterType["NumberBetween"] = "Between";
|
|
759
1270
|
FilterType["StringEquals"] = "Equals";
|
|
760
1271
|
FilterType["StringContains"] = "Contains";
|
|
761
1272
|
FilterType["StringDoesNotContain"] = "Does Not Contain";
|
|
@@ -1255,7 +1766,7 @@ ArrayColumnComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1255
1766
|
</ng-container>
|
|
1256
1767
|
</ng-container>
|
|
1257
1768
|
</ng-template>
|
|
1258
|
-
`, isInline: true, directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1769
|
+
`, isInline: true, directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1259
1770
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ArrayColumnComponent, decorators: [{
|
|
1260
1771
|
type: Component,
|
|
1261
1772
|
args: [{
|
|
@@ -1283,60 +1794,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
1283
1794
|
}, propDecorators: { array: [{
|
|
1284
1795
|
type: Input
|
|
1285
1796
|
}], metaData: [{
|
|
1286
|
-
type: Input
|
|
1287
|
-
}] } });
|
|
1288
|
-
|
|
1289
|
-
class FunctionPipe {
|
|
1290
|
-
transform(func, ...args) {
|
|
1291
|
-
if (typeof func === 'string') {
|
|
1292
|
-
const [instance, ...tail] = args;
|
|
1293
|
-
const method = instance[func].bind(instance);
|
|
1294
|
-
return method(...tail);
|
|
1295
|
-
}
|
|
1296
|
-
return func(...args);
|
|
1297
|
-
}
|
|
1298
|
-
}
|
|
1299
|
-
FunctionPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FunctionPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
1300
|
-
FunctionPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FunctionPipe, name: "func" });
|
|
1301
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FunctionPipe, decorators: [{
|
|
1302
|
-
type: Pipe,
|
|
1303
|
-
args: [{
|
|
1304
|
-
name: 'func'
|
|
1305
|
-
}]
|
|
1306
|
-
}] });
|
|
1307
|
-
|
|
1308
|
-
class SpaceCasePipe {
|
|
1309
|
-
transform(value) {
|
|
1310
|
-
return spaceCase(value);
|
|
1311
|
-
}
|
|
1312
|
-
}
|
|
1313
|
-
SpaceCasePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SpaceCasePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
1314
|
-
SpaceCasePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SpaceCasePipe, name: "spaceCase" });
|
|
1315
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SpaceCasePipe, decorators: [{
|
|
1316
|
-
type: Pipe,
|
|
1317
|
-
args: [{ name: 'spaceCase' }]
|
|
1318
|
-
}] });
|
|
1319
|
-
/**
|
|
1320
|
-
* Adds a space before uppercase letters that either
|
|
1321
|
-
* 1. follows a lowercase letter or digit
|
|
1322
|
-
* 2. or precedes a lowercase letter and follows an alpha-numeric character
|
|
1323
|
-
*
|
|
1324
|
-
* Uppercases the first digit
|
|
1325
|
-
*
|
|
1326
|
-
* Turns underscores into spaces
|
|
1327
|
-
*/
|
|
1328
|
-
function spaceCase(value) {
|
|
1329
|
-
return value === null || value === void 0 ? void 0 : value.replace(/(?<=[a-z0-9])([A-Z])|(?<=[a-zA-Z0-9])([A-Z])(?=[a-z])|_/g, ' $1$2').replace(/^./, str => str.toUpperCase());
|
|
1330
|
-
}
|
|
1797
|
+
type: Input
|
|
1798
|
+
}] } });
|
|
1331
1799
|
|
|
1332
1800
|
class InitializationComponent {
|
|
1333
1801
|
constructor() {
|
|
1334
|
-
this.forTrueIcon = (metaData) => { var _a, _b, _c; return ((_c = (_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.boolean) === null || _b === void 0 ? void 0 : _b.forTrue) === null || _c === void 0 ? void 0 : _c.icon) || 'check'; };
|
|
1335
|
-
this.forFalseIcon = (metaData) => {
|
|
1336
|
-
var _a, _b, _c, _d, _e;
|
|
1337
|
-
return ((_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.boolean) === null || _b === void 0 ? void 0 : _b.showForFalse) === true ? 'clear'
|
|
1338
|
-
: ((_e = (_d = (_c = metaData.additional) === null || _c === void 0 ? void 0 : _c.boolean) === null || _d === void 0 ? void 0 : _d.showForFalse) === null || _e === void 0 ? void 0 : _e.icon) || null;
|
|
1339
|
-
};
|
|
1340
1802
|
this.useRouterLink = (metaData) => { var _a, _b, _c; return ((_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.link) === null || _b === void 0 ? void 0 : _b.useRouterLink) || ((_c = metaData.additional) === null || _c === void 0 ? void 0 : _c.useRouterLink); };
|
|
1341
1803
|
this.target = (metaData) => { var _a, _b, _c; return ((_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.link) === null || _b === void 0 ? void 0 : _b.target) || ((_c = metaData.additional) === null || _c === void 0 ? void 0 : _c.target) || '_blank'; };
|
|
1342
1804
|
this.key = (metaData, element) => {
|
|
@@ -1346,32 +1808,23 @@ class InitializationComponent {
|
|
|
1346
1808
|
};
|
|
1347
1809
|
this.getLink = (metaData, element) => {
|
|
1348
1810
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
1349
|
-
const hasRoute = !!((_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.link) === null || _b === void 0 ? void 0 : _b.
|
|
1350
|
-
let link = hasRoute ? this.parseInterpolatedRoute(((_d = (_c = metaData.additional) === null || _c === void 0 ? void 0 : _c.link) === null || _d === void 0 ? void 0 : _d.
|
|
1811
|
+
const hasRoute = !!((_b = (_a = metaData.additional) === null || _a === void 0 ? void 0 : _a.link) === null || _b === void 0 ? void 0 : _b.interpolatedRoute);
|
|
1812
|
+
let link = hasRoute ? this.parseInterpolatedRoute(((_d = (_c = metaData.additional) === null || _c === void 0 ? void 0 : _c.link) === null || _d === void 0 ? void 0 : _d.interpolatedRoute), element) : (((_f = (_e = metaData.additional) === null || _e === void 0 ? void 0 : _e.link) === null || _f === void 0 ? void 0 : _f.base) || ((_g = metaData.additional) === null || _g === void 0 ? void 0 : _g.base));
|
|
1351
1813
|
if (!hasRoute) {
|
|
1352
|
-
link
|
|
1814
|
+
var needsSlash = !(link === null || link === void 0 ? void 0 : link.endsWith('/'));
|
|
1815
|
+
link += `${needsSlash ? '/' : ''}${this.key(metaData, element)}`;
|
|
1353
1816
|
}
|
|
1354
1817
|
return link;
|
|
1355
1818
|
};
|
|
1356
|
-
this.parseInterpolatedRoute = (route, element) => {
|
|
1357
|
-
let interpolated = (route === null || route === void 0 ? void 0 : route.interpolated) || '';
|
|
1358
|
-
const dict = (route === null || route === void 0 ? void 0 : route.params) || {};
|
|
1359
|
-
Object.keys(dict).forEach(key => {
|
|
1360
|
-
interpolated = interpolated.replace(`{${key}}`, element[dict[key]]);
|
|
1361
|
-
});
|
|
1362
|
-
return interpolated;
|
|
1363
|
-
};
|
|
1819
|
+
this.parseInterpolatedRoute = (route, element) => route.replace(/{([^}]+)}/g, (_, key) => element[key]);
|
|
1364
1820
|
}
|
|
1365
1821
|
}
|
|
1366
1822
|
InitializationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: InitializationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1367
|
-
InitializationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: InitializationComponent, selector: "ng-component", viewQueries: [{ propertyName: "
|
|
1823
|
+
InitializationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: InitializationComponent, selector: "ng-component", viewQueries: [{ propertyName: "linkTemplate", first: true, predicate: ["link"], descendants: true, static: true }, { propertyName: "imageUrlTemplate", first: true, predicate: ["imageUrl"], descendants: true, static: true }, { propertyName: "currencyTemplate", first: true, predicate: ["currency"], descendants: true, static: true }, { propertyName: "arrayTemplate", first: true, predicate: ["array"], descendants: true, static: true }, { propertyName: "defaultTemplate", first: true, predicate: ["default"], descendants: true, static: true }], ngImport: i0, template: "<ng-template #link let-element='element' let-metaData='metaData'>\n <a *ngIf=\"useRouterLink | func : metaData; else hrefLink\" target=\"{{target | func : metaData }}\"\n [routerLink]=\" [(getLink | func : metaData : element)]\">\n {{element[metaData.key]}}\n </a>\n <ng-template #hrefLink>\n <a target=\"{{target | func : metaData}}\"\n href=\"{{(getLink | func : metaData : element)}}\">\n {{element[metaData.key]}}\n </a>\n </ng-template>\n</ng-template>\n<ng-template #imageUrl let-element='element' let-metaData='metaData'>\n <span>\n <img src=\"{{element[metaData.key]}}\" height=\"75px\" width=\"75px\" />\n </span>\n</ng-template>\n\n<ng-template #array let-element='element' let-metaData='metaData'>\n <tb-array-column [array]='element[metaData.key]' [metaData]='metaData'></tb-array-column>\n</ng-template>\n\n<ng-template #default let-element='element' let-metaData='metaData' let-transform='transform' >\n <mat-icon *ngIf=\"metaData.useIcon\" >{{ transform | func : element }}</mat-icon>\n <span *ngIf=\"!metaData.useIcon\" >{{ transform | func : element }}</span>\n</ng-template>\n", components: [{ type: ArrayColumnComponent, selector: "tb-array-column", inputs: ["array", "metaData"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$1.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }], pipes: { "func": FunctionPipe } });
|
|
1368
1824
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: InitializationComponent, decorators: [{
|
|
1369
1825
|
type: Component,
|
|
1370
|
-
args: [{ template: "<ng-template #
|
|
1371
|
-
}], propDecorators: {
|
|
1372
|
-
type: ViewChild,
|
|
1373
|
-
args: ['boolean', { static: true }]
|
|
1374
|
-
}], linkTemplate: [{
|
|
1826
|
+
args: [{ template: "<ng-template #link let-element='element' let-metaData='metaData'>\n <a *ngIf=\"useRouterLink | func : metaData; else hrefLink\" target=\"{{target | func : metaData }}\"\n [routerLink]=\" [(getLink | func : metaData : element)]\">\n {{element[metaData.key]}}\n </a>\n <ng-template #hrefLink>\n <a target=\"{{target | func : metaData}}\"\n href=\"{{(getLink | func : metaData : element)}}\">\n {{element[metaData.key]}}\n </a>\n </ng-template>\n</ng-template>\n<ng-template #imageUrl let-element='element' let-metaData='metaData'>\n <span>\n <img src=\"{{element[metaData.key]}}\" height=\"75px\" width=\"75px\" />\n </span>\n</ng-template>\n\n<ng-template #array let-element='element' let-metaData='metaData'>\n <tb-array-column [array]='element[metaData.key]' [metaData]='metaData'></tb-array-column>\n</ng-template>\n\n<ng-template #default let-element='element' let-metaData='metaData' let-transform='transform' >\n <mat-icon *ngIf=\"metaData.useIcon\" >{{ transform | func : element }}</mat-icon>\n <span *ngIf=\"!metaData.useIcon\" >{{ transform | func : element }}</span>\n</ng-template>\n" }]
|
|
1827
|
+
}], propDecorators: { linkTemplate: [{
|
|
1375
1828
|
type: ViewChild,
|
|
1376
1829
|
args: ['link', { static: true }]
|
|
1377
1830
|
}], imageUrlTemplate: [{
|
|
@@ -1383,15 +1836,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
1383
1836
|
}], arrayTemplate: [{
|
|
1384
1837
|
type: ViewChild,
|
|
1385
1838
|
args: ['array', { static: true }]
|
|
1386
|
-
}], expressionTemplate: [{
|
|
1387
|
-
type: ViewChild,
|
|
1388
|
-
args: ['expression', { static: true }]
|
|
1389
1839
|
}], defaultTemplate: [{
|
|
1390
1840
|
type: ViewChild,
|
|
1391
1841
|
args: ['default', { static: true }]
|
|
1392
|
-
}], enumTemplate: [{
|
|
1393
|
-
type: ViewChild,
|
|
1394
|
-
args: ['enum', { static: true }]
|
|
1395
1842
|
}] } });
|
|
1396
1843
|
|
|
1397
1844
|
class TableTemplateService {
|
|
@@ -1404,17 +1851,17 @@ class TableTemplateService {
|
|
|
1404
1851
|
initTemplates() {
|
|
1405
1852
|
this.templates = {};
|
|
1406
1853
|
this.templates[FieldType.Array] = this.instance.arrayTemplate;
|
|
1407
|
-
this.templates[FieldType.Boolean] = this.instance.
|
|
1408
|
-
this.templates[FieldType.Currency] = this.instance.
|
|
1854
|
+
this.templates[FieldType.Boolean] = this.instance.defaultTemplate;
|
|
1855
|
+
this.templates[FieldType.Currency] = this.instance.defaultTemplate;
|
|
1409
1856
|
this.templates[FieldType.Date] = this.instance.defaultTemplate;
|
|
1410
|
-
this.templates[FieldType.Expression] = this.instance.
|
|
1857
|
+
this.templates[FieldType.Expression] = this.instance.defaultTemplate;
|
|
1411
1858
|
this.templates[FieldType.ImageUrl] = this.instance.imageUrlTemplate;
|
|
1412
1859
|
this.templates[FieldType.Link] = this.instance.linkTemplate;
|
|
1413
1860
|
this.templates[FieldType.Number] = this.instance.defaultTemplate;
|
|
1414
1861
|
this.templates[FieldType.PhoneNumber] = this.instance.defaultTemplate;
|
|
1415
1862
|
this.templates[FieldType.String] = this.instance.defaultTemplate;
|
|
1416
1863
|
this.templates[FieldType.Unknown] = this.instance.defaultTemplate;
|
|
1417
|
-
this.templates[FieldType.Enum] = this.instance.
|
|
1864
|
+
this.templates[FieldType.Enum] = this.instance.defaultTemplate;
|
|
1418
1865
|
}
|
|
1419
1866
|
getTemplate(fieldType) {
|
|
1420
1867
|
return this.templates[fieldType];
|
|
@@ -1427,29 +1874,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
1427
1874
|
args: [{ providedIn: 'root' }]
|
|
1428
1875
|
}], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.Injector }]; } });
|
|
1429
1876
|
|
|
1430
|
-
class StopPropagationDirective {
|
|
1431
|
-
onClick(event) {
|
|
1432
|
-
event.stopPropagation();
|
|
1433
|
-
}
|
|
1434
|
-
onMousedown(event) {
|
|
1435
|
-
event.stopPropagation();
|
|
1436
|
-
}
|
|
1437
|
-
}
|
|
1438
|
-
StopPropagationDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StopPropagationDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1439
|
-
StopPropagationDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: StopPropagationDirective, selector: "[stop-propagation]", host: { listeners: { "click": "onClick($event)", "mousedown": "onMousedown($event)" } }, ngImport: i0 });
|
|
1440
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StopPropagationDirective, decorators: [{
|
|
1441
|
-
type: Directive,
|
|
1442
|
-
args: [{
|
|
1443
|
-
selector: "[stop-propagation]"
|
|
1444
|
-
}]
|
|
1445
|
-
}], propDecorators: { onClick: [{
|
|
1446
|
-
type: HostListener,
|
|
1447
|
-
args: ["click", ["$event"]]
|
|
1448
|
-
}], onMousedown: [{
|
|
1449
|
-
type: HostListener,
|
|
1450
|
-
args: ["mousedown", ["$event"]]
|
|
1451
|
-
}] } });
|
|
1452
|
-
|
|
1453
1877
|
class InListFilterComponent {
|
|
1454
1878
|
constructor(ref, tableState) {
|
|
1455
1879
|
this.ref = ref;
|
|
@@ -1509,7 +1933,7 @@ InListFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
1509
1933
|
{{metaData.fieldType === FieldType.Enum ? (item.value | spaceCase) : item.value}}
|
|
1510
1934
|
</mat-checkbox>
|
|
1511
1935
|
</div>
|
|
1512
|
-
`, isInline: true, components: [{ type: i3.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }], directives: [{ type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }], pipes: { "keyvalue": i1.KeyValuePipe, "async": i1.AsyncPipe, "spaceCase": SpaceCasePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1936
|
+
`, isInline: true, components: [{ type: i3.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }], directives: [{ type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }], pipes: { "keyvalue": i1$1.KeyValuePipe, "async": i1$1.AsyncPipe, "spaceCase": SpaceCasePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1513
1937
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: InListFilterComponent, decorators: [{
|
|
1514
1938
|
type: Component,
|
|
1515
1939
|
args: [{
|
|
@@ -1592,7 +2016,7 @@ class HeaderMenuComponent {
|
|
|
1592
2016
|
}
|
|
1593
2017
|
}
|
|
1594
2018
|
HeaderMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: HeaderMenuComponent, deps: [{ token: TableStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
1595
|
-
HeaderMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: HeaderMenuComponent, selector: "tb-header-menu", inputs: { filter: "filter", metaData: "metaData" }, viewQueries: [{ propertyName: "trigger", first: true, predicate: MatMenuTrigger, descendants: true }], ngImport: i0, template: "<button mat-icon-button disableRipple [matMenuTriggerFor]=\"menu\" style=\"height:16px;\" [matMenuTriggerRestoreFocus]=\"false\">\r\n <mat-icon class=\"menu-icon\">more_vert</mat-icon>\r\n</button>\r\n<mat-menu #menu=\"matMenu\">\r\n <button mat-menu-item (click)=hideField(metaData.key)>\r\n <mat-icon color=\"primary\">visibility_off</mat-icon>\r\n <span>Hide Column</span>\r\n </button>\r\n <ng-form #myForm=\"ngForm\" [ngSwitch]=\"true\" (keydown.enter)=\"onEnter(myForm.value)\">\r\n <input type=\"hidden\" name=\"filterId\" [ngModel]=\"'header-column-' + metaData.key\" />\r\n <input type=\"hidden\" name=\"filterType\" [ngModel]=\"myFilterType\" />\r\n <input type=\"hidden\" name=\"key\" [ngModel]=\"metaData.key\" />\r\n <input type=\"hidden\" name=\"fieldType\" [ngModel]=\"metaData.fieldType\" />\r\n\r\n <ng-container *ngIf=\"(myFilterType === FilterType.Or || myFilterType === FilterType.In); else defaultFilter\">\r\n <tb-in-list-filter style=\"display:block;padding: 0 16px\" name='filterValue' [key]='metaData.key' [(ngModel)]='myFilterValue' >\r\n </tb-in-list-filter>\r\n </ng-container>\r\n\r\n\r\n <ng-template #defaultFilter>\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Link || metaData.fieldType === FieldType.String || metaData.fieldType === FieldType.Array || metaData.fieldType === FieldType.Unknown || metaData.fieldType === FieldType.PhoneNumber\">\r\n <mat-form-field stop-propagation class=\"font\" style=\"padding: 0 16px\">\r\n <mat-icon matPrefix class=\"search-icon\">search</mat-icon>\r\n <mat-label>{{myFilterType === FilterType.StringDoesNotContain ? 'Does Not Contain...' : 'Contains...'}}</mat-label>\r\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\r\n <span matSuffix [matTooltip]=\"myFilterType === FilterType.StringDoesNotContain ? 'Contains' : 'Does Not Contain'\">\r\n <button mat-icon-button color=\"primary\" (click)=\"setStringFilterType()\">\r\n <mat-icon [ngClass]=\"{'chosen-icon': myFilterType === FilterType.StringDoesNotContain }\">\r\n block\r\n </mat-icon>\r\n </button>\r\n </span>\r\n </mat-form-field>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Number || metaData.fieldType === FieldType.Currency\">\r\n <mat-form-field class=\"auto-width\" stop-propagation style=\"padding: 0 16px\">\r\n <mat-label>{{myFilterType === FilterType.NumberEquals ? 'Equals...' : myFilterType === FilterType.NumberLessThan ? 'Less Than...' : 'More Than...'}}</mat-label>\r\n <input matInput type='number' name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\r\n <span matPrefix>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.NumberLessThan)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberLessThan }\">\r\n arrow_back_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.NumberGreaterThan)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberGreaterThan }\">\r\n arrow_forward_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <span (click)=\"setFilterType(FilterType.NumberEquals)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberEquals }\">\r\n =</span>\r\n </button>\r\n </span>\r\n </mat-form-field>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Boolean\">\r\n <div style=\"padding: 0 16px\">\r\n <label>\r\n <mat-icon class=\"search-icon\">filter_list</mat-icon>\r\n </label>\r\n <mat-radio-group stop-propagation #ctrl=\"matRadioGroup\" #boolField='ngModel' class=\"font\" name=\"filterValue\" [ngModel]=\"myFilterValue\" >\r\n <mat-radio-button class=\"filter-radio-button\" (click)=\"myFilterValue = true;\" [value]=\"true\">True</mat-radio-button><br/>\r\n <mat-radio-button class=\"filter-radio-button\" (click)=\"myFilterValue = false\" [value]=\"false\">False</mat-radio-button><br/>\r\n </mat-radio-group>\r\n </div>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Date\">\r\n <mat-form-field style=\"padding: 0 16px\" class=\"font auto-width\" stop-propagation >\r\n <span matPrefix>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.DateOnOrAfter)\" class=\"suffix-icons underline\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateOnOrAfter }\">\r\n arrow_forward_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.DateOnOrBefore)\" class=\"suffix-icons underline\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateOnOrBefore }\">\r\n arrow_back_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <span (click)=\"setFilterType(FilterType.DateIsOn)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateIsOn }\">\r\n =</span>\r\n </button>\r\n </span>\r\n <mat-label>{{myFilterType === FilterType.DateIsOn ? 'On...' :\r\n myFilterType === FilterType.DateOnOrBefore ? 'On or Before...' : 'On or After...'}}</mat-label>\r\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" [matDatepicker]=\"calendar\"\r\n (click)=\"calendar.open()\"/>\r\n <mat-datepicker-toggle matSuffix [for]=\"calendar\" preventEnter></mat-datepicker-toggle>\r\n <mat-datepicker #calendar></mat-datepicker>\r\n </mat-form-field>\r\n </ng-container>\r\n </ng-template>\r\n\r\n <button mat-button (click)=\"onEnter(myForm.value)\" [disabled]=\"myForm.value.filterValue == undefined\" disableRipple>\r\n Apply\r\n </button>\r\n </ng-form>\r\n</mat-menu>\r\n", styles: ["input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}::ng-deep .form-field .mat-form-field-wrapper{padding-bottom:4px!important;padding-top:4px!important;margin-bottom:5px!important}.menu-icon{font-size:16px;line-height:16px!important;vertical-align:top!important}.search-icon{margin-right:16px;vertical-align:middle;height:24px;color:#0000008a;font-size:21px;line-height:1.125}.font{font-size:14px}.filter-radio-button:first-of-type{padding-left:0}.filter-radio-button{padding:10px 40px;min-width:110px}::ng-deep .form-field.mat-form-field-appearance-outline .mat-form-field-infix{padding:5px 0;width:auto}::ng-deep .auto-width .mat-form-field-infix{width:auto}.suffix-icons{font-size:14px;margin-left:6px}mat-icon.chosen-icon.mat-icon.suffix-icons,.chosen-icon{font-size:20px;color:green}mat-icon.mat-icon.suffix-icons.underline{-webkit-text-decoration:underline .1px solid;text-decoration:underline .1px solid;transform:scaleX(.7)}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { type: InListFilterComponent, selector: "tb-in-list-filter , [tb-in-list-filter]", inputs: ["key"] }, { type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i7.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i8.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { type: i8.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }], directives: [{ type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: i6.MatPrefix, selector: "[matPrefix]" }, { type: i6.MatLabel, selector: "mat-label" }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i6.MatSuffix, selector: "[matSuffix]" }, { type: i13.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i7.MatRadioGroup, selector: "mat-radio-group", exportAs: ["matRadioGroup"] }, { type: i8.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2019
|
+
HeaderMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: HeaderMenuComponent, selector: "tb-header-menu", inputs: { filter: "filter", metaData: "metaData" }, viewQueries: [{ propertyName: "trigger", first: true, predicate: MatMenuTrigger, descendants: true }], ngImport: i0, template: "<button mat-icon-button disableRipple [matMenuTriggerFor]=\"menu\" style=\"height:16px;\" [matMenuTriggerRestoreFocus]=\"false\">\r\n <mat-icon class=\"menu-icon\">more_vert</mat-icon>\r\n</button>\r\n<mat-menu #menu=\"matMenu\">\r\n <button mat-menu-item (click)=hideField(metaData.key)>\r\n <mat-icon color=\"primary\">visibility_off</mat-icon>\r\n <span>Hide Column</span>\r\n </button>\r\n <ng-form #myForm=\"ngForm\" [ngSwitch]=\"true\" (keydown.enter)=\"onEnter(myForm.value)\">\r\n <input type=\"hidden\" name=\"filterId\" [ngModel]=\"'header-column-' + metaData.key\" />\r\n <input type=\"hidden\" name=\"filterType\" [ngModel]=\"myFilterType\" />\r\n <input type=\"hidden\" name=\"key\" [ngModel]=\"metaData.key\" />\r\n <input type=\"hidden\" name=\"fieldType\" [ngModel]=\"metaData.fieldType\" />\r\n\r\n <ng-container *ngIf=\"(myFilterType === FilterType.Or || myFilterType === FilterType.In); else defaultFilter\">\r\n <tb-in-list-filter style=\"display:block;padding: 0 16px\" name='filterValue' [key]='metaData.key' [(ngModel)]='myFilterValue' >\r\n </tb-in-list-filter>\r\n </ng-container>\r\n\r\n\r\n <ng-template #defaultFilter>\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Link || metaData.fieldType === FieldType.String || metaData.fieldType === FieldType.Array || metaData.fieldType === FieldType.Unknown || metaData.fieldType === FieldType.PhoneNumber\">\r\n <mat-form-field stop-propagation class=\"font\" style=\"padding: 0 16px\">\r\n <mat-icon matPrefix class=\"search-icon\">search</mat-icon>\r\n <mat-label>{{myFilterType === FilterType.StringDoesNotContain ? 'Does Not Contain...' : 'Contains...'}}</mat-label>\r\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\r\n <span matSuffix [matTooltip]=\"myFilterType === FilterType.StringDoesNotContain ? 'Contains' : 'Does Not Contain'\">\r\n <button mat-icon-button color=\"primary\" (click)=\"setStringFilterType()\">\r\n <mat-icon [ngClass]=\"{'chosen-icon': myFilterType === FilterType.StringDoesNotContain }\">\r\n block\r\n </mat-icon>\r\n </button>\r\n </span>\r\n </mat-form-field>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Number || metaData.fieldType === FieldType.Currency\">\r\n <mat-form-field class=\"auto-width\" stop-propagation style=\"padding: 0 16px\">\r\n <mat-label>{{myFilterType === FilterType.NumberEquals ? 'Equals...' : myFilterType === FilterType.NumberLessThan ? 'Less Than...' : 'More Than...'}}</mat-label>\r\n <input matInput type='number' name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\r\n <span matPrefix>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.NumberLessThan)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberLessThan }\">\r\n arrow_back_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.NumberGreaterThan)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberGreaterThan }\">\r\n arrow_forward_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <span (click)=\"setFilterType(FilterType.NumberEquals)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberEquals }\">\r\n =</span>\r\n </button>\r\n </span>\r\n </mat-form-field>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Boolean\">\r\n <div style=\"padding: 0 16px\">\r\n <label>\r\n <mat-icon class=\"search-icon\">filter_list</mat-icon>\r\n </label>\r\n <mat-radio-group stop-propagation #ctrl=\"matRadioGroup\" #boolField='ngModel' class=\"font\" name=\"filterValue\" [ngModel]=\"myFilterValue\" >\r\n <mat-radio-button class=\"filter-radio-button\" (click)=\"myFilterValue = true;\" [value]=\"true\">True</mat-radio-button><br/>\r\n <mat-radio-button class=\"filter-radio-button\" (click)=\"myFilterValue = false\" [value]=\"false\">False</mat-radio-button><br/>\r\n </mat-radio-group>\r\n </div>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Date\">\r\n <mat-form-field style=\"padding: 0 16px\" class=\"font auto-width\" stop-propagation >\r\n <span matPrefix>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.DateOnOrAfter)\" class=\"suffix-icons underline\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateOnOrAfter }\">\r\n arrow_forward_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.DateOnOrBefore)\" class=\"suffix-icons underline\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateOnOrBefore }\">\r\n arrow_back_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <span (click)=\"setFilterType(FilterType.DateIsOn)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateIsOn }\">\r\n =</span>\r\n </button>\r\n </span>\r\n <mat-label>{{myFilterType === FilterType.DateIsOn ? 'On...' :\r\n myFilterType === FilterType.DateOnOrBefore ? 'On or Before...' : 'On or After...'}}</mat-label>\r\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" [matDatepicker]=\"calendar\"\r\n (click)=\"calendar.open()\"/>\r\n <mat-datepicker-toggle matSuffix [for]=\"calendar\" preventEnter></mat-datepicker-toggle>\r\n <mat-datepicker #calendar></mat-datepicker>\r\n </mat-form-field>\r\n </ng-container>\r\n </ng-template>\r\n\r\n <button mat-button (click)=\"onEnter(myForm.value)\" [disabled]=\"myForm.value.filterValue == undefined\" disableRipple>\r\n Apply\r\n </button>\r\n </ng-form>\r\n</mat-menu>\r\n", styles: ["input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}::ng-deep .form-field .mat-form-field-wrapper{padding-bottom:4px!important;padding-top:4px!important;margin-bottom:5px!important}.menu-icon{font-size:16px;line-height:16px!important;vertical-align:top!important}.search-icon{margin-right:16px;vertical-align:middle;height:24px;color:#0000008a;font-size:21px;line-height:1.125}.font{font-size:14px}.filter-radio-button:first-of-type{padding-left:0}.filter-radio-button{padding:10px 40px;min-width:110px}::ng-deep .form-field.mat-form-field-appearance-outline .mat-form-field-infix{padding:5px 0;width:auto}::ng-deep .auto-width .mat-form-field-infix{width:auto}.suffix-icons{font-size:14px;margin-left:6px}mat-icon.chosen-icon.mat-icon.suffix-icons,.chosen-icon{font-size:20px;color:green}mat-icon.mat-icon.suffix-icons.underline{-webkit-text-decoration:underline .1px solid;text-decoration:underline .1px solid;transform:scaleX(.7)}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { type: InListFilterComponent, selector: "tb-in-list-filter , [tb-in-list-filter]", inputs: ["key"] }, { type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i7.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i8.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { type: i8.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }], directives: [{ type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: i6.MatPrefix, selector: "[matPrefix]" }, { type: i6.MatLabel, selector: "mat-label" }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i6.MatSuffix, selector: "[matSuffix]" }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i7.MatRadioGroup, selector: "mat-radio-group", exportAs: ["matRadioGroup"] }, { type: i8.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1596
2020
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: HeaderMenuComponent, decorators: [{
|
|
1597
2021
|
type: Component,
|
|
1598
2022
|
args: [{ selector: 'tb-header-menu', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button mat-icon-button disableRipple [matMenuTriggerFor]=\"menu\" style=\"height:16px;\" [matMenuTriggerRestoreFocus]=\"false\">\r\n <mat-icon class=\"menu-icon\">more_vert</mat-icon>\r\n</button>\r\n<mat-menu #menu=\"matMenu\">\r\n <button mat-menu-item (click)=hideField(metaData.key)>\r\n <mat-icon color=\"primary\">visibility_off</mat-icon>\r\n <span>Hide Column</span>\r\n </button>\r\n <ng-form #myForm=\"ngForm\" [ngSwitch]=\"true\" (keydown.enter)=\"onEnter(myForm.value)\">\r\n <input type=\"hidden\" name=\"filterId\" [ngModel]=\"'header-column-' + metaData.key\" />\r\n <input type=\"hidden\" name=\"filterType\" [ngModel]=\"myFilterType\" />\r\n <input type=\"hidden\" name=\"key\" [ngModel]=\"metaData.key\" />\r\n <input type=\"hidden\" name=\"fieldType\" [ngModel]=\"metaData.fieldType\" />\r\n\r\n <ng-container *ngIf=\"(myFilterType === FilterType.Or || myFilterType === FilterType.In); else defaultFilter\">\r\n <tb-in-list-filter style=\"display:block;padding: 0 16px\" name='filterValue' [key]='metaData.key' [(ngModel)]='myFilterValue' >\r\n </tb-in-list-filter>\r\n </ng-container>\r\n\r\n\r\n <ng-template #defaultFilter>\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Link || metaData.fieldType === FieldType.String || metaData.fieldType === FieldType.Array || metaData.fieldType === FieldType.Unknown || metaData.fieldType === FieldType.PhoneNumber\">\r\n <mat-form-field stop-propagation class=\"font\" style=\"padding: 0 16px\">\r\n <mat-icon matPrefix class=\"search-icon\">search</mat-icon>\r\n <mat-label>{{myFilterType === FilterType.StringDoesNotContain ? 'Does Not Contain...' : 'Contains...'}}</mat-label>\r\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\r\n <span matSuffix [matTooltip]=\"myFilterType === FilterType.StringDoesNotContain ? 'Contains' : 'Does Not Contain'\">\r\n <button mat-icon-button color=\"primary\" (click)=\"setStringFilterType()\">\r\n <mat-icon [ngClass]=\"{'chosen-icon': myFilterType === FilterType.StringDoesNotContain }\">\r\n block\r\n </mat-icon>\r\n </button>\r\n </span>\r\n </mat-form-field>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Number || metaData.fieldType === FieldType.Currency\">\r\n <mat-form-field class=\"auto-width\" stop-propagation style=\"padding: 0 16px\">\r\n <mat-label>{{myFilterType === FilterType.NumberEquals ? 'Equals...' : myFilterType === FilterType.NumberLessThan ? 'Less Than...' : 'More Than...'}}</mat-label>\r\n <input matInput type='number' name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\r\n <span matPrefix>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.NumberLessThan)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberLessThan }\">\r\n arrow_back_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.NumberGreaterThan)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberGreaterThan }\">\r\n arrow_forward_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <span (click)=\"setFilterType(FilterType.NumberEquals)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.NumberEquals }\">\r\n =</span>\r\n </button>\r\n </span>\r\n </mat-form-field>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Boolean\">\r\n <div style=\"padding: 0 16px\">\r\n <label>\r\n <mat-icon class=\"search-icon\">filter_list</mat-icon>\r\n </label>\r\n <mat-radio-group stop-propagation #ctrl=\"matRadioGroup\" #boolField='ngModel' class=\"font\" name=\"filterValue\" [ngModel]=\"myFilterValue\" >\r\n <mat-radio-button class=\"filter-radio-button\" (click)=\"myFilterValue = true;\" [value]=\"true\">True</mat-radio-button><br/>\r\n <mat-radio-button class=\"filter-radio-button\" (click)=\"myFilterValue = false\" [value]=\"false\">False</mat-radio-button><br/>\r\n </mat-radio-group>\r\n </div>\r\n </ng-container>\r\n\r\n <ng-container *ngSwitchCase=\"metaData.fieldType === FieldType.Date\">\r\n <mat-form-field style=\"padding: 0 16px\" class=\"font auto-width\" stop-propagation >\r\n <span matPrefix>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.DateOnOrAfter)\" class=\"suffix-icons underline\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateOnOrAfter }\">\r\n arrow_forward_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <mat-icon (click)=\"setFilterType(FilterType.DateOnOrBefore)\" class=\"suffix-icons underline\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateOnOrBefore }\">\r\n arrow_back_ios</mat-icon>\r\n </button>\r\n <button mat-icon-button disableRipple>\r\n <span (click)=\"setFilterType(FilterType.DateIsOn)\" class=\"suffix-icons\"\r\n [ngClass]=\"{'chosen-icon': myFilterType === FilterType.DateIsOn }\">\r\n =</span>\r\n </button>\r\n </span>\r\n <mat-label>{{myFilterType === FilterType.DateIsOn ? 'On...' :\r\n myFilterType === FilterType.DateOnOrBefore ? 'On or Before...' : 'On or After...'}}</mat-label>\r\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" [matDatepicker]=\"calendar\"\r\n (click)=\"calendar.open()\"/>\r\n <mat-datepicker-toggle matSuffix [for]=\"calendar\" preventEnter></mat-datepicker-toggle>\r\n <mat-datepicker #calendar></mat-datepicker>\r\n </mat-form-field>\r\n </ng-container>\r\n </ng-template>\r\n\r\n <button mat-button (click)=\"onEnter(myForm.value)\" [disabled]=\"myForm.value.filterValue == undefined\" disableRipple>\r\n Apply\r\n </button>\r\n </ng-form>\r\n</mat-menu>\r\n", styles: ["input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}::ng-deep .form-field .mat-form-field-wrapper{padding-bottom:4px!important;padding-top:4px!important;margin-bottom:5px!important}.menu-icon{font-size:16px;line-height:16px!important;vertical-align:top!important}.search-icon{margin-right:16px;vertical-align:middle;height:24px;color:#0000008a;font-size:21px;line-height:1.125}.font{font-size:14px}.filter-radio-button:first-of-type{padding-left:0}.filter-radio-button{padding:10px 40px;min-width:110px}::ng-deep .form-field.mat-form-field-appearance-outline .mat-form-field-infix{padding:5px 0;width:auto}::ng-deep .auto-width .mat-form-field-infix{width:auto}.suffix-icons{font-size:14px;margin-left:6px}mat-icon.chosen-icon.mat-icon.suffix-icons,.chosen-icon{font-size:20px;color:green}mat-icon.mat-icon.suffix-icons.underline{-webkit-text-decoration:underline .1px solid;text-decoration:underline .1px solid;transform:scaleX(.7)}\n"] }]
|
|
@@ -1605,30 +2029,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
1605
2029
|
args: [MatMenuTrigger]
|
|
1606
2030
|
}] } });
|
|
1607
2031
|
|
|
1608
|
-
class StylerDirective {
|
|
1609
|
-
constructor(el) {
|
|
1610
|
-
this.el = el;
|
|
1611
|
-
}
|
|
1612
|
-
set styler(styles) {
|
|
1613
|
-
if (styles) {
|
|
1614
|
-
Object.keys(styles).forEach(style => {
|
|
1615
|
-
this.el.nativeElement.style[style] = styles[style];
|
|
1616
|
-
});
|
|
1617
|
-
}
|
|
1618
|
-
}
|
|
1619
|
-
;
|
|
1620
|
-
}
|
|
1621
|
-
StylerDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StylerDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
1622
|
-
StylerDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: StylerDirective, selector: "[styler]", inputs: { styler: "styler" }, ngImport: i0 });
|
|
1623
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: StylerDirective, decorators: [{
|
|
1624
|
-
type: Directive,
|
|
1625
|
-
args: [{
|
|
1626
|
-
selector: '[styler]',
|
|
1627
|
-
}]
|
|
1628
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { styler: [{
|
|
1629
|
-
type: Input
|
|
1630
|
-
}] } });
|
|
1631
|
-
|
|
1632
2032
|
class ResizeColumnDirective {
|
|
1633
2033
|
constructor(renderer, el, store) {
|
|
1634
2034
|
this.renderer = renderer;
|
|
@@ -1760,6 +2160,15 @@ class ColumnBuilderComponent {
|
|
|
1760
2160
|
}
|
|
1761
2161
|
ngOnInit() {
|
|
1762
2162
|
var _a, _b;
|
|
2163
|
+
if (this.metaData.fieldType === FieldType.Currency) {
|
|
2164
|
+
this.classes = Object.assign({ ['negative-currency']: (element) => element[this.metaData.key] < 0 }, this.metaData.classes);
|
|
2165
|
+
}
|
|
2166
|
+
else {
|
|
2167
|
+
this.classes = this.metaData.classes;
|
|
2168
|
+
}
|
|
2169
|
+
if (this.metaData.fieldType === FieldType.Boolean) {
|
|
2170
|
+
this.metaData = Object.assign(Object.assign({}, this.metaData), { useIcon: true });
|
|
2171
|
+
}
|
|
1763
2172
|
this.filter = { key: this.metaData.key, fieldType: this.metaData.fieldType };
|
|
1764
2173
|
const width$ = this.state.getUserDefinedWidth$(this.metaData.key).pipe(previousAndCurrent(0), map(this.mapWidth));
|
|
1765
2174
|
const fullMetaStyles = (_b = (_a = this.metaData.additional) === null || _a === void 0 ? void 0 : _a.styles) !== null && _b !== void 0 ? _b : {};
|
|
@@ -1787,14 +2196,14 @@ class ColumnBuilderComponent {
|
|
|
1787
2196
|
}
|
|
1788
2197
|
}
|
|
1789
2198
|
ColumnBuilderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ColumnBuilderComponent, deps: [{ token: TransformCreator }, { token: i3$2.MatTable }, { token: TableStore }, { token: TableTemplateService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1790
|
-
ColumnBuilderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: ColumnBuilderComponent, selector: "tb-column-builder", inputs: { metaData: "metaData", customCell: "customCell", data$: "data$" }, viewQueries: [{ propertyName: "columnDef", first: true, predicate: MatColumnDef, descendants: true }, { propertyName: "bodyTemplate", first: true, predicate: ["body"], descendants: true }], ngImport: i0, template: "<ng-container [matColumnDef]=\"metaData.key\" *ngrxLet=\"styles$ as styles\">\n\n <ng-template #body let-element='element' >\n
|
|
2199
|
+
ColumnBuilderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: ColumnBuilderComponent, selector: "tb-column-builder", inputs: { metaData: "metaData", customCell: "customCell", data$: "data$" }, viewQueries: [{ propertyName: "columnDef", first: true, predicate: MatColumnDef, descendants: true }, { propertyName: "bodyTemplate", first: true, predicate: ["body"], descendants: true }], ngImport: i0, template: "<ng-container [matColumnDef]=\"metaData.key\" *ngrxLet=\"styles$ as styles\" >\n\n <ng-template #body let-element='element' >\n <mat-cell [matTooltip]=\"metaData.toolTip ?? ''\" [conditionalClasses]='metaData.classes' [element]='element' [styler]='styles.body' [class.group-footer]=\"element.isGroupFooter\" (click)='cellClicked(element, metaData.key)' >\n <ng-container *ngTemplateOutlet=\"innerTemplate;context: {metaData: metaData, element: element, transform: transform }\">\n </ng-container>\n <span class=\"no-val\" *ngIf=\"\n !element.isGroupFooter &&\n metaData.fieldType !== FieldType.Expression &&\n (element[metaData.key] == null) &&\n !((customCell && customCell.TemplateRef) || metaData.template)\n \"> - </span>\n </mat-cell>\n\n </ng-template>\n\n <ng-template matHeaderCellDef #myHeader>\n\n <ng-container *ngIf=\"customCell?.columnDef?.headerCell;else header;\">\n <ng-container *ngTemplateOutlet=\"customCell.columnDef.headerCell.template; context: {metaData: metaData, styles: styles.header} \">\n </ng-container>\n </ng-container>\n\n <ng-template #header>\n\n <mat-header-cell cdkDrag [styler]='styles.header' [resizeColumn]=\"true\" [key]=\"metaData.key\" class=\"column-head drag-header\" #headref >\n <div class=\"header-container\" cdkDragHandle>\n <div *ngIf=\"!metaData._internalNotUserDefined || !customCell?.columnDef?.cell ; else headerWithoutMenu\" mat-sort-header style=\"width: 100%\">\n {{ metaData.displayName ? metaData.displayName : ( metaData.key | spaceCase ) }}\n </div>\n <ng-template #headerWithoutMenu >\n <div *ngIf=\"metaData._internalNotUserDefined;\" style=\"width: 100%\">\n {{ metaData.displayName ? metaData.displayName : ( metaData.key | spaceCase ) }}\n </div>\n </ng-template>\n <tb-header-menu\n *ngIf=\"(!metaData._internalNotUserDefined || !customCell?.columnDef?.cell) && (showfilters$ | async);\" #menu [metaData]='metaData' [filter]='filter' >\n </tb-header-menu>\n </div>\n </mat-header-cell>\n\n </ng-template>\n\n </ng-template>\n\n\n <ng-container *matCellDef=\"let element;\">\n <ng-container *ngTemplateOutlet=\"outerTemplate; context: {metaData: metaData, element: element , styles: styles.body }\">\n </ng-container>\n </ng-container>\n\n <ng-template matFooterCellDef>\n <ng-container *ngIf=\"customCell?.columnDef?.footerCell;else footer\">\n <ng-container\n *ngTemplateOutlet=\"customCell.columnDef.footerCell.template;context: {metaData: metaData, data: data$, styles : styles.footer }\">\n </ng-container>\n </ng-container>\n\n <ng-template #footer>\n <mat-footer-cell [styler]='styles.footer' *ngrxLet=\"data$ as data\">\n <span *ngIf=\"data?.length && metaData.additional?.footer\" [ngSwitch]=\"metaData.fieldType\" class=\"bold\">\n <span *ngSwitchCase=\"FieldType.Currency\">\n {{ data | columnTotal: metaData | currency }}\n </span>\n <span *ngSwitchCase=\"FieldType.Number\">\n {{ data | columnTotal: metaData | number }}\n </span>\n </span>\n </mat-footer-cell>\n </ng-template>\n </ng-template>\n</ng-container>\n", styles: [".header-container{display:flex;flex-direction:row;width:100%;align-items:center}.negative-currency{color:red}.column-head{position:relative}.bold,.group-footer{font-weight:900}.cdk-drag-preview{background:white;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:33%;border-right-width:0px}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.drag-handle{color:#add8e6;cursor:move;margin-right:9px}\n"], components: [{ type: i1$2.MatSortHeader, selector: "[mat-sort-header]", inputs: ["disabled", "mat-sort-header", "arrowPosition", "start", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { type: HeaderMenuComponent, selector: "tb-header-menu", inputs: ["filter", "metaData"] }], directives: [{ type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i3$2.MatColumnDef, selector: "[matColumnDef]", inputs: ["sticky", "matColumnDef"] }, { type: i3$2.MatCell, selector: "mat-cell, td[mat-cell]" }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: ConditionalClassesDirective, selector: "[conditionalClasses]", inputs: ["element", "conditionalClasses"] }, { type: StylerDirective, selector: "[styler]", inputs: ["styler"] }, { type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$2.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { type: i3$2.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { type: i12.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: ResizeColumnDirective, selector: "[resizeColumn]", inputs: ["resizeColumn", "key"] }, { type: i12.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { type: i3$2.MatCellDef, selector: "[matCellDef]" }, { type: i3$2.MatFooterCellDef, selector: "[matFooterCellDef]" }, { type: i3$2.MatFooterCell, selector: "mat-footer-cell, td[mat-footer-cell]" }, { type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], pipes: { "spaceCase": SpaceCasePipe, "async": i1$1.AsyncPipe, "currency": i1$1.CurrencyPipe, "columnTotal": ColumnTotalPipe, "number": i1$1.DecimalPipe }, viewProviders: [
|
|
1791
2200
|
{ provide: CDK_DROP_LIST, useExisting: CdkDropList },
|
|
1792
2201
|
], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1793
2202
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ColumnBuilderComponent, decorators: [{
|
|
1794
2203
|
type: Component,
|
|
1795
2204
|
args: [{ selector: 'tb-column-builder', changeDetection: ChangeDetectionStrategy.OnPush, viewProviders: [
|
|
1796
2205
|
{ provide: CDK_DROP_LIST, useExisting: CdkDropList },
|
|
1797
|
-
], template: "<ng-container [matColumnDef]=\"metaData.key\" *ngrxLet=\"styles$ as styles\">\n\n <ng-template #body let-element='element' >\n
|
|
2206
|
+
], template: "<ng-container [matColumnDef]=\"metaData.key\" *ngrxLet=\"styles$ as styles\" >\n\n <ng-template #body let-element='element' >\n <mat-cell [matTooltip]=\"metaData.toolTip ?? ''\" [conditionalClasses]='metaData.classes' [element]='element' [styler]='styles.body' [class.group-footer]=\"element.isGroupFooter\" (click)='cellClicked(element, metaData.key)' >\n <ng-container *ngTemplateOutlet=\"innerTemplate;context: {metaData: metaData, element: element, transform: transform }\">\n </ng-container>\n <span class=\"no-val\" *ngIf=\"\n !element.isGroupFooter &&\n metaData.fieldType !== FieldType.Expression &&\n (element[metaData.key] == null) &&\n !((customCell && customCell.TemplateRef) || metaData.template)\n \"> - </span>\n </mat-cell>\n\n </ng-template>\n\n <ng-template matHeaderCellDef #myHeader>\n\n <ng-container *ngIf=\"customCell?.columnDef?.headerCell;else header;\">\n <ng-container *ngTemplateOutlet=\"customCell.columnDef.headerCell.template; context: {metaData: metaData, styles: styles.header} \">\n </ng-container>\n </ng-container>\n\n <ng-template #header>\n\n <mat-header-cell cdkDrag [styler]='styles.header' [resizeColumn]=\"true\" [key]=\"metaData.key\" class=\"column-head drag-header\" #headref >\n <div class=\"header-container\" cdkDragHandle>\n <div *ngIf=\"!metaData._internalNotUserDefined || !customCell?.columnDef?.cell ; else headerWithoutMenu\" mat-sort-header style=\"width: 100%\">\n {{ metaData.displayName ? metaData.displayName : ( metaData.key | spaceCase ) }}\n </div>\n <ng-template #headerWithoutMenu >\n <div *ngIf=\"metaData._internalNotUserDefined;\" style=\"width: 100%\">\n {{ metaData.displayName ? metaData.displayName : ( metaData.key | spaceCase ) }}\n </div>\n </ng-template>\n <tb-header-menu\n *ngIf=\"(!metaData._internalNotUserDefined || !customCell?.columnDef?.cell) && (showfilters$ | async);\" #menu [metaData]='metaData' [filter]='filter' >\n </tb-header-menu>\n </div>\n </mat-header-cell>\n\n </ng-template>\n\n </ng-template>\n\n\n <ng-container *matCellDef=\"let element;\">\n <ng-container *ngTemplateOutlet=\"outerTemplate; context: {metaData: metaData, element: element , styles: styles.body }\">\n </ng-container>\n </ng-container>\n\n <ng-template matFooterCellDef>\n <ng-container *ngIf=\"customCell?.columnDef?.footerCell;else footer\">\n <ng-container\n *ngTemplateOutlet=\"customCell.columnDef.footerCell.template;context: {metaData: metaData, data: data$, styles : styles.footer }\">\n </ng-container>\n </ng-container>\n\n <ng-template #footer>\n <mat-footer-cell [styler]='styles.footer' *ngrxLet=\"data$ as data\">\n <span *ngIf=\"data?.length && metaData.additional?.footer\" [ngSwitch]=\"metaData.fieldType\" class=\"bold\">\n <span *ngSwitchCase=\"FieldType.Currency\">\n {{ data | columnTotal: metaData | currency }}\n </span>\n <span *ngSwitchCase=\"FieldType.Number\">\n {{ data | columnTotal: metaData | number }}\n </span>\n </span>\n </mat-footer-cell>\n </ng-template>\n </ng-template>\n</ng-container>\n", styles: [".header-container{display:flex;flex-direction:row;width:100%;align-items:center}.negative-currency{color:red}.column-head{position:relative}.bold,.group-footer{font-weight:900}.cdk-drag-preview{background:white;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:33%;border-right-width:0px}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.drag-handle{color:#add8e6;cursor:move;margin-right:9px}\n"] }]
|
|
1798
2207
|
}], ctorParameters: function () { return [{ type: TransformCreator }, { type: i3$2.MatTable }, { type: TableStore }, { type: TableTemplateService }]; }, propDecorators: { metaData: [{
|
|
1799
2208
|
type: Input
|
|
1800
2209
|
}], customCell: [{
|
|
@@ -1857,7 +2266,7 @@ class PaginatorComponent {
|
|
|
1857
2266
|
this.collapseFooter$ = this.state.state$.pipe(map(state => state.persistedTableSettings.collapseFooter));
|
|
1858
2267
|
}
|
|
1859
2268
|
ngAfterViewInit() {
|
|
1860
|
-
this.currentPageData$ = merge
|
|
2269
|
+
this.currentPageData$ = merge(this.paginator.page.pipe(map(mapPaginationEventToCurrentPageDetails)), this.data$.pipe(distinctUntilKeyChanged("length"), delayToAllowForProperUpdate, map(updateCurrentPageDetailsOnDataLengthChange(this.paginator))));
|
|
1861
2270
|
}
|
|
1862
2271
|
paginatorChange() {
|
|
1863
2272
|
if (!this.ourPageEvent) {
|
|
@@ -1876,7 +2285,7 @@ PaginatorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ver
|
|
|
1876
2285
|
<mat-paginator [pageSizeOptions]="[5, 10, 20, 50, 100, 500]" showFirstLastButtons (page)="paginatorChange()"
|
|
1877
2286
|
[ngClass]="{'hide' : (collapseFooter$ | async)}">
|
|
1878
2287
|
</mat-paginator>
|
|
1879
|
-
`, isInline: true, styles: [".mat-row:nth-child(odd){background-color:#cdeefe}.sticky{bottom:0px;position:sticky;border-top:.5px solid rgba(0,0,0,.12)}.page-amounts{color:#0000008a;font-family:Roboto,Helvetica Neue,sans-serif;font-size:12px;margin-right:.2rem}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;background-color:#fff}:host::ng-deep .mat-paginator-container{min-height:initial!important}:host::ng-deep .mat-paginator-container .mat-form-field-infix{padding:0!important}.group-header{font-weight:700;font-size:20px}:host::ng-deep .table-drag-list.cdk-drop-list-dragging .drag-header:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"], components: [{ type: i2.MatPaginator, selector: "mat-paginator", inputs: ["disabled"], exportAs: ["matPaginator"] }], directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], pipes: { "async": i1.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2288
|
+
`, isInline: true, styles: [".mat-row:nth-child(odd){background-color:#cdeefe}.sticky{bottom:0px;position:sticky;border-top:.5px solid rgba(0,0,0,.12)}.page-amounts{color:#0000008a;font-family:Roboto,Helvetica Neue,sans-serif;font-size:12px;margin-right:.2rem}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;background-color:#fff}:host::ng-deep .mat-paginator-container{min-height:initial!important}:host::ng-deep .mat-paginator-container .mat-form-field-infix{padding:0!important}.group-header{font-weight:700;font-size:20px}:host::ng-deep .table-drag-list.cdk-drop-list-dragging .drag-header:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"], components: [{ type: i2.MatPaginator, selector: "mat-paginator", inputs: ["disabled"], exportAs: ["matPaginator"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], pipes: { "async": i1$1.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1880
2289
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: PaginatorComponent, decorators: [{
|
|
1881
2290
|
type: Component,
|
|
1882
2291
|
args: [{ selector: 'tb-paginator', template: `
|
|
@@ -1905,7 +2314,7 @@ const mapPaginationEventToCurrentPageDetails = (pageData) => ({
|
|
|
1905
2314
|
const updateCurrentPageDetailsOnDataLengthChange = (paginator) => () => ({ currentStart: (paginator.pageIndex * paginator.pageSize) + 1,
|
|
1906
2315
|
currentEnd: Math.min(paginator.length, ((paginator.pageIndex + 1) * paginator.pageSize)),
|
|
1907
2316
|
total: paginator.length });
|
|
1908
|
-
const delayToAllowForProperUpdate = delay(0, asyncScheduler);
|
|
2317
|
+
const delayToAllowForProperUpdate = delay$1(0, asyncScheduler);
|
|
1909
2318
|
const metaDataPageSizeChange = (state) => state.state$.pipe(map(state => state.pageSize), distinct());
|
|
1910
2319
|
const setPaginatorPageSize = (paginator) => (pageSize) => paginator._changePageSize(pageSize);
|
|
1911
2320
|
const onPagiantorPageSizeChange = (paginator) => paginator.page.pipe(map(e => e.pageSize), distinct());
|
|
@@ -2045,12 +2454,12 @@ class GenericTableComponent {
|
|
|
2045
2454
|
this.selection.select(...this.dataSource.data);
|
|
2046
2455
|
}
|
|
2047
2456
|
}
|
|
2048
|
-
GenericTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenericTableComponent, deps: [{ token: i1$
|
|
2049
|
-
GenericTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: GenericTableComponent, selector: "tb-generic-table", inputs: { data$: "data$", IndexColumn: "IndexColumn", SelectionColumn: "SelectionColumn", trackBy: "trackBy", rows: "rows", isSticky: "isSticky", columnBuilders: "columnBuilders", columnInfos: "columnInfos", disableSort: "disableSort" }, outputs: { selection$: "selection$" }, viewQueries: [{ propertyName: "table", first: true, predicate: MatTable, descendants: true, static: true }, { propertyName: "dropList", first: true, predicate: CdkDropList, descendants: true, static: true }, { propertyName: "tableElRef", first: true, predicate: ["table"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<mat-table\n cdkDropList\n cdkDropListLockAxis='x'\n cdkDropListOrientation=\"horizontal\"\n (cdkDropListDropped)=\"drop($event)\"\n class=\"table-drag-list\"\n #table\n [dataSource]=\"dataSource\"\n [trackBy]='trackByFunction'\n [styler]=\"tableWidth | async\"\n>\n\n <ng-container matColumnDef=\"select\">\n\n <mat-header-cell *matHeaderCellDef class=\"f-mat-header-cell\" style=\"flex: 0 0 30px;\" >\n <mat-checkbox (change)=\"$event ? masterToggle() : null\"\n [checked]=\"!!(masterToggleChecked$ | async)\"\n [indeterminate]=\"masterToggleIndeterminate$ | async\">\n </mat-checkbox>\n </mat-header-cell>\n\n <mat-cell *matCellDef=\"let row\" style=\"flex: 0 0 30px;\">\n <mat-checkbox *ngIf=\"!row.isGroupFooter\"\n (click)=\"$event.stopPropagation()\"\n (change)=\"$event ? selection.toggle(row) : null\"\n [checked]=\"selection.isSelected(row)\">\n </mat-checkbox>\n </mat-cell>\n\n <mat-footer-cell *matFooterCellDef style=\"flex: 0 0 30px;\">\n {{ selection.selected.length }}\n </mat-footer-cell>\n </ng-container>\n\n <ng-container matColumnDef=\"index\">\n <mat-header-cell *matHeaderCellDef class=\"f-mat-header-cell\" >#</mat-header-cell>\n <mat-cell *matCellDef=\"let i = index;\"> {{ (tbPaginator.paginator.pageIndex * tbPaginator.paginator.pageSize) + i + 1 }} </mat-cell>\n <mat-footer-cell *matFooterCellDef></mat-footer-cell>\n\n </ng-container>\n\n <ng-container matColumnDef=\"groupHeader\">\n <mat-cell *matCellDef=\"let row\" class=\"group-header\">\n {{row.groupHeaderName}}\n </mat-cell>\n </ng-container>\n\n <ng-container *ngIf=\"showHeader$ | async\">\n <mat-header-row *matHeaderRowDef=\"keys; sticky: isSticky\"></mat-header-row>\n </ng-container>\n <mat-row *matRowDef=\"let row; columns: keys; let i = index\"></mat-row>\n <mat-row *matRowDef=\"let row; columns: ['groupHeader']; when: isGroupHeader\" style=\"background-color: lightgray;\"></mat-row>\n <mat-row *matRowDef=\"let row; columns: keys; when: isGroupFooter\" style=\"background-color: whitesmoke;\"></mat-row>\n <mat-footer-row *matFooterRowDef=\"keys\"></mat-footer-row>\n\n</mat-table>\n\n<div class=\"flx-row-end sticky\">\n <tb-paginator #tbPaginator\n [dataSource]=\"dataSource\"\n [tableElRef]=\"tableElRef\"\n [data$]=\"data$\">\n </tb-paginator>\n\n <mat-icon [matTooltip]=\"(collapseFooter$ | async) ? 'expand' : 'collapse'\" class=\"collapse-icon footer\" (click)=\"state.toggleCollapseFooter()\">\n {{(collapseFooter$ | async) ? 'expand_more' : 'expand_less'}}\n </mat-icon>\n</div>\n", styles: [".mat-row:nth-child(odd){background-color:#cdeefe}.sticky{bottom:0px;position:sticky;border-top:.5px solid rgba(0,0,0,.12)}.page-amounts{color:#0000008a;font-family:Roboto,Helvetica Neue,sans-serif;font-size:12px;margin-right:.2rem}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;background-color:#fff}:host::ng-deep .mat-paginator-container{min-height:initial!important}:host::ng-deep .mat-paginator-container .mat-form-field-infix{padding:0!important}.group-header{font-weight:700;font-size:20px}:host::ng-deep .table-drag-list.cdk-drop-list-dragging .drag-header:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"], components: [{ type: i3$2.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { type: i3.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { type: i3$2.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { type: i3$2.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { type: i3$2.MatFooterRow, selector: "mat-footer-row, tr[mat-footer-row]", exportAs: ["matFooterRow"] }, { type: PaginatorComponent, selector: "tb-paginator", inputs: ["dataSource", "tableElRef", "data$"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type:
|
|
2457
|
+
GenericTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenericTableComponent, deps: [{ token: i1$2.MatSort }, { token: TableStore }, { token: i0.ViewContainerRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
2458
|
+
GenericTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: GenericTableComponent, selector: "tb-generic-table", inputs: { data$: "data$", IndexColumn: "IndexColumn", SelectionColumn: "SelectionColumn", trackBy: "trackBy", rows: "rows", isSticky: "isSticky", columnBuilders: "columnBuilders", columnInfos: "columnInfos", disableSort: "disableSort" }, outputs: { selection$: "selection$" }, viewQueries: [{ propertyName: "table", first: true, predicate: MatTable, descendants: true, static: true }, { propertyName: "dropList", first: true, predicate: CdkDropList, descendants: true, static: true }, { propertyName: "tableElRef", first: true, predicate: ["table"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: "<mat-table\n cdkDropList\n cdkDropListLockAxis='x'\n cdkDropListOrientation=\"horizontal\"\n (cdkDropListDropped)=\"drop($event)\"\n class=\"table-drag-list\"\n #table\n [dataSource]=\"dataSource\"\n [trackBy]='trackByFunction'\n [styler]=\"tableWidth | async\"\n>\n\n <ng-container matColumnDef=\"select\">\n\n <mat-header-cell *matHeaderCellDef class=\"f-mat-header-cell\" style=\"flex: 0 0 30px;\" >\n <mat-checkbox (change)=\"$event ? masterToggle() : null\"\n [checked]=\"!!(masterToggleChecked$ | async)\"\n [indeterminate]=\"masterToggleIndeterminate$ | async\">\n </mat-checkbox>\n </mat-header-cell>\n\n <mat-cell *matCellDef=\"let row\" style=\"flex: 0 0 30px;\">\n <mat-checkbox *ngIf=\"!row.isGroupFooter\"\n (click)=\"$event.stopPropagation()\"\n (change)=\"$event ? selection.toggle(row) : null\"\n [checked]=\"selection.isSelected(row)\">\n </mat-checkbox>\n </mat-cell>\n\n <mat-footer-cell *matFooterCellDef style=\"flex: 0 0 30px;\">\n {{ selection.selected.length }}\n </mat-footer-cell>\n </ng-container>\n\n <ng-container matColumnDef=\"index\">\n <mat-header-cell *matHeaderCellDef class=\"f-mat-header-cell\" >#</mat-header-cell>\n <mat-cell *matCellDef=\"let i = index;\"> {{ (tbPaginator.paginator.pageIndex * tbPaginator.paginator.pageSize) + i + 1 }} </mat-cell>\n <mat-footer-cell *matFooterCellDef></mat-footer-cell>\n\n </ng-container>\n\n <ng-container matColumnDef=\"groupHeader\">\n <mat-cell *matCellDef=\"let row\" class=\"group-header\">\n {{row.groupHeaderName}}\n </mat-cell>\n </ng-container>\n\n <ng-container *ngIf=\"showHeader$ | async\">\n <mat-header-row *matHeaderRowDef=\"keys; sticky: isSticky\"></mat-header-row>\n </ng-container>\n <mat-row *matRowDef=\"let row; columns: keys; let i = index\"></mat-row>\n <mat-row *matRowDef=\"let row; columns: ['groupHeader']; when: isGroupHeader\" style=\"background-color: lightgray;\"></mat-row>\n <mat-row *matRowDef=\"let row; columns: keys; when: isGroupFooter\" style=\"background-color: whitesmoke;\"></mat-row>\n <mat-footer-row *matFooterRowDef=\"keys\"></mat-footer-row>\n\n</mat-table>\n\n<div class=\"flx-row-end sticky\">\n <tb-paginator #tbPaginator\n [dataSource]=\"dataSource\"\n [tableElRef]=\"tableElRef\"\n [data$]=\"data$\">\n </tb-paginator>\n\n <mat-icon [matTooltip]=\"(collapseFooter$ | async) ? 'expand' : 'collapse'\" class=\"collapse-icon footer\" (click)=\"state.toggleCollapseFooter()\">\n {{(collapseFooter$ | async) ? 'expand_more' : 'expand_less'}}\n </mat-icon>\n</div>\n", styles: [".mat-row:nth-child(odd){background-color:#cdeefe}.sticky{bottom:0px;position:sticky;border-top:.5px solid rgba(0,0,0,.12)}.page-amounts{color:#0000008a;font-family:Roboto,Helvetica Neue,sans-serif;font-size:12px;margin-right:.2rem}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;background-color:#fff}:host::ng-deep .mat-paginator-container{min-height:initial!important}:host::ng-deep .mat-paginator-container .mat-form-field-infix{padding:0!important}.group-header{font-weight:700;font-size:20px}:host::ng-deep .table-drag-list.cdk-drop-list-dragging .drag-header:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"], components: [{ type: i3$2.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { type: i3.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { type: i3$2.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { type: i3$2.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { type: i3$2.MatFooterRow, selector: "mat-footer-row, tr[mat-footer-row]", exportAs: ["matFooterRow"] }, { type: PaginatorComponent, selector: "tb-paginator", inputs: ["dataSource", "tableElRef", "data$"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i12.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: StylerDirective, selector: "[styler]", inputs: ["styler"] }, { type: i3$2.MatColumnDef, selector: "[matColumnDef]", inputs: ["sticky", "matColumnDef"] }, { type: i3$2.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { type: i3$2.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { type: i3$2.MatCellDef, selector: "[matCellDef]" }, { type: i3$2.MatCell, selector: "mat-cell, td[mat-cell]" }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$2.MatFooterCellDef, selector: "[matFooterCellDef]" }, { type: i3$2.MatFooterCell, selector: "mat-footer-cell, td[mat-footer-cell]" }, { type: i3$2.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { type: i3$2.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { type: i3$2.MatFooterRowDef, selector: "[matFooterRowDef]", inputs: ["matFooterRowDef", "matFooterRowDefSticky"] }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }], pipes: { "async": i1$1.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2050
2459
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenericTableComponent, decorators: [{
|
|
2051
2460
|
type: Component,
|
|
2052
2461
|
args: [{ selector: 'tb-generic-table', changeDetection: ChangeDetectionStrategy.OnPush, template: "<mat-table\n cdkDropList\n cdkDropListLockAxis='x'\n cdkDropListOrientation=\"horizontal\"\n (cdkDropListDropped)=\"drop($event)\"\n class=\"table-drag-list\"\n #table\n [dataSource]=\"dataSource\"\n [trackBy]='trackByFunction'\n [styler]=\"tableWidth | async\"\n>\n\n <ng-container matColumnDef=\"select\">\n\n <mat-header-cell *matHeaderCellDef class=\"f-mat-header-cell\" style=\"flex: 0 0 30px;\" >\n <mat-checkbox (change)=\"$event ? masterToggle() : null\"\n [checked]=\"!!(masterToggleChecked$ | async)\"\n [indeterminate]=\"masterToggleIndeterminate$ | async\">\n </mat-checkbox>\n </mat-header-cell>\n\n <mat-cell *matCellDef=\"let row\" style=\"flex: 0 0 30px;\">\n <mat-checkbox *ngIf=\"!row.isGroupFooter\"\n (click)=\"$event.stopPropagation()\"\n (change)=\"$event ? selection.toggle(row) : null\"\n [checked]=\"selection.isSelected(row)\">\n </mat-checkbox>\n </mat-cell>\n\n <mat-footer-cell *matFooterCellDef style=\"flex: 0 0 30px;\">\n {{ selection.selected.length }}\n </mat-footer-cell>\n </ng-container>\n\n <ng-container matColumnDef=\"index\">\n <mat-header-cell *matHeaderCellDef class=\"f-mat-header-cell\" >#</mat-header-cell>\n <mat-cell *matCellDef=\"let i = index;\"> {{ (tbPaginator.paginator.pageIndex * tbPaginator.paginator.pageSize) + i + 1 }} </mat-cell>\n <mat-footer-cell *matFooterCellDef></mat-footer-cell>\n\n </ng-container>\n\n <ng-container matColumnDef=\"groupHeader\">\n <mat-cell *matCellDef=\"let row\" class=\"group-header\">\n {{row.groupHeaderName}}\n </mat-cell>\n </ng-container>\n\n <ng-container *ngIf=\"showHeader$ | async\">\n <mat-header-row *matHeaderRowDef=\"keys; sticky: isSticky\"></mat-header-row>\n </ng-container>\n <mat-row *matRowDef=\"let row; columns: keys; let i = index\"></mat-row>\n <mat-row *matRowDef=\"let row; columns: ['groupHeader']; when: isGroupHeader\" style=\"background-color: lightgray;\"></mat-row>\n <mat-row *matRowDef=\"let row; columns: keys; when: isGroupFooter\" style=\"background-color: whitesmoke;\"></mat-row>\n <mat-footer-row *matFooterRowDef=\"keys\"></mat-footer-row>\n\n</mat-table>\n\n<div class=\"flx-row-end sticky\">\n <tb-paginator #tbPaginator\n [dataSource]=\"dataSource\"\n [tableElRef]=\"tableElRef\"\n [data$]=\"data$\">\n </tb-paginator>\n\n <mat-icon [matTooltip]=\"(collapseFooter$ | async) ? 'expand' : 'collapse'\" class=\"collapse-icon footer\" (click)=\"state.toggleCollapseFooter()\">\n {{(collapseFooter$ | async) ? 'expand_more' : 'expand_less'}}\n </mat-icon>\n</div>\n", styles: [".mat-row:nth-child(odd){background-color:#cdeefe}.sticky{bottom:0px;position:sticky;border-top:.5px solid rgba(0,0,0,.12)}.page-amounts{color:#0000008a;font-family:Roboto,Helvetica Neue,sans-serif;font-size:12px;margin-right:.2rem}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;background-color:#fff}:host::ng-deep .mat-paginator-container{min-height:initial!important}:host::ng-deep .mat-paginator-container .mat-form-field-infix{padding:0!important}.group-header{font-weight:700;font-size:20px}:host::ng-deep .table-drag-list.cdk-drop-list-dragging .drag-header:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"] }]
|
|
2053
|
-
}], ctorParameters: function () { return [{ type: i1$
|
|
2462
|
+
}], ctorParameters: function () { return [{ type: i1$2.MatSort }, { type: TableStore }, { type: i0.ViewContainerRef }, { type: i0.Injector }]; }, propDecorators: { data$: [{
|
|
2054
2463
|
type: Input
|
|
2055
2464
|
}], IndexColumn: [{
|
|
2056
2465
|
type: Input
|
|
@@ -2112,7 +2521,7 @@ class CustomCellDirective {
|
|
|
2112
2521
|
};
|
|
2113
2522
|
}
|
|
2114
2523
|
}
|
|
2115
|
-
CustomCellDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: CustomCellDirective, deps: [{ token: i0.TemplateRef, optional: true }, { token: i1$
|
|
2524
|
+
CustomCellDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: CustomCellDirective, deps: [{ token: i0.TemplateRef, optional: true }, { token: i1$3.CdkColumnDef, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2116
2525
|
CustomCellDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: CustomCellDirective, selector: "[customCell]", inputs: { customCell: "customCell", displayName: "displayName", preSort: "preSort", TemplateRef: "TemplateRef", customCellOrder: "customCellOrder", customCellWidth: "customCellWidth" }, ngImport: i0 });
|
|
2117
2526
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: CustomCellDirective, decorators: [{
|
|
2118
2527
|
type: Directive,
|
|
@@ -2122,7 +2531,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
2122
2531
|
}], ctorParameters: function () {
|
|
2123
2532
|
return [{ type: i0.TemplateRef, decorators: [{
|
|
2124
2533
|
type: Optional
|
|
2125
|
-
}] }, { type: i1$
|
|
2534
|
+
}] }, { type: i1$3.CdkColumnDef, decorators: [{
|
|
2126
2535
|
type: Optional
|
|
2127
2536
|
}] }];
|
|
2128
2537
|
}, propDecorators: { customCell: [{
|
|
@@ -2165,7 +2574,7 @@ class GenColDisplayerComponent {
|
|
|
2165
2574
|
}
|
|
2166
2575
|
}
|
|
2167
2576
|
GenColDisplayerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenColDisplayerComponent, deps: [{ token: TableStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
2168
|
-
GenColDisplayerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: GenColDisplayerComponent, selector: "tb-col-displayer", ngImport: i0, template: "<ng-container *ngIf=\"columns$ | async as displayCols\">\n <span matTooltip=\"Show/hide columns\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">visibility_off</mat-icon>\n </button>\n </span>\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\">\n\n <button mat-menu-item>\n <div style=\"display: flex; flex-direction: row-reverse;\">\n <span matTooltip=\"Close\">\n <button class=\"filter-button\" mat-icon-button>\n <mat-icon>close</mat-icon>\n </button>\n </span>\n </div>\n </button>\n <button mat-menu-item stop-propagation>\n <div style=\"display: flex; justify-content: space-between;\">\n <span matTooltip=\"Show all columns\">\n <button mat-icon-button (click)=\"reset(displayCols)\">\n <mat-icon color=\"primary\">done_all</mat-icon>\n </button>\n </span>\n\n <span matTooltip=\"Hide all columns\">\n <button mat-icon-button (click)=\"unset(displayCols)\">\n <mat-icon color=\"primary\">cancel</mat-icon>\n </button>\n </span>\n </div>\n </button>\n\n <div cdkDropList (cdkDropListDropped)=\"drop($event)\" stop-propagation cdkDropListLockAxis='y' >\n <button [class.isHidden]=\"!col.isVisible\" stop-propagation mat-menu-item cdkDrag [cdkDragData]=\"col\"\n *ngFor=\"let col of displayCols\">\n <div (click)=\"col.isVisible = !col.isVisible; emit(displayCols)\" style=\"display: flex; justify-content: space-between; align-items: center;\">\n <p class=\"label\" style=\"display: flex;\">\n {{col.displayName || (col.key | spaceCase) }}\n </p>\n <span matTooltip=\"Hide Column\" class=\"show-hide\" *ngIf=\"col.isVisible; else hidden\">\n <button mat-icon-button>\n <mat-icon color=\"primary\">check_box</mat-icon>\n </button>\n </span>\n\n <ng-template #hidden >\n <span matTooltip=\"Show Column\" class=\"show-hide\">\n <button mat-icon-button>\n <mat-icon>indeterminate_check_box</mat-icon>\n </button>\n </span>\n </ng-template>\n\n </div>\n </button>\n </div>\n </mat-menu>\n</ng-container>\n", styles: [".show-hide{margin-left:15px}.label{color:#6495ed;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;text-align:left;margin:0;font-size:17px;font-weight:700;display:inline-block;width:66%}.row{margin:0;padding:0}.isHidden{background-color:#d3d3d3;color:#a9a9a9;font-weight:700;font-size:17px;white-space:nowrap}.filter-button{margin-top:10px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type:
|
|
2577
|
+
GenColDisplayerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: GenColDisplayerComponent, selector: "tb-col-displayer", ngImport: i0, template: "<ng-container *ngIf=\"columns$ | async as displayCols\">\n <span matTooltip=\"Show/hide columns\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">visibility_off</mat-icon>\n </button>\n </span>\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\">\n\n <button mat-menu-item>\n <div style=\"display: flex; flex-direction: row-reverse;\">\n <span matTooltip=\"Close\">\n <button class=\"filter-button\" mat-icon-button>\n <mat-icon>close</mat-icon>\n </button>\n </span>\n </div>\n </button>\n <button mat-menu-item stop-propagation>\n <div style=\"display: flex; justify-content: space-between;\">\n <span matTooltip=\"Show all columns\">\n <button mat-icon-button (click)=\"reset(displayCols)\">\n <mat-icon color=\"primary\">done_all</mat-icon>\n </button>\n </span>\n\n <span matTooltip=\"Hide all columns\">\n <button mat-icon-button (click)=\"unset(displayCols)\">\n <mat-icon color=\"primary\">cancel</mat-icon>\n </button>\n </span>\n </div>\n </button>\n\n <div cdkDropList (cdkDropListDropped)=\"drop($event)\" stop-propagation cdkDropListLockAxis='y' >\n <button [class.isHidden]=\"!col.isVisible\" stop-propagation mat-menu-item cdkDrag [cdkDragData]=\"col\"\n *ngFor=\"let col of displayCols\">\n <div (click)=\"col.isVisible = !col.isVisible; emit(displayCols)\" style=\"display: flex; justify-content: space-between; align-items: center;\">\n <p class=\"label\" style=\"display: flex;\">\n {{col.displayName || (col.key | spaceCase) }}\n </p>\n <span matTooltip=\"Hide Column\" class=\"show-hide\" *ngIf=\"col.isVisible; else hidden\">\n <button mat-icon-button>\n <mat-icon color=\"primary\">check_box</mat-icon>\n </button>\n </span>\n\n <ng-template #hidden >\n <span matTooltip=\"Show Column\" class=\"show-hide\">\n <button mat-icon-button>\n <mat-icon>indeterminate_check_box</mat-icon>\n </button>\n </span>\n </ng-template>\n\n </div>\n </button>\n </div>\n </mat-menu>\n</ng-container>\n", styles: [".show-hide{margin-left:15px}.label{color:#6495ed;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;text-align:left;margin:0;font-size:17px;font-weight:700;display:inline-block;width:66%}.row{margin:0;padding:0}.isHidden{background-color:#d3d3d3;color:#a9a9a9;font-weight:700;font-size:17px;white-space:nowrap}.filter-button{margin-top:10px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: i12.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i12.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }], pipes: { "async": i1$1.AsyncPipe, "spaceCase": SpaceCasePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2169
2578
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenColDisplayerComponent, decorators: [{
|
|
2170
2579
|
type: Component,
|
|
2171
2580
|
args: [{ selector: 'tb-col-displayer', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *ngIf=\"columns$ | async as displayCols\">\n <span matTooltip=\"Show/hide columns\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">visibility_off</mat-icon>\n </button>\n </span>\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\">\n\n <button mat-menu-item>\n <div style=\"display: flex; flex-direction: row-reverse;\">\n <span matTooltip=\"Close\">\n <button class=\"filter-button\" mat-icon-button>\n <mat-icon>close</mat-icon>\n </button>\n </span>\n </div>\n </button>\n <button mat-menu-item stop-propagation>\n <div style=\"display: flex; justify-content: space-between;\">\n <span matTooltip=\"Show all columns\">\n <button mat-icon-button (click)=\"reset(displayCols)\">\n <mat-icon color=\"primary\">done_all</mat-icon>\n </button>\n </span>\n\n <span matTooltip=\"Hide all columns\">\n <button mat-icon-button (click)=\"unset(displayCols)\">\n <mat-icon color=\"primary\">cancel</mat-icon>\n </button>\n </span>\n </div>\n </button>\n\n <div cdkDropList (cdkDropListDropped)=\"drop($event)\" stop-propagation cdkDropListLockAxis='y' >\n <button [class.isHidden]=\"!col.isVisible\" stop-propagation mat-menu-item cdkDrag [cdkDragData]=\"col\"\n *ngFor=\"let col of displayCols\">\n <div (click)=\"col.isVisible = !col.isVisible; emit(displayCols)\" style=\"display: flex; justify-content: space-between; align-items: center;\">\n <p class=\"label\" style=\"display: flex;\">\n {{col.displayName || (col.key | spaceCase) }}\n </p>\n <span matTooltip=\"Hide Column\" class=\"show-hide\" *ngIf=\"col.isVisible; else hidden\">\n <button mat-icon-button>\n <mat-icon color=\"primary\">check_box</mat-icon>\n </button>\n </span>\n\n <ng-template #hidden >\n <span matTooltip=\"Show Column\" class=\"show-hide\">\n <button mat-icon-button>\n <mat-icon>indeterminate_check_box</mat-icon>\n </button>\n </span>\n </ng-template>\n\n </div>\n </button>\n </div>\n </mat-menu>\n</ng-container>\n", styles: [".show-hide{margin-left:15px}.label{color:#6495ed;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;text-align:left;margin:0;font-size:17px;font-weight:700;display:inline-block;width:66%}.row{margin:0;padding:0}.isHidden{background-color:#d3d3d3;color:#a9a9a9;font-weight:700;font-size:17px;white-space:nowrap}.filter-button{margin-top:10px}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}\n"] }]
|
|
@@ -2203,36 +2612,12 @@ class GenFilterDisplayerComponent {
|
|
|
2203
2612
|
}
|
|
2204
2613
|
}
|
|
2205
2614
|
GenFilterDisplayerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenFilterDisplayerComponent, deps: [{ token: TableStore }, { token: WrapperFilterStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
2206
|
-
GenFilterDisplayerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: GenFilterDisplayerComponent, selector: "tb-filter-displayer", ngImport: i0, template: "<button stop-propagation class=\"filter-button\" mat-icon-button [matMenuTriggerFor]=\"menu\" matTooltip=\"Add Filter\">\n <mat-icon class=\"filter-icon\" color=\"primary\">filter_list</mat-icon>\n</button>\n<mat-menu #menu=\"matMenu\">\n <button class=\"filter-labels\" *ngFor=\"let md of filterCols$ | async\" (click)=\"addFilter(md)\" mat-menu-item>\n {{md.displayName || (md.key | spaceCase)}}\n </button>\n</mat-menu>\n", styles: [".filter{margin:15px;display:inline-block}.filter-button{color:#6495ed;font-size:22px;font-weight:700}.cancel-button{font-size:24px;font-weight:700;height:initial;line-height:initial}.filter-wrapper{margin-top:1em;margin-bottom:1em;float:right}.menu{margin-bottom:10px;width:109.1%}.filter-labels{color:#6495ed;font-size:17px;font-weight:600}.float{position:absolute;width:-moz-fit-content;width:fit-content;z-index:101;top:10px;right:180px;max-width:90vw}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: StopPropagationDirective, selector: "[stop-propagation]" }, { type:
|
|
2615
|
+
GenFilterDisplayerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: GenFilterDisplayerComponent, selector: "tb-filter-displayer", ngImport: i0, template: "<button stop-propagation class=\"filter-button\" mat-icon-button [matMenuTriggerFor]=\"menu\" matTooltip=\"Add Filter\">\n <mat-icon class=\"filter-icon\" color=\"primary\">filter_list</mat-icon>\n</button>\n<mat-menu #menu=\"matMenu\">\n <button class=\"filter-labels\" *ngFor=\"let md of filterCols$ | async\" (click)=\"addFilter(md)\" mat-menu-item>\n {{md.displayName || (md.key | spaceCase)}}\n </button>\n</mat-menu>\n", styles: [".filter{margin:15px;display:inline-block}.filter-button{color:#6495ed;font-size:22px;font-weight:700}.cancel-button{font-size:24px;font-weight:700;height:initial;line-height:initial}.filter-wrapper{margin-top:1em;margin-bottom:1em;float:right}.menu{margin-bottom:10px;width:109.1%}.filter-labels{color:#6495ed;font-size:17px;font-weight:600}.float{position:absolute;width:-moz-fit-content;width:fit-content;z-index:101;top:10px;right:180px;max-width:90vw}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i1$1.AsyncPipe, "spaceCase": SpaceCasePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2207
2616
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: GenFilterDisplayerComponent, decorators: [{
|
|
2208
2617
|
type: Component,
|
|
2209
2618
|
args: [{ selector: 'tb-filter-displayer', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button stop-propagation class=\"filter-button\" mat-icon-button [matMenuTriggerFor]=\"menu\" matTooltip=\"Add Filter\">\n <mat-icon class=\"filter-icon\" color=\"primary\">filter_list</mat-icon>\n</button>\n<mat-menu #menu=\"matMenu\">\n <button class=\"filter-labels\" *ngFor=\"let md of filterCols$ | async\" (click)=\"addFilter(md)\" mat-menu-item>\n {{md.displayName || (md.key | spaceCase)}}\n </button>\n</mat-menu>\n", styles: [".filter{margin:15px;display:inline-block}.filter-button{color:#6495ed;font-size:22px;font-weight:700}.cancel-button{font-size:24px;font-weight:700;height:initial;line-height:initial}.filter-wrapper{margin-top:1em;margin-bottom:1em;float:right}.menu{margin-bottom:10px;width:109.1%}.filter-labels{color:#6495ed;font-size:17px;font-weight:600}.float{position:absolute;width:-moz-fit-content;width:fit-content;z-index:101;top:10px;right:180px;max-width:90vw}\n"] }]
|
|
2210
2619
|
}], ctorParameters: function () { return [{ type: TableStore }, { type: WrapperFilterStore }]; } });
|
|
2211
2620
|
|
|
2212
|
-
class AutoFocusDirective {
|
|
2213
|
-
constructor(elementRef) {
|
|
2214
|
-
this.elementRef = elementRef;
|
|
2215
|
-
this.autoFocus = true;
|
|
2216
|
-
}
|
|
2217
|
-
ngAfterViewInit() {
|
|
2218
|
-
if (this.autoFocus) {
|
|
2219
|
-
setTimeout(() => {
|
|
2220
|
-
this.elementRef.nativeElement.focus();
|
|
2221
|
-
});
|
|
2222
|
-
}
|
|
2223
|
-
}
|
|
2224
|
-
}
|
|
2225
|
-
AutoFocusDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: AutoFocusDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2226
|
-
AutoFocusDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: AutoFocusDirective, selector: "[autoFocus]", inputs: { autoFocus: "autoFocus" }, ngImport: i0 });
|
|
2227
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: AutoFocusDirective, decorators: [{
|
|
2228
|
-
type: Directive,
|
|
2229
|
-
args: [{
|
|
2230
|
-
selector: '[autoFocus]'
|
|
2231
|
-
}]
|
|
2232
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { autoFocus: [{
|
|
2233
|
-
type: Input
|
|
2234
|
-
}] } });
|
|
2235
|
-
|
|
2236
2621
|
class InFilterComponent {
|
|
2237
2622
|
constructor(ref) {
|
|
2238
2623
|
this.ref = ref;
|
|
@@ -2280,7 +2665,7 @@ InFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", vers
|
|
|
2280
2665
|
provide: NG_VALUE_ACCESSOR,
|
|
2281
2666
|
useExisting: InFilterComponent,
|
|
2282
2667
|
multi: true
|
|
2283
|
-
}], ngImport: i0, template: "<div class=inline>\n <div *ngFor=\"let val of value; index as i\">\n <input *ngIf=\"type === FieldType.Number || type === FieldType.Currency\"\n [ngModel]=\"val\" (ngModelChange)=\"onValueChange(i,$event)\"\n [readonly]=\"i+1 < value.length\" type=\"number\" [ngModelOptions]=\"{standalone:true}\" [autoFocus]=\"i === value.length - 1\"/>\n <input *ngIf=\"type !== FieldType.Number && type !== FieldType.Currency\"\n [ngModel]=\"val\" (ngModelChange)=\"onValueChange(i,$event)\"\n [readonly]=\"i+1 < value.length\" type=\"string\" [ngModelOptions]=\"{standalone:true}\"\n #input [autoFocus]=\"i === value.length - 1\" />\n <button [disabled]=\"value.length <= 1\" (click)=\"removeInput(i)\">-</button>\n <button *ngIf=\"i === value.length - 1\" [disabled]=\"val == undefined || val === ''\" (click)=\"addInput()\">+</button>\n </div>\n</div>\n", styles: [".inline{display:inline-block}\n"], directives: [{ type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: AutoFocusDirective, selector: "[autoFocus]", inputs: ["autoFocus"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2668
|
+
}], ngImport: i0, template: "<div class=inline>\n <div *ngFor=\"let val of value; index as i\">\n <input *ngIf=\"type === FieldType.Number || type === FieldType.Currency\"\n [ngModel]=\"val\" (ngModelChange)=\"onValueChange(i,$event)\"\n [readonly]=\"i+1 < value.length\" type=\"number\" [ngModelOptions]=\"{standalone:true}\" [autoFocus]=\"i === value.length - 1\"/>\n <input *ngIf=\"type !== FieldType.Number && type !== FieldType.Currency\"\n [ngModel]=\"val\" (ngModelChange)=\"onValueChange(i,$event)\"\n [readonly]=\"i+1 < value.length\" type=\"string\" [ngModelOptions]=\"{standalone:true}\"\n #input [autoFocus]=\"i === value.length - 1\" />\n <button [disabled]=\"value.length <= 1\" (click)=\"removeInput(i)\">-</button>\n <button *ngIf=\"i === value.length - 1\" [disabled]=\"val == undefined || val === ''\" (click)=\"addInput()\">+</button>\n </div>\n</div>\n", styles: [".inline{display:inline-block}\n"], directives: [{ type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: AutoFocusDirective, selector: "[autoFocus]", inputs: ["autoFocus"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2284
2669
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: InFilterComponent, decorators: [{
|
|
2285
2670
|
type: Component,
|
|
2286
2671
|
args: [{ selector: 'lib-in-filter', changeDetection: ChangeDetectionStrategy.OnPush, providers: [{
|
|
@@ -2299,7 +2684,7 @@ class NumberFilterComponent {
|
|
|
2299
2684
|
}
|
|
2300
2685
|
}
|
|
2301
2686
|
NumberFilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: NumberFilterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2302
|
-
NumberFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: NumberFilterComponent, selector: "tb-number-filter", inputs: { CurrentFilterType: "CurrentFilterType", info: "info" }, ngImport: i0, template: "<ng-container *ngIf=\"CurrentFilterType !== FilterType.NumberBetween && CurrentFilterType !== FilterType.IsNull && CurrentFilterType !== FilterType.In\">\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"filterValue\" [ngModel]=\"info.filterValue\" type=\"number\"/>\n </mat-form-field>\n</ng-container>\n\n\n<ng-container *ngIf=\"CurrentFilterType === FilterType.NumberBetween\">\n <ng-container ngModelGroup=\"filterValue\" >\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"Start\" [ngModel]=\"info.filterValue?.Start\" placeholder=\"Start\" type=\"number\"/>\n </mat-form-field>\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"End\" [ngModel]=\"info.filterValue?.End\" placeholder=\"End\" type=\"number\"/>\n </mat-form-field>\n </ng-container>\n</ng-container>\n\n<div class=\"inline\" *ngIf=\"CurrentFilterType === FilterType.In\">\n <lib-in-filter name='filterValue' [type]=\"FieldType.Number\" [(ngModel)]='info.filterValue' ></lib-in-filter>\n</div>\n", styles: [".switch{display:inline-block}.my-filter{margin-right:15px}.inline{display:inline-block}\n"], components: [{ type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: InFilterComponent, selector: "lib-in-filter", inputs: ["type"] }], directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5.NgModelGroup, selector: "[ngModelGroup]", inputs: ["ngModelGroup"], exportAs: ["ngModelGroup"] }], viewProviders: [{ provide: ControlContainer, useExisting: NgForm }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2687
|
+
NumberFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: NumberFilterComponent, selector: "tb-number-filter", inputs: { CurrentFilterType: "CurrentFilterType", info: "info" }, ngImport: i0, template: "<ng-container *ngIf=\"CurrentFilterType !== FilterType.NumberBetween && CurrentFilterType !== FilterType.IsNull && CurrentFilterType !== FilterType.In\">\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"filterValue\" [ngModel]=\"info.filterValue\" type=\"number\"/>\n </mat-form-field>\n</ng-container>\n\n\n<ng-container *ngIf=\"CurrentFilterType === FilterType.NumberBetween\">\n <ng-container ngModelGroup=\"filterValue\" >\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"Start\" [ngModel]=\"info.filterValue?.Start\" placeholder=\"Start\" type=\"number\"/>\n </mat-form-field>\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"End\" [ngModel]=\"info.filterValue?.End\" placeholder=\"End\" type=\"number\"/>\n </mat-form-field>\n </ng-container>\n</ng-container>\n\n<div class=\"inline\" *ngIf=\"CurrentFilterType === FilterType.In\">\n <lib-in-filter name='filterValue' [type]=\"FieldType.Number\" [(ngModel)]='info.filterValue' ></lib-in-filter>\n</div>\n", styles: [".switch{display:inline-block}.my-filter{margin-right:15px}.inline{display:inline-block}\n"], components: [{ type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: InFilterComponent, selector: "lib-in-filter", inputs: ["type"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i5.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5.NgModelGroup, selector: "[ngModelGroup]", inputs: ["ngModelGroup"], exportAs: ["ngModelGroup"] }], viewProviders: [{ provide: ControlContainer, useExisting: NgForm }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2303
2688
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: NumberFilterComponent, decorators: [{
|
|
2304
2689
|
type: Component,
|
|
2305
2690
|
args: [{ selector: 'tb-number-filter', changeDetection: ChangeDetectionStrategy.OnPush, viewProviders: [{ provide: ControlContainer, useExisting: NgForm }], template: "<ng-container *ngIf=\"CurrentFilterType !== FilterType.NumberBetween && CurrentFilterType !== FilterType.IsNull && CurrentFilterType !== FilterType.In\">\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"filterValue\" [ngModel]=\"info.filterValue\" type=\"number\"/>\n </mat-form-field>\n</ng-container>\n\n\n<ng-container *ngIf=\"CurrentFilterType === FilterType.NumberBetween\">\n <ng-container ngModelGroup=\"filterValue\" >\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"Start\" [ngModel]=\"info.filterValue?.Start\" placeholder=\"Start\" type=\"number\"/>\n </mat-form-field>\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"End\" [ngModel]=\"info.filterValue?.End\" placeholder=\"End\" type=\"number\"/>\n </mat-form-field>\n </ng-container>\n</ng-container>\n\n<div class=\"inline\" *ngIf=\"CurrentFilterType === FilterType.In\">\n <lib-in-filter name='filterValue' [type]=\"FieldType.Number\" [(ngModel)]='info.filterValue' ></lib-in-filter>\n</div>\n", styles: [".switch{display:inline-block}.my-filter{margin-right:15px}.inline{display:inline-block}\n"] }]
|
|
@@ -2315,7 +2700,7 @@ class DateFilterComponent {
|
|
|
2315
2700
|
}
|
|
2316
2701
|
}
|
|
2317
2702
|
DateFilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DateFilterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2318
|
-
DateFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: DateFilterComponent, selector: "tb-date-filter", inputs: { info: "info", CurrentFilterType: "CurrentFilterType" }, ngImport: i0, template: "<ng-container *ngIf=\"CurrentFilterType !== FilterType.DateBetween && CurrentFilterType !== FilterType.IsNull\">\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"filterValue\" [ngModel]=\"info.filterValue\" [matDatepicker]=\"cal\"/>\n <mat-datepicker-toggle matSuffix [for]=\"cal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #cal></mat-datepicker>\n </mat-form-field>\n</ng-container>\n\n<ng-container *ngIf=\"CurrentFilterType === FilterType.DateBetween\">\n <ng-container ngModelGroup=\"filterValue\">\n <mat-form-field class=\"my-filter\" >\n <input matInput name=\"Start\" [ngModel]=\"info.filterValue?.Start\" placeholder=\"From\" [matDatepicker]=\"fromVal\"\n (click)=\"fromVal.open()\"/>\n <mat-datepicker-toggle matSuffix [for]=\"fromVal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #fromVal></mat-datepicker>\n </mat-form-field>\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"End\" [ngModel]=\"info.filterValue?.End\" placeholder=\"To\" [matDatepicker]=\"toVal\" (click)=\"toVal.open()\"/>\n <mat-datepicker-toggle matSuffix [for]=\"toVal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #toVal></mat-datepicker>\n </mat-form-field>\n </ng-container>\n</ng-container>\n\n", components: [{ type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i8.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { type: i8.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }], directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i8.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i6.MatSuffix, selector: "[matSuffix]" }, { type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5.NgModelGroup, selector: "[ngModelGroup]", inputs: ["ngModelGroup"], exportAs: ["ngModelGroup"] }], viewProviders: [{ provide: ControlContainer, useExisting: NgForm }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2703
|
+
DateFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: DateFilterComponent, selector: "tb-date-filter", inputs: { info: "info", CurrentFilterType: "CurrentFilterType" }, ngImport: i0, template: "<ng-container *ngIf=\"CurrentFilterType !== FilterType.DateBetween && CurrentFilterType !== FilterType.IsNull\">\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"filterValue\" [ngModel]=\"info.filterValue\" [matDatepicker]=\"cal\"/>\n <mat-datepicker-toggle matSuffix [for]=\"cal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #cal></mat-datepicker>\n </mat-form-field>\n</ng-container>\n\n<ng-container *ngIf=\"CurrentFilterType === FilterType.DateBetween\">\n <ng-container ngModelGroup=\"filterValue\">\n <mat-form-field class=\"my-filter\" >\n <input matInput name=\"Start\" [ngModel]=\"info.filterValue?.Start\" placeholder=\"From\" [matDatepicker]=\"fromVal\"\n (click)=\"fromVal.open()\"/>\n <mat-datepicker-toggle matSuffix [for]=\"fromVal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #fromVal></mat-datepicker>\n </mat-form-field>\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"End\" [ngModel]=\"info.filterValue?.End\" placeholder=\"To\" [matDatepicker]=\"toVal\" (click)=\"toVal.open()\"/>\n <mat-datepicker-toggle matSuffix [for]=\"toVal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #toVal></mat-datepicker>\n </mat-form-field>\n </ng-container>\n</ng-container>\n\n", components: [{ type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i8.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { type: i8.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i8.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i6.MatSuffix, selector: "[matSuffix]" }, { type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5.NgModelGroup, selector: "[ngModelGroup]", inputs: ["ngModelGroup"], exportAs: ["ngModelGroup"] }], viewProviders: [{ provide: ControlContainer, useExisting: NgForm }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2319
2704
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DateFilterComponent, decorators: [{
|
|
2320
2705
|
type: Component,
|
|
2321
2706
|
args: [{ selector: 'tb-date-filter', changeDetection: ChangeDetectionStrategy.OnPush, viewProviders: [{ provide: ControlContainer, useExisting: NgForm }], template: "<ng-container *ngIf=\"CurrentFilterType !== FilterType.DateBetween && CurrentFilterType !== FilterType.IsNull\">\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"filterValue\" [ngModel]=\"info.filterValue\" [matDatepicker]=\"cal\"/>\n <mat-datepicker-toggle matSuffix [for]=\"cal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #cal></mat-datepicker>\n </mat-form-field>\n</ng-container>\n\n<ng-container *ngIf=\"CurrentFilterType === FilterType.DateBetween\">\n <ng-container ngModelGroup=\"filterValue\">\n <mat-form-field class=\"my-filter\" >\n <input matInput name=\"Start\" [ngModel]=\"info.filterValue?.Start\" placeholder=\"From\" [matDatepicker]=\"fromVal\"\n (click)=\"fromVal.open()\"/>\n <mat-datepicker-toggle matSuffix [for]=\"fromVal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #fromVal></mat-datepicker>\n </mat-form-field>\n <mat-form-field class=\"my-filter\">\n <input matInput name=\"End\" [ngModel]=\"info.filterValue?.End\" placeholder=\"To\" [matDatepicker]=\"toVal\" (click)=\"toVal.open()\"/>\n <mat-datepicker-toggle matSuffix [for]=\"toVal\" preventEnter></mat-datepicker-toggle>\n <mat-datepicker #toVal></mat-datepicker>\n </mat-form-field>\n </ng-container>\n</ng-container>\n\n" }]
|
|
@@ -2346,7 +2731,7 @@ class FilterComponent {
|
|
|
2346
2731
|
}
|
|
2347
2732
|
}
|
|
2348
2733
|
FilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FilterComponent, deps: [{ token: TableStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
2349
|
-
FilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: FilterComponent, selector: "tb-filter", inputs: { filter: "filter" }, outputs: { close: "close" }, ngImport: i0, template: "<mat-card class=\"mat-elevation-z5\" *ngIf=\"filter\">\n <form #form=\"ngForm\" (keydown.enter)=\"onEnter(form.value,$event)\" (keydown.escape)=\"close.emit()\">\n <input type=\"hidden\" name=\"filterId\" [ngModel]=\"filter.filterId\" />\n <input type=\"hidden\" name=\"key\" [ngModel]=\"filter.key\" />\n <input type=\"hidden\" name=\"fieldType\" [ngModel]=\"filter.fieldType\" />\n <div class=\"row\" >\n <h4 class=\"filter-name\">{{(filter.key | spaceCase)}} Filter</h4>\n <button class=\"cancel-button\" color=\"primary\" mat-icon-button (click)=\"close.emit();\" type=\"button\"\n matTooltip=\"Close\">\n <mat-icon class=\"cancel-button\" color=\"primary\">close</mat-icon>\n </button>\n </div>\n <div class=\"row\">\n <mat-form-field class=\"my-filter\" >\n <mat-select placeholder=\"Select Filter Type\" name=\"filterType\" [(ngModel)]=\"currentFilterType\" >\n <mat-option *ngFor=\"let kvp of filterTypes[filter.fieldType] | keyvalue \" [value]=\"$any(kvp.value)[0]\">\n {{ kvp.key }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n <ng-container [ngSwitch]=\"true\">\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.String || filter.fieldType === FieldType.Array || filter.fieldType === FieldType.Link ||\n filter.fieldType === FieldType.Unknown || filter.fieldType === FieldType.PhoneNumber\" >\n <ng-container *ngTemplateOutlet=\"String\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Number || filter.fieldType === FieldType.Currency\">\n <tb-number-filter [info]=\"filter\" [CurrentFilterType]=\"currentFilterType!\" ></tb-number-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Boolean\">\n <ng-container *ngTemplateOutlet=\"Boolean\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Date\">\n <tb-date-filter [info]=\"filter\" [CurrentFilterType]=\"currentFilterType!\"></tb-date-filter>\n </ng-container>\n <ng-container *ngSwitchCase='filter.fieldType === FieldType.Enum' >\n <ng-container *ngTemplateOutlet=\"Enum\"></ng-container>\n </ng-container>\n </ng-container>\n\n <mat-radio-group name=\"filterValue\" [ngModel]=\"filter.filterValue\" *ngIf=\"currentFilterType === FilterType.IsNull\">\n <mat-radio-button [value]=\"true\">True</mat-radio-button>\n <mat-radio-button [value]=\"false\">False</mat-radio-button>\n </mat-radio-group>\n\n </div>\n <button mat-button (click)=\"state.addFilter(form.value)\" disableRipple [disabled]=\"form.value.filterValue==undefined || !form.value.filterType\">\n Apply\n </button>\n\n\n<ng-template #String>\n <mat-form-field class=\"my-filter\" *ngIf=\"currentFilterType !== FilterType.IsNull && currentFilterType !== FilterType.In\">\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\n </mat-form-field>\n <ng-container *ngIf=\"currentFilterType === FilterType.In\">\n <lib-in-filter [type]=\"FieldType.String\" name='filterValue' [(ngModel)]=\"filter.filterValue\" ></lib-in-filter>\n </ng-container>\n</ng-template>\n\n<ng-template #Boolean >\n <div class=\"switch\" [ngSwitch]=\"currentFilterType\">\n <div class=\"switch\" *ngSwitchCase=\"FilterType.BooleanEquals\">\n <mat-radio-group name=\"filterValue\" [ngModel]=\"filter.filterValue\" >\n <mat-radio-button [value]=\"true\" preventEnter>True</mat-radio-button>\n <mat-radio-button [value]=\"false\" preventEnter>False</mat-radio-button>\n </mat-radio-group>\n </div>\n </div>\n</ng-template>\n\n <ng-template #Enum>\n <ng-container *ngIf='currentFilterType === FilterType.In' >\n <tb-in-list-filter [key]='filter.key' name='filterValue' [(ngModel)]='filter.filterValue' ></tb-in-list-filter>\n </ng-container>\n </ng-template>\n\n </form>\n</mat-card>\n", styles: [".filter-name{color:#6495ed;margin-right:30px;font-weight:600;display:inline-block}.switch{display:inline-block}.my-filter{margin-right:15px}.cancel-button{float:right}.row{margin:0}.cancel-button{font-size:18px;font-weight:700}mat-radio-button{margin:5px}\n"], components: [{ type: i2$1.MatCard, selector: "mat-card", exportAs: ["matCard"] }, { type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i6$1.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { type: i6$2.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { type: NumberFilterComponent, selector: "tb-number-filter", inputs: ["CurrentFilterType", "info"] }, { type: DateFilterComponent, selector: "tb-date-filter", inputs: ["info", "CurrentFilterType"] }, { type: i7.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: InFilterComponent, selector: "lib-in-filter", inputs: ["type"] }, { type: InListFilterComponent, selector: "tb-in-list-filter , [tb-in-list-filter]", inputs: ["key"] }], directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type:
|
|
2734
|
+
FilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: FilterComponent, selector: "tb-filter", inputs: { filter: "filter" }, outputs: { close: "close" }, ngImport: i0, template: "<mat-card class=\"mat-elevation-z5\" *ngIf=\"filter\">\n <form #form=\"ngForm\" (keydown.enter)=\"onEnter(form.value,$event)\" (keydown.escape)=\"close.emit()\">\n <input type=\"hidden\" name=\"filterId\" [ngModel]=\"filter.filterId\" />\n <input type=\"hidden\" name=\"key\" [ngModel]=\"filter.key\" />\n <input type=\"hidden\" name=\"fieldType\" [ngModel]=\"filter.fieldType\" />\n <div class=\"row\" >\n <h4 class=\"filter-name\">{{(filter.key | spaceCase)}} Filter</h4>\n <button class=\"cancel-button\" color=\"primary\" mat-icon-button (click)=\"close.emit();\" type=\"button\"\n matTooltip=\"Close\">\n <mat-icon class=\"cancel-button\" color=\"primary\">close</mat-icon>\n </button>\n </div>\n <div class=\"row\">\n <mat-form-field class=\"my-filter\" >\n <mat-select placeholder=\"Select Filter Type\" name=\"filterType\" [(ngModel)]=\"currentFilterType\" >\n <mat-option *ngFor=\"let kvp of filterTypes[filter.fieldType] | keyvalue \" [value]=\"$any(kvp.value)[0]\">\n {{ kvp.key }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n <ng-container [ngSwitch]=\"true\">\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.String || filter.fieldType === FieldType.Array || filter.fieldType === FieldType.Link ||\n filter.fieldType === FieldType.Unknown || filter.fieldType === FieldType.PhoneNumber\" >\n <ng-container *ngTemplateOutlet=\"String\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Number || filter.fieldType === FieldType.Currency\">\n <tb-number-filter [info]=\"filter\" [CurrentFilterType]=\"currentFilterType!\" ></tb-number-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Boolean\">\n <ng-container *ngTemplateOutlet=\"Boolean\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Date\">\n <tb-date-filter [info]=\"filter\" [CurrentFilterType]=\"currentFilterType!\"></tb-date-filter>\n </ng-container>\n <ng-container *ngSwitchCase='filter.fieldType === FieldType.Enum' >\n <ng-container *ngTemplateOutlet=\"Enum\"></ng-container>\n </ng-container>\n </ng-container>\n\n <mat-radio-group name=\"filterValue\" [ngModel]=\"filter.filterValue\" *ngIf=\"currentFilterType === FilterType.IsNull\">\n <mat-radio-button [value]=\"true\">True</mat-radio-button>\n <mat-radio-button [value]=\"false\">False</mat-radio-button>\n </mat-radio-group>\n\n </div>\n <button mat-button (click)=\"state.addFilter(form.value)\" disableRipple [disabled]=\"form.value.filterValue==undefined || !form.value.filterType\">\n Apply\n </button>\n\n\n<ng-template #String>\n <mat-form-field class=\"my-filter\" *ngIf=\"currentFilterType !== FilterType.IsNull && currentFilterType !== FilterType.In\">\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\n </mat-form-field>\n <ng-container *ngIf=\"currentFilterType === FilterType.In\">\n <lib-in-filter [type]=\"FieldType.String\" name='filterValue' [(ngModel)]=\"filter.filterValue\" ></lib-in-filter>\n </ng-container>\n</ng-template>\n\n<ng-template #Boolean >\n <div class=\"switch\" [ngSwitch]=\"currentFilterType\">\n <div class=\"switch\" *ngSwitchCase=\"FilterType.BooleanEquals\">\n <mat-radio-group name=\"filterValue\" [ngModel]=\"filter.filterValue\" >\n <mat-radio-button [value]=\"true\" preventEnter>True</mat-radio-button>\n <mat-radio-button [value]=\"false\" preventEnter>False</mat-radio-button>\n </mat-radio-group>\n </div>\n </div>\n</ng-template>\n\n <ng-template #Enum>\n <ng-container *ngIf='currentFilterType === FilterType.In' >\n <tb-in-list-filter [key]='filter.key' name='filterValue' [(ngModel)]='filter.filterValue' ></tb-in-list-filter>\n </ng-container>\n </ng-template>\n\n </form>\n</mat-card>\n", styles: [".filter-name{color:#6495ed;margin-right:30px;font-weight:600;display:inline-block}.switch{display:inline-block}.my-filter{margin-right:15px}.cancel-button{float:right}.row{margin:0}.cancel-button{font-size:18px;font-weight:700}mat-radio-button{margin:5px}\n"], components: [{ type: i2$1.MatCard, selector: "mat-card", exportAs: ["matCard"] }, { type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i6$1.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { type: i6$2.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { type: NumberFilterComponent, selector: "tb-number-filter", inputs: ["CurrentFilterType", "info"] }, { type: DateFilterComponent, selector: "tb-date-filter", inputs: ["info", "CurrentFilterType"] }, { type: i7.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: InFilterComponent, selector: "lib-in-filter", inputs: ["type"] }, { type: InListFilterComponent, selector: "tb-in-list-filter , [tb-in-list-filter]", inputs: ["key"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i7.MatRadioGroup, selector: "mat-radio-group", exportAs: ["matRadioGroup"] }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }], pipes: { "spaceCase": SpaceCasePipe, "keyvalue": i1$1.KeyValuePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2350
2735
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FilterComponent, decorators: [{
|
|
2351
2736
|
type: Component,
|
|
2352
2737
|
args: [{ selector: 'tb-filter', changeDetection: ChangeDetectionStrategy.OnPush, template: "<mat-card class=\"mat-elevation-z5\" *ngIf=\"filter\">\n <form #form=\"ngForm\" (keydown.enter)=\"onEnter(form.value,$event)\" (keydown.escape)=\"close.emit()\">\n <input type=\"hidden\" name=\"filterId\" [ngModel]=\"filter.filterId\" />\n <input type=\"hidden\" name=\"key\" [ngModel]=\"filter.key\" />\n <input type=\"hidden\" name=\"fieldType\" [ngModel]=\"filter.fieldType\" />\n <div class=\"row\" >\n <h4 class=\"filter-name\">{{(filter.key | spaceCase)}} Filter</h4>\n <button class=\"cancel-button\" color=\"primary\" mat-icon-button (click)=\"close.emit();\" type=\"button\"\n matTooltip=\"Close\">\n <mat-icon class=\"cancel-button\" color=\"primary\">close</mat-icon>\n </button>\n </div>\n <div class=\"row\">\n <mat-form-field class=\"my-filter\" >\n <mat-select placeholder=\"Select Filter Type\" name=\"filterType\" [(ngModel)]=\"currentFilterType\" >\n <mat-option *ngFor=\"let kvp of filterTypes[filter.fieldType] | keyvalue \" [value]=\"$any(kvp.value)[0]\">\n {{ kvp.key }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n <ng-container [ngSwitch]=\"true\">\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.String || filter.fieldType === FieldType.Array || filter.fieldType === FieldType.Link ||\n filter.fieldType === FieldType.Unknown || filter.fieldType === FieldType.PhoneNumber\" >\n <ng-container *ngTemplateOutlet=\"String\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Number || filter.fieldType === FieldType.Currency\">\n <tb-number-filter [info]=\"filter\" [CurrentFilterType]=\"currentFilterType!\" ></tb-number-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Boolean\">\n <ng-container *ngTemplateOutlet=\"Boolean\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"filter.fieldType === FieldType.Date\">\n <tb-date-filter [info]=\"filter\" [CurrentFilterType]=\"currentFilterType!\"></tb-date-filter>\n </ng-container>\n <ng-container *ngSwitchCase='filter.fieldType === FieldType.Enum' >\n <ng-container *ngTemplateOutlet=\"Enum\"></ng-container>\n </ng-container>\n </ng-container>\n\n <mat-radio-group name=\"filterValue\" [ngModel]=\"filter.filterValue\" *ngIf=\"currentFilterType === FilterType.IsNull\">\n <mat-radio-button [value]=\"true\">True</mat-radio-button>\n <mat-radio-button [value]=\"false\">False</mat-radio-button>\n </mat-radio-group>\n\n </div>\n <button mat-button (click)=\"state.addFilter(form.value)\" disableRipple [disabled]=\"form.value.filterValue==undefined || !form.value.filterType\">\n Apply\n </button>\n\n\n<ng-template #String>\n <mat-form-field class=\"my-filter\" *ngIf=\"currentFilterType !== FilterType.IsNull && currentFilterType !== FilterType.In\">\n <input matInput name=\"filterValue\" [ngModel]=\"filter.filterValue\" />\n </mat-form-field>\n <ng-container *ngIf=\"currentFilterType === FilterType.In\">\n <lib-in-filter [type]=\"FieldType.String\" name='filterValue' [(ngModel)]=\"filter.filterValue\" ></lib-in-filter>\n </ng-container>\n</ng-template>\n\n<ng-template #Boolean >\n <div class=\"switch\" [ngSwitch]=\"currentFilterType\">\n <div class=\"switch\" *ngSwitchCase=\"FilterType.BooleanEquals\">\n <mat-radio-group name=\"filterValue\" [ngModel]=\"filter.filterValue\" >\n <mat-radio-button [value]=\"true\" preventEnter>True</mat-radio-button>\n <mat-radio-button [value]=\"false\" preventEnter>False</mat-radio-button>\n </mat-radio-group>\n </div>\n </div>\n</ng-template>\n\n <ng-template #Enum>\n <ng-container *ngIf='currentFilterType === FilterType.In' >\n <tb-in-list-filter [key]='filter.key' name='filterValue' [(ngModel)]='filter.filterValue' ></tb-in-list-filter>\n </ng-container>\n </ng-template>\n\n </form>\n</mat-card>\n", styles: [".filter-name{color:#6495ed;margin-right:30px;font-weight:600;display:inline-block}.switch{display:inline-block}.my-filter{margin-right:15px}.cancel-button{float:right}.row{margin:0}.cancel-button{font-size:18px;font-weight:700}mat-radio-button{margin:5px}\n"] }]
|
|
@@ -2987,7 +3372,11 @@ class DataFilter {
|
|
|
2987
3372
|
var _a;
|
|
2988
3373
|
return new DataFilter(combineArrays([
|
|
2989
3374
|
(_a = this.filters$) !== null && _a !== void 0 ? _a : of([]),
|
|
2990
|
-
filters$.pipe(map(fltrs => fltrs
|
|
3375
|
+
filters$.pipe(map(fltrs => fltrs
|
|
3376
|
+
// we only want to remove it if it was specifically set to false
|
|
3377
|
+
// as apposed to falsy
|
|
3378
|
+
.filter(f => f.active !== false)
|
|
3379
|
+
.map(filter => createFilterFunc(filter))))
|
|
2991
3380
|
]));
|
|
2992
3381
|
}
|
|
2993
3382
|
}
|
|
@@ -3011,7 +3400,7 @@ class ExportToCsvService {
|
|
|
3011
3400
|
this.datePipe = datePipe;
|
|
3012
3401
|
this.exportToCsv = (data) => {
|
|
3013
3402
|
const exportableFields$ = this.state.state$.pipe(map(mapExportableFields));
|
|
3014
|
-
combineLatest([data, exportableFields$]).pipe(first(), map(([data, fields]) => this.csvData(data, fields))).subscribe(csv => downloadData(csv, 'export.csv', 'text/csv'));
|
|
3403
|
+
combineLatest([data, exportableFields$]).pipe(first$1(), map(([data, fields]) => this.csvData(data, fields))).subscribe(csv => downloadData(csv, 'export.csv', 'text/csv'));
|
|
3015
3404
|
};
|
|
3016
3405
|
this.csvData = (data, metaData) => {
|
|
3017
3406
|
const res = data.map(row => metaData.map(meta => this.metaToField(meta, row)).join(','));
|
|
@@ -3058,7 +3447,7 @@ class ExportToCsvService {
|
|
|
3058
3447
|
return this.datePipe.transform(val, dateFormat);
|
|
3059
3448
|
}
|
|
3060
3449
|
}
|
|
3061
|
-
ExportToCsvService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ExportToCsvService, deps: [{ token: TableStore }, { token: TableBuilderConfigToken }, { token: i1.DatePipe }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3450
|
+
ExportToCsvService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ExportToCsvService, deps: [{ token: TableStore }, { token: TableBuilderConfigToken }, { token: i1$1.DatePipe }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3062
3451
|
ExportToCsvService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ExportToCsvService });
|
|
3063
3452
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ExportToCsvService, decorators: [{
|
|
3064
3453
|
type: Injectable
|
|
@@ -3066,7 +3455,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
3066
3455
|
return [{ type: TableStore }, { type: undefined, decorators: [{
|
|
3067
3456
|
type: Inject,
|
|
3068
3457
|
args: [TableBuilderConfigToken]
|
|
3069
|
-
}] }, { type: i1.DatePipe }];
|
|
3458
|
+
}] }, { type: i1$1.DatePipe }];
|
|
3070
3459
|
} });
|
|
3071
3460
|
const removeFromMetaData = (state, keysToRemove) => orderMetaData(state)
|
|
3072
3461
|
.filter(meta => !keysToRemove.includes(meta.key));
|
|
@@ -3175,12 +3564,12 @@ class FormatFilterValuePipe {
|
|
|
3175
3564
|
}));
|
|
3176
3565
|
}
|
|
3177
3566
|
}
|
|
3178
|
-
FormatFilterValuePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FormatFilterValuePipe, deps: [{ token: TableStore }, { token: i1.DatePipe }], target: i0.ɵɵFactoryTarget.Pipe });
|
|
3567
|
+
FormatFilterValuePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FormatFilterValuePipe, deps: [{ token: TableStore }, { token: i1$1.DatePipe }], target: i0.ɵɵFactoryTarget.Pipe });
|
|
3179
3568
|
FormatFilterValuePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FormatFilterValuePipe, name: "formatFilterValue" });
|
|
3180
3569
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FormatFilterValuePipe, decorators: [{
|
|
3181
3570
|
type: Pipe,
|
|
3182
3571
|
args: [{ name: 'formatFilterValue' }]
|
|
3183
|
-
}], ctorParameters: function () { return [{ type: TableStore }, { type: i1.DatePipe }]; } });
|
|
3572
|
+
}], ctorParameters: function () { return [{ type: TableStore }, { type: i1$1.DatePipe }]; } });
|
|
3184
3573
|
|
|
3185
3574
|
class FilterChipsComponent {
|
|
3186
3575
|
constructor(tableState, filterStore) {
|
|
@@ -3202,7 +3591,7 @@ class FilterChipsComponent {
|
|
|
3202
3591
|
}
|
|
3203
3592
|
}
|
|
3204
3593
|
FilterChipsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FilterChipsComponent, deps: [{ token: TableStore }, { token: WrapperFilterStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
3205
|
-
FilterChipsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: FilterChipsComponent, selector: "lib-filter-list", ngImport: i0, template: "<div style=\"display: flex; flex-direction: row;justify-content: flex-end;\" *ngrxLet=\"currentFilters$ as currentFilters\" >\n\n <button class=\"cancel-button\" *ngIf=\"currentFilters.length\" mat-icon-button (click)=\"clearAll()\"\n matTooltip=\"Close all Filters\">\n <mat-icon class=\"cancel-button\" color=\"primary\">close</mat-icon>\n </button>\n\n\n <div *ngIf=\"currentFilters.length\" class=\"float\">\n <div class=\"filter\" *ngFor=\"let filter of (currentFilters$ | async); index as i;\">\n <tb-filter [filter]=\"filter\" (close)=\"deleteByIndex(i)\" > </tb-filter>\n </div>\n </div>\n\n <mat-chip-list *ngrxLet=\"filters$ as filters\">\n <mat-chip *ngFor=\"let filter of filters\" (dblclick)=\"addFilter(filter)\" (removed)=\"tableState.removeFilter(filter.filterId!)\">\n {{ filter.key | keyDisplay | async }} {{filter.filterType | formatFilterType : filter.filterValue}} {{ filter.filterValue | formatFilterValue: filter.key : filter.filterType | async }}\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n <mat-chip *ngIf=\"filters.length >= 2\" (removed)=\"tableState.clearFilters()\">\n Clear All\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n </mat-chip-list>\n\n</div>\n", styles: [".filter{margin:15px;display:inline-block}.filter-button{color:#6495ed;font-size:22px;font-weight:700}.cancel-button{font-size:24px;font-weight:700;height:initial;line-height:initial}.filter-wrapper{margin-top:1em;margin-bottom:1em;float:right}.menu{margin-bottom:10px;width:109.1%}.filter-labels{color:#6495ed;font-size:17px;font-weight:600}.float{position:absolute;width:-moz-fit-content;width:fit-content;z-index:101;top:10px;right:180px;max-width:90vw}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: FilterComponent, selector: "tb-filter", inputs: ["filter"], outputs: ["close"] }, { type: i6$3.MatChipList, selector: "mat-chip-list", inputs: ["errorStateMatcher", "multiple", "compareWith", "value", "required", "placeholder", "disabled", "aria-orientation", "selectable", "tabIndex"], outputs: ["change", "valueChange"], exportAs: ["matChipList"] }], directives: [{ type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type:
|
|
3594
|
+
FilterChipsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: FilterChipsComponent, selector: "lib-filter-list", ngImport: i0, template: "<div style=\"display: flex; flex-direction: row;justify-content: flex-end;\" *ngrxLet=\"currentFilters$ as currentFilters\" >\n\n <button class=\"cancel-button\" *ngIf=\"currentFilters.length\" mat-icon-button (click)=\"clearAll()\"\n matTooltip=\"Close all Filters\">\n <mat-icon class=\"cancel-button\" color=\"primary\">close</mat-icon>\n </button>\n\n\n <div *ngIf=\"currentFilters.length\" class=\"float\">\n <div class=\"filter\" *ngFor=\"let filter of (currentFilters$ | async); index as i;\">\n <tb-filter [filter]=\"filter\" (close)=\"deleteByIndex(i)\" > </tb-filter>\n </div>\n </div>\n\n <mat-chip-list *ngrxLet=\"filters$ as filters\">\n <mat-chip *ngFor=\"let filter of filters\" (dblclick)=\"addFilter(filter)\" (removed)=\"tableState.removeFilter(filter.filterId!)\">\n {{ filter.key | keyDisplay | async }} {{filter.filterType | formatFilterType : filter.filterValue}} {{ filter.filterValue | formatFilterValue: filter.key : filter.filterType | async }}\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n <mat-chip *ngIf=\"filters.length >= 2\" (removed)=\"tableState.clearFilters()\">\n Clear All\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n </mat-chip-list>\n\n</div>\n", styles: [".filter{margin:15px;display:inline-block}.filter-button{color:#6495ed;font-size:22px;font-weight:700}.cancel-button{font-size:24px;font-weight:700;height:initial;line-height:initial}.filter-wrapper{margin-top:1em;margin-bottom:1em;float:right}.menu{margin-bottom:10px;width:109.1%}.filter-labels{color:#6495ed;font-size:17px;font-weight:600}.float{position:absolute;width:-moz-fit-content;width:fit-content;z-index:101;top:10px;right:180px;max-width:90vw}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: FilterComponent, selector: "tb-filter", inputs: ["filter"], outputs: ["close"] }, { type: i6$3.MatChipList, selector: "mat-chip-list", inputs: ["errorStateMatcher", "multiple", "compareWith", "value", "required", "placeholder", "disabled", "aria-orientation", "selectable", "tabIndex"], outputs: ["change", "valueChange"], exportAs: ["matChipList"] }], directives: [{ type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6$3.MatChip, selector: "mat-basic-chip, [mat-basic-chip], mat-chip, [mat-chip]", inputs: ["color", "disableRipple", "tabIndex", "selected", "value", "selectable", "disabled", "removable"], outputs: ["selectionChange", "destroyed", "removed"], exportAs: ["matChip"] }, { type: i6$3.MatChipRemove, selector: "[matChipRemove]" }], pipes: { "async": i1$1.AsyncPipe, "keyDisplay": KeyDisplayPipe, "formatFilterType": FormatFilterTypePipe, "formatFilterValue": FormatFilterValuePipe } });
|
|
3206
3595
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: FilterChipsComponent, decorators: [{
|
|
3207
3596
|
type: Component,
|
|
3208
3597
|
args: [{ selector: 'lib-filter-list', template: "<div style=\"display: flex; flex-direction: row;justify-content: flex-end;\" *ngrxLet=\"currentFilters$ as currentFilters\" >\n\n <button class=\"cancel-button\" *ngIf=\"currentFilters.length\" mat-icon-button (click)=\"clearAll()\"\n matTooltip=\"Close all Filters\">\n <mat-icon class=\"cancel-button\" color=\"primary\">close</mat-icon>\n </button>\n\n\n <div *ngIf=\"currentFilters.length\" class=\"float\">\n <div class=\"filter\" *ngFor=\"let filter of (currentFilters$ | async); index as i;\">\n <tb-filter [filter]=\"filter\" (close)=\"deleteByIndex(i)\" > </tb-filter>\n </div>\n </div>\n\n <mat-chip-list *ngrxLet=\"filters$ as filters\">\n <mat-chip *ngFor=\"let filter of filters\" (dblclick)=\"addFilter(filter)\" (removed)=\"tableState.removeFilter(filter.filterId!)\">\n {{ filter.key | keyDisplay | async }} {{filter.filterType | formatFilterType : filter.filterValue}} {{ filter.filterValue | formatFilterValue: filter.key : filter.filterType | async }}\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n <mat-chip *ngIf=\"filters.length >= 2\" (removed)=\"tableState.clearFilters()\">\n Clear All\n <mat-icon matChipRemove>cancel</mat-icon>\n </mat-chip>\n </mat-chip-list>\n\n</div>\n", styles: [".filter{margin:15px;display:inline-block}.filter-button{color:#6495ed;font-size:22px;font-weight:700}.cancel-button{font-size:24px;font-weight:700;height:initial;line-height:initial}.filter-wrapper{margin-top:1em;margin-bottom:1em;float:right}.menu{margin-bottom:10px;width:109.1%}.filter-labels{color:#6495ed;font-size:17px;font-weight:600}.float{position:absolute;width:-moz-fit-content;width:fit-content;z-index:101;top:10px;right:180px;max-width:90vw}\n"] }]
|
|
@@ -3252,7 +3641,7 @@ class SortMenuComponent {
|
|
|
3252
3641
|
this.dirty$ = new BehaviorSubject(false);
|
|
3253
3642
|
this.apply = this.store.effect((obs) => obs.pipe(tap(() => {
|
|
3254
3643
|
this.dirty$.next(false);
|
|
3255
|
-
this.tableState.setAllSort(this.store.sorted$.pipe(first()));
|
|
3644
|
+
this.tableState.setAllSort(this.store.sorted$.pipe(first$1()));
|
|
3256
3645
|
})));
|
|
3257
3646
|
this.sorted$ = this.store.sorted$.pipe(map(data => [...data]));
|
|
3258
3647
|
this.notSorted$ = this.store.notSorted$.pipe(map(data => [...data]));
|
|
@@ -3263,209 +3652,42 @@ class SortMenuComponent {
|
|
|
3263
3652
|
}
|
|
3264
3653
|
ngOnInit() {
|
|
3265
3654
|
this.store.reset();
|
|
3266
|
-
}
|
|
3267
|
-
dropIntoSorted(event) {
|
|
3268
|
-
this.dirty$.next(true);
|
|
3269
|
-
if (event.previousContainer === event.container) {
|
|
3270
|
-
moveItemInArray(event.container.data, event.previousIndex, event.currentIndex);
|
|
3271
|
-
}
|
|
3272
|
-
else {
|
|
3273
|
-
transferArrayItem(event.previousContainer.data, event.container.data, event.previousIndex, event.currentIndex);
|
|
3274
|
-
event.container.data[event.currentIndex] = Object.assign(Object.assign({}, event.container.data[event.currentIndex]), { direction: SortDirection.asc });
|
|
3275
|
-
this.store.setSorted(event.container.data);
|
|
3276
|
-
this.store.setNotSorted(event.previousContainer.data);
|
|
3277
|
-
}
|
|
3278
|
-
}
|
|
3279
|
-
dropIntoNotSorted(event) {
|
|
3280
|
-
if (event.previousContainer === event.container) {
|
|
3281
|
-
return;
|
|
3282
|
-
}
|
|
3283
|
-
else {
|
|
3284
|
-
this.dirty$.next(true);
|
|
3285
|
-
transferArrayItem(event.previousContainer.data, event.container.data, event.previousIndex, event.currentIndex);
|
|
3286
|
-
event.container.data[event.currentIndex] = Object.assign({}, event.container.data[event.currentIndex]);
|
|
3287
|
-
this.store.setNotSorted(event.container.data);
|
|
3288
|
-
this.store.setSorted(event.previousContainer.data);
|
|
3289
|
-
}
|
|
3290
|
-
}
|
|
3291
|
-
setDirection(sort) {
|
|
3292
|
-
this.dirty$.next(true);
|
|
3293
|
-
this.store.setDirection(sort);
|
|
3294
|
-
}
|
|
3295
|
-
}
|
|
3296
|
-
SortMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SortMenuComponent, deps: [{ token: TableStore }, { token: SortMenuComponentStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
3297
|
-
SortMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: SortMenuComponent, selector: "tb-sort-menu", providers: [SortMenuComponentStore], ngImport: i0, template: "<ng-container *ngrxLet=\"dirty$ as dirty\">\n<ng-container *ngIf=\"sorted$ | async as sorted\">\n <ng-container *ngIf=\"notSorted$ | async as notSorted\">\n <!-- Menu Trigger -->\n <span matTooltip=\"Sort\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">swap_vert</mat-icon>\n </button>\n </span>\n\n <!-- Menu -->\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\" (closed)=\"reset()\">\n <div mat-menu-item class=\"menu-button\">\n <div class=\"close-button-wrapper\">\n <span matTooltip=\"Close\">\n <mat-icon>close</mat-icon>\n </span>\n <span *ngIf=\"dirty\" matTooltip=\"Undo\" stop-propagation (click)=\"reset()\">\n <mat-icon>undo</mat-icon>\n </span>\n </div>\n </div>\n\n <!-- Apply Button -->\n <div class=\"apply-button-wrapper\">\n <button mat-button color=\"primary\" (click)=\"apply(null)\"\n stop-propagation [class.apply-border]=\"dirty\"\n [disabled]=\"!dirty\">\n Apply\n <ng-container *ngIf=\"dirty\">Unsaved Changes</ng-container>\n </button>\n </div>\n\n <!-- Default Sorting Text -->\n <div *ngIf=\"!sorted.length\" class=\"tip\" >\n Sorting List\n </div>\n\n <!-- Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #sortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[notSortedGroup]\"\n [cdkDropListData]=\"sorted\"\n (cdkDropListDropped)=\"dropIntoSorted($event)\">\n\n <!-- Menu Item Wrapper -->\n <ng-container *ngFor=\"let sort of sorted;let i=index\">\n\n <!-- Menu Item Headers -->\n <span *ngIf=\"sorted.length > 1 && i === 0 \" class=\"description\" class=\"sort-header\">First By</span>\n <span *ngIf=\"sorted.length > 1 && i !== 0 \" class=\"description\" class=\"sort-header\">Then By</span>\n\n <!-- Menu Item -->\n <div mat-menu-item cdkDrag class=\"menu-item\">\n <div class=\"sort-item\">\n <span class=\"sorted-name\">\n {{sort.displayName || (sort.active | spaceCase)}}\n <span class=\"direction-text\">{{sort.direction}}</span>\n </span>\n\n <!-- Sort Direction Buttons -->\n <div class=\"up-down-buttons-wrapper\">\n <button class=\"up-down-button up-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.asc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction !== SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_upward\n </mat-icon>\n </button>\n\n <button class=\"up-down-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.desc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction === SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_downward\n </mat-icon>\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n </div>\n\n <!-- Default Not Sorted Text -->\n <div *ngIf=\"!notSorted.length\" class=\"tip\" >\n Not Sorted List\n </div>\n <!-- Not Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #notSortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[sortedGroup]\"\n [cdkDropListData]=\"notSorted\"\n (cdkDropListDropped)=\"dropIntoNotSorted($event)\">\n <div mat-menu-item *ngFor=\"let sort of notSorted\" class=\"menu-item\" cdkDrag>\n <span class=\"not-sorted-name\">{{sort.displayName || (sort.active | spaceCase)}}</span>\n </div>\n </div>\n </mat-menu>\n </ng-container>\n</ng-container>\n</ng-container>\n", styles: [".cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.list{padding:5px 2px;border-bottom:solid 1px #ccc;color:#000000de;background:white}.light-arrow{color:#93b1ea78}.dark-arrow{color:#224e9c}.up-down-button{background-color:#fff;border-radius:30%;border-color:#0ff;padding:1px 1px 0;border-width:.5px;cursor:pointer}.mat-icon.up-down-icon{margin-right:0;font-size:20px;font-weight:lighter}.sort-item{display:flex;align-items:center;justify-content:space-between}.up-down-buttons-wrapper{margin-left:2rem}.up-button{margin-right:.3rem}.mat-menu-item.menu-item,.mat-menu-item.menu-button{padding:0 3px;font-size:17px;font-weight:700;line-height:25px;height:30px}.mat-menu-item.menu-item{cursor:move}.sorted-name{color:#224e9c}.not-sorted-name{color:#93b1ea}.apply-border{border:#224e9c solid .5px}.apply-border:hover{background-color:#faebd7}.apply-button-wrapper{display:grid;justify-content:center}.sort-header{font-size:10px;font-style:italic}.tip{padding:0 3px;color:#d3d3d3}.direction-text{font-size:small;font-weight:400}.close-button-wrapper{display:flex;flex-direction:row-reverse}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i13.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: i10.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], pipes: { "async": i1.AsyncPipe, "spaceCase": SpaceCasePipe } });
|
|
3298
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SortMenuComponent, decorators: [{
|
|
3299
|
-
type: Component,
|
|
3300
|
-
args: [{ selector: 'tb-sort-menu', providers: [SortMenuComponentStore], template: "<ng-container *ngrxLet=\"dirty$ as dirty\">\n<ng-container *ngIf=\"sorted$ | async as sorted\">\n <ng-container *ngIf=\"notSorted$ | async as notSorted\">\n <!-- Menu Trigger -->\n <span matTooltip=\"Sort\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">swap_vert</mat-icon>\n </button>\n </span>\n\n <!-- Menu -->\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\" (closed)=\"reset()\">\n <div mat-menu-item class=\"menu-button\">\n <div class=\"close-button-wrapper\">\n <span matTooltip=\"Close\">\n <mat-icon>close</mat-icon>\n </span>\n <span *ngIf=\"dirty\" matTooltip=\"Undo\" stop-propagation (click)=\"reset()\">\n <mat-icon>undo</mat-icon>\n </span>\n </div>\n </div>\n\n <!-- Apply Button -->\n <div class=\"apply-button-wrapper\">\n <button mat-button color=\"primary\" (click)=\"apply(null)\"\n stop-propagation [class.apply-border]=\"dirty\"\n [disabled]=\"!dirty\">\n Apply\n <ng-container *ngIf=\"dirty\">Unsaved Changes</ng-container>\n </button>\n </div>\n\n <!-- Default Sorting Text -->\n <div *ngIf=\"!sorted.length\" class=\"tip\" >\n Sorting List\n </div>\n\n <!-- Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #sortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[notSortedGroup]\"\n [cdkDropListData]=\"sorted\"\n (cdkDropListDropped)=\"dropIntoSorted($event)\">\n\n <!-- Menu Item Wrapper -->\n <ng-container *ngFor=\"let sort of sorted;let i=index\">\n\n <!-- Menu Item Headers -->\n <span *ngIf=\"sorted.length > 1 && i === 0 \" class=\"description\" class=\"sort-header\">First By</span>\n <span *ngIf=\"sorted.length > 1 && i !== 0 \" class=\"description\" class=\"sort-header\">Then By</span>\n\n <!-- Menu Item -->\n <div mat-menu-item cdkDrag class=\"menu-item\">\n <div class=\"sort-item\">\n <span class=\"sorted-name\">\n {{sort.displayName || (sort.active | spaceCase)}}\n <span class=\"direction-text\">{{sort.direction}}</span>\n </span>\n\n <!-- Sort Direction Buttons -->\n <div class=\"up-down-buttons-wrapper\">\n <button class=\"up-down-button up-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.asc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction !== SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_upward\n </mat-icon>\n </button>\n\n <button class=\"up-down-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.desc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction === SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_downward\n </mat-icon>\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n </div>\n\n <!-- Default Not Sorted Text -->\n <div *ngIf=\"!notSorted.length\" class=\"tip\" >\n Not Sorted List\n </div>\n <!-- Not Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #notSortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[sortedGroup]\"\n [cdkDropListData]=\"notSorted\"\n (cdkDropListDropped)=\"dropIntoNotSorted($event)\">\n <div mat-menu-item *ngFor=\"let sort of notSorted\" class=\"menu-item\" cdkDrag>\n <span class=\"not-sorted-name\">{{sort.displayName || (sort.active | spaceCase)}}</span>\n </div>\n </div>\n </mat-menu>\n </ng-container>\n</ng-container>\n</ng-container>\n", styles: [".cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.list{padding:5px 2px;border-bottom:solid 1px #ccc;color:#000000de;background:white}.light-arrow{color:#93b1ea78}.dark-arrow{color:#224e9c}.up-down-button{background-color:#fff;border-radius:30%;border-color:#0ff;padding:1px 1px 0;border-width:.5px;cursor:pointer}.mat-icon.up-down-icon{margin-right:0;font-size:20px;font-weight:lighter}.sort-item{display:flex;align-items:center;justify-content:space-between}.up-down-buttons-wrapper{margin-left:2rem}.up-button{margin-right:.3rem}.mat-menu-item.menu-item,.mat-menu-item.menu-button{padding:0 3px;font-size:17px;font-weight:700;line-height:25px;height:30px}.mat-menu-item.menu-item{cursor:move}.sorted-name{color:#224e9c}.not-sorted-name{color:#93b1ea}.apply-border{border:#224e9c solid .5px}.apply-border:hover{background-color:#faebd7}.apply-button-wrapper{display:grid;justify-content:center}.sort-header{font-size:10px;font-style:italic}.tip{padding:0 3px;color:#d3d3d3}.direction-text{font-size:small;font-weight:400}.close-button-wrapper{display:flex;flex-direction:row-reverse}\n"] }]
|
|
3301
|
-
}], ctorParameters: function () { return [{ type: TableStore }, { type: SortMenuComponentStore }]; } });
|
|
3302
|
-
|
|
3303
|
-
class ClickEmitterDirective extends Subject {
|
|
3304
|
-
constructor() {
|
|
3305
|
-
super();
|
|
3306
|
-
}
|
|
3307
|
-
}
|
|
3308
|
-
ClickEmitterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickEmitterDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3309
|
-
ClickEmitterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: ClickEmitterDirective, selector: "[clickEmitter]", host: { listeners: { "click": "next(true)" } }, exportAs: ["clickEmitter"], usesInheritance: true, ngImport: i0 });
|
|
3310
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickEmitterDirective, decorators: [{
|
|
3311
|
-
type: Directive,
|
|
3312
|
-
args: [{
|
|
3313
|
-
selector: '[clickEmitter]',
|
|
3314
|
-
exportAs: 'clickEmitter',
|
|
3315
|
-
host: {
|
|
3316
|
-
'(click)': 'next(true)'
|
|
3317
|
-
}
|
|
3318
|
-
}]
|
|
3319
|
-
}], ctorParameters: function () { return []; } });
|
|
3320
|
-
|
|
3321
|
-
class DialogService {
|
|
3322
|
-
constructor() {
|
|
3323
|
-
this.allOpenAppDialogs = [];
|
|
3324
|
-
}
|
|
3325
|
-
addDialogRef(ref) {
|
|
3326
|
-
this.allOpenAppDialogs.push(ref);
|
|
3327
|
-
}
|
|
3328
|
-
removeDialogRef(ref) {
|
|
3329
|
-
this.allOpenAppDialogs = this.allOpenAppDialogs.filter(rf => ref.id !== rf.id);
|
|
3330
|
-
}
|
|
3331
|
-
closeAllAppDialogs() {
|
|
3332
|
-
this.allOpenAppDialogs.forEach(ref => ref.close());
|
|
3333
|
-
}
|
|
3334
|
-
}
|
|
3335
|
-
DialogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3336
|
-
DialogService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogService, providedIn: 'root' });
|
|
3337
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogService, decorators: [{
|
|
3338
|
-
type: Injectable,
|
|
3339
|
-
args: [{
|
|
3340
|
-
providedIn: 'root'
|
|
3341
|
-
}]
|
|
3342
|
-
}] });
|
|
3343
|
-
|
|
3344
|
-
class DialogWrapper {
|
|
3345
|
-
constructor(vcr) {
|
|
3346
|
-
this.vcr = vcr;
|
|
3347
|
-
this.viewEmbeded = false;
|
|
3348
|
-
this.viewContext = {
|
|
3349
|
-
close: () => { },
|
|
3350
|
-
};
|
|
3351
|
-
}
|
|
3352
|
-
set template(tmpl) {
|
|
3353
|
-
if (this.viewEmbeded) {
|
|
3354
|
-
this.vcr.clear();
|
|
3355
|
-
}
|
|
3356
|
-
this.viewEmbeded = true;
|
|
3357
|
-
this.vcr.createEmbeddedView(tmpl, this.viewContext);
|
|
3358
|
-
}
|
|
3359
|
-
set close(closeMethod) {
|
|
3360
|
-
this.viewContext.close = closeMethod;
|
|
3361
|
-
}
|
|
3362
|
-
set data(value) {
|
|
3363
|
-
this.viewContext.$implicit = value;
|
|
3364
|
-
this.viewContext.opDialog = value;
|
|
3365
|
-
}
|
|
3366
|
-
}
|
|
3367
|
-
DialogWrapper.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogWrapper, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
3368
|
-
DialogWrapper.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: DialogWrapper, selector: "app-dialog-content", ngImport: i0, template: ``, isInline: true });
|
|
3369
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: DialogWrapper, decorators: [{
|
|
3370
|
-
type: Component,
|
|
3371
|
-
args: [{
|
|
3372
|
-
selector: 'app-dialog-content',
|
|
3373
|
-
template: ``
|
|
3374
|
-
}]
|
|
3375
|
-
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; } });
|
|
3376
|
-
const defaultDialogConfig = {
|
|
3377
|
-
maxHeight: '95vh'
|
|
3378
|
-
};
|
|
3379
|
-
class DialogDirective {
|
|
3380
|
-
constructor(templateRef, dialog, service) {
|
|
3381
|
-
this.templateRef = templateRef;
|
|
3382
|
-
this.dialog = dialog;
|
|
3383
|
-
this.service = service;
|
|
3384
|
-
this.opDialogClosed = new EventEmitter();
|
|
3385
|
-
this._dialogConfig = defaultDialogConfig;
|
|
3386
|
-
this._data = new Subject();
|
|
3387
|
-
this.subscription = this._data.pipe(switchAll()).subscribe(d => {
|
|
3388
|
-
if (d) {
|
|
3389
|
-
this.opDialogConfig.data = d;
|
|
3390
|
-
this.setDialogState(true);
|
|
3391
|
-
}
|
|
3392
|
-
else {
|
|
3393
|
-
this.setDialogState(false);
|
|
3394
|
-
}
|
|
3395
|
-
});
|
|
3396
|
-
}
|
|
3397
|
-
set opDialogConfig(config) {
|
|
3398
|
-
this._dialogConfig = Object.assign(Object.assign({}, defaultDialogConfig), config);
|
|
3399
|
-
}
|
|
3400
|
-
get opDialogConfig() {
|
|
3401
|
-
return this._dialogConfig;
|
|
3402
|
-
}
|
|
3403
|
-
set state(open_close) {
|
|
3404
|
-
this._data.next(open_close);
|
|
3405
|
-
}
|
|
3406
|
-
close() {
|
|
3407
|
-
var _a;
|
|
3408
|
-
(_a = this.dialogRef) === null || _a === void 0 ? void 0 : _a.close();
|
|
3409
|
-
}
|
|
3410
|
-
initDialog() {
|
|
3411
|
-
if (this.nativeElement) {
|
|
3412
|
-
const rect = this.nativeElement.getBoundingClientRect();
|
|
3413
|
-
const position = { left: `${rect.left}px`, top: `${rect.bottom - 50}px` };
|
|
3414
|
-
this.opDialogConfig = Object.assign(Object.assign({}, this.opDialogConfig), { position });
|
|
3415
|
-
}
|
|
3416
|
-
this.dialogRef = this.dialog.open(DialogWrapper, this.opDialogConfig);
|
|
3417
|
-
this.componentWrapper = this.dialogRef.componentInstance;
|
|
3418
|
-
this.componentWrapper.close = () => { var _a; return (_a = this.dialogRef) === null || _a === void 0 ? void 0 : _a.close(); };
|
|
3419
|
-
this.componentWrapper.data = this.opDialogConfig.data;
|
|
3420
|
-
this.componentWrapper.template = this.templateRef;
|
|
3421
|
-
if (!this.opDialogConfig.disableClose) {
|
|
3422
|
-
this.service.addDialogRef(this.dialogRef);
|
|
3423
|
-
}
|
|
3424
|
-
const sub = this.dialogRef.afterClosed().subscribe(() => {
|
|
3425
|
-
this.opDialogClosed.emit(true);
|
|
3426
|
-
this.service.removeDialogRef(this.dialogRef);
|
|
3427
|
-
this.dialogRef = undefined;
|
|
3428
|
-
sub.unsubscribe();
|
|
3429
|
-
});
|
|
3430
|
-
}
|
|
3431
|
-
setDialogState(open) {
|
|
3432
|
-
if (open) {
|
|
3433
|
-
if (!this.dialogRef) {
|
|
3434
|
-
this.initDialog();
|
|
3435
|
-
}
|
|
3436
|
-
else {
|
|
3437
|
-
this.componentWrapper.data = this.opDialogConfig.data;
|
|
3438
|
-
}
|
|
3655
|
+
}
|
|
3656
|
+
dropIntoSorted(event) {
|
|
3657
|
+
this.dirty$.next(true);
|
|
3658
|
+
if (event.previousContainer === event.container) {
|
|
3659
|
+
moveItemInArray(event.container.data, event.previousIndex, event.currentIndex);
|
|
3439
3660
|
}
|
|
3440
|
-
else
|
|
3441
|
-
|
|
3661
|
+
else {
|
|
3662
|
+
transferArrayItem(event.previousContainer.data, event.container.data, event.previousIndex, event.currentIndex);
|
|
3663
|
+
event.container.data[event.currentIndex] = Object.assign(Object.assign({}, event.container.data[event.currentIndex]), { direction: SortDirection.asc });
|
|
3664
|
+
this.store.setSorted(event.container.data);
|
|
3665
|
+
this.store.setNotSorted(event.previousContainer.data);
|
|
3442
3666
|
}
|
|
3443
3667
|
}
|
|
3444
|
-
|
|
3445
|
-
if (
|
|
3446
|
-
|
|
3668
|
+
dropIntoNotSorted(event) {
|
|
3669
|
+
if (event.previousContainer === event.container) {
|
|
3670
|
+
return;
|
|
3671
|
+
}
|
|
3672
|
+
else {
|
|
3673
|
+
this.dirty$.next(true);
|
|
3674
|
+
transferArrayItem(event.previousContainer.data, event.container.data, event.previousIndex, event.currentIndex);
|
|
3675
|
+
event.container.data[event.currentIndex] = Object.assign({}, event.container.data[event.currentIndex]);
|
|
3676
|
+
this.store.setNotSorted(event.container.data);
|
|
3677
|
+
this.store.setSorted(event.previousContainer.data);
|
|
3447
3678
|
}
|
|
3448
3679
|
}
|
|
3449
|
-
|
|
3450
|
-
|
|
3680
|
+
setDirection(sort) {
|
|
3681
|
+
this.dirty$.next(true);
|
|
3682
|
+
this.store.setDirection(sort);
|
|
3451
3683
|
}
|
|
3452
3684
|
}
|
|
3453
|
-
|
|
3454
|
-
|
|
3455
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type:
|
|
3456
|
-
type:
|
|
3457
|
-
args: [{ selector: '[
|
|
3458
|
-
}], ctorParameters: function () { return [{ type:
|
|
3459
|
-
type: Output
|
|
3460
|
-
}], opDialogConfig: [{
|
|
3461
|
-
type: Input
|
|
3462
|
-
}], state: [{
|
|
3463
|
-
type: Input,
|
|
3464
|
-
args: ['opDialog']
|
|
3465
|
-
}], nativeElement: [{
|
|
3466
|
-
type: Input,
|
|
3467
|
-
args: ['opDialogOrigin']
|
|
3468
|
-
}] } });
|
|
3685
|
+
SortMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SortMenuComponent, deps: [{ token: TableStore }, { token: SortMenuComponentStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
3686
|
+
SortMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: SortMenuComponent, selector: "tb-sort-menu", providers: [SortMenuComponentStore], ngImport: i0, template: "<ng-container *ngrxLet=\"dirty$ as dirty\">\n<ng-container *ngIf=\"sorted$ | async as sorted\">\n <ng-container *ngIf=\"notSorted$ | async as notSorted\">\n <!-- Menu Trigger -->\n <span matTooltip=\"Sort\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">swap_vert</mat-icon>\n </button>\n </span>\n\n <!-- Menu -->\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\" (closed)=\"reset()\">\n <div mat-menu-item class=\"menu-button\">\n <div class=\"close-button-wrapper\">\n <span matTooltip=\"Close\">\n <mat-icon>close</mat-icon>\n </span>\n <span *ngIf=\"dirty\" matTooltip=\"Undo\" stop-propagation (click)=\"reset()\">\n <mat-icon>undo</mat-icon>\n </span>\n </div>\n </div>\n\n <!-- Apply Button -->\n <div class=\"apply-button-wrapper\">\n <button mat-button color=\"primary\" (click)=\"apply(null)\"\n stop-propagation [class.apply-border]=\"dirty\"\n [disabled]=\"!dirty\">\n Apply\n <ng-container *ngIf=\"dirty\">Unsaved Changes</ng-container>\n </button>\n </div>\n\n <!-- Default Sorting Text -->\n <div *ngIf=\"!sorted.length\" class=\"tip\" >\n Sorting List\n </div>\n\n <!-- Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #sortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[notSortedGroup]\"\n [cdkDropListData]=\"sorted\"\n (cdkDropListDropped)=\"dropIntoSorted($event)\">\n\n <!-- Menu Item Wrapper -->\n <ng-container *ngFor=\"let sort of sorted;let i=index\">\n\n <!-- Menu Item Headers -->\n <span *ngIf=\"sorted.length > 1 && i === 0 \" class=\"description\" class=\"sort-header\">First By</span>\n <span *ngIf=\"sorted.length > 1 && i !== 0 \" class=\"description\" class=\"sort-header\">Then By</span>\n\n <!-- Menu Item -->\n <div mat-menu-item cdkDrag class=\"menu-item\">\n <div class=\"sort-item\">\n <span class=\"sorted-name\">\n {{sort.displayName || (sort.active | spaceCase)}}\n <span class=\"direction-text\">{{sort.direction}}</span>\n </span>\n\n <!-- Sort Direction Buttons -->\n <div class=\"up-down-buttons-wrapper\">\n <button class=\"up-down-button up-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.asc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction !== SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_upward\n </mat-icon>\n </button>\n\n <button class=\"up-down-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.desc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction === SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_downward\n </mat-icon>\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n </div>\n\n <!-- Default Not Sorted Text -->\n <div *ngIf=\"!notSorted.length\" class=\"tip\" >\n Not Sorted List\n </div>\n <!-- Not Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #notSortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[sortedGroup]\"\n [cdkDropListData]=\"notSorted\"\n (cdkDropListDropped)=\"dropIntoNotSorted($event)\">\n <div mat-menu-item *ngFor=\"let sort of notSorted\" class=\"menu-item\" cdkDrag>\n <span class=\"not-sorted-name\">{{sort.displayName || (sort.active | spaceCase)}}</span>\n </div>\n </div>\n </mat-menu>\n </ng-container>\n</ng-container>\n</ng-container>\n", styles: [".cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.list{padding:5px 2px;border-bottom:solid 1px #ccc;color:#000000de;background:white}.light-arrow{color:#93b1ea78}.dark-arrow{color:#224e9c}.up-down-button{background-color:#fff;border-radius:30%;border-color:#0ff;padding:1px 1px 0;border-width:.5px;cursor:pointer}.mat-icon.up-down-icon{margin-right:0;font-size:20px;font-weight:lighter}.sort-item{display:flex;align-items:center;justify-content:space-between}.up-down-buttons-wrapper{margin-left:2rem}.up-button{margin-right:.3rem}.mat-menu-item.menu-item,.mat-menu-item.menu-button{padding:0 3px;font-size:17px;font-weight:700;line-height:25px;height:30px}.mat-menu-item.menu-item{cursor:move}.sorted-name{color:#224e9c}.not-sorted-name{color:#93b1ea}.apply-border{border:#224e9c solid .5px}.apply-border:hover{background-color:#faebd7}.apply-button-wrapper{display:grid;justify-content:center}.sort-header{font-size:10px;font-style:italic}.tip{padding:0 3px;color:#d3d3d3}.direction-text{font-size:small;font-weight:400}.close-button-wrapper{display:flex;flex-direction:row-reverse}\n"], components: [{ type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: i12.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i12.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], pipes: { "async": i1$1.AsyncPipe, "spaceCase": SpaceCasePipe } });
|
|
3687
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: SortMenuComponent, decorators: [{
|
|
3688
|
+
type: Component,
|
|
3689
|
+
args: [{ selector: 'tb-sort-menu', providers: [SortMenuComponentStore], template: "<ng-container *ngrxLet=\"dirty$ as dirty\">\n<ng-container *ngIf=\"sorted$ | async as sorted\">\n <ng-container *ngIf=\"notSorted$ | async as notSorted\">\n <!-- Menu Trigger -->\n <span matTooltip=\"Sort\">\n <button mat-icon-button [matMenuTriggerFor]=\"menu\">\n <mat-icon color=\"primary\">swap_vert</mat-icon>\n </button>\n </span>\n\n <!-- Menu -->\n <mat-menu #menu=\"matMenu\" class=\"my-mat-menu\" (closed)=\"reset()\">\n <div mat-menu-item class=\"menu-button\">\n <div class=\"close-button-wrapper\">\n <span matTooltip=\"Close\">\n <mat-icon>close</mat-icon>\n </span>\n <span *ngIf=\"dirty\" matTooltip=\"Undo\" stop-propagation (click)=\"reset()\">\n <mat-icon>undo</mat-icon>\n </span>\n </div>\n </div>\n\n <!-- Apply Button -->\n <div class=\"apply-button-wrapper\">\n <button mat-button color=\"primary\" (click)=\"apply(null)\"\n stop-propagation [class.apply-border]=\"dirty\"\n [disabled]=\"!dirty\">\n Apply\n <ng-container *ngIf=\"dirty\">Unsaved Changes</ng-container>\n </button>\n </div>\n\n <!-- Default Sorting Text -->\n <div *ngIf=\"!sorted.length\" class=\"tip\" >\n Sorting List\n </div>\n\n <!-- Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #sortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[notSortedGroup]\"\n [cdkDropListData]=\"sorted\"\n (cdkDropListDropped)=\"dropIntoSorted($event)\">\n\n <!-- Menu Item Wrapper -->\n <ng-container *ngFor=\"let sort of sorted;let i=index\">\n\n <!-- Menu Item Headers -->\n <span *ngIf=\"sorted.length > 1 && i === 0 \" class=\"description\" class=\"sort-header\">First By</span>\n <span *ngIf=\"sorted.length > 1 && i !== 0 \" class=\"description\" class=\"sort-header\">Then By</span>\n\n <!-- Menu Item -->\n <div mat-menu-item cdkDrag class=\"menu-item\">\n <div class=\"sort-item\">\n <span class=\"sorted-name\">\n {{sort.displayName || (sort.active | spaceCase)}}\n <span class=\"direction-text\">{{sort.direction}}</span>\n </span>\n\n <!-- Sort Direction Buttons -->\n <div class=\"up-down-buttons-wrapper\">\n <button class=\"up-down-button up-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.asc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction !== SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_upward\n </mat-icon>\n </button>\n\n <button class=\"up-down-button\" stop-propagation\n (click)=\"setDirection({active:sort.active,direction:SortDirection.desc,displayName:sort.displayName})\">\n <mat-icon [ngClass]=\"sort.direction === SortDirection.asc ? 'light-arrow' : 'dark-arrow'\" class=\"up-down-icon\">\n arrow_downward\n </mat-icon>\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n </div>\n\n <!-- Default Not Sorted Text -->\n <div *ngIf=\"!notSorted.length\" class=\"tip\" >\n Not Sorted List\n </div>\n <!-- Not Sorted Menu List -->\n <div class=\"list\"\n cdkDropList\n #notSortedGroup=\"cdkDropList\"\n [cdkDropListConnectedTo]=\"[sortedGroup]\"\n [cdkDropListData]=\"notSorted\"\n (cdkDropListDropped)=\"dropIntoNotSorted($event)\">\n <div mat-menu-item *ngFor=\"let sort of notSorted\" class=\"menu-item\" cdkDrag>\n <span class=\"not-sorted-name\">{{sort.displayName || (sort.active | spaceCase)}}</span>\n </div>\n </div>\n </mat-menu>\n </ng-container>\n</ng-container>\n</ng-container>\n", styles: [".cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.list{padding:5px 2px;border-bottom:solid 1px #ccc;color:#000000de;background:white}.light-arrow{color:#93b1ea78}.dark-arrow{color:#224e9c}.up-down-button{background-color:#fff;border-radius:30%;border-color:#0ff;padding:1px 1px 0;border-width:.5px;cursor:pointer}.mat-icon.up-down-icon{margin-right:0;font-size:20px;font-weight:lighter}.sort-item{display:flex;align-items:center;justify-content:space-between}.up-down-buttons-wrapper{margin-left:2rem}.up-button{margin-right:.3rem}.mat-menu-item.menu-item,.mat-menu-item.menu-button{padding:0 3px;font-size:17px;font-weight:700;line-height:25px;height:30px}.mat-menu-item.menu-item{cursor:move}.sorted-name{color:#224e9c}.not-sorted-name{color:#93b1ea}.apply-border{border:#224e9c solid .5px}.apply-border:hover{background-color:#faebd7}.apply-button-wrapper{display:grid;justify-content:center}.sort-header{font-size:10px;font-style:italic}.tip{padding:0 3px;color:#d3d3d3}.direction-text{font-size:small;font-weight:400}.close-button-wrapper{display:flex;flex-direction:row-reverse}\n"] }]
|
|
3690
|
+
}], ctorParameters: function () { return [{ type: TableStore }, { type: SortMenuComponentStore }]; } });
|
|
3469
3691
|
|
|
3470
3692
|
class TableContainerComponent {
|
|
3471
3693
|
constructor(state, exportToCsvService, config, store, wrapper) {
|
|
@@ -3514,7 +3736,7 @@ class TableContainerComponent {
|
|
|
3514
3736
|
this.state.setTableSettings(this.tableBuilder.settings);
|
|
3515
3737
|
this.state.runOnceWhen(stateIs(InitializationState.MetaDataLoaded), state => {
|
|
3516
3738
|
if (this.tableId) {
|
|
3517
|
-
const persistedState$ = this.store.pipe(select(selectLocalProfileState(this.tableId)), first(), tap(persistedState => {
|
|
3739
|
+
const persistedState$ = this.store.pipe(select(selectLocalProfileState(this.tableId)), first$1(), tap(persistedState => {
|
|
3518
3740
|
if (!persistedState) {
|
|
3519
3741
|
this.state.setIntializationState(InitializationState.LoadedFromStore);
|
|
3520
3742
|
}
|
|
@@ -3550,7 +3772,7 @@ class TableContainerComponent {
|
|
|
3550
3772
|
this.exportToCsvService.exportToCsv(sorted);
|
|
3551
3773
|
}
|
|
3552
3774
|
saveState() {
|
|
3553
|
-
this.state.getSavableState().pipe(first()).subscribe(tableState => {
|
|
3775
|
+
this.state.getSavableState().pipe(first$1()).subscribe(tableState => {
|
|
3554
3776
|
this.OnSaveState.next(null);
|
|
3555
3777
|
this.store.dispatch(setLocalProfile({ key: this.tableId, value: tableState, persist: true }));
|
|
3556
3778
|
});
|
|
@@ -3591,7 +3813,7 @@ class TableContainerComponent {
|
|
|
3591
3813
|
customFilters.push(f);
|
|
3592
3814
|
}
|
|
3593
3815
|
});
|
|
3594
|
-
const filters$ = from(customFilters.map(cf => cf.filter$)).pipe(mergeAll(), scan((a, b) => {
|
|
3816
|
+
const filters$ = from(customFilters.map(cf => cf.filter$)).pipe(mergeAll(), scan$1((a, b) => {
|
|
3595
3817
|
if (b.active) {
|
|
3596
3818
|
a[b.filterId] = isCustomFilter(b) ? b.predicate : createFilterFunc(b);
|
|
3597
3819
|
}
|
|
@@ -3643,7 +3865,7 @@ class TableContainerComponent {
|
|
|
3643
3865
|
}
|
|
3644
3866
|
}
|
|
3645
3867
|
TableContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: TableContainerComponent, deps: [{ token: TableStore }, { token: ExportToCsvService }, { token: TableBuilderConfigToken }, { token: i3$3.Store }, { token: TableWrapperDirective, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
3646
|
-
TableContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: TableContainerComponent, selector: "tb-table-container", inputs: { tableId: "tableId", tableBuilder: "tableBuilder", IndexColumn: "IndexColumn", SelectionColumn: "SelectionColumn", trackBy: "trackBy", isSticky: "isSticky", pageSize: "pageSize", inputFilters: "inputFilters" }, outputs: { selection$: "selection$", data: "data", OnStateReset: "OnStateReset", OnSaveState: "OnSaveState", state$: "state$" }, providers: [TableStore, ExportToCsvService, WrapperFilterStore], queries: [{ propertyName: "customFilters", predicate: TableCustomFilterDirective, descendants: true }, { propertyName: "filters", predicate: TableFilterDirective, descendants: true }, { propertyName: "customRows", predicate: MatRowDef }, { propertyName: "customCells", predicate: CustomCellDirective }], ngImport: i0, template: "<ng-content select=\"[before]\" >\n</ng-content>\n\n<ng-container multiSort [matSortDisabled]=\"disableSort\">\n <ng-container *ngrxLet=\"state.tableSettings$ as tableSettings\">\n\n\n <div class=\"header-wrapper\">\n <div class=\"title\">\n <ng-content select=\".tb-header-title\"\n *ngIf=\"(!(collapseHeader$ | async)) || tableSettings.showTitleWhenHeaderCollapsed\">\n\n </ng-content>\n </div>\n <div class=\"flx-row-end\">\n <lib-filter-list></lib-filter-list>\n <ng-container *ngIf=\"!tableSettings.hideHeader\">\n <ng-container *ngIf=\"!(collapseHeader$ | async); else allMenu\">\n <ng-container *ngTemplateOutlet=\"headerMenu\"></ng-container>\n <button mat-icon-button color='primary' [matMenuTriggerFor]=\"mainMenu\"\n [ngClass]=\"{'flat-menu':(collapseHeader$ | async)}\">\n <mat-icon>{{(collapseHeader$ | async) ? 'more_horiz' : 'more_vert'}}</mat-icon>\n </button>\n <mat-menu #mainMenu='matMenu'>\n <ng-container *ngTemplateOutlet=\"headerMenuExtra\"></ng-container>\n </mat-menu>\n </ng-container>\n <ng-template #allMenu>\n <button mat-icon-button color='primary' [matMenuTriggerFor]=\"mainMenu\"\n [ngClass]=\"{'flat-menu':(collapseHeader$ | async)}\">\n <mat-icon>{{(collapseHeader$ | async) ? 'more_horiz' : 'more_vert'}}</mat-icon>\n </button>\n <mat-menu #mainMenu='matMenu'>\n <div class=\"flex-column\">\n <ng-container *ngTemplateOutlet=\"headerMenu\"></ng-container>\n </div>\n <ng-container *ngTemplateOutlet=\"headerMenuExtra\"></ng-container>\n </mat-menu>\n </ng-template>\n <mat-icon [matTooltip]=\"(collapseHeader$ | async) ? 'expand' : 'collapse'\" class=\"collapse-icon header\"\n (click)=\"state.toggleCollapseHeader()\">\n {{(collapseHeader$ | async) ? 'expand_less' : 'expand_more'}}\n </mat-icon>\n </ng-container>\n </div>\n </div>\n\n <div style=\"clear: both;\">\n <tb-generic-table [rows]='customRows' [data$]=\"data\" [IndexColumn]='IndexColumn'\n [SelectionColumn]='SelectionColumn' (selection$)='selection$.emit($event)' [trackBy]='trackBy'\n [isSticky]='isSticky' [columnInfos]='myColumns$' [disableSort]=\"disableSort\">\n </tb-generic-table>\n </div>\n\n\n\n <ng-template #headerMenu>\n <ng-container>\n <tb-filter-displayer *ngIf=\"!tableSettings.hideFilter\">\n </tb-filter-displayer>\n <tb-col-displayer *ngIf=\"!tableSettings.hideColumnSettings\"></tb-col-displayer>\n <tb-sort-menu *ngIf=\"!tableSettings.hideSort\"></tb-sort-menu>\n </ng-container>\n </ng-template>\n <ng-template #headerMenuExtra>\n <button mat-menu-item (click)=\"resetState()\">\n <mat-icon color=\"primary\">autorenew</mat-icon>\n <span>Reset table</span>\n </button>\n <button mat-menu-item (click)=\"exportToCsv()\" *ngIf=\"!tableSettings.hideExport\">\n <mat-icon color=\"primary\">file_download</mat-icon>\n <span>Export Table</span>\n </button>\n <ng-container *ngIf=\"currentStateKey$ | async as currentKey\">\n <button mat-menu-item *ngIf=\"tableId\" (click)=\"saveState()\">\n <mat-icon color=\"primary\">save</mat-icon>\n <span>Save to {{currentKey}}</span>\n </button>\n <button *ngIf='tableId' mat-menu-item [matMenuTriggerFor]=\"savedNames\">\n <span>Choose Profile</span>\n </button>\n </ng-container>\n\n <mat-menu #savedNames='matMenu' panelClass='wide-menu'>\n <button mat-menu-item clickEmitter #add='clickEmitter'>\n <mat-icon>add</mat-icon>\n <span>New</span>\n </button>\n <ng-container *ngFor='let key of stateKeys$ | async'>\n <button mat-menu-item (click)='setProfileState(key)'>\n <div style='display: flex; align-items: center; justify-content: space-between;'>\n <span style='display:flex;'>{{key}}</span>\n <span style='display:flex;'>\n <span style=\"width: 120px;\"></span>\n <mat-icon color='warn' (click)='deleteProfileState(key)' stop-propagation>delete_forever</mat-icon>\n </span>\n </div>\n </button>\n </ng-container>\n </mat-menu>\n <div *opDialog='add'>\n <mat-form-field>\n <input style='width:90%' matInput #addedKey />\n </mat-form-field>\n <button mat-button (click)='setProfileState(addedKey.value); add.next(false);'\n [disabled]=\"!addedKey.value\">Add</button>\n </div>\n </ng-template>\n\n </ng-container>\n\n</ng-container>\n", styles: [".wide-menu{width:200px!important}.header-wrapper{display:flex;flex-direction:row;justify-content:space-between;width:100%}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center}.flat-menu{line-height:initial;height:initial}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"], components: [{ type: FilterChipsComponent, selector: "lib-filter-list" }, { type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: GenericTableComponent, selector: "tb-generic-table", inputs: ["data$", "IndexColumn", "SelectionColumn", "trackBy", "rows", "isSticky", "columnBuilders", "columnInfos", "disableSort"], outputs: ["selection$"] }, { type: GenFilterDisplayerComponent, selector: "tb-filter-displayer" }, { type: GenColDisplayerComponent, selector: "tb-col-displayer" }, { type: SortMenuComponent, selector: "tb-sort-menu" }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }], directives: [{ type: MultiSortDirective, selector: "[multiSort]", inputs: ["matSortDisabled"], exportAs: ["multiSort"] }, { type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type:
|
|
3868
|
+
TableContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: TableContainerComponent, selector: "tb-table-container", inputs: { tableId: "tableId", tableBuilder: "tableBuilder", IndexColumn: "IndexColumn", SelectionColumn: "SelectionColumn", trackBy: "trackBy", isSticky: "isSticky", pageSize: "pageSize", inputFilters: "inputFilters" }, outputs: { selection$: "selection$", data: "data", OnStateReset: "OnStateReset", OnSaveState: "OnSaveState", state$: "state$" }, providers: [TableStore, ExportToCsvService, WrapperFilterStore], queries: [{ propertyName: "customFilters", predicate: TableCustomFilterDirective, descendants: true }, { propertyName: "filters", predicate: TableFilterDirective, descendants: true }, { propertyName: "customRows", predicate: MatRowDef }, { propertyName: "customCells", predicate: CustomCellDirective }], ngImport: i0, template: "<ng-content select=\"[before]\" >\n</ng-content>\n\n<ng-container multiSort [matSortDisabled]=\"disableSort\">\n <ng-container *ngrxLet=\"state.tableSettings$ as tableSettings\">\n\n\n <div class=\"header-wrapper\">\n <div class=\"title\">\n <ng-content select=\".tb-header-title\"\n *ngIf=\"(!(collapseHeader$ | async)) || tableSettings.showTitleWhenHeaderCollapsed\">\n\n </ng-content>\n </div>\n <div class=\"flx-row-end\">\n <lib-filter-list></lib-filter-list>\n <ng-container *ngIf=\"!tableSettings.hideHeader\">\n <ng-container *ngIf=\"!(collapseHeader$ | async); else allMenu\">\n <ng-container *ngTemplateOutlet=\"headerMenu\"></ng-container>\n <button mat-icon-button color='primary' [matMenuTriggerFor]=\"mainMenu\"\n [ngClass]=\"{'flat-menu':(collapseHeader$ | async)}\">\n <mat-icon>{{(collapseHeader$ | async) ? 'more_horiz' : 'more_vert'}}</mat-icon>\n </button>\n <mat-menu #mainMenu='matMenu'>\n <ng-container *ngTemplateOutlet=\"headerMenuExtra\"></ng-container>\n </mat-menu>\n </ng-container>\n <ng-template #allMenu>\n <button mat-icon-button color='primary' [matMenuTriggerFor]=\"mainMenu\"\n [ngClass]=\"{'flat-menu':(collapseHeader$ | async)}\">\n <mat-icon>{{(collapseHeader$ | async) ? 'more_horiz' : 'more_vert'}}</mat-icon>\n </button>\n <mat-menu #mainMenu='matMenu'>\n <div class=\"flex-column\">\n <ng-container *ngTemplateOutlet=\"headerMenu\"></ng-container>\n </div>\n <ng-container *ngTemplateOutlet=\"headerMenuExtra\"></ng-container>\n </mat-menu>\n </ng-template>\n <mat-icon [matTooltip]=\"(collapseHeader$ | async) ? 'expand' : 'collapse'\" class=\"collapse-icon header\"\n (click)=\"state.toggleCollapseHeader()\">\n {{(collapseHeader$ | async) ? 'expand_less' : 'expand_more'}}\n </mat-icon>\n </ng-container>\n </div>\n </div>\n\n <div style=\"clear: both;\">\n <tb-generic-table [rows]='customRows' [data$]=\"data\" [IndexColumn]='IndexColumn'\n [SelectionColumn]='SelectionColumn' (selection$)='selection$.emit($event)' [trackBy]='trackBy'\n [isSticky]='isSticky' [columnInfos]='myColumns$' [disableSort]=\"disableSort\">\n </tb-generic-table>\n </div>\n\n\n\n <ng-template #headerMenu>\n <ng-container>\n <tb-filter-displayer *ngIf=\"!tableSettings.hideFilter\">\n </tb-filter-displayer>\n <tb-col-displayer *ngIf=\"!tableSettings.hideColumnSettings\"></tb-col-displayer>\n <tb-sort-menu *ngIf=\"!tableSettings.hideSort\"></tb-sort-menu>\n </ng-container>\n </ng-template>\n <ng-template #headerMenuExtra>\n <button mat-menu-item (click)=\"resetState()\">\n <mat-icon color=\"primary\">autorenew</mat-icon>\n <span>Reset table</span>\n </button>\n <button mat-menu-item (click)=\"exportToCsv()\" *ngIf=\"!tableSettings.hideExport\">\n <mat-icon color=\"primary\">file_download</mat-icon>\n <span>Export Table</span>\n </button>\n <ng-container *ngIf=\"currentStateKey$ | async as currentKey\">\n <button mat-menu-item *ngIf=\"tableId\" (click)=\"saveState()\">\n <mat-icon color=\"primary\">save</mat-icon>\n <span>Save to {{currentKey}}</span>\n </button>\n <button *ngIf='tableId' mat-menu-item [matMenuTriggerFor]=\"savedNames\">\n <span>Choose Profile</span>\n </button>\n </ng-container>\n\n <mat-menu #savedNames='matMenu' panelClass='wide-menu'>\n <button mat-menu-item clickEmitter #add='clickEmitter'>\n <mat-icon>add</mat-icon>\n <span>New</span>\n </button>\n <ng-container *ngFor='let key of stateKeys$ | async'>\n <button mat-menu-item (click)='setProfileState(key)'>\n <div style='display: flex; align-items: center; justify-content: space-between;'>\n <span style='display:flex;'>{{key}}</span>\n <span style='display:flex;'>\n <span style=\"width: 120px;\"></span>\n <mat-icon color='warn' (click)='deleteProfileState(key)' stop-propagation>delete_forever</mat-icon>\n </span>\n </div>\n </button>\n </ng-container>\n </mat-menu>\n <div *opDialog='add'>\n <mat-form-field>\n <input style='width:90%' matInput #addedKey />\n </mat-form-field>\n <button mat-button (click)='setProfileState(addedKey.value); add.next(false);'\n [disabled]=\"!addedKey.value\">Add</button>\n </div>\n </ng-template>\n\n </ng-container>\n\n</ng-container>\n", styles: [".wide-menu{width:200px!important}.header-wrapper{display:flex;flex-direction:row;justify-content:space-between;width:100%}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center}.flat-menu{line-height:initial;height:initial}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"], components: [{ type: FilterChipsComponent, selector: "lib-filter-list" }, { type: i3$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: GenericTableComponent, selector: "tb-generic-table", inputs: ["data$", "IndexColumn", "SelectionColumn", "trackBy", "rows", "isSticky", "columnBuilders", "columnInfos", "disableSort"], outputs: ["selection$"] }, { type: GenFilterDisplayerComponent, selector: "tb-filter-displayer" }, { type: GenColDisplayerComponent, selector: "tb-col-displayer" }, { type: SortMenuComponent, selector: "tb-sort-menu" }, { type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { type: i6.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }], directives: [{ type: MultiSortDirective, selector: "[multiSort]", inputs: ["matSortDisabled"], exportAs: ["multiSort"] }, { type: i7$1.LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i8$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { type: ClickEmitterDirective, selector: "[clickEmitter]", exportAs: ["clickEmitter"] }, { type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: StopPropagationDirective, selector: "[stop-propagation]" }, { type: DialogDirective, selector: "[opDialog]", inputs: ["opDialogConfig", "opDialog", "opDialogOrigin"], outputs: ["opDialogClosed"] }, { type: i4$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }], pipes: { "async": i1$1.AsyncPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
3647
3869
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: TableContainerComponent, decorators: [{
|
|
3648
3870
|
type: Component,
|
|
3649
3871
|
args: [{ selector: 'tb-table-container', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TableStore, ExportToCsvService, WrapperFilterStore], template: "<ng-content select=\"[before]\" >\n</ng-content>\n\n<ng-container multiSort [matSortDisabled]=\"disableSort\">\n <ng-container *ngrxLet=\"state.tableSettings$ as tableSettings\">\n\n\n <div class=\"header-wrapper\">\n <div class=\"title\">\n <ng-content select=\".tb-header-title\"\n *ngIf=\"(!(collapseHeader$ | async)) || tableSettings.showTitleWhenHeaderCollapsed\">\n\n </ng-content>\n </div>\n <div class=\"flx-row-end\">\n <lib-filter-list></lib-filter-list>\n <ng-container *ngIf=\"!tableSettings.hideHeader\">\n <ng-container *ngIf=\"!(collapseHeader$ | async); else allMenu\">\n <ng-container *ngTemplateOutlet=\"headerMenu\"></ng-container>\n <button mat-icon-button color='primary' [matMenuTriggerFor]=\"mainMenu\"\n [ngClass]=\"{'flat-menu':(collapseHeader$ | async)}\">\n <mat-icon>{{(collapseHeader$ | async) ? 'more_horiz' : 'more_vert'}}</mat-icon>\n </button>\n <mat-menu #mainMenu='matMenu'>\n <ng-container *ngTemplateOutlet=\"headerMenuExtra\"></ng-container>\n </mat-menu>\n </ng-container>\n <ng-template #allMenu>\n <button mat-icon-button color='primary' [matMenuTriggerFor]=\"mainMenu\"\n [ngClass]=\"{'flat-menu':(collapseHeader$ | async)}\">\n <mat-icon>{{(collapseHeader$ | async) ? 'more_horiz' : 'more_vert'}}</mat-icon>\n </button>\n <mat-menu #mainMenu='matMenu'>\n <div class=\"flex-column\">\n <ng-container *ngTemplateOutlet=\"headerMenu\"></ng-container>\n </div>\n <ng-container *ngTemplateOutlet=\"headerMenuExtra\"></ng-container>\n </mat-menu>\n </ng-template>\n <mat-icon [matTooltip]=\"(collapseHeader$ | async) ? 'expand' : 'collapse'\" class=\"collapse-icon header\"\n (click)=\"state.toggleCollapseHeader()\">\n {{(collapseHeader$ | async) ? 'expand_less' : 'expand_more'}}\n </mat-icon>\n </ng-container>\n </div>\n </div>\n\n <div style=\"clear: both;\">\n <tb-generic-table [rows]='customRows' [data$]=\"data\" [IndexColumn]='IndexColumn'\n [SelectionColumn]='SelectionColumn' (selection$)='selection$.emit($event)' [trackBy]='trackBy'\n [isSticky]='isSticky' [columnInfos]='myColumns$' [disableSort]=\"disableSort\">\n </tb-generic-table>\n </div>\n\n\n\n <ng-template #headerMenu>\n <ng-container>\n <tb-filter-displayer *ngIf=\"!tableSettings.hideFilter\">\n </tb-filter-displayer>\n <tb-col-displayer *ngIf=\"!tableSettings.hideColumnSettings\"></tb-col-displayer>\n <tb-sort-menu *ngIf=\"!tableSettings.hideSort\"></tb-sort-menu>\n </ng-container>\n </ng-template>\n <ng-template #headerMenuExtra>\n <button mat-menu-item (click)=\"resetState()\">\n <mat-icon color=\"primary\">autorenew</mat-icon>\n <span>Reset table</span>\n </button>\n <button mat-menu-item (click)=\"exportToCsv()\" *ngIf=\"!tableSettings.hideExport\">\n <mat-icon color=\"primary\">file_download</mat-icon>\n <span>Export Table</span>\n </button>\n <ng-container *ngIf=\"currentStateKey$ | async as currentKey\">\n <button mat-menu-item *ngIf=\"tableId\" (click)=\"saveState()\">\n <mat-icon color=\"primary\">save</mat-icon>\n <span>Save to {{currentKey}}</span>\n </button>\n <button *ngIf='tableId' mat-menu-item [matMenuTriggerFor]=\"savedNames\">\n <span>Choose Profile</span>\n </button>\n </ng-container>\n\n <mat-menu #savedNames='matMenu' panelClass='wide-menu'>\n <button mat-menu-item clickEmitter #add='clickEmitter'>\n <mat-icon>add</mat-icon>\n <span>New</span>\n </button>\n <ng-container *ngFor='let key of stateKeys$ | async'>\n <button mat-menu-item (click)='setProfileState(key)'>\n <div style='display: flex; align-items: center; justify-content: space-between;'>\n <span style='display:flex;'>{{key}}</span>\n <span style='display:flex;'>\n <span style=\"width: 120px;\"></span>\n <mat-icon color='warn' (click)='deleteProfileState(key)' stop-propagation>delete_forever</mat-icon>\n </span>\n </div>\n </button>\n </ng-container>\n </mat-menu>\n <div *opDialog='add'>\n <mat-form-field>\n <input style='width:90%' matInput #addedKey />\n </mat-form-field>\n <button mat-button (click)='setProfileState(addedKey.value); add.next(false);'\n [disabled]=\"!addedKey.value\">Add</button>\n </div>\n </ng-template>\n\n </ng-container>\n\n</ng-container>\n", styles: [".wide-menu{width:200px!important}.header-wrapper{display:flex;flex-direction:row;justify-content:space-between;width:100%}.flx-row-end{display:flex;flex-direction:row;justify-content:flex-end;align-items:center}.flat-menu{line-height:initial;height:initial}\n", ".collapse-icon{font-size:16px;height:16px;padding-bottom:.2rem;color:#3f51b5}.collapse-icon.header{align-self:flex-end}.collapse-icon.footer{align-self:flex-start}.collapse-icon:hover{cursor:pointer}.hide{display:none}\n"] }]
|
|
@@ -3786,168 +4008,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImpor
|
|
|
3786
4008
|
type: Injectable
|
|
3787
4009
|
}], ctorParameters: function () { return [{ type: i1$4.Actions }, { type: i3$3.Store }]; } });
|
|
3788
4010
|
|
|
3789
|
-
class PreventEnterDirective {
|
|
3790
|
-
onKeyDown() {
|
|
3791
|
-
return false;
|
|
3792
|
-
}
|
|
3793
|
-
}
|
|
3794
|
-
PreventEnterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: PreventEnterDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3795
|
-
PreventEnterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: PreventEnterDirective, selector: "preventEnter", host: { listeners: { "keydown.enter": "onKeyDown($event)" } }, ngImport: i0 });
|
|
3796
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: PreventEnterDirective, decorators: [{
|
|
3797
|
-
type: Directive,
|
|
3798
|
-
args: [{
|
|
3799
|
-
selector: 'preventEnter'
|
|
3800
|
-
}]
|
|
3801
|
-
}], propDecorators: { onKeyDown: [{
|
|
3802
|
-
type: HostListener,
|
|
3803
|
-
args: ['keydown.enter', ['$event']]
|
|
3804
|
-
}] } });
|
|
3805
|
-
|
|
3806
|
-
class ClickSubjectDirective extends Subject {
|
|
3807
|
-
constructor() {
|
|
3808
|
-
super();
|
|
3809
|
-
}
|
|
3810
|
-
set clickSubject(val) {
|
|
3811
|
-
this._val = val;
|
|
3812
|
-
}
|
|
3813
|
-
}
|
|
3814
|
-
ClickSubjectDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickSubjectDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3815
|
-
ClickSubjectDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: ClickSubjectDirective, selector: "[clickSubject]", inputs: { clickSubject: "clickSubject" }, host: { listeners: { "click": "next(this._val)" } }, exportAs: ["clickSubject"], usesInheritance: true, ngImport: i0 });
|
|
3816
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ClickSubjectDirective, decorators: [{
|
|
3817
|
-
type: Directive,
|
|
3818
|
-
args: [{
|
|
3819
|
-
selector: '[clickSubject]',
|
|
3820
|
-
exportAs: 'clickSubject',
|
|
3821
|
-
host: {
|
|
3822
|
-
'(click)': 'next(this._val)'
|
|
3823
|
-
}
|
|
3824
|
-
}]
|
|
3825
|
-
}], ctorParameters: function () { return []; }, propDecorators: { clickSubject: [{
|
|
3826
|
-
type: Input,
|
|
3827
|
-
args: ['clickSubject']
|
|
3828
|
-
}] } });
|
|
3829
|
-
|
|
3830
|
-
class MatSlideToggleGroupDirective {
|
|
3831
|
-
constructor() {
|
|
3832
|
-
this.allowMultiple = false;
|
|
3833
|
-
this._ready = new ReplaySubject(1);
|
|
3834
|
-
}
|
|
3835
|
-
set toggles(val) {
|
|
3836
|
-
this._toggles = val;
|
|
3837
|
-
this._ready.next(true);
|
|
3838
|
-
}
|
|
3839
|
-
get valueEmitter() {
|
|
3840
|
-
return this._ready.pipe(switchMap$1(_ => this.getObs()));
|
|
3841
|
-
}
|
|
3842
|
-
getInitValue() {
|
|
3843
|
-
const startValue = this._toggles.reduce((prev, cur) => {
|
|
3844
|
-
if (!cur.name) {
|
|
3845
|
-
throw new Error('toggle must have the name attribute set');
|
|
3846
|
-
}
|
|
3847
|
-
prev[cur.name] = cur.checked;
|
|
3848
|
-
return prev;
|
|
3849
|
-
}, {});
|
|
3850
|
-
return startValue;
|
|
3851
|
-
}
|
|
3852
|
-
getObs() {
|
|
3853
|
-
var toggleChanges = merge$1(...this._toggles.map(toggle => toggle.change));
|
|
3854
|
-
const startValue = this.getInitValue();
|
|
3855
|
-
return toggleChanges.pipe(scan$1((prev, cur) => {
|
|
3856
|
-
const toggleName = cur.source.name;
|
|
3857
|
-
const newVal = Object.assign(Object.assign({}, prev), { [toggleName]: cur.checked });
|
|
3858
|
-
if (cur.checked && !this.allowMultiple) {
|
|
3859
|
-
Object.keys(prev)
|
|
3860
|
-
.filter(key => key !== toggleName && prev[key])
|
|
3861
|
-
.forEach(key => {
|
|
3862
|
-
newVal[key] = false;
|
|
3863
|
-
this._toggles.find(toggle => toggle.name === key).toggle();
|
|
3864
|
-
});
|
|
3865
|
-
}
|
|
3866
|
-
return newVal;
|
|
3867
|
-
}, startValue), startWith$1(startValue));
|
|
3868
|
-
}
|
|
3869
|
-
}
|
|
3870
|
-
MatSlideToggleGroupDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: MatSlideToggleGroupDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3871
|
-
MatSlideToggleGroupDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.5", type: MatSlideToggleGroupDirective, selector: "[opMatSlideToggleGroup]", inputs: { allowMultiple: "allowMultiple" }, outputs: { valueEmitter: "valueEmitter" }, queries: [{ propertyName: "toggles", predicate: MatSlideToggle }], ngImport: i0 });
|
|
3872
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: MatSlideToggleGroupDirective, decorators: [{
|
|
3873
|
-
type: Directive,
|
|
3874
|
-
args: [{ selector: '[opMatSlideToggleGroup]', }]
|
|
3875
|
-
}], propDecorators: { allowMultiple: [{
|
|
3876
|
-
type: Input
|
|
3877
|
-
}], toggles: [{
|
|
3878
|
-
type: ContentChildren,
|
|
3879
|
-
args: [MatSlideToggle]
|
|
3880
|
-
}], valueEmitter: [{
|
|
3881
|
-
type: Output
|
|
3882
|
-
}] } });
|
|
3883
|
-
|
|
3884
|
-
class UtilitiesModule {
|
|
3885
|
-
}
|
|
3886
|
-
UtilitiesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
3887
|
-
UtilitiesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, declarations: [SpaceCasePipe,
|
|
3888
|
-
PhoneNumberPipe,
|
|
3889
|
-
FunctionPipe,
|
|
3890
|
-
StopPropagationDirective,
|
|
3891
|
-
StylerDirective,
|
|
3892
|
-
PreventEnterDirective,
|
|
3893
|
-
AutoFocusDirective,
|
|
3894
|
-
ClickSubjectDirective,
|
|
3895
|
-
ClickEmitterDirective,
|
|
3896
|
-
DialogDirective,
|
|
3897
|
-
MatSlideToggleGroupDirective], exports: [StopPropagationDirective,
|
|
3898
|
-
PreventEnterDirective,
|
|
3899
|
-
SpaceCasePipe,
|
|
3900
|
-
PhoneNumberPipe,
|
|
3901
|
-
FunctionPipe,
|
|
3902
|
-
StopPropagationDirective,
|
|
3903
|
-
StylerDirective,
|
|
3904
|
-
PreventEnterDirective,
|
|
3905
|
-
AutoFocusDirective,
|
|
3906
|
-
ClickSubjectDirective,
|
|
3907
|
-
ClickEmitterDirective,
|
|
3908
|
-
DialogDirective,
|
|
3909
|
-
MatSlideToggleGroupDirective] });
|
|
3910
|
-
UtilitiesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, providers: [
|
|
3911
|
-
DialogService
|
|
3912
|
-
], imports: [[]] });
|
|
3913
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: UtilitiesModule, decorators: [{
|
|
3914
|
-
type: NgModule,
|
|
3915
|
-
args: [{
|
|
3916
|
-
imports: [],
|
|
3917
|
-
exports: [
|
|
3918
|
-
StopPropagationDirective,
|
|
3919
|
-
PreventEnterDirective,
|
|
3920
|
-
SpaceCasePipe,
|
|
3921
|
-
PhoneNumberPipe,
|
|
3922
|
-
FunctionPipe,
|
|
3923
|
-
StopPropagationDirective,
|
|
3924
|
-
StylerDirective,
|
|
3925
|
-
PreventEnterDirective,
|
|
3926
|
-
AutoFocusDirective,
|
|
3927
|
-
ClickSubjectDirective,
|
|
3928
|
-
ClickEmitterDirective,
|
|
3929
|
-
DialogDirective,
|
|
3930
|
-
MatSlideToggleGroupDirective,
|
|
3931
|
-
],
|
|
3932
|
-
declarations: [
|
|
3933
|
-
SpaceCasePipe,
|
|
3934
|
-
PhoneNumberPipe,
|
|
3935
|
-
FunctionPipe,
|
|
3936
|
-
StopPropagationDirective,
|
|
3937
|
-
StylerDirective,
|
|
3938
|
-
PreventEnterDirective,
|
|
3939
|
-
AutoFocusDirective,
|
|
3940
|
-
ClickSubjectDirective,
|
|
3941
|
-
ClickEmitterDirective,
|
|
3942
|
-
DialogDirective,
|
|
3943
|
-
MatSlideToggleGroupDirective,
|
|
3944
|
-
],
|
|
3945
|
-
providers: [
|
|
3946
|
-
DialogService
|
|
3947
|
-
]
|
|
3948
|
-
}]
|
|
3949
|
-
}] });
|
|
3950
|
-
|
|
3951
4011
|
class TableBuilderModule {
|
|
3952
4012
|
static forRoot(config) {
|
|
3953
4013
|
return {
|
|
@@ -4111,7 +4171,7 @@ class TableBuilder {
|
|
|
4111
4171
|
this.data$ = this.data$.pipe(defaultShareReplay());
|
|
4112
4172
|
this.metaData$ = metaData$ ?
|
|
4113
4173
|
metaData$.pipe(defaultShareReplay()) :
|
|
4114
|
-
data$.pipe(first(), map(data => this.createMetaData(data[0])), defaultShareReplay());
|
|
4174
|
+
data$.pipe(first$1(), map(data => this.createMetaData(data[0])), defaultShareReplay());
|
|
4115
4175
|
const s = isObservable(settings) ? settings : of(settings);
|
|
4116
4176
|
this.settings = s.pipe(map(sett => new GeneralTableSettings(sett)), defaultShareReplay());
|
|
4117
4177
|
}
|
|
@@ -4156,6 +4216,110 @@ const CreateTableBuilder = (reportDef$) => {
|
|
|
4156
4216
|
return new TableBuilder(reportDef$.pipe(map(r => r.data)), reportDef$.pipe(map(r => r.metaData)));
|
|
4157
4217
|
};
|
|
4158
4218
|
|
|
4219
|
+
// State
|
|
4220
|
+
class AppStatusState {
|
|
4221
|
+
}
|
|
4222
|
+
class ActionStatus {
|
|
4223
|
+
}
|
|
4224
|
+
const intitalState = {
|
|
4225
|
+
ids: [],
|
|
4226
|
+
entities: {}
|
|
4227
|
+
};
|
|
4228
|
+
var serverStatusTypes;
|
|
4229
|
+
(function (serverStatusTypes) {
|
|
4230
|
+
serverStatusTypes[serverStatusTypes["notStarted"] = 0] = "notStarted";
|
|
4231
|
+
serverStatusTypes[serverStatusTypes["inProgress"] = 1] = "inProgress";
|
|
4232
|
+
serverStatusTypes[serverStatusTypes["success"] = 2] = "success";
|
|
4233
|
+
serverStatusTypes[serverStatusTypes["error"] = 3] = "error";
|
|
4234
|
+
})(serverStatusTypes || (serverStatusTypes = {}));
|
|
4235
|
+
// Entity and Selectors
|
|
4236
|
+
const statusAdapter = createEntityAdapter(); // { selectId: a => a.id }
|
|
4237
|
+
const initialState = statusAdapter.getInitialState(intitalState);
|
|
4238
|
+
const getStatusState = createFeatureSelector('ActionStatus');
|
|
4239
|
+
const { selectIds, selectEntities, selectAll, selectTotal } = statusAdapter.getSelectors(getStatusState);
|
|
4240
|
+
const selectEntity = (id) => createSelector(selectEntities, (entities) => entities[id]);
|
|
4241
|
+
// Reducers
|
|
4242
|
+
function actionStatusReducer(state = initialState, action) {
|
|
4243
|
+
const actionStatus = _.get(action, 'payload.actionStatus');
|
|
4244
|
+
if (actionStatus) {
|
|
4245
|
+
if (state.ids.find(id => id === actionStatus.id)) {
|
|
4246
|
+
const modifiedObj = Object.assign({}, state.entities[actionStatus.id]);
|
|
4247
|
+
modifiedObj.status = actionStatus.status;
|
|
4248
|
+
modifiedObj.responsePayload = actionStatus.responsePayload;
|
|
4249
|
+
return statusAdapter.upsertOne(modifiedObj, state);
|
|
4250
|
+
}
|
|
4251
|
+
else {
|
|
4252
|
+
return statusAdapter.addOne(actionStatus, state);
|
|
4253
|
+
}
|
|
4254
|
+
}
|
|
4255
|
+
return state;
|
|
4256
|
+
}
|
|
4257
|
+
|
|
4258
|
+
class NgrxExtModule {
|
|
4259
|
+
}
|
|
4260
|
+
NgrxExtModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: NgrxExtModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
4261
|
+
NgrxExtModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: NgrxExtModule, imports: [CommonModule, i3$3.StoreFeatureModule] });
|
|
4262
|
+
NgrxExtModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: NgrxExtModule, imports: [[
|
|
4263
|
+
CommonModule,
|
|
4264
|
+
StoreModule.forFeature('ActionStatus', actionStatusReducer),
|
|
4265
|
+
]] });
|
|
4266
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: NgrxExtModule, decorators: [{
|
|
4267
|
+
type: NgModule,
|
|
4268
|
+
args: [{
|
|
4269
|
+
declarations: [],
|
|
4270
|
+
imports: [
|
|
4271
|
+
CommonModule,
|
|
4272
|
+
StoreModule.forFeature('ActionStatus', actionStatusReducer),
|
|
4273
|
+
]
|
|
4274
|
+
}]
|
|
4275
|
+
}] });
|
|
4276
|
+
|
|
4277
|
+
class ActionStateSpinnerComponent {
|
|
4278
|
+
constructor() {
|
|
4279
|
+
this.serverStatusTypes = serverStatusTypes;
|
|
4280
|
+
}
|
|
4281
|
+
ngOnInit() {
|
|
4282
|
+
this.serverActionStatus$ = this.status$.pipe(delayOn(a => a.status === serverStatusTypes.inProgress, 500));
|
|
4283
|
+
}
|
|
4284
|
+
}
|
|
4285
|
+
ActionStateSpinnerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ActionStateSpinnerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4286
|
+
ActionStateSpinnerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.5", type: ActionStateSpinnerComponent, selector: "lib-action-state-spinner", inputs: { status$: "status$" }, ngImport: i0, template: "<div id=\"blocker\" *ngIf=\"(serverActionStatus$ | async)?.status === serverStatusTypes.inProgress\">\n <mat-spinner class=\"spinner\" [diameter]=\"200\"></mat-spinner>\n</div>\n", styles: ["#blocker{position:fixed;top:0px;left:0px;width:100%;height:100%;background-color:#0e0d0d69;z-index:999999}.spinner{position:absolute;top:50%;left:40%;transform:translate(-50%,-50%)}\n"], components: [{ type: i1$5.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "diameter", "strokeWidth", "mode", "value"], exportAs: ["matProgressSpinner"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "async": i1$1.AsyncPipe } });
|
|
4287
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ActionStateSpinnerComponent, decorators: [{
|
|
4288
|
+
type: Component,
|
|
4289
|
+
args: [{ selector: 'lib-action-state-spinner', template: "<div id=\"blocker\" *ngIf=\"(serverActionStatus$ | async)?.status === serverStatusTypes.inProgress\">\n <mat-spinner class=\"spinner\" [diameter]=\"200\"></mat-spinner>\n</div>\n", styles: ["#blocker{position:fixed;top:0px;left:0px;width:100%;height:100%;background-color:#0e0d0d69;z-index:999999}.spinner{position:absolute;top:50%;left:40%;transform:translate(-50%,-50%)}\n"] }]
|
|
4290
|
+
}], propDecorators: { status$: [{
|
|
4291
|
+
type: Input
|
|
4292
|
+
}] } });
|
|
4293
|
+
|
|
4294
|
+
class ActionStateUiModule {
|
|
4295
|
+
}
|
|
4296
|
+
ActionStateUiModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ActionStateUiModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
4297
|
+
ActionStateUiModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ActionStateUiModule, declarations: [ActionStateSpinnerComponent], imports: [CommonModule,
|
|
4298
|
+
MatProgressSpinnerModule], exports: [ActionStateSpinnerComponent] });
|
|
4299
|
+
ActionStateUiModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ActionStateUiModule, imports: [[
|
|
4300
|
+
CommonModule,
|
|
4301
|
+
MatProgressSpinnerModule,
|
|
4302
|
+
]] });
|
|
4303
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.5", ngImport: i0, type: ActionStateUiModule, decorators: [{
|
|
4304
|
+
type: NgModule,
|
|
4305
|
+
args: [{
|
|
4306
|
+
declarations: [
|
|
4307
|
+
ActionStateSpinnerComponent,
|
|
4308
|
+
],
|
|
4309
|
+
imports: [
|
|
4310
|
+
CommonModule,
|
|
4311
|
+
MatProgressSpinnerModule,
|
|
4312
|
+
],
|
|
4313
|
+
exports: [
|
|
4314
|
+
ActionStateSpinnerComponent,
|
|
4315
|
+
]
|
|
4316
|
+
}]
|
|
4317
|
+
}] });
|
|
4318
|
+
|
|
4319
|
+
/*
|
|
4320
|
+
* Public API Surface of action-state
|
|
4321
|
+
*/
|
|
4322
|
+
|
|
4159
4323
|
/*
|
|
4160
4324
|
* Public API Surface of http-request-state
|
|
4161
4325
|
*/
|
|
@@ -4164,5 +4328,5 @@ const CreateTableBuilder = (reportDef$) => {
|
|
|
4164
4328
|
* Generated bundle index. Do not edit.
|
|
4165
4329
|
*/
|
|
4166
4330
|
|
|
4167
|
-
export { ArrayStyle, AutoFocusDirective, ClickEmitterDirective, ClickSubjectDirective, CreateTableBuilder, CustomCellDirective, DateFilterComponent, DialogDirective, DialogService, DialogWrapper, FieldType, FilterChipsComponent, FilterComponent, FilterType, FunctionPipe, GenColDisplayerComponent, GenFilterDisplayerComponent, GeneralTableSettings, GenericTableComponent, HttpErrorStateDirective, HttpInProgressStateDirective, HttpNotStartedStateDirective, HttpRequestModule, HttpRequestStateDirective, HttpRequestStateFactory, HttpRequestStateStore, HttpRequestStatus, HttpRequestStrategy, HttpSuccessStateDirective, MatButtonToggleFilterDirective, MatCheckboxTbFilterDirective, MatOptionTbFilterDirective, MatRadioButtonTbFilterDirective, MatSlideToggleGroupDirective, MatSlideToggleTbFilterDirective, MatTableObservableDataSource, MultiSortDirective, NotPersisitedTableSettings, PaginatorComponent, PesrsistedTableSettings, PhoneNumberPipe, PreventEnterDirective, ResizeColumnDirective, SortDirection, SpaceCasePipe, StopPropagationDirective, StylerDirective, TableBuilder, TableBuilderModule, TableColumnHeaderSettings, TableContainerComponent, TableCustomFilterDirective, TableCustomFilterDirectiveBase, TableFilterDirective, TableFilterStringContainsDirective, TableWrapperDirective, TableWrapperFooterSettings, TableWrapperHeaderSettings, Target, TbSelectedFilterDirective, UtilitiesModule, chainRequest, combineArrays, createFailure, createSuccess, defaultShareReplay, filterArray, getRequestorBody, getRequestorStatus, httpRequest, httpRequestor, inProgress, isErrorState, isSuccessState, mapArray, mapError, notNull, notStarted, onWait, onceWhen, previousAndCurrent, skipOneWhen, spaceCase, statusIsSuccessOrInProgress, switchOff, tapError, tapSuccess };
|
|
4331
|
+
export { ActionStateSpinnerComponent, ActionStateUiModule, ActionStatus, AppStatusState, ArrayStyle, AutoFocusDirective, ClickEmitterDirective, ClickSubjectDirective, ConditionalClassesDirective, CreateTableBuilder, CustomCellDirective, DateFilterComponent, DialogDirective, DialogService, DialogWrapper, FieldType, FilterChipsComponent, FilterComponent, FilterType, FunctionPipe, GenColDisplayerComponent, GenFilterDisplayerComponent, GeneralTableSettings, GenericTableComponent, HttpErrorStateDirective, HttpInProgressStateDirective, HttpNotStartedStateDirective, HttpRequestModule, HttpRequestStateDirective, HttpRequestStateFactory, HttpRequestStateStore, HttpRequestStatus, HttpRequestStrategy, HttpSuccessStateDirective, MatButtonToggleFilterDirective, MatCheckboxTbFilterDirective, MatOptionTbFilterDirective, MatRadioButtonTbFilterDirective, MatSlideToggleGroupDirective, MatSlideToggleTbFilterDirective, MatTableObservableDataSource, MultiSortDirective, NgrxExtModule, NotPersisitedTableSettings, PaginatorComponent, PesrsistedTableSettings, PhoneNumberPipe, PreventEnterDirective, ResizeColumnDirective, SortDirection, SpaceCasePipe, StopPropagationDirective, StylerDirective, TableBuilder, TableBuilderModule, TableColumnHeaderSettings, TableContainerComponent, TableCustomFilterDirective, TableCustomFilterDirectiveBase, TableFilterDirective, TableFilterStringContainsDirective, TableWrapperDirective, TableWrapperFooterSettings, TableWrapperHeaderSettings, Target, TbSelectedFilterDirective, UtilitiesModule, actionStatusReducer, chainRequest, combineArrays, createFailure, createSuccess, defaultShareReplay, delayOn, filterArray, getRequestorBody, getRequestorStatus, getStatusState, httpRequest, httpRequestor, inProgress, initialState, isErrorState, isSuccessState, mapArray, mapError, notNull, notStarted, onWait, onceWhen, previousAndCurrent, selectAll, selectEntities, selectEntity, selectIds, selectTotal, serverStatusTypes, skipOneWhen, spaceCase, statusAdapter, statusIsSuccessOrInProgress, switchOff, tapError, tapSuccess };
|
|
4168
4332
|
//# sourceMappingURL=one-paragon-angular-utilities.mjs.map
|