/**
 * @fileoverview added by tsickle
 * @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
 */
import * as tslib_1 from "tslib";
import { Component, ChangeDetectionStrategy, ViewChild, Input } from '@angular/core';
import { IgxExcelStyleDefaultExpressionComponent } from './excel-style-default-expression.component';
import { IgxDatePickerComponent } from '../../../date-picker/date-picker.component';
import { DisplayDensity } from '../../../core/density';
/**
 * @hidden
 */
var IgxExcelStyleDateExpressionComponent = /** @class */ (function (_super) {
    tslib_1.__extends(IgxExcelStyleDateExpressionComponent, _super);
    function IgxExcelStyleDateExpressionComponent() {
        return _super !== null && _super.apply(this, arguments) || this;
    }
    Object.defineProperty(IgxExcelStyleDateExpressionComponent.prototype, "inputValuesElement", {
        get: /**
         * @protected
         * @return {?}
         */
        function () {
            return this.datePicker.getEditElement();
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxExcelStyleDateExpressionComponent.prototype, "inputDatePlaceholder", {
        get: /**
         * @return {?}
         */
        function () {
            return this.grid.resourceStrings['igx_grid_filter_row_date_placeholder'];
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} openDialog
     * @return {?}
     */
    IgxExcelStyleDateExpressionComponent.prototype.openDatePicker = /**
     * @param {?} openDialog
     * @return {?}
     */
    function (openDialog) {
        openDialog();
    };
    IgxExcelStyleDateExpressionComponent.decorators = [
        { type: Component, args: [{
                    changeDetection: ChangeDetectionStrategy.OnPush,
                    preserveWhitespaces: false,
                    selector: 'igx-excel-style-date-expression',
                    template: "<igx-drop-down #dropdownConditions [maxHeight]=\"'200px'\" [width]=\"getInputWidth()\"\n    [displayDensity]=\"displayDensity\"\n    (onSelection)=\"onConditionsChanged($event)\">\n    <igx-drop-down-item *ngFor=\"let condition of conditions\" [value]=\"condition\"\n        [selected]=\"isConditionSelected(condition)\">\n        <igx-icon fontSet=\"filtering-icons\" [name]=\"getCondition(condition).iconName\"></igx-icon>\n        <span>{{ translateCondition(condition) }}</span>\n    </igx-drop-down-item>\n</igx-drop-down>\n\n<igx-input-group #inputGroupConditions (click)=\"toggleCustomDialogDropDown()\" type=\"box\"\n    [displayDensity]=\"displayDensity\" [supressInputAutofocus]=\"true\">\n\n    <igx-prefix>\n        <igx-icon *ngIf=\"expressionUI.expression.condition\" fontSet=\"filtering-icons\" [name]=\"getIconName()\"></igx-icon>\n        <igx-icon *ngIf=\"!expressionUI.expression.condition\">filter_list</igx-icon>\n    </igx-prefix>\n\n    <input igxInput (keydown)=\"onInputConditionsKeyDown($event)\" tabindex=\"0\"\n        [igxDropDownItemNavigation]=\"dropdownConditions\" [placeholder]=\"inputConditionsPlaceholder\" autocomplete=\"off\"\n        [value]=\"getConditionName(expressionUI.expression.condition)\" [readonly]=\"true\" />\n</igx-input-group>\n\n<igx-date-picker #datePicker mode=\"dropdown\" [(ngModel)]=\"expressionUI.expression.searchVal\" [locale]=\"grid.locale\"\n    [outlet]=\"grid.outletDirective\">\n    <ng-template igxDatePickerTemplate let-openDialog=\"openDialog\" let-value=\"value\">\n        <igx-input-group #dropDownTarget type=\"box\" [displayDensity]=\"displayDensity\" [supressInputAutofocus]=\"true\">\n            <input #input igxInput tabindex=\"0\" (click)=\"openDatePicker(openDialog)\"\n                [placeholder]=\"inputDatePlaceholder\" autocomplete=\"off\" [value]=\"value | igxdate: grid.locale\"\n                [readonly]=\"true\"\n                [disabled]=\"expressionUI.expression.condition && expressionUI.expression.condition.isUnary\" />\n        </igx-input-group>\n    </ng-template>\n</igx-date-picker>\n\n<button (click)=\"onRemoveButtonClick()\" igxButton=\"icon\" [displayDensity]=\"displayDensity\" *ngIf=\"!isSingle\">\n    <igx-icon>cancel</igx-icon>\n</button>\n\n<igx-buttongroup #logicOperatorButtonGroup *ngIf=\"!isLast\" [multiSelection]=\"false\">\n    <span igxButton [displayDensity]=\"displayDensity\" #andButton (keydown)=\"onLogicOperatorKeyDown($event, 0)\"\n        tabindex=\"0\" [selected]=\"expressionUI.afterOperator === 0\" type=\"button\"\n        (click)=\"onLogicOperatorButtonClicked($event, 0)\">\n        {{ grid.resourceStrings.igx_grid_filter_operator_and }}\n    </span>\n\n    <span igxButton [displayDensity]=\"displayDensity\" #orButton tabindex=\"0\"\n        (keydown)=\"onLogicOperatorKeyDown($event, 1)\" [selected]=\"expressionUI.afterOperator === 1\" type=\"button\"\n        (click)=\"onLogicOperatorButtonClicked($event, 1)\">\n        {{ grid.resourceStrings.igx_grid_filter_operator_or }}\n    </span>\n</igx-buttongroup>"
                }] }
    ];
    IgxExcelStyleDateExpressionComponent.propDecorators = {
        datePicker: [{ type: ViewChild, args: ['datePicker', { read: IgxDatePickerComponent },] }],
        displayDensity: [{ type: Input }]
    };
    return IgxExcelStyleDateExpressionComponent;
}(IgxExcelStyleDefaultExpressionComponent));
export { IgxExcelStyleDateExpressionComponent };
if (false) {
    /**
     * @type {?}
     * @private
     */
    IgxExcelStyleDateExpressionComponent.prototype.datePicker;
    /** @type {?} */
    IgxExcelStyleDateExpressionComponent.prototype.displayDensity;
}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXhjZWwtc3R5bGUtZGF0ZS1leHByZXNzaW9uLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiJuZzovL2lnbml0ZXVpLWFuZ3VsYXIvIiwic291cmNlcyI6WyJsaWIvZ3JpZHMvZmlsdGVyaW5nL2V4Y2VsLXN0eWxlL2V4Y2VsLXN0eWxlLWRhdGUtZXhwcmVzc2lvbi5jb21wb25lbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7QUFBQSxPQUFPLEVBQ0gsU0FBUyxFQUNULHVCQUF1QixFQUN2QixTQUFTLEVBQ1QsS0FBSyxFQUNSLE1BQU0sZUFBZSxDQUFDO0FBQ3ZCLE9BQU8sRUFBRSx1Q0FBdUMsRUFBRSxNQUFNLDRDQUE0QyxDQUFDO0FBQ3JHLE9BQU8sRUFBRSxzQkFBc0IsRUFBRSxNQUFNLDR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