UNPKG

ng2-smart-table-pager-mod

Version:

Angular Smart Table Mod

52 lines 3.15 kB
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; return c > 3 && r && Object.defineProperty(target, key, r), r; }; var __metadata = (this && this.__metadata) || function (k, v) { if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); }; import { Component, Input, Output, EventEmitter } from '@angular/core'; import { Grid } from '../../../lib/grid'; import { DataSource } from '../../../lib/data-source/data-source'; var TheadTitlesRowComponent = (function () { function TheadTitlesRowComponent() { this.sort = new EventEmitter(); this.selectAllRows = new EventEmitter(); } TheadTitlesRowComponent.prototype.ngOnChanges = function () { this.isMultiSelectVisible = this.grid.isMultiSelectVisible(); this.showActionColumnLeft = this.grid.showActionColumn('left'); this.showActionColumnRight = this.grid.showActionColumn('right'); }; return TheadTitlesRowComponent; }()); __decorate([ Input(), __metadata("design:type", Grid) ], TheadTitlesRowComponent.prototype, "grid", void 0); __decorate([ Input(), __metadata("design:type", Boolean) ], TheadTitlesRowComponent.prototype, "isAllSelected", void 0); __decorate([ Input(), __metadata("design:type", DataSource) ], TheadTitlesRowComponent.prototype, "source", void 0); __decorate([ Output(), __metadata("design:type", Object) ], TheadTitlesRowComponent.prototype, "sort", void 0); __decorate([ Output(), __metadata("design:type", Object) ], TheadTitlesRowComponent.prototype, "selectAllRows", void 0); TheadTitlesRowComponent = __decorate([ Component({ selector: '[ng2-st-thead-titles-row]', template: "\n <th ng2-st-checkbox-select-all *ngIf=\"isMultiSelectVisible\"\n [grid]=\"grid\"\n [source]=\"source\"\n [isAllSelected]=\"isAllSelected\"\n (click)=\"selectAllRows.emit($event)\">\n </th>\n <th ng2-st-actions-title *ngIf=\"showActionColumnLeft\" [grid]=\"grid\"></th>\n <th *ngFor=\"let column of grid.getColumns()\" class=\"ng2-smart-th {{ column.id }}\" [ngClass]=\"column.class\"\n [style.width]=\"column.width\" >\n <ng2-st-column-title [source]=\"source\" [column]=\"column\" (sort)=\"sort.emit($event)\"></ng2-st-column-title>\n </th>\n <th ng2-st-actions-title *ngIf=\"showActionColumnRight\" [grid]=\"grid\"></th>\n ", }) ], TheadTitlesRowComponent); export { TheadTitlesRowComponent }; //# sourceMappingURL=thead-titles-row.component.js.map