@rxap/tree 12.3.2 → 12.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
1
  (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('rxjs'), require('@angular/cdk/tree'), require('@angular/cdk/collections'), require('rxjs/operators'), require('@rxap/data-source'), require('@rxap/utilities'), require('@angular/core'), require('@rxap/utilities/rxjs'), require('@angular/cdk/portal'), require('@angular/material/tree'), require('@angular/material/icon'), require('@angular/material/checkbox'), require('@angular/material/button'), require('@angular/material/progress-spinner'), require('@angular/material/divider'), require('@angular/flex-layout/flex'), require('@angular/common'), require('@angular/flex-layout/extended'), require('@rxap/material-directives/icon'), require('@rxap/contenteditable'), require('@angular/flex-layout')) :
3
- typeof define === 'function' && define.amd ? define('@rxap/tree', ['exports', 'rxjs', '@angular/cdk/tree', '@angular/cdk/collections', 'rxjs/operators', '@rxap/data-source', '@rxap/utilities', '@angular/core', '@rxap/utilities/rxjs', '@angular/cdk/portal', '@angular/material/tree', '@angular/material/icon', '@angular/material/checkbox', '@angular/material/button', '@angular/material/progress-spinner', '@angular/material/divider', '@angular/flex-layout/flex', '@angular/common', '@angular/flex-layout/extended', '@rxap/material-directives/icon', '@rxap/contenteditable', '@angular/flex-layout'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.rxap = global.rxap || {}, global.rxap.tree = {}), global.rxjs, global.ng.cdk.tree, global.ng.cdk.collections, global.rxjs.operators, global.dataSource, global.utilities, global.ng.core, global.rxjs$1, global.ng.cdk.portal, global.ng.material.tree, global.ng.material.icon, global.ng.material.checkbox, global.ng.material.button, global.ng.material.progressSpinner, global.ng.material.divider, global.ng.flexLayout.flex, global.ng.common, global.ng.flexLayout.extended, global.i10, global.i11, global.ng.flexLayout));
5
- }(this, (function (exports, rxjs, tree, collections, operators, dataSource, utilities, i0, rxjs$1, i12, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, flexLayout) { 'use strict';
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('rxjs'), require('@angular/cdk/tree'), require('@angular/cdk/collections'), require('rxjs/operators'), require('@rxap/data-source'), require('@rxap/utilities'), require('@angular/core'), require('@rxap/utilities/rxjs'), require('@angular/cdk/portal'), require('@angular/material/progress-bar'), require('@angular/material/tree'), require('@angular/material/icon'), require('@angular/material/checkbox'), require('@angular/material/button'), require('@angular/material/progress-spinner'), require('@angular/material/divider'), require('@angular/flex-layout/flex'), require('@angular/common'), require('@angular/flex-layout/extended'), require('@rxap/material-directives/icon'), require('@rxap/contenteditable'), require('@angular/flex-layout')) :
3
+ typeof define === 'function' && define.amd ? define('@rxap/tree', ['exports', 'rxjs', '@angular/cdk/tree', '@angular/cdk/collections', 'rxjs/operators', '@rxap/data-source', '@rxap/utilities', '@angular/core', '@rxap/utilities/rxjs', '@angular/cdk/portal', '@angular/material/progress-bar', '@angular/material/tree', '@angular/material/icon', '@angular/material/checkbox', '@angular/material/button', '@angular/material/progress-spinner', '@angular/material/divider', '@angular/flex-layout/flex', '@angular/common', '@angular/flex-layout/extended', '@rxap/material-directives/icon', '@rxap/contenteditable', '@angular/flex-layout'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.rxap = global.rxap || {}, global.rxap.tree = {}), global.rxjs, global.ng.cdk.tree, global.ng.cdk.collections, global.rxjs.operators, global.dataSource, global.utilities, global.ng.core, global.rxjs$1, global.ng.cdk.portal, global.ng.material.progressBar, global.ng.material.tree, global.ng.material.icon, global.ng.material.checkbox, global.ng.material.button, global.ng.material.progressSpinner, global.ng.material.divider, global.ng.flexLayout.flex, global.ng.common, global.ng.flexLayout.extended, global.i11, global.i12, global.ng.flexLayout));
5
+ })(this, (function (exports, rxjs, tree, collections, operators, dataSource, utilities, i0, rxjs$1, i13, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12, flexLayout) { 'use strict';
6
6
 
7
7
  function _interopNamespace(e) {
8
8
  if (e && e.__esModule) return e;
@@ -13,19 +13,17 @@
13
13
  var d = Object.getOwnPropertyDescriptor(e, k);
14
14
  Object.defineProperty(n, k, d.get ? d : {
15
15
  enumerable: true,
16
- get: function () {
17
- return e[k];
18
- }
16
+ get: function () { return e[k]; }
19
17
  });
20
18
  }
21
19
  });
22
20
  }
23
- n['default'] = e;
21
+ n["default"] = e;
24
22
  return Object.freeze(n);
25
23
  }
26
24
 
27
25
  var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
28
- var i12__namespace = /*#__PURE__*/_interopNamespace(i12);
26
+ var i13__namespace = /*#__PURE__*/_interopNamespace(i13);
29
27
  var i1__namespace = /*#__PURE__*/_interopNamespace(i1);
30
28
  var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
31
29
  var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
@@ -37,6 +35,7 @@
37
35
  var i9__namespace = /*#__PURE__*/_interopNamespace(i9);
38
36
  var i10__namespace = /*#__PURE__*/_interopNamespace(i10);
39
37
  var i11__namespace = /*#__PURE__*/_interopNamespace(i11);
38
+ var i12__namespace = /*#__PURE__*/_interopNamespace(i12);
40
39
 
41
40
  /*! *****************************************************************************
42
41
  Copyright (c) Microsoft Corporation.
@@ -586,7 +585,9 @@
586
585
  }
587
586
  var flatTree = function (node) {
588
587
  if (!Array.isArray(node.children)) {
589
- console.log(node);
588
+ if (i0.isDevMode()) {
589
+ console.log(node);
590
+ }
590
591
  throw new Error('Node has not defined children');
591
592
  }
592
593
  if (node.expanded || _this.expanded.isSelected(node.id)) {
@@ -782,13 +783,13 @@
782
783
  };
783
784
  return TreeDataSource;
784
785
  }(dataSource.BaseDataSource));
785
- TreeDataSource.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeDataSource, deps: [{ token: RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD }, { token: RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD }, { token: dataSource.RXAP_DATA_SOURCE_METADATA }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
786
- TreeDataSource.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeDataSource });
786
+ TreeDataSource.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeDataSource, deps: [{ token: RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD }, { token: RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD }, { token: dataSource.RXAP_DATA_SOURCE_METADATA }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
787
+ TreeDataSource.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeDataSource });
787
788
  __decorate([
788
789
  utilities.Required,
789
790
  __metadata("design:type", tree.FlatTreeControl)
790
791
  ], TreeDataSource.prototype, "treeControl", void 0);
791
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeDataSource, decorators: [{
792
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeDataSource, decorators: [{
792
793
  type: i0.Injectable
793
794
  }], ctorParameters: function () {
794
795
  return [{ type: undefined, decorators: [{
@@ -809,9 +810,9 @@
809
810
  }
810
811
  return TreeContentDirective;
811
812
  }());
812
- TreeContentDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeContentDirective, deps: [{ token: i0.TemplateRef }], target: i0__namespace.ɵɵFactoryTarget.Directive });
813
- TreeContentDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.0.1", type: TreeContentDirective, selector: "ng-template[rxapTreeContent]", ngImport: i0__namespace });
814
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeContentDirective, decorators: [{
813
+ TreeContentDirective.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeContentDirective, deps: [{ token: i0.TemplateRef }], target: i0__namespace.ɵɵFactoryTarget.Directive });
814
+ TreeContentDirective.ɵdir = i0__namespace.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: TreeContentDirective, selector: "ng-template[rxapTreeContent]", ngImport: i0__namespace });
815
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeContentDirective, decorators: [{
815
816
  type: i0.Directive,
816
817
  args: [{
817
818
  // tslint:disable-next-line:directive-selector
@@ -860,6 +861,13 @@
860
861
  enumerable: false,
861
862
  configurable: true
862
863
  });
864
+ Object.defineProperty(TreeComponent.prototype, "cacheId", {
865
+ get: function () {
866
+ return ['rxap', 'tree', this.id].join('/');
867
+ },
868
+ enumerable: false,
869
+ configurable: true
870
+ });
863
871
  TreeComponent.prototype.ngOnInit = function () {
864
872
  var _this = this;
865
873
  var _a;
@@ -871,6 +879,10 @@
871
879
  if (this.dataSource.selected.hasValue()) {
872
880
  this.dataSource.selected.selected.forEach(function (node) { return _this.openDetails(node); });
873
881
  }
882
+ var cachedOffset = localStorage.getItem(this.cacheId);
883
+ if (cachedOffset && cachedOffset.match(/^(\d+\.)?\d+px$/)) {
884
+ this.setDividerOffset(cachedOffset);
885
+ }
874
886
  };
875
887
  TreeComponent.prototype.ngAfterContentInit = function () {
876
888
  var _this = this;
@@ -880,7 +892,7 @@
880
892
  };
881
893
  TreeComponent.prototype.openDetails = function (node) {
882
894
  if (this.content) {
883
- this.portal = new i12.TemplatePortal(this.content.template, this.viewContainerRef, {
895
+ this.portal = new i13.TemplatePortal(this.content.template, this.viewContainerRef, {
884
896
  $implicit: node.item,
885
897
  node: node,
886
898
  });
@@ -904,16 +916,20 @@
904
916
  this._treeContainerWidth = this.treeContainer.nativeElement.clientWidth;
905
917
  }
906
918
  this._treeContainerWidth = $event.clientX - 75;
907
- var width = this._treeContainerWidth + 'px';
908
- this.renderer.setStyle(this.treeContainer.nativeElement, 'max-width', width);
909
- this.renderer.setStyle(this.treeContainer.nativeElement, 'min-width', width);
910
- this.renderer.setStyle(this.treeContainer.nativeElement, 'flex-basis', width);
919
+ var offset = this._treeContainerWidth + 'px';
920
+ this.setDividerOffset(offset);
911
921
  }
912
922
  };
923
+ TreeComponent.prototype.setDividerOffset = function (offset) {
924
+ this.renderer.setStyle(this.treeContainer.nativeElement, 'max-width', offset);
925
+ this.renderer.setStyle(this.treeContainer.nativeElement, 'min-width', offset);
926
+ this.renderer.setStyle(this.treeContainer.nativeElement, 'flex-basis', offset);
927
+ localStorage.setItem(this.cacheId, offset);
928
+ };
913
929
  return TreeComponent;
914
930
  }());
915
- TreeComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeComponent, deps: [{ token: i0.ViewContainerRef }, { token: i0.ChangeDetectorRef }, { token: RXAP_TREE_CONTENT_EDITABLE_METHOD, optional: true }, { token: i0__namespace.Renderer2 }], target: i0__namespace.ɵɵFactoryTarget.Component });
916
- TreeComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.1", type: TreeComponent, selector: "rxap-tree", inputs: { dataSource: "dataSource", contentEditableMethod: "contentEditableMethod", toDisplay: "toDisplay", getIcon: "getIcon", multiple: "multiple", hasDetails: "hasDetails", hideLeafIcon: "hideLeafIcon" }, outputs: { details: "details" }, host: { listeners: { "mouseup": "onMouseup()", "mousemove": "onMousemove($event)" } }, queries: [{ propertyName: "content", first: true, predicate: TreeContentDirective, descendants: true, static: true }], viewQueries: [{ propertyName: "treeContainer", first: true, predicate: ["treeContainer"], descendants: true, static: true }], ngImport: i0__namespace, template: "<div class=\"container\" fxLayout=\"row\">\n <div #treeContainer class=\"tree-container\" fxFlex=\"nogrow\">\n <mat-tree *ngIf=\"dataSource; else loading\" [dataSource]=\"dataSource\" [treeControl]=\"treeControl\" class=\"tree-view\">\n\n <!-- Node without children -->\n <mat-tree-node *matTreeNodeDef=\"let node\" matTreeNodePadding>\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <mat-icon [fxHide]=\"hideLeafIcon\" fxFlex=\"40px\">subdirectory_arrow_right</mat-icon>\n <mat-icon *ngIf=\"node.icon\" [rxapIcon]=\"node.icon\" fxFlex=\"40px\"></mat-icon>\n <ng-template [ngIf]=\"multiple\">\n <mat-checkbox (change)=\"node.toggleSelect()\" [checked]=\"node.selected\" [disabled]=\"!node.hasDetails\" fxFlex=\"nogrow\">{{ node.display }}</mat-checkbox>\n </ng-template>\n <ng-template [ngIf]=\"!multiple\">\n <button\n (click)=\"node.select()\"\n [color]=\"node.selected ? 'primary' : null\"\n [disabled]=\"!node.hasDetails\"\n fxFlex=\"nogrow\"\n mat-button\n >\n {{ node.display }}\n </button>\n </ng-template>\n </div>\n </mat-tree-node>\n\n <!-- Node with children -->\n <mat-tree-node *matTreeNodeDef=\"let node; when: hasChild\" matTreeNodePadding>\n <button [attr.aria-label]=\"'toggle ' + node.filename\" mat-icon-button matTreeNodeToggle>\n <mat-icon class=\"mat-icon-rtl-mirror\">\n {{ treeControl.isExpanded(node) ? 'expand_more' : 'chevron_right' }}\n </mat-icon>\n </button>\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <mat-icon *ngIf=\"node.icon; else withoutIcon\" [rxapIcon]=\"node.icon\" fxFlex=\"40px\"></mat-icon>\n <ng-template #withoutIcon>\n <div fxFlex=\"0\"></div>\n </ng-template>\n <ng-template [ngIfElse]=\"withoutDetails\" [ngIf]=\"node.hasDetails\">\n <button\n (click)=\"node.select()\"\n [color]=\"node.selected ? 'primary' : null\"\n fxFlex=\"nogrow\"\n mat-button\n >\n {{ node.display }}\n </button>\n </ng-template>\n <ng-template #withoutDetails>\n <span\n (change)=\"onContentEditableChange($event, node)\"\n [disabled]=\"!nodeDisplayEditable\"\n fxFlex=\"nogrow\"\n rxapContenteditable>\n {{ node.display }}\n </span>\n </ng-template>\n <mat-progress-spinner\n *ngIf=\"node.isLoading$ | async\"\n [diameter]=\"16\"\n fxFlex=\"nogrow\"\n fxFlexOffset=\"16px\"\n mode=\"indeterminate\"\n ></mat-progress-spinner>\n </div>\n </mat-tree-node>\n\n </mat-tree>\n </div>\n\n <div (mousedown)=\"onMousedown()\"\n class=\"divider\"\n fxFlex=\"nogrow\">\n <mat-divider\n [vertical]=\"true\"\n >\n </mat-divider>\n </div>\n\n <div class=\"details\" fxFlex=\"grow\">\n <ng-template [cdkPortalOutlet]=\"portal\"></ng-template>\n <ng-content></ng-content>\n </div>\n</div>\n\n<ng-template #loading>Load data source</ng-template>\n", styles: [".container{height:100%}.tree-view{background-color:transparent;background-color:initial}.details,.tree-container{max-height:calc(100vh - 64px - 32px);overflow-y:auto}.tree-container{min-width:-webkit-fit-content;min-width:-moz-fit-content;min-width:fit-content}.divider{cursor:ew-resize;padding:12px}.divider ::ng-deep .mat-divider{height:100%}"], components: [{ type: i1__namespace.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { type: i2__namespace.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i3__namespace.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "id", "labelPosition", "name", "required", "checked", "disabled", "indeterminate", "aria-describedby", "value"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { type: i4__namespace.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i5__namespace.MatProgressSpinner, selector: "mat-progress-spinner", inputs: ["color", "mode", "diameter", "strokeWidth", "value"], exportAs: ["matProgressSpinner"] }, { type: i6__namespace.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }], directives: [{ type: i7__namespace.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { type: i7__namespace.DefaultFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg]", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }, { type: i8__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1__namespace.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { type: i1__namespace.MatTreeNode, selector: "mat-tree-node", inputs: ["role", "disabled", "tabIndex"], exportAs: ["matTreeNode"] }, { type: i1__namespace.MatTreeNodePadding, selector: "[matTreeNodePadding]", inputs: ["matTreeNodePadding", "matTreeNodePaddingIndent"] }, { type: i7__namespace.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { type: i9__namespace.DefaultShowHideDirective, selector: " [fxShow], [fxShow.print], [fxShow.xs], [fxShow.sm], [fxShow.md], [fxShow.lg], [fxShow.xl], [fxShow.lt-sm], [fxShow.lt-md], [fxShow.lt-lg], [fxShow.lt-xl], [fxShow.gt-xs], [fxShow.gt-sm], [fxShow.gt-md], [fxShow.gt-lg], [fxHide], [fxHide.print], [fxHide.xs], [fxHide.sm], [fxHide.md], [fxHide.lg], [fxHide.xl], [fxHide.lt-sm], [fxHide.lt-md], [fxHide.lt-lg], [fxHide.lt-xl], [fxHide.gt-xs], [fxHide.gt-sm], [fxHide.gt-md], [fxHide.gt-lg]", inputs: ["fxShow", "fxShow.print", "fxShow.xs", "fxShow.sm", "fxShow.md", "fxShow.lg", "fxShow.xl", "fxShow.lt-sm", "fxShow.lt-md", "fxShow.lt-lg", "fxShow.lt-xl", "fxShow.gt-xs", "fxShow.gt-sm", "fxShow.gt-md", "fxShow.gt-lg", "fxHide", "fxHide.print", "fxHide.xs", "fxHide.sm", "fxHide.md", "fxHide.lg", "fxHide.xl", "fxHide.lt-sm", "fxHide.lt-md", "fxHide.lt-lg", "fxHide.lt-xl", "fxHide.gt-xs", "fxHide.gt-sm", "fxHide.gt-md", "fxHide.gt-lg"] }, { type: i10__namespace.IconDirective, selector: "mat-icon[rxapIcon]", inputs: ["rxapIcon"] }, { type: i1__namespace.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { type: i11__namespace.ContenteditableDirective, selector: "[rxapContenteditable]", inputs: ["rxapContenteditable", "disabled"], outputs: ["change"] }, { type: i7__namespace.DefaultFlexOffsetDirective, selector: " [fxFlexOffset], [fxFlexOffset.xs], [fxFlexOffset.sm], [fxFlexOffset.md], [fxFlexOffset.lg], [fxFlexOffset.xl], [fxFlexOffset.lt-sm], [fxFlexOffset.lt-md], [fxFlexOffset.lt-lg], [fxFlexOffset.lt-xl], [fxFlexOffset.gt-xs], [fxFlexOffset.gt-sm], [fxFlexOffset.gt-md], [fxFlexOffset.gt-lg]", inputs: ["fxFlexOffset", "fxFlexOffset.xs", "fxFlexOffset.sm", "fxFlexOffset.md", "fxFlexOffset.lg", "fxFlexOffset.xl", "fxFlexOffset.lt-sm", "fxFlexOffset.lt-md", "fxFlexOffset.lt-lg", "fxFlexOffset.lt-xl", "fxFlexOffset.gt-xs", "fxFlexOffset.gt-sm", "fxFlexOffset.gt-md", "fxFlexOffset.gt-lg"] }, { type: i12__namespace.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], pipes: { "async": i8__namespace.AsyncPipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
931
+ TreeComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeComponent, deps: [{ token: i0.ViewContainerRef }, { token: i0.ChangeDetectorRef }, { token: RXAP_TREE_CONTENT_EDITABLE_METHOD, optional: true }, { token: i0__namespace.Renderer2 }], target: i0__namespace.ɵɵFactoryTarget.Component });
932
+ TreeComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: TreeComponent, selector: "rxap-tree", inputs: { dataSource: "dataSource", contentEditableMethod: "contentEditableMethod", toDisplay: "toDisplay", getIcon: "getIcon", multiple: "multiple", hasDetails: "hasDetails", hideLeafIcon: "hideLeafIcon", id: "id" }, outputs: { details: "details" }, host: { listeners: { "mouseup": "onMouseup()", "mousemove": "onMousemove($event)" } }, queries: [{ propertyName: "content", first: true, predicate: TreeContentDirective, descendants: true, static: true }], viewQueries: [{ propertyName: "treeContainer", first: true, predicate: ["treeContainer"], descendants: true, static: true }], ngImport: i0__namespace, template: "<div class=\"container\" fxLayout=\"row\">\n <div #treeContainer class=\"tree-container\" fxFlex=\"nogrow\">\n <mat-progress-bar *ngIf=\"!dataSource || (dataSource.loading$ | async)\" mode=\"indeterminate\"></mat-progress-bar>\n <mat-tree *ngIf=\"dataSource; else loading\" [dataSource]=\"dataSource\" [treeControl]=\"treeControl\" class=\"tree-view\">\n\n <!-- Node without children -->\n <mat-tree-node *matTreeNodeDef=\"let node\" matTreeNodePadding>\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <mat-icon [fxHide]=\"hideLeafIcon\" fxFlex=\"40px\">subdirectory_arrow_right</mat-icon>\n <mat-icon *ngIf=\"node.icon\" [rxapIcon]=\"node.icon\" fxFlex=\"40px\"></mat-icon>\n <ng-template [ngIf]=\"multiple\">\n <mat-checkbox (change)=\"node.toggleSelect()\" [checked]=\"node.selected\" [disabled]=\"!node.hasDetails\" fxFlex=\"nogrow\">{{ node.display }}</mat-checkbox>\n </ng-template>\n <ng-template [ngIf]=\"!multiple\">\n <button\n (click)=\"node.select()\"\n [color]=\"node.selected ? 'primary' : null\"\n [disabled]=\"!node.hasDetails\"\n fxFlex=\"nogrow\"\n mat-button\n >\n {{ node.display }}\n </button>\n </ng-template>\n </div>\n </mat-tree-node>\n\n <!-- Node with children -->\n <mat-tree-node *matTreeNodeDef=\"let node; when: hasChild\" matTreeNodePadding>\n <button [attr.aria-label]=\"'toggle ' + node.filename\" mat-icon-button matTreeNodeToggle>\n <mat-icon class=\"mat-icon-rtl-mirror\">\n {{ treeControl.isExpanded(node) ? 'expand_more' : 'chevron_right' }}\n </mat-icon>\n </button>\n <div fxLayout=\"row\" fxLayoutAlign=\"start center\">\n <mat-icon *ngIf=\"node.icon; else withoutIcon\" [rxapIcon]=\"node.icon\" fxFlex=\"40px\"></mat-icon>\n <ng-template #withoutIcon>\n <div fxFlex=\"0\"></div>\n </ng-template>\n <ng-template [ngIfElse]=\"withoutDetails\" [ngIf]=\"node.hasDetails\">\n <button\n (click)=\"node.select()\"\n [color]=\"node.selected ? 'primary' : null\"\n fxFlex=\"nogrow\"\n mat-button\n >\n {{ node.display }}\n </button>\n </ng-template>\n <ng-template #withoutDetails>\n <span\n (change)=\"onContentEditableChange($event, node)\"\n [disabled]=\"!nodeDisplayEditable\"\n fxFlex=\"nogrow\"\n rxapContenteditable>\n {{ node.display }}\n </span>\n </ng-template>\n <mat-progress-spinner\n *ngIf=\"node.isLoading$ | async\"\n [diameter]=\"16\"\n fxFlex=\"nogrow\"\n fxFlexOffset=\"16px\"\n mode=\"indeterminate\"\n ></mat-progress-spinner>\n </div>\n </mat-tree-node>\n\n </mat-tree>\n </div>\n\n <div (mousedown)=\"onMousedown()\"\n class=\"divider\"\n fxFlex=\"nogrow\">\n <mat-divider\n [vertical]=\"true\"\n >\n </mat-divider>\n </div>\n\n <div class=\"details\" fxFlex=\"grow\">\n <ng-template [cdkPortalOutlet]=\"portal\"></ng-template>\n <ng-content></ng-content>\n </div>\n</div>\n\n<ng-template #loading>Load data source</ng-template>\n", styles: [".container{height:100%}.tree-view{background-color:transparent;background-color:initial}.details,.tree-container{max-height:calc(100vh - 64px - 32px);overflow-y:auto}.tree-container{min-width:256px;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}.divider{cursor:ew-resize;padding:12px}.divider ::ng-deep .mat-divider{height:100%}"], components: [{ type: i1__namespace.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "mode", "value", "bufferValue"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { type: i2__namespace.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { type: i3__namespace.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i4__namespace.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "id", "labelPosition", "name", "required", "checked", "disabled", "indeterminate", "aria-describedby", "value"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { type: i5__namespace.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i6__namespace.MatProgressSpinner, selector: "mat-progress-spinner", inputs: ["color", "mode", "diameter", "strokeWidth", "value"], exportAs: ["matProgressSpinner"] }, { type: i7__namespace.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }], directives: [{ type: i8__namespace.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { type: i8__namespace.DefaultFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg]", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }, { type: i9__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { type: i2__namespace.MatTreeNode, selector: "mat-tree-node", inputs: ["role", "disabled", "tabIndex"], exportAs: ["matTreeNode"] }, { type: i2__namespace.MatTreeNodePadding, selector: "[matTreeNodePadding]", inputs: ["matTreeNodePadding", "matTreeNodePaddingIndent"] }, { type: i8__namespace.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { type: i10__namespace.DefaultShowHideDirective, selector: " [fxShow], [fxShow.print], [fxShow.xs], [fxShow.sm], [fxShow.md], [fxShow.lg], [fxShow.xl], [fxShow.lt-sm], [fxShow.lt-md], [fxShow.lt-lg], [fxShow.lt-xl], [fxShow.gt-xs], [fxShow.gt-sm], [fxShow.gt-md], [fxShow.gt-lg], [fxHide], [fxHide.print], [fxHide.xs], [fxHide.sm], [fxHide.md], [fxHide.lg], [fxHide.xl], [fxHide.lt-sm], [fxHide.lt-md], [fxHide.lt-lg], [fxHide.lt-xl], [fxHide.gt-xs], [fxHide.gt-sm], [fxHide.gt-md], [fxHide.gt-lg]", inputs: ["fxShow", "fxShow.print", "fxShow.xs", "fxShow.sm", "fxShow.md", "fxShow.lg", "fxShow.xl", "fxShow.lt-sm", "fxShow.lt-md", "fxShow.lt-lg", "fxShow.lt-xl", "fxShow.gt-xs", "fxShow.gt-sm", "fxShow.gt-md", "fxShow.gt-lg", "fxHide", "fxHide.print", "fxHide.xs", "fxHide.sm", "fxHide.md", "fxHide.lg", "fxHide.xl", "fxHide.lt-sm", "fxHide.lt-md", "fxHide.lt-lg", "fxHide.lt-xl", "fxHide.gt-xs", "fxHide.gt-sm", "fxHide.gt-md", "fxHide.gt-lg"] }, { type: i11__namespace.IconDirective, selector: "mat-icon[rxapIcon]", inputs: ["rxapIcon"] }, { type: i2__namespace.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { type: i12__namespace.ContenteditableDirective, selector: "[rxapContenteditable]", inputs: ["rxapContenteditable", "disabled"], outputs: ["change"] }, { type: i8__namespace.DefaultFlexOffsetDirective, selector: " [fxFlexOffset], [fxFlexOffset.xs], [fxFlexOffset.sm], [fxFlexOffset.md], [fxFlexOffset.lg], [fxFlexOffset.xl], [fxFlexOffset.lt-sm], [fxFlexOffset.lt-md], [fxFlexOffset.lt-lg], [fxFlexOffset.lt-xl], [fxFlexOffset.gt-xs], [fxFlexOffset.gt-sm], [fxFlexOffset.gt-md], [fxFlexOffset.gt-lg]", inputs: ["fxFlexOffset", "fxFlexOffset.xs", "fxFlexOffset.sm", "fxFlexOffset.md", "fxFlexOffset.lg", "fxFlexOffset.xl", "fxFlexOffset.lt-sm", "fxFlexOffset.lt-md", "fxFlexOffset.lt-lg", "fxFlexOffset.lt-xl", "fxFlexOffset.gt-xs", "fxFlexOffset.gt-sm", "fxFlexOffset.gt-md", "fxFlexOffset.gt-lg"] }, { type: i13__namespace.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], pipes: { "async": i9__namespace.AsyncPipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
917
933
  __decorate([
918
934
  utilities.Required,
919
935
  __metadata("design:type", TreeDataSource)
@@ -924,7 +940,7 @@
924
940
  __metadata("design:paramtypes", [rxjs$1.Node]),
925
941
  __metadata("design:returntype", void 0)
926
942
  ], TreeComponent.prototype, "openDetails", null);
927
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeComponent, decorators: [{
943
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeComponent, decorators: [{
928
944
  type: i0.Component,
929
945
  args: [{
930
946
  // tslint:disable-next-line:component-selector
@@ -963,6 +979,8 @@
963
979
  args: [TreeContentDirective, { static: true }]
964
980
  }], hideLeafIcon: [{
965
981
  type: i0.Input
982
+ }], id: [{
983
+ type: i0.Input
966
984
  }], details: [{
967
985
  type: i0.Output
968
986
  }], treeContainer: [{
@@ -981,46 +999,49 @@
981
999
  }
982
1000
  return TreeComponentModule;
983
1001
  }());
984
- TreeComponentModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeComponentModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
985
- TreeComponentModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeComponentModule, declarations: [TreeComponent, TreeContentDirective], imports: [i8.CommonModule,
986
- i1.MatTreeModule,
987
- i4.MatButtonModule,
988
- i2.MatIconModule,
1002
+ TreeComponentModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeComponentModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
1003
+ TreeComponentModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeComponentModule, declarations: [TreeComponent, TreeContentDirective], imports: [i9.CommonModule,
1004
+ i2.MatTreeModule,
1005
+ i5.MatButtonModule,
1006
+ i3.MatIconModule,
989
1007
  flexLayout.FlexLayoutModule,
990
- i6.MatDividerModule,
991
- i5.MatProgressSpinnerModule,
992
- i12.PortalModule,
993
- i11.ContenteditableDirectiveModule,
994
- i10.IconDirectiveModule,
995
- i3.MatCheckboxModule], exports: [TreeComponent, TreeContentDirective] });
996
- TreeComponentModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeComponentModule, imports: [[
997
- i8.CommonModule,
998
- i1.MatTreeModule,
999
- i4.MatButtonModule,
1000
- i2.MatIconModule,
1008
+ i7.MatDividerModule,
1009
+ i6.MatProgressSpinnerModule,
1010
+ i13.PortalModule,
1011
+ i12.ContenteditableDirectiveModule,
1012
+ i11.IconDirectiveModule,
1013
+ i4.MatCheckboxModule,
1014
+ i1.MatProgressBarModule], exports: [TreeComponent, TreeContentDirective] });
1015
+ TreeComponentModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeComponentModule, imports: [[
1016
+ i9.CommonModule,
1017
+ i2.MatTreeModule,
1018
+ i5.MatButtonModule,
1019
+ i3.MatIconModule,
1001
1020
  flexLayout.FlexLayoutModule,
1002
- i6.MatDividerModule,
1003
- i5.MatProgressSpinnerModule,
1004
- i12.PortalModule,
1005
- i11.ContenteditableDirectiveModule,
1006
- i10.IconDirectiveModule,
1007
- i3.MatCheckboxModule
1021
+ i7.MatDividerModule,
1022
+ i6.MatProgressSpinnerModule,
1023
+ i13.PortalModule,
1024
+ i12.ContenteditableDirectiveModule,
1025
+ i11.IconDirectiveModule,
1026
+ i4.MatCheckboxModule,
1027
+ i1.MatProgressBarModule
1008
1028
  ]] });
1009
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0__namespace, type: TreeComponentModule, decorators: [{
1029
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: TreeComponentModule, decorators: [{
1010
1030
  type: i0.NgModule,
1011
1031
  args: [{
1012
1032
  imports: [
1013
- i8.CommonModule,
1014
- i1.MatTreeModule,
1015
- i4.MatButtonModule,
1016
- i2.MatIconModule,
1033
+ i9.CommonModule,
1034
+ i2.MatTreeModule,
1035
+ i5.MatButtonModule,
1036
+ i3.MatIconModule,
1017
1037
  flexLayout.FlexLayoutModule,
1018
- i6.MatDividerModule,
1019
- i5.MatProgressSpinnerModule,
1020
- i12.PortalModule,
1021
- i11.ContenteditableDirectiveModule,
1022
- i10.IconDirectiveModule,
1023
- i3.MatCheckboxModule
1038
+ i7.MatDividerModule,
1039
+ i6.MatProgressSpinnerModule,
1040
+ i13.PortalModule,
1041
+ i12.ContenteditableDirectiveModule,
1042
+ i11.IconDirectiveModule,
1043
+ i4.MatCheckboxModule,
1044
+ i1.MatProgressBarModule
1024
1045
  ],
1025
1046
  declarations: [TreeComponent, TreeContentDirective],
1026
1047
  exports: [TreeComponent, TreeContentDirective],
@@ -1043,5 +1064,5 @@
1043
1064
 
1044
1065
  Object.defineProperty(exports, '__esModule', { value: true });
1045
1066
 
1046
- })));
1067
+ }));
1047
1068
  //# sourceMappingURL=rxap-tree.umd.js.map