@acorex/components 4.2.27 → 4.2.30
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/esm2020/lib/search-bar/search-bar.component.mjs +18 -9
- package/esm2020/lib/tab-page/tab-page-host.component.mjs +3 -2
- package/fesm2015/acorex-components.mjs +19 -9
- package/fesm2015/acorex-components.mjs.map +1 -1
- package/fesm2020/acorex-components.mjs +19 -9
- package/fesm2020/acorex-components.mjs.map +1 -1
- package/lib/search-bar/search-bar.component.d.ts +9 -0
- package/package.json +1 -1
|
@@ -10258,7 +10258,6 @@ class AXSearchBarComponent {
|
|
|
10258
10258
|
this._context = {};
|
|
10259
10259
|
}
|
|
10260
10260
|
set items(v) {
|
|
10261
|
-
debugger;
|
|
10262
10261
|
v.forEach((el) => {
|
|
10263
10262
|
if (el.value != null) {
|
|
10264
10263
|
this._filterItems.push({
|
|
@@ -10268,10 +10267,13 @@ class AXSearchBarComponent {
|
|
|
10268
10267
|
});
|
|
10269
10268
|
}
|
|
10270
10269
|
});
|
|
10271
|
-
this._items = _.chain(v)
|
|
10270
|
+
this._items = _.chain(v)
|
|
10271
|
+
.groupBy((x) => x.property.row)
|
|
10272
|
+
.map((value, key) => ({ row: key, items: value }))
|
|
10273
|
+
.value();
|
|
10272
10274
|
}
|
|
10273
10275
|
clearItem(name) {
|
|
10274
|
-
this._editors.find(e => e.property.property.name == name).clear();
|
|
10276
|
+
this._editors.find((e) => e.property.property.name == name).clear();
|
|
10275
10277
|
}
|
|
10276
10278
|
handleButtonClick() {
|
|
10277
10279
|
this.dropdown.toggle();
|
|
@@ -10284,13 +10286,21 @@ class AXSearchBarComponent {
|
|
|
10284
10286
|
this._filterItemsClone.push({
|
|
10285
10287
|
name: e.property.name,
|
|
10286
10288
|
title: e.property.title,
|
|
10287
|
-
value: e.value
|
|
10289
|
+
value: e.value,
|
|
10290
|
+
filterOptions: {
|
|
10291
|
+
filters: e.property.editorOptions.filters ? e.property.editorOptions.filters : null,
|
|
10292
|
+
logic: e.property.editorOptions.logic ? e.property.editorOptions.logic : null,
|
|
10293
|
+
ignoreCase: e.property.editorOptions.ignoreCase ? e.property.editorOptions.ignoreCase : null,
|
|
10294
|
+
joinType: e.property.editorOptions.joinType ? e.property.editorOptions.joinType : null,
|
|
10295
|
+
operator: e.property.editorOptions.operator ? e.property.editorOptions.operator : null,
|
|
10296
|
+
truncateDate: e.property.editorOptions.truncateDate ? e.property.editorOptions.truncateDate : null
|
|
10297
|
+
}
|
|
10288
10298
|
});
|
|
10289
10299
|
}
|
|
10290
10300
|
this.onValueChange.emit(e);
|
|
10291
10301
|
}
|
|
10292
10302
|
handleItemRemoveClick(item) {
|
|
10293
|
-
this._editors.forEach(e => {
|
|
10303
|
+
this._editors.forEach((e) => {
|
|
10294
10304
|
if (e.property.property.name == item.name) {
|
|
10295
10305
|
e.clear();
|
|
10296
10306
|
}
|
|
@@ -10303,7 +10313,7 @@ class AXSearchBarComponent {
|
|
|
10303
10313
|
this.onSearchValue.emit(this._filterItems);
|
|
10304
10314
|
}
|
|
10305
10315
|
clear() {
|
|
10306
|
-
this._editors.forEach(e => {
|
|
10316
|
+
this._editors.forEach((e) => {
|
|
10307
10317
|
e.clear();
|
|
10308
10318
|
});
|
|
10309
10319
|
this._filterItems = [];
|
|
@@ -10336,8 +10346,7 @@ class AXSearchBarComponent {
|
|
|
10336
10346
|
}
|
|
10337
10347
|
return className.toString().replace(/,/, ' ');
|
|
10338
10348
|
}
|
|
10339
|
-
ngOnInit() {
|
|
10340
|
-
}
|
|
10349
|
+
ngOnInit() { }
|
|
10341
10350
|
}
|
|
10342
10351
|
AXSearchBarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: AXSearchBarComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
10343
10352
|
AXSearchBarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: AXSearchBarComponent, selector: "ax-search-bar", inputs: { size: "size", disabled: "disabled", items: "items", rtl: "rtl" }, outputs: { onValueChange: "onValueChange", onSearchValue: "onSearchValue" }, viewQueries: [{ propertyName: "dropdown", first: true, predicate: ["dropdown"], descendants: true, static: true }, { propertyName: "_editors", predicate: AXPropertyEditorRendererDirective, descendants: true }], ngImport: i0, template: "<ax-drop-down [fitParent]=\"true\" [size]=\"size\" [showDropDownButton]=\"false\" icon=\"far fa-sliders-h\" #dropdown\r\n maxHeight=\"unset\">\r\n <ng-container start>\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n </ng-container>\r\n <ng-container header>\r\n <div class=\"ax chips-container\">\r\n <div class=\"chips\" *ngFor=\"let item of _filterItems\">\r\n <span class=\"chips-text\">\r\n <b>{{item.title}} :</b> {{item.value}}\r\n </span>\r\n <span class=\"close-icon\" (click)=\"handleItemRemoveClick(item)\">\r\n <i class=\"far fa-times close\"></i>\r\n </span>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-container panel>\r\n <div class=\"panel-box\">\r\n <div *ngFor=\"let item of _items\" class=\"row\">\r\n <div *ngFor=\"let prop of item.items\" class=\"{{renderCol(prop.property.col)}}\">\r\n <!-- <ax-form-group> -->\r\n <div *ngIf=\"prop.property.visible != false\">\r\n <ax-label>{{prop.property.title}}</ax-label>\r\n <ng-container ax-property-editor-renderer [property]=\"prop\" [context]=\"_context\"\r\n (onValueChange)=\"handleValueChange($event)\"></ng-container>\r\n </div>\r\n <!-- </ax-form-group> -->\r\n </div>\r\n </div>\r\n <div class=\"footer-button\">\r\n <ax-button (click)=\"search()\">{{'common.search' | trans}}</ax-button>\r\n <ax-button type=\"blank danger\" (click)=\"clear()\">{{'dataGrid.clearFilter' | trans}}</ax-button>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-container end>\r\n <ax-button end icon=\"far fa-sliders-h icon\" type=\"light blank\" [disabled]=\"disabled\" [size]=\"size\"\r\n [tabIndex]=\"-1\" (click)=\"handleButtonClick()\">{{'common.search' | trans}}</ax-button>\r\n </ng-container>\r\n\r\n</ax-drop-down>\r\n", styles: [".ax.chips-container{height:100%}.panel-box{padding:1rem}.panel-box .footer-button{margin-top:1rem;display:flex;align-items:center;gap:.5rem}\n"], components: [{ type: AXDropdownComponent, selector: "ax-drop-down", inputs: ["rtl", "readonly", "loading"], outputs: ["dropdownToggle", "onButtonClick"] }, { type: AXLabelComponent, selector: "ax-label", inputs: ["size"] }, { type: AXButtonComponent, selector: "ax-button", inputs: ["type", "icon", "submitBehavior", "cancelBehavior", "block", "loading", "selected"] }], directives: [{ type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: AXPropertyEditorRendererDirective, selector: "[ax-property-editor-renderer]", inputs: ["property", "validationForm", "context", "host", "groupId"], outputs: ["onValueChange"] }], pipes: { "trans": i1$2.AXTranslatorPipe } });
|
|
@@ -13486,7 +13495,8 @@ class AXTabPageHostComponent {
|
|
|
13486
13495
|
active() {
|
|
13487
13496
|
const func = this.componentRef?.instance?.onActivated;
|
|
13488
13497
|
if (func) {
|
|
13489
|
-
func();
|
|
13498
|
+
const f = func.bind(this.componentRef.instance);
|
|
13499
|
+
f();
|
|
13490
13500
|
}
|
|
13491
13501
|
}
|
|
13492
13502
|
async ngAfterViewInit() {
|