@coolon/angular-ui-powerups 3.9.0 → 3.10.1
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/CHANGELOG.md +9 -0
- package/assets/table.scss +18 -0
- package/bundles/coolon-angular-ui-powerups.umd.js +1210 -507
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/esm2015/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/components.module.js +13 -5
- package/esm2015/lib/components/components.module.js.map +1 -1
- package/esm2015/lib/components/components.module.metadata.json +1 -1
- package/esm2015/lib/components/components.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/exports.js +11 -0
- package/esm2015/lib/components/exports.js.map +1 -1
- package/esm2015/lib/components/exports.metadata.json +1 -1
- package/esm2015/lib/components/table/abstract-table-model.js +173 -0
- package/esm2015/lib/components/table/abstract-table-model.js.map +1 -0
- package/esm2015/lib/components/table/abstract-table-model.metadata.json +1 -0
- package/esm2015/lib/components/table/column-model.js +6 -3
- package/esm2015/lib/components/table/column-model.js.map +1 -1
- package/esm2015/lib/components/table/column-model.metadata.json +1 -1
- package/esm2015/lib/components/table/table-model.js +7 -171
- package/esm2015/lib/components/table/table-model.js.map +1 -1
- package/esm2015/lib/components/table/table-model.metadata.json +1 -1
- package/esm2015/lib/components/table/table.component.js +3 -3
- package/esm2015/lib/components/table/table.component.js.map +1 -1
- package/esm2015/lib/components/table/table.component.metadata.json +1 -1
- package/esm2015/lib/components/tree-table/decorated-tree-node.js +169 -0
- package/esm2015/lib/components/tree-table/decorated-tree-node.js.map +1 -0
- package/esm2015/lib/components/tree-table/decorated-tree-node.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-expansion-model.js +48 -0
- package/esm2015/lib/components/tree-table/tree-expansion-model.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-expansion-model.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.js +68 -0
- package/esm2015/lib/components/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.js +71 -0
- package/esm2015/lib/components/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.scss.shim.ngstyle.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-label-column-model.js +33 -0
- package/esm2015/lib/components/tree-table/tree-label-column-model.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-label-column-model.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-node.js +2 -0
- package/esm2015/lib/components/tree-table/tree-node.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-node.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-table-component.js +63 -0
- package/esm2015/lib/components/tree-table/tree-table-component.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-table-component.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-table-component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-table-model.js +108 -0
- package/esm2015/lib/components/tree-table/tree-table-model.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-table-model.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/tree-table.component.scss.ngstyle.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-to-list-model.js +25 -0
- package/esm2015/lib/components/tree-table/tree-to-list-model.js.map +1 -0
- package/esm2015/lib/components/tree-table/tree-to-list-model.metadata.json +1 -0
- package/esm2015/lib/components/tree-table/visitable.class.js +26 -0
- package/esm2015/lib/components/tree-table/visitable.class.js.map +1 -0
- package/esm2015/lib/components/tree-table/visitable.class.metadata.json +1 -0
- package/esm2015/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/route/visit-sanitiser.js +1 -1
- package/esm2015/lib/place/route/visit-sanitiser.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +966 -373
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/exports.d.ts +11 -0
- package/lib/components/table/abstract-table-model.d.ts +61 -0
- package/lib/components/table/column-model.d.ts +11 -12
- package/lib/components/table/table-model.d.ts +4 -59
- package/lib/components/table/table.component.d.ts +2 -2
- package/lib/components/tree-table/decorated-tree-node.d.ts +43 -0
- package/lib/components/tree-table/tree-expansion-model.d.ts +18 -0
- package/lib/components/tree-table/tree-inheritance-icon/tree-inheritance-icon.component.d.ts +28 -0
- package/lib/components/tree-table/tree-label-cell-renderer/tree-label-cell-renderer.component.d.ts +25 -0
- package/lib/components/tree-table/tree-label-column-model.d.ts +20 -0
- package/lib/components/tree-table/tree-node.d.ts +3 -0
- package/lib/components/tree-table/tree-table-component.d.ts +7 -0
- package/lib/components/tree-table/tree-table-model.d.ts +33 -0
- package/lib/components/tree-table/tree-to-list-model.d.ts +12 -0
- package/lib/components/tree-table/visitable.class.d.ts +22 -0
- package/package.json +1 -1
- package/schematics/place-routes/place-builder.js +1 -1
- package/schematics/place-routes/place-builder.js.map +1 -1
- package/schematics/utils/build-context.js +0 -2
- package/schematics/utils/build-context.js.map +1 -1
- package/schematics/utils/schematic-tree-file-system.js +6 -2
- package/schematics/utils/schematic-tree-file-system.js.map +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DOCUMENT, CommonModule, Location } from '@angular/common';
|
|
2
|
-
import { Directive, ElementRef, Inject, Host, Optional, Input, HostListener, NgZone, ɵɵdefineInjectable, ɵɵinject, Injectable, NgModule, Component, ContentChild,
|
|
2
|
+
import { Directive, ElementRef, Inject, Host, Optional, Input, HostListener, NgZone, ɵɵdefineInjectable, ɵɵinject, Injectable, NgModule, Component, ContentChild, ViewEncapsulation, HostBinding, InjectionToken, ViewChildren, SkipSelf, EventEmitter, ViewChild, Output, Self, TemplateRef, ChangeDetectorRef, ContentChildren, ViewContainerRef, Injector, ComponentFactoryResolver, INJECTOR } from '@angular/core';
|
|
3
3
|
import { FormsModule } from '@angular/forms';
|
|
4
4
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
5
5
|
import { MatInputModule } from '@angular/material/input';
|
|
@@ -18,12 +18,12 @@ import { MatTableModule } from '@angular/material/table';
|
|
|
18
18
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
19
19
|
import { FontAwesomeModule, FaIconLibrary } from '@fortawesome/angular-fontawesome';
|
|
20
20
|
import { fas } from '@fortawesome/free-solid-svg-icons';
|
|
21
|
-
import { GarbageCollector, DelegatingValueModel, assert, UnaryCommand, lang, Dsl, Logger, TrackExternal, Command,
|
|
21
|
+
import { GarbageCollector, DelegatingValueModel, assert, UnaryCommand, lang, Dsl, Logger, TrackExternal, Command, MutableListModel, StoreInListModel, ValueModel, StoreInValueModel, Disposable, MutableValueModel, DelegatingListModel, FocusManager, EventListenerList, Form, Guard, Binding, DebugContext, ListModel, MultipleSelectionModel, DirtyTrackingForm, ComputedListModel, DelegatingCommand, Deferred, Trace, Functions } from '@coolon/pectin';
|
|
22
22
|
import { __decorate, __metadata, __awaiter } from 'tslib';
|
|
23
23
|
import { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';
|
|
24
|
-
import _, {
|
|
24
|
+
import _, { find, filter, each, isNil, isEqual } from 'lodash';
|
|
25
25
|
import { Enum } from 'typescript-string-enums';
|
|
26
|
-
import { assert as assert$1, Opts, lang as lang$1, Klass } from '@coolon/typescript-utilities';
|
|
26
|
+
import { assert as assert$1, Mixin, Opts, lang as lang$1, Klass } from '@coolon/typescript-utilities';
|
|
27
27
|
import produce from 'immer';
|
|
28
28
|
import { FlexModule, GridModule } from '@angular/flex-layout';
|
|
29
29
|
import { MatDialogModule, MatDialog, MAT_DIALOG_DEFAULT_OPTIONS, MatDialogConfig } from '@angular/material/dialog';
|
|
@@ -506,10 +506,68 @@ __decorate([
|
|
|
506
506
|
__metadata("design:type", Command)
|
|
507
507
|
], CardContainerComponent.prototype, "addCardCommand", void 0);
|
|
508
508
|
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
509
|
+
/**
|
|
510
|
+
* Custom CSS:
|
|
511
|
+
* @example
|
|
512
|
+
* root: { // globally
|
|
513
|
+
* --aup-command-face-icon-gap: 8px;
|
|
514
|
+
* }
|
|
515
|
+
* aup-command-face { // per instance
|
|
516
|
+
* --icon-gap: 4px;
|
|
517
|
+
* }
|
|
518
|
+
*/
|
|
519
|
+
class CommandFaceComponent extends DisposableComponent {
|
|
520
|
+
constructor() {
|
|
521
|
+
super();
|
|
522
|
+
this.facesModel = new MutableListModel();
|
|
523
|
+
this.ignoreIcon = false;
|
|
524
|
+
this.ignoreText = false;
|
|
525
|
+
this.includeMissingIconInLayout = false;
|
|
526
|
+
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
527
|
+
this.faceAdapters = chain(this.facesModel).map(face => new CommandFace.Adapter(face));
|
|
528
|
+
const activeFace = this.faceAdapters.first();
|
|
529
|
+
this.activeIcon = activeFace.pluck("icon");
|
|
530
|
+
this.activeColor = activeFace.pluck("color");
|
|
531
|
+
}
|
|
532
|
+
get requiresMissingIconInLayout() {
|
|
533
|
+
return this.includeMissingIconInLayout && !this.activeIcon.value;
|
|
534
|
+
}
|
|
535
|
+
ngOnInit() {
|
|
536
|
+
}
|
|
537
|
+
shouldIncludeIcon(face) {
|
|
538
|
+
return (!this.ignoreIcon && face.icon) || this.includeMissingIconInLayout;
|
|
539
|
+
}
|
|
540
|
+
hasIconStart(face) {
|
|
541
|
+
return this.shouldIncludeIcon(face) && (!face.iconPosition || face.iconPosition === CommandFace.Position.START);
|
|
542
|
+
}
|
|
543
|
+
hasIconEnd(face) {
|
|
544
|
+
return this.shouldIncludeIcon(face) && face.iconPosition === CommandFace.Position.END;
|
|
545
|
+
}
|
|
546
|
+
get color() {
|
|
547
|
+
return this.activeColor.value;
|
|
548
|
+
}
|
|
549
|
+
}
|
|
550
|
+
CommandFaceComponent.decorators = [
|
|
551
|
+
{ type: Component, args: [{
|
|
552
|
+
selector: 'aup-command-face',
|
|
553
|
+
template: "<div class=\"face-container\" *ngFor=\"let face of faceAdapters.value\">\n <aup-icon *ngIf=\"hasIconStart(face)\" [icon]=\"face.icon\"></aup-icon>\n <span *ngIf=\"face.text\">{{face.text}}</span>\n <aup-icon *ngIf=\"hasIconEnd(face)\" [icon]=\"face.icon\"></aup-icon>\n</div>\n",
|
|
554
|
+
encapsulation: ViewEncapsulation.None,
|
|
555
|
+
styles: ["aup-command-face{--icon-gap:var(--aup-command-face-icon-gap);display:-ms-inline-grid;display:inline-grid}aup-command-face>.face-container{-ms-grid-column:1;-ms-grid-row:1;align-items:center;display:inline-flex;flex-direction:row;grid-column:1;grid-row:1}aup-command-face>.face-container:not(:first-child){visibility:hidden}aup-command-face>.face-container *+*{margin-left:var(--icon-gap)}aup-command-face.hide-icon aup-icon{visibility:hidden}aup-command-face.centered{justify-items:center}"]
|
|
556
|
+
},] }
|
|
557
|
+
];
|
|
558
|
+
CommandFaceComponent.ctorParameters = () => [];
|
|
559
|
+
CommandFaceComponent.propDecorators = {
|
|
560
|
+
_rawFaces: [{ type: Input, args: ['faces',] }],
|
|
561
|
+
ignoreIcon: [{ type: Input }],
|
|
562
|
+
ignoreText: [{ type: Input }],
|
|
563
|
+
includeMissingIconInLayout: [{ type: Input }],
|
|
564
|
+
requiresMissingIconInLayout: [{ type: HostBinding, args: ['class.hide-icon',] }],
|
|
565
|
+
color: [{ type: HostBinding, args: ['attr.color',] }]
|
|
566
|
+
};
|
|
567
|
+
__decorate([
|
|
568
|
+
StoreInListModel('facesModel'),
|
|
569
|
+
__metadata("design:type", Array)
|
|
570
|
+
], CommandFaceComponent.prototype, "_rawFaces", void 0);
|
|
513
571
|
|
|
514
572
|
class PopupAwareComponent extends DisposableComponent {
|
|
515
573
|
constructor(element, parent) {
|
|
@@ -607,92 +665,23 @@ __decorate([
|
|
|
607
665
|
__metadata("design:type", Object)
|
|
608
666
|
], CommandComponent.prototype, "busyFace", void 0);
|
|
609
667
|
|
|
610
|
-
class CommandContainer extends GarbageCollector {
|
|
611
|
-
constructor(parent) {
|
|
612
|
-
super();
|
|
613
|
-
this.parent = parent;
|
|
614
|
-
}
|
|
615
|
-
get depth() {
|
|
616
|
-
return this.hasParent() ? this.parent.depth + 1 : 0;
|
|
617
|
-
}
|
|
618
|
-
hasParent() {
|
|
619
|
-
return !!this.parent;
|
|
620
|
-
}
|
|
621
|
-
get orientation() {
|
|
622
|
-
return CommandContainer.Orientation.VERTICAL;
|
|
623
|
-
}
|
|
624
|
-
}
|
|
625
|
-
(function (CommandContainer) {
|
|
626
|
-
CommandContainer.Orientation = Enum({ HORIZONTAL: 'horizontal', VERTICAL: 'vertical' });
|
|
627
|
-
})(CommandContainer || (CommandContainer = {}));
|
|
628
|
-
|
|
629
668
|
/**
|
|
630
669
|
*
|
|
631
670
|
*/
|
|
632
|
-
class
|
|
671
|
+
class FlexComponent extends DisposableComponent {
|
|
633
672
|
constructor() {
|
|
634
673
|
super();
|
|
635
674
|
}
|
|
636
|
-
get orientation() {
|
|
637
|
-
return CommandContainer.Orientation.HORIZONTAL;
|
|
638
|
-
}
|
|
639
|
-
// @Trace()
|
|
640
|
-
ngOnInit() {
|
|
641
|
-
}
|
|
642
|
-
// @Trace()
|
|
643
|
-
ngAfterContentInit() {
|
|
644
|
-
// this.group.initialise();
|
|
645
|
-
}
|
|
646
|
-
// @Trace()
|
|
647
|
-
ngAfterViewInit() {
|
|
648
|
-
}
|
|
649
|
-
}
|
|
650
|
-
ToolBarComponent.decorators = [
|
|
651
|
-
{ type: Component, args: [{
|
|
652
|
-
selector: 'aup-tool-bar',
|
|
653
|
-
template: '<div class="toolbar-content"><ng-content></ng-content></div>',
|
|
654
|
-
encapsulation: ViewEncapsulation.None,
|
|
655
|
-
styles: [":host{display:inline-block}.toolbar-content{align-items:center;display:inline-flex;flex-direction:row}.toolbar-content>aup-separator{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0 4px 8px}.toolbar-content>aup-flex{flex:1}.toolbar-content>*+*{margin-left:8px}"]
|
|
656
|
-
},] }
|
|
657
|
-
];
|
|
658
|
-
ToolBarComponent.ctorParameters = () => [];
|
|
659
|
-
|
|
660
|
-
/**
|
|
661
|
-
*
|
|
662
|
-
*/
|
|
663
|
-
class SeparatorComponent extends PopupAwareComponent {
|
|
664
|
-
constructor(element, popupContainer, containerParent) {
|
|
665
|
-
super(element, popupContainer);
|
|
666
|
-
this.containerParent = containerParent;
|
|
667
|
-
}
|
|
668
|
-
isHorizontalContainer() {
|
|
669
|
-
return this.containerParent instanceof ToolBarComponent && this.containerParent.orientation === CommandContainer.Orientation.HORIZONTAL;
|
|
670
|
-
}
|
|
671
675
|
ngOnInit() {
|
|
672
676
|
}
|
|
673
677
|
}
|
|
674
|
-
|
|
678
|
+
FlexComponent.decorators = [
|
|
675
679
|
{ type: Component, args: [{
|
|
676
|
-
selector: 'aup-
|
|
677
|
-
template:
|
|
678
|
-
<mat-divider [vertical]="!isHorizontalContainer()"></mat-divider>`,
|
|
679
|
-
styles: [`:host {
|
|
680
|
-
}`,
|
|
681
|
-
`:host(.horizontal-container) {
|
|
682
|
-
display: inline-flex;
|
|
683
|
-
flex-direction: row;
|
|
684
|
-
align-items: stretch;
|
|
685
|
-
}`]
|
|
680
|
+
selector: 'aup-flex',
|
|
681
|
+
template: ``
|
|
686
682
|
},] }
|
|
687
683
|
];
|
|
688
|
-
|
|
689
|
-
{ type: ElementRef },
|
|
690
|
-
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [POPUP_CONTAINER,] }] },
|
|
691
|
-
{ type: CommandContainer, decorators: [{ type: Optional }] }
|
|
692
|
-
];
|
|
693
|
-
SeparatorComponent.propDecorators = {
|
|
694
|
-
isHorizontalContainer: [{ type: HostBinding, args: ['class.horizontal-container',] }]
|
|
695
|
-
};
|
|
684
|
+
FlexComponent.ctorParameters = () => [];
|
|
696
685
|
|
|
697
686
|
/**
|
|
698
687
|
*
|
|
@@ -760,241 +749,252 @@ AbstractPopupMenuComponent.propDecorators = {
|
|
|
760
749
|
/**
|
|
761
750
|
*
|
|
762
751
|
*/
|
|
763
|
-
class
|
|
752
|
+
class MoreMenuComponent extends AbstractPopupMenuComponent {
|
|
764
753
|
constructor(element, parent) {
|
|
765
754
|
super(element, parent);
|
|
755
|
+
this.tooltipModel = new MutableValueModel();
|
|
766
756
|
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
767
|
-
|
|
757
|
+
this.faceModelDelegate.setDelegate(chain(this.tooltipModel).map(tooltip => {
|
|
758
|
+
return {
|
|
759
|
+
icon: () => 'mat:more_vert',
|
|
760
|
+
tooltip() {
|
|
761
|
+
return tooltip;
|
|
762
|
+
}
|
|
763
|
+
};
|
|
764
|
+
}, { allowNil: true }));
|
|
765
|
+
}
|
|
766
|
+
get face() {
|
|
767
|
+
return this.faceModelDelegate.value;
|
|
768
768
|
}
|
|
769
769
|
}
|
|
770
|
-
|
|
770
|
+
MoreMenuComponent.decorators = [
|
|
771
771
|
{ type: Component, args: [{
|
|
772
|
-
selector: 'aup-
|
|
772
|
+
selector: 'aup-more-menu',
|
|
773
773
|
template: "<div class=\"content\" style=\"display: none\">\n <ng-content></ng-content>\n</div>\n<ng-container *ngIf=\"isRoot()\">\n <ng-container *ngIf=\"faceAdapter.text\" [ngSwitch]=\"faceAdapter.style\">\n <ng-container *ngSwitchCase=\"'stroked'\">\n <button matMenuTrigger\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n mat-stroked-button>\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]=\"this\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'raised'\">\n <button matMenuTrigger\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n mat-raised-button>\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]=\"this\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button matMenuTrigger\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n mat-button>\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu [parent]=\"this\" (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n </ng-container>\n\n <ng-container *ngIf=\"!faceAdapter.text\">\n <button matMenuTrigger\n mat-icon-button\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n >\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]=\"this\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n</ng-container>\n",
|
|
774
774
|
providers: [
|
|
775
|
-
{ provide: POPUP_CONTAINER, useExisting:
|
|
775
|
+
{ provide: POPUP_CONTAINER, useExisting: MoreMenuComponent }
|
|
776
776
|
]
|
|
777
777
|
},] }
|
|
778
778
|
];
|
|
779
|
-
|
|
779
|
+
MoreMenuComponent.ctorParameters = () => [
|
|
780
780
|
{ type: ElementRef },
|
|
781
781
|
{ type: undefined, decorators: [{ type: Inject, args: [POPUP_CONTAINER,] }, { type: Optional }, { type: SkipSelf }] }
|
|
782
782
|
];
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
face: [{ type: Input }]
|
|
783
|
+
MoreMenuComponent.propDecorators = {
|
|
784
|
+
tooltip: [{ type: Input }]
|
|
786
785
|
};
|
|
787
786
|
__decorate([
|
|
788
|
-
|
|
789
|
-
__metadata("design:type",
|
|
790
|
-
],
|
|
791
|
-
__decorate([
|
|
792
|
-
StoreInValueModel('faceModel'),
|
|
793
|
-
__metadata("design:type", Object)
|
|
794
|
-
], PopupMenuComponent.prototype, "face", void 0);
|
|
787
|
+
StoreInValueModel('tooltipModel'),
|
|
788
|
+
__metadata("design:type", String)
|
|
789
|
+
], MoreMenuComponent.prototype, "tooltip", void 0);
|
|
795
790
|
|
|
796
|
-
|
|
797
|
-
|
|
791
|
+
var TrackBy;
|
|
792
|
+
(function (TrackBy) {
|
|
793
|
+
TrackBy.byIndex = (data, index) => index;
|
|
794
|
+
})(TrackBy || (TrackBy = {}));
|
|
795
|
+
|
|
796
|
+
class CommandContainer extends GarbageCollector {
|
|
797
|
+
constructor(parent) {
|
|
798
798
|
super();
|
|
799
|
-
this.
|
|
800
|
-
this.commandFired = new EventEmitter();
|
|
801
|
-
this.TrackBy = TrackBy;
|
|
802
|
-
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
803
|
-
// this.children = chain(this.groupViewDataModel).pluckList('children');
|
|
804
|
-
// this.hasMixedIcons = chain(this.groupViewDataModel).pluck('hasMixedIcons');
|
|
805
|
-
const faces = chain(this._childList).map(child => {
|
|
806
|
-
return child.getFace();
|
|
807
|
-
}).rejectNil();
|
|
808
|
-
const icons = faces.select(face => !!CommandFace.getIconOf(face));
|
|
809
|
-
const iconCount = icons.count();
|
|
810
|
-
const totalFaces = faces.count();
|
|
811
|
-
this.hasMixedIcons = valueOf.all(iconCount.isGreaterThan(0), totalFaces.doesNotEqual(iconCount)).areTruthy();
|
|
812
|
-
}
|
|
813
|
-
get parent() {
|
|
814
|
-
return this._parentComponent;
|
|
815
|
-
}
|
|
816
|
-
set parent(comp) {
|
|
817
|
-
this._parentComponent = comp;
|
|
818
|
-
this._childList.setDelegate(comp.children);
|
|
819
|
-
}
|
|
820
|
-
get children() {
|
|
821
|
-
return this.parent.children.value;
|
|
822
|
-
}
|
|
823
|
-
executeCommand(data) {
|
|
824
|
-
if (this.isCommand(data)) {
|
|
825
|
-
data.command.execute().finally(() => {
|
|
826
|
-
this.commandFired.emit();
|
|
827
|
-
});
|
|
828
|
-
}
|
|
829
|
-
}
|
|
830
|
-
isEnabled(data) {
|
|
831
|
-
return true; //ViewData.getCommand(data).enabled.value;
|
|
832
|
-
}
|
|
833
|
-
// @Trace()
|
|
834
|
-
onCommandFired() {
|
|
835
|
-
this.commandFired.emit();
|
|
836
|
-
this.triggers.forEach(trigger => {
|
|
837
|
-
if (trigger.menuOpen) {
|
|
838
|
-
trigger.closeMenu();
|
|
839
|
-
}
|
|
840
|
-
});
|
|
841
|
-
}
|
|
842
|
-
isCommand(child) {
|
|
843
|
-
return child instanceof CommandComponent;
|
|
844
|
-
}
|
|
845
|
-
isPopupMenu(child) {
|
|
846
|
-
return child instanceof AbstractPopupMenuComponent;
|
|
799
|
+
this.parent = parent;
|
|
847
800
|
}
|
|
848
|
-
|
|
849
|
-
return
|
|
801
|
+
get depth() {
|
|
802
|
+
return this.hasParent() ? this.parent.depth + 1 : 0;
|
|
850
803
|
}
|
|
851
|
-
|
|
852
|
-
return this.
|
|
804
|
+
hasParent() {
|
|
805
|
+
return !!this.parent;
|
|
853
806
|
}
|
|
854
|
-
|
|
855
|
-
return
|
|
856
|
-
child.faces.value :
|
|
857
|
-
this.isPopupMenu(child) ?
|
|
858
|
-
[child.faceAdapter.face] :
|
|
859
|
-
undefined;
|
|
807
|
+
get orientation() {
|
|
808
|
+
return CommandContainer.Orientation.VERTICAL;
|
|
860
809
|
}
|
|
861
810
|
}
|
|
862
|
-
|
|
863
|
-
{
|
|
864
|
-
|
|
865
|
-
template: "<mat-menu #menu [xPosition]=\"parent.xPosition\" [yPosition]=\"parent.yPosition\">\n <ng-template matMenuContent>\n <ng-container *ngFor=\"let child of children; trackBy: TrackBy.byIndex\" >\n <button *ngIf=\"isCommand(child)\"\n (click)=\"executeCommand(child)\"\n [disabled]=\"!isEnabled(child)\"\n [matTooltip]=\"getTooltip(child)\"\n mat-menu-item>\n <aup-command-face [faces]=\"getFaces(child)\"\n [includeMissingIconInLayout]=\"hasMixedIcons.value\"></aup-command-face>\n </button>\n\n <ng-container *ngIf=\"isPopupMenu(child)\">\n <button mat-menu-item\n matMenuTrigger\n [matMenuTriggerFor]=\"innerPanel.menuComponent\"\n >\n <aup-command-face [faces]=\"getFaces(child)\"\n [includeMissingIconInLayout]=\"hasMixedIcons.value\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #innerPanel\n [parent]=\"child\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n <mat-divider *ngIf=\"isSeparator(child)\"></mat-divider>\n\n </ng-container>\n\n </ng-template>\n</mat-menu>\n"
|
|
866
|
-
},] }
|
|
867
|
-
];
|
|
868
|
-
PopupMenuRendererComponent.ctorParameters = () => [];
|
|
869
|
-
PopupMenuRendererComponent.propDecorators = {
|
|
870
|
-
parent: [{ type: Input }],
|
|
871
|
-
menuComponent: [{ type: ViewChild, args: ['menu', { static: true },] }],
|
|
872
|
-
commandFired: [{ type: Output }],
|
|
873
|
-
triggers: [{ type: ViewChildren, args: [MatMenuTrigger,] }]
|
|
874
|
-
};
|
|
811
|
+
(function (CommandContainer) {
|
|
812
|
+
CommandContainer.Orientation = Enum({ HORIZONTAL: 'horizontal', VERTICAL: 'vertical' });
|
|
813
|
+
})(CommandContainer || (CommandContainer = {}));
|
|
875
814
|
|
|
876
815
|
/**
|
|
877
|
-
*
|
|
878
|
-
* @example
|
|
879
|
-
* root: { // globally
|
|
880
|
-
* --aup-command-face-icon-gap: 8px;
|
|
881
|
-
* }
|
|
882
|
-
* aup-command-face { // per instance
|
|
883
|
-
* --icon-gap: 4px;
|
|
884
|
-
* }
|
|
816
|
+
*
|
|
885
817
|
*/
|
|
886
|
-
class
|
|
818
|
+
class ToolBarComponent extends CommandContainer {
|
|
887
819
|
constructor() {
|
|
888
820
|
super();
|
|
889
|
-
this.facesModel = new MutableListModel();
|
|
890
|
-
this.ignoreIcon = false;
|
|
891
|
-
this.ignoreText = false;
|
|
892
|
-
this.includeMissingIconInLayout = false;
|
|
893
|
-
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
894
|
-
this.faceAdapters = chain(this.facesModel).map(face => new CommandFace.Adapter(face));
|
|
895
|
-
const activeFace = this.faceAdapters.first();
|
|
896
|
-
this.activeIcon = activeFace.pluck("icon");
|
|
897
|
-
this.activeColor = activeFace.pluck("color");
|
|
898
821
|
}
|
|
899
|
-
get
|
|
900
|
-
return
|
|
822
|
+
get orientation() {
|
|
823
|
+
return CommandContainer.Orientation.HORIZONTAL;
|
|
901
824
|
}
|
|
825
|
+
// @Trace()
|
|
902
826
|
ngOnInit() {
|
|
903
827
|
}
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
hasIconStart(face) {
|
|
908
|
-
return this.shouldIncludeIcon(face) && (!face.iconPosition || face.iconPosition === CommandFace.Position.START);
|
|
909
|
-
}
|
|
910
|
-
hasIconEnd(face) {
|
|
911
|
-
return this.shouldIncludeIcon(face) && face.iconPosition === CommandFace.Position.END;
|
|
828
|
+
// @Trace()
|
|
829
|
+
ngAfterContentInit() {
|
|
830
|
+
// this.group.initialise();
|
|
912
831
|
}
|
|
913
|
-
|
|
914
|
-
|
|
832
|
+
// @Trace()
|
|
833
|
+
ngAfterViewInit() {
|
|
915
834
|
}
|
|
916
835
|
}
|
|
917
|
-
|
|
836
|
+
ToolBarComponent.decorators = [
|
|
918
837
|
{ type: Component, args: [{
|
|
919
|
-
selector: 'aup-
|
|
920
|
-
template:
|
|
838
|
+
selector: 'aup-tool-bar',
|
|
839
|
+
template: '<div class="toolbar-content"><ng-content></ng-content></div>',
|
|
921
840
|
encapsulation: ViewEncapsulation.None,
|
|
922
|
-
styles: ["
|
|
841
|
+
styles: [":host{display:inline-block}.toolbar-content{align-items:center;display:inline-flex;flex-direction:row}.toolbar-content>aup-separator{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0 4px 8px}.toolbar-content>aup-flex{flex:1}.toolbar-content>*+*{margin-left:8px}"]
|
|
923
842
|
},] }
|
|
924
843
|
];
|
|
925
|
-
|
|
926
|
-
CommandFaceComponent.propDecorators = {
|
|
927
|
-
_rawFaces: [{ type: Input, args: ['faces',] }],
|
|
928
|
-
ignoreIcon: [{ type: Input }],
|
|
929
|
-
ignoreText: [{ type: Input }],
|
|
930
|
-
includeMissingIconInLayout: [{ type: Input }],
|
|
931
|
-
requiresMissingIconInLayout: [{ type: HostBinding, args: ['class.hide-icon',] }],
|
|
932
|
-
color: [{ type: HostBinding, args: ['attr.color',] }]
|
|
933
|
-
};
|
|
934
|
-
__decorate([
|
|
935
|
-
StoreInListModel('facesModel'),
|
|
936
|
-
__metadata("design:type", Array)
|
|
937
|
-
], CommandFaceComponent.prototype, "_rawFaces", void 0);
|
|
844
|
+
ToolBarComponent.ctorParameters = () => [];
|
|
938
845
|
|
|
939
846
|
/**
|
|
940
847
|
*
|
|
941
848
|
*/
|
|
942
|
-
class
|
|
943
|
-
constructor() {
|
|
944
|
-
super();
|
|
849
|
+
class SeparatorComponent extends PopupAwareComponent {
|
|
850
|
+
constructor(element, popupContainer, containerParent) {
|
|
851
|
+
super(element, popupContainer);
|
|
852
|
+
this.containerParent = containerParent;
|
|
853
|
+
}
|
|
854
|
+
isHorizontalContainer() {
|
|
855
|
+
return this.containerParent instanceof ToolBarComponent && this.containerParent.orientation === CommandContainer.Orientation.HORIZONTAL;
|
|
945
856
|
}
|
|
946
857
|
ngOnInit() {
|
|
947
858
|
}
|
|
948
859
|
}
|
|
949
|
-
|
|
860
|
+
SeparatorComponent.decorators = [
|
|
950
861
|
{ type: Component, args: [{
|
|
951
|
-
selector: 'aup-
|
|
952
|
-
template:
|
|
862
|
+
selector: 'aup-separator',
|
|
863
|
+
template: `
|
|
864
|
+
<mat-divider [vertical]="!isHorizontalContainer()"></mat-divider>`,
|
|
865
|
+
styles: [`:host {
|
|
866
|
+
}`,
|
|
867
|
+
`:host(.horizontal-container) {
|
|
868
|
+
display: inline-flex;
|
|
869
|
+
flex-direction: row;
|
|
870
|
+
align-items: stretch;
|
|
871
|
+
}`]
|
|
953
872
|
},] }
|
|
954
873
|
];
|
|
955
|
-
|
|
874
|
+
SeparatorComponent.ctorParameters = () => [
|
|
875
|
+
{ type: ElementRef },
|
|
876
|
+
{ type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [POPUP_CONTAINER,] }] },
|
|
877
|
+
{ type: CommandContainer, decorators: [{ type: Optional }] }
|
|
878
|
+
];
|
|
879
|
+
SeparatorComponent.propDecorators = {
|
|
880
|
+
isHorizontalContainer: [{ type: HostBinding, args: ['class.horizontal-container',] }]
|
|
881
|
+
};
|
|
956
882
|
|
|
957
883
|
/**
|
|
958
884
|
*
|
|
959
885
|
*/
|
|
960
|
-
class
|
|
886
|
+
class PopupMenuComponent extends AbstractPopupMenuComponent {
|
|
961
887
|
constructor(element, parent) {
|
|
962
888
|
super(element, parent);
|
|
963
|
-
this.tooltipModel = new MutableValueModel();
|
|
964
889
|
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
965
|
-
|
|
966
|
-
return {
|
|
967
|
-
icon: () => 'mat:more_vert',
|
|
968
|
-
tooltip() {
|
|
969
|
-
return tooltip;
|
|
970
|
-
}
|
|
971
|
-
};
|
|
972
|
-
}, { allowNil: true }));
|
|
973
|
-
}
|
|
974
|
-
get face() {
|
|
975
|
-
return this.faceModelDelegate.value;
|
|
890
|
+
// group.faceListModel = chain(this.faceModel).mapToList(face => [face]);
|
|
976
891
|
}
|
|
977
892
|
}
|
|
978
|
-
|
|
893
|
+
PopupMenuComponent.decorators = [
|
|
979
894
|
{ type: Component, args: [{
|
|
980
|
-
selector: 'aup-
|
|
895
|
+
selector: 'aup-popup-menu',
|
|
981
896
|
template: "<div class=\"content\" style=\"display: none\">\n <ng-content></ng-content>\n</div>\n<ng-container *ngIf=\"isRoot()\">\n <ng-container *ngIf=\"faceAdapter.text\" [ngSwitch]=\"faceAdapter.style\">\n <ng-container *ngSwitchCase=\"'stroked'\">\n <button matMenuTrigger\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n mat-stroked-button>\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]=\"this\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'raised'\">\n <button matMenuTrigger\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n mat-raised-button>\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]=\"this\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button matMenuTrigger\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n mat-button>\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu [parent]=\"this\" (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n </ng-container>\n\n <ng-container *ngIf=\"!faceAdapter.text\">\n <button matMenuTrigger\n mat-icon-button\n [matMenuTriggerFor]=\"subMenu.menuComponent\"\n [matTooltip]=\"faceAdapter.tooltip\"\n [color]=\"faceAdapter.color\"\n >\n <aup-command-face [faces]=\"[face]\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]=\"this\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n</ng-container>\n",
|
|
982
897
|
providers: [
|
|
983
|
-
{ provide: POPUP_CONTAINER, useExisting:
|
|
898
|
+
{ provide: POPUP_CONTAINER, useExisting: PopupMenuComponent }
|
|
984
899
|
]
|
|
985
900
|
},] }
|
|
986
901
|
];
|
|
987
|
-
|
|
902
|
+
PopupMenuComponent.ctorParameters = () => [
|
|
988
903
|
{ type: ElementRef },
|
|
989
904
|
{ type: undefined, decorators: [{ type: Inject, args: [POPUP_CONTAINER,] }, { type: Optional }, { type: SkipSelf }] }
|
|
990
905
|
];
|
|
991
|
-
|
|
992
|
-
|
|
906
|
+
PopupMenuComponent.propDecorators = {
|
|
907
|
+
faceModel: [{ type: Input }],
|
|
908
|
+
face: [{ type: Input }]
|
|
993
909
|
};
|
|
994
910
|
__decorate([
|
|
995
|
-
|
|
996
|
-
__metadata("design:type",
|
|
997
|
-
],
|
|
911
|
+
TrackExternal({ delegateTo: 'faceModelDelegate' }),
|
|
912
|
+
__metadata("design:type", ValueModel)
|
|
913
|
+
], PopupMenuComponent.prototype, "faceModel", void 0);
|
|
914
|
+
__decorate([
|
|
915
|
+
StoreInValueModel('faceModel'),
|
|
916
|
+
__metadata("design:type", Object)
|
|
917
|
+
], PopupMenuComponent.prototype, "face", void 0);
|
|
918
|
+
|
|
919
|
+
class PopupMenuRendererComponent extends DisposableComponent {
|
|
920
|
+
constructor() {
|
|
921
|
+
super();
|
|
922
|
+
this._childList = new DelegatingListModel();
|
|
923
|
+
this.commandFired = new EventEmitter();
|
|
924
|
+
this.TrackBy = TrackBy;
|
|
925
|
+
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
926
|
+
// this.children = chain(this.groupViewDataModel).pluckList('children');
|
|
927
|
+
// this.hasMixedIcons = chain(this.groupViewDataModel).pluck('hasMixedIcons');
|
|
928
|
+
const faces = chain(this._childList).map(child => {
|
|
929
|
+
return child.getFace();
|
|
930
|
+
}).rejectNil();
|
|
931
|
+
const icons = faces.select(face => !!CommandFace.getIconOf(face));
|
|
932
|
+
const iconCount = icons.count();
|
|
933
|
+
const totalFaces = faces.count();
|
|
934
|
+
this.hasMixedIcons = valueOf.all(iconCount.isGreaterThan(0), totalFaces.doesNotEqual(iconCount)).areTruthy();
|
|
935
|
+
}
|
|
936
|
+
get parent() {
|
|
937
|
+
return this._parentComponent;
|
|
938
|
+
}
|
|
939
|
+
set parent(comp) {
|
|
940
|
+
this._parentComponent = comp;
|
|
941
|
+
this._childList.setDelegate(comp.children);
|
|
942
|
+
}
|
|
943
|
+
get children() {
|
|
944
|
+
return this.parent.children.value;
|
|
945
|
+
}
|
|
946
|
+
executeCommand(data) {
|
|
947
|
+
if (this.isCommand(data)) {
|
|
948
|
+
data.command.execute().finally(() => {
|
|
949
|
+
this.commandFired.emit();
|
|
950
|
+
});
|
|
951
|
+
}
|
|
952
|
+
}
|
|
953
|
+
isEnabled(data) {
|
|
954
|
+
return true; //ViewData.getCommand(data).enabled.value;
|
|
955
|
+
}
|
|
956
|
+
// @Trace()
|
|
957
|
+
onCommandFired() {
|
|
958
|
+
this.commandFired.emit();
|
|
959
|
+
this.triggers.forEach(trigger => {
|
|
960
|
+
if (trigger.menuOpen) {
|
|
961
|
+
trigger.closeMenu();
|
|
962
|
+
}
|
|
963
|
+
});
|
|
964
|
+
}
|
|
965
|
+
isCommand(child) {
|
|
966
|
+
return child instanceof CommandComponent;
|
|
967
|
+
}
|
|
968
|
+
isPopupMenu(child) {
|
|
969
|
+
return child instanceof AbstractPopupMenuComponent;
|
|
970
|
+
}
|
|
971
|
+
isSeparator(child) {
|
|
972
|
+
return child instanceof SeparatorComponent;
|
|
973
|
+
}
|
|
974
|
+
getTooltip(child) {
|
|
975
|
+
return this.isCommand(child) ? CommandFace.getTooltipOf(child.face) : undefined;
|
|
976
|
+
}
|
|
977
|
+
getFaces(child) {
|
|
978
|
+
return this.isCommand(child) ?
|
|
979
|
+
child.faces.value :
|
|
980
|
+
this.isPopupMenu(child) ?
|
|
981
|
+
[child.faceAdapter.face] :
|
|
982
|
+
undefined;
|
|
983
|
+
}
|
|
984
|
+
}
|
|
985
|
+
PopupMenuRendererComponent.decorators = [
|
|
986
|
+
{ type: Component, args: [{
|
|
987
|
+
selector: 'aup-popup-menu-renderer',
|
|
988
|
+
template: "<mat-menu #menu [xPosition]=\"parent.xPosition\" [yPosition]=\"parent.yPosition\">\n <ng-template matMenuContent>\n <ng-container *ngFor=\"let child of children; trackBy: TrackBy.byIndex\" >\n <button *ngIf=\"isCommand(child)\"\n (click)=\"executeCommand(child)\"\n [disabled]=\"!isEnabled(child)\"\n [matTooltip]=\"getTooltip(child)\"\n mat-menu-item>\n <aup-command-face [faces]=\"getFaces(child)\"\n [includeMissingIconInLayout]=\"hasMixedIcons.value\"></aup-command-face>\n </button>\n\n <ng-container *ngIf=\"isPopupMenu(child)\">\n <button mat-menu-item\n matMenuTrigger\n [matMenuTriggerFor]=\"innerPanel.menuComponent\"\n >\n <aup-command-face [faces]=\"getFaces(child)\"\n [includeMissingIconInLayout]=\"hasMixedIcons.value\"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #innerPanel\n [parent]=\"child\"\n (commandFired)=\"onCommandFired()\"></aup-popup-menu-renderer>\n </ng-container>\n\n <mat-divider *ngIf=\"isSeparator(child)\"></mat-divider>\n\n </ng-container>\n\n </ng-template>\n</mat-menu>\n"
|
|
989
|
+
},] }
|
|
990
|
+
];
|
|
991
|
+
PopupMenuRendererComponent.ctorParameters = () => [];
|
|
992
|
+
PopupMenuRendererComponent.propDecorators = {
|
|
993
|
+
parent: [{ type: Input }],
|
|
994
|
+
menuComponent: [{ type: ViewChild, args: ['menu', { static: true },] }],
|
|
995
|
+
commandFired: [{ type: Output }],
|
|
996
|
+
triggers: [{ type: ViewChildren, args: [MatMenuTrigger,] }]
|
|
997
|
+
};
|
|
998
998
|
|
|
999
999
|
class FocusContainerComponent extends DisposableComponent {
|
|
1000
1000
|
constructor(focusManager) {
|
|
@@ -2006,10 +2006,13 @@ const noop = () => {
|
|
|
2006
2006
|
const ɵ0 = noop;
|
|
2007
2007
|
const CELL_RENDERER_COMPONENT_ROW_CACHE = Symbol("aup-cell-renderer:row-data-cache");
|
|
2008
2008
|
class ColumnModel {
|
|
2009
|
-
constructor(columnId,
|
|
2009
|
+
constructor(columnId, textPropertiesProvider) {
|
|
2010
2010
|
this.columnId = columnId;
|
|
2011
|
-
this.
|
|
2011
|
+
this.textPropertiesProvider = textPropertiesProvider;
|
|
2012
2012
|
this._selectRowOnClick = undefined;
|
|
2013
|
+
this.installHeaderRenderer();
|
|
2014
|
+
}
|
|
2015
|
+
installHeaderRenderer() {
|
|
2013
2016
|
this.cellHeaderRenderer(DefaultHeaderCellRendererComponent, (component, column) => {
|
|
2014
2017
|
component.headerText = column.getHeaderText();
|
|
2015
2018
|
});
|
|
@@ -2022,7 +2025,7 @@ class ColumnModel {
|
|
|
2022
2025
|
return this.columnId;
|
|
2023
2026
|
}
|
|
2024
2027
|
getColumnTextProperties() {
|
|
2025
|
-
return this._columnTextProperties || this.
|
|
2028
|
+
return this._columnTextProperties || this.textPropertiesProvider();
|
|
2026
2029
|
}
|
|
2027
2030
|
textProperties(columnTextProperties) {
|
|
2028
2031
|
this._columnTextProperties = columnTextProperties;
|
|
@@ -2311,7 +2314,6 @@ class SelectionColumnModel extends ColumnModel {
|
|
|
2311
2314
|
}
|
|
2312
2315
|
}
|
|
2313
2316
|
|
|
2314
|
-
var TableModel_1;
|
|
2315
2317
|
// export type StringPropertiesOf<T> = { [K in keyof T]: T[K] extends string ? K : never }[keyof T];
|
|
2316
2318
|
// export type NumberPropertiesOf<T> = { [K in keyof T]: T[K] extends number ? K : never }[keyof T];
|
|
2317
2319
|
class RowClass {
|
|
@@ -2320,80 +2322,10 @@ class RowClass {
|
|
|
2320
2322
|
this.matches = matches;
|
|
2321
2323
|
}
|
|
2322
2324
|
}
|
|
2323
|
-
|
|
2324
|
-
* Example:
|
|
2325
|
-
* @example
|
|
2326
|
-
* const model = TableModel.fromList(heroList, table => {
|
|
2327
|
-
* table.pluck("firstName");
|
|
2328
|
-
* table.pluck("lastName");
|
|
2329
|
-
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
2330
|
-
* });
|
|
2331
|
-
*
|
|
2332
|
-
* Editable tables
|
|
2333
|
-
* @example
|
|
2334
|
-
* const saveCommand = UnaryCommand.create((form: Form<Hero>) => {
|
|
2335
|
-
* if (form.validate()) {
|
|
2336
|
-
* // normal form save stuff
|
|
2337
|
-
* return true; // finish editing
|
|
2338
|
-
* }
|
|
2339
|
-
* return false; // continue editiing
|
|
2340
|
-
* }
|
|
2341
|
-
* const colorsNames: ListModel<string> = ...;
|
|
2342
|
-
* const model = TableModel.fromList(heroList, table => {
|
|
2343
|
-
* table.pluck("firstName").cellEditor(StringInputComponent); <-- interface CellEditor { valueModel: DirtyTrackingForm.ValueModel<string> | ValueModel<string>; }
|
|
2344
|
-
* table.pluck("lastName").cellEditor(StringInputComponent, {
|
|
2345
|
-
* validators: [Validator.present("We need a last name")]
|
|
2346
|
-
* });
|
|
2347
|
-
* table.pluck("age").cellEditor(NumberInputComponent);
|
|
2348
|
-
* table.pluck("favoriteColor").cellEditor(SelectInputComponent, {
|
|
2349
|
-
* initialiseComponent(component: SelectInputComponent) {
|
|
2350
|
-
* selectInput.optionsModel = colorsNames; // <- initialise our component
|
|
2351
|
-
* }
|
|
2352
|
-
* });
|
|
2353
|
-
* table.addEditControls(saveCommand); // <- required to enable editing
|
|
2354
|
-
* });
|
|
2355
|
-
*
|
|
2356
|
-
* Selection models
|
|
2357
|
-
* @example
|
|
2358
|
-
* const model = TableModel.fromList(heroList, table => {
|
|
2359
|
-
* table.addSelectionColumn(selectionModel); // <- can be single or multiple selection model
|
|
2360
|
-
* table.pluck("firstName");
|
|
2361
|
-
* table.pluck("lastName");
|
|
2362
|
-
* });
|
|
2363
|
-
*
|
|
2364
|
-
* Custom cell renderers and editors
|
|
2365
|
-
* @example
|
|
2366
|
-
* const model = TableModel.fromList(heroList, table => {
|
|
2367
|
-
* table.pluck("favoriteColor")
|
|
2368
|
-
* .cellHeaderRenderer(CellHeaderRendererComponent, (component, column) => {
|
|
2369
|
-
* // configure your component with what ever you need.
|
|
2370
|
-
* });
|
|
2371
|
-
* .cellRenderer(CellRendererComponent) // <-- interface CellEditor { value: string; }
|
|
2372
|
-
* .cellEditor(CellEditorComponent.); // <-- interface CellEditor { valueModel: DirtyTrackingForm.ValueModel<string> | ValueModel<string>; }
|
|
2373
|
-
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
2374
|
-
* });
|
|
2375
|
-
*
|
|
2376
|
-
* I18n
|
|
2377
|
-
* @example
|
|
2378
|
-
* [table.yml]
|
|
2379
|
-
* table:
|
|
2380
|
-
* columns(ColumnTextProperties[]):
|
|
2381
|
-
* firstName:
|
|
2382
|
-
* headerText: "First Name"
|
|
2383
|
-
* fullName:
|
|
2384
|
-
* headerText: "Full Name"
|
|
2385
|
-
*
|
|
2386
|
-
* const model = TableModel.fromList(heroList, table => {
|
|
2387
|
-
* table.pluck("favoriteColor").cellRenderer(...).cellEditor(...);
|
|
2388
|
-
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
2389
|
-
*
|
|
2390
|
-
* table.columnTextProperties(I18n.table.columns); // <- configures all columns
|
|
2391
|
-
* });
|
|
2392
|
-
*/
|
|
2393
|
-
let TableModel = TableModel_1 = class TableModel {
|
|
2325
|
+
let AbstractTableModel = class AbstractTableModel extends GarbageCollector {
|
|
2394
2326
|
constructor(sourceOfTruth) {
|
|
2327
|
+
super();
|
|
2395
2328
|
this.sourceOfTruth = sourceOfTruth;
|
|
2396
|
-
this._garbage = new GarbageCollector();
|
|
2397
2329
|
this._columns = new MutableListModel();
|
|
2398
2330
|
this._editorSessions = new MutableListModel();
|
|
2399
2331
|
this.rowClassNamePredicates = [];
|
|
@@ -2403,7 +2335,7 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2403
2335
|
return this.identityOf ? this.identityOf(item) : index;
|
|
2404
2336
|
};
|
|
2405
2337
|
this.identityOf = sourceOfTruth.identityOf;
|
|
2406
|
-
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this
|
|
2338
|
+
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(this);
|
|
2407
2339
|
this._columnsById = chain(this._columns).indexBy('columnId');
|
|
2408
2340
|
this._rowsBeingEdited = new MutableListModel([], {
|
|
2409
2341
|
identifiedWith: this.identityOf
|
|
@@ -2414,11 +2346,6 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2414
2346
|
this.firstEditableColumn = chain(this.columns).select(c => c.hasEditorPortal()).first();
|
|
2415
2347
|
this.hasColumnsWithRowSelectionExplicitlyEnabled = chain(this._columns).findIndex(column => column.isRowSelectionExplicitlyEnabled()).isGreaterThanOrEqualTo(0);
|
|
2416
2348
|
}
|
|
2417
|
-
static fromList(sourceOfTruth, builder) {
|
|
2418
|
-
const model = new TableModel_1(sourceOfTruth);
|
|
2419
|
-
builder(model);
|
|
2420
|
-
return model;
|
|
2421
|
-
}
|
|
2422
2349
|
get rowsBeingEdited() {
|
|
2423
2350
|
return this._rowsBeingEdited.readonly;
|
|
2424
2351
|
}
|
|
@@ -2426,28 +2353,32 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2426
2353
|
return this._columns.readonly;
|
|
2427
2354
|
}
|
|
2428
2355
|
pluck(property, options) {
|
|
2429
|
-
|
|
2356
|
+
const columnId = (options === null || options === void 0 ? void 0 : options.columnId) || property.toString();
|
|
2357
|
+
return this.addColumn(new PropertyColumnModel(columnId, property, () => this.getColumnTextProperties(columnId)));
|
|
2430
2358
|
}
|
|
2431
2359
|
pluckList(property, options) {
|
|
2432
|
-
|
|
2360
|
+
const columnId = (options === null || options === void 0 ? void 0 : options.columnId) || property.toString();
|
|
2361
|
+
return this.addColumn(new ListPropertyColumnModel(columnId, property, () => this.getColumnTextProperties(columnId)));
|
|
2433
2362
|
}
|
|
2434
|
-
|
|
2363
|
+
_addSelectionColumn(selectionModel) {
|
|
2435
2364
|
assert.isNil(this.selectionColumnModel);
|
|
2436
|
-
|
|
2365
|
+
const columnId = 'selection-column';
|
|
2366
|
+
this.selectionColumnModel = new SelectionColumnModel(columnId, () => this.getColumnTextProperties(columnId), selectionModel);
|
|
2437
2367
|
return this.addColumn(this.selectionColumnModel);
|
|
2438
2368
|
}
|
|
2439
2369
|
addEditControls(saveCommand) {
|
|
2440
2370
|
this.saveCommand = saveCommand;
|
|
2441
|
-
|
|
2371
|
+
const columnId = 'editControls';
|
|
2372
|
+
return this.addColumn(new EditorControlColumnModel(columnId, saveCommand, () => this.getColumnTextProperties(columnId)));
|
|
2442
2373
|
}
|
|
2443
2374
|
addCustomColumn(columnId, dataAccessor) {
|
|
2444
|
-
return this.addColumn(new CustomValueColumnModel(columnId, this, dataAccessor));
|
|
2375
|
+
return this.addColumn(new CustomValueColumnModel(columnId, () => this.getColumnTextProperties(columnId), dataAccessor));
|
|
2445
2376
|
}
|
|
2446
2377
|
addComponentColumn(columnId, component, onComponentInitOrOptions) {
|
|
2447
|
-
return this.addColumn(new CustomValueColumnModel(columnId, this, row => row)).cellRenderer(component, onComponentInitOrOptions);
|
|
2378
|
+
return this.addColumn(new CustomValueColumnModel(columnId, () => this.getColumnTextProperties(columnId), row => row)).cellRenderer(component, onComponentInitOrOptions);
|
|
2448
2379
|
}
|
|
2449
2380
|
addTemplateColumn(columnId) {
|
|
2450
|
-
return this.addColumn(new CustomTemplateColumnModel(columnId, this));
|
|
2381
|
+
return this.addColumn(new CustomTemplateColumnModel(columnId, () => this.getColumnTextProperties(columnId)));
|
|
2451
2382
|
}
|
|
2452
2383
|
addRowClass(className, predicate) {
|
|
2453
2384
|
this.rowClassNamePredicates.push(new RowClass(className, predicate));
|
|
@@ -2474,14 +2405,18 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2474
2405
|
}
|
|
2475
2406
|
return column;
|
|
2476
2407
|
}
|
|
2408
|
+
get selectionModel() {
|
|
2409
|
+
var _a;
|
|
2410
|
+
return (_a = this.selectionColumnModel) === null || _a === void 0 ? void 0 : _a.selectionModel;
|
|
2411
|
+
}
|
|
2477
2412
|
// removeColumn(column: ColumnModel<Row>) {
|
|
2478
2413
|
//
|
|
2479
2414
|
// }
|
|
2480
2415
|
columnTextProperties(columnTextProperties) {
|
|
2481
2416
|
this._columnTextPropertiesLookup = columnTextProperties;
|
|
2482
2417
|
}
|
|
2483
|
-
getColumnTextProperties(
|
|
2484
|
-
return this._columnTextPropertiesLookup ? this._columnTextPropertiesLookup[
|
|
2418
|
+
getColumnTextProperties(columnId) {
|
|
2419
|
+
return this._columnTextPropertiesLookup ? this._columnTextPropertiesLookup[columnId] : undefined;
|
|
2485
2420
|
}
|
|
2486
2421
|
startEditSession(row) {
|
|
2487
2422
|
const rowId = this.identityOf(row);
|
|
@@ -2526,11 +2461,6 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2526
2461
|
return this.isRowSelectionEnabled() || this.rowClickListeners.listenerCount > 0;
|
|
2527
2462
|
}
|
|
2528
2463
|
isCursorEnabled(column) {
|
|
2529
|
-
// console.log({
|
|
2530
|
-
// column: column.columnId,
|
|
2531
|
-
// rowSelectionEnabled: this.isRowSelectionEnabledFor(column),
|
|
2532
|
-
// hasRowListeners: this.rowClickListeners.listenerCount > 0
|
|
2533
|
-
// });
|
|
2534
2464
|
return this.isRowSelectionEnabledFor(column) || this.rowClickListeners.listenerCount > 0;
|
|
2535
2465
|
}
|
|
2536
2466
|
selectRow(row) {
|
|
@@ -2540,7 +2470,6 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2540
2470
|
onRowClicked(callback) {
|
|
2541
2471
|
return this.rowClickListeners.add(callback);
|
|
2542
2472
|
}
|
|
2543
|
-
// @Trace()
|
|
2544
2473
|
_notifyCellClicked(columnModel, row) {
|
|
2545
2474
|
if (this.isRowSelectionEnabledFor(columnModel)) {
|
|
2546
2475
|
this.selectRow(row);
|
|
@@ -2548,10 +2477,10 @@ let TableModel = TableModel_1 = class TableModel {
|
|
|
2548
2477
|
this.rowClickListeners.fire(l => l(row));
|
|
2549
2478
|
}
|
|
2550
2479
|
};
|
|
2551
|
-
|
|
2480
|
+
AbstractTableModel = __decorate([
|
|
2552
2481
|
TrackExternal.Strategy(new TrackExternal.OneTimeBinding()),
|
|
2553
2482
|
__metadata("design:paramtypes", [ListModel])
|
|
2554
|
-
],
|
|
2483
|
+
], AbstractTableModel);
|
|
2555
2484
|
|
|
2556
2485
|
/**
|
|
2557
2486
|
* Create your model:
|
|
@@ -2607,7 +2536,7 @@ TableComponent.decorators = [
|
|
|
2607
2536
|
{ type: Component, args: [{
|
|
2608
2537
|
selector: 'aup-table',
|
|
2609
2538
|
template: "<table mat-table [dataSource]=\"tableModel.dataSource.value\" [trackBy]=\"tableModel.trackBy\">\n\n <ng-container *ngFor=\"let column of columns.value; index as index; first as first; last as last\" matColumnDef=\"{{column.columnId}}\">\n <th mat-header-cell *matHeaderCellDef>\n <aup-table-header-cell-renderer [column]=\"column\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef=\"let row\" (click)=\"notifyCellClicked(column, row)\" [class.enable-cursor]=\"tableModel.isCursorEnabled(column)\">\n <aup-table-cell-renderer [column]=\"column\"\n [row]=\"row\"\n [tableModel]=\"tableModel\"\n [editSession]=\"tableModel.getEditSessionFor(row)\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-cell-renderer>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"columnIds.value\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: columnIds.value; let i = index\"\n [ngClass]=\"tableModel.getRowClasses(row)\" [class.enable-hover]=\"tableModel.isHoverEnabled()\" [attr.trackBy]=\"tableModel.trackBy(i, row)\"\n ></tr>\n\n</table>\n",
|
|
2610
|
-
styles: [":host{align-items:stretch;display:flex;flex-direction:column}:host table{flex:1;width:100%}"]
|
|
2539
|
+
styles: [":host{align-items:stretch;display:flex;flex-direction:column}:host table{flex:1;width:100%}.mat-column-selection-column{width:1px!important}"]
|
|
2611
2540
|
},] }
|
|
2612
2541
|
];
|
|
2613
2542
|
TableComponent.ctorParameters = () => [];
|
|
@@ -2616,7 +2545,7 @@ TableComponent.propDecorators = {
|
|
|
2616
2545
|
};
|
|
2617
2546
|
__decorate([
|
|
2618
2547
|
TrackExternal(),
|
|
2619
|
-
__metadata("design:type",
|
|
2548
|
+
__metadata("design:type", AbstractTableModel)
|
|
2620
2549
|
], TableComponent.prototype, "tableModel", void 0);
|
|
2621
2550
|
|
|
2622
2551
|
class ColumnTemplateDirective {
|
|
@@ -2627,28 +2556,110 @@ class ColumnTemplateDirective {
|
|
|
2627
2556
|
this.aupColumnTemplateFillCell = false;
|
|
2628
2557
|
this.aupColumnTemplateAutoPadChild = undefined;
|
|
2629
2558
|
}
|
|
2630
|
-
ngOnInit() {
|
|
2631
|
-
var _a;
|
|
2632
|
-
assert.isTruthy(this.aupColumnTemplateColumnId);
|
|
2633
|
-
this.host.registerColumnTemplate(this.aupColumnTemplateColumnId, this.templateRef, this.viewContainer, this.aupColumnTemplateFillCell, (_a = this.aupColumnTemplateAutoPadChild) !== null && _a !== void 0 ? _a : this.aupColumnTemplateFillCell);
|
|
2559
|
+
ngOnInit() {
|
|
2560
|
+
var _a;
|
|
2561
|
+
assert.isTruthy(this.aupColumnTemplateColumnId);
|
|
2562
|
+
this.host.registerColumnTemplate(this.aupColumnTemplateColumnId, this.templateRef, this.viewContainer, this.aupColumnTemplateFillCell, (_a = this.aupColumnTemplateAutoPadChild) !== null && _a !== void 0 ? _a : this.aupColumnTemplateFillCell);
|
|
2563
|
+
}
|
|
2564
|
+
}
|
|
2565
|
+
ColumnTemplateDirective.decorators = [
|
|
2566
|
+
{ type: Directive, args: [{
|
|
2567
|
+
selector: '[aupColumnTemplate]'
|
|
2568
|
+
},] }
|
|
2569
|
+
];
|
|
2570
|
+
ColumnTemplateDirective.ctorParameters = () => [
|
|
2571
|
+
{ type: TableComponent },
|
|
2572
|
+
{ type: TemplateRef },
|
|
2573
|
+
{ type: ViewContainerRef }
|
|
2574
|
+
];
|
|
2575
|
+
ColumnTemplateDirective.propDecorators = {
|
|
2576
|
+
aupColumnTemplate: [{ type: Input }],
|
|
2577
|
+
aupColumnTemplateColumnId: [{ type: Input }],
|
|
2578
|
+
aupColumnTemplateFillCell: [{ type: Input }],
|
|
2579
|
+
aupColumnTemplateAutoPadChild: [{ type: Input }]
|
|
2580
|
+
};
|
|
2581
|
+
|
|
2582
|
+
/**
|
|
2583
|
+
* Example:
|
|
2584
|
+
* @example
|
|
2585
|
+
* const model = TableModel.fromList(heroList, table => {
|
|
2586
|
+
* table.pluck("firstName");
|
|
2587
|
+
* table.pluck("lastName");
|
|
2588
|
+
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
2589
|
+
* });
|
|
2590
|
+
*
|
|
2591
|
+
* Editable tables
|
|
2592
|
+
* @example
|
|
2593
|
+
* const saveCommand = UnaryCommand.create((form: Form<Hero>) => {
|
|
2594
|
+
* if (form.validate()) {
|
|
2595
|
+
* // normal form save stuff
|
|
2596
|
+
* return true; // finish editing
|
|
2597
|
+
* }
|
|
2598
|
+
* return false; // continue editiing
|
|
2599
|
+
* }
|
|
2600
|
+
* const colorsNames: ListModel<string> = ...;
|
|
2601
|
+
* const model = TableModel.fromList(heroList, table => {
|
|
2602
|
+
* table.pluck("firstName").cellEditor(StringInputComponent); <-- interface CellEditor { valueModel: DirtyTrackingForm.ValueModel<string> | ValueModel<string>; }
|
|
2603
|
+
* table.pluck("lastName").cellEditor(StringInputComponent, {
|
|
2604
|
+
* validators: [Validator.present("We need a last name")]
|
|
2605
|
+
* });
|
|
2606
|
+
* table.pluck("age").cellEditor(NumberInputComponent);
|
|
2607
|
+
* table.pluck("favoriteColor").cellEditor(SelectInputComponent, {
|
|
2608
|
+
* initialiseComponent(component: SelectInputComponent) {
|
|
2609
|
+
* selectInput.optionsModel = colorsNames; // <- initialise our component
|
|
2610
|
+
* }
|
|
2611
|
+
* });
|
|
2612
|
+
* table.addEditControls(saveCommand); // <- required to enable editing
|
|
2613
|
+
* });
|
|
2614
|
+
*
|
|
2615
|
+
* Selection models
|
|
2616
|
+
* @example
|
|
2617
|
+
* const model = TableModel.fromList(heroList, table => {
|
|
2618
|
+
* table.addSelectionColumn(selectionModel); // <- can be single or multiple selection model
|
|
2619
|
+
* table.pluck("firstName");
|
|
2620
|
+
* table.pluck("lastName");
|
|
2621
|
+
* });
|
|
2622
|
+
*
|
|
2623
|
+
* Custom cell renderers and editors
|
|
2624
|
+
* @example
|
|
2625
|
+
* const model = TableModel.fromList(heroList, table => {
|
|
2626
|
+
* table.pluck("favoriteColor")
|
|
2627
|
+
* .cellHeaderRenderer(CellHeaderRendererComponent, (component, column) => {
|
|
2628
|
+
* // configure your component with what ever you need.
|
|
2629
|
+
* });
|
|
2630
|
+
* .cellRenderer(CellRendererComponent) // <-- interface CellEditor { value: string; }
|
|
2631
|
+
* .cellEditor(CellEditorComponent.); // <-- interface CellEditor { valueModel: DirtyTrackingForm.ValueModel<string> | ValueModel<string>; }
|
|
2632
|
+
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
2633
|
+
* });
|
|
2634
|
+
*
|
|
2635
|
+
* I18n
|
|
2636
|
+
* @example
|
|
2637
|
+
* [table.yml]
|
|
2638
|
+
* table:
|
|
2639
|
+
* columns(ColumnTextProperties[]):
|
|
2640
|
+
* firstName:
|
|
2641
|
+
* headerText: "First Name"
|
|
2642
|
+
* fullName:
|
|
2643
|
+
* headerText: "Full Name"
|
|
2644
|
+
*
|
|
2645
|
+
* const model = TableModel.fromList(heroList, table => {
|
|
2646
|
+
* table.pluck("favoriteColor").cellRenderer(...).cellEditor(...);
|
|
2647
|
+
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
2648
|
+
*
|
|
2649
|
+
* table.columnTextProperties(I18n.table.columns); // <- configures all columns
|
|
2650
|
+
* });
|
|
2651
|
+
*/
|
|
2652
|
+
class TableModel extends AbstractTableModel {
|
|
2653
|
+
static fromList(sourceOfTruth, builder) {
|
|
2654
|
+
const model = new TableModel(sourceOfTruth);
|
|
2655
|
+
if (builder)
|
|
2656
|
+
builder(model);
|
|
2657
|
+
return model;
|
|
2658
|
+
}
|
|
2659
|
+
addSelectionColumn(selectionModel) {
|
|
2660
|
+
return this._addSelectionColumn(selectionModel);
|
|
2634
2661
|
}
|
|
2635
2662
|
}
|
|
2636
|
-
ColumnTemplateDirective.decorators = [
|
|
2637
|
-
{ type: Directive, args: [{
|
|
2638
|
-
selector: '[aupColumnTemplate]'
|
|
2639
|
-
},] }
|
|
2640
|
-
];
|
|
2641
|
-
ColumnTemplateDirective.ctorParameters = () => [
|
|
2642
|
-
{ type: TableComponent },
|
|
2643
|
-
{ type: TemplateRef },
|
|
2644
|
-
{ type: ViewContainerRef }
|
|
2645
|
-
];
|
|
2646
|
-
ColumnTemplateDirective.propDecorators = {
|
|
2647
|
-
aupColumnTemplate: [{ type: Input }],
|
|
2648
|
-
aupColumnTemplateColumnId: [{ type: Input }],
|
|
2649
|
-
aupColumnTemplateFillCell: [{ type: Input }],
|
|
2650
|
-
aupColumnTemplateAutoPadChild: [{ type: Input }]
|
|
2651
|
-
};
|
|
2652
2663
|
|
|
2653
2664
|
class TableCellRendererComponent extends DisposableComponent {
|
|
2654
2665
|
constructor() {
|
|
@@ -2815,6 +2826,583 @@ TableRowMenuComponent.propDecorators = {
|
|
|
2815
2826
|
menu: [{ type: ViewChild, args: [MatMenuTrigger,] }]
|
|
2816
2827
|
};
|
|
2817
2828
|
|
|
2829
|
+
const SVG_HEIGHT = 60;
|
|
2830
|
+
class TreeInheritanceIconComponent {
|
|
2831
|
+
constructor() {
|
|
2832
|
+
this.pixelWidth = 24;
|
|
2833
|
+
this.pixelHeight = 48;
|
|
2834
|
+
}
|
|
2835
|
+
get heightOffset() {
|
|
2836
|
+
return SVG_HEIGHT - this.pixelHeight;
|
|
2837
|
+
}
|
|
2838
|
+
get viewBox() {
|
|
2839
|
+
return `${0} ${this.heightOffset} ${this.pixelWidth} ${this.pixelHeight - this.heightOffset}`;
|
|
2840
|
+
}
|
|
2841
|
+
hasHead() {
|
|
2842
|
+
return TreeInheritanceIconComponent.HAS_HEAD.includes(this.type);
|
|
2843
|
+
}
|
|
2844
|
+
hasTerminal() {
|
|
2845
|
+
return TreeInheritanceIconComponent.HAS_TERMINAL.includes(this.type);
|
|
2846
|
+
}
|
|
2847
|
+
hasLeadIn() {
|
|
2848
|
+
return TreeInheritanceIconComponent.HAS_LEAD_IN.includes(this.type);
|
|
2849
|
+
}
|
|
2850
|
+
hasTail() {
|
|
2851
|
+
return TreeInheritanceIconComponent.HAS_TAIL.includes(this.type);
|
|
2852
|
+
}
|
|
2853
|
+
}
|
|
2854
|
+
TreeInheritanceIconComponent.decorators = [
|
|
2855
|
+
{ type: Component, args: [{
|
|
2856
|
+
selector: 'aup-tree-inheritance-icon',
|
|
2857
|
+
template: "<svg xmlns=\"http://www.w3.org/2000/svg\" [attr.width]=\"pixelWidth\" [attr.height]=\"pixelHeight\" [attr.viewBox]=\"viewBox\">\n <g fill=\"none\" fill-rule=\"evenodd\">\n <rect *ngIf=\"hasHead()\" width=\"1\" height=\"32.5\" x=\"11.5\" fill=\"currentColor\"/>\n <rect *ngIf=\"hasTail()\" width=\"1\" height=\"32.5\" x=\"11.5\" y=\"31.5\" fill=\"currentColor\"/>\n\n <rect *ngIf=\"hasLeadIn()\" width=\"12\" height=\"1\" y=\"31.5\" fill=\"currentColor\"/>\n <rect *ngIf=\"hasTerminal()\" width=\"12\" height=\"1\" x=\"12\" y=\"31.5\" fill=\"currentColor\"/>\n </g>\n</svg>\n",
|
|
2858
|
+
styles: [":host{color:inherit;position:relative}svg{color:var(--line-color);display:block}"]
|
|
2859
|
+
},] }
|
|
2860
|
+
];
|
|
2861
|
+
TreeInheritanceIconComponent.ctorParameters = () => [];
|
|
2862
|
+
TreeInheritanceIconComponent.propDecorators = {
|
|
2863
|
+
type: [{ type: Input }, { type: HostBinding, args: ["class",] }],
|
|
2864
|
+
pixelWidth: [{ type: Input }],
|
|
2865
|
+
pixelHeight: [{ type: Input }]
|
|
2866
|
+
};
|
|
2867
|
+
(function (TreeInheritanceIconComponent) {
|
|
2868
|
+
TreeInheritanceIconComponent.Type = Enum({
|
|
2869
|
+
ICON_BLANK: 'blank',
|
|
2870
|
+
ICON_PARENT: 'parent',
|
|
2871
|
+
ICON_INHERITED_TERMINAL: 'inherited_terminal',
|
|
2872
|
+
ICON_INHERITED_THROUGH_TERMINAL: 'inherited_through_terminal',
|
|
2873
|
+
ICON_THROUGH: 'through' // |
|
|
2874
|
+
});
|
|
2875
|
+
TreeInheritanceIconComponent.HAS_LEAD_IN = [
|
|
2876
|
+
TreeInheritanceIconComponent.Type.ICON_PARENT
|
|
2877
|
+
];
|
|
2878
|
+
TreeInheritanceIconComponent.HAS_TERMINAL = [
|
|
2879
|
+
TreeInheritanceIconComponent.Type.ICON_INHERITED_TERMINAL,
|
|
2880
|
+
TreeInheritanceIconComponent.Type.ICON_INHERITED_THROUGH_TERMINAL,
|
|
2881
|
+
TreeInheritanceIconComponent.Type.ICON_PARENT
|
|
2882
|
+
];
|
|
2883
|
+
TreeInheritanceIconComponent.HAS_HEAD = [
|
|
2884
|
+
TreeInheritanceIconComponent.Type.ICON_THROUGH,
|
|
2885
|
+
TreeInheritanceIconComponent.Type.ICON_INHERITED_TERMINAL,
|
|
2886
|
+
TreeInheritanceIconComponent.Type.ICON_INHERITED_THROUGH_TERMINAL
|
|
2887
|
+
];
|
|
2888
|
+
TreeInheritanceIconComponent.HAS_TAIL = [
|
|
2889
|
+
TreeInheritanceIconComponent.Type.ICON_PARENT,
|
|
2890
|
+
TreeInheritanceIconComponent.Type.ICON_THROUGH,
|
|
2891
|
+
TreeInheritanceIconComponent.Type.ICON_INHERITED_THROUGH_TERMINAL
|
|
2892
|
+
];
|
|
2893
|
+
})(TreeInheritanceIconComponent || (TreeInheritanceIconComponent = {}));
|
|
2894
|
+
|
|
2895
|
+
class SelfAndDescendantsVisitor {
|
|
2896
|
+
constructor() {
|
|
2897
|
+
}
|
|
2898
|
+
visit(it) {
|
|
2899
|
+
this.onVisit(it);
|
|
2900
|
+
if (this.shouldVisitChildrenOf(it)) {
|
|
2901
|
+
it.visitChildren(this);
|
|
2902
|
+
}
|
|
2903
|
+
}
|
|
2904
|
+
shouldVisitChildrenOf(it) {
|
|
2905
|
+
return true;
|
|
2906
|
+
}
|
|
2907
|
+
}
|
|
2908
|
+
(function (SelfAndDescendantsVisitor) {
|
|
2909
|
+
class Each extends SelfAndDescendantsVisitor {
|
|
2910
|
+
constructor(callback) {
|
|
2911
|
+
super();
|
|
2912
|
+
this.callback = callback;
|
|
2913
|
+
}
|
|
2914
|
+
onVisit(it) {
|
|
2915
|
+
this.callback(it);
|
|
2916
|
+
}
|
|
2917
|
+
}
|
|
2918
|
+
SelfAndDescendantsVisitor.Each = Each;
|
|
2919
|
+
})(SelfAndDescendantsVisitor || (SelfAndDescendantsVisitor = {}));
|
|
2920
|
+
|
|
2921
|
+
class DecoratedTreeNodeMixin {
|
|
2922
|
+
constructor(parent, node) {
|
|
2923
|
+
this.parent = parent;
|
|
2924
|
+
this.node = node;
|
|
2925
|
+
}
|
|
2926
|
+
get decoratedSelf() {
|
|
2927
|
+
return this.memoize("decoratedSelf", () => {
|
|
2928
|
+
return this.parent ? this.parent.children.find(child => child.node === this.node) : DecoratedTreeNode.createRoot(this.node);
|
|
2929
|
+
});
|
|
2930
|
+
}
|
|
2931
|
+
get children() {
|
|
2932
|
+
return this.memoize("children", () => {
|
|
2933
|
+
return this.node.children ? this.node.children.map(child => {
|
|
2934
|
+
return Mixin.createProxy(child, new DecoratedTreeNodeMixin(this.decoratedSelf, child));
|
|
2935
|
+
}) : [];
|
|
2936
|
+
});
|
|
2937
|
+
}
|
|
2938
|
+
descendants() {
|
|
2939
|
+
return this.memoize("descendants", () => {
|
|
2940
|
+
const result = [];
|
|
2941
|
+
this.visitDescendants(child => result.push(child));
|
|
2942
|
+
return result;
|
|
2943
|
+
});
|
|
2944
|
+
}
|
|
2945
|
+
selfAndDescendants() {
|
|
2946
|
+
return this.memoize("selfAndDescendants", () => {
|
|
2947
|
+
const result = [];
|
|
2948
|
+
this.visitSelfAndDescendants(child => result.push(child));
|
|
2949
|
+
return result;
|
|
2950
|
+
});
|
|
2951
|
+
}
|
|
2952
|
+
siblingsBefore() {
|
|
2953
|
+
return this.memoize('siblingsBefore', () => {
|
|
2954
|
+
if (this.parent) {
|
|
2955
|
+
return this.parent.children.slice(0, this.myIndex());
|
|
2956
|
+
}
|
|
2957
|
+
else {
|
|
2958
|
+
return [];
|
|
2959
|
+
}
|
|
2960
|
+
});
|
|
2961
|
+
}
|
|
2962
|
+
siblingsAfter() {
|
|
2963
|
+
return this.memoize('siblingsAfter', () => {
|
|
2964
|
+
if (this.parent) {
|
|
2965
|
+
return this.parent.children.slice(1 + this.myIndex());
|
|
2966
|
+
}
|
|
2967
|
+
else {
|
|
2968
|
+
return [];
|
|
2969
|
+
}
|
|
2970
|
+
});
|
|
2971
|
+
}
|
|
2972
|
+
siblings() {
|
|
2973
|
+
return this.memoize('siblings', () => [].concat(this.siblingsBefore(), this.siblingsAfter()));
|
|
2974
|
+
}
|
|
2975
|
+
isFirstChild() {
|
|
2976
|
+
return this.memoize('isFirstChild', () => this.parent ? this.myIndex() === 0 : false);
|
|
2977
|
+
}
|
|
2978
|
+
myIndex() {
|
|
2979
|
+
return this.memoize('myIndex', () => {
|
|
2980
|
+
const myIndex = this.parent.children.findIndex(child => child.node === this.node);
|
|
2981
|
+
assert.isTruthy(myIndex >= 0, 'illegal state, expected index to be >= 0');
|
|
2982
|
+
return myIndex;
|
|
2983
|
+
});
|
|
2984
|
+
}
|
|
2985
|
+
isLastChild() {
|
|
2986
|
+
return this.memoize('isLastChild', () => {
|
|
2987
|
+
return this.parent ? this.myIndex() === this.parent.children.length - 1 : false;
|
|
2988
|
+
});
|
|
2989
|
+
}
|
|
2990
|
+
hasSiblings() {
|
|
2991
|
+
return this.parent ? this.node.children.length > 1 : false;
|
|
2992
|
+
}
|
|
2993
|
+
find(predicate) {
|
|
2994
|
+
return find(this.descendants(), predicate);
|
|
2995
|
+
}
|
|
2996
|
+
select(predicate) {
|
|
2997
|
+
return filter(this.descendants(), predicate);
|
|
2998
|
+
}
|
|
2999
|
+
flattenInto(array) {
|
|
3000
|
+
this.visitSelfAndDescendants(child => array.push(child));
|
|
3001
|
+
return array;
|
|
3002
|
+
}
|
|
3003
|
+
ancestors() {
|
|
3004
|
+
return this.memoize('ancestors', () => {
|
|
3005
|
+
return this.parent ? this.parent.ancestors().concat([this.parent]) : [];
|
|
3006
|
+
});
|
|
3007
|
+
}
|
|
3008
|
+
ancestorsAndSelf() {
|
|
3009
|
+
return this.memoize("ancestorsAndSelf", () => {
|
|
3010
|
+
return this.ancestors().concat([(this.decoratedSelf)]);
|
|
3011
|
+
});
|
|
3012
|
+
}
|
|
3013
|
+
pathToParent(parent) {
|
|
3014
|
+
return this.memoize("pathToParent", () => {
|
|
3015
|
+
if (this.node === parent.node) {
|
|
3016
|
+
return [];
|
|
3017
|
+
}
|
|
3018
|
+
else if (this.parent) {
|
|
3019
|
+
return this.parent.pathToParent(parent).concat([this.parent]);
|
|
3020
|
+
}
|
|
3021
|
+
else {
|
|
3022
|
+
throw new Error('parent is not an ancestor');
|
|
3023
|
+
}
|
|
3024
|
+
});
|
|
3025
|
+
}
|
|
3026
|
+
pathToParentAndSelf(parent) {
|
|
3027
|
+
return this.memoize("pathToParentAndSelf", () => {
|
|
3028
|
+
return this.pathToParent(parent).concat([this.decoratedSelf]);
|
|
3029
|
+
});
|
|
3030
|
+
}
|
|
3031
|
+
isRoot() {
|
|
3032
|
+
return !this.parent;
|
|
3033
|
+
}
|
|
3034
|
+
get depth() {
|
|
3035
|
+
return this.isRoot() ? 0 : this.parent.depth + 1;
|
|
3036
|
+
}
|
|
3037
|
+
isLeaf() {
|
|
3038
|
+
return !this.isRoot() && this.node.children.length < 1;
|
|
3039
|
+
}
|
|
3040
|
+
hasChildren() {
|
|
3041
|
+
return this.node.children.length > 0;
|
|
3042
|
+
}
|
|
3043
|
+
depthFromParent(parent) {
|
|
3044
|
+
return this.pathToParent(parent).length;
|
|
3045
|
+
}
|
|
3046
|
+
treeDepth() {
|
|
3047
|
+
return this.memoize("treeDepth", () => {
|
|
3048
|
+
return 1 + this.descendants().map(child => child.depthFromParent(this)).reduce((prev, current) => Math.max(prev, current));
|
|
3049
|
+
});
|
|
3050
|
+
}
|
|
3051
|
+
flatten() {
|
|
3052
|
+
return this.memoize("flatten", () => {
|
|
3053
|
+
return this.flattenInto([]);
|
|
3054
|
+
});
|
|
3055
|
+
}
|
|
3056
|
+
visit(visitor) {
|
|
3057
|
+
visitor.visit(this);
|
|
3058
|
+
return visitor;
|
|
3059
|
+
}
|
|
3060
|
+
visitChildren(visitor) {
|
|
3061
|
+
each(this.children, child => child.visit(visitor));
|
|
3062
|
+
return visitor;
|
|
3063
|
+
}
|
|
3064
|
+
visitSelfAndDescendants(callback) {
|
|
3065
|
+
this.visit(new SelfAndDescendantsVisitor.Each(callback));
|
|
3066
|
+
}
|
|
3067
|
+
visitDescendants(callback) {
|
|
3068
|
+
this.visitChildren(new SelfAndDescendantsVisitor.Each(callback));
|
|
3069
|
+
}
|
|
3070
|
+
memoize(property, factory) {
|
|
3071
|
+
const key = `__${property}`;
|
|
3072
|
+
if (isNil(this[key])) {
|
|
3073
|
+
this[key] = factory();
|
|
3074
|
+
}
|
|
3075
|
+
return this[key];
|
|
3076
|
+
}
|
|
3077
|
+
}
|
|
3078
|
+
var DecoratedTreeNode;
|
|
3079
|
+
(function (DecoratedTreeNode) {
|
|
3080
|
+
function createRoot(node) {
|
|
3081
|
+
return Mixin.createProxy(node, new DecoratedTreeNodeMixin(undefined, node));
|
|
3082
|
+
}
|
|
3083
|
+
DecoratedTreeNode.createRoot = createRoot;
|
|
3084
|
+
})(DecoratedTreeNode || (DecoratedTreeNode = {}));
|
|
3085
|
+
|
|
3086
|
+
class TreeExpansionModel {
|
|
3087
|
+
constructor(identityOf) {
|
|
3088
|
+
this.identityOf = identityOf;
|
|
3089
|
+
this.collapsedIds = new Set();
|
|
3090
|
+
this._isExpandedPredicate = new MutableValueModel(() => true);
|
|
3091
|
+
this.updatePredicate();
|
|
3092
|
+
}
|
|
3093
|
+
get isExpandedPredicate() {
|
|
3094
|
+
return this._isExpandedPredicate.readonly;
|
|
3095
|
+
}
|
|
3096
|
+
// @Trace()
|
|
3097
|
+
expand(node) {
|
|
3098
|
+
if (this.isCollapsed(node)) {
|
|
3099
|
+
this.collapsedIds.delete(this.identityOf(node.node));
|
|
3100
|
+
this.updatePredicate();
|
|
3101
|
+
}
|
|
3102
|
+
}
|
|
3103
|
+
// @Trace()
|
|
3104
|
+
collapse(node) {
|
|
3105
|
+
if (!this.isCollapsed(node)) {
|
|
3106
|
+
this.collapsedIds.add(this.identityOf(node.node));
|
|
3107
|
+
this.updatePredicate();
|
|
3108
|
+
}
|
|
3109
|
+
}
|
|
3110
|
+
canExpand(node) {
|
|
3111
|
+
return node.hasChildren() && this.isCollapsed(node);
|
|
3112
|
+
}
|
|
3113
|
+
canCollapse(node) {
|
|
3114
|
+
return node.hasChildren() && !this.isCollapsed(node);
|
|
3115
|
+
}
|
|
3116
|
+
isCollapsed(node) {
|
|
3117
|
+
return this.collapsedIds.has(this.identityOf(node.node));
|
|
3118
|
+
}
|
|
3119
|
+
isExpanded(node) {
|
|
3120
|
+
return !this.isCollapsed(node);
|
|
3121
|
+
}
|
|
3122
|
+
ensureAncestorsAndSelfVisible(node) {
|
|
3123
|
+
node.ancestors()
|
|
3124
|
+
.map(a => this.identityOf(node.node))
|
|
3125
|
+
.forEach(id => this.collapsedIds.delete(id));
|
|
3126
|
+
this.updatePredicate();
|
|
3127
|
+
}
|
|
3128
|
+
updatePredicate() {
|
|
3129
|
+
this._isExpandedPredicate.value = (node) => !this.collapsedIds.has(this.identityOf(node.node));
|
|
3130
|
+
}
|
|
3131
|
+
}
|
|
3132
|
+
|
|
3133
|
+
class TreeLabelColumnModel extends ColumnModel {
|
|
3134
|
+
constructor(columnId, textPropertiesProvider, expansionModel) {
|
|
3135
|
+
super(columnId, textPropertiesProvider);
|
|
3136
|
+
this.expansionModel = expansionModel;
|
|
3137
|
+
this.iconFactory = (node, expanded) => expanded ? 'mat:folder_open' : 'mat:folder';
|
|
3138
|
+
this.cellRenderer(TreeLabelCellRendererComponent);
|
|
3139
|
+
}
|
|
3140
|
+
pluck(property) {
|
|
3141
|
+
this.labelProperty = property;
|
|
3142
|
+
}
|
|
3143
|
+
addIcon(factory) {
|
|
3144
|
+
this.iconFactory = factory;
|
|
3145
|
+
}
|
|
3146
|
+
cellRenderer(componentType) {
|
|
3147
|
+
this.configureCellRenderer(new ComponentCellRendererPortalRef(componentType, (component, rowData, firstTime) => {
|
|
3148
|
+
if (firstTime) {
|
|
3149
|
+
component.expansionModel = this.expansionModel;
|
|
3150
|
+
}
|
|
3151
|
+
component.value = rowData.row;
|
|
3152
|
+
component.label = _.isNil(this.labelProperty) ? undefined : rowData.row[this.labelProperty];
|
|
3153
|
+
component.iconFactory = this.iconFactory;
|
|
3154
|
+
}));
|
|
3155
|
+
return this;
|
|
3156
|
+
}
|
|
3157
|
+
selectRowOnClick(selectOnRowClick) {
|
|
3158
|
+
return super.selectRowOnClick(selectOnRowClick);
|
|
3159
|
+
}
|
|
3160
|
+
}
|
|
3161
|
+
|
|
3162
|
+
class TreeLabelCellRendererComponent extends DisposableComponent {
|
|
3163
|
+
constructor() {
|
|
3164
|
+
super();
|
|
3165
|
+
this.iconTypes = [];
|
|
3166
|
+
this.nodeModel = new MutableValueModel();
|
|
3167
|
+
const { chain } = Dsl.disposeWith(this);
|
|
3168
|
+
this.iconList = chain(this.nodeModel).mapToList(node => {
|
|
3169
|
+
const icons = node.ancestors().slice(1).map(ancestor => {
|
|
3170
|
+
return ancestor.isLastChild() ? TreeInheritanceIconComponent.Type.ICON_BLANK : TreeInheritanceIconComponent.Type.ICON_THROUGH;
|
|
3171
|
+
});
|
|
3172
|
+
if (!node.isRoot()) {
|
|
3173
|
+
icons.push(node.isLastChild() ? TreeInheritanceIconComponent.Type.ICON_INHERITED_TERMINAL : TreeInheritanceIconComponent.Type.ICON_INHERITED_THROUGH_TERMINAL);
|
|
3174
|
+
}
|
|
3175
|
+
return icons;
|
|
3176
|
+
});
|
|
3177
|
+
}
|
|
3178
|
+
ngOnInit() {
|
|
3179
|
+
const { chain } = Dsl.disposeWith(this);
|
|
3180
|
+
this.canExpand = chain(this.nodeModel).map(node => {
|
|
3181
|
+
return node.hasChildren() && this.expansionModel.isCollapsed(node);
|
|
3182
|
+
}, { dependsOn: this.expansionModel.isExpandedPredicate });
|
|
3183
|
+
this.canCollapse = chain(this.nodeModel).map(node => {
|
|
3184
|
+
return node.hasChildren() && !this.expansionModel.isCollapsed(node);
|
|
3185
|
+
}, { dependsOn: this.expansionModel.isExpandedPredicate });
|
|
3186
|
+
this.iconModel = chain(this.nodeModel).map(node => {
|
|
3187
|
+
return this.node.isLeaf() ? undefined : this.iconFactory(node, this.expansionModel.isExpanded(this.node));
|
|
3188
|
+
}, { dependsOn: this.expansionModel.isExpandedPredicate });
|
|
3189
|
+
}
|
|
3190
|
+
get isRoot() {
|
|
3191
|
+
return this.node.isRoot();
|
|
3192
|
+
}
|
|
3193
|
+
get isLeaf() {
|
|
3194
|
+
return this.node.isLeaf();
|
|
3195
|
+
}
|
|
3196
|
+
get node() {
|
|
3197
|
+
return this.nodeModel.value;
|
|
3198
|
+
}
|
|
3199
|
+
// @Trace()
|
|
3200
|
+
expandOrCollapse(node) {
|
|
3201
|
+
this.expansionModel.isCollapsed(node) ? this.expansionModel.expand(node) : this.expansionModel.collapse(node);
|
|
3202
|
+
}
|
|
3203
|
+
}
|
|
3204
|
+
TreeLabelCellRendererComponent.decorators = [
|
|
3205
|
+
{ type: Component, args: [{
|
|
3206
|
+
selector: 'aup-tree-label-cell-renderer',
|
|
3207
|
+
template: "<div class=\"tree-icons\">\n <aup-tree-inheritance-icon *ngFor=\"let iconClass of iconList.value\" [type]=\"iconClass\"></aup-tree-inheritance-icon>\n <aup-icon *ngIf=\"iconModel.value\"\n [icon]=\"iconModel.value\"\n [class.clickable]=\"canExpand.value || canCollapse.value\"\n (click)=\"expandOrCollapse(node)\" ></aup-icon>\n</div>\n<div class=\"label\">{{label}}</div>\n",
|
|
3208
|
+
styles: [":host{--line-color:#ddd;--node-color:#999;align-items:stretch;display:inline-flex;flex-direction:row}:host div.label{align-items:center;display:flex;flex-direction:row;padding-left:6px;white-space:nowrap}:host div.tree-icons{-ms-grid-rows:1fr;align-items:stretch;display:-ms-grid;display:grid;grid-auto-columns:auto;grid-auto-flow:column;grid-template-rows:1fr;justify-content:stretch}:host div.tree-icons aup-icon{-ms-grid-row-align:center;align-self:center;color:var(--node-color)}:host div.tree-icons aup-icon.clickable{cursor:pointer}:host div.tree-icons aup-icon,:host div.tree-icons aup-tree-inheritance-icon{margin-left:4px}"]
|
|
3209
|
+
},] }
|
|
3210
|
+
];
|
|
3211
|
+
TreeLabelCellRendererComponent.ctorParameters = () => [];
|
|
3212
|
+
TreeLabelCellRendererComponent.propDecorators = {
|
|
3213
|
+
value: [{ type: Input }],
|
|
3214
|
+
label: [{ type: Input }],
|
|
3215
|
+
iconFactory: [{ type: Input }],
|
|
3216
|
+
expansionModel: [{ type: Input }],
|
|
3217
|
+
isRoot: [{ type: HostBinding, args: ['class.root',] }],
|
|
3218
|
+
isLeaf: [{ type: HostBinding, args: ['class.leaf',] }]
|
|
3219
|
+
};
|
|
3220
|
+
__decorate([
|
|
3221
|
+
StoreInValueModel('nodeModel'),
|
|
3222
|
+
__metadata("design:type", Object)
|
|
3223
|
+
], TreeLabelCellRendererComponent.prototype, "value", void 0);
|
|
3224
|
+
|
|
3225
|
+
class TreeToListModel extends ComputedListModel {
|
|
3226
|
+
constructor(source, expansionModel) {
|
|
3227
|
+
super(source);
|
|
3228
|
+
this.source = source;
|
|
3229
|
+
this.expansionModel = expansionModel;
|
|
3230
|
+
this.trackSource(this.expansionModel.isExpandedPredicate);
|
|
3231
|
+
}
|
|
3232
|
+
getIdentityOf(item) {
|
|
3233
|
+
return this.source.identityOf(item.node);
|
|
3234
|
+
}
|
|
3235
|
+
compute(values) {
|
|
3236
|
+
const result = [];
|
|
3237
|
+
values.forEach(value => this.addNodeAndVisibleChildren(DecoratedTreeNode.createRoot(value), result));
|
|
3238
|
+
return result;
|
|
3239
|
+
}
|
|
3240
|
+
addNodeAndVisibleChildren(node, result) {
|
|
3241
|
+
result.push(node);
|
|
3242
|
+
if (node.hasChildren() && !this.expansionModel.isCollapsed(node)) {
|
|
3243
|
+
node.children.forEach(child => this.addNodeAndVisibleChildren(child, result));
|
|
3244
|
+
}
|
|
3245
|
+
}
|
|
3246
|
+
}
|
|
3247
|
+
|
|
3248
|
+
// import {T } from '@client/api/light-architect/model/area/area.class';
|
|
3249
|
+
// TODO:
|
|
3250
|
+
// Selection Models:
|
|
3251
|
+
// - as simple navigation tree
|
|
3252
|
+
// - as editable grid (selecte all, even hidden etc?)
|
|
3253
|
+
// - fixing selection on underlying model changes.
|
|
3254
|
+
// - rendering selection: row highlighting, checkboxes (in the tree renderer or in separate column), both.
|
|
3255
|
+
// Expansion Models:
|
|
3256
|
+
// - Add ability to auto show to depth
|
|
3257
|
+
// - Add a predicate to check default expansion (i.e. has children of a certain type)
|
|
3258
|
+
//
|
|
3259
|
+
class TreeTableModel extends AbstractTableModel {
|
|
3260
|
+
constructor(source, treeExpansionModel) {
|
|
3261
|
+
super(source);
|
|
3262
|
+
this.treeExpansionModel = treeExpansionModel;
|
|
3263
|
+
}
|
|
3264
|
+
static fromRoot(sourceOfTruth, builder) {
|
|
3265
|
+
const garbage = new GarbageCollector();
|
|
3266
|
+
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(garbage);
|
|
3267
|
+
const children = chain(sourceOfTruth).mapToList(root => [root]);
|
|
3268
|
+
const model = this.fromList(children, builder);
|
|
3269
|
+
model.registerDisposable(garbage);
|
|
3270
|
+
return model;
|
|
3271
|
+
}
|
|
3272
|
+
static fromChildrenOf(sourceOfTruth, builder) {
|
|
3273
|
+
const garbage = new GarbageCollector();
|
|
3274
|
+
const { chain, valueOf, before, when, after, observe, switchOn } = Dsl.disposeWith(garbage);
|
|
3275
|
+
const children = chain(sourceOfTruth).mapToList(root => root.children); // for some reason pluck list can't see 'children'
|
|
3276
|
+
const model = this.fromList(children, builder);
|
|
3277
|
+
model.registerDisposable(garbage);
|
|
3278
|
+
return model;
|
|
3279
|
+
}
|
|
3280
|
+
static fromList(sourceOfTruth, builder) {
|
|
3281
|
+
const treeExpansionModel = new TreeExpansionModel(sourceOfTruth.identityOf);
|
|
3282
|
+
const nodes = new TreeToListModel(sourceOfTruth, treeExpansionModel);
|
|
3283
|
+
const model = new TreeTableModel(nodes, treeExpansionModel);
|
|
3284
|
+
model.registerDisposable(nodes);
|
|
3285
|
+
if (builder)
|
|
3286
|
+
builder(model);
|
|
3287
|
+
return model;
|
|
3288
|
+
}
|
|
3289
|
+
treeControlColumn(builder) {
|
|
3290
|
+
const columnId = 'tree-label';
|
|
3291
|
+
const column = new TreeLabelColumnModel(columnId, () => this.getColumnTextProperties(columnId), this.treeExpansionModel);
|
|
3292
|
+
builder(column);
|
|
3293
|
+
this.addColumn(column);
|
|
3294
|
+
}
|
|
3295
|
+
expand(node) {
|
|
3296
|
+
this.treeExpansionModel.expand(node);
|
|
3297
|
+
}
|
|
3298
|
+
collapse(node) {
|
|
3299
|
+
this.treeExpansionModel.expand(node);
|
|
3300
|
+
}
|
|
3301
|
+
isCollapsed(node) {
|
|
3302
|
+
return this.treeExpansionModel.isCollapsed(node);
|
|
3303
|
+
}
|
|
3304
|
+
ensureAncestorsAndSelfVisible(node) {
|
|
3305
|
+
this.treeExpansionModel.ensureAncestorsAndSelfVisible(node);
|
|
3306
|
+
}
|
|
3307
|
+
}
|
|
3308
|
+
class FlattenStrategy extends SelfAndDescendantsVisitor {
|
|
3309
|
+
constructor(collapsedIds) {
|
|
3310
|
+
super();
|
|
3311
|
+
this.collapsedIds = collapsedIds;
|
|
3312
|
+
this._areas = [];
|
|
3313
|
+
this._collapsed = new Set(collapsedIds);
|
|
3314
|
+
}
|
|
3315
|
+
onVisit(it) {
|
|
3316
|
+
this._areas.push(it);
|
|
3317
|
+
}
|
|
3318
|
+
shouldVisitChildrenOf(it) {
|
|
3319
|
+
return !this._collapsed.has(it);
|
|
3320
|
+
}
|
|
3321
|
+
get flattenedAreas() {
|
|
3322
|
+
return this._areas;
|
|
3323
|
+
}
|
|
3324
|
+
}
|
|
3325
|
+
// class DecoratorCache {
|
|
3326
|
+
//
|
|
3327
|
+
// private map = new Map<number, T>();
|
|
3328
|
+
//
|
|
3329
|
+
// get(area:T): T {
|
|
3330
|
+
//
|
|
3331
|
+
// if (!area) return null;
|
|
3332
|
+
//
|
|
3333
|
+
// let decoratedArea = this.map.get(area.id);
|
|
3334
|
+
// if (!decoratedArea) {
|
|
3335
|
+
// decoratedArea = TreeModel.AreaDecorator.decorate(area);
|
|
3336
|
+
// this.map.set(area.id, decoratedArea);
|
|
3337
|
+
// }
|
|
3338
|
+
// return decoratedArea;
|
|
3339
|
+
// }
|
|
3340
|
+
//
|
|
3341
|
+
// clear() {
|
|
3342
|
+
// this.map.clear();
|
|
3343
|
+
// }
|
|
3344
|
+
//
|
|
3345
|
+
//
|
|
3346
|
+
// }
|
|
3347
|
+
|
|
3348
|
+
//
|
|
3349
|
+
// const template = `
|
|
3350
|
+
// <table-component list-model="zoneTreeController.visibleAreas"
|
|
3351
|
+
// selection-model="zoneTreeController.selectionModel"
|
|
3352
|
+
// selection-command="zoneTreeController.selectionCommand"
|
|
3353
|
+
// hover-model="zoneTreeController.decoratedHoverModel"
|
|
3354
|
+
// no-hover="zoneTreeController.noHover"
|
|
3355
|
+
// no-lines="true" no-scroll>
|
|
3356
|
+
//
|
|
3357
|
+
// <row-attr name="parent-id" value="{{item.parent.id}}"></row-attr>
|
|
3358
|
+
// <row-attr name="area-id" value="{{item.id}}"></row-attr>
|
|
3359
|
+
// <row-attr name="area-name" value="{{item.name}}"></row-attr>
|
|
3360
|
+
// <row-attr name="area-depth" value="{{item.depthFromZone()}}"></row-attr>
|
|
3361
|
+
// <row-attr name="collapsed" value="{{zoneTreeController.isCollapsed(item)}}"></row-attr>
|
|
3362
|
+
//
|
|
3363
|
+
// <column class="area" ng-class="{root: item.isZone(), parent: item.isGroup()}" class="allow-squish">
|
|
3364
|
+
// <!--<label>Rooms in {{zoneTreeController.zoneModel.value.name}}</label>-->
|
|
3365
|
+
// <label>Rooms</label>
|
|
3366
|
+
// <div layout="row" layout-align="start center">
|
|
3367
|
+
// <tree-icons tree-item="item"></tree-icons>
|
|
3368
|
+
// <area-icon area="item"></area-icon>
|
|
3369
|
+
// <span ng-if="item.isZone()">Zone ({{item.name}})</span>
|
|
3370
|
+
// <span ng-if="!item.isZone()">{{item.name}}</span>
|
|
3371
|
+
// </div>
|
|
3372
|
+
// </column>
|
|
3373
|
+
// <column class="expand-collapse" ng-class="{collapsed: zoneTreeController.isCollapsed(item)}">
|
|
3374
|
+
// <md-button class="md-icon-button"
|
|
3375
|
+
// ng-if="zoneTreeController.canCollapse(item)"
|
|
3376
|
+
// ng-click="zoneTreeController.toggleCollapse(item)">
|
|
3377
|
+
// <md-icon>keyboard_arrow_up</md-icon>
|
|
3378
|
+
// </md-button>
|
|
3379
|
+
// </column>
|
|
3380
|
+
//
|
|
3381
|
+
// </table-component>
|
|
3382
|
+
// `;
|
|
3383
|
+
class TreeTableComponent extends DisposableComponent {
|
|
3384
|
+
constructor() {
|
|
3385
|
+
super();
|
|
3386
|
+
}
|
|
3387
|
+
}
|
|
3388
|
+
TreeTableComponent.decorators = [
|
|
3389
|
+
{ type: Component, args: [{
|
|
3390
|
+
selector: "aup-tree-table",
|
|
3391
|
+
template: "<aup-table [tableModel]=\"treeTableModel\"></aup-table>\n",
|
|
3392
|
+
encapsulation: ViewEncapsulation.None // allow us to target nested table styles
|
|
3393
|
+
,
|
|
3394
|
+
styles: ["td.mat-cell{border-bottom-width:0!important;border-top-width:0!important}td.mat-column-tree-label{width:1px}aup-table-cell-renderer[column-id=tree-label]{padding-left:8px!important}aup-tree-label-cell-renderer{flex:1}"]
|
|
3395
|
+
},] }
|
|
3396
|
+
];
|
|
3397
|
+
TreeTableComponent.ctorParameters = () => [];
|
|
3398
|
+
TreeTableComponent.propDecorators = {
|
|
3399
|
+
treeTableModel: [{ type: Input }]
|
|
3400
|
+
};
|
|
3401
|
+
__decorate([
|
|
3402
|
+
TrackExternal(),
|
|
3403
|
+
__metadata("design:type", TreeTableModel)
|
|
3404
|
+
], TreeTableComponent.prototype, "treeTableModel", void 0);
|
|
3405
|
+
|
|
2818
3406
|
class VerticalFocusContainerComponent extends FocusContainerComponent {
|
|
2819
3407
|
constructor(focusManager) {
|
|
2820
3408
|
super(focusManager);
|
|
@@ -2925,7 +3513,11 @@ ComponentsModule.decorators = [
|
|
|
2925
3513
|
SeparatorComponent,
|
|
2926
3514
|
FlexComponent,
|
|
2927
3515
|
AbstractPopupMenuComponent,
|
|
2928
|
-
PopupMenuRendererComponent
|
|
3516
|
+
PopupMenuRendererComponent,
|
|
3517
|
+
TreeTableComponent,
|
|
3518
|
+
TreeInheritanceIconComponent,
|
|
3519
|
+
TreeLabelCellRendererComponent,
|
|
3520
|
+
IconComponent
|
|
2929
3521
|
],
|
|
2930
3522
|
imports: [
|
|
2931
3523
|
CommonModule,
|
|
@@ -2978,7 +3570,8 @@ ComponentsModule.decorators = [
|
|
|
2978
3570
|
CommandFaceComponent,
|
|
2979
3571
|
MoreMenuComponent,
|
|
2980
3572
|
SeparatorComponent,
|
|
2981
|
-
FlexComponent
|
|
3573
|
+
FlexComponent,
|
|
3574
|
+
TreeTableComponent
|
|
2982
3575
|
],
|
|
2983
3576
|
providers: [
|
|
2984
3577
|
FocusBindingFactory
|
|
@@ -6763,7 +7356,7 @@ class VisitSanitiser {
|
|
|
6763
7356
|
const routeIdDef = placeDef.getRouteIdParameterDef();
|
|
6764
7357
|
const routeId = visit.getRouteId();
|
|
6765
7358
|
const sanitisedValue = yield routeIdDef.sanitise(routeId, visit, this.placeHistory, this.injector, this.navigationSession.isPopState);
|
|
6766
|
-
console.log({
|
|
7359
|
+
// console.log({routeId, sanitisedValue});
|
|
6767
7360
|
// ###------- EARLY EXIT --------###
|
|
6768
7361
|
if (routeIdDef.hasChanged(routeId, sanitisedValue)) {
|
|
6769
7362
|
// if the route id has changed we redirect immediately as other
|
|
@@ -7016,5 +7609,5 @@ function VisitParameterList(options) {
|
|
|
7016
7609
|
* Generated bundle index. Do not edit.
|
|
7017
7610
|
*/
|
|
7018
7611
|
|
|
7019
|
-
export { ACTIVITY_DATA, AUP_PLACE_CONFIG, AbstractInputActivity, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityContainerComponent, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddItemInteractionContextComponent, AlertDialogComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CellEditorPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnModel, ColumnTemplateDirective, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, ConfirmThenDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControls, EditSession, EditorControlColumnModel, EmptyStateComponent, EventCleanUpSession, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, Formatter, HEADER_CELL_RENDERER_PORTAL, IconComponent, InPlaceInteractionContextComponent, InteractionContextTriggerFor, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, LEFT_RIGHT_PLACE_ANIMATION, ListPlaceNavComponent, ListPropertyColumnModel, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, ParameterDefinition, PasswordInputComponent, Place, PlaceAccessGuard, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, RouteId, ScrollContainerComponent, SectionHeaderComponent, SelectCellRendererComponent, SelectHeaderCellRendererComponent, SelectInputActivity, SelectInputComponent, SelectionColumnModel, SeparatorComponent, SidePlaceNavigationComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableCellRendererComponent, TableComponent, TableHeaderCellRendererComponent, TableModel, TableRowMenuComponent, TemplateCellRendererPortalRef, TextInputComponent, ToolBarComponent, TrackBy, UrlService, UrlSnapshot, VerticalFocusContainerComponent, Visit, VisitParameter, VisitParameterList, VisitSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, slideDownOnEnterAnimation, slideRightOnEnterAnimation, ɵ0 };
|
|
7612
|
+
export { ACTIVITY_DATA, AUP_PLACE_CONFIG, AbstractInputActivity, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityContainerComponent, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddItemInteractionContextComponent, AlertDialogComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CellEditorPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnModel, ColumnTemplateDirective, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, ConfirmThenDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControls, EditSession, EditorControlColumnModel, EmptyStateComponent, EventCleanUpSession, FlattenStrategy, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, Formatter, HEADER_CELL_RENDERER_PORTAL, IconComponent, InPlaceInteractionContextComponent, InteractionContextTriggerFor, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, LEFT_RIGHT_PLACE_ANIMATION, ListPlaceNavComponent, ListPropertyColumnModel, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, ParameterDefinition, PasswordInputComponent, Place, PlaceAccessGuard, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, RouteId, ScrollContainerComponent, SectionHeaderComponent, SelectCellRendererComponent, SelectHeaderCellRendererComponent, SelectInputActivity, SelectInputComponent, SelectionColumnModel, SelfAndDescendantsVisitor, SeparatorComponent, SidePlaceNavigationComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableCellRendererComponent, TableComponent, TableHeaderCellRendererComponent, TableModel, TableRowMenuComponent, TemplateCellRendererPortalRef, TextInputComponent, ToolBarComponent, TrackBy, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, TreeToListModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, Visit, VisitParameter, VisitParameterList, VisitSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, slideDownOnEnterAnimation, slideRightOnEnterAnimation, ɵ0 };
|
|
7020
7613
|
//# sourceMappingURL=coolon-angular-ui-powerups.js.map
|