@progress/kendo-angular-filter 0.1.2-dev.202201201353 → 0.1.4-dev.202202141437

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/dist/cdn/main.js CHANGED
@@ -2,4 +2,4 @@
2
2
  * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
3
  * Licensed under commercial license. See LICENSE.md in the project root for more information
4
4
  *-------------------------------------------------------------------------------------------*/
5
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@angular/core"),require("tslib"),require("@progress/kendo-angular-l10n"),require("@progress/kendo-licensing"),require("@angular/common"),require("@progress/kendo-angular-dropdowns"),require("@progress/kendo-angular-inputs"),require("@progress/kendo-angular-label"),require("@progress/kendo-angular-buttons"),require("@progress/kendo-angular-dateinputs")):"function"==typeof define&&define.amd?define(["@angular/core","tslib","@progress/kendo-angular-l10n","@progress/kendo-licensing","@angular/common","@progress/kendo-angular-dropdowns","@progress/kendo-angular-inputs","@progress/kendo-angular-label","@progress/kendo-angular-buttons","@progress/kendo-angular-dateinputs"],t):"object"==typeof exports?exports.KendoAngularFilter=t(require("@angular/core"),require("tslib"),require("@progress/kendo-angular-l10n"),require("@progress/kendo-licensing"),require("@angular/common"),require("@progress/kendo-angular-dropdowns"),require("@progress/kendo-angular-inputs"),require("@progress/kendo-angular-label"),require("@progress/kendo-angular-buttons"),require("@progress/kendo-angular-dateinputs")):e.KendoAngularFilter=t(e["@angular/core"],e.tslib,e["@progress/kendo-angular-l10n"],e["@progress/kendo-licensing"],e["@angular/common"],e["@progress/kendo-angular-dropdowns"],e["@progress/kendo-angular-inputs"],e["@progress/kendo-angular-label"],e["@progress/kendo-angular-buttons"],e["@progress/kendo-angular-dateinputs"])}(window,(function(e,t,r,o,i,n,a,l,s,u){return function(e){var t={};function r(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(o,i,function(t){return e[t]}.bind(null,i));return o},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=7)}([function(t,r){t.exports=e},function(e,r){e.exports=t},function(e,t){e.exports=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(4);t.localizeOperators=function(e){return function(t){return Object.keys(e).map((function(r){return{text:t.get(r),value:e[r]}}))}};var l=function(){function e(e){this.localization=e,this.value={filters:[],logic:"or"},this.filters=[],this.isEditorDisabled=!1}return Object.defineProperty(e.prototype,"defaultNumericOperators",{get:function(){return t.localizeOperators(a.defaultNumericOperators)(this.localization)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"defaultStringOperators",{get:function(){return t.localizeOperators(a.defaultStringOperators)(this.localization)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"defaultDateOperators",{get:function(){return t.localizeOperators(a.defaultDateOperators)(this.localization)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"logicOperators",{get:function(){return t.localizeOperators(a.logicOperators)(this.localization)},enumerable:!0,configurable:!0}),e.prototype.addFilterGroup=function(e){e.filters.push({logic:"or",filters:[]})},e.prototype.addFilterExpression=function(e){e.filters.push({operator:"eq",value:null,field:null})},e.prototype.remove=function(e,t,r){var o=this;if(r||(r=this.value),e!==r){var i=r.filters.indexOf(e);i>=0&&i===t?r.filters=r.filters.filter((function(t){return t!==e})):r.filters.forEach((function(r){return r.filters&&o.remove(e,t,r)}))}else r.filters=[]},e=o.__decorate([i.Injectable(),o.__metadata("design:paramtypes",[n.LocalizationService])],e)}();t.FilterService=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.nullOperators=["isnull","isnotnull","isempty","isnotempty"],t.numericOperators=[{text:"Is equal to",value:"eq"},{text:"Not equal to",value:"neq"},{text:"Greater than or equal to",value:"gte"},{text:"Greater than",value:"gt"},{text:"Less than or equal to",value:"lte"},{text:"Less than",value:"lt"},{text:"Is null",value:"isnull"},{text:"Is not null",value:"isnotnull"}],t.stringOperators=[{text:"Is equal to",value:"eq"},{text:"Not equal to",value:"neq"},{text:"Contains",value:"contains"},{text:"Does not contain",value:"doesnotcontain"},{text:"Starts with",value:"startswith"},{text:"Ends with",value:"endswith"},{text:"Is null",value:"isnull"},{text:"Is not null",value:"isnotnull"},{text:"Is empty",value:"isempty"},{text:"Is not empty",value:"isnotempty"}],t.booleanOperators=[{text:"Is equal to",value:"eq"},{text:"Is not equal to",value:"neq"}],t.dateOperators=[{text:"Is equal to",value:"eq"},{text:"Not equal to",value:"neq"},{text:"Greater than or equal to",value:"gte"},{text:"Greater than",value:"gt"},{text:"Less than or equal to",value:"lte"},{text:"Less than",value:"lt"},{text:"Is null",value:"isnull"},{text:"Is not null",value:"isnotnull"}],t.isArray=function(e){return Array.isArray(e)},t.getKeyByValue=function(e,t){return Object.keys(e).find((function(r){return e[r]===t}))},t.defaultStringOperators={filterEqOperator:"eq",filterNotEqOperator:"neq",filterContainsOperator:"contains",filterNotContainsOperator:"doesnotcontain",filterStartsWithOperator:"startswith",filterEndsWithOperator:"endswith",filterIsNullOperator:"isnull",filterIsNotNullOperator:"isnotnull",filterIsEmptyOperator:"isempty",filterIsNotEmptyOperator:"isnotempty"},t.defaultNumericOperators={filterEqOperator:"eq",filterNotEqOperator:"neq",filterGteOperator:"gte",filterGtOperator:"gt",filterLteOperator:"lte",filterLtOperator:"lt",filterIsNullOperator:"isnull",filterIsNotNullOperator:"isnotnull"},t.defaultDateOperators={filterEqOperator:"eq",filterNotEqOperator:"neq",filterAfterOrEqualOperator:"gte",filterAfterOperator:"gt",filterBeforeOrEqualOperator:"lte",filterBeforeOperator:"lt",filterIsNullOperator:"isnull",filterIsNotNullOperator:"isnotnull"},t.defaultOperators={string:t.defaultStringOperators,number:t.defaultNumericOperators,date:t.defaultDateOperators},t.logicOperators={filterAndLogic:"and",filterOrLogic:"or"},t.isFilterEditor=function(e){return["string","number","boolean","date"].indexOf(e)>=0}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=r(0),u=r(8),d=r(9),p=function(){function e(e,t,r){this.filterService=e,this.localization=t,this.cdr=r,this.valueChange=new i.EventEmitter,u.validatePackage(d.packageMetadata),this.direction=t.rtl?"rtl":"ltr"}return Object.defineProperty(e.prototype,"filters",{get:function(){return this.filterService.filters},set:function(e){if(i.isDevMode()&&(!l.isArray(e)||0===e.length))throw new Error("Pass at least one user-defined filter through the [filters] input property. See http://www.telerik.com/kendo-angular-ui/components/filter/#data-binding");this.filterService.filters=e.map((function(e){var t=Object.assign({},e);return t.title||(t.title=t.field),t}))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"value",{get:function(){return this.filterService.value},set:function(e){var t=JSON.parse(JSON.stringify(e));this.normalizeValue(t),this.filterService.value=t},enumerable:!0,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;if(0===this.filters.length)throw new Error("Pass at least one user-defined filter through the [filters] input property. See http://www.telerik.com/kendo-angular-ui/components/filter/#data-binding");this.localization.changes.subscribe((function(t){var r=t.rtl;e.direction=r?"rtl":"ltr",e.cdr.detectChanges()}))},e.prototype.ngOnDestroy=function(){this.localization.changes.unsubscribe()},e.prototype.getCurrentFilter=function(){return this.value},e.prototype.getCurrentFilterChildren=function(){return this.value.filters},e.prototype.onValueChange=function(){this.valueChange.emit(this.filterService.value)},e.prototype.normalizeFilter=function(e){var t=this.filterService.filters.find((function(t){return t.field===e.field}));if(i.isDevMode()&&!t)throw new Error("There is no user-defined filter with '"+e.field+"' field provided through the [filters] input property.");i.isDevMode()&&"boolean"===t.editor&&!e.value&&!1!==e.value&&console.warn("Provide a value for the boolean '"+e.field+"' user-defined filter as the operator is always set to 'eq'."),"boolean"===t.editor&&(e.operator="eq"),"date"===t.editor&&e.value&&(e.value=new Date(e.value)),e.value||!1===e.value||(e.value=null)},e.prototype.normalizeValue=function(e){var t=this;e.filters.forEach((function(e){e.filters?t.normalizeValue(e):t.normalizeFilter(e)}))},o.__decorate([i.HostBinding("attr.dir"),o.__metadata("design:type",String)],e.prototype,"direction",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Array),o.__metadata("design:paramtypes",[Array])],e.prototype,"filters",null),o.__decorate([i.Input(),o.__metadata("design:type",Object),o.__metadata("design:paramtypes",[Object])],e.prototype,"value",null),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter",template:'\n <ng-container kendoFilterLocalizedMessages\n i18n-editorDateTodayText="kendo.filter.editorDateTodayText|The text of the Today button of the Date editor"\n editorDateTodayText="Today"\n\n i18n-editorDateToggleText="kendo.filter.editorDateToggleText|The title of the Toggle button of the Date editor."\n editorDateToggleText="Toggle calendar"\n\n i18n-editorNumericDecrement="kendo.filter.editorNumericDecrement|The title of the Decrement button of the Numeric editor"\n editorNumericDecrement="Decrement"\n\n i18n-editorNumericIncrement="kendo.filter.editorNumericIncrement|The title of the Increment button of the Numeric editor"\n editorNumericIncrement="Increment"\n\n i18n-filterExpressionOperators="kendo.filter.filterExpressionOperators|The text of the Filter Expression Operators drop down"\n filterExpressionOperators="Operators"\n\n i18n-filterExpressionFilters="kendo.filter.filterExpressionFilters|The text of the Filter Expression filters drop down"\n filterExpressionFilters="Fields"\n\n i18n-remove="kendo.filter.remove|The text of the Remove button"\n remove="Remove"\n\n i18n-addFilter="kendo.filter.addFilter|The text of the Add Filter button"\n addFilter="Add Filter"\n\n i18n-addGroup="kendo.filter.addGroup|The text of the Add Group button"\n addGroup="Add Group"\n\n i18n-filterAndLogic="kendo.filter.filterAndLogic|The text of the And filter logic"\n filterAndLogic="And"\n\n i18n-filterOrLogic="kendo.filter.filterOrLogic|The text of the Or filter logic"\n filterOrLogic="Or"\n\n i18n-filterEqOperator="kendo.filter.filterEqOperator|The text of the equal filter operator"\n filterEqOperator="Is equal to"\n\n i18n-filterNotEqOperator="kendo.filter.filterNotEqOperator|The text of the not equal filter operator"\n filterNotEqOperator="Is not equal to"\n\n i18n-filterIsNullOperator="kendo.filter.filterIsNullOperator|The text of the is null filter operator"\n filterIsNullOperator="Is null"\n\n i18n-filterIsNotNullOperator="kendo.filter.filterIsNotNullOperator|The text of the is not null filter operator"\n filterIsNotNullOperator="Is not null"\n\n i18n-filterIsEmptyOperator="kendo.filter.filterIsEmptyOperator|The text of the is empty filter operator"\n filterIsEmptyOperator="Is empty"\n\n i18n-filterIsNotEmptyOperator="kendo.filter.filterIsNotEmptyOperator|The text of the is not empty filter operator"\n filterIsNotEmptyOperator="Is not empty"\n\n i18n-filterStartsWithOperator="kendo.filter.filterStartsWithOperator|The text of the starts with filter operator"\n filterStartsWithOperator="Starts with"\n\n i18n-filterContainsOperator="kendo.filter.filterContainsOperator|The text of the contains filter operator"\n filterContainsOperator="Contains"\n\n i18n-filterNotContainsOperator="kendo.filter.filterNotContainsOperator|The text of the does not contain filter operator"\n filterNotContainsOperator="Does not contain"\n\n i18n-filterEndsWithOperator="kendo.filter.filterEndsWithOperator|The text of the ends with filter operator"\n filterEndsWithOperator="Ends with"\n\n i18n-filterGteOperator="kendo.filter.filterGteOperator|The text of the greater than or equal filter operator"\n filterGteOperator="Is greater than or equal to"\n\n i18n-filterGtOperator="kendo.filter.filterGtOperator|The text of the greater than filter operator"\n filterGtOperator="Is greater than"\n\n i18n-filterLteOperator="kendo.filter.filterLteOperator|The text of the less than or equal filter operator"\n filterLteOperator="Is less than or equal to"\n\n i18n-filterLtOperator="kendo.filter.filterLtOperator|The text of the less than filter operator"\n filterLtOperator="Is less than"\n\n i18n-filterIsTrue="kendo.filter.filterIsTrue|The text of the IsTrue boolean filter option"\n filterIsTrue="Is True"\n\n i18n-filterIsFalse="kendo.filter.filterIsFalse|The text of the IsFalse boolean filter option"\n filterIsFalse="Is False"\n\n i18n-filterBooleanAll="kendo.filter.filterBooleanAll|The text of the (All) boolean filter option"\n filterBooleanAll="(All)"\n\n i18n-filterAfterOrEqualOperator="kendo.filter.filterAfterOrEqualOperator|The text of the after or equal date filter operator"\n filterAfterOrEqualOperator="Is after or equal to"\n\n i18n-filterAfterOperator="kendo.filter.filterAfterOperator|The text of the after date filter operator"\n filterAfterOperator="Is after"\n\n i18n-filterBeforeOperator="kendo.filter.filterBeforeOperator|The text of the before date filter operator"\n filterBeforeOperator="Is before"\n\n i18n-filterBeforeOrEqualOperator="kendo.filter.filterBeforeOrEqualOperator|The text of the before or equal date filter operator"\n filterBeforeOrEqualOperator="Is before or equal to"\n\n i18n-filterFieldAriaLabel="kendo.filter.filterFieldAriaLabel|The text of the filter field aria label"\n filterFieldAriaLabel="field"\n\n i18n-filterOperatorAriaLabel="kendo.filter.filterOperatorAriaLabel|The text of the filter operator aria label"\n filterOperatorAriaLabel="operator"\n\n i18n-filterValueAriaLabel="kendo.filter.filterValueAriaLabel|The text of the filter value aria label"\n filterValueAriaLabel="value"\n\n i18n-filterAriaLabel="kendo.filter.filterAriaLabel|The text of the filter row aria label"\n filterAriaLabel="filter"\n\n i18n-filterToolbarAriaLabel="kendo.filter.filterToolbarAriaLabel|The text of the filter toolbar aria label"\n filterToolbarAriaLabel="filter settings"\n >\n </ng-container>\n <div class="k-widget k-filter" [attr.dir]="direction">\n <ul class=\'k-filter-container\'>\n <li class=\'k-filter-group-main\'>\n <kendo-filter-group\n [currentItem]="getCurrentFilter()"\n (valueChange)="onValueChange()"\n >\n </kendo-filter-group>\n </li>\n </ul>\n </div>\n'}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService,s.ChangeDetectorRef])],e)}();t.FilterComponent=p},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o.__extends(t,e),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterExpressionOperators",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterExpressionFilters",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"remove",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"addGroup",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"addFilter",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAndLogic",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterOrLogic",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterEqOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterNotEqOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsNullOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsNotNullOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsEmptyOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsNotEmptyOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterStartsWithOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterContainsOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterNotContainsOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterEndsWithOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterGteOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterGtOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterLteOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterLtOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsTrue",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsFalse",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterBooleanAll",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAfterOrEqualOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAfterOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterBeforeOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterBeforeOrEqualOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorNumericDecrement",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorNumericIncrement",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorDateTodayText",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorDateToggleText",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterFieldAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterOperatorAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterValueAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterToolbarAriaLabel",void 0),t}(r(2).ComponentMessages);t.Messages=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(5);t.FilterComponent=o.FilterComponent;var i=r(10);t.FilterModule=i.FilterModule},function(e,t){e.exports=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.packageMetadata={name:"@progress/kendo-angular-filter",productName:"Kendo UI for Angular",productCodes:["KENDOUIANGULAR","KENDOUICOMPLETE"],publishDate:1642686699,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning"}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(11),l=r(12),s=r(13),u=r(14),d=r(15),p=r(16),f=r(17),c=r(18),g=r(5),m=r(19),v=r(20),h=r(21),_=function(){function e(){}return e=o.__decorate([i.NgModule({imports:[h.SharedModule],declarations:[g.FilterComponent,u.FilterNumericEditorComponent,d.FilterTextEditorComponent,f.FilterExpressionComponent,c.FilterGroupComponent,p.FilterExpressionOperatorsComponent,l.FilterBooleanEditorComponent,s.FilterDateEditorComponent,v.LocalizedMessagesDirective,m.CustomMessagesComponent,a.AriaLabelValueDirective],exports:[g.FilterComponent,u.FilterNumericEditorComponent,d.FilterTextEditorComponent,f.FilterExpressionComponent,c.FilterGroupComponent,p.FilterExpressionOperatorsComponent,l.FilterBooleanEditorComponent,s.FilterDateEditorComponent,v.LocalizedMessagesDirective,m.CustomMessagesComponent,a.AriaLabelValueDirective],providers:[n.LocalizationService,{provide:n.L10N_PREFIX,useValue:"kendo.filter"}]})],e)}();t.FilterModule=_},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=function(){function e(e,t){this.hostElement=e,this.renderer=t}return e.prototype.ngOnChanges=function(){var e=this.hostElement.nativeElement.querySelector("input")||this.hostElement.nativeElement;this.renderer.setAttribute(e,"aria-label",this.ariaLabel)},o.__decorate([i.Input("kendoAriaLabelValue"),o.__metadata("design:type",String)],e.prototype,"ariaLabel",void 0),e=o.__decorate([i.Directive({selector:"[kendoAriaLabelValue]"}),o.__metadata("design:paramtypes",[i.ElementRef,i.Renderer2])],e)}();t.AriaLabelValueDirective=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=function(){function e(e){this.localization=e,this.valueChange=new i.EventEmitter,this.items=[{text:this.localization.get("filterIsTrue"),value:!0},{text:this.localization.get("filterIsFalse"),value:!1}],this.defaultItem={text:this.localization.get("filterBooleanAll"),value:null}}return e.prototype.messageFor=function(e){return this.localization.get(e)},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-boolean-editor",template:'\n <kendo-dropdownlist\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [data]="items"\n [defaultItem]="defaultItem"\n [valuePrimitive]="true"\n textField="text"\n valueField="value"\n >\n </kendo-dropdownlist>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService])],e)}();t.FilterBooleanEditorComponent=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.localization=e,this.filterService=t,this.valueChange=new i.EventEmitter}return e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.isDisabled=function(){var e=this.filterService.isEditorDisabled;return e&&(this.currentItem.value=null),e},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-date-editor",template:'\n <kendo-datepicker\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [disabled]="isDisabled()">\n <kendo-datepicker-messages\n [toggle]="messageFor(\'editorDateToggleText\')"\n [today]="messageFor(\'editorDateTodayText\')">\n </kendo-datepicker-messages>\n </kendo-datepicker>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService,a.FilterService])],e)}();t.FilterDateEditorComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.localization=e,this.filterService=t,this.valueChange=new i.EventEmitter}return e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.isDisabled=function(){var e=this.filterService.isEditorDisabled;return e&&(this.currentItem.value=null),e},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-numeric-editor",template:'\n <kendo-numerictextbox\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [disabled]="isDisabled()">\n <kendo-numerictextbox-messages\n [increment]="messageFor(\'editorNumericIncrement\')"\n [decrement]="messageFor(\'editorNumericDecrement\')">\n </kendo-numerictextbox-messages>\n </kendo-numerictextbox>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService,a.FilterService])],e)}();t.FilterNumericEditorComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.localization=e,this.filterService=t,this.valueChange=new i.EventEmitter}return e.prototype.isDisabled=function(){var e=this.filterService.isEditorDisabled;return e&&(this.currentItem.value=null),e},e.prototype.messageFor=function(e){return this.localization.get(e)},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-text-editor",template:'\n <kendo-textbox\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [disabled]="isDisabled()">\n </kendo-textbox>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService,a.FilterService])],e)}();t.FilterTextEditorComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=function(){function e(e,t){this.filterService=e,this.localization=t,this.valueChange=new i.EventEmitter,this.operators=[]}return e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.operatorValueChange=function(e){this.valueChange.emit(),this.filterService.isEditorDisabled=l.nullOperators.indexOf(e)>=0},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Array)],e.prototype,"operators",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-expression-operators",template:'\n <kendo-dropdownlist\n [kendoAriaLabelValue]="messageFor(\'filterOperatorAriaLabel\')"\n [data]="operators"\n [title]="messageFor(\'filterExpressionOperators\')"\n [(value)]="currentItem.operator"\n (valueChange)="operatorValueChange($event)"\n [valuePrimitive]="true"\n textField="text"\n valueField="value"\n >\n </kendo-dropdownlist>\n '}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService])],e)}();t.FilterExpressionOperatorsComponent=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=function(){function e(e,t){this.filterService=e,this.localization=t,this.valueChange=new i.EventEmitter,this.operators=[],this.filters=[],this.isBoolean=!1,this.isEditorDisabled=!1}return e.prototype.ngOnInit=function(){if(this.filters=this.filterService.filters,this.currentItem.field){var e=this.getFilterExpressionByField(this.currentItem.field);this.setOperators(e)}if(!this.currentItem.field){this.currentItem.field=this.filterService.filters[0].field;var t=this.getFilterExpressionByField(this.filterService.filters[0].field);this.setOperators(t)}},e.prototype.normalizeOperators=function(e,t){for(var r=[],o=0;o<t.length;o++)l.isFilterEditor(e)&&r.push({value:t[o],text:this.localization.get(l.getKeyByValue(l.defaultOperators[e],t[o]))});return r},e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.getFilterExpressionByField=function(e){var t=this.filterService.filters.find((function(t){return t.field===e}));return t||null},e.prototype.filterValueChange=function(e){this.currentItem.value=null,this.currentItem.field=e;var t=this.getFilterExpressionByField(this.currentItem.field);this.setOperators(t),this.valueChange.emit()},e.prototype.getDefaultOperators=function(e){switch(e){case"string":return this.filterService.defaultStringOperators;case"number":return this.filterService.defaultNumericOperators;case"date":return this.filterService.defaultDateOperators}},e.prototype.getEditorType=function(){var e=this;return this.filterService.filters.find((function(t){return t.field===e.currentItem.field})).editor},e.prototype.removeFilterExpression=function(){this.filterService.remove(this.currentItem,this.index),this.valueChange.emit()},e.prototype.setOperators=function(e){if(this.isBoolean="boolean"===e.editor,!this.isBoolean)if(e.operators){var t=this.normalizeOperators(e.editor,e.operators);this.operators=t,this.currentItem.operator=t[0].value}else this.operators=this.getDefaultOperators(e.editor),this.currentItem.operator=this.operators[0].value},o.__decorate([i.Input(),o.__metadata("design:type",Number)],e.prototype,"index",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-expression",template:'\n <div class="k-filter-toolbar" role="group" [attr.aria-label]="messageFor(\'filterAriaLabel\')">\n <div class="k-toolbar">\n <div class="k-filter-toolbar-item k-filter-field">\n <kendo-dropdownlist\n [kendoAriaLabelValue]="messageFor(\'filterFieldAriaLabel\')"\n [title]="messageFor(\'filterExpressionFilters\')"\n [data]="filters"\n textField="title"\n valueField="field"\n [value]="currentItem.field"\n [valuePrimitive]="true"\n (valueChange)="filterValueChange($event)">\n </kendo-dropdownlist>\n </div>\n <div *ngIf="!isBoolean" class="k-filter-toolbar-item k-filter-operator">\n <kendo-filter-expression-operators\n [currentItem]="currentItem"\n [operators]="operators"\n (valueChange)="valueChange.emit();">\n </kendo-filter-expression-operators>\n </div>\n\n <ng-container [ngSwitch]="getEditorType()">\n <kendo-filter-text-editor *ngSwitchCase="\'string\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-text-editor>\n <kendo-filter-numeric-editor *ngSwitchCase="\'number\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-numeric-editor>\n <kendo-filter-boolean-editor *ngSwitchCase="\'boolean\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-boolean-editor>\n <kendo-filter-date-editor *ngSwitchCase="\'date\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-date-editor>\n </ng-container>\n\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n icon="close"\n fillMode="flat"\n [title]="messageFor(\'remove\')"\n (click)="removeFilterExpression()">\n </button>\n </div>\n </div>\n </div>\n '}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService])],e)}();t.FilterExpressionComponent=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.filterService=e,this.localization=t,this.index=0,this.currentItem={logic:"or",filters:[]},this.valueChange=new i.EventEmitter,this.logicOperators=[]}return e.prototype.ngOnInit=function(){this.logicOperators=this.filterService.logicOperators},e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.selectedChange=function(e){this.currentItem.logic!==e&&(this.currentItem.logic=e,this.valueChange.emit())},e.prototype.addFilterExpression=function(){this.filterService.addFilterExpression(this.currentItem),this.valueChange.emit()},e.prototype.addFilterGroup=function(){this.filterService.addFilterGroup(this.currentItem),this.valueChange.emit()},e.prototype.removeFilterGroup=function(){this.filterService.remove(this.currentItem,this.index),this.valueChange.emit()},o.__decorate([i.Input(),o.__metadata("design:type",Number)],e.prototype,"index",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-group",template:'\n <div class="k-filter-toolbar" role="toolbar" [attr.aria-label]="messageFor(\'filterToolbarAriaLabel\')">\n <div class="k-toolbar">\n <div class="k-filter-toolbar-item">\n <div class="k-widget k-button-group" role="group">\n <button\n *ngFor="let operator of logicOperators"\n kendoButton\n [ngClass]="{\'k-group-start\': operator.value === \'and\', \'k-group-end\': operator.value === \'or\'}"\n [selected]="currentItem.logic === operator.value"\n [title]="operator.text"\n (click)="selectedChange(operator.value)"\n >\n {{operator.text}}\n </button>\n </div>\n </div>\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n [title]="messageFor(\'addFilter\')"\n icon="filter-add-expression"\n (click)="addFilterExpression()">\n {{messageFor(\'addFilter\')}}\n </button>\n </div>\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n [title]="messageFor(\'addGroup\')"\n icon="filter-add-group"\n (click)="addFilterGroup()">\n {{messageFor(\'addGroup\')}}\n </button>\n </div>\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n icon="close"\n fillMode="flat"\n [title]="messageFor(\'remove\')"\n (click)="removeFilterGroup()">\n </button>\n </div>\n </div>\n </div>\n\n <ul class="k-filter-lines" *ngIf="currentItem.filters">\n <ng-container *ngFor="let item of currentItem.filters; let i = index;">\n <li class="k-filter-item" *ngIf="!item.filters">\n <kendo-filter-expression (valueChange)="valueChange.emit()" [currentItem]="item" [index]="i">\n </kendo-filter-expression>\n </li>\n <li class="k-filter-item" *ngIf="item.filters" >\n <kendo-filter-group\n (valueChange)="valueChange.emit()"\n [currentItem]="item"\n [index]="i"\n >\n </kendo-filter-group>\n </li>\n </ng-container>\n </ul>\n '}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService])],e)}();t.FilterGroupComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(6),l=function(e){function t(t){var r=e.call(this)||this;return r.service=t,r}var r;return o.__extends(t,e),r=t,Object.defineProperty(t.prototype,"override",{get:function(){return!0},enumerable:!0,configurable:!0}),t=r=o.__decorate([i.Component({providers:[{provide:a.Messages,useExisting:i.forwardRef((function(){return r}))}],selector:"kendo-filter-messages",template:""}),o.__metadata("design:paramtypes",[n.LocalizationService])],t)}(a.Messages);t.CustomMessagesComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(6),l=function(e){function t(t){var r=e.call(this)||this;return r.service=t,r}var r;return o.__extends(t,e),r=t,t=r=o.__decorate([i.Directive({providers:[{provide:a.Messages,useExisting:i.forwardRef((function(){return r}))}],selector:"[kendoFilterLocalizedMessages]"}),o.__metadata("design:paramtypes",[n.LocalizationService])],t)}(a.Messages);t.LocalizedMessagesDirective=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(22),n=r(23),a=r(24),l=r(25),s=r(0),u=r(26),d=r(3),p=r(27),f=[i.CommonModule,a.InputsModule,l.LabelModule,n.DropDownsModule,u.ButtonsModule,p.DateInputsModule],c=function(){function e(){}return e=o.__decorate([s.NgModule({imports:f.slice(),exports:f.slice(),providers:[d.FilterService]})],e)}();t.SharedModule=c},function(e,t){e.exports=i},function(e,t){e.exports=n},function(e,t){e.exports=a},function(e,t){e.exports=l},function(e,t){e.exports=s},function(e,t){e.exports=u}])}));
5
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@angular/core"),require("tslib"),require("@progress/kendo-angular-l10n"),require("@progress/kendo-licensing"),require("@angular/common"),require("@progress/kendo-angular-dropdowns"),require("@progress/kendo-angular-inputs"),require("@progress/kendo-angular-label"),require("@progress/kendo-angular-buttons"),require("@progress/kendo-angular-dateinputs")):"function"==typeof define&&define.amd?define(["@angular/core","tslib","@progress/kendo-angular-l10n","@progress/kendo-licensing","@angular/common","@progress/kendo-angular-dropdowns","@progress/kendo-angular-inputs","@progress/kendo-angular-label","@progress/kendo-angular-buttons","@progress/kendo-angular-dateinputs"],t):"object"==typeof exports?exports.KendoAngularFilter=t(require("@angular/core"),require("tslib"),require("@progress/kendo-angular-l10n"),require("@progress/kendo-licensing"),require("@angular/common"),require("@progress/kendo-angular-dropdowns"),require("@progress/kendo-angular-inputs"),require("@progress/kendo-angular-label"),require("@progress/kendo-angular-buttons"),require("@progress/kendo-angular-dateinputs")):e.KendoAngularFilter=t(e["@angular/core"],e.tslib,e["@progress/kendo-angular-l10n"],e["@progress/kendo-licensing"],e["@angular/common"],e["@progress/kendo-angular-dropdowns"],e["@progress/kendo-angular-inputs"],e["@progress/kendo-angular-label"],e["@progress/kendo-angular-buttons"],e["@progress/kendo-angular-dateinputs"])}(window,(function(e,t,r,o,i,n,a,l,s,u){return function(e){var t={};function r(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(o,i,function(t){return e[t]}.bind(null,i));return o},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=7)}([function(t,r){t.exports=e},function(e,r){e.exports=t},function(e,t){e.exports=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=function(){function e(){this.value={filters:[],logic:"or"},this.filters=[],this.isEditorDisabled=!1}return e.prototype.addFilterGroup=function(e){e.filters.push({logic:"or",filters:[]})},e.prototype.addFilterExpression=function(e){e.filters.push({operator:"eq",value:null,field:null})},e.prototype.remove=function(e,t,r){var o=this;if(r||(r=this.value),e!==r){var i=r.filters.indexOf(e);i>=0&&i===t?r.filters=r.filters.filter((function(t){return t!==e})):r.filters.forEach((function(r){return r.filters&&o.remove(e,t,r)}))}else r.filters=[]},e=o.__decorate([i.Injectable()],e)}();t.FilterService=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.nullOperators=["isnull","isnotnull","isempty","isnotempty"],t.numericOperators=[{text:"Is equal to",value:"eq"},{text:"Not equal to",value:"neq"},{text:"Greater than or equal to",value:"gte"},{text:"Greater than",value:"gt"},{text:"Less than or equal to",value:"lte"},{text:"Less than",value:"lt"},{text:"Is null",value:"isnull"},{text:"Is not null",value:"isnotnull"}],t.stringOperators=[{text:"Is equal to",value:"eq"},{text:"Not equal to",value:"neq"},{text:"Contains",value:"contains"},{text:"Does not contain",value:"doesnotcontain"},{text:"Starts with",value:"startswith"},{text:"Ends with",value:"endswith"},{text:"Is null",value:"isnull"},{text:"Is not null",value:"isnotnull"},{text:"Is empty",value:"isempty"},{text:"Is not empty",value:"isnotempty"}],t.booleanOperators=[{text:"Is equal to",value:"eq"},{text:"Is not equal to",value:"neq"}],t.dateOperators=[{text:"Is equal to",value:"eq"},{text:"Not equal to",value:"neq"},{text:"Greater than or equal to",value:"gte"},{text:"Greater than",value:"gt"},{text:"Less than or equal to",value:"lte"},{text:"Less than",value:"lt"},{text:"Is null",value:"isnull"},{text:"Is not null",value:"isnotnull"}],t.isArray=function(e){return Array.isArray(e)},t.getKeyByValue=function(e,t){return Object.keys(e).find((function(r){return e[r]===t}))},t.defaultStringOperators={filterEqOperator:"eq",filterNotEqOperator:"neq",filterContainsOperator:"contains",filterNotContainsOperator:"doesnotcontain",filterStartsWithOperator:"startswith",filterEndsWithOperator:"endswith",filterIsNullOperator:"isnull",filterIsNotNullOperator:"isnotnull",filterIsEmptyOperator:"isempty",filterIsNotEmptyOperator:"isnotempty"},t.defaultNumericOperators={filterEqOperator:"eq",filterNotEqOperator:"neq",filterGteOperator:"gte",filterGtOperator:"gt",filterLteOperator:"lte",filterLtOperator:"lt",filterIsNullOperator:"isnull",filterIsNotNullOperator:"isnotnull"},t.defaultDateOperators={filterEqOperator:"eq",filterNotEqOperator:"neq",filterAfterOrEqualOperator:"gte",filterAfterOperator:"gt",filterBeforeOrEqualOperator:"lte",filterBeforeOperator:"lt",filterIsNullOperator:"isnull",filterIsNotNullOperator:"isnotnull"},t.defaultOperators={string:t.defaultStringOperators,number:t.defaultNumericOperators,date:t.defaultDateOperators},t.logicOperators={filterAndLogic:"and",filterOrLogic:"or"},t.isFilterEditor=function(e){return["string","number","boolean","date"].indexOf(e)>=0},t.localizeOperators=function(e){return function(t){return Object.keys(e).map((function(r){return{text:t.get(r),value:e[r]}}))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=r(0),u=r(8),d=r(9),p=function(){function e(e,t,r){this.filterService=e,this.localization=t,this.cdr=r,this.valueChange=new i.EventEmitter,u.validatePackage(d.packageMetadata),this.direction=t.rtl?"rtl":"ltr"}return Object.defineProperty(e.prototype,"filters",{get:function(){return this.filterService.filters},set:function(e){if(i.isDevMode()&&(!l.isArray(e)||0===e.length))throw new Error("Pass at least one user-defined filter through the [filters] input property. See http://www.telerik.com/kendo-angular-ui/components/filter/#data-binding");this.filterService.filters=e.map((function(e){var t=Object.assign({},e);return t.title||(t.title=t.field),t}))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"value",{get:function(){return this.filterService.value},set:function(e){var t=JSON.parse(JSON.stringify(e));this.normalizeValue(t),this.filterService.value=t},enumerable:!0,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;if(0===this.filters.length)throw new Error("Pass at least one user-defined filter through the [filters] input property. See http://www.telerik.com/kendo-angular-ui/components/filter/#data-binding");this.localizationSubscription=this.localization.changes.subscribe((function(t){var r=t.rtl;e.direction=r?"rtl":"ltr",e.cdr.detectChanges()}))},e.prototype.ngOnDestroy=function(){this.localizationSubscription&&this.localizationSubscription.unsubscribe()},e.prototype.getCurrentFilter=function(){return this.value},e.prototype.getCurrentFilterChildren=function(){return this.value.filters},e.prototype.onValueChange=function(){this.valueChange.emit(this.filterService.value)},e.prototype.normalizeFilter=function(e){var t=this.filterService.filters.find((function(t){return t.field===e.field}));if(i.isDevMode()&&!t)throw new Error("There is no user-defined filter with '"+e.field+"' field provided through the [filters] input property.");i.isDevMode()&&"boolean"===t.editor&&!e.value&&!1!==e.value&&console.warn("Provide a value for the boolean '"+e.field+"' user-defined filter as the operator is always set to 'eq'."),"boolean"===t.editor&&(e.operator="eq"),"date"===t.editor&&e.value&&(e.value=new Date(e.value)),e.value||!1===e.value||(e.value=null)},e.prototype.normalizeValue=function(e){var t=this;e.filters.forEach((function(e){e.filters?t.normalizeValue(e):t.normalizeFilter(e)}))},o.__decorate([i.HostBinding("attr.dir"),o.__metadata("design:type",String)],e.prototype,"direction",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Array),o.__metadata("design:paramtypes",[Array])],e.prototype,"filters",null),o.__decorate([i.Input(),o.__metadata("design:type",Object),o.__metadata("design:paramtypes",[Object])],e.prototype,"value",null),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter",template:'\n <ng-container kendoFilterLocalizedMessages\n i18n-editorDateTodayText="kendo.filter.editorDateTodayText|The text of the Today button of the Date editor"\n editorDateTodayText="Today"\n\n i18n-editorDateToggleText="kendo.filter.editorDateToggleText|The title of the Toggle button of the Date editor."\n editorDateToggleText="Toggle calendar"\n\n i18n-editorNumericDecrement="kendo.filter.editorNumericDecrement|The title of the Decrement button of the Numeric editor"\n editorNumericDecrement="Decrement"\n\n i18n-editorNumericIncrement="kendo.filter.editorNumericIncrement|The title of the Increment button of the Numeric editor"\n editorNumericIncrement="Increment"\n\n i18n-filterExpressionOperators="kendo.filter.filterExpressionOperators|The text of the Filter Expression Operators drop down"\n filterExpressionOperators="Operators"\n\n i18n-filterExpressionFilters="kendo.filter.filterExpressionFilters|The text of the Filter Expression filters drop down"\n filterExpressionFilters="Fields"\n\n i18n-remove="kendo.filter.remove|The text of the Remove button"\n remove="Remove"\n\n i18n-addFilter="kendo.filter.addFilter|The text of the Add Filter button"\n addFilter="Add Filter"\n\n i18n-addGroup="kendo.filter.addGroup|The text of the Add Group button"\n addGroup="Add Group"\n\n i18n-filterAndLogic="kendo.filter.filterAndLogic|The text of the And filter logic"\n filterAndLogic="And"\n\n i18n-filterOrLogic="kendo.filter.filterOrLogic|The text of the Or filter logic"\n filterOrLogic="Or"\n\n i18n-filterEqOperator="kendo.filter.filterEqOperator|The text of the equal filter operator"\n filterEqOperator="Is equal to"\n\n i18n-filterNotEqOperator="kendo.filter.filterNotEqOperator|The text of the not equal filter operator"\n filterNotEqOperator="Is not equal to"\n\n i18n-filterIsNullOperator="kendo.filter.filterIsNullOperator|The text of the is null filter operator"\n filterIsNullOperator="Is null"\n\n i18n-filterIsNotNullOperator="kendo.filter.filterIsNotNullOperator|The text of the is not null filter operator"\n filterIsNotNullOperator="Is not null"\n\n i18n-filterIsEmptyOperator="kendo.filter.filterIsEmptyOperator|The text of the is empty filter operator"\n filterIsEmptyOperator="Is empty"\n\n i18n-filterIsNotEmptyOperator="kendo.filter.filterIsNotEmptyOperator|The text of the is not empty filter operator"\n filterIsNotEmptyOperator="Is not empty"\n\n i18n-filterStartsWithOperator="kendo.filter.filterStartsWithOperator|The text of the starts with filter operator"\n filterStartsWithOperator="Starts with"\n\n i18n-filterContainsOperator="kendo.filter.filterContainsOperator|The text of the contains filter operator"\n filterContainsOperator="Contains"\n\n i18n-filterNotContainsOperator="kendo.filter.filterNotContainsOperator|The text of the does not contain filter operator"\n filterNotContainsOperator="Does not contain"\n\n i18n-filterEndsWithOperator="kendo.filter.filterEndsWithOperator|The text of the ends with filter operator"\n filterEndsWithOperator="Ends with"\n\n i18n-filterGteOperator="kendo.filter.filterGteOperator|The text of the greater than or equal filter operator"\n filterGteOperator="Is greater than or equal to"\n\n i18n-filterGtOperator="kendo.filter.filterGtOperator|The text of the greater than filter operator"\n filterGtOperator="Is greater than"\n\n i18n-filterLteOperator="kendo.filter.filterLteOperator|The text of the less than or equal filter operator"\n filterLteOperator="Is less than or equal to"\n\n i18n-filterLtOperator="kendo.filter.filterLtOperator|The text of the less than filter operator"\n filterLtOperator="Is less than"\n\n i18n-filterIsTrue="kendo.filter.filterIsTrue|The text of the IsTrue boolean filter option"\n filterIsTrue="Is True"\n\n i18n-filterIsFalse="kendo.filter.filterIsFalse|The text of the IsFalse boolean filter option"\n filterIsFalse="Is False"\n\n i18n-filterBooleanAll="kendo.filter.filterBooleanAll|The text of the (All) boolean filter option"\n filterBooleanAll="(All)"\n\n i18n-filterAfterOrEqualOperator="kendo.filter.filterAfterOrEqualOperator|The text of the after or equal date filter operator"\n filterAfterOrEqualOperator="Is after or equal to"\n\n i18n-filterAfterOperator="kendo.filter.filterAfterOperator|The text of the after date filter operator"\n filterAfterOperator="Is after"\n\n i18n-filterBeforeOperator="kendo.filter.filterBeforeOperator|The text of the before date filter operator"\n filterBeforeOperator="Is before"\n\n i18n-filterBeforeOrEqualOperator="kendo.filter.filterBeforeOrEqualOperator|The text of the before or equal date filter operator"\n filterBeforeOrEqualOperator="Is before or equal to"\n\n i18n-filterFieldAriaLabel="kendo.filter.filterFieldAriaLabel|The text of the filter field aria label"\n filterFieldAriaLabel="field"\n\n i18n-filterOperatorAriaLabel="kendo.filter.filterOperatorAriaLabel|The text of the filter operator aria label"\n filterOperatorAriaLabel="operator"\n\n i18n-filterValueAriaLabel="kendo.filter.filterValueAriaLabel|The text of the filter value aria label"\n filterValueAriaLabel="value"\n\n i18n-filterAriaLabel="kendo.filter.filterAriaLabel|The text of the filter row aria label"\n filterAriaLabel="filter"\n\n i18n-filterToolbarAriaLabel="kendo.filter.filterToolbarAriaLabel|The text of the filter toolbar aria label"\n filterToolbarAriaLabel="filter settings"\n >\n </ng-container>\n <div class="k-widget k-filter" [attr.dir]="direction">\n <ul class=\'k-filter-container\'>\n <li class=\'k-filter-group-main\'>\n <kendo-filter-group\n [currentItem]="getCurrentFilter()"\n (valueChange)="onValueChange()"\n >\n </kendo-filter-group>\n </li>\n </ul>\n </div>\n'}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService,s.ChangeDetectorRef])],e)}();t.FilterComponent=p},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o.__extends(t,e),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterExpressionOperators",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterExpressionFilters",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"remove",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"addGroup",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"addFilter",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAndLogic",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterOrLogic",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterEqOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterNotEqOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsNullOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsNotNullOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsEmptyOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsNotEmptyOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterStartsWithOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterContainsOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterNotContainsOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterEndsWithOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterGteOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterGtOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterLteOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterLtOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsTrue",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterIsFalse",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterBooleanAll",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAfterOrEqualOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAfterOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterBeforeOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterBeforeOrEqualOperator",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorNumericDecrement",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorNumericIncrement",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorDateTodayText",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"editorDateToggleText",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterFieldAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterOperatorAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterValueAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterAriaLabel",void 0),o.__decorate([i.Input(),o.__metadata("design:type",String)],t.prototype,"filterToolbarAriaLabel",void 0),t}(r(2).ComponentMessages);t.Messages=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(5);t.FilterComponent=o.FilterComponent;var i=r(10);t.FilterModule=i.FilterModule},function(e,t){e.exports=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.packageMetadata={name:"@progress/kendo-angular-filter",productName:"Kendo UI for Angular",productCodes:["KENDOUIANGULAR","KENDOUICOMPLETE"],publishDate:1644849341,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning"}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(11),l=r(12),s=r(13),u=r(14),d=r(15),p=r(16),f=r(17),c=r(18),g=r(5),m=r(19),v=r(20),h=r(21),_=function(){function e(){}return e=o.__decorate([i.NgModule({imports:[h.SharedModule],declarations:[g.FilterComponent,u.FilterNumericEditorComponent,d.FilterTextEditorComponent,f.FilterExpressionComponent,c.FilterGroupComponent,p.FilterExpressionOperatorsComponent,l.FilterBooleanEditorComponent,s.FilterDateEditorComponent,v.LocalizedMessagesDirective,m.CustomMessagesComponent,a.AriaLabelValueDirective],exports:[g.FilterComponent,u.FilterNumericEditorComponent,d.FilterTextEditorComponent,f.FilterExpressionComponent,c.FilterGroupComponent,p.FilterExpressionOperatorsComponent,l.FilterBooleanEditorComponent,s.FilterDateEditorComponent,v.LocalizedMessagesDirective,m.CustomMessagesComponent,a.AriaLabelValueDirective],providers:[n.LocalizationService,{provide:n.L10N_PREFIX,useValue:"kendo.filter"}]})],e)}();t.FilterModule=_},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=function(){function e(e,t){this.hostElement=e,this.renderer=t}return e.prototype.ngOnChanges=function(){var e=this.hostElement.nativeElement.querySelector("input")||this.hostElement.nativeElement;this.renderer.setAttribute(e,"aria-label",this.ariaLabel)},o.__decorate([i.Input("kendoAriaLabelValue"),o.__metadata("design:type",String)],e.prototype,"ariaLabel",void 0),e=o.__decorate([i.Directive({selector:"[kendoAriaLabelValue]"}),o.__metadata("design:paramtypes",[i.ElementRef,i.Renderer2])],e)}();t.AriaLabelValueDirective=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=function(){function e(e){this.localization=e,this.valueChange=new i.EventEmitter,this.items=[{text:this.localization.get("filterIsTrue"),value:!0},{text:this.localization.get("filterIsFalse"),value:!1}],this.defaultItem={text:this.localization.get("filterBooleanAll"),value:null}}return e.prototype.messageFor=function(e){return this.localization.get(e)},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-boolean-editor",template:'\n <kendo-dropdownlist\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [data]="items"\n [defaultItem]="defaultItem"\n [valuePrimitive]="true"\n textField="text"\n valueField="value"\n >\n </kendo-dropdownlist>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService])],e)}();t.FilterBooleanEditorComponent=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.localization=e,this.filterService=t,this.valueChange=new i.EventEmitter}return e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.isDisabled=function(){var e=this.filterService.isEditorDisabled;return e&&(this.currentItem.value=null),e},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-date-editor",template:'\n <kendo-datepicker\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [disabled]="isDisabled()">\n <kendo-datepicker-messages\n [toggle]="messageFor(\'editorDateToggleText\')"\n [today]="messageFor(\'editorDateTodayText\')">\n </kendo-datepicker-messages>\n </kendo-datepicker>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService,a.FilterService])],e)}();t.FilterDateEditorComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.localization=e,this.filterService=t,this.valueChange=new i.EventEmitter}return e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.isDisabled=function(){var e=this.filterService.isEditorDisabled;return e&&(this.currentItem.value=null),e},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-numeric-editor",template:'\n <kendo-numerictextbox\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [disabled]="isDisabled()">\n <kendo-numerictextbox-messages\n [increment]="messageFor(\'editorNumericIncrement\')"\n [decrement]="messageFor(\'editorNumericDecrement\')">\n </kendo-numerictextbox-messages>\n </kendo-numerictextbox>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService,a.FilterService])],e)}();t.FilterNumericEditorComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=function(){function e(e,t){this.localization=e,this.filterService=t,this.valueChange=new i.EventEmitter}return e.prototype.isDisabled=function(){var e=this.filterService.isEditorDisabled;return e&&(this.currentItem.value=null),e},e.prototype.messageFor=function(e){return this.localization.get(e)},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-text-editor",template:'\n <kendo-textbox\n [kendoAriaLabelValue]="messageFor(\'filterValueAriaLabel\')"\n class="k-filter-toolbar-item k-filter-value"\n [(value)]="currentItem.value"\n (valueChange)="valueChange.emit()"\n [disabled]="isDisabled()">\n </kendo-textbox>\n '}),o.__metadata("design:paramtypes",[n.LocalizationService,a.FilterService])],e)}();t.FilterTextEditorComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=function(){function e(e,t){this.filterService=e,this.localization=t,this.valueChange=new i.EventEmitter,this.operators=[]}return e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.operatorValueChange=function(e){this.valueChange.emit(),this.filterService.isEditorDisabled=l.nullOperators.indexOf(e)>=0},o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Array)],e.prototype,"operators",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-expression-operators",template:'\n <kendo-dropdownlist\n [kendoAriaLabelValue]="messageFor(\'filterOperatorAriaLabel\')"\n [data]="operators"\n [title]="messageFor(\'filterExpressionOperators\')"\n [(value)]="currentItem.operator"\n (valueChange)="operatorValueChange($event)"\n [valuePrimitive]="true"\n textField="text"\n valueField="value"\n >\n </kendo-dropdownlist>\n '}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService])],e)}();t.FilterExpressionOperatorsComponent=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=function(){function e(e,t){this.filterService=e,this.localization=t,this.valueChange=new i.EventEmitter,this.operators=[],this.filters=[],this.isBoolean=!1,this.isEditorDisabled=!1}return e.prototype.ngOnInit=function(){if(this.filters=this.filterService.filters,this.currentItem.field){var e=this.getFilterExpressionByField(this.currentItem.field);this.setOperators(e)}if(!this.currentItem.field){this.currentItem.field=this.filterService.filters[0].field;var t=this.getFilterExpressionByField(this.filterService.filters[0].field);this.setOperators(t)}},e.prototype.normalizeOperators=function(e,t){for(var r=[],o=0;o<t.length;o++)l.isFilterEditor(e)&&r.push({value:t[o],text:this.localization.get(l.getKeyByValue(l.defaultOperators[e],t[o]))});return r},e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.getFilterExpressionByField=function(e){var t=this.filterService.filters.find((function(t){return t.field===e}));return t||null},e.prototype.filterValueChange=function(e){this.currentItem.value=null,this.currentItem.field=e;var t=this.getFilterExpressionByField(this.currentItem.field);this.setOperators(t),this.valueChange.emit()},e.prototype.getDefaultOperators=function(e){switch(e){case"string":return l.localizeOperators(l.defaultDateOperators)(this.localization);case"number":return l.localizeOperators(l.defaultNumericOperators)(this.localization);case"date":return l.localizeOperators(l.defaultDateOperators)(this.localization)}},e.prototype.getEditorType=function(){var e=this;return this.filterService.filters.find((function(t){return t.field===e.currentItem.field})).editor},e.prototype.removeFilterExpression=function(){this.filterService.remove(this.currentItem,this.index),this.valueChange.emit()},e.prototype.setOperators=function(e){if(this.isBoolean="boolean"===e.editor,!this.isBoolean)if(e.operators){var t=this.normalizeOperators(e.editor,e.operators);this.operators=t,this.currentItem.operator=t[0].value}else this.operators=this.getDefaultOperators(e.editor),this.currentItem.operator=this.operators[0].value},o.__decorate([i.Input(),o.__metadata("design:type",Number)],e.prototype,"index",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-expression",template:'\n <div class="k-filter-toolbar" role="group" [attr.aria-label]="messageFor(\'filterAriaLabel\')">\n <div class="k-toolbar">\n <div class="k-filter-toolbar-item k-filter-field">\n <kendo-dropdownlist\n [kendoAriaLabelValue]="messageFor(\'filterFieldAriaLabel\')"\n [title]="messageFor(\'filterExpressionFilters\')"\n [data]="filters"\n textField="title"\n valueField="field"\n [value]="currentItem.field"\n [valuePrimitive]="true"\n (valueChange)="filterValueChange($event)">\n </kendo-dropdownlist>\n </div>\n <div *ngIf="!isBoolean" class="k-filter-toolbar-item k-filter-operator">\n <kendo-filter-expression-operators\n [currentItem]="currentItem"\n [operators]="operators"\n (valueChange)="valueChange.emit();">\n </kendo-filter-expression-operators>\n </div>\n\n <ng-container [ngSwitch]="getEditorType()">\n <kendo-filter-text-editor *ngSwitchCase="\'string\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-text-editor>\n <kendo-filter-numeric-editor *ngSwitchCase="\'number\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-numeric-editor>\n <kendo-filter-boolean-editor *ngSwitchCase="\'boolean\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-boolean-editor>\n <kendo-filter-date-editor *ngSwitchCase="\'date\'" [currentItem]="currentItem" (valueChange)="valueChange.emit()"></kendo-filter-date-editor>\n </ng-container>\n\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n icon="close"\n fillMode="flat"\n [title]="messageFor(\'remove\')"\n (click)="removeFilterExpression()">\n </button>\n </div>\n </div>\n </div>\n '}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService])],e)}();t.FilterExpressionComponent=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(3),l=r(4),s=function(){function e(e,t){this.filterService=e,this.localization=t,this.index=0,this.currentItem={logic:"or",filters:[]},this.valueChange=new i.EventEmitter}return Object.defineProperty(e.prototype,"logicOperators",{get:function(){return l.localizeOperators(l.logicOperators)(this.localization)},enumerable:!0,configurable:!0}),e.prototype.messageFor=function(e){return this.localization.get(e)},e.prototype.selectedChange=function(e){this.currentItem.logic!==e&&(this.currentItem.logic=e,this.valueChange.emit())},e.prototype.addFilterExpression=function(){this.filterService.addFilterExpression(this.currentItem),this.valueChange.emit()},e.prototype.addFilterGroup=function(){this.filterService.addFilterGroup(this.currentItem),this.valueChange.emit()},e.prototype.removeFilterGroup=function(){this.filterService.remove(this.currentItem,this.index),this.valueChange.emit()},o.__decorate([i.Input(),o.__metadata("design:type",Number)],e.prototype,"index",void 0),o.__decorate([i.Input(),o.__metadata("design:type",Object)],e.prototype,"currentItem",void 0),o.__decorate([i.Output(),o.__metadata("design:type",i.EventEmitter)],e.prototype,"valueChange",void 0),e=o.__decorate([i.Component({selector:"kendo-filter-group",template:'\n <div class="k-filter-toolbar" role="toolbar" [attr.aria-label]="messageFor(\'filterToolbarAriaLabel\')">\n <div class="k-toolbar">\n <div class="k-filter-toolbar-item">\n <div class="k-widget k-button-group" role="group">\n <button\n *ngFor="let operator of logicOperators"\n kendoButton\n [ngClass]="{\'k-group-start\': operator.value === \'and\', \'k-group-end\': operator.value === \'or\'}"\n [selected]="currentItem.logic === operator.value"\n [title]="operator.text"\n (click)="selectedChange(operator.value)"\n >\n {{operator.text}}\n </button>\n </div>\n </div>\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n [title]="messageFor(\'addFilter\')"\n icon="filter-add-expression"\n (click)="addFilterExpression()">\n {{messageFor(\'addFilter\')}}\n </button>\n </div>\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n [title]="messageFor(\'addGroup\')"\n icon="filter-add-group"\n (click)="addFilterGroup()">\n {{messageFor(\'addGroup\')}}\n </button>\n </div>\n <div class="k-filter-toolbar-item">\n <button\n kendoButton\n icon="close"\n fillMode="flat"\n [title]="messageFor(\'remove\')"\n (click)="removeFilterGroup()">\n </button>\n </div>\n </div>\n </div>\n\n <ul class="k-filter-lines" *ngIf="currentItem.filters">\n <ng-container *ngFor="let item of currentItem.filters; let i = index;">\n <li class="k-filter-item" *ngIf="!item.filters">\n <kendo-filter-expression (valueChange)="valueChange.emit()" [currentItem]="item" [index]="i">\n </kendo-filter-expression>\n </li>\n <li class="k-filter-item" *ngIf="item.filters" >\n <kendo-filter-group\n (valueChange)="valueChange.emit()"\n [currentItem]="item"\n [index]="i"\n >\n </kendo-filter-group>\n </li>\n </ng-container>\n </ul>\n '}),o.__metadata("design:paramtypes",[a.FilterService,n.LocalizationService])],e)}();t.FilterGroupComponent=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(6),l=function(e){function t(t){var r=e.call(this)||this;return r.service=t,r}var r;return o.__extends(t,e),r=t,Object.defineProperty(t.prototype,"override",{get:function(){return!0},enumerable:!0,configurable:!0}),t=r=o.__decorate([i.Component({providers:[{provide:a.Messages,useExisting:i.forwardRef((function(){return r}))}],selector:"kendo-filter-messages",template:""}),o.__metadata("design:paramtypes",[n.LocalizationService])],t)}(a.Messages);t.CustomMessagesComponent=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(0),n=r(2),a=r(6),l=function(e){function t(t){var r=e.call(this)||this;return r.service=t,r}var r;return o.__extends(t,e),r=t,t=r=o.__decorate([i.Directive({providers:[{provide:a.Messages,useExisting:i.forwardRef((function(){return r}))}],selector:"[kendoFilterLocalizedMessages]"}),o.__metadata("design:paramtypes",[n.LocalizationService])],t)}(a.Messages);t.LocalizedMessagesDirective=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(1),i=r(22),n=r(23),a=r(24),l=r(25),s=r(0),u=r(26),d=r(3),p=r(27),f=[i.CommonModule,a.InputsModule,l.LabelModule,n.DropDownsModule,u.ButtonsModule,p.DateInputsModule],c=function(){function e(){}return e=o.__decorate([s.NgModule({imports:f.slice(),exports:f.slice(),providers:[d.FilterService]})],e)}();t.SharedModule=c},function(e,t){e.exports=i},function(e,t){e.exports=n},function(e,t){e.exports=a},function(e,t){e.exports=l},function(e,t){e.exports=s},function(e,t){e.exports=u}])}));
@@ -6,7 +6,7 @@ import * as tslib_1 from "tslib";
6
6
  import { Component, EventEmitter, Input, Output } from '@angular/core';
7
7
  import { LocalizationService } from '@progress/kendo-angular-l10n';
8
8
  import { FilterService } from './filter.service';
9
- import { defaultOperators, getKeyByValue, isFilterEditor } from './util';
9
+ import { defaultDateOperators, defaultNumericOperators, defaultOperators, getKeyByValue, isFilterEditor, localizeOperators } from './util';
10
10
  /**
11
11
  * @hidden
12
12
  */
@@ -64,11 +64,11 @@ var FilterExpressionComponent = /** @class */ (function () {
64
64
  FilterExpressionComponent.prototype.getDefaultOperators = function (operatorsType) {
65
65
  switch (operatorsType) {
66
66
  case 'string':
67
- return this.filterService.defaultStringOperators;
67
+ return localizeOperators(defaultDateOperators)(this.localization);
68
68
  case 'number':
69
- return this.filterService.defaultNumericOperators;
69
+ return localizeOperators(defaultNumericOperators)(this.localization);
70
70
  case 'date':
71
- return this.filterService.defaultDateOperators;
71
+ return localizeOperators(defaultDateOperators)(this.localization);
72
72
  default:
73
73
  break;
74
74
  }
@@ -6,6 +6,7 @@ import * as tslib_1 from "tslib";
6
6
  import { Component, EventEmitter, Input, Output } from '@angular/core';
7
7
  import { LocalizationService } from '@progress/kendo-angular-l10n';
8
8
  import { FilterService } from './filter.service';
9
+ import { localizeOperators, logicOperators } from './util';
9
10
  /**
10
11
  * @hidden
11
12
  */
@@ -19,11 +20,14 @@ var FilterGroupComponent = /** @class */ (function () {
19
20
  filters: []
20
21
  };
21
22
  this.valueChange = new EventEmitter();
22
- this.logicOperators = [];
23
23
  }
24
- FilterGroupComponent.prototype.ngOnInit = function () {
25
- this.logicOperators = this.filterService.logicOperators;
26
- };
24
+ Object.defineProperty(FilterGroupComponent.prototype, "logicOperators", {
25
+ get: function () {
26
+ return localizeOperators(logicOperators)(this.localization);
27
+ },
28
+ enumerable: true,
29
+ configurable: true
30
+ });
27
31
  FilterGroupComponent.prototype.messageFor = function (key) {
28
32
  return this.localization.get(key);
29
33
  };
@@ -97,14 +97,16 @@ var FilterComponent = /** @class */ (function () {
97
97
  if (this.filters.length === 0) {
98
98
  throw new Error("Pass at least one user-defined filter through the [filters] input property. See http://www.telerik.com/kendo-angular-ui/components/filter/#data-binding");
99
99
  }
100
- this.localization.changes.subscribe(function (_a) {
100
+ this.localizationSubscription = this.localization.changes.subscribe(function (_a) {
101
101
  var rtl = _a.rtl;
102
102
  _this.direction = rtl ? 'rtl' : 'ltr';
103
103
  _this.cdr.detectChanges();
104
104
  });
105
105
  };
106
106
  FilterComponent.prototype.ngOnDestroy = function () {
107
- this.localization.changes.unsubscribe();
107
+ if (this.localizationSubscription) {
108
+ this.localizationSubscription.unsubscribe();
109
+ }
108
110
  };
109
111
  /**
110
112
  * @hidden
@@ -4,53 +4,15 @@
4
4
  *-------------------------------------------------------------------------------------------*/
5
5
  import * as tslib_1 from "tslib";
6
6
  import { Injectable } from '@angular/core';
7
- import { LocalizationService } from '@progress/kendo-angular-l10n';
8
- import { defaultDateOperators, defaultNumericOperators, defaultStringOperators, logicOperators } from './util';
9
- /**
10
- * @hidden
11
- */
12
- export var localizeOperators = function (operators) { return function (localization) { return Object.keys(operators).map(function (key) { return ({
13
- text: localization.get(key),
14
- value: operators[key]
15
- }); }); }; };
16
7
  /**
17
8
  * @hidden
18
9
  */
19
10
  var FilterService = /** @class */ (function () {
20
- function FilterService(localization) {
21
- this.localization = localization;
11
+ function FilterService() {
22
12
  this.value = { filters: [], logic: 'or' };
23
13
  this.filters = [];
24
14
  this.isEditorDisabled = false;
25
15
  }
26
- Object.defineProperty(FilterService.prototype, "defaultNumericOperators", {
27
- get: function () {
28
- return localizeOperators(defaultNumericOperators)(this.localization);
29
- },
30
- enumerable: true,
31
- configurable: true
32
- });
33
- Object.defineProperty(FilterService.prototype, "defaultStringOperators", {
34
- get: function () {
35
- return localizeOperators(defaultStringOperators)(this.localization);
36
- },
37
- enumerable: true,
38
- configurable: true
39
- });
40
- Object.defineProperty(FilterService.prototype, "defaultDateOperators", {
41
- get: function () {
42
- return localizeOperators(defaultDateOperators)(this.localization);
43
- },
44
- enumerable: true,
45
- configurable: true
46
- });
47
- Object.defineProperty(FilterService.prototype, "logicOperators", {
48
- get: function () {
49
- return localizeOperators(logicOperators)(this.localization);
50
- },
51
- enumerable: true,
52
- configurable: true
53
- });
54
16
  FilterService.prototype.addFilterGroup = function (item) {
55
17
  var filterGroup = { logic: 'or', filters: [] };
56
18
  item.filters.push(filterGroup);
@@ -76,8 +38,7 @@ var FilterService = /** @class */ (function () {
76
38
  parentItem.filters.forEach(function (filter) { return filter.filters && _this.remove(item, positionIndex, filter); });
77
39
  };
78
40
  FilterService = tslib_1.__decorate([
79
- Injectable(),
80
- tslib_1.__metadata("design:paramtypes", [LocalizationService])
41
+ Injectable()
81
42
  ], FilterService);
82
43
  return FilterService;
83
44
  }());
@@ -9,7 +9,7 @@ export var packageMetadata = {
9
9
  name: '@progress/kendo-angular-filter',
10
10
  productName: 'Kendo UI for Angular',
11
11
  productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
12
- publishDate: 1642686699,
12
+ publishDate: 1644849341,
13
13
  version: '',
14
14
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
15
15
  };
package/dist/es/util.js CHANGED
@@ -127,3 +127,10 @@ export var isFilterEditor = function (editorType) {
127
127
  var supportedEditorTypes = ['string', 'number', 'boolean', 'date'];
128
128
  return supportedEditorTypes.indexOf(editorType) >= 0;
129
129
  };
130
+ /**
131
+ * @hidden
132
+ */
133
+ export var localizeOperators = function (operators) { return function (localization) { return Object.keys(operators).map(function (key) { return ({
134
+ text: localization.get(key),
135
+ value: operators[key]
136
+ }); }); }; };
@@ -6,7 +6,7 @@ import * as tslib_1 from "tslib";
6
6
  import { Component, EventEmitter, Input, Output } from '@angular/core';
7
7
  import { LocalizationService } from '@progress/kendo-angular-l10n';
8
8
  import { FilterService } from './filter.service';
9
- import { defaultOperators, getKeyByValue, isFilterEditor } from './util';
9
+ import { defaultDateOperators, defaultNumericOperators, defaultOperators, getKeyByValue, isFilterEditor, localizeOperators } from './util';
10
10
  /**
11
11
  * @hidden
12
12
  */
@@ -64,11 +64,11 @@ let FilterExpressionComponent = class FilterExpressionComponent {
64
64
  getDefaultOperators(operatorsType) {
65
65
  switch (operatorsType) {
66
66
  case 'string':
67
- return this.filterService.defaultStringOperators;
67
+ return localizeOperators(defaultDateOperators)(this.localization);
68
68
  case 'number':
69
- return this.filterService.defaultNumericOperators;
69
+ return localizeOperators(defaultNumericOperators)(this.localization);
70
70
  case 'date':
71
- return this.filterService.defaultDateOperators;
71
+ return localizeOperators(defaultDateOperators)(this.localization);
72
72
  default:
73
73
  break;
74
74
  }
@@ -2,25 +2,24 @@
2
2
  * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
3
  * Licensed under commercial license. See LICENSE.md in the project root for more information
4
4
  *-------------------------------------------------------------------------------------------*/
5
- import { EventEmitter, OnInit } from '@angular/core';
5
+ import { EventEmitter } from '@angular/core';
6
6
  import { LocalizationService } from '@progress/kendo-angular-l10n';
7
7
  import { CompositeFilterDescriptor } from '@progress/kendo-data-query';
8
8
  import { FilterService } from './filter.service';
9
9
  /**
10
10
  * @hidden
11
11
  */
12
- export declare class FilterGroupComponent implements OnInit {
12
+ export declare class FilterGroupComponent {
13
13
  private filterService;
14
14
  localization: LocalizationService;
15
15
  index: number;
16
16
  currentItem: CompositeFilterDescriptor;
17
17
  valueChange: EventEmitter<void>;
18
- logicOperators: {
18
+ constructor(filterService: FilterService, localization: LocalizationService);
19
+ readonly logicOperators: {
19
20
  text: string;
20
21
  value: string;
21
22
  }[];
22
- constructor(filterService: FilterService, localization: LocalizationService);
23
- ngOnInit(): void;
24
23
  messageFor(key: string): string;
25
24
  selectedChange(logicOperator: 'or' | 'and'): void;
26
25
  addFilterExpression(): void;
@@ -6,6 +6,7 @@ import * as tslib_1 from "tslib";
6
6
  import { Component, EventEmitter, Input, Output } from '@angular/core';
7
7
  import { LocalizationService } from '@progress/kendo-angular-l10n';
8
8
  import { FilterService } from './filter.service';
9
+ import { localizeOperators, logicOperators } from './util';
9
10
  /**
10
11
  * @hidden
11
12
  */
@@ -19,10 +20,9 @@ let FilterGroupComponent = class FilterGroupComponent {
19
20
  filters: []
20
21
  };
21
22
  this.valueChange = new EventEmitter();
22
- this.logicOperators = [];
23
23
  }
24
- ngOnInit() {
25
- this.logicOperators = this.filterService.logicOperators;
24
+ get logicOperators() {
25
+ return localizeOperators(logicOperators)(this.localization);
26
26
  }
27
27
  messageFor(key) {
28
28
  return this.localization.get(key);
@@ -60,6 +60,7 @@ export declare class FilterComponent implements OnInit, OnDestroy {
60
60
  * That is each time a Filter Group or Filter Expression is added, removed, or updated.
61
61
  */
62
62
  valueChange: EventEmitter<CompositeFilterDescriptor>;
63
+ private localizationSubscription;
63
64
  constructor(filterService: FilterService, localization: LocalizationService, cdr: ChangeDetectorRef);
64
65
  ngOnInit(): void;
65
66
  ngOnDestroy(): void;
@@ -88,13 +88,15 @@ let FilterComponent = class FilterComponent {
88
88
  if (this.filters.length === 0) {
89
89
  throw new Error(`Pass at least one user-defined filter through the [filters] input property. See http://www.telerik.com/kendo-angular-ui/components/filter/#data-binding`);
90
90
  }
91
- this.localization.changes.subscribe(({ rtl }) => {
91
+ this.localizationSubscription = this.localization.changes.subscribe(({ rtl }) => {
92
92
  this.direction = rtl ? 'rtl' : 'ltr';
93
93
  this.cdr.detectChanges();
94
94
  });
95
95
  }
96
96
  ngOnDestroy() {
97
- this.localization.changes.unsubscribe();
97
+ if (this.localizationSubscription) {
98
+ this.localizationSubscription.unsubscribe();
99
+ }
98
100
  }
99
101
  /**
100
102
  * @hidden
@@ -2,41 +2,15 @@
2
2
  * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
3
  * Licensed under commercial license. See LICENSE.md in the project root for more information
4
4
  *-------------------------------------------------------------------------------------------*/
5
- import { LocalizationService } from '@progress/kendo-angular-l10n';
6
5
  import { CompositeFilterDescriptor, FilterDescriptor } from '@progress/kendo-data-query';
7
6
  import { FilterExpression } from './model/filter-expression';
8
- /**
9
- * @hidden
10
- */
11
- export declare const localizeOperators: (operators: any) => (localization: any) => {
12
- text: any;
13
- value: any;
14
- }[];
15
7
  /**
16
8
  * @hidden
17
9
  */
18
10
  export declare class FilterService {
19
- private localization;
20
11
  value: CompositeFilterDescriptor;
21
12
  filters: FilterExpression[];
22
13
  isEditorDisabled: boolean;
23
- constructor(localization: LocalizationService);
24
- readonly defaultNumericOperators: {
25
- text: string;
26
- value: string;
27
- }[];
28
- readonly defaultStringOperators: {
29
- text: string;
30
- value: string;
31
- }[];
32
- readonly defaultDateOperators: {
33
- text: string;
34
- value: string;
35
- }[];
36
- readonly logicOperators: {
37
- text: string;
38
- value: string;
39
- }[];
40
14
  addFilterGroup(item: CompositeFilterDescriptor): void;
41
15
  addFilterExpression(item: CompositeFilterDescriptor): void;
42
16
  remove(item: CompositeFilterDescriptor | FilterDescriptor, positionIndex: number, parentItem?: CompositeFilterDescriptor): void;
@@ -4,37 +4,18 @@
4
4
  *-------------------------------------------------------------------------------------------*/
5
5
  import * as tslib_1 from "tslib";
6
6
  import { Injectable } from '@angular/core';
7
- import { LocalizationService } from '@progress/kendo-angular-l10n';
8
- import { defaultDateOperators, defaultNumericOperators, defaultStringOperators, logicOperators } from './util';
9
- /**
10
- * @hidden
11
- */
12
- export const localizeOperators = operators => localization => Object.keys(operators).map(key => ({
13
- text: localization.get(key),
14
- value: operators[key]
15
- }));
16
7
  /**
17
8
  * @hidden
18
9
  */
19
10
  let FilterService = class FilterService {
20
- constructor(localization) {
21
- this.localization = localization;
11
+ /**
12
+ * @hidden
13
+ */
14
+ constructor() {
22
15
  this.value = { filters: [], logic: 'or' };
23
16
  this.filters = [];
24
17
  this.isEditorDisabled = false;
25
18
  }
26
- get defaultNumericOperators() {
27
- return localizeOperators(defaultNumericOperators)(this.localization);
28
- }
29
- get defaultStringOperators() {
30
- return localizeOperators(defaultStringOperators)(this.localization);
31
- }
32
- get defaultDateOperators() {
33
- return localizeOperators(defaultDateOperators)(this.localization);
34
- }
35
- get logicOperators() {
36
- return localizeOperators(logicOperators)(this.localization);
37
- }
38
19
  addFilterGroup(item) {
39
20
  let filterGroup = { logic: 'or', filters: [] };
40
21
  item.filters.push(filterGroup);
@@ -60,7 +41,6 @@ let FilterService = class FilterService {
60
41
  }
61
42
  };
62
43
  FilterService = tslib_1.__decorate([
63
- Injectable(),
64
- tslib_1.__metadata("design:paramtypes", [LocalizationService])
44
+ Injectable()
65
45
  ], FilterService);
66
46
  export { FilterService };