ngx-angular-query-builder 0.0.2 → 0.0.3
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/README.md +1 -3
- package/bundles/ngx-angular-query-builder.umd.js +2 -2
- package/bundles/ngx-angular-query-builder.umd.js.map +1 -1
- package/esm2015/lib/query-builder/query-builder.component.js +3 -3
- package/fesm2015/ngx-angular-query-builder.js +2 -2
- package/fesm2015/ngx-angular-query-builder.js.map +1 -1
- package/package.json +1 -1
|
@@ -778,7 +778,7 @@ class QueryBuilderComponent {
|
|
|
778
778
|
}
|
|
779
779
|
}
|
|
780
780
|
QueryBuilderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: QueryBuilderComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
781
|
-
QueryBuilderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.13", type: QueryBuilderComponent, selector: "query-builder", inputs: { disabled: "disabled", data: "data", allowRuleset: "allowRuleset", allowCollapse: "allowCollapse", emptyMessage: "emptyMessage", classNames: "classNames", operatorMap: "operatorMap", parentValue: "parentValue", config: "config", parentArrowIconTemplate: "parentArrowIconTemplate", parentInputTemplates: "parentInputTemplates", parentOperatorTemplate: "parentOperatorTemplate", parentFieldTemplate: "parentFieldTemplate", parentEntityTemplate: "parentEntityTemplate", parentSwitchGroupTemplate: "parentSwitchGroupTemplate", parentButtonGroupTemplate: "parentButtonGroupTemplate", parentRemoveButtonTemplate: "parentRemoveButtonTemplate", parentEmptyWarningTemplate: "parentEmptyWarningTemplate", parentChangeCallback: "parentChangeCallback", parentTouchedCallback: "parentTouchedCallback", persistValueOnFieldChange: "persistValueOnFieldChange", value: "value" }, host: { properties: { "attr.query-builder-condition": "this.condintion" } }, providers: [CONTROL_VALUE_ACCESSOR, VALIDATOR], queries: [{ propertyName: "buttonGroupTemplate", first: true, predicate: QueryButtonGroupDirective, descendants: true }, { propertyName: "switchGroupTemplate", first: true, predicate: QuerySwitchGroupDirective, descendants: true }, { propertyName: "fieldTemplate", first: true, predicate: QueryFieldDirective, descendants: true }, { propertyName: "entityTemplate", first: true, predicate: QueryEntityDirective, descendants: true }, { propertyName: "operatorTemplate", first: true, predicate: QueryOperatorDirective, descendants: true }, { propertyName: "removeButtonTemplate", first: true, predicate: QueryRemoveButtonDirective, descendants: true }, { propertyName: "emptyWarningTemplate", first: true, predicate: QueryEmptyWarningDirective, descendants: true }, { propertyName: "arrowIconTemplate", first: true, predicate: QueryArrowIconDirective, descendants: true }, { propertyName: "inputTemplates", predicate: QueryInputDirective }], viewQueries: [{ propertyName: "treeContainer", first: true, predicate: ["treeContainer"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div [ngClass]=\"getClassNames('switchRow')\">\n <ng-template #defaultArrowIcon>\n <i [ngClass]=\"getClassNames('arrowIcon')\"></i>\n </ng-template>\n\n <a *ngIf=\"allowCollapse\" (click)=\"toggleCollapse()\" [ngClass]=\"getClassNames('arrowIconButton', data.collapsed ? 'collapsed' : '')\">\n <ng-container *ngIf=\"getArrowIconTemplate() as template; else defaultArrowIcon\">\n <ng-container *ngTemplateOutlet=\"template; context: getArrowIconContext()\"></ng-container>\n </ng-container>\n </a>\n\n <ng-container *ngIf=\"getButtonGroupTemplate() as template; else defaultButtonGroup\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getButtonGroupContext()\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultButtonGroup>\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <button type=\"button\" (click)=\"addRule()\" [ngClass]=\"getClassNames('button')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Rule\n </button>\n <button type=\"button\" (click)=\"addRuleSet()\" [ngClass]=\"getClassNames('button')\" *ngIf=\"allowRuleset\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Ruleset\n </button>\n <ng-container *ngIf=\"!!parentValue && allowRuleset\">\n <button type=\"button\" (click)=\"removeRuleSet()\" [ngClass]=\"getClassNames('button', 'removeButton')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </ng-container>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getSwitchGroupTemplate() as template; else defaultSwitchGroup\">\n <ng-container *ngTemplateOutlet=\"template; context: getSwitchGroupContext()\"></ng-container>\n </ng-container>\n\n <ng-template #defaultSwitchGroup>\n <div [ngClass]=\"getClassNames('switchGroup', 'transition')\" *ngIf=\"data\">\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"and\" #andOption />\n <label (click)=\"changeCondition(andOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">AND</label>\n </div>\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"or\" #orOption />\n <label (click)=\"changeCondition(orOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">OR</label>\n </div>\n </div>\n </ng-template>\n</div>\n\n<div #treeContainer (transitionend)=\"transitionEnd($event)\" [ngClass]=\"getClassNames('treeContainer', data.collapsed ? 'collapsed' : '')\">\n <ul [ngClass]=\"getClassNames('tree')\" *ngIf=\"data && data.rules\">\n <ng-container *ngFor=\"let rule of data.rules;let i=index\">\n\n <ng-container *ngIf=\"{ruleset: !!rule.rules, invalid: !config.allowEmptyRulesets && rule.rules && rule.rules.length === 0} as local\">\n <li [ngClass]=\"getQueryItemClassName(local)\">\n <ng-container *ngIf=\"!local.ruleset\">\n\n <ng-container *ngIf=\"getRemoveButtonTemplate() as template; else defaultRemoveButton\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getRemoveButtonContext(rule)\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultRemoveButton>\n <div [ngClass]=\"getClassNames('removeButtonSize', 'rightAlign')\">\n <button type=\"button\" [ngClass]=\"getClassNames('button', 'removeButton')\" (click)=\"removeRule(rule, data)\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </div>\n </ng-template>\n\n <div *ngIf=\"entities?.length\" class=\"q-inline-block-display\">\n <ng-container *ngIf=\"getEntityTemplate() as template; else defaultEntity\">\n <ng-container *ngTemplateOutlet=\"template; context: getEntityContext(rule)\"></ng-container>\n </ng-container>\n </div>\n\n <ng-template #defaultEntity>\n <div [ngClass]=\"getClassNames('entityControlSize')\">\n <select [ngClass]=\"getClassNames('entityControl')\" [(ngModel)]=\"rule.entity\" (ngModelChange)=\"changeEntity($event, rule,i,data)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let entity of entities\" [ngValue]=\"entity.value\">\n {{entity.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getFieldTemplate() as template; else defaultField\">\n <ng-container *ngTemplateOutlet=\"template; context: getFieldContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultField>\n <div [ngClass]=\"getClassNames('fieldControlSize')\">\n <select [ngClass]=\"getClassNames('fieldControl')\" [(ngModel)]=\"rule.field\" (ngModelChange)=\"changeField($event, rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let field of getFields(rule.entity)\" [ngValue]=\"field.value\">\n {{field.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getOperatorTemplate() as template; else defaultOperator\">\n <ng-container *ngTemplateOutlet=\"template; context: getOperatorContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultOperator>\n <div [ngClass]=\"getClassNames('operatorControlSize')\">\n <select [ngClass]=\"getClassNames('operatorControl')\" [(ngModel)]=\"rule.operator\" (ngModelChange)=\"changeOperator(rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let operator of getOperators(rule.field)\" [ngValue]=\"operator\">\n {{operator}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"findTemplateForRule(rule) as template; else defaultInput\">\n <ng-container *ngTemplateOutlet=\"template; context: getInputContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultInput>\n <div [ngClass]=\"getClassNames('inputControlSize')\" [ngSwitch]=\"getInputType(rule.field, rule.operator)\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'string'\" type=\"text\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'number'\" type=\"number\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'date'\" type=\"date\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'time'\" type=\"time\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'category'\">\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n <ng-container *ngSwitchCase=\"'multiselect'\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" multiple>\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n </ng-container>\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'boolean'\" type=\"checkbox\">\n </div>\n </ng-template>\n\n </ng-container>\n <query-builder *ngIf=\"local.ruleset\" [data]=\"rule\" [disabled]=\"disabled\" [parentTouchedCallback]=\"parentTouchedCallback || onTouchedCallback\"\n [parentChangeCallback]=\"parentChangeCallback || onChangeCallback\" [parentInputTemplates]=\"parentInputTemplates || inputTemplates\"\n [parentOperatorTemplate]=\"parentOperatorTemplate || operatorTemplate\" [parentFieldTemplate]=\"parentFieldTemplate || fieldTemplate\"\n [parentEntityTemplate]=\"parentEntityTemplate || entityTemplate\" [parentSwitchGroupTemplate]=\"parentSwitchGroupTemplate || switchGroupTemplate\"\n [parentButtonGroupTemplate]=\"parentButtonGroupTemplate || buttonGroupTemplate\" [parentRemoveButtonTemplate]=\"parentRemoveButtonTemplate || removeButtonTemplate\"\n [parentEmptyWarningTemplate]=\"parentEmptyWarningTemplate || emptyWarningTemplate\" [parentArrowIconTemplate]=\"parentArrowIconTemplate || arrowIconTemplate\"\n [parentValue]=\"data\" [classNames]=\"classNames\" [config]=\"config\" [allowRuleset]=\"allowRuleset\"\n [allowCollapse]=\"allowCollapse\" [emptyMessage]=\"emptyMessage\" [operatorMap]=\"operatorMap\">\n </query-builder>\n\n <ng-container *ngIf=\"getEmptyWarningTemplate() as template; else defaultEmptyWarning\">\n <ng-container *ngIf=\"local.invalid\">\n <ng-container *ngTemplateOutlet=\"template; context: getEmptyWarningContext()\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-template #defaultEmptyWarning>\n <p [ngClass]=\"getClassNames('emptyWarning')\" *ngIf=\"local.invalid\">\n {{emptyMessage}}\n </p>\n </ng-template>\n </li>\n </ng-container>\n </ng-container>\n </ul>\n</div>\n", styles: ["@charset \"UTF-8\";:host{display:block;width:100%}:host .q-icon{font-style:normal;font-size:12px}:host .q-remove-icon:before{content:\"\\274c\"}:host .q-arrow-icon-button{float:left;margin:4px 6px 4px 0;transform:rotate(90deg);transition:linear .25s transform;cursor:pointer}:host .q-arrow-icon-button.q-collapsed{transform:rotate(0)}:host .q-arrow-icon:before{content:\"\\25b6\"}:host .q-add-icon{color:#555}:host .q-add-icon:before{content:\"\\2795\"}:host .q-remove-button{color:#b3415d;width:31px}:host .q-switch-group,:host .q-button-group{font-family:\"Lucida Grande\",Tahoma,Verdana,sans-serif;overflow:hidden}:host .q-right-align{float:right}:host .q-button{margin-left:8px;padding:0 8px;background-color:#fff}:host .q-button:disabled{display:none}:host .q-control-size{display:inline-block;vertical-align:top;padding-right:10px}:host .q-input-control,:host .q-operator-control,:host .q-field-control,:host .q-entity-control{display:inline-block;padding:5px 8px;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;box-sizing:border-box;width:auto;min-width:180px}:host .q-input-control:disabled,:host .q-operator-control:disabled,:host .q-field-control:disabled,:host .q-entity-control:disabled{border-color:transparent}:host .q-operator-control,:host .q-field-control,:host .q-entity-control,:host .q-input-control:not([type=checkbox]){min-height:32px;-webkit-appearance:none}:host .q-switch-label,:host .q-button{float:left;margin-bottom:0;font-size:14px;line-height:30px;font-weight:normal;text-align:center;text-shadow:none;border:1px solid rgba(0,0,0,.2);box-sizing:border-box}:host .q-switch-label:hover,:host .q-button:hover{cursor:pointer;background-color:#f0f0f0}:host .q-switch-label{background-color:#e4e4e4;padding:0 8px}:host .q-switch-radio{position:absolute;clip:rect(0,0,0,0);height:1px;width:1px;border:0;overflow:hidden}:host .q-switch-radio:checked+.q-switch-label{border:1px solid #619ed7;background:white;color:#3176b3}:host .q-switch-radio:disabled+.q-switch-label{display:none}:host .q-switch-radio:checked:disabled+.q-switch-label{display:initial;color:initial;cursor:default;border-color:transparent}:host .q-invalid-ruleset{border:1px solid rgba(179,65,93,.5)!important;background:rgba(179,65,93,.1)!important}:host .q-empty-warning{color:#8d252e;text-align:center}:host .q-ruleset{border:1px solid #CCC}:host .q-rule{border:1px solid #CCC;background:white}:host .q-transition{transition:all .1s ease-in-out}:host .q-tree-container{width:100%;overflow:hidden;transition:ease-in .25s max-height}:host .q-tree-container.q-collapsed{max-height:0!important}:host .q-tree{list-style:none;margin:4px 0 2px}:host .q-row{padding:6px 8px;margin-top:6px}:host .q-connector{position:relative}:host .q-connector:before{top:-5px;border-width:0 0 2px 2px}:host .q-connector:after{border-width:0 0 0 2px;top:50%}:host .q-connector:before,:host .q-connector:after{content:\"\";left:-12px;border-color:#ccc;border-style:solid;width:9px;height:calc(50% + 6px);position:absolute}:host .q-connector:last-child:after{content:none}:host .q-inline-block-display{display:inline-block;vertical-align:top}\n"], components: [{ type: QueryBuilderComponent, selector: "query-builder", inputs: ["disabled", "data", "allowRuleset", "allowCollapse", "emptyMessage", "classNames", "operatorMap", "parentValue", "config", "parentArrowIconTemplate", "parentInputTemplates", "parentOperatorTemplate", "parentFieldTemplate", "parentEntityTemplate", "parentSwitchGroupTemplate", "parentButtonGroupTemplate", "parentRemoveButtonTemplate", "parentEmptyWarningTemplate", "parentChangeCallback", "parentTouchedCallback", "persistValueOnFieldChange", "value"] }], directives: [{ type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i2.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i2.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i2.SelectMultipleControlValueAccessor, selector: "select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]", inputs: ["compareWith"] }, { type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }] });
|
|
781
|
+
QueryBuilderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.13", type: QueryBuilderComponent, selector: "query-builder", inputs: { disabled: "disabled", data: "data", allowRuleset: "allowRuleset", allowCollapse: "allowCollapse", emptyMessage: "emptyMessage", classNames: "classNames", operatorMap: "operatorMap", parentValue: "parentValue", config: "config", parentArrowIconTemplate: "parentArrowIconTemplate", parentInputTemplates: "parentInputTemplates", parentOperatorTemplate: "parentOperatorTemplate", parentFieldTemplate: "parentFieldTemplate", parentEntityTemplate: "parentEntityTemplate", parentSwitchGroupTemplate: "parentSwitchGroupTemplate", parentButtonGroupTemplate: "parentButtonGroupTemplate", parentRemoveButtonTemplate: "parentRemoveButtonTemplate", parentEmptyWarningTemplate: "parentEmptyWarningTemplate", parentChangeCallback: "parentChangeCallback", parentTouchedCallback: "parentTouchedCallback", persistValueOnFieldChange: "persistValueOnFieldChange", value: "value" }, host: { properties: { "attr.query-builder-condition": "this.condintion" } }, providers: [CONTROL_VALUE_ACCESSOR, VALIDATOR], queries: [{ propertyName: "buttonGroupTemplate", first: true, predicate: QueryButtonGroupDirective, descendants: true }, { propertyName: "switchGroupTemplate", first: true, predicate: QuerySwitchGroupDirective, descendants: true }, { propertyName: "fieldTemplate", first: true, predicate: QueryFieldDirective, descendants: true }, { propertyName: "entityTemplate", first: true, predicate: QueryEntityDirective, descendants: true }, { propertyName: "operatorTemplate", first: true, predicate: QueryOperatorDirective, descendants: true }, { propertyName: "removeButtonTemplate", first: true, predicate: QueryRemoveButtonDirective, descendants: true }, { propertyName: "emptyWarningTemplate", first: true, predicate: QueryEmptyWarningDirective, descendants: true }, { propertyName: "arrowIconTemplate", first: true, predicate: QueryArrowIconDirective, descendants: true }, { propertyName: "inputTemplates", predicate: QueryInputDirective, descendants: true }], viewQueries: [{ propertyName: "treeContainer", first: true, predicate: ["treeContainer"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div [ngClass]=\"getClassNames('switchRow')\">\n <ng-template #defaultArrowIcon>\n <i [ngClass]=\"getClassNames('arrowIcon')\"></i>\n </ng-template>\n\n <a *ngIf=\"allowCollapse\" (click)=\"toggleCollapse()\" [ngClass]=\"getClassNames('arrowIconButton', data.collapsed ? 'collapsed' : '')\">\n <ng-container *ngIf=\"getArrowIconTemplate() as template; else defaultArrowIcon\">\n <ng-container *ngTemplateOutlet=\"template; context: getArrowIconContext()\"></ng-container>\n </ng-container>\n </a>\n\n <ng-container *ngIf=\"getButtonGroupTemplate() as template; else defaultButtonGroup\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getButtonGroupContext()\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultButtonGroup>\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <button type=\"button\" (click)=\"addRule()\" [ngClass]=\"getClassNames('button')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Rule\n </button>\n <button type=\"button\" (click)=\"addRuleSet()\" [ngClass]=\"getClassNames('button')\" *ngIf=\"allowRuleset\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Ruleset\n </button>\n <ng-container *ngIf=\"!!parentValue && allowRuleset\">\n <button type=\"button\" (click)=\"removeRuleSet()\" [ngClass]=\"getClassNames('button', 'removeButton')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </ng-container>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getSwitchGroupTemplate() as template; else defaultSwitchGroup\">\n <ng-container *ngTemplateOutlet=\"template; context: getSwitchGroupContext()\"></ng-container>\n </ng-container>\n\n <ng-template #defaultSwitchGroup>\n <div [ngClass]=\"getClassNames('switchGroup', 'transition')\" *ngIf=\"data\">\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"and\" #andOption />\n <label (click)=\"changeCondition(andOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">AND</label>\n </div>\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"or\" #orOption />\n <label (click)=\"changeCondition(orOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">OR</label>\n </div>\n </div>\n </ng-template>\n</div>\n\n<div #treeContainer (transitionend)=\"transitionEnd($event)\" [ngClass]=\"getClassNames('treeContainer', data.collapsed ? 'collapsed' : '')\">\n <ul [ngClass]=\"getClassNames('tree')\" *ngIf=\"data && data.rules\">\n <ng-container *ngFor=\"let rule of data.rules;let i=index\">\n\n <ng-container *ngIf=\"{ruleset: !!rule.rules, invalid: !config.allowEmptyRulesets && rule.rules && rule.rules.length === 0} as local\">\n <li [ngClass]=\"getQueryItemClassName(local)\">\n <ng-container *ngIf=\"!local.ruleset\">\n\n <ng-container *ngIf=\"getRemoveButtonTemplate() as template; else defaultRemoveButton\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getRemoveButtonContext(rule)\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultRemoveButton>\n <div [ngClass]=\"getClassNames('removeButtonSize', 'rightAlign')\">\n <button type=\"button\" [ngClass]=\"getClassNames('button', 'removeButton')\" (click)=\"removeRule(rule, data)\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </div>\n </ng-template>\n\n <div *ngIf=\"entities?.length\" class=\"q-inline-block-display\">\n <ng-container *ngIf=\"getEntityTemplate() as template; else defaultEntity\">\n <ng-container *ngTemplateOutlet=\"template; context: getEntityContext(rule)\"></ng-container>\n </ng-container>\n </div>\n\n <ng-template #defaultEntity>\n <div [ngClass]=\"getClassNames('entityControlSize')\">\n <select [ngClass]=\"getClassNames('entityControl')\" [(ngModel)]=\"rule.entity\" (ngModelChange)=\"changeEntity($event, rule,i,data)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let entity of entities\" [ngValue]=\"entity.value\">\n {{entity.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getFieldTemplate() as template; else defaultField\">\n <ng-container *ngTemplateOutlet=\"template; context: getFieldContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultField>\n <div [ngClass]=\"getClassNames('fieldControlSize')\">\n <select [ngClass]=\"getClassNames('fieldControl')\" [(ngModel)]=\"rule.field\" (ngModelChange)=\"changeField($event, rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let field of getFields(rule.entity)\" [ngValue]=\"field.value\">\n {{field.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getOperatorTemplate() as template; else defaultOperator\">\n <ng-container *ngTemplateOutlet=\"template; context: getOperatorContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultOperator>\n <div [ngClass]=\"getClassNames('operatorControlSize')\">\n <select [ngClass]=\"getClassNames('operatorControl')\" [(ngModel)]=\"rule.operator\" (ngModelChange)=\"changeOperator(rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let operator of getOperators(rule.field)\" [ngValue]=\"operator\">\n {{operator}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"findTemplateForRule(rule) as template; else defaultInput\">\n <ng-container *ngTemplateOutlet=\"template; context: getInputContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultInput>\n <div [ngClass]=\"getClassNames('inputControlSize')\" [ngSwitch]=\"getInputType(rule.field, rule.operator)\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'string'\" type=\"text\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'number'\" type=\"number\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'date'\" type=\"date\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'time'\" type=\"time\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'category'\">\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n <ng-container *ngSwitchCase=\"'multiselect'\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" multiple>\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n </ng-container>\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'boolean'\" type=\"checkbox\">\n </div>\n </ng-template>\n\n </ng-container>\n <query-builder *ngIf=\"local.ruleset\" [data]=\"rule\" [disabled]=\"disabled\" [parentTouchedCallback]=\"parentTouchedCallback || onTouchedCallback\"\n [parentChangeCallback]=\"parentChangeCallback || onChangeCallback\" [parentInputTemplates]=\"parentInputTemplates || inputTemplates\"\n [parentOperatorTemplate]=\"parentOperatorTemplate || operatorTemplate\" [parentFieldTemplate]=\"parentFieldTemplate || fieldTemplate\"\n [parentEntityTemplate]=\"parentEntityTemplate || entityTemplate\" [parentSwitchGroupTemplate]=\"parentSwitchGroupTemplate || switchGroupTemplate\"\n [parentButtonGroupTemplate]=\"parentButtonGroupTemplate || buttonGroupTemplate\" [parentRemoveButtonTemplate]=\"parentRemoveButtonTemplate || removeButtonTemplate\"\n [parentEmptyWarningTemplate]=\"parentEmptyWarningTemplate || emptyWarningTemplate\" [parentArrowIconTemplate]=\"parentArrowIconTemplate || arrowIconTemplate\"\n [parentValue]=\"data\" [classNames]=\"classNames\" [config]=\"config\" [allowRuleset]=\"allowRuleset\"\n [allowCollapse]=\"allowCollapse\" [emptyMessage]=\"emptyMessage\" [operatorMap]=\"operatorMap\">\n </query-builder>\n\n <ng-container *ngIf=\"getEmptyWarningTemplate() as template; else defaultEmptyWarning\">\n <ng-container *ngIf=\"local.invalid\">\n <ng-container *ngTemplateOutlet=\"template; context: getEmptyWarningContext()\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-template #defaultEmptyWarning>\n <p [ngClass]=\"getClassNames('emptyWarning')\" *ngIf=\"local.invalid\">\n {{emptyMessage}}\n </p>\n </ng-template>\n </li>\n </ng-container>\n </ng-container>\n </ul>\n</div>\n", styles: ["@charset \"UTF-8\";:host{display:block;width:100%}:host .q-icon{font-style:normal;font-size:12px}:host .q-remove-icon:before{content:\"\\274c\"}:host .q-arrow-icon-button{float:left;margin:4px 6px 4px 0;transform:rotate(90deg);transition:linear .25s transform;cursor:pointer}:host .q-arrow-icon-button.q-collapsed{transform:rotate(0)}:host .q-arrow-icon:before{content:\"\\25b6\"}:host .q-add-icon{color:#555}:host .q-add-icon:before{content:\"\\2795\"}:host .q-remove-button{color:#b3415d;width:31px}:host .q-switch-group,:host .q-button-group{font-family:\"Lucida Grande\",Tahoma,Verdana,sans-serif;overflow:hidden}:host .q-right-align{float:right}:host .q-button{margin-left:8px;padding:0 8px;background-color:#fff}:host .q-button:disabled{display:none}:host .q-control-size{display:inline-block;vertical-align:top;padding-right:10px}:host .q-input-control,:host .q-operator-control,:host .q-field-control,:host .q-entity-control{display:inline-block;padding:5px 8px;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;box-sizing:border-box;width:auto;min-width:180px}:host .q-input-control:disabled,:host .q-operator-control:disabled,:host .q-field-control:disabled,:host .q-entity-control:disabled{border-color:transparent}:host .q-operator-control,:host .q-field-control,:host .q-entity-control,:host .q-input-control:not([type=checkbox]){min-height:32px;-webkit-appearance:none}:host .q-switch-label,:host .q-button{float:left;margin-bottom:0;font-size:14px;line-height:30px;font-weight:normal;text-align:center;text-shadow:none;border:1px solid rgba(0,0,0,.2);box-sizing:border-box}:host .q-switch-label:hover,:host .q-button:hover{cursor:pointer;background-color:#f0f0f0}:host .q-switch-label{background-color:#e4e4e4;padding:0 8px}:host .q-switch-radio{position:absolute;clip:rect(0,0,0,0);height:1px;width:1px;border:0;overflow:hidden}:host .q-switch-radio:checked+.q-switch-label{border:1px solid #619ed7;background:white;color:#3176b3}:host .q-switch-radio:disabled+.q-switch-label{display:none}:host .q-switch-radio:checked:disabled+.q-switch-label{display:initial;color:initial;cursor:default;border-color:transparent}:host .q-invalid-ruleset{border:1px solid rgba(179,65,93,.5)!important;background:rgba(179,65,93,.1)!important}:host .q-empty-warning{color:#8d252e;text-align:center}:host .q-ruleset{border:1px solid #CCC}:host .q-rule{border:1px solid #CCC;background:white}:host .q-transition{transition:all .1s ease-in-out}:host .q-tree-container{width:100%;overflow:hidden;transition:ease-in .25s max-height}:host .q-tree-container.q-collapsed{max-height:0!important}:host .q-tree{list-style:none;margin:4px 0 2px}:host .q-row{padding:6px 8px;margin-top:6px}:host .q-connector{position:relative}:host .q-connector:before{top:-5px;border-width:0 0 2px 2px}:host .q-connector:after{border-width:0 0 0 2px;top:50%}:host .q-connector:before,:host .q-connector:after{content:\"\";left:-12px;border-color:#ccc;border-style:solid;width:9px;height:calc(50% + 6px);position:absolute}:host .q-connector:last-child:after{content:none}:host .q-inline-block-display{display:inline-block;vertical-align:top}\n"], components: [{ type: QueryBuilderComponent, selector: "query-builder", inputs: ["disabled", "data", "allowRuleset", "allowCollapse", "emptyMessage", "classNames", "operatorMap", "parentValue", "config", "parentArrowIconTemplate", "parentInputTemplates", "parentOperatorTemplate", "parentFieldTemplate", "parentEntityTemplate", "parentSwitchGroupTemplate", "parentButtonGroupTemplate", "parentRemoveButtonTemplate", "parentEmptyWarningTemplate", "parentChangeCallback", "parentTouchedCallback", "persistValueOnFieldChange", "value"] }], directives: [{ type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i2.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i2.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { type: i2.SelectMultipleControlValueAccessor, selector: "select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]", inputs: ["compareWith"] }, { type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }] });
|
|
782
782
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: QueryBuilderComponent, decorators: [{
|
|
783
783
|
type: Component,
|
|
784
784
|
args: [{
|
|
@@ -858,7 +858,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.13", ngImpo
|
|
|
858
858
|
args: [QueryEmptyWarningDirective]
|
|
859
859
|
}], inputTemplates: [{
|
|
860
860
|
type: ContentChildren,
|
|
861
|
-
args: [QueryInputDirective]
|
|
861
|
+
args: [QueryInputDirective, { descendants: true }]
|
|
862
862
|
}], arrowIconTemplate: [{
|
|
863
863
|
type: ContentChild,
|
|
864
864
|
args: [QueryArrowIconDirective]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-angular-query-builder.js","sources":["../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-operator.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-field.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-entity.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-switch-group.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-button-group.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-input.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-remove-button.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-empty-warning.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-arrow-icon.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-builder.component.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-builder.component.html","../../../projects/ngx-angular-query-builder/src/lib/ngx-angular-query-builder.module.ts","../../../projects/ngx-angular-query-builder/src/public-api.ts","../../../projects/ngx-angular-query-builder/src/ngx-angular-query-builder.ts"],"sourcesContent":["import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryOperator]'})\nexport class QueryOperatorDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryField]'})\nexport class QueryFieldDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryEntity]'})\nexport class QueryEntityDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[querySwitchGroup]'})\nexport class QuerySwitchGroupDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryButtonGroup]'})\nexport class QueryButtonGroupDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, Input, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryInput]'})\nexport class QueryInputDirective {\n /** Unique name for query input type. */\n @Input()\n get queryInputType(): string { return this._type; }\n set queryInputType(value: string) {\n // If the directive is set without a type (updated programatically), then this setter will\n // trigger with an empty string and should not overwrite the programatically set value.\n if (!value) { return; }\n this._type = value;\n }\n private _type!: string;\n\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryRemoveButton]'})\nexport class QueryRemoveButtonDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryEmptyWarning]'})\nexport class QueryEmptyWarningDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryArrowIcon]'})\nexport class QueryArrowIconDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import {\n AbstractControl,\n ControlValueAccessor,\n NG_VALUE_ACCESSOR,\n NG_VALIDATORS,\n ValidationErrors,\n Validator\n} from '@angular/forms';\nimport { QueryOperatorDirective } from './query-operator.directive';\nimport { QueryFieldDirective } from './query-field.directive';\nimport { QueryEntityDirective } from './query-entity.directive';\nimport { QuerySwitchGroupDirective } from './query-switch-group.directive';\nimport { QueryButtonGroupDirective } from './query-button-group.directive';\nimport { QueryInputDirective } from './query-input.directive';\nimport { QueryRemoveButtonDirective } from './query-remove-button.directive';\nimport { QueryEmptyWarningDirective } from './query-empty-warning.directive';\nimport { QueryArrowIconDirective } from './query-arrow-icon.directive';\nimport {\n ButtonGroupContext,\n Entity,\n Field,\n SwitchGroupContext,\n EntityContext,\n FieldContext,\n InputContext,\n LocalRuleMeta,\n OperatorContext,\n Option,\n QueryBuilderClassNames,\n QueryBuilderConfig,\n RemoveButtonContext,\n ArrowIconContext,\n Rule,\n RuleSet,\n EmptyWarningContext,\n} from './query-builder.interfaces';\nimport {\n ChangeDetectorRef,\n Component,\n ContentChild,\n ContentChildren,\n forwardRef,\n Input,\n OnChanges,\n OnInit,\n QueryList,\n SimpleChanges,\n TemplateRef,\n ViewChild,\n ElementRef,\n HostBinding\n} from '@angular/core';\n\nexport const CONTROL_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => QueryBuilderComponent),\n multi: true\n};\n\nexport const VALIDATOR: any = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => QueryBuilderComponent),\n multi: true\n};\n\n@Component({\n selector: 'query-builder',\n templateUrl: './query-builder.component.html',\n styleUrls: ['./query-builder.component.scss'],\n providers: [CONTROL_VALUE_ACCESSOR, VALIDATOR]\n})\nexport class QueryBuilderComponent implements OnChanges, ControlValueAccessor, Validator {\n public fields: Field[];\n public filterFields: Field[];\n public entities: Entity[];\n public defaultClassNames: QueryBuilderClassNames = {\n arrowIconButton: 'q-arrow-icon-button',\n arrowIcon: 'q-icon q-arrow-icon',\n removeIcon: 'q-icon q-remove-icon',\n addIcon: 'q-icon q-add-icon',\n button: 'q-button',\n buttonGroup: 'q-button-group',\n removeButton: 'q-remove-button',\n switchGroup: 'q-switch-group',\n switchLabel: 'q-switch-label',\n switchRadio: 'q-switch-radio',\n rightAlign: 'q-right-align',\n transition: 'q-transition',\n collapsed: 'q-collapsed',\n treeContainer: 'q-tree-container',\n tree: 'q-tree',\n row: 'q-row',\n connector: 'q-connector',\n rule: 'q-rule',\n ruleSet: 'q-ruleset',\n invalidRuleSet: 'q-invalid-ruleset',\n emptyWarning: 'q-empty-warning',\n fieldControl: 'q-field-control',\n fieldControlSize: 'q-control-size',\n entityControl: 'q-entity-control',\n entityControlSize: 'q-control-size',\n operatorControl: 'q-operator-control',\n operatorControlSize: 'q-control-size',\n inputControl: 'q-input-control',\n inputControlSize: 'q-control-size'\n };\n public defaultOperatorMap: { [key: string]: string[] } = {\n string: ['=', '!=', 'contains', 'like'],\n number: ['=', '!=', '>', '>=', '<', '<='],\n time: ['=', '!=', '>', '>=', '<', '<='],\n date: ['=', '!=', '>', '>=', '<', '<='],\n category: ['=', '!=', 'in', 'not in'],\n boolean: ['=']\n };\n @Input() disabled = false;\n @Input() data: RuleSet = { condition: 'add', rules: [] };\n\n\n @HostBinding('attr.query-builder-condition') get condintion() {\n return this.data?.condition;\n }\n\n // For ControlValueAccessor interface\n public onChangeCallback!: () => void;\n public onTouchedCallback!: () => any;\n\n @Input() allowRuleset = true;\n @Input() allowCollapse = false;\n @Input() emptyMessage = 'A ruleset cannot be empty. Please add a rule or remove it all together.';\n @Input() classNames: QueryBuilderClassNames = {};\n @Input() operatorMap: { [key: string]: string[] } = {};\n @Input() parentValue: RuleSet = { condition: 'add', rules: [] };\n @Input() config: QueryBuilderConfig = { fields: {} };\n @Input() parentArrowIconTemplate!: QueryArrowIconDirective;\n @Input() parentInputTemplates!: QueryList<QueryInputDirective>;\n @Input() parentOperatorTemplate!: QueryOperatorDirective;\n @Input() parentFieldTemplate!: QueryFieldDirective;\n @Input() parentEntityTemplate!: QueryEntityDirective;\n @Input() parentSwitchGroupTemplate!: QuerySwitchGroupDirective;\n @Input() parentButtonGroupTemplate!: QueryButtonGroupDirective;\n @Input() parentRemoveButtonTemplate!: QueryRemoveButtonDirective;\n @Input() parentEmptyWarningTemplate!: QueryEmptyWarningDirective;\n @Input() parentChangeCallback!: () => void;\n @Input() parentTouchedCallback!: () => void;\n @Input() persistValueOnFieldChange = false;\n\n @ViewChild('treeContainer', {static: true}) treeContainer!: ElementRef;\n\n @ContentChild(QueryButtonGroupDirective) buttonGroupTemplate!: QueryButtonGroupDirective;\n @ContentChild(QuerySwitchGroupDirective) switchGroupTemplate!: QuerySwitchGroupDirective;\n @ContentChild(QueryFieldDirective) fieldTemplate!: QueryFieldDirective;\n @ContentChild(QueryEntityDirective) entityTemplate!: QueryEntityDirective;\n @ContentChild(QueryOperatorDirective) operatorTemplate!: QueryOperatorDirective;\n @ContentChild(QueryRemoveButtonDirective) removeButtonTemplate!: QueryRemoveButtonDirective;\n @ContentChild(QueryEmptyWarningDirective) emptyWarningTemplate!: QueryEmptyWarningDirective;\n @ContentChildren(QueryInputDirective) inputTemplates!: QueryList<QueryInputDirective>;\n @ContentChild(QueryArrowIconDirective) arrowIconTemplate!: QueryArrowIconDirective;\n\n private defaultTemplateTypes: string[] = [\n 'string', 'number', 'time', 'date', 'category', 'boolean', 'multiselect'];\n private defaultPersistValueTypes: string[] = [\n 'string', 'number', 'time', 'date', 'boolean'];\n private defaultEmptyList: any[] = [];\n private operatorsCache: { [key: string]: string[] } = {};\n private inputContextCache = new Map<Rule, InputContext>();\n private operatorContextCache = new Map<Rule, OperatorContext>();\n private fieldContextCache = new Map<Rule, FieldContext>();\n private entityContextCache = new Map<Rule, EntityContext>();\n private removeButtonContextCache = new Map<Rule, RemoveButtonContext>();\n private buttonGroupContext!: ButtonGroupContext;\n\n constructor(\n private changeDetectorRef: ChangeDetectorRef\n ) {\n this.fields = [];\n this.filterFields = [];\n this.entities = [];\n }\n\n // ----------OnInit Implementation----------\n\n // ----------OnChanges Implementation----------\n\n ngOnChanges(changes: SimpleChanges) {\n const config = this.config;\n const type = typeof config;\n if (type === 'object') {\n this.fields = Object.keys(config.fields).map((value) => {\n const field = config.fields[value];\n field.value = field.value || value;\n return field;\n });\n if (config.entities) {\n this.entities = Object.keys(config.entities).map((value) => {\n const entity = config.entities ? config.entities[value]: [] as any;\n entity.value = entity.value || value;\n return entity;\n });\n } else {\n this.entities = [];\n }\n this.operatorsCache = {};\n } else {\n throw new Error(`Expected 'config' must be a valid object, got ${type} instead.`);\n }\n }\n\n // ----------Validator Implementation----------\n\n validate(control: AbstractControl): ValidationErrors | null {\n const errors: { [key: string]: any } = {};\n const ruleErrorStore = [] as any;\n let hasErrors = false;\n\n if (!this.config.allowEmptyRulesets && this.checkEmptyRuleInRuleset(this.data)) {\n errors.empty = 'Empty rulesets are not allowed.';\n hasErrors = true;\n }\n\n this.validateRulesInRuleset(this.data, ruleErrorStore);\n\n if (ruleErrorStore.length) {\n errors.rules = ruleErrorStore;\n hasErrors = true;\n }\n return hasErrors ? errors : null;\n }\n\n // ----------ControlValueAccessor Implementation----------\n\n @Input()\n get value(): RuleSet {\n return this.data;\n }\n set value(value: RuleSet) {\n // When component is initialized without a formControl, null is passed to value\n this.data = value || { condition: 'add', rules: [] };\n this.handleDataChange();\n }\n\n writeValue(obj: any): void {\n this.value = obj;\n }\n registerOnChange(fn: any): void {\n this.onChangeCallback = () => fn(this.data);\n }\n registerOnTouched(fn: any): void {\n this.onTouchedCallback = () => fn(this.data);\n }\n setDisabledState(isDisabled: boolean): void {\n this.disabled = isDisabled;\n this.changeDetectorRef.detectChanges();\n }\n\n // ----------END----------\n\n getDisabledState = (): boolean => {\n return this.disabled;\n }\n\n findTemplateForRule(rule: Rule): TemplateRef<any> | any {\n const type = this.getInputType(rule.field, rule.operator as string);\n if (type) {\n const queryInput = this.findQueryInput(type);\n if (queryInput) {\n return queryInput.template;\n } else {\n if (this.defaultTemplateTypes.indexOf(type) === -1) {\n console.warn(`Could not find template for field with type: ${type}`);\n }\n return null;\n }\n }\n }\n\n findQueryInput(type: string): QueryInputDirective {\n const templates = this.parentInputTemplates || this.inputTemplates;\n return templates.find((item) => item.queryInputType === type) as QueryInputDirective;\n }\n\n getOperators(field: string): string[] {\n if (this.operatorsCache[field]) {\n return this.operatorsCache[field];\n }\n let operators = this.defaultEmptyList;\n const fieldObject = this.config.fields[field];\n\n if (this.config.getOperators) {\n return this.config.getOperators(field, fieldObject);\n }\n\n const type = fieldObject.type;\n\n if (fieldObject && fieldObject.operators) {\n operators = fieldObject.operators;\n } else if (type) {\n operators = (this.operatorMap && this.operatorMap[type]) || this.defaultOperatorMap[type] || this.defaultEmptyList;\n if (operators.length === 0) {\n console.warn(\n `No operators found for field '${field}' with type ${fieldObject.type}. ` +\n `Please define an 'operators' property on the field or use the 'operatorMap' binding to fix this.`);\n }\n if (fieldObject.nullable) {\n operators = operators.concat(['is null', 'is not null']);\n }\n } else {\n console.warn(`No 'type' property found on field: '${field}'`);\n }\n\n // Cache reference to array object, so it won't be computed next time and trigger a rerender.\n this.operatorsCache[field] = operators;\n return operators;\n }\n\n getFields(entity: string): Field[] {\n if (this.entities.length && entity) {\n return this.fields.filter((field) => {\n return field && field.entity === entity;\n });\n } else {\n return this.fields;\n }\n }\n\n getInputType(field: string, operator: string): string | null {\n if (this.config.getInputType) {\n return this.config.getInputType(field, operator);\n }\n\n if (!this.config.fields[field]) {\n throw new Error(`No configuration for field '${field}' could be found! Please add it to config.fields.`);\n }\n\n const type = this.config.fields[field].type;\n switch (operator) {\n case 'is null':\n case 'is not null':\n return null; // No displayed component\n case 'in':\n case 'not in':\n return type === 'category' || type === 'boolean' ? 'multiselect' : type;\n default:\n return type;\n }\n }\n\n getOptions(field: string): Option[] {\n if (this.config.getOptions) {\n return this.config.getOptions(field);\n }\n return this.config.fields[field].options || this.defaultEmptyList;\n }\n\n getClassNames(...args: string[]): any | string[] {\n const clsLookup = this.classNames ? this.classNames : this.defaultClassNames as any;\n const defaultClassNames = this.defaultClassNames as any;\n const classNames = args.map((id: any) => clsLookup[id] || defaultClassNames[id]).filter((c: any) => !!c);\n return classNames.length ? classNames.join(' ') : [];\n }\n\n getDefaultField(entity: Entity): Field | null {\n if (!entity) {\n return null;\n } else if (entity.defaultField !== undefined) {\n return this.getDefaultValue(entity.defaultField);\n } else {\n const entityFields = this.fields.filter((field) => {\n return field && field.entity === entity.value;\n });\n if (entityFields && entityFields.length) {\n return entityFields[0];\n } else {\n console.warn(`No fields found for entity '${entity.name}'. ` +\n `A 'defaultOperator' is also not specified on the field config. Operator value will default to null.`);\n return null;\n }\n }\n }\n\n getDefaultOperator(field: Field): string | null {\n if (field && field.defaultOperator !== undefined) {\n return this.getDefaultValue(field.defaultOperator);\n } else {\n const operators = this.getOperators(field.value as string);\n if (operators && operators.length) {\n return operators[0];\n } else {\n console.warn(`No operators found for field '${field.value}'. ` +\n `A 'defaultOperator' is also not specified on the field config. Operator value will default to null.`);\n return null;\n }\n }\n }\n\n addRule(parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n parent = parent || this.data;\n if (this.config.addRule) {\n this.config.addRule(parent);\n } else {\n const field = this.fields[0];\n parent.rules = parent.rules.concat([{\n field: field.value as string,\n operator: this.getDefaultOperator(field) as string,\n value: this.getDefaultValue(field.defaultValue),\n entity: field.entity\n }]);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n removeRule(rule: Rule, parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n parent = parent || this.data;\n if (this.config.removeRule) {\n this.config.removeRule(rule, parent);\n } else {\n parent.rules = parent.rules.filter((r) => r !== rule);\n }\n this.inputContextCache.delete(rule);\n this.operatorContextCache.delete(rule);\n this.fieldContextCache.delete(rule);\n this.entityContextCache.delete(rule);\n this.removeButtonContextCache.delete(rule);\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n addRuleSet(parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n parent = parent || this.data;\n if (this.config.addRuleSet) {\n this.config.addRuleSet(parent);\n } else {\n parent.rules = parent.rules.concat([{ condition: 'add', rules: [] }]);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n removeRuleSet(ruleset?: RuleSet, parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n ruleset = ruleset || this.data;\n parent = parent || this.parentValue;\n if (this.config.removeRuleSet) {\n this.config.removeRuleSet(ruleset, parent);\n } else {\n parent.rules = parent.rules.filter((r) => r !== ruleset);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n transitionEnd(e: Event): void {\n this.treeContainer.nativeElement.style.maxHeight = null;\n }\n\n toggleCollapse(): void {\n this.computedTreeContainerHeight();\n setTimeout(() => {\n this.data.collapsed = !this.data.collapsed;\n }, 100);\n }\n\n computedTreeContainerHeight(): void {\n const nativeElement: HTMLElement = this.treeContainer.nativeElement;\n if (nativeElement && nativeElement.firstElementChild) {\n nativeElement.style.maxHeight = (nativeElement.firstElementChild.clientHeight + 8) + 'px';\n }\n }\n\n changeCondition(value: string): void {\n if (this.disabled) {\n return;\n }\n\n this.data.condition = value;\n this.handleTouched();\n this.handleDataChange();\n }\n\n changeOperator(rule: Rule): void {\n if (this.disabled) {\n return;\n }\n\n if (this.config.coerceValueForOperator) {\n rule.value = this.config.coerceValueForOperator(rule.operator as string, rule.value, rule);\n } else {\n rule.value = this.coerceValueForOperator(rule.operator as string, rule.value, rule);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n coerceValueForOperator(operator: string, value: any, rule: Rule): any {\n const inputType: string | null = this.getInputType(rule.field, operator);\n if (inputType === 'multiselect' && !Array.isArray(value)) {\n return [value];\n }\n return value;\n }\n\n changeInput(): void {\n if (this.disabled) {\n return;\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n changeField(fieldValue: string, rule: Rule): void {\n if (this.disabled) {\n return;\n }\n\n const inputContext = this.inputContextCache.get(rule);\n const currentField = inputContext && inputContext.field;\n\n const nextField: Field = this.config.fields[fieldValue];\n\n const nextValue = this.calculateFieldChangeValue(\n currentField as Field, nextField, rule.value);\n\n if (nextValue !== undefined) {\n rule.value = nextValue;\n } else {\n delete rule.value;\n }\n\n rule.operator = this.getDefaultOperator(nextField) as string;\n\n // Create new context objects so templates will automatically update\n this.inputContextCache.delete(rule);\n this.operatorContextCache.delete(rule);\n this.fieldContextCache.delete(rule);\n this.entityContextCache.delete(rule);\n this.getInputContext(rule);\n this.getFieldContext(rule);\n this.getOperatorContext(rule);\n this.getEntityContext(rule);\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n changeEntity(entityValue: string, rule: Rule, index: number, data: RuleSet): void {\n if (this.disabled) {\n return;\n }\n let i = index;\n let rs = data;\n const entity: Entity = this.entities.find((e) => e.value === entityValue) as Entity;\n const defaultField: Field = this.getDefaultField(entity) as Field;\n if (!rs) {\n rs = this.data;\n i = rs.rules.findIndex((x) => x === rule);\n }\n rule.field = defaultField.value as string;\n rs.rules[i] = rule;\n if (defaultField) {\n this.changeField(defaultField.value as string, rule);\n } else {\n this.handleTouched();\n this.handleDataChange();\n }\n }\n\n getDefaultValue(defaultValue: any): any {\n switch (typeof defaultValue) {\n case 'function':\n return defaultValue();\n default:\n return defaultValue;\n }\n }\n\n getOperatorTemplate(): TemplateRef<any> | null {\n const t = this.parentOperatorTemplate || this.operatorTemplate;\n return t ? t.template : null;\n }\n\n getFieldTemplate(): TemplateRef<any> | null {\n const t = this.parentFieldTemplate || this.fieldTemplate;\n return t ? t.template : null;\n }\n\n getEntityTemplate(): TemplateRef<any> | null {\n const t = this.parentEntityTemplate || this.entityTemplate;\n return t ? t.template : null;\n }\n\n getArrowIconTemplate(): TemplateRef<any> | null {\n const t = this.parentArrowIconTemplate || this.arrowIconTemplate;\n return t ? t.template : null;\n }\n\n getButtonGroupTemplate(): TemplateRef<any> | null {\n const t = this.parentButtonGroupTemplate || this.buttonGroupTemplate;\n return t ? t.template : null;\n }\n\n getSwitchGroupTemplate(): TemplateRef<any> | null {\n const t = this.parentSwitchGroupTemplate || this.switchGroupTemplate;\n return t ? t.template : null;\n }\n\n getRemoveButtonTemplate(): TemplateRef<any> | null {\n const t = this.parentRemoveButtonTemplate || this.removeButtonTemplate;\n return t ? t.template : null;\n }\n\n getEmptyWarningTemplate(): TemplateRef<any> | null {\n const t = this.parentEmptyWarningTemplate || this.emptyWarningTemplate;\n return t ? t.template : null;\n }\n\n getQueryItemClassName(local: LocalRuleMeta): string {\n let cls = this.getClassNames('row', 'connector', 'transition');\n cls += ' ' + this.getClassNames(local.ruleset ? 'ruleSet' : 'rule');\n if (local.invalid) {\n cls += ' ' + this.getClassNames('invalidRuleSet');\n }\n return cls as string;\n }\n\n getButtonGroupContext(): ButtonGroupContext {\n if (!this.buttonGroupContext) {\n this.buttonGroupContext = {\n addRule: this.addRule.bind(this),\n addRuleSet: this.allowRuleset && this.addRuleSet.bind(this) as any,\n removeRuleSet: this.allowRuleset && this.parentValue && this.removeRuleSet.bind(this) as any,\n getDisabledState: this.getDisabledState,\n $implicit: this.data\n };\n }\n return this.buttonGroupContext;\n }\n\n getRemoveButtonContext(rule: Rule): RemoveButtonContext {\n if (!this.removeButtonContextCache.has(rule)) {\n this.removeButtonContextCache.set(rule, {\n removeRule: this.removeRule.bind(this),\n getDisabledState: this.getDisabledState,\n $implicit: rule\n });\n }\n return this.removeButtonContextCache.get(rule) as RemoveButtonContext;\n }\n\n getFieldContext(rule: Rule): FieldContext {\n if (!this.fieldContextCache.has(rule)) {\n this.fieldContextCache.set(rule, {\n onChange: this.changeField.bind(this),\n getFields: this.getFields.bind(this),\n getDisabledState: this.getDisabledState,\n fields: this.fields,\n $implicit: rule\n });\n }\n return this.fieldContextCache.get(rule) as FieldContext;\n }\n\n getEntityContext(rule: Rule): EntityContext {\n if (!this.entityContextCache.has(rule)) {\n this.entityContextCache.set(rule, {\n onChange: this.changeEntity.bind(this) as any,\n getDisabledState: this.getDisabledState,\n entities: this.entities,\n $implicit: rule\n });\n }\n return this.entityContextCache.get(rule) as EntityContext;\n }\n\n getSwitchGroupContext(): SwitchGroupContext {\n return {\n onChange: this.changeCondition.bind(this),\n getDisabledState: this.getDisabledState,\n $implicit: this.data\n };\n }\n\n getArrowIconContext(): ArrowIconContext {\n return {\n getDisabledState: this.getDisabledState,\n $implicit: this.data\n };\n }\n\n getEmptyWarningContext(): EmptyWarningContext {\n return {\n getDisabledState: this.getDisabledState,\n message: this.emptyMessage,\n $implicit: this.data\n };\n }\n\n getOperatorContext(rule: Rule): OperatorContext {\n if (!this.operatorContextCache.has(rule)) {\n this.operatorContextCache.set(rule, {\n onChange: this.changeOperator.bind(this) as any,\n getDisabledState: this.getDisabledState,\n operators: this.getOperators(rule.field),\n $implicit: rule\n });\n }\n return this.operatorContextCache.get(rule) as OperatorContext;\n }\n\n getInputContext(rule: Rule): InputContext {\n if (!this.inputContextCache.has(rule)) {\n this.inputContextCache.set(rule, {\n onChange: this.changeInput.bind(this),\n getDisabledState: this.getDisabledState,\n options: this.getOptions(rule.field),\n field: this.config.fields[rule.field],\n $implicit: rule\n });\n }\n return this.inputContextCache.get(rule) as InputContext;\n }\n\n private calculateFieldChangeValue(\n currentField: Field,\n nextField: Field,\n currentValue: any\n ): any {\n\n if (this.config.calculateFieldChangeValue != null) {\n return this.config.calculateFieldChangeValue(\n currentField, nextField, currentValue);\n }\n\n const canKeepValue = () => {\n if (currentField == null || nextField == null) {\n return false;\n }\n return currentField.type === nextField.type\n && this.defaultPersistValueTypes.indexOf(currentField.type) !== -1;\n };\n\n if (this.persistValueOnFieldChange && canKeepValue()) {\n return currentValue;\n }\n\n if (nextField && nextField.defaultValue !== undefined) {\n return this.getDefaultValue(nextField.defaultValue);\n }\n\n return undefined;\n }\n\n private checkEmptyRuleInRuleset(ruleset: RuleSet): boolean {\n if (!ruleset || !ruleset.rules || ruleset.rules.length === 0) {\n return true;\n } else {\n return ruleset.rules.some((item: RuleSet | any) => {\n if (item.rules) {\n return this.checkEmptyRuleInRuleset(item);\n } else {\n return false;\n }\n });\n }\n }\n\n private validateRulesInRuleset(ruleset: RuleSet, errorStore: any[]) {\n if (ruleset && ruleset.rules && ruleset.rules.length > 0) {\n ruleset.rules.forEach((item) => {\n if ((item as RuleSet).rules) {\n return this.validateRulesInRuleset(item as RuleSet, errorStore);\n } else if ((item as Rule).field) {\n const field = this.config.fields[(item as Rule).field];\n if (field && field.validator && field.validator.apply) {\n const error = field.validator(item as Rule, ruleset);\n if (error != null) {\n errorStore.push(error);\n }\n }\n }\n });\n }\n }\n\n private handleDataChange(): void {\n this.changeDetectorRef.markForCheck();\n if (this.onChangeCallback) {\n this.onChangeCallback();\n }\n if (this.parentChangeCallback) {\n this.parentChangeCallback();\n }\n }\n\n private handleTouched(): void {\n if (this.onTouchedCallback) {\n this.onTouchedCallback();\n }\n if (this.parentTouchedCallback) {\n this.parentTouchedCallback();\n }\n }\n}\n","<div [ngClass]=\"getClassNames('switchRow')\">\n <ng-template #defaultArrowIcon>\n <i [ngClass]=\"getClassNames('arrowIcon')\"></i>\n </ng-template>\n\n <a *ngIf=\"allowCollapse\" (click)=\"toggleCollapse()\" [ngClass]=\"getClassNames('arrowIconButton', data.collapsed ? 'collapsed' : '')\">\n <ng-container *ngIf=\"getArrowIconTemplate() as template; else defaultArrowIcon\">\n <ng-container *ngTemplateOutlet=\"template; context: getArrowIconContext()\"></ng-container>\n </ng-container>\n </a>\n\n <ng-container *ngIf=\"getButtonGroupTemplate() as template; else defaultButtonGroup\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getButtonGroupContext()\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultButtonGroup>\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <button type=\"button\" (click)=\"addRule()\" [ngClass]=\"getClassNames('button')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Rule\n </button>\n <button type=\"button\" (click)=\"addRuleSet()\" [ngClass]=\"getClassNames('button')\" *ngIf=\"allowRuleset\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Ruleset\n </button>\n <ng-container *ngIf=\"!!parentValue && allowRuleset\">\n <button type=\"button\" (click)=\"removeRuleSet()\" [ngClass]=\"getClassNames('button', 'removeButton')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </ng-container>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getSwitchGroupTemplate() as template; else defaultSwitchGroup\">\n <ng-container *ngTemplateOutlet=\"template; context: getSwitchGroupContext()\"></ng-container>\n </ng-container>\n\n <ng-template #defaultSwitchGroup>\n <div [ngClass]=\"getClassNames('switchGroup', 'transition')\" *ngIf=\"data\">\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"and\" #andOption />\n <label (click)=\"changeCondition(andOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">AND</label>\n </div>\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"or\" #orOption />\n <label (click)=\"changeCondition(orOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">OR</label>\n </div>\n </div>\n </ng-template>\n</div>\n\n<div #treeContainer (transitionend)=\"transitionEnd($event)\" [ngClass]=\"getClassNames('treeContainer', data.collapsed ? 'collapsed' : '')\">\n <ul [ngClass]=\"getClassNames('tree')\" *ngIf=\"data && data.rules\">\n <ng-container *ngFor=\"let rule of data.rules;let i=index\">\n\n <ng-container *ngIf=\"{ruleset: !!rule.rules, invalid: !config.allowEmptyRulesets && rule.rules && rule.rules.length === 0} as local\">\n <li [ngClass]=\"getQueryItemClassName(local)\">\n <ng-container *ngIf=\"!local.ruleset\">\n\n <ng-container *ngIf=\"getRemoveButtonTemplate() as template; else defaultRemoveButton\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getRemoveButtonContext(rule)\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultRemoveButton>\n <div [ngClass]=\"getClassNames('removeButtonSize', 'rightAlign')\">\n <button type=\"button\" [ngClass]=\"getClassNames('button', 'removeButton')\" (click)=\"removeRule(rule, data)\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </div>\n </ng-template>\n\n <div *ngIf=\"entities?.length\" class=\"q-inline-block-display\">\n <ng-container *ngIf=\"getEntityTemplate() as template; else defaultEntity\">\n <ng-container *ngTemplateOutlet=\"template; context: getEntityContext(rule)\"></ng-container>\n </ng-container>\n </div>\n\n <ng-template #defaultEntity>\n <div [ngClass]=\"getClassNames('entityControlSize')\">\n <select [ngClass]=\"getClassNames('entityControl')\" [(ngModel)]=\"rule.entity\" (ngModelChange)=\"changeEntity($event, rule,i,data)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let entity of entities\" [ngValue]=\"entity.value\">\n {{entity.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getFieldTemplate() as template; else defaultField\">\n <ng-container *ngTemplateOutlet=\"template; context: getFieldContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultField>\n <div [ngClass]=\"getClassNames('fieldControlSize')\">\n <select [ngClass]=\"getClassNames('fieldControl')\" [(ngModel)]=\"rule.field\" (ngModelChange)=\"changeField($event, rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let field of getFields(rule.entity)\" [ngValue]=\"field.value\">\n {{field.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getOperatorTemplate() as template; else defaultOperator\">\n <ng-container *ngTemplateOutlet=\"template; context: getOperatorContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultOperator>\n <div [ngClass]=\"getClassNames('operatorControlSize')\">\n <select [ngClass]=\"getClassNames('operatorControl')\" [(ngModel)]=\"rule.operator\" (ngModelChange)=\"changeOperator(rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let operator of getOperators(rule.field)\" [ngValue]=\"operator\">\n {{operator}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"findTemplateForRule(rule) as template; else defaultInput\">\n <ng-container *ngTemplateOutlet=\"template; context: getInputContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultInput>\n <div [ngClass]=\"getClassNames('inputControlSize')\" [ngSwitch]=\"getInputType(rule.field, rule.operator)\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'string'\" type=\"text\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'number'\" type=\"number\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'date'\" type=\"date\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'time'\" type=\"time\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'category'\">\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n <ng-container *ngSwitchCase=\"'multiselect'\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" multiple>\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n </ng-container>\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'boolean'\" type=\"checkbox\">\n </div>\n </ng-template>\n\n </ng-container>\n <query-builder *ngIf=\"local.ruleset\" [data]=\"rule\" [disabled]=\"disabled\" [parentTouchedCallback]=\"parentTouchedCallback || onTouchedCallback\"\n [parentChangeCallback]=\"parentChangeCallback || onChangeCallback\" [parentInputTemplates]=\"parentInputTemplates || inputTemplates\"\n [parentOperatorTemplate]=\"parentOperatorTemplate || operatorTemplate\" [parentFieldTemplate]=\"parentFieldTemplate || fieldTemplate\"\n [parentEntityTemplate]=\"parentEntityTemplate || entityTemplate\" [parentSwitchGroupTemplate]=\"parentSwitchGroupTemplate || switchGroupTemplate\"\n [parentButtonGroupTemplate]=\"parentButtonGroupTemplate || buttonGroupTemplate\" [parentRemoveButtonTemplate]=\"parentRemoveButtonTemplate || removeButtonTemplate\"\n [parentEmptyWarningTemplate]=\"parentEmptyWarningTemplate || emptyWarningTemplate\" [parentArrowIconTemplate]=\"parentArrowIconTemplate || arrowIconTemplate\"\n [parentValue]=\"data\" [classNames]=\"classNames\" [config]=\"config\" [allowRuleset]=\"allowRuleset\"\n [allowCollapse]=\"allowCollapse\" [emptyMessage]=\"emptyMessage\" [operatorMap]=\"operatorMap\">\n </query-builder>\n\n <ng-container *ngIf=\"getEmptyWarningTemplate() as template; else defaultEmptyWarning\">\n <ng-container *ngIf=\"local.invalid\">\n <ng-container *ngTemplateOutlet=\"template; context: getEmptyWarningContext()\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-template #defaultEmptyWarning>\n <p [ngClass]=\"getClassNames('emptyWarning')\" *ngIf=\"local.invalid\">\n {{emptyMessage}}\n </p>\n </ng-template>\n </li>\n </ng-container>\n </ng-container>\n </ul>\n</div>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormsModule, } from '@angular/forms';\n\nimport { QueryBuilderComponent } from './query-builder/query-builder.component';\n\nimport { QueryArrowIconDirective } from './query-builder/query-arrow-icon.directive';\nimport { QueryFieldDirective } from './query-builder/query-field.directive';\nimport { QueryInputDirective } from './query-builder/query-input.directive';\nimport { QueryEntityDirective } from './query-builder/query-entity.directive';\nimport { QueryOperatorDirective } from './query-builder/query-operator.directive';\nimport { QueryButtonGroupDirective } from './query-builder/query-button-group.directive';\nimport { QuerySwitchGroupDirective } from './query-builder/query-switch-group.directive';\nimport { QueryRemoveButtonDirective } from './query-builder/query-remove-button.directive';\nimport { QueryEmptyWarningDirective } from './query-builder/query-empty-warning.directive';\n\n@NgModule({\n imports: [\n CommonModule,\n FormsModule\n ],\n declarations: [\n QueryBuilderComponent,\n QueryInputDirective,\n QueryOperatorDirective,\n QueryFieldDirective,\n QueryEntityDirective,\n QueryButtonGroupDirective,\n QuerySwitchGroupDirective,\n QueryRemoveButtonDirective,\n QueryEmptyWarningDirective,\n QueryArrowIconDirective\n ],\n exports: [\n QueryBuilderComponent,\n QueryInputDirective,\n QueryOperatorDirective,\n QueryFieldDirective,\n QueryEntityDirective,\n QueryButtonGroupDirective,\n QuerySwitchGroupDirective,\n QueryRemoveButtonDirective,\n QueryEmptyWarningDirective,\n QueryArrowIconDirective\n ]\n})\nexport class NgxAngularQueryBuilderModule { }\n","/*\n * Public API Surface of ngx-angular-query-builder\n */\n\nexport * from './lib/query-builder/query-builder.interfaces';\n\nexport * from './lib/query-builder/query-builder.component';\n\nexport * from './lib/query-builder/query-button-group.directive';\nexport * from './lib/query-builder/query-entity.directive';\nexport * from './lib/query-builder/query-field.directive';\nexport * from './lib/query-builder/query-input.directive';\nexport * from './lib/query-builder/query-operator.directive';\nexport * from './lib/query-builder/query-switch-group.directive';\nexport * from './lib/query-builder/query-remove-button.directive';\nexport * from './lib/query-builder/query-empty-warning.directive';\nexport * from './lib/query-builder/query-arrow-icon.directive';\n\nexport * from './lib/ngx-angular-query-builder.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;MAGa,sBAAsB;IACjC,YAAmB,QAA0B;QAA1B,aAAQ,GAAR,QAAQ,CAAkB;KAAI;;oHADtC,sBAAsB;wGAAtB,sBAAsB;4FAAtB,sBAAsB;kBADlC,SAAS;mBAAC,EAAC,QAAQ,EAAE,iBAAiB,EAAC;;;MCC3B,mBAAmB;IAC9B,YAAmB,QAA0B;QAA1B,aAAQ,GAAR,QAAQ,CAAkB;KAAI;;iHADtC,mBAAmB;qGAAnB,mBAAmB;4FAAnB,mBAAmB;kBAD/B,SAAS;mBAAC,EAAC,QAAQ,EAAE,cAAc,EAAC;;;MCCxB,oBAAoB;IAC/B,YAAmB,QAA0B;QAA1B,aAAQ,GAAR,QAAQ,CAAkB;KAAI;;kHADtC,oBAAoB;sGA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oB;wBACpB,yBAAyB;wBACzB,yBAAyB;wBACzB,0BAA0B;wBAC1B,0BAA0B;wBAC1B,uBAAuB;qBACxB;iBACF;;;AC7CD;;;;ACAA;;;;;;"}
|
|
1
|
+
{"version":3,"file":"ngx-angular-query-builder.js","sources":["../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-operator.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-field.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-entity.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-switch-group.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-button-group.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-input.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-remove-button.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-empty-warning.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-arrow-icon.directive.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-builder.component.ts","../../../projects/ngx-angular-query-builder/src/lib/query-builder/query-builder.component.html","../../../projects/ngx-angular-query-builder/src/lib/ngx-angular-query-builder.module.ts","../../../projects/ngx-angular-query-builder/src/public-api.ts","../../../projects/ngx-angular-query-builder/src/ngx-angular-query-builder.ts"],"sourcesContent":["import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryOperator]'})\nexport class QueryOperatorDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryField]'})\nexport class QueryFieldDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryEntity]'})\nexport class QueryEntityDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[querySwitchGroup]'})\nexport class QuerySwitchGroupDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryButtonGroup]'})\nexport class QueryButtonGroupDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, Input, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryInput]'})\nexport class QueryInputDirective {\n /** Unique name for query input type. */\n @Input()\n get queryInputType(): string { return this._type; }\n set queryInputType(value: string) {\n // If the directive is set without a type (updated programatically), then this setter will\n // trigger with an empty string and should not overwrite the programatically set value.\n if (!value) { return; }\n this._type = value;\n }\n private _type!: string;\n\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryRemoveButton]'})\nexport class QueryRemoveButtonDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryEmptyWarning]'})\nexport class QueryEmptyWarningDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import { Directive, TemplateRef } from '@angular/core';\n\n@Directive({selector: '[queryArrowIcon]'})\nexport class QueryArrowIconDirective {\n constructor(public template: TemplateRef<any>) {}\n}\n","import {\n AbstractControl,\n ControlValueAccessor,\n NG_VALUE_ACCESSOR,\n NG_VALIDATORS,\n ValidationErrors,\n Validator\n} from '@angular/forms';\nimport { QueryOperatorDirective } from './query-operator.directive';\nimport { QueryFieldDirective } from './query-field.directive';\nimport { QueryEntityDirective } from './query-entity.directive';\nimport { QuerySwitchGroupDirective } from './query-switch-group.directive';\nimport { QueryButtonGroupDirective } from './query-button-group.directive';\nimport { QueryInputDirective } from './query-input.directive';\nimport { QueryRemoveButtonDirective } from './query-remove-button.directive';\nimport { QueryEmptyWarningDirective } from './query-empty-warning.directive';\nimport { QueryArrowIconDirective } from './query-arrow-icon.directive';\nimport {\n ButtonGroupContext,\n Entity,\n Field,\n SwitchGroupContext,\n EntityContext,\n FieldContext,\n InputContext,\n LocalRuleMeta,\n OperatorContext,\n Option,\n QueryBuilderClassNames,\n QueryBuilderConfig,\n RemoveButtonContext,\n ArrowIconContext,\n Rule,\n RuleSet,\n EmptyWarningContext,\n} from './query-builder.interfaces';\nimport {\n ChangeDetectorRef,\n Component,\n ContentChild,\n ContentChildren,\n forwardRef,\n Input,\n OnChanges,\n OnInit,\n QueryList,\n SimpleChanges,\n TemplateRef,\n ViewChild,\n ElementRef,\n HostBinding\n} from '@angular/core';\n\nexport const CONTROL_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => QueryBuilderComponent),\n multi: true\n};\n\nexport const VALIDATOR: any = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => QueryBuilderComponent),\n multi: true\n};\n\n@Component({\n selector: 'query-builder',\n templateUrl: './query-builder.component.html',\n styleUrls: ['./query-builder.component.scss'],\n providers: [CONTROL_VALUE_ACCESSOR, VALIDATOR]\n})\nexport class QueryBuilderComponent implements OnChanges, ControlValueAccessor, Validator {\n public fields: Field[];\n public filterFields: Field[];\n public entities: Entity[];\n public defaultClassNames: QueryBuilderClassNames = {\n arrowIconButton: 'q-arrow-icon-button',\n arrowIcon: 'q-icon q-arrow-icon',\n removeIcon: 'q-icon q-remove-icon',\n addIcon: 'q-icon q-add-icon',\n button: 'q-button',\n buttonGroup: 'q-button-group',\n removeButton: 'q-remove-button',\n switchGroup: 'q-switch-group',\n switchLabel: 'q-switch-label',\n switchRadio: 'q-switch-radio',\n rightAlign: 'q-right-align',\n transition: 'q-transition',\n collapsed: 'q-collapsed',\n treeContainer: 'q-tree-container',\n tree: 'q-tree',\n row: 'q-row',\n connector: 'q-connector',\n rule: 'q-rule',\n ruleSet: 'q-ruleset',\n invalidRuleSet: 'q-invalid-ruleset',\n emptyWarning: 'q-empty-warning',\n fieldControl: 'q-field-control',\n fieldControlSize: 'q-control-size',\n entityControl: 'q-entity-control',\n entityControlSize: 'q-control-size',\n operatorControl: 'q-operator-control',\n operatorControlSize: 'q-control-size',\n inputControl: 'q-input-control',\n inputControlSize: 'q-control-size'\n };\n public defaultOperatorMap: { [key: string]: string[] } = {\n string: ['=', '!=', 'contains', 'like'],\n number: ['=', '!=', '>', '>=', '<', '<='],\n time: ['=', '!=', '>', '>=', '<', '<='],\n date: ['=', '!=', '>', '>=', '<', '<='],\n category: ['=', '!=', 'in', 'not in'],\n boolean: ['=']\n };\n @Input() disabled = false;\n @Input() data: RuleSet = { condition: 'add', rules: [] };\n\n\n @HostBinding('attr.query-builder-condition') get condintion() {\n return this.data?.condition;\n }\n\n // For ControlValueAccessor interface\n public onChangeCallback!: () => void;\n public onTouchedCallback!: () => any;\n\n @Input() allowRuleset = true;\n @Input() allowCollapse = false;\n @Input() emptyMessage = 'A ruleset cannot be empty. Please add a rule or remove it all together.';\n @Input() classNames: QueryBuilderClassNames = {};\n @Input() operatorMap: { [key: string]: string[] } = {};\n @Input() parentValue: RuleSet = { condition: 'add', rules: [] };\n @Input() config: QueryBuilderConfig = { fields: {} };\n @Input() parentArrowIconTemplate!: QueryArrowIconDirective;\n @Input() parentInputTemplates!: QueryList<QueryInputDirective>;\n @Input() parentOperatorTemplate!: QueryOperatorDirective;\n @Input() parentFieldTemplate!: QueryFieldDirective;\n @Input() parentEntityTemplate!: QueryEntityDirective;\n @Input() parentSwitchGroupTemplate!: QuerySwitchGroupDirective;\n @Input() parentButtonGroupTemplate!: QueryButtonGroupDirective;\n @Input() parentRemoveButtonTemplate!: QueryRemoveButtonDirective;\n @Input() parentEmptyWarningTemplate!: QueryEmptyWarningDirective;\n @Input() parentChangeCallback!: () => void;\n @Input() parentTouchedCallback!: () => void;\n @Input() persistValueOnFieldChange = false;\n\n @ViewChild('treeContainer', {static: true}) treeContainer!: ElementRef;\n\n @ContentChild(QueryButtonGroupDirective) buttonGroupTemplate!: QueryButtonGroupDirective;\n @ContentChild(QuerySwitchGroupDirective) switchGroupTemplate!: QuerySwitchGroupDirective;\n @ContentChild(QueryFieldDirective) fieldTemplate!: QueryFieldDirective;\n @ContentChild(QueryEntityDirective) entityTemplate!: QueryEntityDirective;\n @ContentChild(QueryOperatorDirective) operatorTemplate!: QueryOperatorDirective;\n @ContentChild(QueryRemoveButtonDirective) removeButtonTemplate!: QueryRemoveButtonDirective;\n @ContentChild(QueryEmptyWarningDirective) emptyWarningTemplate!: QueryEmptyWarningDirective;\n @ContentChildren(QueryInputDirective, {descendants: true}) inputTemplates!: QueryList<QueryInputDirective>;\n @ContentChild(QueryArrowIconDirective) arrowIconTemplate!: QueryArrowIconDirective;\n\n private defaultTemplateTypes: string[] = [\n 'string', 'number', 'time', 'date', 'category', 'boolean', 'multiselect'];\n private defaultPersistValueTypes: string[] = [\n 'string', 'number', 'time', 'date', 'boolean'];\n private defaultEmptyList: any[] = [];\n private operatorsCache: { [key: string]: string[] } = {};\n private inputContextCache = new Map<Rule, InputContext>();\n private operatorContextCache = new Map<Rule, OperatorContext>();\n private fieldContextCache = new Map<Rule, FieldContext>();\n private entityContextCache = new Map<Rule, EntityContext>();\n private removeButtonContextCache = new Map<Rule, RemoveButtonContext>();\n private buttonGroupContext!: ButtonGroupContext;\n\n constructor(\n private changeDetectorRef: ChangeDetectorRef\n ) {\n this.fields = [];\n this.filterFields = [];\n this.entities = [];\n }\n\n // ----------OnInit Implementation----------\n\n // ----------OnChanges Implementation----------\n\n ngOnChanges(changes: SimpleChanges) {\n const config = this.config;\n const type = typeof config;\n if (type === 'object') {\n this.fields = Object.keys(config.fields).map((value) => {\n const field = config.fields[value];\n field.value = field.value || value;\n return field;\n });\n if (config.entities) {\n this.entities = Object.keys(config.entities).map((value) => {\n const entity = config.entities ? config.entities[value]: [] as any;\n entity.value = entity.value || value;\n return entity;\n });\n } else {\n this.entities = [];\n }\n this.operatorsCache = {};\n } else {\n throw new Error(`Expected 'config' must be a valid object, got ${type} instead.`);\n }\n }\n\n // ----------Validator Implementation----------\n\n validate(control: AbstractControl): ValidationErrors | null {\n const errors: { [key: string]: any } = {};\n const ruleErrorStore = [] as any;\n let hasErrors = false;\n\n if (!this.config.allowEmptyRulesets && this.checkEmptyRuleInRuleset(this.data)) {\n errors.empty = 'Empty rulesets are not allowed.';\n hasErrors = true;\n }\n\n this.validateRulesInRuleset(this.data, ruleErrorStore);\n\n if (ruleErrorStore.length) {\n errors.rules = ruleErrorStore;\n hasErrors = true;\n }\n return hasErrors ? errors : null;\n }\n\n // ----------ControlValueAccessor Implementation----------\n\n @Input()\n get value(): RuleSet {\n return this.data;\n }\n set value(value: RuleSet) {\n // When component is initialized without a formControl, null is passed to value\n this.data = value || { condition: 'add', rules: [] };\n this.handleDataChange();\n }\n\n writeValue(obj: any): void {\n this.value = obj;\n }\n registerOnChange(fn: any): void {\n this.onChangeCallback = () => fn(this.data);\n }\n registerOnTouched(fn: any): void {\n this.onTouchedCallback = () => fn(this.data);\n }\n setDisabledState(isDisabled: boolean): void {\n this.disabled = isDisabled;\n this.changeDetectorRef.detectChanges();\n }\n\n // ----------END----------\n\n getDisabledState = (): boolean => {\n return this.disabled;\n }\n\n findTemplateForRule(rule: Rule): TemplateRef<any> | any {\n const type = this.getInputType(rule.field, rule.operator as string);\n if (type) {\n const queryInput = this.findQueryInput(type);\n if (queryInput) {\n return queryInput.template;\n } else {\n if (this.defaultTemplateTypes.indexOf(type) === -1) {\n console.warn(`Could not find template for field with type: ${type}`);\n }\n return null;\n }\n }\n }\n\n findQueryInput(type: string): QueryInputDirective {\n const templates = this.parentInputTemplates || this.inputTemplates;\n return templates.find((item) => item.queryInputType === type) as QueryInputDirective;\n }\n\n getOperators(field: string): string[] {\n if (this.operatorsCache[field]) {\n return this.operatorsCache[field];\n }\n let operators = this.defaultEmptyList;\n const fieldObject = this.config.fields[field];\n\n if (this.config.getOperators) {\n return this.config.getOperators(field, fieldObject);\n }\n\n const type = fieldObject.type;\n\n if (fieldObject && fieldObject.operators) {\n operators = fieldObject.operators;\n } else if (type) {\n operators = (this.operatorMap && this.operatorMap[type]) || this.defaultOperatorMap[type] || this.defaultEmptyList;\n if (operators.length === 0) {\n console.warn(\n `No operators found for field '${field}' with type ${fieldObject.type}. ` +\n `Please define an 'operators' property on the field or use the 'operatorMap' binding to fix this.`);\n }\n if (fieldObject.nullable) {\n operators = operators.concat(['is null', 'is not null']);\n }\n } else {\n console.warn(`No 'type' property found on field: '${field}'`);\n }\n\n // Cache reference to array object, so it won't be computed next time and trigger a rerender.\n this.operatorsCache[field] = operators;\n return operators;\n }\n\n getFields(entity: string): Field[] {\n if (this.entities.length && entity) {\n return this.fields.filter((field) => {\n return field && field.entity === entity;\n });\n } else {\n return this.fields;\n }\n }\n\n getInputType(field: string, operator: string): string | null {\n if (this.config.getInputType) {\n return this.config.getInputType(field, operator);\n }\n\n if (!this.config.fields[field]) {\n throw new Error(`No configuration for field '${field}' could be found! Please add it to config.fields.`);\n }\n\n const type = this.config.fields[field].type;\n switch (operator) {\n case 'is null':\n case 'is not null':\n return null; // No displayed component\n case 'in':\n case 'not in':\n return type === 'category' || type === 'boolean' ? 'multiselect' : type;\n default:\n return type;\n }\n }\n\n getOptions(field: string): Option[] {\n if (this.config.getOptions) {\n return this.config.getOptions(field);\n }\n return this.config.fields[field].options || this.defaultEmptyList;\n }\n\n getClassNames(...args: string[]): any | string[] {\n const clsLookup = this.classNames ? this.classNames : this.defaultClassNames as any;\n const defaultClassNames = this.defaultClassNames as any;\n const classNames = args.map((id: any) => clsLookup[id] || defaultClassNames[id]).filter((c: any) => !!c);\n return classNames.length ? classNames.join(' ') : [];\n }\n\n getDefaultField(entity: Entity): Field | null {\n if (!entity) {\n return null;\n } else if (entity.defaultField !== undefined) {\n return this.getDefaultValue(entity.defaultField);\n } else {\n const entityFields = this.fields.filter((field) => {\n return field && field.entity === entity.value;\n });\n if (entityFields && entityFields.length) {\n return entityFields[0];\n } else {\n console.warn(`No fields found for entity '${entity.name}'. ` +\n `A 'defaultOperator' is also not specified on the field config. Operator value will default to null.`);\n return null;\n }\n }\n }\n\n getDefaultOperator(field: Field): string | null {\n if (field && field.defaultOperator !== undefined) {\n return this.getDefaultValue(field.defaultOperator);\n } else {\n const operators = this.getOperators(field.value as string);\n if (operators && operators.length) {\n return operators[0];\n } else {\n console.warn(`No operators found for field '${field.value}'. ` +\n `A 'defaultOperator' is also not specified on the field config. Operator value will default to null.`);\n return null;\n }\n }\n }\n\n addRule(parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n parent = parent || this.data;\n if (this.config.addRule) {\n this.config.addRule(parent);\n } else {\n const field = this.fields[0];\n parent.rules = parent.rules.concat([{\n field: field.value as string,\n operator: this.getDefaultOperator(field) as string,\n value: this.getDefaultValue(field.defaultValue),\n entity: field.entity\n }]);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n removeRule(rule: Rule, parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n parent = parent || this.data;\n if (this.config.removeRule) {\n this.config.removeRule(rule, parent);\n } else {\n parent.rules = parent.rules.filter((r) => r !== rule);\n }\n this.inputContextCache.delete(rule);\n this.operatorContextCache.delete(rule);\n this.fieldContextCache.delete(rule);\n this.entityContextCache.delete(rule);\n this.removeButtonContextCache.delete(rule);\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n addRuleSet(parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n parent = parent || this.data;\n if (this.config.addRuleSet) {\n this.config.addRuleSet(parent);\n } else {\n parent.rules = parent.rules.concat([{ condition: 'add', rules: [] }]);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n removeRuleSet(ruleset?: RuleSet, parent?: RuleSet): void {\n if (this.disabled) {\n return;\n }\n\n ruleset = ruleset || this.data;\n parent = parent || this.parentValue;\n if (this.config.removeRuleSet) {\n this.config.removeRuleSet(ruleset, parent);\n } else {\n parent.rules = parent.rules.filter((r) => r !== ruleset);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n transitionEnd(e: Event): void {\n this.treeContainer.nativeElement.style.maxHeight = null;\n }\n\n toggleCollapse(): void {\n this.computedTreeContainerHeight();\n setTimeout(() => {\n this.data.collapsed = !this.data.collapsed;\n }, 100);\n }\n\n computedTreeContainerHeight(): void {\n const nativeElement: HTMLElement = this.treeContainer.nativeElement;\n if (nativeElement && nativeElement.firstElementChild) {\n nativeElement.style.maxHeight = (nativeElement.firstElementChild.clientHeight + 8) + 'px';\n }\n }\n\n changeCondition(value: string): void {\n if (this.disabled) {\n return;\n }\n\n this.data.condition = value;\n this.handleTouched();\n this.handleDataChange();\n }\n\n changeOperator(rule: Rule): void {\n if (this.disabled) {\n return;\n }\n\n if (this.config.coerceValueForOperator) {\n rule.value = this.config.coerceValueForOperator(rule.operator as string, rule.value, rule);\n } else {\n rule.value = this.coerceValueForOperator(rule.operator as string, rule.value, rule);\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n coerceValueForOperator(operator: string, value: any, rule: Rule): any {\n const inputType: string | null = this.getInputType(rule.field, operator);\n if (inputType === 'multiselect' && !Array.isArray(value)) {\n return [value];\n }\n return value;\n }\n\n changeInput(): void {\n if (this.disabled) {\n return;\n }\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n changeField(fieldValue: string, rule: Rule): void {\n if (this.disabled) {\n return;\n }\n\n const inputContext = this.inputContextCache.get(rule);\n const currentField = inputContext && inputContext.field;\n\n const nextField: Field = this.config.fields[fieldValue];\n\n const nextValue = this.calculateFieldChangeValue(\n currentField as Field, nextField, rule.value);\n\n if (nextValue !== undefined) {\n rule.value = nextValue;\n } else {\n delete rule.value;\n }\n\n rule.operator = this.getDefaultOperator(nextField) as string;\n\n // Create new context objects so templates will automatically update\n this.inputContextCache.delete(rule);\n this.operatorContextCache.delete(rule);\n this.fieldContextCache.delete(rule);\n this.entityContextCache.delete(rule);\n this.getInputContext(rule);\n this.getFieldContext(rule);\n this.getOperatorContext(rule);\n this.getEntityContext(rule);\n\n this.handleTouched();\n this.handleDataChange();\n }\n\n changeEntity(entityValue: string, rule: Rule, index: number, data: RuleSet): void {\n if (this.disabled) {\n return;\n }\n let i = index;\n let rs = data;\n const entity: Entity = this.entities.find((e) => e.value === entityValue) as Entity;\n const defaultField: Field = this.getDefaultField(entity) as Field;\n if (!rs) {\n rs = this.data;\n i = rs.rules.findIndex((x) => x === rule);\n }\n rule.field = defaultField.value as string;\n rs.rules[i] = rule;\n if (defaultField) {\n this.changeField(defaultField.value as string, rule);\n } else {\n this.handleTouched();\n this.handleDataChange();\n }\n }\n\n getDefaultValue(defaultValue: any): any {\n switch (typeof defaultValue) {\n case 'function':\n return defaultValue();\n default:\n return defaultValue;\n }\n }\n\n getOperatorTemplate(): TemplateRef<any> | null {\n const t = this.parentOperatorTemplate || this.operatorTemplate;\n return t ? t.template : null;\n }\n\n getFieldTemplate(): TemplateRef<any> | null {\n const t = this.parentFieldTemplate || this.fieldTemplate;\n return t ? t.template : null;\n }\n\n getEntityTemplate(): TemplateRef<any> | null {\n const t = this.parentEntityTemplate || this.entityTemplate;\n return t ? t.template : null;\n }\n\n getArrowIconTemplate(): TemplateRef<any> | null {\n const t = this.parentArrowIconTemplate || this.arrowIconTemplate;\n return t ? t.template : null;\n }\n\n getButtonGroupTemplate(): TemplateRef<any> | null {\n const t = this.parentButtonGroupTemplate || this.buttonGroupTemplate;\n return t ? t.template : null;\n }\n\n getSwitchGroupTemplate(): TemplateRef<any> | null {\n const t = this.parentSwitchGroupTemplate || this.switchGroupTemplate;\n return t ? t.template : null;\n }\n\n getRemoveButtonTemplate(): TemplateRef<any> | null {\n const t = this.parentRemoveButtonTemplate || this.removeButtonTemplate;\n return t ? t.template : null;\n }\n\n getEmptyWarningTemplate(): TemplateRef<any> | null {\n const t = this.parentEmptyWarningTemplate || this.emptyWarningTemplate;\n return t ? t.template : null;\n }\n\n getQueryItemClassName(local: LocalRuleMeta): string {\n let cls = this.getClassNames('row', 'connector', 'transition');\n cls += ' ' + this.getClassNames(local.ruleset ? 'ruleSet' : 'rule');\n if (local.invalid) {\n cls += ' ' + this.getClassNames('invalidRuleSet');\n }\n return cls as string;\n }\n\n getButtonGroupContext(): ButtonGroupContext {\n if (!this.buttonGroupContext) {\n this.buttonGroupContext = {\n addRule: this.addRule.bind(this),\n addRuleSet: this.allowRuleset && this.addRuleSet.bind(this) as any,\n removeRuleSet: this.allowRuleset && this.parentValue && this.removeRuleSet.bind(this) as any,\n getDisabledState: this.getDisabledState,\n $implicit: this.data\n };\n }\n return this.buttonGroupContext;\n }\n\n getRemoveButtonContext(rule: Rule): RemoveButtonContext {\n if (!this.removeButtonContextCache.has(rule)) {\n this.removeButtonContextCache.set(rule, {\n removeRule: this.removeRule.bind(this),\n getDisabledState: this.getDisabledState,\n $implicit: rule\n });\n }\n return this.removeButtonContextCache.get(rule) as RemoveButtonContext;\n }\n\n getFieldContext(rule: Rule): FieldContext {\n if (!this.fieldContextCache.has(rule)) {\n this.fieldContextCache.set(rule, {\n onChange: this.changeField.bind(this),\n getFields: this.getFields.bind(this),\n getDisabledState: this.getDisabledState,\n fields: this.fields,\n $implicit: rule\n });\n }\n return this.fieldContextCache.get(rule) as FieldContext;\n }\n\n getEntityContext(rule: Rule): EntityContext {\n if (!this.entityContextCache.has(rule)) {\n this.entityContextCache.set(rule, {\n onChange: this.changeEntity.bind(this) as any,\n getDisabledState: this.getDisabledState,\n entities: this.entities,\n $implicit: rule\n });\n }\n return this.entityContextCache.get(rule) as EntityContext;\n }\n\n getSwitchGroupContext(): SwitchGroupContext {\n return {\n onChange: this.changeCondition.bind(this),\n getDisabledState: this.getDisabledState,\n $implicit: this.data\n };\n }\n\n getArrowIconContext(): ArrowIconContext {\n return {\n getDisabledState: this.getDisabledState,\n $implicit: this.data\n };\n }\n\n getEmptyWarningContext(): EmptyWarningContext {\n return {\n getDisabledState: this.getDisabledState,\n message: this.emptyMessage,\n $implicit: this.data\n };\n }\n\n getOperatorContext(rule: Rule): OperatorContext {\n if (!this.operatorContextCache.has(rule)) {\n this.operatorContextCache.set(rule, {\n onChange: this.changeOperator.bind(this) as any,\n getDisabledState: this.getDisabledState,\n operators: this.getOperators(rule.field),\n $implicit: rule\n });\n }\n return this.operatorContextCache.get(rule) as OperatorContext;\n }\n\n getInputContext(rule: Rule): InputContext {\n if (!this.inputContextCache.has(rule)) {\n this.inputContextCache.set(rule, {\n onChange: this.changeInput.bind(this),\n getDisabledState: this.getDisabledState,\n options: this.getOptions(rule.field),\n field: this.config.fields[rule.field],\n $implicit: rule\n });\n }\n return this.inputContextCache.get(rule) as InputContext;\n }\n\n private calculateFieldChangeValue(\n currentField: Field,\n nextField: Field,\n currentValue: any\n ): any {\n\n if (this.config.calculateFieldChangeValue != null) {\n return this.config.calculateFieldChangeValue(\n currentField, nextField, currentValue);\n }\n\n const canKeepValue = () => {\n if (currentField == null || nextField == null) {\n return false;\n }\n return currentField.type === nextField.type\n && this.defaultPersistValueTypes.indexOf(currentField.type) !== -1;\n };\n\n if (this.persistValueOnFieldChange && canKeepValue()) {\n return currentValue;\n }\n\n if (nextField && nextField.defaultValue !== undefined) {\n return this.getDefaultValue(nextField.defaultValue);\n }\n\n return undefined;\n }\n\n private checkEmptyRuleInRuleset(ruleset: RuleSet): boolean {\n if (!ruleset || !ruleset.rules || ruleset.rules.length === 0) {\n return true;\n } else {\n return ruleset.rules.some((item: RuleSet | any) => {\n if (item.rules) {\n return this.checkEmptyRuleInRuleset(item);\n } else {\n return false;\n }\n });\n }\n }\n\n private validateRulesInRuleset(ruleset: RuleSet, errorStore: any[]) {\n if (ruleset && ruleset.rules && ruleset.rules.length > 0) {\n ruleset.rules.forEach((item) => {\n if ((item as RuleSet).rules) {\n return this.validateRulesInRuleset(item as RuleSet, errorStore);\n } else if ((item as Rule).field) {\n const field = this.config.fields[(item as Rule).field];\n if (field && field.validator && field.validator.apply) {\n const error = field.validator(item as Rule, ruleset);\n if (error != null) {\n errorStore.push(error);\n }\n }\n }\n });\n }\n }\n\n private handleDataChange(): void {\n this.changeDetectorRef.markForCheck();\n if (this.onChangeCallback) {\n this.onChangeCallback();\n }\n if (this.parentChangeCallback) {\n this.parentChangeCallback();\n }\n }\n\n private handleTouched(): void {\n if (this.onTouchedCallback) {\n this.onTouchedCallback();\n }\n if (this.parentTouchedCallback) {\n this.parentTouchedCallback();\n }\n }\n}\n","<div [ngClass]=\"getClassNames('switchRow')\">\n <ng-template #defaultArrowIcon>\n <i [ngClass]=\"getClassNames('arrowIcon')\"></i>\n </ng-template>\n\n <a *ngIf=\"allowCollapse\" (click)=\"toggleCollapse()\" [ngClass]=\"getClassNames('arrowIconButton', data.collapsed ? 'collapsed' : '')\">\n <ng-container *ngIf=\"getArrowIconTemplate() as template; else defaultArrowIcon\">\n <ng-container *ngTemplateOutlet=\"template; context: getArrowIconContext()\"></ng-container>\n </ng-container>\n </a>\n\n <ng-container *ngIf=\"getButtonGroupTemplate() as template; else defaultButtonGroup\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getButtonGroupContext()\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultButtonGroup>\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <button type=\"button\" (click)=\"addRule()\" [ngClass]=\"getClassNames('button')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Rule\n </button>\n <button type=\"button\" (click)=\"addRuleSet()\" [ngClass]=\"getClassNames('button')\" *ngIf=\"allowRuleset\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('addIcon')\"></i> Ruleset\n </button>\n <ng-container *ngIf=\"!!parentValue && allowRuleset\">\n <button type=\"button\" (click)=\"removeRuleSet()\" [ngClass]=\"getClassNames('button', 'removeButton')\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </ng-container>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getSwitchGroupTemplate() as template; else defaultSwitchGroup\">\n <ng-container *ngTemplateOutlet=\"template; context: getSwitchGroupContext()\"></ng-container>\n </ng-container>\n\n <ng-template #defaultSwitchGroup>\n <div [ngClass]=\"getClassNames('switchGroup', 'transition')\" *ngIf=\"data\">\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"and\" #andOption />\n <label (click)=\"changeCondition(andOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">AND</label>\n </div>\n <div [ngClass]=\"getClassNames('switchControl')\">\n <input type=\"radio\" [ngClass]=\"getClassNames('switchRadio')\" [(ngModel)]=\"data.condition\" [disabled]=disabled\n value=\"or\" #orOption />\n <label (click)=\"changeCondition(orOption.value)\" [ngClass]=\"getClassNames('switchLabel')\">OR</label>\n </div>\n </div>\n </ng-template>\n</div>\n\n<div #treeContainer (transitionend)=\"transitionEnd($event)\" [ngClass]=\"getClassNames('treeContainer', data.collapsed ? 'collapsed' : '')\">\n <ul [ngClass]=\"getClassNames('tree')\" *ngIf=\"data && data.rules\">\n <ng-container *ngFor=\"let rule of data.rules;let i=index\">\n\n <ng-container *ngIf=\"{ruleset: !!rule.rules, invalid: !config.allowEmptyRulesets && rule.rules && rule.rules.length === 0} as local\">\n <li [ngClass]=\"getQueryItemClassName(local)\">\n <ng-container *ngIf=\"!local.ruleset\">\n\n <ng-container *ngIf=\"getRemoveButtonTemplate() as template; else defaultRemoveButton\">\n <div [ngClass]=\"getClassNames('buttonGroup', 'rightAlign')\">\n <ng-container *ngTemplateOutlet=\"template; context: getRemoveButtonContext(rule)\"></ng-container>\n </div>\n </ng-container>\n\n <ng-template #defaultRemoveButton>\n <div [ngClass]=\"getClassNames('removeButtonSize', 'rightAlign')\">\n <button type=\"button\" [ngClass]=\"getClassNames('button', 'removeButton')\" (click)=\"removeRule(rule, data)\" [disabled]=disabled>\n <i [ngClass]=\"getClassNames('removeIcon')\"></i>\n </button>\n </div>\n </ng-template>\n\n <div *ngIf=\"entities?.length\" class=\"q-inline-block-display\">\n <ng-container *ngIf=\"getEntityTemplate() as template; else defaultEntity\">\n <ng-container *ngTemplateOutlet=\"template; context: getEntityContext(rule)\"></ng-container>\n </ng-container>\n </div>\n\n <ng-template #defaultEntity>\n <div [ngClass]=\"getClassNames('entityControlSize')\">\n <select [ngClass]=\"getClassNames('entityControl')\" [(ngModel)]=\"rule.entity\" (ngModelChange)=\"changeEntity($event, rule,i,data)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let entity of entities\" [ngValue]=\"entity.value\">\n {{entity.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getFieldTemplate() as template; else defaultField\">\n <ng-container *ngTemplateOutlet=\"template; context: getFieldContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultField>\n <div [ngClass]=\"getClassNames('fieldControlSize')\">\n <select [ngClass]=\"getClassNames('fieldControl')\" [(ngModel)]=\"rule.field\" (ngModelChange)=\"changeField($event, rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let field of getFields(rule.entity)\" [ngValue]=\"field.value\">\n {{field.name}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"getOperatorTemplate() as template; else defaultOperator\">\n <ng-container *ngTemplateOutlet=\"template; context: getOperatorContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultOperator>\n <div [ngClass]=\"getClassNames('operatorControlSize')\">\n <select [ngClass]=\"getClassNames('operatorControl')\" [(ngModel)]=\"rule.operator\" (ngModelChange)=\"changeOperator(rule)\"\n [disabled]=\"disabled\">\n <option *ngFor=\"let operator of getOperators(rule.field)\" [ngValue]=\"operator\">\n {{operator}}\n </option>\n </select>\n </div>\n </ng-template>\n\n <ng-container *ngIf=\"findTemplateForRule(rule) as template; else defaultInput\">\n <ng-container *ngTemplateOutlet=\"template; context: getInputContext(rule)\"></ng-container>\n </ng-container>\n\n <ng-template #defaultInput>\n <div [ngClass]=\"getClassNames('inputControlSize')\" [ngSwitch]=\"getInputType(rule.field, rule.operator)\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'string'\" type=\"text\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'number'\" type=\"number\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'date'\" type=\"date\">\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'time'\" type=\"time\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'category'\">\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n <ng-container *ngSwitchCase=\"'multiselect'\">\n <select [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" multiple>\n <option *ngFor=\"let opt of getOptions(rule.field)\" [ngValue]=\"opt.value\">\n {{opt.name}}\n </option>\n </select>\n </ng-container>\n <input [ngClass]=\"getClassNames('inputControl')\" [(ngModel)]=\"rule.value\" (ngModelChange)=\"changeInput()\"\n [disabled]=\"disabled\" *ngSwitchCase=\"'boolean'\" type=\"checkbox\">\n </div>\n </ng-template>\n\n </ng-container>\n <query-builder *ngIf=\"local.ruleset\" [data]=\"rule\" [disabled]=\"disabled\" [parentTouchedCallback]=\"parentTouchedCallback || onTouchedCallback\"\n [parentChangeCallback]=\"parentChangeCallback || onChangeCallback\" [parentInputTemplates]=\"parentInputTemplates || inputTemplates\"\n [parentOperatorTemplate]=\"parentOperatorTemplate || operatorTemplate\" [parentFieldTemplate]=\"parentFieldTemplate || fieldTemplate\"\n [parentEntityTemplate]=\"parentEntityTemplate || entityTemplate\" [parentSwitchGroupTemplate]=\"parentSwitchGroupTemplate || switchGroupTemplate\"\n [parentButtonGroupTemplate]=\"parentButtonGroupTemplate || buttonGroupTemplate\" [parentRemoveButtonTemplate]=\"parentRemoveButtonTemplate || removeButtonTemplate\"\n [parentEmptyWarningTemplate]=\"parentEmptyWarningTemplate || emptyWarningTemplate\" [parentArrowIconTemplate]=\"parentArrowIconTemplate || arrowIconTemplate\"\n [parentValue]=\"data\" [classNames]=\"classNames\" [config]=\"config\" [allowRuleset]=\"allowRuleset\"\n [allowCollapse]=\"allowCollapse\" [emptyMessage]=\"emptyMessage\" [operatorMap]=\"operatorMap\">\n </query-builder>\n\n <ng-container *ngIf=\"getEmptyWarningTemplate() as template; else defaultEmptyWarning\">\n <ng-container *ngIf=\"local.invalid\">\n <ng-container *ngTemplateOutlet=\"template; context: getEmptyWarningContext()\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-template #defaultEmptyWarning>\n <p [ngClass]=\"getClassNames('emptyWarning')\" *ngIf=\"local.invalid\">\n {{emptyMessage}}\n </p>\n </ng-template>\n </li>\n </ng-container>\n </ng-container>\n </ul>\n</div>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormsModule, } from '@angular/forms';\n\nimport { QueryBuilderComponent } from './query-builder/query-builder.component';\n\nimport { QueryArrowIconDirective } from './query-builder/query-arrow-icon.directive';\nimport { QueryFieldDirective } from './query-builder/query-field.directive';\nimport { QueryInputDirective } from './query-builder/query-input.directive';\nimport { QueryEntityDirective } from './query-builder/query-entity.directive';\nimport { QueryOperatorDirective } from './query-builder/query-operator.directive';\nimport { QueryButtonGroupDirective } from './query-builder/query-button-group.directive';\nimport { QuerySwitchGroupDirective } from './query-builder/query-switch-group.directive';\nimport { QueryRemoveButtonDirective } from './query-builder/query-remove-button.directive';\nimport { QueryEmptyWarningDirective } from './query-builder/query-empty-warning.directive';\n\n@NgModule({\n imports: [\n CommonModule,\n FormsModule\n ],\n declarations: [\n QueryBuilderComponent,\n QueryInputDirective,\n QueryOperatorDirective,\n QueryFieldDirective,\n QueryEntityDirective,\n QueryButtonGroupDirective,\n QuerySwitchGroupDirective,\n QueryRemoveButtonDirective,\n QueryEmptyWarningDirective,\n QueryArrowIconDirective\n ],\n exports: [\n QueryBuilderComponent,\n QueryInputDirective,\n QueryOperatorDirective,\n QueryFieldDirective,\n QueryEntityDirective,\n QueryButtonGroupDirective,\n QuerySwitchGroupDirective,\n QueryRemoveButtonDirective,\n QueryEmptyWarningDirective,\n QueryArrowIconDirective\n ]\n})\nexport class NgxAngularQueryBuilderModule { }\n","/*\n * Public API Surface of ngx-angular-query-builder\n */\n\nexport * from './lib/query-builder/query-builder.interfaces';\n\nexport * from './lib/query-builder/query-builder.component';\n\nexport * from './lib/query-builder/query-button-group.directive';\nexport * from './lib/query-builder/query-entity.directive';\nexport * from './lib/query-builder/query-field.directive';\nexport * from './lib/query-builder/query-input.directive';\nexport * from './lib/query-builder/query-operator.directive';\nexport * from './lib/query-builder/query-switch-group.directive';\nexport * from './lib/query-builder/query-remove-button.directive';\nexport * from './lib/query-builder/query-empty-warning.directive';\nexport * from './lib/query-builder/query-arrow-icon.directive';\n\nexport * from './lib/ngx-angular-query-builder.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;MAGa,sBAAsB;IACjC,YAAmB,QAA0B;QAA1B,aAAQ,GAAR,QAAQ,CAAkB;KAAI;;oHADtC,sBAAsB;wGAAtB,sBAAsB;4FAAtB,sBAAsB;kBADlC,SAAS;mBAAC,EAAC,QAAQ,EAAE,iBAAiB,EAAC;;;MCC3B,mBAAmB;IAC9B,YAAmB,QAA0B;QAA1B,aAAQ,GAAR,QAAQ,CAAkB;KAAI;;iHADtC,mBAAmB;qGAAnB,mBAAmB;4FAAnB,mBAAmB;kBAD/B,SAAS;mBAAC,EAAC,QAAQ,EAAE,cAAc,EAAC;;;MCCxB,oBAAoB;IAC/B,YAA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