@firestitch/filter 9.9.1 → 9.9.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/interfaces/action.interface.d.ts +1 -0
- package/app/models/action.model.d.ts +1 -0
- package/bundles/firestitch-filter.umd.js +11 -4
- package/bundles/firestitch-filter.umd.js.map +1 -1
- package/bundles/firestitch-filter.umd.min.js +1 -1
- package/bundles/firestitch-filter.umd.min.js.map +1 -1
- package/esm2015/app/components/action-button/action-button.component.js +2 -2
- package/esm2015/app/components/action-kebab-actions/action-kebab-actions.component.js +2 -2
- package/esm2015/app/interfaces/action.interface.js +1 -1
- package/esm2015/app/models/action.model.js +2 -1
- package/esm2015/app/models/items/base-item.js +2 -2
- package/esm2015/app/services/external-params-controller.service.js +8 -2
- package/esm2015/app/services/items-store.service.js +2 -2
- package/esm5/app/components/action-button/action-button.component.js +2 -2
- package/esm5/app/components/action-kebab-actions/action-kebab-actions.component.js +2 -2
- package/esm5/app/interfaces/action.interface.js +1 -1
- package/esm5/app/models/action.model.js +2 -1
- package/esm5/app/models/items/base-item.js +2 -2
- package/esm5/app/services/external-params-controller.service.js +8 -2
- package/esm5/app/services/items-store.service.js +2 -2
- package/fesm2015/firestitch-filter.js +11 -4
- package/fesm2015/firestitch-filter.js.map +1 -1
- package/fesm5/firestitch-filter.js +11 -4
- package/fesm5/firestitch-filter.js.map +1 -1
- package/firestitch-filter.metadata.json +1 -1
- package/package.json +1 -1
|
@@ -494,6 +494,7 @@
|
|
|
494
494
|
});
|
|
495
495
|
BaseItem.prototype.loadDefaultValue = function () {
|
|
496
496
|
var _this = this;
|
|
497
|
+
this._pendingDefaultValue = true;
|
|
497
498
|
return this.defaultValueFn()
|
|
498
499
|
.pipe(operators.tap(function (value) {
|
|
499
500
|
_this.defaultValue = value;
|
|
@@ -566,7 +567,6 @@
|
|
|
566
567
|
this.label = item.label;
|
|
567
568
|
this.chipLabel = item.chipLabel;
|
|
568
569
|
if (typeof item.default === 'function') {
|
|
569
|
-
this._pendingDefaultValue = true;
|
|
570
570
|
this.defaultValueFn = item.default;
|
|
571
571
|
}
|
|
572
572
|
else {
|
|
@@ -1869,7 +1869,7 @@
|
|
|
1869
1869
|
var _this = this;
|
|
1870
1870
|
var pendingItems = this.items
|
|
1871
1871
|
.filter(function (item) {
|
|
1872
|
-
return item.
|
|
1872
|
+
return item.defaultValueFn
|
|
1873
1873
|
&& (item.persistedValue === null || item.persistedValue === undefined);
|
|
1874
1874
|
});
|
|
1875
1875
|
if (pendingItems.length > 0) {
|
|
@@ -2692,6 +2692,12 @@
|
|
|
2692
2692
|
};
|
|
2693
2693
|
ExternalParamsController.prototype._listenItemsChange = function () {
|
|
2694
2694
|
var _this = this;
|
|
2695
|
+
this._itemsStore.ready$
|
|
2696
|
+
.pipe(operators.filter(function (v) { return v; }), operators.take(1), operators.takeUntil(this._destroy$))
|
|
2697
|
+
.subscribe(function () {
|
|
2698
|
+
_this._saveQueryParams();
|
|
2699
|
+
_this._savePersistedParams();
|
|
2700
|
+
});
|
|
2695
2701
|
this._itemsStore
|
|
2696
2702
|
.itemsChange$
|
|
2697
2703
|
.pipe(operators.takeUntil(this._destroy$))
|
|
@@ -3219,6 +3225,7 @@
|
|
|
3219
3225
|
this.label = config.label;
|
|
3220
3226
|
this.mode = config.mode;
|
|
3221
3227
|
this.icon = config.icon;
|
|
3228
|
+
this.iconPlacement = config.iconPlacement;
|
|
3222
3229
|
this._showFn = config.show;
|
|
3223
3230
|
this.tabIndex = (_d = config.tabIndex) !== null && _d !== void 0 ? _d : 0;
|
|
3224
3231
|
if (config.multiple !== undefined) {
|
|
@@ -5147,7 +5154,7 @@
|
|
|
5147
5154
|
FsFilterActionButtonComponent = __decorate([
|
|
5148
5155
|
core.Component({
|
|
5149
5156
|
selector: 'fs-filter-action-button',
|
|
5150
|
-
template: "<ng-container [ngSwitch]=\"action.type\">\n <!-- Basic button -->\n <button type=\"button\"\n *ngSwitchCase=\"'basic'\"\n mat-button\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Raised button -->\n <button type=\"button\"\n *ngSwitchDefault\n mat-raised-button\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Icon button -->\n <button type=\"button\"\n *ngSwitchCase=\"'icon'\"\n mat-icon-button\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Fab button -->\n <button type=\"button\"\n *ngSwitchCase=\"'fab'\"\n mat-fab\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Mini Fab button -->\n <button type=\"button\"\n *ngSwitchCase=\"'mini-fab'\"\n mat-mini-fab\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <ng-template #buttonContent>\n <mat-icon *ngIf=\"action.
|
|
5157
|
+
template: "<ng-container [ngSwitch]=\"action.type\">\n <!-- Basic button -->\n <button type=\"button\"\n *ngSwitchCase=\"'basic'\"\n mat-button\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Raised button -->\n <button type=\"button\"\n *ngSwitchDefault\n mat-raised-button\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Icon button -->\n <button type=\"button\"\n *ngSwitchCase=\"'icon'\"\n mat-icon-button\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Fab button -->\n <button type=\"button\"\n *ngSwitchCase=\"'fab'\"\n mat-fab\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <!-- Mini Fab button -->\n <button type=\"button\"\n *ngSwitchCase=\"'mini-fab'\"\n mat-mini-fab\n (click)=\"action.click && action.click($event)\"\n [color]=\"action.color\"\n [ngClass]=\"action.classArray\"\n [disabled]=\"action.disabled$ | async\"\n [tabIndex]=\"action.tabIndex\"\n >\n <ng-template [ngTemplateOutlet]=\"buttonContent\"></ng-template>\n </button>\n\n <ng-template #buttonContent>\n <ng-container *ngIf=\"!action.icon else withIcon\">\n {{action.label}}\n </ng-container>\n\n <ng-template #withIcon>\n <mat-icon *ngIf=\"!action.iconPlacement || action.iconPlacement === 'left'\">{{action.icon}}</mat-icon>\n {{action.label}}\n <mat-icon *ngIf=\"action.iconPlacement === 'right'\">{{action.icon}}</mat-icon>\n </ng-template>\n </ng-template>\n</ng-container>\n",
|
|
5151
5158
|
host: {
|
|
5152
5159
|
class: 'action-button',
|
|
5153
5160
|
},
|
|
@@ -5167,7 +5174,7 @@
|
|
|
5167
5174
|
FsFilterActionKebabActionsComponent = __decorate([
|
|
5168
5175
|
core.Component({
|
|
5169
5176
|
selector: 'fs-filter-action-kebab-actions',
|
|
5170
|
-
template: "<button type=\"button\"\n mat-icon-button\n class=\"menu-button\"\n [fsMenuTriggerFor]=\"kebabActionsMenu\">\n <mat-icon>more_vert</mat-icon>\n</button>\n<fs-menu #kebabActionsMenu>\n <ng-container *ngFor=\"let action of kebabActions\">\n <ng-container [ngSwitch]=\"action.mode\">\n <!-- Case when actions was collapsed from action with mode = 'menu'-->\n <ng-container *ngSwitchCase=\"'menu'\">\n <ng-container *ngFor=\"let childAction of action.items\">\n <ng-container *ngIf=\"childAction.isGroup else simpleMenuItem\">\n <fs-menu-group>\n <ng-template fs-group-menu-item-template>\n {{ action.label }} <mat-icon style=\"margin: 0;\">arrow_right</mat-icon> {{childAction.label}}\n </ng-template>\n <ng-container *ngFor=\"let subAction of childAction.items\">\n <ng-template fs-menu-item\n [link]=\"subAction.routerLink?.link\"\n [queryParams]=\"subAction.routerLink?.queryParams\"\n [hidden]=\"!(subAction.visible$ | async)\"\n (click)=\"subAction.click($event)\">\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]=\"childAction.routerLink?.link\"\n [queryParams]=\"childAction.routerLink?.queryParams\"\n [hidden]=\"!(childAction.visible$ | async)\"\n (click)=\"childAction.click($event);\">\n <mat-icon *ngIf=\"childAction.icon\">{{childAction.icon}}</mat-icon>\n {{ action.label }} <mat-icon style=\"margin: 0;\">arrow_right</mat-icon>{{ childAction.label }}\n </ng-template>\n </ng-template>\n </ng-container>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <ng-template fs-menu-item\n (click)=\"action.click($event)\"\n [fsClass]=\"action.classArray\"\n >\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon> {{action.label}}\n </ng-template>\n </ng-container>\n\n </ng-container>\n </ng-container>\n</fs-menu>\n",
|
|
5177
|
+
template: "<button type=\"button\"\n mat-icon-button\n class=\"menu-button\"\n [fsMenuTriggerFor]=\"kebabActionsMenu\">\n <mat-icon>more_vert</mat-icon>\n</button>\n<fs-menu #kebabActionsMenu>\n <ng-container *ngFor=\"let action of kebabActions\">\n <ng-container [ngSwitch]=\"action.mode\">\n <!-- Case when actions was collapsed from action with mode = 'menu'-->\n <ng-container *ngSwitchCase=\"'menu'\">\n <ng-container *ngFor=\"let childAction of action.items\">\n <ng-container *ngIf=\"childAction.isGroup else simpleMenuItem\">\n <fs-menu-group>\n <ng-template fs-group-menu-item-template>\n {{ action.label }} <mat-icon style=\"margin: 0;\">arrow_right</mat-icon> {{childAction.label}}\n </ng-template>\n <ng-container *ngFor=\"let subAction of childAction.items\">\n <ng-template fs-menu-item\n [link]=\"subAction.routerLink?.link\"\n [queryParams]=\"subAction.routerLink?.queryParams\"\n [hidden]=\"!(subAction.visible$ | async)\"\n (click)=\"subAction.click($event)\">\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]=\"childAction.routerLink?.link\"\n [queryParams]=\"childAction.routerLink?.queryParams\"\n [hidden]=\"!(childAction.visible$ | async)\"\n (click)=\"childAction.click($event);\">\n <mat-icon *ngIf=\"childAction.icon\">{{childAction.icon}}</mat-icon>\n {{ action.label }} <mat-icon style=\"margin: 0;\">arrow_right</mat-icon>{{ childAction.label }}\n </ng-template>\n </ng-template>\n </ng-container>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'file'\">\n <ng-template fs-menu-item\n [fsClass]=\"action.classArray\"\n >\n <fs-file\n class=\"action-button\"\n [multiple]=\"action.multiple\"\n (select)=\"action.fileSelected($event)\"\n (error)=\"action.fileError($event)\"\n (clicked)=\"action.click($event)\">\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon> {{action.label}}\n </fs-file>\n </ng-template>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <ng-template fs-menu-item\n (click)=\"action.click($event)\"\n [fsClass]=\"action.classArray\"\n >\n <mat-icon *ngIf=\"action.icon\">{{action.icon}}</mat-icon> {{action.label}}\n </ng-template>\n </ng-container>\n\n </ng-container>\n </ng-container>\n</fs-menu>\n",
|
|
5171
5178
|
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
|
5172
5179
|
styles: [".menu-button{width:36px;height:36px;line-height:36px}"]
|
|
5173
5180
|
})
|