/**
 * @fileoverview added by tsickle
 * @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
 */
import { Component, Input, ViewChildren, QueryList, HostBinding, ViewChild, ElementRef, ChangeDetectionStrategy, ChangeDetectorRef } from '@angular/core';
import { IgxSummaryCellComponent } from './summary-cell.component';
import { IgxGridForOfDirective } from '../../directives/for-of/for_of.directive';
import { GridBaseAPIService } from '../api.service';
import { IgxForOfSyncService } from '../../directives/for-of/for_of.sync.service';
var IgxSummaryRowComponent = /** @class */ (function () {
    function IgxSummaryRowComponent(gridAPI, element, cdr) {
        this.gridAPI = gridAPI;
        this.element = element;
        this.cdr = cdr;
        this.firstCellIndentation = -1;
    }
    Object.defineProperty(IgxSummaryRowComponent.prototype, "dataRowIndex", {
        get: /**
         * @return {?}
         */
        function () {
            return this.index;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxSummaryRowComponent.prototype, "minHeight", {
        get: /**
         * @return {?}
         */
        function () {
            return this.grid.summaryService.calcMaxSummaryHeight() - 1;
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @return {?}
     */
    IgxSummaryRowComponent.prototype.ngDoCheck = /**
     * @return {?}
     */
    function () {
        this.cdr.markForCheck();
    };
    Object.defineProperty(IgxSummaryRowComponent.prototype, "grid", {
        get: /**
         * @return {?}
         */
        function () {
            return this.gridAPI.grid;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxSummaryRowComponent.prototype, "nativeElement", {
        get: /**
         * @return {?}
         */
        function () {
            return this.element.nativeElement;
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} columnName
     * @return {?}
     */
    IgxSummaryRowComponent.prototype.getColumnSummaries = /**
     * @param {?} columnName
     * @return {?}
     */
    function (columnName) {
        if (!this.summaries.get(columnName)) {
            return [];
        }
        return this.summaries.get(columnName);
    };
    Object.defineProperty(IgxSummaryRowComponent.prototype, "pinnedColumns", {
        /**
         * @hidden
         */
        get: /**
         * @hidden
         * @return {?}
         */
        function () {
            return this.grid.pinnedColumns;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxSummaryRowComponent.prototype, "unpinnedColumns", {
        /**
         * @hidden
         */
        get: /**
         * @hidden
         * @return {?}
         */
        function () {
            return this.grid.unpinnedColumns;
        },
        enumerable: true,
        configurable: true
    });
    IgxSummaryRowComponent.decorators = [
        { type: Component, args: [{
                    changeDetection: ChangeDetectionStrategy.OnPush,
                    preserveWhitespaces: false,
                    selector: 'igx-grid-summary-row',
                    template: "<ng-container *ngIf=\"summaries.size\">\n    <ng-container *ngIf=\"grid.summariesMargin\">\n        <div\n        class=\"igx-grid__summaries-patch\"\n        [style.min-width.px]=\"grid.summariesMargin\"\n        [style.flex-basis.px]=\"grid.summariesMargin\"\n        ></div>\n    </ng-container>\n    <ng-container *ngIf=\"pinnedColumns.length > 0\">\n        <igx-grid-summary-cell *ngFor=\"let col of pinnedColumns | igxNotGrouped\"\n            class=\"igx-grid-summary igx-grid-summary--fw igx-grid-summary--pinned\"\n            [class.igx-grid-summary--cosy]=\"grid.displayDensity === 'cosy'\"\n            [class.igx-grid-summary--compact]=\"grid.displayDensity === 'compact'\"\n            [class.igx-grid-summary--empty]=\"!col.hasSummary\"\n            [class.igx-grid-summary--pinned-last]=\"col.isLastPinned\"\n            [column]=\"col\"\n            [firstCellIndentation]=\"firstCellIndentation\"\n            [rowIndex]=\"index\"\n            [summaryResults]=\"getColumnSummaries(col.field)\"\n            [hasSummary]=\"col.hasSummary\"\n            [density]=\"grid.displayDensity\"\n            [style.max-height.px]=\"minHeight\"\n            [style.min-height.px]=\"minHeight\">\n        </igx-grid-summary-cell>\n    </ng-container>\n    <ng-template igxGridFor let-col [igxGridForOf]=\"unpinnedColumns | igxNotGrouped\" [igxForScrollContainer]=\"grid.parentVirtDir\" let-colIndex=\"index\" [igxForScrollOrientation]=\"'horizontal'\" [igxForContainerSize]=\"grid.unpinnedWidth\" [igxForTrackBy]=\"grid.trackColumnChanges\" [igxForSizePropName]='\"calcPixelWidth\"' #igxDirRef>\n        <igx-grid-summary-cell\n            class=\"igx-grid-summary igx-grid-summary--fw\"\n            [class.igx-grid-summary--cosy]=\"grid.displayDensity === 'cosy'\"\n            [class.igx-grid-summary--compact]=\"grid.displayDensity === 'compact'\"\n            [class.igx-grid-summary--empty]=\"!col.hasSummary\"\n            [column]=\"col\"\n            [rowIndex]=\"index\"\n            [firstCellIndentation]=\"firstCellIndentation\"\n            [summaryResults]=\"getColumnSummaries(col.field)\"\n            [hasSummary]=\"col.hasSummary\"\n            [density]=\"grid.displayDensity\"\n            [style.max-height.px]=\"minHeight\"\n            [style.min-height.px]=\"minHeight\">\n        </igx-grid-summary-cell>\n    </ng-template>\n</ng-container>\n",
                    providers: [IgxForOfSyncService]
                }] }
    ];
    /** @nocollapse */
    IgxSummaryRowComponent.ctorParameters = function () { return [
        { type: GridBaseAPIService },
        { type: ElementRef },
        { type: ChangeDetectorRef }
    ]; };
    IgxSummaryRowComponent.propDecorators = {
        summaries: [{ type: Input }],
        gridID: [{ type: Input }],
        index: [{ type: Input }],
        firstCellIndentation: [{ type: Input }],
        dataRowIndex: [{ type: HostBinding, args: ['attr.data-rowIndex',] }],
        summaryCells: [{ type: ViewChildren, args: [IgxSummaryCellComponent, { read: IgxSummaryCellComponent },] }],
        virtDirRow: [{ type: ViewChild, args: ['igxDirRef', { read: IgxGridForOfDirective, static: false },] }]
    };
    return IgxSummaryRowComponent;
}());
export { IgxSummaryRowComponent };
if (false) {
    /** @type {?} */
    IgxSummaryRowComponent.prototype.summaries;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.gridID;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.index;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.firstCellIndentation;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.summaryCells;
    /**
     * @hidden
     * @type {?}
     */
    IgxSummaryRowComponent.prototype.virtDirRow;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.gridAPI;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.element;
    /** @type {?} */
    IgxSummaryRowComponent.prototype.cdr;
}
//# sourceMappingURL=data:application/json;base64, 