@coolon/angular-ui-powerups 16.1.0-aplpha.151 → 16.1.0-aplpha.153

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.
Files changed (25) hide show
  1. package/assets/table.scss +1 -1
  2. package/esm2022/lib/components/components.module.mjs +16 -16
  3. package/esm2022/lib/components/exports.mjs +4 -4
  4. package/esm2022/lib/components/loadable-component.mjs +1 -1
  5. package/esm2022/lib/components/tables/abstract-table-model.mjs +43 -24
  6. package/esm2022/lib/components/tables/renderer/table-action-column/menu-builder.mjs +2 -0
  7. package/esm2022/lib/components/tables/renderer/table-action-column/table-action-column.component.mjs +147 -0
  8. package/esm2022/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu-popup.component.mjs +45 -0
  9. package/esm2022/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu.component.mjs +71 -0
  10. package/fesm2022/coolon-angular-ui-powerups.mjs +199 -110
  11. package/fesm2022/coolon-angular-ui-powerups.mjs.map +1 -1
  12. package/lib/components/components.module.d.ts +4 -4
  13. package/lib/components/exports.d.ts +3 -3
  14. package/lib/components/loadable-component.d.ts +2 -2
  15. package/lib/components/tables/abstract-table-model.d.ts +26 -19
  16. package/lib/components/tables/renderer/table-action-column/menu-builder.d.ts +7 -0
  17. package/lib/components/tables/renderer/table-action-column/table-action-column.component.d.ts +41 -0
  18. package/lib/components/tables/renderer/table-custom-more-menu/table-custom-more-menu-popup.component.d.ts +19 -0
  19. package/lib/components/tables/renderer/{table-more-menu/table-more-menu.component.d.ts → table-custom-more-menu/table-custom-more-menu.component.d.ts} +7 -7
  20. package/package.json +1 -1
  21. package/esm2022/lib/components/tables/renderer/table-more-menu/table-more-menu-popup/table-more-menu-popup.component.mjs +0 -40
  22. package/esm2022/lib/components/tables/renderer/table-more-menu/table-more-menu.component.mjs +0 -65
  23. package/esm2022/lib/components/tables/table-row-menu/table-row-menu.component.mjs +0 -84
  24. package/lib/components/tables/renderer/table-more-menu/table-more-menu-popup/table-more-menu-popup.component.d.ts +0 -18
  25. package/lib/components/tables/table-row-menu/table-row-menu.component.d.ts +0 -28
@@ -4366,7 +4366,142 @@ class FooterRowModel {
4366
4366
  })(FooterRowModel || (FooterRowModel = {}));
4367
4367
  ProxyRegistry.registerOneTimeBinding(FooterRowModel);
4368
4368
 
4369
- class TableMoreMenuComponent extends DisposableComponent {
4369
+ // TODO: This performs poorly, lots of factory calls initial rendering and on mouse movements
4370
+ class CommandData {
4371
+ factory;
4372
+ face;
4373
+ constructor(factory, face) {
4374
+ this.factory = factory;
4375
+ this.face = face;
4376
+ }
4377
+ }
4378
+ class DownloadData {
4379
+ createInfo;
4380
+ constructor(createInfo) {
4381
+ this.createInfo = createInfo;
4382
+ }
4383
+ createDownloadInfo(value) {
4384
+ return this.createInfo(value);
4385
+ }
4386
+ }
4387
+ /**
4388
+ *
4389
+ */
4390
+ class TableActionColumnComponent extends DisposableComponent {
4391
+ value;
4392
+ menu;
4393
+ actions = [];
4394
+ moreActions = [];
4395
+ trackByIndex = Track.byIndex;
4396
+ constructor() {
4397
+ super();
4398
+ this.onInit(() => console.log("table action column init"));
4399
+ }
4400
+ addCommand(commandFactory, properties) {
4401
+ this.actions.push(new CommandData(commandFactory, properties));
4402
+ }
4403
+ addSeparator() {
4404
+ this.actions.push(null);
4405
+ }
4406
+ addDownload(factory) {
4407
+ this.actions.push(new DownloadData(factory));
4408
+ }
4409
+ addMoreMenu(builder) {
4410
+ const self = this;
4411
+ builder({
4412
+ addCommand(factory, face) {
4413
+ self.moreActions.push(new CommandData(factory, face));
4414
+ },
4415
+ addSeparator() {
4416
+ self.moreActions.push(null);
4417
+ },
4418
+ addDownload(factory) {
4419
+ self.moreActions.push(new DownloadData(factory));
4420
+ }
4421
+ });
4422
+ }
4423
+ // createMoreMenuCommand(item: CommandData<T>, value: T): Command<void> {
4424
+ // const { when } = Dsl.disposeWith(this);
4425
+ // const command = item.factory.create(value, { disposedWith: this });
4426
+ // when(command.busy$).becomesFalsey(() => {
4427
+ // this.closeMoreMenu();
4428
+ // });
4429
+ // return command;
4430
+ // }
4431
+ closeMoreMenu() {
4432
+ this.menu.closeMenu();
4433
+ }
4434
+ isCommand(item) {
4435
+ return item instanceof CommandData;
4436
+ }
4437
+ isDownload(item) {
4438
+ return item instanceof DownloadData;
4439
+ }
4440
+ isSeparator(item) {
4441
+ return !item;
4442
+ }
4443
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableActionColumnComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
4444
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableActionColumnComponent, selector: "aup-table-action-column", inputs: { value: "value" }, viewQueries: [{ propertyName: "menu", first: true, predicate: MatMenuTrigger, descendants: true }], usesInheritance: true, ngImport: i0, template: `
4445
+ <aup-tool-bar>
4446
+ <ng-container *ngFor="let action of actions;trackBy: trackByIndex">
4447
+ <aup-command *ngIf="isCommand(action)"
4448
+ #comp
4449
+ [command]="action.factory.create(value, {disposedWith: comp})"
4450
+ [face]="action.face" />
4451
+ <aup-file-download *ngIf="isDownload(action)" [download]="action.createDownloadInfo(value)" />
4452
+ <aup-separator *ngIf="isSeparator(action)" />
4453
+ </ng-container>
4454
+ </aup-tool-bar>
4455
+ <ng-container *ngIf="moreActions.length > 0">
4456
+ <aup-flex class="flex" />
4457
+ <aup-more-menu>
4458
+ <ng-container *ngFor="let action of moreActions; trackBy: trackByIndex">
4459
+ <aup-command *ngIf="isCommand(action)"
4460
+ #comp
4461
+ [command]="action.factory.create(value, {disposedWith: comp})"
4462
+ [face]="action.face" />
4463
+ <aup-file-download *ngIf="isDownload(action)" [download]="action.createDownloadInfo(value)" />
4464
+ <aup-separator *ngIf="isSeparator(action)" />
4465
+ </ng-container>
4466
+ </aup-more-menu>
4467
+ </ng-container>
4468
+ `, isInline: true, styles: [":host{display:inline-flex;flex-direction:row;align-items:center}:host:last-child{padding-right:0}\n"], dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ToolBarComponent, selector: "aup-tool-bar" }, { kind: "component", type: CommandComponent, selector: "aup-command", inputs: ["command", "face$", "face", "busyFace$", "busyFace", "alignFace"] }, { kind: "component", type: MoreMenuComponent, selector: "aup-more-menu", inputs: ["tooltip"] }, { kind: "component", type: SeparatorComponent, selector: "aup-separator" }, { kind: "component", type: FlexComponent, selector: "aup-flex" }, { kind: "component", type: FileDownloadComponent, selector: "aup-file-download", inputs: ["download$", "download", "alignFace"] }] });
4469
+ }
4470
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableActionColumnComponent, decorators: [{
4471
+ type: Component,
4472
+ args: [{ selector: 'aup-table-action-column', template: `
4473
+ <aup-tool-bar>
4474
+ <ng-container *ngFor="let action of actions;trackBy: trackByIndex">
4475
+ <aup-command *ngIf="isCommand(action)"
4476
+ #comp
4477
+ [command]="action.factory.create(value, {disposedWith: comp})"
4478
+ [face]="action.face" />
4479
+ <aup-file-download *ngIf="isDownload(action)" [download]="action.createDownloadInfo(value)" />
4480
+ <aup-separator *ngIf="isSeparator(action)" />
4481
+ </ng-container>
4482
+ </aup-tool-bar>
4483
+ <ng-container *ngIf="moreActions.length > 0">
4484
+ <aup-flex class="flex" />
4485
+ <aup-more-menu>
4486
+ <ng-container *ngFor="let action of moreActions; trackBy: trackByIndex">
4487
+ <aup-command *ngIf="isCommand(action)"
4488
+ #comp
4489
+ [command]="action.factory.create(value, {disposedWith: comp})"
4490
+ [face]="action.face" />
4491
+ <aup-file-download *ngIf="isDownload(action)" [download]="action.createDownloadInfo(value)" />
4492
+ <aup-separator *ngIf="isSeparator(action)" />
4493
+ </ng-container>
4494
+ </aup-more-menu>
4495
+ </ng-container>
4496
+ `, styles: [":host{display:inline-flex;flex-direction:row;align-items:center}:host:last-child{padding-right:0}\n"] }]
4497
+ }], ctorParameters: function () { return []; }, propDecorators: { value: [{
4498
+ type: Input
4499
+ }], menu: [{
4500
+ type: ViewChild,
4501
+ args: [MatMenuTrigger]
4502
+ }] } });
4503
+
4504
+ class TableCustomMoreMenuComponent extends DisposableComponent {
4370
4505
  value$ = new MutableValueModel();
4371
4506
  #value_accessor_storage;
4372
4507
  get value() { return this.#value_accessor_storage; }
@@ -4401,23 +4536,29 @@ class TableMoreMenuComponent extends DisposableComponent {
4401
4536
  get visible$() {
4402
4537
  return this._visible$.readonly$;
4403
4538
  }
4404
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableMoreMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
4405
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableMoreMenuComponent, selector: "aup-table-more-menu", host: { listeners: { "click": "preventDefault($event)" } }, viewQueries: [{ propertyName: "matMenuTrigger", first: true, predicate: MatMenuTrigger, descendants: true }], usesInheritance: true, ngImport: i0, template: "<mat-menu #menu=\"matMenu\" xPosition=\"before\">\n <ng-template matMenuContent [cdkPortalOutlet]=\"popupComponentPortal$.value\"\n (attached)=\"initialise($event)\"></ng-template>\n</mat-menu>\n\n<button mat-icon-button [matMenuTriggerFor]=\"menu\" data-cy=\"more-menu-trigger\" *ngIf=\"visible$.value\">\n <aup-icon icon=\"mat:more_vert\"></aup-icon>\n</button>\n", styles: [":host{display:inline;text-align:end}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "directive", type: i1$4.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }, { kind: "component", type: i2$1.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "directive", type: i2$1.MatMenuContent, selector: "ng-template[matMenuContent]" }, { kind: "directive", type: i2$1.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "component", type: IconComponent, selector: "aup-icon", inputs: ["icon"] }] });
4539
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCustomMoreMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
4540
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableCustomMoreMenuComponent, selector: "aup-table-custom-more-menu", host: { listeners: { "click": "preventDefault($event)" } }, viewQueries: [{ propertyName: "matMenuTrigger", first: true, predicate: MatMenuTrigger, descendants: true }], usesInheritance: true, ngImport: i0, template: "<mat-menu #menu=\"matMenu\" xPosition=\"before\">\n <ng-template matMenuContent [cdkPortalOutlet]=\"popupComponentPortal$.value\" (attached)=\"initialise($event)\"></ng-template>\n</mat-menu>\n\n<button mat-icon-button [matMenuTriggerFor]=\"menu\" data-cy=\"more-menu-trigger\" *ngIf=\"visible$.value\">\n <aup-icon icon=\"mat:more_vert\"></aup-icon>\n</button>\n", styles: [":host{display:inline;text-align:end}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "directive", type: i1$4.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }, { kind: "component", type: i2$1.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "directive", type: i2$1.MatMenuContent, selector: "ng-template[matMenuContent]" }, { kind: "directive", type: i2$1.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "component", type: IconComponent, selector: "aup-icon", inputs: ["icon"] }] });
4406
4541
  }
4407
4542
  __decorate([
4408
4543
  StoreInValueModel(),
4409
4544
  __metadata("design:type", Object)
4410
- ], TableMoreMenuComponent.prototype, "value", null);
4411
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableMoreMenuComponent, decorators: [{
4545
+ ], TableCustomMoreMenuComponent.prototype, "value", null);
4546
+ __decorate([
4547
+ Trace(),
4548
+ __metadata("design:type", Function),
4549
+ __metadata("design:paramtypes", [Object]),
4550
+ __metadata("design:returntype", void 0)
4551
+ ], TableCustomMoreMenuComponent.prototype, "initialise", null);
4552
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCustomMoreMenuComponent, decorators: [{
4412
4553
  type: Component,
4413
- args: [{ selector: "aup-table-more-menu", template: "<mat-menu #menu=\"matMenu\" xPosition=\"before\">\n <ng-template matMenuContent [cdkPortalOutlet]=\"popupComponentPortal$.value\"\n (attached)=\"initialise($event)\"></ng-template>\n</mat-menu>\n\n<button mat-icon-button [matMenuTriggerFor]=\"menu\" data-cy=\"more-menu-trigger\" *ngIf=\"visible$.value\">\n <aup-icon icon=\"mat:more_vert\"></aup-icon>\n</button>\n", styles: [":host{display:inline;text-align:end}\n"] }]
4554
+ args: [{ selector: "aup-table-custom-more-menu", template: "<mat-menu #menu=\"matMenu\" xPosition=\"before\">\n <ng-template matMenuContent [cdkPortalOutlet]=\"popupComponentPortal$.value\" (attached)=\"initialise($event)\"></ng-template>\n</mat-menu>\n\n<button mat-icon-button [matMenuTriggerFor]=\"menu\" data-cy=\"more-menu-trigger\" *ngIf=\"visible$.value\">\n <aup-icon icon=\"mat:more_vert\"></aup-icon>\n</button>\n", styles: [":host{display:inline;text-align:end}\n"] }]
4414
4555
  }], ctorParameters: function () { return []; }, propDecorators: { value: [], matMenuTrigger: [{
4415
4556
  type: ViewChild,
4416
4557
  args: [MatMenuTrigger]
4417
4558
  }], preventDefault: [{
4418
4559
  type: HostListener,
4419
4560
  args: ["click", ["$event"]]
4420
- }] } });
4561
+ }], initialise: [] } });
4421
4562
 
4422
4563
  var DefaultArrayFormatter = ColumnTextSearchFormatter.DefaultArrayFormatter;
4423
4564
  var DefaultValueFormatter = ColumnTextSearchFormatter.DefaultValueFormatter;
@@ -4473,16 +4614,16 @@ class AbstractTableModel extends GarbageCollector {
4473
4614
  this._rowsBeingEdited$ = new MutableListModel([], {
4474
4615
  identifiedWith: row => this.identityOf(row)
4475
4616
  });
4476
- this._editorSessionByRowId = chain(this._editorSessions).indexBy("rowId");
4617
+ this._editorSessionByRowId = chain(this._editorSessions).indexBy('rowId');
4477
4618
  this.editing$ = chain(this._editorSessions).count().isGreaterThan(0);
4478
4619
  this.textSearchPredicate$ = chain(this.visibleColumns$).reduceAll(columns => {
4479
4620
  return (row, regex) => {
4480
4621
  return (!regex || !!columns.find(c => regex.test(c.getSearchTextFor(row))));
4481
4622
  };
4482
4623
  });
4483
- this.selectionColumnModel = new SelectionColumnModel("selection-column", this.columnManager, () => this.getColumnTextProperties("selection-column"));
4624
+ this.selectionColumnModel = new SelectionColumnModel('selection-column', this.columnManager, () => this.getColumnTextProperties('selection-column'));
4484
4625
  this.addColumn(this.selectionColumnModel, { before: null }); // first column
4485
- this.addRowClass("aup-row-selected", row => this.selectionColumnModel.isSelected(row));
4626
+ this.addRowClass('aup-row-selected', row => this.selectionColumnModel.isSelected(row));
4486
4627
  this.firstEditableColumn$ = chain(this.columns$).select(c => c.hasEditorPortal()).first();
4487
4628
  this.firstVisibleColumn$ = chain(this.visibleColumns$).first();
4488
4629
  this.lastVisibleColumn$ = chain(this.visibleColumns$).last();
@@ -4559,7 +4700,7 @@ class AbstractTableModel extends GarbageCollector {
4559
4700
  const { when } = Dsl.disposeWith(editSession);
4560
4701
  when(editSession.liveRowValue$).changes((editedValue) => {
4561
4702
  this._rowsBeingEdited$.replaceOrPush(editedValue);
4562
- }, { initialValue: "triggerChangeUnlessNil" });
4703
+ }, { initialValue: 'triggerChangeUnlessNil' });
4563
4704
  this._editorSessions.push(editSession);
4564
4705
  editSession.onDispose(() => {
4565
4706
  this._rowsBeingEdited$.remove(editSession.liveRowValue$.value);
@@ -4599,7 +4740,7 @@ class AbstractTableModel extends GarbageCollector {
4599
4740
  if (isFunction(formFactory)) {
4600
4741
  this._createForm = formFactory;
4601
4742
  }
4602
- const columnId = "editControls";
4743
+ const columnId = 'editControls';
4603
4744
  return this.addColumn(new EditorControlColumnModel(columnId, this.columnManager, saveCommandFactory, () => this.getColumnTextProperties(columnId)));
4604
4745
  }
4605
4746
  addCustomColumn(columnId, dataAccessor) {
@@ -4608,15 +4749,33 @@ class AbstractTableModel extends GarbageCollector {
4608
4749
  addComponentColumn(columnId, component, onComponentInitOrOptions) {
4609
4750
  return this.addColumn(new CustomValueColumnModel(columnId, this.columnManager, () => this.getColumnTextProperties(columnId), row => row)).cellRenderer(component, onComponentInitOrOptions);
4610
4751
  }
4611
- addMoreMenu(componentClass, initialiseCallback) {
4612
- return this.addComponentColumn("more-menu", TableMoreMenuComponent, (component) => {
4752
+ addMoreMenu(builder) {
4753
+ // re-using the action column as it much simpler in teh case of just commands
4754
+ return this.addActionColumn((component) => {
4755
+ component.addMoreMenu(builder);
4756
+ }).columnTextProperties({
4757
+ headerText() {
4758
+ return '';
4759
+ }
4760
+ });
4761
+ }
4762
+ /**
4763
+ * Use this method if the more menu popup needs custom components
4764
+ */
4765
+ addCustomMoreMenu(componentClass, initialiseCallback) {
4766
+ return this.addComponentColumn('custom-more-menu', TableCustomMoreMenuComponent, (component) => {
4613
4767
  component.configurePopupComponentType(componentClass, initialiseCallback);
4614
4768
  }).columnTextProperties({
4615
4769
  headerText() {
4616
- return "";
4770
+ return '';
4617
4771
  }
4618
4772
  });
4619
4773
  }
4774
+ addActionColumn(builder) {
4775
+ return this.addComponentColumn("actions", TableActionColumnComponent, (c) => {
4776
+ builder(c);
4777
+ });
4778
+ }
4620
4779
  addFooterRow(component, initialiseCallback) {
4621
4780
  assert.isNil(this.footerRowModel);
4622
4781
  this.footerRowModel = new FooterRowModel.Impl(component, initialiseCallback);
@@ -5117,10 +5276,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
5117
5276
  type: Directive
5118
5277
  }] });
5119
5278
 
5120
- class TableMoreMenuPopupComponent extends LoadableComponent {
5279
+ class TableCustomMoreMenuPopupComponent extends LoadableComponent {
5121
5280
  _value$ = this.registerDisposable(new DelegatingValueModel());
5122
5281
  _visible$ = this.registerDisposable(new DelegatingValueModel()).withDefault(true);
5123
5282
  _closeCommand = this.registerDisposable(new DelegatingCommand());
5283
+ constructor() {
5284
+ super();
5285
+ this.onInit(() => console.log('init'));
5286
+ }
5124
5287
  initialise(row$, closeCommand) {
5125
5288
  this._value$.setDelegate(row$);
5126
5289
  this._closeCommand.setDelegate(closeCommand);
@@ -5139,93 +5302,19 @@ class TableMoreMenuPopupComponent extends LoadableComponent {
5139
5302
  return this._value$.readonly$;
5140
5303
  }
5141
5304
  register(comp) {
5305
+ // ignored
5142
5306
  }
5143
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableMoreMenuPopupComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
5144
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableMoreMenuPopupComponent, selector: "aup-table-more-menu-popup", providers: [
5145
- { provide: POPUP_CONTAINER, useValue: TableMoreMenuPopupComponent },
5307
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCustomMoreMenuPopupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
5308
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableCustomMoreMenuPopupComponent, selector: "aup-table-more-menu-popup", providers: [
5309
+ { provide: POPUP_CONTAINER, useValue: TableCustomMoreMenuPopupComponent },
5146
5310
  ], usesInheritance: true, ngImport: i0, template: '', isInline: true });
5147
5311
  }
5148
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableMoreMenuPopupComponent, decorators: [{
5312
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCustomMoreMenuPopupComponent, decorators: [{
5149
5313
  type: Component,
5150
5314
  args: [{ selector: 'aup-table-more-menu-popup', template: '', providers: [
5151
- { provide: POPUP_CONTAINER, useValue: TableMoreMenuPopupComponent },
5315
+ { provide: POPUP_CONTAINER, useValue: TableCustomMoreMenuPopupComponent },
5152
5316
  ] }]
5153
- }] });
5154
-
5155
- class MenuItemData {
5156
- factory;
5157
- face;
5158
- constructor(factory, face) {
5159
- this.factory = factory;
5160
- this.face = face;
5161
- }
5162
- }
5163
- /**
5164
- *
5165
- */
5166
- class TableRowMenuComponent extends DisposableComponent {
5167
- value;
5168
- menu;
5169
- actions = [];
5170
- moreActions = [];
5171
- registerAction(commandFactory, properties) {
5172
- this.actions.push(new MenuItemData(commandFactory, properties));
5173
- }
5174
- registerMoreAction(commandFactory, properties) {
5175
- this.moreActions.push(new MenuItemData(commandFactory, properties));
5176
- }
5177
- constructor() {
5178
- super();
5179
- }
5180
- createMoreMenuCommand(item, value) {
5181
- const { when } = Dsl.disposeWith(this);
5182
- const command = item.factory.create(value, { disposedWith: this });
5183
- when(command.busy$).becomesFalsey(() => {
5184
- this.closeMoreMenu();
5185
- });
5186
- return command;
5187
- }
5188
- closeMoreMenu() {
5189
- this.menu.closeMenu();
5190
- }
5191
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableRowMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
5192
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableRowMenuComponent, selector: "aup-table-row-menu", inputs: { value: "value" }, viewQueries: [{ propertyName: "menu", first: true, predicate: MatMenuTrigger, descendants: true }], usesInheritance: true, ngImport: i0, template: `
5193
- <aup-tool-bar>
5194
- <aup-command *ngFor="let action of actions"
5195
- #comp
5196
- [command]="action.factory.create(value, {disposedWith: comp})"
5197
- [face]="action.face"></aup-command>
5198
- </aup-tool-bar>
5199
- <ng-container *ngIf="moreActions.length > 0">
5200
- <aup-more-menu>
5201
- <aup-command *ngFor="let action of moreActions" #comp [command]="action.factory.create(value, {disposedWith: comp})"
5202
- [face]="action.face"></aup-command>
5203
- </aup-more-menu>
5204
- </ng-container>
5205
- `, isInline: true, styles: [":host{display:inline-flex;flex-direction:row;align-items:center}\n"], dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ToolBarComponent, selector: "aup-tool-bar" }, { kind: "component", type: CommandComponent, selector: "aup-command", inputs: ["command", "face$", "face", "busyFace$", "busyFace", "alignFace"] }, { kind: "component", type: MoreMenuComponent, selector: "aup-more-menu", inputs: ["tooltip"] }] });
5206
- }
5207
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableRowMenuComponent, decorators: [{
5208
- type: Component,
5209
- args: [{ selector: 'aup-table-row-menu', template: `
5210
- <aup-tool-bar>
5211
- <aup-command *ngFor="let action of actions"
5212
- #comp
5213
- [command]="action.factory.create(value, {disposedWith: comp})"
5214
- [face]="action.face"></aup-command>
5215
- </aup-tool-bar>
5216
- <ng-container *ngIf="moreActions.length > 0">
5217
- <aup-more-menu>
5218
- <aup-command *ngFor="let action of moreActions" #comp [command]="action.factory.create(value, {disposedWith: comp})"
5219
- [face]="action.face"></aup-command>
5220
- </aup-more-menu>
5221
- </ng-container>
5222
- `, styles: [":host{display:inline-flex;flex-direction:row;align-items:center}\n"] }]
5223
- }], ctorParameters: function () { return []; }, propDecorators: { value: [{
5224
- type: Input
5225
- }], menu: [{
5226
- type: ViewChild,
5227
- args: [MatMenuTrigger]
5228
- }] } });
5317
+ }], ctorParameters: function () { return []; } });
5229
5318
 
5230
5319
  class TableFilterModel extends GarbageCollector {
5231
5320
  _source$ = this.registerDisposable(new DelegatingListModel());
@@ -6413,7 +6502,7 @@ class ComponentsModule {
6413
6502
  TableHeaderCellComponent,
6414
6503
  IconComponent,
6415
6504
  SectionHeaderComponent,
6416
- TableRowMenuComponent,
6505
+ TableActionColumnComponent,
6417
6506
  ToolBarComponent,
6418
6507
  CommandComponent,
6419
6508
  PopupMenuComponent,
@@ -6435,8 +6524,8 @@ class ComponentsModule {
6435
6524
  LoadingContainerComponent,
6436
6525
  MarkdownComponent,
6437
6526
  TableBodyComponent,
6438
- TableMoreMenuComponent,
6439
- TableMoreMenuPopupComponent,
6527
+ TableCustomMoreMenuComponent,
6528
+ TableCustomMoreMenuPopupComponent,
6440
6529
  SearchInputComponent,
6441
6530
  TableFooterRow,
6442
6531
  FileDownloadComponent,
@@ -6486,7 +6575,7 @@ class ComponentsModule {
6486
6575
  ColumnTemplateDirective,
6487
6576
  IconComponent,
6488
6577
  SectionHeaderComponent,
6489
- TableRowMenuComponent,
6578
+ TableActionColumnComponent,
6490
6579
  ToolBarComponent,
6491
6580
  CommandComponent,
6492
6581
  PopupMenuComponent,
@@ -6501,8 +6590,8 @@ class ComponentsModule {
6501
6590
  LabelledValueComponent,
6502
6591
  LoadingContainerComponent,
6503
6592
  MarkdownComponent,
6504
- TableMoreMenuComponent,
6505
- TableMoreMenuPopupComponent,
6593
+ TableCustomMoreMenuComponent,
6594
+ TableCustomMoreMenuPopupComponent,
6506
6595
  SearchInputComponent,
6507
6596
  ButtonRendererComponent] });
6508
6597
  static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: ComponentsModule, providers: [FocusBindingFactory, MarkdownService], imports: [CommonModule,
@@ -6588,7 +6677,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
6588
6677
  TableHeaderCellComponent,
6589
6678
  IconComponent,
6590
6679
  SectionHeaderComponent,
6591
- TableRowMenuComponent,
6680
+ TableActionColumnComponent,
6592
6681
  ToolBarComponent,
6593
6682
  CommandComponent,
6594
6683
  PopupMenuComponent,
@@ -6610,8 +6699,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
6610
6699
  LoadingContainerComponent,
6611
6700
  MarkdownComponent,
6612
6701
  TableBodyComponent,
6613
- TableMoreMenuComponent,
6614
- TableMoreMenuPopupComponent,
6702
+ TableCustomMoreMenuComponent,
6703
+ TableCustomMoreMenuPopupComponent,
6615
6704
  SearchInputComponent,
6616
6705
  TableFooterRow,
6617
6706
  FileDownloadComponent,
@@ -6643,7 +6732,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
6643
6732
  ColumnTemplateDirective,
6644
6733
  IconComponent,
6645
6734
  SectionHeaderComponent,
6646
- TableRowMenuComponent,
6735
+ TableActionColumnComponent,
6647
6736
  ToolBarComponent,
6648
6737
  CommandComponent,
6649
6738
  PopupMenuComponent,
@@ -6658,8 +6747,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
6658
6747
  LabelledValueComponent,
6659
6748
  LoadingContainerComponent,
6660
6749
  MarkdownComponent,
6661
- TableMoreMenuComponent,
6662
- TableMoreMenuPopupComponent,
6750
+ TableCustomMoreMenuComponent,
6751
+ TableCustomMoreMenuPopupComponent,
6663
6752
  SearchInputComponent,
6664
6753
  ButtonRendererComponent,
6665
6754
  ],
@@ -12975,5 +13064,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
12975
13064
  * Generated bundle index. Do not edit.
12976
13065
  */
12977
13066
 
12978
- export { ACTIVITY_DATA, ALERT_CONFIG, AUP_PLACE_CONFIG, AUP_TABLE_VIRTUAL_SCROLL_BUFFER_MULTIPLIER, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractCellRenderer, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityBodyComponent, ActivityContainerComponent, ActivityContext, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddCardActivityComponent, AddItemInteractionContextComponent, Alert, AlertDialogComponent, AlertRendererComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, ButtonRendererComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CellEditorPortalRef, CellFooterPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnManager, ColumnModel, ColumnOrderManager, ColumnTemplateDirective, ColumnTextSearchFormatter, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, Confirm, ConfirmRendererComponent, ConfirmThenDialogComponent, ConfirmThenExecuteDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControlsComponent, EditSession, EditorControlColumnModel, EmptyStateComponent, EnableCellTextSearch, EventCleanUpSession, FOOTER_CELL_RENDERER_PORTAL, FileDownloadComponent, FlattenedTreeListModel, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, FooterRowModel, Formatter, GarbageCollectorDirective, HEADER_CELL_RENDERER_PORTAL, HighlightPipe, HighlightTextModelDirective, HorizontalAlignment, INTERACTION_CONTEXT, IconComponent, InPlaceInteractionContextComponent, InlineActivityTriggerComponent, InlineEditorModel, InlineStringEditorComponent, InputActivity, InteractionContextProvider, InteractionContextTriggerForDirective, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, Keys, LEFT_RIGHT_PLACE_ANIMATION, LabelledValueComponent, ListPlaceNavComponent, ListPropertyColumnModel, LoadableComponent, LoadingContainerComponent, MarkdownComponent, MarkdownService, ModalActivityTriggerComponent, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NotAuthorisedNoticeComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, PaginatorComponent, ParameterDefinition, PasswordInputComponent, Place, PlaceAccessGuard, PlaceAuthService, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupActivityTriggerComponent, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, ResizeObserverDirective, RouteId, ScrollContainerComponent, SearchInputComponent, SectionHeaderComponent, SelectInputActivity, SelectInputComponent, SelectionCellComponent, SelectionColumnModel, SelectionHeaderCellComponent, SeparatorComponent, SidePlaceNavigationComponent, SlideDownInteractionContextComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableBodyComponent, TableCellComponent, TableComponent, TableFilterModel, TableFooterRow, TableHeaderCellComponent, TableModel, TableMoreMenuComponent, TableMoreMenuPopupComponent, TableRowAttributesDirective, TableRowMenuComponent, TemplateCellRendererPortalRef, TextInputComponent, TextSearchContext, ToolBarComponent, Track, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, VisibilityService, Visit, VisitParameter, VisitParameterList, VisitSegment, VisitSegmentSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, markdownPillExtension, slideDownAndRightOnEnterAnimation, slideDownOnEnterAnimation, slideDownWhenOpenAnimation, slideRightOnEnterAnimation, treeNodeDecorator };
13067
+ export { ACTIVITY_DATA, ALERT_CONFIG, AUP_PLACE_CONFIG, AUP_TABLE_VIRTUAL_SCROLL_BUFFER_MULTIPLIER, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractCellRenderer, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityBodyComponent, ActivityContainerComponent, ActivityContext, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddCardActivityComponent, AddItemInteractionContextComponent, Alert, AlertDialogComponent, AlertRendererComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, ButtonRendererComponent, CELL_EDITOR_PORTAL, CELL_RENDERER_PORTAL, CardContainerComponent, CellEditorPortalRef, CellFooterPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnManager, ColumnModel, ColumnOrderManager, ColumnTemplateDirective, ColumnTextSearchFormatter, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, Confirm, ConfirmRendererComponent, ConfirmThenDialogComponent, ConfirmThenExecuteDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EditRowControlsComponent, EditSession, EditorControlColumnModel, EmptyStateComponent, EnableCellTextSearch, EventCleanUpSession, FOOTER_CELL_RENDERER_PORTAL, FileDownloadComponent, FlattenedTreeListModel, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, FooterRowModel, Formatter, GarbageCollectorDirective, HEADER_CELL_RENDERER_PORTAL, HighlightPipe, HighlightTextModelDirective, HorizontalAlignment, INTERACTION_CONTEXT, IconComponent, InPlaceInteractionContextComponent, InlineActivityTriggerComponent, InlineEditorModel, InlineStringEditorComponent, InputActivity, InteractionContextProvider, InteractionContextTriggerForDirective, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, Keys, LEFT_RIGHT_PLACE_ANIMATION, LabelledValueComponent, ListPlaceNavComponent, ListPropertyColumnModel, LoadableComponent, LoadingContainerComponent, MarkdownComponent, MarkdownService, ModalActivityTriggerComponent, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NotAuthorisedNoticeComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_EDITOR_COMPONENT, PORTAL_RENDERER_COMPONENT, PaginatorComponent, ParameterDefinition, PasswordInputComponent, Place, PlaceAccessGuard, PlaceAuthService, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupActivityTriggerComponent, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, ResizeObserverDirective, RouteId, ScrollContainerComponent, SearchInputComponent, SectionHeaderComponent, SelectInputActivity, SelectInputComponent, SelectionCellComponent, SelectionColumnModel, SelectionHeaderCellComponent, SeparatorComponent, SidePlaceNavigationComponent, SlideDownInteractionContextComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableActionColumnComponent, TableBodyComponent, TableCellComponent, TableComponent, TableCustomMoreMenuComponent, TableCustomMoreMenuPopupComponent, TableFilterModel, TableFooterRow, TableHeaderCellComponent, TableModel, TableRowAttributesDirective, TemplateCellRendererPortalRef, TextInputComponent, TextSearchContext, ToolBarComponent, Track, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, VisibilityService, Visit, VisitParameter, VisitParameterList, VisitSegment, VisitSegmentSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, leftRightPlaceAnimation, markdownPillExtension, slideDownAndRightOnEnterAnimation, slideDownOnEnterAnimation, slideDownWhenOpenAnimation, slideRightOnEnterAnimation, treeNodeDecorator };
12979
13068
  //# sourceMappingURL=coolon-angular-ui-powerups.mjs.map