@firestitch/list 9.11.1 → 9.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/app/classes/list-controller.d.ts +4 -2
  2. package/app/classes/reorder-controller.d.ts +2 -0
  3. package/app/components/body/row/inline-action/inline-action.component.d.ts +3 -0
  4. package/app/components/body/row/menu-action/menu-action.component.d.ts +9 -0
  5. package/app/components/list/list.component.d.ts +1 -0
  6. package/app/interfaces/listconfig.interface.d.ts +9 -0
  7. package/app/models/row-action.model.d.ts +4 -1
  8. package/bundles/firestitch-list.umd.js +112 -16
  9. package/bundles/firestitch-list.umd.js.map +1 -1
  10. package/bundles/firestitch-list.umd.min.js +2 -2
  11. package/bundles/firestitch-list.umd.min.js.map +1 -1
  12. package/esm2015/app/classes/list-controller.js +10 -3
  13. package/esm2015/app/classes/reorder-controller.js +12 -3
  14. package/esm2015/app/components/body/row/actions/actions.component.js +2 -2
  15. package/esm2015/app/components/body/row/inline-action/inline-action.component.js +10 -2
  16. package/esm2015/app/components/body/row/menu-action/menu-action.component.js +41 -0
  17. package/esm2015/app/components/list/list.component.js +12 -1
  18. package/esm2015/app/fs-list.module.js +5 -1
  19. package/esm2015/app/interfaces/listconfig.interface.js +1 -1
  20. package/esm2015/app/models/row-action.model.js +12 -2
  21. package/esm2015/firestitch-list.js +7 -6
  22. package/esm2015/public_api.js +1 -1
  23. package/esm5/app/classes/list-controller.js +18 -3
  24. package/esm5/app/classes/reorder-controller.js +12 -3
  25. package/esm5/app/components/body/row/actions/actions.component.js +2 -2
  26. package/esm5/app/components/body/row/inline-action/inline-action.component.js +10 -2
  27. package/esm5/app/components/body/row/menu-action/menu-action.component.js +42 -0
  28. package/esm5/app/components/list/list.component.js +13 -1
  29. package/esm5/app/fs-list.module.js +5 -1
  30. package/esm5/app/interfaces/listconfig.interface.js +1 -1
  31. package/esm5/app/models/row-action.model.js +12 -2
  32. package/esm5/firestitch-list.js +7 -6
  33. package/esm5/public_api.js +1 -1
  34. package/fesm2015/firestitch-list.js +94 -8
  35. package/fesm2015/firestitch-list.js.map +1 -1
  36. package/fesm5/firestitch-list.js +104 -8
  37. package/fesm5/firestitch-list.js.map +1 -1
  38. package/firestitch-list.d.ts +7 -6
  39. package/firestitch-list.metadata.json +1 -1
  40. package/package.json +1 -1
  41. package/public_api.d.ts +1 -1
@@ -15,6 +15,7 @@ import { ItemType, FilterComponent, ExternalParamsController as ExternalParamsCo
15
15
  import { FsScrollService, FsScrollModule } from '@firestitch/scroll';
16
16
  import { FsMenuModule } from '@firestitch/menu';
17
17
  import { FsPrompt, FsPromptModule } from '@firestitch/prompt';
18
+ import { FsFileModule } from '@firestitch/file';
18
19
  import { isString, isObject, isBoolean, isNumber, isFunction, get, cloneDeep, mergeWith, random, merge as merge$1 } from 'lodash-es';
19
20
  import { Subject, BehaviorSubject, Observable, merge, from, combineLatest, of } from 'rxjs';
20
21
  import { takeUntil, tap, take, map, debounceTime, switchMap, mapTo, catchError, distinctUntilChanged, shareReplay, skip, filter } from 'rxjs/operators';
@@ -325,6 +326,15 @@ class RowAction extends Model {
325
326
  return this.clickEvent(row, event, index, rowActionsRef, clickFn);
326
327
  };
327
328
  this._linkFn = value.link;
329
+ if (value.file) {
330
+ if (value.file.select) {
331
+ this.fileUploadFn = (selection, row, index) => {
332
+ value.file.select(selection, row, index);
333
+ };
334
+ }
335
+ this.fileUploadErrorFn = value.file.error;
336
+ this.fileMultiple = value.file.multiple;
337
+ }
328
338
  if (typeof value.label === 'function') {
329
339
  this._labelFn = value.label;
330
340
  this.label = '';
@@ -344,7 +354,8 @@ class RowAction extends Model {
344
354
  this.rowActions.forEach((action) => {
345
355
  action.checkShowStatus(row, index);
346
356
  });
347
- this.isShown = this.rowActions.some((action) => action.isShown);
357
+ const groupVisible = !this.show || this.show(row, index);
358
+ this.isShown = groupVisible && this.rowActions.some((action) => action.isShown);
348
359
  }
349
360
  else if (this.show) {
350
361
  this.isShown = this.show(row, index);
@@ -2429,6 +2440,7 @@ class List extends Model {
2429
2440
  // Empty state
2430
2441
  this.emptyStateEnabled = false;
2431
2442
  this.onDestroy$ = new Subject();
2443
+ this._filtersQuery = new BehaviorSubject(null);
2432
2444
  this._fromJSON(config);
2433
2445
  this.initialize(config);
2434
2446
  this._headerConfig = new StyleConfig(config.header);
@@ -2445,6 +2457,12 @@ class List extends Model {
2445
2457
  get hasSavedFilters() {
2446
2458
  return !!this.filterConfig.savedFilters;
2447
2459
  }
2460
+ get filtersQuery() {
2461
+ return this._filtersQuery.getValue();
2462
+ }
2463
+ get filtersQuery$() {
2464
+ return this._filtersQuery.asObservable();
2465
+ }
2448
2466
  fetchRemote(query) {
2449
2467
  const options = {
2450
2468
  state: this.dataController.operation,
@@ -2900,7 +2918,7 @@ class List extends Model {
2900
2918
  if (this.filterInitCb) {
2901
2919
  this.filterInitCb(filters);
2902
2920
  }
2903
- this.filtersQuery = filters;
2921
+ this._filtersQuery.next(filters);
2904
2922
  this.checkRestoreFilter();
2905
2923
  }
2906
2924
  /**
@@ -2912,7 +2930,7 @@ class List extends Model {
2912
2930
  if (this.filterChangeCb) {
2913
2931
  this.filterChangeCb(filterQuery, filterSort);
2914
2932
  }
2915
- this.filtersQuery = filterQuery;
2933
+ this._filtersQuery.next(filterQuery);
2916
2934
  this.restoreMode = false;
2917
2935
  // Restore option
2918
2936
  this.checkRestoreFilter();
@@ -3129,6 +3147,7 @@ let ReorderController = class ReorderController {
3129
3147
  this._enabled$ = new BehaviorSubject(false);
3130
3148
  this._manualReorderActivated$ = new BehaviorSubject(false);
3131
3149
  this._reorderDisabled$ = new BehaviorSubject(false);
3150
+ this._numberOfActiveFilters = 0;
3132
3151
  this._destroy$ = new Subject();
3133
3152
  }
3134
3153
  get enabled() {
@@ -3148,13 +3167,17 @@ let ReorderController = class ReorderController {
3148
3167
  return this._enabled$
3149
3168
  .pipe(map((enabled) => {
3150
3169
  return enabled && this.position === ReorderPosition.Left;
3151
- }), distinctUntilChanged(), shareReplay(), takeUntil(this._destroy$));
3170
+ }), map((enabled) => {
3171
+ return enabled && this._numberOfActiveFilters === 0;
3172
+ }), distinctUntilChanged(), shareReplay());
3152
3173
  }
3153
3174
  get rightReorderActivated$() {
3154
3175
  return this._enabled$
3155
3176
  .pipe(map((enabled) => {
3156
3177
  return enabled && this.position === ReorderPosition.Right;
3157
- }), distinctUntilChanged(), shareReplay(), takeUntil(this._destroy$));
3178
+ }), map((enabled) => {
3179
+ return enabled && this._numberOfActiveFilters === 0;
3180
+ }), distinctUntilChanged(), shareReplay());
3158
3181
  }
3159
3182
  get reorderDisabled$() {
3160
3183
  return this._reorderDisabled$.asObservable();
@@ -3263,6 +3286,10 @@ let ReorderController = class ReorderController {
3263
3286
  this._reorderDisabled$.next(true);
3264
3287
  this._actionsController.updateDisabledState();
3265
3288
  }
3289
+ setNunberOfActiveFilters(activeFilters) {
3290
+ this._numberOfActiveFilters = activeFilters;
3291
+ this.enabled = this.enabled;
3292
+ }
3266
3293
  };
3267
3294
  ReorderController = __decorate([
3268
3295
  Injectable(),
@@ -3731,6 +3758,7 @@ let FsListComponent = class FsListComponent {
3731
3758
  this._updateCustomizeAction(listConfig.actions);
3732
3759
  this.list = new List(this._el, listConfig, this.fsScroll, this.selectionDialog, this._router, this._route, this._persistance, this._inDialog);
3733
3760
  this._waitFirstLoad();
3761
+ this._listenFiltersQueryChange();
3734
3762
  this.reorderController.initWithConfig(config.reorder, this.list.dataController, this.list.actions);
3735
3763
  if (this.listColumnDirectives) {
3736
3764
  this.list.tranformTemplatesToColumns(this.listColumnDirectives);
@@ -3803,6 +3831,16 @@ let FsListComponent = class FsListComponent {
3803
3831
  this.cdRef.markForCheck();
3804
3832
  });
3805
3833
  }
3834
+ _listenFiltersQueryChange() {
3835
+ this.list.filtersQuery$
3836
+ .pipe(takeUntil(this.list.onDestroy$), takeUntil(this._destroy))
3837
+ .subscribe((value) => {
3838
+ if (value) {
3839
+ const activeFilters = Object.keys(value).length;
3840
+ this.reorderController.setNunberOfActiveFilters(activeFilters);
3841
+ }
3842
+ });
3843
+ }
3806
3844
  _configMergeCustomizer(objValue, srcValue) {
3807
3845
  if (Array.isArray(objValue)) {
3808
3846
  return objValue;
@@ -5027,7 +5065,7 @@ __decorate([
5027
5065
  FsRowActionsComponent = __decorate([
5028
5066
  Component({
5029
5067
  selector: 'fs-list-row-actions',
5030
- template: "<ng-container *ngIf=\"!restoreMode || (restoreMode && !restoreAction)\">\n <ng-container *ngFor=\"let action of inlineRowActions; trackBy: trackByFn\">\n <fs-list-row-inline-action class=\"row-inline-action row-inline-action-{{action.type}}\"\n [action]=\"action\"\n [ngClass]=\"{'mobile-hide': action.menu === undefined}\"\n (clicked)=\"actionClick(action, row, $event)\">\n </fs-list-row-inline-action>\n </ng-container>\n</ng-container>\n\n<!-- Menu -->\n<fs-menu class=\"row-menu-action\"\n *ngIf=\"menuRowActions.length || (restoreMode && restoreAction)\"\n (click)=\"clickOnTrigger($event)\"\n #menuRef\n>\n <!-- Case when we have usual menu actions -->\n <ng-container *ngIf=\"!restoreMode || (restoreMode && !restoreAction)\">\n <ng-container *ngFor=\"let action of inlineRowActions; trackBy: trackByFn\">\n <ng-template class=\"hidden-mobile-menu-action\"\n fs-menu-item\n [link]=\"action.routerLink?.link\"\n [queryParams]=\"action.routerLink?.queryParams\"\n [target]=\"action.routerLink?.target\"\n [hidden]=\"action.menu !== undefined && !action.isShown\">\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon>\n {{action.label}}\n </ng-template>\n </ng-container>\n\n <ng-container *ngFor=\"let action of menuRowActions; trackBy: trackByFn\">\n <ng-container *ngIf=\"action.isGroup else simpleMenuItem\">\n <fs-menu-group [label]=\"action.label\">\n <ng-container *ngFor=\"let subAction of action.rowActions\">\n <ng-template fs-menu-item\n [link]=\"subAction.routerLink?.link\"\n [queryParams]=\"subAction.routerLink?.queryParams\"\n [target]=\"subAction.routerLink?.target\"\n [hidden]=\"!subAction.isShown\"\n (click)=\"actionClick(subAction, row, $event, menuRef);\">\n <mat-icon *ngIf=\"subAction.icon\">{{subAction.icon}}</mat-icon>\n {{subAction.label}}\n </ng-template>\n </ng-container>\n </fs-menu-group>\n </ng-container>\n <ng-template #simpleMenuItem>\n <ng-template fs-menu-item\n [link]=\"action.routerLink?.link\"\n [queryParams]=\"action.routerLink?.queryParams\"\n [target]=\"action.routerLink?.target\"\n [hidden]=\"!action.isShown\"\n (click)=\"actionClick(action, row, $event, menuRef);\">\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon>\n {{action.label}}\n </ng-template>\n </ng-template>\n </ng-container>\n </ng-container>\n\n <!-- Case when we have restore mode enabled and must hide menu actions -->\n <ng-container *ngIf=\"restoreMode && restoreAction\">\n <ng-template fs-menu-item (click)=\"actionClick(restoreAction, row, $event, menuRef)\">\n <mat-icon *ngIf=\"restoreAction.icon\">{{restoreAction.icon}}</mat-icon>\n {{restoreAction.label}}\n </ng-template>\n </ng-container>\n</fs-menu>\n",
5068
+ template: "<ng-container *ngIf=\"!restoreMode || (restoreMode && !restoreAction)\">\n <ng-container *ngFor=\"let action of inlineRowActions; trackBy: trackByFn\">\n <fs-list-row-inline-action class=\"row-inline-action row-inline-action-{{action.type}}\"\n [action]=\"action\"\n [ngClass]=\"{'mobile-hide': action.menu === undefined}\"\n (clicked)=\"actionClick(action, row, $event)\"\n (fileSelect)=\"action.fileUploadFn($event, row, index)\">\n </fs-list-row-inline-action>\n </ng-container>\n</ng-container>\n\n<!-- Menu -->\n<fs-menu class=\"row-menu-action\"\n *ngIf=\"menuRowActions.length || (restoreMode && restoreAction)\"\n (click)=\"clickOnTrigger($event)\"\n #menuRef\n>\n <!-- Case when we have usual menu actions -->\n <ng-container *ngIf=\"!restoreMode || (restoreMode && !restoreAction)\">\n <ng-container *ngFor=\"let action of inlineRowActions; trackBy: trackByFn\">\n <ng-template class=\"hidden-mobile-menu-action\"\n fs-menu-item\n [link]=\"action.routerLink?.link\"\n [queryParams]=\"action.routerLink?.queryParams\"\n [target]=\"action.routerLink?.target\"\n [hidden]=\"action.menu !== undefined && !action.isShown\">\n <fs-list-row-menu-action\n [icon]=\"action.icon\"\n [label]=\"action.label\"\n [file]=\"!!action.fileUploadFn\"\n [fileMultiple]=\"action.fileMultiple\"\n (fileSelect)=\"action.fileUploadFn($event, row, index)\"\n (fileError)=\"action.fileUploadErrorFn && action.fileUploadErrorFn($event)\">\n </fs-list-row-menu-action>\n </ng-template>\n </ng-container>\n\n <ng-container *ngFor=\"let action of menuRowActions; trackBy: trackByFn\">\n <ng-container *ngIf=\"action.isGroup else simpleMenuItem\">\n <fs-menu-group [label]=\"action.label\">\n <ng-container *ngFor=\"let subAction of action.rowActions\">\n <ng-template fs-menu-item\n [link]=\"subAction.routerLink?.link\"\n [queryParams]=\"subAction.routerLink?.queryParams\"\n [target]=\"subAction.routerLink?.target\"\n [hidden]=\"!subAction.isShown\"\n (click)=\"actionClick(subAction, row, $event, menuRef);\">\n <fs-list-row-menu-action\n [icon]=\"subAction.icon\"\n [label]=\"subAction.label\"\n [file]=\"!!subAction.fileUploadFn\"\n [fileMultiple]=\"subAction.fileMultiple\"\n (fileSelect)=\"subAction.fileUploadFn($event, row, index)\"\n (fileError)=\"subAction.fileUploadErrorFn && subAction.fileUploadErrorFn($event)\">\n </fs-list-row-menu-action>\n </ng-template>\n </ng-container>\n </fs-menu-group>\n </ng-container>\n <ng-template #simpleMenuItem>\n <ng-template fs-menu-item\n [link]=\"action.routerLink?.link\"\n [queryParams]=\"action.routerLink?.queryParams\"\n [target]=\"action.routerLink?.target\"\n [hidden]=\"!action.isShown\"\n (click)=\"actionClick(action, row, $event, menuRef);\">\n <fs-list-row-menu-action\n [icon]=\"action.icon\"\n [label]=\"action.label\"\n [file]=\"!!action.fileUploadFn\"\n [fileMultiple]=\"action.fileMultiple\"\n (fileSelect)=\"action.fileUploadFn($event, row, index)\"\n (fileError)=\"action.fileUploadErrorFn && action.fileUploadErrorFn($event)\">\n </fs-list-row-menu-action>\n </ng-template>\n </ng-template>\n </ng-container>\n </ng-container>\n\n <!-- Case when we have restore mode enabled and must hide menu actions -->\n <ng-container *ngIf=\"restoreMode && restoreAction\">\n <ng-template fs-menu-item (click)=\"actionClick(restoreAction, row, $event, menuRef)\">\n <mat-icon *ngIf=\"restoreAction.icon\">{{restoreAction.icon}}</mat-icon>\n {{restoreAction.label}}\n </ng-template>\n </ng-container>\n</fs-menu>\n",
5031
5069
  changeDetection: ChangeDetectionStrategy.OnPush
5032
5070
  }),
5033
5071
  __metadata("design:paramtypes", [FsPrompt])
@@ -5037,10 +5075,14 @@ let FsRowInlineActionComponent = class FsRowInlineActionComponent {
5037
5075
  constructor(_fsPrompt) {
5038
5076
  this._fsPrompt = _fsPrompt;
5039
5077
  this.clicked = new EventEmitter();
5078
+ this.fileSelect = new EventEmitter();
5040
5079
  }
5041
5080
  actionClick(event) {
5042
5081
  this.clicked.emit(event);
5043
5082
  }
5083
+ fileSelected(event) {
5084
+ this.fileSelect.emit(event);
5085
+ }
5044
5086
  };
5045
5087
  FsRowInlineActionComponent.ctorParameters = () => [
5046
5088
  { type: FsPrompt }
@@ -5053,15 +5095,57 @@ __decorate([
5053
5095
  Output(),
5054
5096
  __metadata("design:type", Object)
5055
5097
  ], FsRowInlineActionComponent.prototype, "clicked", void 0);
5098
+ __decorate([
5099
+ Output(),
5100
+ __metadata("design:type", Object)
5101
+ ], FsRowInlineActionComponent.prototype, "fileSelect", void 0);
5056
5102
  FsRowInlineActionComponent = __decorate([
5057
5103
  Component({
5058
5104
  selector: 'fs-list-row-inline-action',
5059
- template: "<ng-container *ngIf=\"action.isShown\" [ngSwitch]=\"action.type\">\n <!-- Basic button -->\n <ng-container *ngSwitchCase=\"'basic'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-button\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-button\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Raised button -->\n <ng-container *ngSwitchCase=\"'raised'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-raised-button\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-raised-button\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Icon button -->\n <ng-container *ngSwitchCase=\"'icon'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-icon-button\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-icon-button\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Fab button -->\n <ng-container *ngSwitchCase=\"'fab'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-fab\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-fab\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Mini Fab button -->\n <ng-container *ngSwitchCase=\"'mini-fab'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-mini-fab\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-mini-fab\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <ng-template #buttonContent let-value=\"value\">\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon>\n {{action.label}}\n </ng-template>\n</ng-container>\n",
5105
+ template: "<ng-container *ngIf=\"action.isShown\" [ngSwitch]=\"action.type\">\n <!-- Basic button -->\n <ng-container *ngSwitchCase=\"'basic'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-button\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-button\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Raised button -->\n <ng-container *ngSwitchCase=\"'raised'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-raised-button\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-raised-button\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Icon button -->\n <ng-container *ngSwitchCase=\"'icon'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-icon-button\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-icon-button\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Fab button -->\n <ng-container *ngSwitchCase=\"'fab'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-fab\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-fab\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <!-- Mini Fab button -->\n <ng-container *ngSwitchCase=\"'mini-fab'\">\n <ng-container *ngIf=\"!action.routerLink; else link\">\n <button type=\"button\"\n mat-mini-fab\n (click)=\"actionClick($event)\"\n [ngClass]=\"action.classArray\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n </ng-container>\n <ng-template #link>\n <a mat-mini-fab\n [routerLink]=\"action.routerLink.link\"\n [queryParams]=\"action.routerLink.queryParams\">\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </a>\n </ng-template>\n </ng-container>\n\n <ng-template #buttonContent>\n <ng-container *ngIf=\"!action.fileUploadFn else uploadFileBtn\">\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon>\n {{action.label}}\n </ng-container>\n\n <ng-template #uploadFileBtn>\n <fs-file\n class=\"action-button\"\n [multiple]=\"action.fileMultiple\"\n (select)=\"fileSelected($event)\"\n (error)=\"action.fileUploadErrorFn && action.fileUploadErrorFn($event)\">\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon>\n {{action.label}}\n </fs-file>\n </ng-template>\n </ng-template>\n</ng-container>\n",
5060
5106
  changeDetection: ChangeDetectionStrategy.OnPush
5061
5107
  }),
5062
5108
  __metadata("design:paramtypes", [FsPrompt])
5063
5109
  ], FsRowInlineActionComponent);
5064
5110
 
5111
+ let FsRowMenuActionComponent = class FsRowMenuActionComponent {
5112
+ constructor() {
5113
+ this.fileSelect = new EventEmitter();
5114
+ this.fileError = new EventEmitter();
5115
+ }
5116
+ };
5117
+ __decorate([
5118
+ Input(),
5119
+ __metadata("design:type", String)
5120
+ ], FsRowMenuActionComponent.prototype, "icon", void 0);
5121
+ __decorate([
5122
+ Input(),
5123
+ __metadata("design:type", String)
5124
+ ], FsRowMenuActionComponent.prototype, "label", void 0);
5125
+ __decorate([
5126
+ Input(),
5127
+ __metadata("design:type", Boolean)
5128
+ ], FsRowMenuActionComponent.prototype, "file", void 0);
5129
+ __decorate([
5130
+ Input(),
5131
+ __metadata("design:type", Boolean)
5132
+ ], FsRowMenuActionComponent.prototype, "fileMultiple", void 0);
5133
+ __decorate([
5134
+ Output(),
5135
+ __metadata("design:type", Object)
5136
+ ], FsRowMenuActionComponent.prototype, "fileSelect", void 0);
5137
+ __decorate([
5138
+ Output(),
5139
+ __metadata("design:type", Object)
5140
+ ], FsRowMenuActionComponent.prototype, "fileError", void 0);
5141
+ FsRowMenuActionComponent = __decorate([
5142
+ Component({
5143
+ selector: 'fs-list-row-menu-action',
5144
+ template: "<ng-container *ngIf=\"!file else withFile\">\n <mat-icon *ngIf=\"icon\">{{icon}}</mat-icon>\n {{label}}\n</ng-container>\n\n<ng-template #withFile>\n <fs-file\n class=\"action-button\"\n [multiple]=\"fileMultiple\"\n (select)=\"fileSelect.emit($event)\"\n (error)=\"fileError.emit($event)\">\n <mat-icon *ngIf=\"icon\">{{icon}}</mat-icon>\n {{label}}\n </fs-file>\n</ng-template>\n",
5145
+ changeDetection: ChangeDetectionStrategy.OnPush
5146
+ })
5147
+ ], FsRowMenuActionComponent);
5148
+
5065
5149
  let FsListManageSavedFiltersComponent = class FsListManageSavedFiltersComponent {
5066
5150
  constructor(_externalParams) {
5067
5151
  this._externalParams = _externalParams;
@@ -5268,6 +5352,7 @@ FsListModule = FsListModule_1 = __decorate([
5268
5352
  FsPromptModule,
5269
5353
  MatDialogModule,
5270
5354
  MatTooltipModule,
5355
+ FsFileModule,
5271
5356
  ],
5272
5357
  declarations: [
5273
5358
  // Components
@@ -5275,6 +5360,7 @@ FsListModule = FsListModule_1 = __decorate([
5275
5360
  FsRowComponent,
5276
5361
  FsRowActionsComponent,
5277
5362
  FsRowInlineActionComponent,
5363
+ FsRowMenuActionComponent,
5278
5364
  FsCellComponent,
5279
5365
  FsFooterRowComponent,
5280
5366
  FsFooterCellComponent,
@@ -5333,5 +5419,5 @@ function FsListConfigFactory(config) {
5333
5419
  * Generated bundle index. Do not edit.
5334
5420
  */
5335
5421
 
5336
- export { ActionType, Column, FS_LIST_CONFIG, FS_LIST_DEFAULT_CONFIG, FsBodyComponent, FsCellComponent, FsFooterCellComponent, FsFooterComponent, FsFooterRowComponent, FsHeadCellComponent, FsHeadComponent, FsListCellDirective, FsListColumnDirective, FsListComponent, FsListEmptyStateDirective, FsListFooterDirective, FsListHeaderDirective, FsListModule, FsListState, FsPaginationComponent, FsRowComponent, FsStatusComponent, List, PaginationController, PaginationStrategy, ReorderController, ReorderPosition, ReorderStrategy, RowAction, RowType, SelectionChangeType, SelectionController, SortingController, SortingDirection, StyleConfig, FsListConfigFactory as ɵa, GroupExpandNotifierService as ɵb, PersistanceController as ɵc, FsListGroupCellDirective as ɵd, FsListGroupExpandTriggerDirective as ɵe, FsListDraggableListDirective as ɵf, FsRowActionsComponent as ɵg, FsRowInlineActionComponent as ɵh, FsListLoaderComponent as ɵi, FsListSavedFiltersComponent as ɵj, FsListManageSavedFiltersComponent as ɵk, FsListDraggableRowDirective as ɵl, CustomizeColsDialogComponent as ɵm };
5422
+ export { ActionType, Column, FS_LIST_CONFIG, FS_LIST_DEFAULT_CONFIG, FsBodyComponent, FsCellComponent, FsFooterCellComponent, FsFooterComponent, FsFooterRowComponent, FsHeadCellComponent, FsHeadComponent, FsListCellDirective, FsListColumnDirective, FsListComponent, FsListEmptyStateDirective, FsListFooterDirective, FsListHeaderDirective, FsListModule, FsListState, FsPaginationComponent, FsRowComponent, FsStatusComponent, List, PaginationController, PaginationStrategy, ReorderController, ReorderPosition, ReorderStrategy, RowAction, RowType, SelectionChangeType, SelectionController, SortingController, SortingDirection, StyleConfig, FsListConfigFactory as ɵa, GroupExpandNotifierService as ɵb, PersistanceController as ɵc, FsListGroupCellDirective as ɵd, FsListGroupExpandTriggerDirective as ɵe, FsListDraggableListDirective as ɵf, FsRowActionsComponent as ɵg, FsRowInlineActionComponent as ɵh, FsRowMenuActionComponent as ɵi, FsListLoaderComponent as ɵj, FsListSavedFiltersComponent as ɵk, FsListManageSavedFiltersComponent as ɵl, FsListDraggableRowDirective as ɵm, CustomizeColsDialogComponent as ɵn };
5337
5423
  //# sourceMappingURL=firestitch-list.js.map