UNPKG

@netgrif/components

Version:

Netgrif Application Engine frontend Angular components

20 lines 7.59 kB
import { Component } from '@angular/core'; import { AbstractSearchClauseComponent } from '@netgrif/components-core'; import * as i0 from "@angular/core"; import * as i1 from "@angular/common"; import * as i2 from "@ngbracket/ngx-layout"; import * as i3 from "@angular/material/button"; import * as i4 from "../search-predicate-component/search-predicate.component"; import * as i5 from "@ngx-translate/core"; export class SearchClauseComponent extends AbstractSearchClauseComponent { constructor() { super(); } static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: SearchClauseComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: SearchClauseComponent, selector: "nc-search-clause", usesInheritance: true, ngImport: i0, template: "<div fxLayout=\"row wrap\" fxLayoutAlign=\"start center\">\n <div *ngFor=\"let item of getPredicateMap() | keyvalue; trackBy: trackByPredicates; first as first\" fxLayout=\"row\"\n fxLayoutAlign=\"start center\">\n <div *ngIf=\"!first\" class=\"bool-operator-margin\">{{'search.or' | translate | uppercase}}</div>\n <nc-search-predicate [predicate]=\"item.value.wrappedPredicate\" [predicateId]=\"item.key\"\n [remove$]=\"removeChild$\" [generator]=\"item.value.generator\"\n [editable]=\"editable\"></nc-search-predicate>\n </div>\n <button *ngIf=\"editable\" mat-stroked-button (click)=\"addChildPredicate()\" class=\"bool-operator-margin advanced-search-buttons\">+ {{'search.or' | translate | uppercase}}</button>\n</div>\n", styles: [".bool-operator-margin{margin:0 8px 0 4px}.bool-operator-button{margin-left:4px}.advanced-search-buttons{min-height:43px}.prefix-icon{color:#64748b}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.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: i2.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: "component", type: i3.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: i4.SearchPredicateComponent, selector: "nc-search-predicate" }, { kind: "pipe", type: i1.UpperCasePipe, name: "uppercase" }, { kind: "pipe", type: i1.KeyValuePipe, name: "keyvalue" }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }] }); } i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: SearchClauseComponent, decorators: [{ type: Component, args: [{ selector: 'nc-search-clause', template: "<div fxLayout=\"row wrap\" fxLayoutAlign=\"start center\">\n <div *ngFor=\"let item of getPredicateMap() | keyvalue; trackBy: trackByPredicates; first as first\" fxLayout=\"row\"\n fxLayoutAlign=\"start center\">\n <div *ngIf=\"!first\" class=\"bool-operator-margin\">{{'search.or' | translate | uppercase}}</div>\n <nc-search-predicate [predicate]=\"item.value.wrappedPredicate\" [predicateId]=\"item.key\"\n [remove$]=\"removeChild$\" [generator]=\"item.value.generator\"\n [editable]=\"editable\"></nc-search-predicate>\n </div>\n <button *ngIf=\"editable\" mat-stroked-button (click)=\"addChildPredicate()\" class=\"bool-operator-margin advanced-search-buttons\">+ {{'search.or' | translate | uppercase}}</button>\n</div>\n", styles: [".bool-operator-margin{margin:0 8px 0 4px}.bool-operator-button{margin-left:4px}.advanced-search-buttons{min-height:43px}.prefix-icon{color:#64748b}\n"] }] }], ctorParameters: () => [] }); //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2VhcmNoLWNsYXVzZS5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZXRncmlmLWNvbXBvbmVudHMvc3JjL2xpYi9zZWFyY2gvYWR2YW5jZWQtc2VhcmNoL3NlYXJjaC1jbGF1c2UtY29tcG9uZW50L3NlYXJjaC1jbGF1c2UuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmV0Z3JpZi1jb21wb25lbnRzL3NyYy9saWIvc2VhcmNoL2FkdmFuY2VkLXNlYXJjaC9zZWFyY2gtY2xhdXNlLWNvbXBvbmVudC9zZWFyY2gtY2xhdXNlLmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGlu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