@rxap/tree 16.0.0-dev.0 → 16.0.0-dev.10

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,71 +1,63 @@
1
- import { __decorate, __metadata } from 'tslib';
2
- import { BehaviorSubject, Subject, from, merge } from 'rxjs';
3
- import { FlatTreeControl } from '@angular/cdk/tree';
4
1
  import { SelectionModel } from '@angular/cdk/collections';
5
- import { map, tap, switchMap, startWith } from 'rxjs/operators';
6
- import { BaseDataSource, RXAP_DATA_SOURCE_METADATA } from '@rxap/data-source';
7
- import { joinPath, Required, DebounceCall } from '@rxap/utilities';
8
2
  import * as i0 from '@angular/core';
9
- import { InjectionToken, isDevMode, Injectable, Inject, TemplateRef, Directive, EventEmitter, ViewContainerRef, ChangeDetectorRef, Component, ChangeDetectionStrategy, Optional, Input, ContentChild, Output, ViewChild, HostListener, NgModule } from '@angular/core';
10
- import { ToggleSubject, Node } from '@rxap/utilities/rxjs';
11
- import * as i9 from '@angular/cdk/portal';
3
+ import { InjectionToken, isDevMode, Injectable, Inject, TemplateRef, Directive, EventEmitter, ViewContainerRef, ChangeDetectorRef, Component, ChangeDetectionStrategy, Optional, Input, ContentChild, Output, ViewChild, HostListener } from '@angular/core';
4
+ import { BaseDataSource, RXAP_DATA_SOURCE_METADATA } from '@rxap/data-source';
5
+ import { Node } from '@rxap/data-structure-tree';
6
+ import { ToggleSubject } from '@rxap/rxjs';
7
+ import { joinPath, DebounceCall } from '@rxap/utilities';
8
+ import { BehaviorSubject, Subject, from, merge } from 'rxjs';
9
+ import { map, tap, switchMap, startWith } from 'rxjs/operators';
10
+ import { __decorate, __metadata } from 'tslib';
11
+ import * as i10 from '@angular/cdk/portal';
12
12
  import { TemplatePortal, PortalModule } from '@angular/cdk/portal';
13
- import * as i1 from '@angular/common';
14
- import { CommonModule } from '@angular/common';
15
- import * as i2 from '@angular/material/tree';
16
- import { MatTreeModule } from '@angular/material/tree';
17
- import * as i3 from '@angular/material/legacy-button';
18
- import { MatLegacyButtonModule } from '@angular/material/legacy-button';
19
- import * as i4 from '@angular/material/icon';
20
- import { MatIconModule } from '@angular/material/icon';
21
- import * as i5 from '@angular/flex-layout/flex';
22
- import * as i6 from '@angular/flex-layout/extended';
23
- import * as i7 from '@angular/material/divider';
13
+ import { FlatTreeControl } from '@angular/cdk/tree';
14
+ import { NgStyle, NgIf, AsyncPipe } from '@angular/common';
15
+ import * as i2 from '@angular/flex-layout/extended';
16
+ import { ExtendedModule } from '@angular/flex-layout/extended';
17
+ import * as i1 from '@angular/flex-layout/flex';
18
+ import { FlexModule } from '@angular/flex-layout/flex';
19
+ import * as i7 from '@angular/material/button';
20
+ import { MatButtonModule } from '@angular/material/button';
21
+ import * as i6 from '@angular/material/checkbox';
22
+ import { MatCheckboxModule } from '@angular/material/checkbox';
23
+ import * as i9 from '@angular/material/divider';
24
24
  import { MatDividerModule } from '@angular/material/divider';
25
- import * as i8 from '@angular/material/legacy-progress-spinner';
26
- import { MatLegacyProgressSpinnerModule } from '@angular/material/legacy-progress-spinner';
27
- import * as i10 from '@rxap/contenteditable';
28
- import { ContenteditableDirectiveModule } from '@rxap/contenteditable';
29
- import * as i11 from '@rxap/material-directives/icon';
30
- import { IconDirectiveModule } from '@rxap/material-directives/icon';
31
- import * as i12 from '@angular/material/legacy-checkbox';
32
- import { MatLegacyCheckboxModule } from '@angular/material/legacy-checkbox';
33
- import * as i13 from '@angular/material/legacy-progress-bar';
34
- import { MatLegacyProgressBarModule } from '@angular/material/legacy-progress-bar';
35
- import { FlexLayoutModule } from '@angular/flex-layout';
25
+ import * as i5 from '@angular/material/icon';
26
+ import { MatIconModule } from '@angular/material/icon';
27
+ import * as i3 from '@angular/material/progress-bar';
28
+ import { MatProgressBarModule } from '@angular/material/progress-bar';
29
+ import * as i8 from '@angular/material/progress-spinner';
30
+ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
31
+ import * as i4 from '@angular/material/tree';
32
+ import { MatTreeModule } from '@angular/material/tree';
33
+ import { ContenteditableDirective } from '@rxap/contenteditable';
34
+ import { IconDirective } from '@rxap/material-directives/icon';
36
35
 
37
36
  function isSelectionChange(obj) {
38
- return !!obj && obj.hasOwnProperty('added') && obj.hasOwnProperty('removed');
37
+ return !!obj && !!obj['added'] && !!obj['removed'];
39
38
  }
40
39
  const RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD = new InjectionToken('rxap/tree/data-source/root-remote-method');
41
40
  const RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD = new InjectionToken('rxap/tree/data-source/children-remote-method');
42
41
  class TreeDataSource extends BaseDataSource {
43
- get nodeParameters() {
44
- return this._nodeParameters;
45
- }
46
- set nodeParameters(nodeParameters) {
47
- this._nodeParameters = nodeParameters;
48
- this.tree$.value.forEach(node => node.parameters = nodeParameters);
49
- }
50
42
  constructor(rootRemoteMethod, childrenRemoteMethod, metadata = null) {
51
43
  super(metadata);
52
44
  this.rootRemoteMethod = rootRemoteMethod;
53
45
  this.childrenRemoteMethod = childrenRemoteMethod;
54
46
  this.tree$ = new BehaviorSubject([]);
47
+ this.loading$ = new ToggleSubject(true);
48
+ // TODO : änlich problem wie bei der redundaten expand SelectionModel.
49
+ this._data$ = new BehaviorSubject([]);
55
50
  this._expandedLocalStorageSubscription = null;
56
51
  this._selectedLocalStorageSubscription = null;
57
- // TODO : änlich problem wie bei der redundaten expand SelectionModel.
58
52
  // im localStorage wird nur die id gespeichert.
59
53
  this._preSelected = [];
60
- this._data$ = new BehaviorSubject([]);
61
- this.loading$ = new ToggleSubject(true);
54
+ this._refreshMatchFilter = new Subject();
55
+ this._nodeParameters = null;
62
56
  this.toDisplay = () => 'to display function not defined';
63
57
  this.getIcon = () => null;
64
58
  this.getStyle = () => ({});
65
59
  this.hasDetails = () => true;
66
60
  this.matchFilter = () => true;
67
- this._refreshMatchFilter = new Subject();
68
- this._nodeParameters = null;
69
61
  this.tree$
70
62
  .pipe(map((tree) => tree
71
63
  .map((child) => this.flatTree(child))
@@ -75,6 +67,13 @@ class TreeDataSource extends BaseDataSource {
75
67
  this.initSelected();
76
68
  this.initExpanded();
77
69
  }
70
+ get nodeParameters() {
71
+ return this._nodeParameters;
72
+ }
73
+ set nodeParameters(nodeParameters) {
74
+ this._nodeParameters = nodeParameters;
75
+ this.tree$.value.forEach(node => node.parameters = nodeParameters);
76
+ }
78
77
  async getTreeRoot() {
79
78
  this.loading$.enable();
80
79
  const root = await this.getRoot();
@@ -228,6 +227,50 @@ class TreeDataSource extends BaseDataSource {
228
227
  refreshMatchFilter() {
229
228
  this._refreshMatchFilter.next();
230
229
  }
230
+ async refresh() {
231
+ const rootNodes = await this.getTreeRoot();
232
+ // refresh all expanded nodes;
233
+ const loadExpandedNodes = async (children) => {
234
+ for (const child of children) {
235
+ if (this.expanded.isSelected(child.id)) {
236
+ // call the node method to ensure that the expanded property of
237
+ // Node is set.
238
+ await child.expand();
239
+ }
240
+ if (child.hasChildren) {
241
+ await loadExpandedNodes(child.children);
242
+ }
243
+ }
244
+ };
245
+ await Promise.all(rootNodes
246
+ .filter((node) => node.hasChildren)
247
+ .map((node) => loadExpandedNodes(node.children)));
248
+ const selected = this.selected.selected
249
+ .map((node) => this.getNodeById(node.id))
250
+ .filter(Boolean);
251
+ this.selected.clear();
252
+ this.selected.select(...selected);
253
+ }
254
+ reset() {
255
+ this.selected.clear();
256
+ this.expanded.clear();
257
+ return this.getTreeRoot();
258
+ }
259
+ setGetStyle(getStyle = this.getStyle) {
260
+ this.getStyle = getStyle;
261
+ }
262
+ /**
263
+ * recall the getStyle, getIcon and toDisplay methods
264
+ * and update the node objects
265
+ */
266
+ updateNodes() {
267
+ this._data$.value.forEach(node => {
268
+ node.style = this.getStyle(node.item);
269
+ node.icon = this.getIcon(node.item);
270
+ node.display = this.toDisplay(node.item);
271
+ });
272
+ this._data$.next(this._data$.value);
273
+ }
231
274
  _connect(collectionViewer) {
232
275
  this.treeControl.expansionModel.changed.subscribe((change) => {
233
276
  if (isSelectionChange(change)) {
@@ -278,33 +321,9 @@ class TreeDataSource extends BaseDataSource {
278
321
  return Promise.resolve();
279
322
  }), switchMap(() => merge(collectionViewer.viewChange, this._data$).pipe(map(() => this._data$.value))), switchMap(nodeList => this._refreshMatchFilter.pipe(startWith(null), map(() => nodeList.filter(node => this.matchFilter(node))))));
280
323
  }
281
- async refresh() {
282
- const rootNodes = await this.getTreeRoot();
283
- // refresh all expanded nodes;
284
- const loadExpandedNodes = async (children) => {
285
- for (const child of children) {
286
- if (this.expanded.isSelected(child.id)) {
287
- // call the node method to ensure that the expanded property of
288
- // Node is set.
289
- await child.expand();
290
- }
291
- if (child.hasChildren) {
292
- await loadExpandedNodes(child.children);
293
- }
294
- }
295
- };
296
- await Promise.all(rootNodes
297
- .filter((node) => node.hasChildren)
298
- .map((node) => loadExpandedNodes(node.children)));
299
- const selected = this.selected.selected
300
- .map((node) => this.getNodeById(node.id))
301
- .filter(Boolean);
302
- this.selected.clear();
303
- this.selected.select(...selected);
304
- }
305
324
  initSelected() {
306
325
  const key = joinPath('rxap/tree', this.id, 'selected');
307
- if (this.metadata.cacheSelected) {
326
+ if (this.metadata['cacheSelected']) {
308
327
  if (localStorage.getItem(key)) {
309
328
  try {
310
329
  this._preSelected = JSON.parse(localStorage.getItem(key));
@@ -315,21 +334,16 @@ class TreeDataSource extends BaseDataSource {
315
334
  }
316
335
  }
317
336
  this.selected = new SelectionModel(!!this.metadata.selectMultiple, []);
318
- if (this.metadata.cacheSelected) {
337
+ if (this.metadata['cacheSelected']) {
319
338
  this._selectedLocalStorageSubscription = this.selected.changed
320
339
  .pipe(tap(() => localStorage.setItem(key, JSON.stringify(this.selected.selected.map((s) => s.id)))))
321
340
  .subscribe();
322
341
  }
323
342
  }
324
- reset() {
325
- this.selected.clear();
326
- this.expanded.clear();
327
- return this.getTreeRoot();
328
- }
329
343
  initExpanded() {
330
344
  const key = joinPath('rxap/tree', this.id, 'expanded');
331
345
  let expanded = [];
332
- if (this.metadata.cacheExpanded) {
346
+ if (this.metadata['cacheExpanded']) {
333
347
  if (localStorage.getItem(key)) {
334
348
  try {
335
349
  expanded = JSON.parse(localStorage.getItem(key));
@@ -340,35 +354,16 @@ class TreeDataSource extends BaseDataSource {
340
354
  }
341
355
  }
342
356
  this.expanded = new SelectionModel(this.metadata.expandMultiple !== false, expanded);
343
- if (this.metadata.cacheExpanded) {
357
+ if (this.metadata['cacheExpanded']) {
344
358
  this._expandedLocalStorageSubscription = this.expanded.changed
345
359
  .pipe(tap(() => localStorage.setItem(key, JSON.stringify(this.expanded.selected))))
346
360
  .subscribe();
347
361
  }
348
362
  }
349
- setGetStyle(getStyle = this.getStyle) {
350
- this.getStyle = getStyle;
351
- }
352
- /**
353
- * recall the getStyle, getIcon and toDisplay methods
354
- * and update the node objects
355
- */
356
- updateNodes() {
357
- this._data$.value.forEach(node => {
358
- node.style = this.getStyle(node.item);
359
- node.icon = this.getIcon(node.item);
360
- node.display = this.toDisplay(node.item);
361
- });
362
- this._data$.next(this._data$.value);
363
- }
364
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeDataSource, deps: [{ token: RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD }, { token: RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD }, { token: RXAP_DATA_SOURCE_METADATA }], target: i0.ɵɵFactoryTarget.Injectable }); }
365
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeDataSource }); }
363
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeDataSource, deps: [{ token: RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD }, { token: RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD }, { token: RXAP_DATA_SOURCE_METADATA }], target: i0.ɵɵFactoryTarget.Injectable }); }
364
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeDataSource }); }
366
365
  }
367
- __decorate([
368
- Required,
369
- __metadata("design:type", FlatTreeControl)
370
- ], TreeDataSource.prototype, "treeControl", void 0);
371
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeDataSource, decorators: [{
366
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeDataSource, decorators: [{
372
367
  type: Injectable
373
368
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
374
369
  type: Inject,
@@ -379,20 +374,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImpor
379
374
  }] }, { type: undefined, decorators: [{
380
375
  type: Inject,
381
376
  args: [RXAP_DATA_SOURCE_METADATA]
382
- }] }]; }, propDecorators: { treeControl: [] } });
377
+ }] }]; } });
383
378
 
384
379
  class TreeContentDirective {
385
380
  constructor(template) {
386
381
  this.template = template;
387
382
  }
388
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeContentDirective, deps: [{ token: TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
389
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.2", type: TreeContentDirective, selector: "ng-template[rxapTreeContent]", ngImport: i0 }); }
383
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeContentDirective, deps: [{ token: TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
384
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.1.4", type: TreeContentDirective, isStandalone: true, selector: "ng-template[rxapTreeContent]", ngImport: i0 }); }
390
385
  }
391
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeContentDirective, decorators: [{
386
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeContentDirective, decorators: [{
392
387
  type: Directive,
393
388
  args: [{
394
- // tslint:disable-next-line:directive-selector
395
389
  selector: 'ng-template[rxapTreeContent]',
390
+ standalone: true,
396
391
  }]
397
392
  }], ctorParameters: function () { return [{ type: i0.TemplateRef, decorators: [{
398
393
  type: Inject,
@@ -402,12 +397,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImpor
402
397
  const RXAP_TREE_CONTENT_EDITABLE_METHOD = new InjectionToken('rxap/tree-content-editable-method');
403
398
 
404
399
  class TreeComponent {
405
- get nodeDisplayEditable() {
406
- return !!this.contentEditableMethod;
407
- }
408
- get cacheId() {
409
- return ['rxap', 'tree', this.id].join('/');
410
- }
411
400
  constructor(viewContainerRef, cdr, contentEditableMethod, renderer) {
412
401
  this.viewContainerRef = viewContainerRef;
413
402
  this.cdr = cdr;
@@ -417,9 +406,6 @@ class TreeComponent {
417
406
  this.details = new EventEmitter();
418
407
  this.dividerOffset = '256px';
419
408
  this.portal = null;
420
- this.getLevel = (node) => node.depth;
421
- this.isExpandable = (node) => node.hasChildren;
422
- this.hasChild = (_, nodeData) => nodeData.hasChildren;
423
409
  /**
424
410
  * Indicates that the divider is moved with mouse down
425
411
  * @private
@@ -432,9 +418,18 @@ class TreeComponent {
432
418
  * @private
433
419
  */
434
420
  this._treeContainerWidth = null;
421
+ this.getLevel = (node) => node.depth;
422
+ this.isExpandable = (node) => node.hasChildren;
423
+ this.hasChild = (_, nodeData) => nodeData.hasChildren;
435
424
  this.treeControl = new FlatTreeControl(this.getLevel, this.isExpandable);
436
425
  this.contentEditableMethod = contentEditableMethod;
437
426
  }
427
+ get nodeDisplayEditable() {
428
+ return !!this.contentEditableMethod;
429
+ }
430
+ get cacheId() {
431
+ return ['rxap', 'tree', this.id].join('/');
432
+ }
438
433
  ngOnInit() {
439
434
  this.dataSource.setTreeControl(this.treeControl);
440
435
  this.dataSource.setToDisplay(this.toDisplay);
@@ -450,7 +445,7 @@ class TreeComponent {
450
445
  this.setDividerOffset(cachedOffset);
451
446
  }
452
447
  else if (isDevMode()) {
453
- console.log("Divider offset cache is not available or invalid: " + cachedOffset);
448
+ console.log('Divider offset cache is not available or invalid: ' + cachedOffset);
454
449
  }
455
450
  }
456
451
  ngAfterContentInit() {
@@ -489,7 +484,7 @@ class TreeComponent {
489
484
  }
490
485
  setDividerOffset(offset) {
491
486
  if (isDevMode()) {
492
- console.log("set divider offset to: " + offset);
487
+ console.log('set divider offset to: ' + offset);
493
488
  }
494
489
  this.dividerOffset = offset;
495
490
  this.renderer.setStyle(this.treeContainer.nativeElement, 'max-width', offset);
@@ -497,22 +492,34 @@ class TreeComponent {
497
492
  this.renderer.setStyle(this.treeContainer.nativeElement, 'flex-basis', offset);
498
493
  localStorage.setItem(this.cacheId, offset);
499
494
  }
500
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeComponent, deps: [{ token: ViewContainerRef }, { token: ChangeDetectorRef }, { token: RXAP_TREE_CONTENT_EDITABLE_METHOD, optional: true }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component }); }
501
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.2", type: TreeComponent, selector: "rxap-tree", inputs: { dataSource: "dataSource", contentEditableMethod: "contentEditableMethod", toDisplay: "toDisplay", getIcon: "getIcon", getStyle: "getStyle", multiple: "multiple", hasDetails: "hasDetails", hideLeafIcon: "hideLeafIcon", id: "id", dividerOffset: "dividerOffset" }, 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, template: "<div class=\"container\" fxLayout=\"row\">\n <div [ngStyle]=\"{ maxWidth: dividerOffset, minWidth: dividerOffset, flexBasis: dividerOffset }\" #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\n (change)=\"node.toggleSelect()\"\n [checked]=\"node.selected\"\n [disabled]=\"!node.hasDetails\"\n [ngStyle]=\"node.style\"\n fxFlex=\"nogrow\">\n {{ node.display }}\n </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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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:initial}.details{max-height:calc(100vh - 96px);overflow-y:auto}.tree-container{max-height:calc(100vh - 96px);overflow-y:auto;width:-moz-fit-content;width:fit-content}.divider{cursor:ew-resize;padding:12px}.divider ::ng-deep .mat-divider{height:100%}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { kind: "directive", type: i2.MatTreeNodePadding, selector: "[matTreeNodePadding]", inputs: ["matTreeNodePadding", "matTreeNodePaddingIndent"] }, { kind: "directive", type: i2.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { kind: "component", type: i2.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { kind: "directive", type: i2.MatTreeNode, selector: "mat-tree-node", inputs: ["role", "disabled", "tabIndex"], exportAs: ["matTreeNode"] }, { kind: "component", type: i3.MatLegacyButton, 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"] }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i5.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"] }, { kind: "directive", type: i5.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"] }, { kind: "directive", type: i5.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"] }, { kind: "directive", type: i5.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"] }, { kind: "directive", type: i6.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"] }, { kind: "directive", type: i6.DefaultStyleDirective, selector: " [ngStyle], [ngStyle.xs], [ngStyle.sm], [ngStyle.md], [ngStyle.lg], [ngStyle.xl], [ngStyle.lt-sm], [ngStyle.lt-md], [ngStyle.lt-lg], [ngStyle.lt-xl], [ngStyle.gt-xs], [ngStyle.gt-sm], [ngStyle.gt-md], [ngStyle.gt-lg]", inputs: ["ngStyle", "ngStyle.xs", "ngStyle.sm", "ngStyle.md", "ngStyle.lg", "ngStyle.xl", "ngStyle.lt-sm", "ngStyle.lt-md", "ngStyle.lt-lg", "ngStyle.lt-xl", "ngStyle.gt-xs", "ngStyle.gt-sm", "ngStyle.gt-md", "ngStyle.gt-lg"] }, { kind: "component", type: i7.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "component", type: i8.MatLegacyProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "diameter", "strokeWidth", "mode", "value"], exportAs: ["matProgressSpinner"] }, { kind: "directive", type: i9.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }, { kind: "directive", type: i10.ContenteditableDirective, selector: "[rxapContenteditable]", inputs: ["rxapContenteditable", "disabled"], outputs: ["change"] }, { kind: "directive", type: i11.IconDirective, selector: "mat-icon[rxapIcon]", inputs: ["rxapIcon"] }, { kind: "component", type: i12.MatLegacyCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex"], exportAs: ["matCheckbox"] }, { kind: "component", type: i13.MatLegacyProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
495
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeComponent, deps: [{ token: ViewContainerRef }, { token: ChangeDetectorRef }, { token: RXAP_TREE_CONTENT_EDITABLE_METHOD, optional: true }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component }); }
496
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.4", type: TreeComponent, isStandalone: true, selector: "rxap-tree", inputs: { dataSource: "dataSource", contentEditableMethod: "contentEditableMethod", toDisplay: "toDisplay", getIcon: "getIcon", getStyle: "getStyle", multiple: "multiple", hasDetails: "hasDetails", hideLeafIcon: "hideLeafIcon", id: "id", dividerOffset: "dividerOffset" }, 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, template: "<div class=\"container\" fxLayout=\"row\">\n <div #treeContainer [ngStyle]=\"{ maxWidth: dividerOffset, minWidth: dividerOffset, flexBasis: dividerOffset }\"\n 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\"\n 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\n (change)=\"node.toggleSelect()\"\n [checked]=\"node.selected\"\n [disabled]=\"!node.hasDetails\"\n [ngStyle]=\"node.style\"\n fxFlex=\"nogrow\">\n {{ node.display }}\n </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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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:initial}.details{max-height:calc(100vh - 96px);overflow-y:auto}.tree-container{max-height:calc(100vh - 96px);overflow-y:auto;width:-moz-fit-content;width:fit-content}.divider{cursor:ew-resize;padding:12px}.divider ::ng-deep .mat-divider{height:100%}\n"], dependencies: [{ kind: "ngmodule", type: FlexModule }, { kind: "directive", type: i1.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"] }, { kind: "directive", type: i1.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"] }, { kind: "directive", type: i1.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"] }, { kind: "directive", type: i1.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"] }, { kind: "directive", type: NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: ExtendedModule }, { kind: "directive", type: i2.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"] }, { kind: "directive", type: i2.DefaultStyleDirective, selector: " [ngStyle], [ngStyle.xs], [ngStyle.sm], [ngStyle.md], [ngStyle.lg], [ngStyle.xl], [ngStyle.lt-sm], [ngStyle.lt-md], [ngStyle.lt-lg], [ngStyle.lt-xl], [ngStyle.gt-xs], [ngStyle.gt-sm], [ngStyle.gt-md], [ngStyle.gt-lg]", inputs: ["ngStyle", "ngStyle.xs", "ngStyle.sm", "ngStyle.md", "ngStyle.lg", "ngStyle.xl", "ngStyle.lt-sm", "ngStyle.lt-md", "ngStyle.lt-lg", "ngStyle.lt-xl", "ngStyle.gt-xs", "ngStyle.gt-sm", "ngStyle.gt-md", "ngStyle.gt-lg"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatProgressBarModule }, { kind: "component", type: i3.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "ngmodule", type: MatTreeModule }, { kind: "directive", type: i4.MatTreeNodeDef, selector: "[matTreeNodeDef]", inputs: ["matTreeNodeDefWhen", "matTreeNode"] }, { kind: "directive", type: i4.MatTreeNodePadding, selector: "[matTreeNodePadding]", inputs: ["matTreeNodePadding", "matTreeNodePaddingIndent"] }, { kind: "directive", type: i4.MatTreeNodeToggle, selector: "[matTreeNodeToggle]", inputs: ["matTreeNodeToggleRecursive"] }, { kind: "component", type: i4.MatTree, selector: "mat-tree", exportAs: ["matTree"] }, { kind: "directive", type: i4.MatTreeNode, selector: "mat-tree-node", inputs: ["role", "disabled", "tabIndex"], exportAs: ["matTreeNode"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: IconDirective, selector: "mat-icon[rxapIcon]", inputs: ["rxapIcon"] }, { kind: "ngmodule", type: MatCheckboxModule }, { kind: "component", type: i6.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex"], exportAs: ["matCheckbox"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i7.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i7.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "directive", type: ContenteditableDirective, selector: "[rxapContenteditable]", inputs: ["rxapContenteditable", "disabled"], outputs: ["change"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i8.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i9.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "ngmodule", type: PortalModule }, { kind: "directive", type: i10.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
502
497
  }
503
- __decorate([
504
- Required,
505
- __metadata("design:type", TreeDataSource)
506
- ], TreeComponent.prototype, "dataSource", void 0);
507
498
  __decorate([
508
499
  DebounceCall(100),
509
500
  __metadata("design:type", Function),
510
501
  __metadata("design:paramtypes", [Node]),
511
502
  __metadata("design:returntype", void 0)
512
503
  ], TreeComponent.prototype, "openDetails", null);
513
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeComponent, decorators: [{
504
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: TreeComponent, decorators: [{
514
505
  type: Component,
515
- args: [{ selector: 'rxap-tree', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"container\" fxLayout=\"row\">\n <div [ngStyle]=\"{ maxWidth: dividerOffset, minWidth: dividerOffset, flexBasis: dividerOffset }\" #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\n (change)=\"node.toggleSelect()\"\n [checked]=\"node.selected\"\n [disabled]=\"!node.hasDetails\"\n [ngStyle]=\"node.style\"\n fxFlex=\"nogrow\">\n {{ node.display }}\n </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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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:initial}.details{max-height:calc(100vh - 96px);overflow-y:auto}.tree-container{max-height:calc(100vh - 96px);overflow-y:auto;width:-moz-fit-content;width:fit-content}.divider{cursor:ew-resize;padding:12px}.divider ::ng-deep .mat-divider{height:100%}\n"] }]
506
+ args: [{ selector: 'rxap-tree', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [
507
+ FlexModule,
508
+ NgStyle,
509
+ ExtendedModule,
510
+ NgIf,
511
+ MatProgressBarModule,
512
+ MatTreeModule,
513
+ MatIconModule,
514
+ IconDirective,
515
+ MatCheckboxModule,
516
+ MatButtonModule,
517
+ ContenteditableDirective,
518
+ MatProgressSpinnerModule,
519
+ MatDividerModule,
520
+ PortalModule,
521
+ AsyncPipe,
522
+ ], template: "<div class=\"container\" fxLayout=\"row\">\n <div #treeContainer [ngStyle]=\"{ maxWidth: dividerOffset, minWidth: dividerOffset, flexBasis: dividerOffset }\"\n 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\"\n 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\n (change)=\"node.toggleSelect()\"\n [checked]=\"node.selected\"\n [disabled]=\"!node.hasDetails\"\n [ngStyle]=\"node.style\"\n fxFlex=\"nogrow\">\n {{ node.display }}\n </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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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 [ngStyle]=\"node.style\"\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:initial}.details{max-height:calc(100vh - 96px);overflow-y:auto}.tree-container{max-height:calc(100vh - 96px);overflow-y:auto;width:-moz-fit-content;width:fit-content}.divider{cursor:ew-resize;padding:12px}.divider ::ng-deep .mat-divider{height:100%}\n"] }]
516
523
  }], ctorParameters: function () { return [{ type: i0.ViewContainerRef, decorators: [{
517
524
  type: Inject,
518
525
  args: [ViewContainerRef]
@@ -525,7 +532,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImpor
525
532
  type: Inject,
526
533
  args: [RXAP_TREE_CONTENT_EDITABLE_METHOD]
527
534
  }] }, { type: i0.Renderer2 }]; }, propDecorators: { dataSource: [{
528
- type: Input
535
+ type: Input,
536
+ args: [{ required: true }]
529
537
  }], contentEditableMethod: [{
530
538
  type: Input
531
539
  }], toDisplay: [{
@@ -560,58 +568,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImpor
560
568
  args: ['mousemove', ['$event']]
561
569
  }] } });
562
570
 
563
- class TreeComponentModule {
564
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeComponentModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
565
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.0.2", ngImport: i0, type: TreeComponentModule, declarations: [TreeComponent, TreeContentDirective], imports: [CommonModule,
566
- MatTreeModule,
567
- MatLegacyButtonModule,
568
- MatIconModule,
569
- FlexLayoutModule,
570
- MatDividerModule,
571
- MatLegacyProgressSpinnerModule,
572
- PortalModule,
573
- ContenteditableDirectiveModule,
574
- IconDirectiveModule,
575
- MatLegacyCheckboxModule,
576
- MatLegacyProgressBarModule], exports: [TreeComponent, TreeContentDirective] }); }
577
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeComponentModule, imports: [CommonModule,
578
- MatTreeModule,
579
- MatLegacyButtonModule,
580
- MatIconModule,
581
- FlexLayoutModule,
582
- MatDividerModule,
583
- MatLegacyProgressSpinnerModule,
584
- PortalModule,
585
- ContenteditableDirectiveModule,
586
- IconDirectiveModule,
587
- MatLegacyCheckboxModule,
588
- MatLegacyProgressBarModule] }); }
589
- }
590
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: TreeComponentModule, decorators: [{
591
- type: NgModule,
592
- args: [{
593
- imports: [
594
- CommonModule,
595
- MatTreeModule,
596
- MatLegacyButtonModule,
597
- MatIconModule,
598
- FlexLayoutModule,
599
- MatDividerModule,
600
- MatLegacyProgressSpinnerModule,
601
- PortalModule,
602
- ContenteditableDirectiveModule,
603
- IconDirectiveModule,
604
- MatLegacyCheckboxModule,
605
- MatLegacyProgressBarModule,
606
- ],
607
- declarations: [TreeComponent, TreeContentDirective],
608
- exports: [TreeComponent, TreeContentDirective]
609
- }]
610
- }] });
611
-
612
571
  /**
613
572
  * Generated bundle index. Do not edit.
614
573
  */
615
574
 
616
- export { RXAP_TREE_CONTENT_EDITABLE_METHOD, RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD, RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD, TreeComponent, TreeComponentModule, TreeContentDirective, TreeDataSource, isSelectionChange };
575
+ export { RXAP_TREE_CONTENT_EDITABLE_METHOD, RXAP_TREE_DATA_SOURCE_CHILDREN_REMOTE_METHOD, RXAP_TREE_DATA_SOURCE_ROOT_REMOTE_METHOD, TreeComponent, TreeContentDirective, TreeDataSource, isSelectionChange };
617
576
  //# sourceMappingURL=rxap-tree.mjs.map