diff --git a/docs/changelog.md b/docs/changelog.md
index b50ce56ac..c21e927a6 100644
--- a/docs/changelog.md
+++ b/docs/changelog.md
@@ -1,5 +1,9 @@
# Changelog
+## 1.7.0
+- Enhancement: Add RxJS Support
+- Chore: Fix builds on windows
+
## 1.6.0
- Bug: Column headers not re-ordering (#238)
- Bug: Datatable doesn't sort data correctly when data changed (#284)
diff --git a/package.json b/package.json
index 28ef32857..712f42787 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "angular2-data-table",
- "version": "1.6.0",
+ "version": "1.7.0",
"description": "angular2-data-table is a Angular2 component for presenting large and complex data.",
"main": "release/index.js",
"typings": "release/index.d.ts",
@@ -16,8 +16,8 @@
"clean:dist": "rimraf dist",
"clean:release": "rimraf release",
"build": "webpack --display-error-details",
- "build:release": "NODE_ENV=production npm run build",
- "build:package": "NODE_ENV=package npm run build",
+ "build:release": "cross-env NODE_ENV=production npm run build",
+ "build:package": "cross-env NODE_ENV=package npm run build",
"build:ts": "tsc",
"build:aot": "ngc",
"build:sass": "node-sass -o dist/ src/",
@@ -81,6 +81,7 @@
"clean-webpack-plugin": "^0.1.10",
"copy-webpack-plugin": "^4.0.0",
"core-js": "^2.4.0",
+ "cross-env": "^3.1.3",
"css-loader": "^0.24.0",
"extract-text-webpack-plugin": "^2.0.0-beta.4",
"fs-extra": "^1.0.0",
diff --git a/release/app.css b/release/app.css
deleted file mode 100644
index c4d7510d1..000000000
--- a/release/app.css
+++ /dev/null
@@ -1,368 +0,0 @@
-/**
- * angular2-data-table v"1.6.0" (https://github.com/swimlane/angular2-data-table)
- * Copyright 2016
- * Licensed under MIT
- */
-.datatable {
- display: block;
- overflow: hidden;
- -webkit-box-pack: center;
- -ms-flex-pack: center;
- justify-content: center;
- position: relative;
- /**
- * Vertical Scrolling Adjustments
- */
- /**
- * Horizontal Scrolling Adjustments
- */
- /**
- * Fixed Header Height Adjustments
- */
- /**
- * Fixed row height adjustments
- */
- /**
- * Shared Styles
- */
- /**
- * Header Styles
- */
- /**
- * Body Styles
- */
- /**
- * Footer Styles
- */ }
- .datatable [hidden] {
- display: none !important; }
- .datatable *, .datatable *:before, .datatable *:after {
- box-sizing: border-box; }
- .datatable.scroll-vertical .datatable-body {
- overflow-y: auto; }
- .datatable.scroll-vertical .datatable-body .datatable-row-wrapper {
- position: absolute; }
- .datatable.scroll-horz .datatable-body {
- overflow-x: auto; }
- .datatable.fixed-header .datatable-header .datatable-header-inner {
- white-space: nowrap; }
- .datatable.fixed-header .datatable-header .datatable-header-inner .datatable-header-cell {
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis; }
- .datatable.fixed-row .datatable-scroll {
- white-space: nowrap; }
- .datatable.fixed-row .datatable-scroll .datatable-body-row {
- white-space: nowrap; }
- .datatable.fixed-row .datatable-scroll .datatable-body-row .datatable-body-cell {
- overflow: hidden;
- white-space: nowrap;
- text-overflow: ellipsis; }
- .datatable .datatable-body-row,
- .datatable .datatable-header-inner {
- display: -webkit-box;
- display: -ms-flexbox;
- display: flex;
- -webkit-box-orient: horizontal;
- -webkit-box-direction: normal;
- -ms-flex-direction: row;
- flex-direction: row;
- -ms-flex-flow: row;
- -o-flex-flow: row;
- flex-flow: row; }
- .datatable .datatable-body-cell,
- .datatable .datatable-header-cell {
- vertical-align: top;
- display: inline-block;
- line-height: 1.625;
- -webkit-user-select: none;
- -moz-user-select: none;
- -ms-user-select: none;
- -o-user-select: none;
- user-select: none; }
- .datatable .datatable-body-cell:focus,
- .datatable .datatable-header-cell:focus {
- outline: none; }
- .datatable .datatable-row-left,
- .datatable .datatable-row-right {
- z-index: 9; }
- .datatable .datatable-row-left,
- .datatable .datatable-row-center,
- .datatable .datatable-row-right {
- position: relative; }
- .datatable .datatable-header {
- display: block;
- overflow: hidden; }
- .datatable .datatable-header .datatable-header-inner {
- -webkit-box-align: stretch;
- -ms-flex-align: stretch;
- align-items: stretch;
- -webkit-align-items: stretch; }
- .datatable .datatable-header .datatable-header-cell {
- position: relative;
- display: inline-block; }
- .datatable .datatable-header .datatable-header-cell.longpress {
- cursor: move; }
- .datatable .datatable-header .datatable-header-cell.sortable {
- cursor: pointer; }
- .datatable .datatable-header .datatable-header-cell .sort-btn {
- line-height: 100%;
- vertical-align: middle;
- display: inline-block; }
- .datatable .datatable-header .datatable-header-cell .resize-handle {
- display: inline-block;
- position: absolute;
- right: 0;
- top: 0;
- bottom: 0;
- width: 5px;
- padding: 0 8px;
- visibility: hidden;
- cursor: ew-resize; }
- .datatable .datatable-header .datatable-header-cell.resizeable:hover .resize-handle {
- visibility: visible; }
- .datatable .datatable-body {
- position: relative;
- z-index: 10;
- display: block; }
- .datatable .datatable-body .datatable-scroll {
- display: inline-block; }
- .datatable .datatable-body .datatable-row-detail {
- overflow-y: hidden; }
- .datatable .datatable-body .datatable-row-wrapper {
- display: -webkit-box;
- display: -ms-flexbox;
- display: flex;
- -webkit-box-orient: vertical;
- -webkit-box-direction: normal;
- -ms-flex-direction: column;
- flex-direction: column; }
- .datatable .datatable-body .datatable-body-row {
- outline: none; }
- .datatable .datatable-body .datatable-body-row > div {
- display: -webkit-box;
- display: -ms-flexbox;
- display: flex; }
- .datatable .datatable-footer {
- display: block;
- width: 100%; }
- .datatable .datatable-footer > div {
- display: -webkit-box;
- display: -ms-flexbox;
- display: flex;
- -webkit-box-align: center;
- -ms-flex-align: center;
- align-items: center;
- width: 100%; }
- .datatable .datatable-footer .page-count {
- display: inline-block;
- -webkit-box-flex: 1;
- -ms-flex: 1 1 20%;
- flex: 1 1 20%; }
- .datatable .datatable-footer .datatable-pager {
- display: inline-block;
- -webkit-box-flex: 1;
- -ms-flex: 1 1 80%;
- flex: 1 1 80%;
- text-align: right; }
- .datatable .datatable-footer .datatable-pager .pager,
- .datatable .datatable-footer .datatable-pager .pager li {
- padding: 0;
- margin: 0;
- display: inline-block;
- list-style: none; }
- .datatable .datatable-footer .datatable-pager .pager li, .datatable .datatable-footer .datatable-pager .pager li a {
- outline: none; }
- .datatable .datatable-footer .datatable-pager .pager li a {
- cursor: pointer;
- display: inline-block; }
- .datatable .datatable-footer .datatable-pager .pager li.disabled a {
- cursor: not-allowed; }
-.datatable.material {
- background: #FFF;
- box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 1px 2px 0 rgba(0, 0, 0, 0.24);
- /**
- * Shared Styles
- */
- /**
- * Global Row Styles
- */
- /**
- * Header Styles
- */
- /**
- * Body Styles
- */
- /**
- * Footer Styles
- */ }
- .datatable.material.striped .datatable-row-odd {
- background: #eee; }
- .datatable.material .empty-row {
- height: 50px;
- text-align: left;
- padding: .5rem 1.2rem;
- vertical-align: top;
- border-top: 0; }
- .datatable.material .loading-row {
- text-align: left;
- padding: .5rem 1.2rem;
- vertical-align: top;
- border-top: 0; }
- .datatable.material .datatable-header .datatable-row-left,
- .datatable.material .datatable-body .datatable-row-left {
- background-color: #FFF;
- background-position: 100% 0;
- background-repeat: repeat-y;
- background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAABCAYAAAD5PA/NAAAAFklEQVQIHWPSkNeSBmJhTQVtbiDNCgASagIIuJX8OgAAAABJRU5ErkJggg==); }
- .datatable.material .datatable-header .datatable-row-right,
- .datatable.material .datatable-body .datatable-row-right {
- background-position: 0 0;
- background-color: #fff;
- background-repeat: repeat-y;
- background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAABCAYAAAD5PA/NAAAAFklEQVQI12PQkNdi1VTQ5gbSwkAsDQARLAIGtOSFUAAAAABJRU5ErkJggg==); }
- .datatable.material .datatable-header {
- border-bottom: 1px solid rgba(0, 0, 0, 0.12); }
- .datatable.material .datatable-header .datatable-header-cell {
- text-align: left;
- padding: .5rem 1.2rem;
- font-weight: 400;
- color: #757575;
- vertical-align: bottom; }
- .datatable.material .datatable-header .datatable-header-cell.longpress {
- color: #00E676; }
- .datatable.material .datatable-header .datatable-header-cell.dragging .resize-handle {
- border-right: none; }
- .datatable.material .datatable-header .resize-handle {
- border-right: solid 1px #eee; }
- .datatable.material .datatable-body .datatable-row-detail {
- background: #f5f5f5;
- padding: 10px; }
- .datatable.material .datatable-body .datatable-body-row .datatable-body-cell {
- text-align: left;
- padding: .5rem 1.2rem;
- vertical-align: top;
- border-top: 0;
- -webkit-transition: width 0.3s ease;
- transition: width 0.3s ease; }
- .datatable.material .datatable-body .datatable-body-row:hover,
- .datatable.material .datatable-body .datatable-body-row:hover .datatable-row-group {
- background-color: #eee;
- -webkit-transition-property: background;
- transition-property: background;
- -webkit-transition-duration: .3s;
- transition-duration: .3s;
- -webkit-transition-timing-function: linear;
- transition-timing-function: linear; }
- .datatable.material .datatable-body .datatable-body-row:focus,
- .datatable.material .datatable-body .datatable-body-row:focus .datatable-row-group {
- background-color: #ddd; }
- .datatable.material .datatable-body .datatable-body-row.active,
- .datatable.material .datatable-body .datatable-body-row.active .datatable-row-group {
- background-color: #304FFE;
- color: #FFF; }
- .datatable.material .datatable-body .datatable-body-row.active:hover,
- .datatable.material .datatable-body .datatable-body-row.active:hover .datatable-row-group {
- background-color: #193AE4;
- color: #FFF; }
- .datatable.material .datatable-body .datatable-body-row.active:focus,
- .datatable.material .datatable-body .datatable-body-row.active:focus .datatable-row-group {
- background-color: #2041EF;
- color: #FFF; }
- .datatable.material .datatable-body .progress-linear {
- display: block;
- position: relative;
- width: 100%;
- height: 5px;
- padding: 0;
- margin: 0;
- position: absolute; }
- .datatable.material .datatable-body .progress-linear .container {
- display: block;
- position: relative;
- overflow: hidden;
- width: 100%;
- height: 5px;
- -webkit-transform: translate(0, 0) scale(1, 1);
- transform: translate(0, 0) scale(1, 1);
- background-color: #aad1f9; }
- .datatable.material .datatable-body .progress-linear .container .bar {
- -webkit-transition: all .2s linear;
- transition: all .2s linear;
- -webkit-animation: query 0.8s infinite cubic-bezier(0.39, 0.575, 0.565, 1);
- animation: query 0.8s infinite cubic-bezier(0.39, 0.575, 0.565, 1);
- transition: -webkit-transform .2s linear;
- -webkit-transition: -webkit-transform .2s linear;
- transition: transform .2s linear;
- transition: transform .2s linear, -webkit-transform .2s linear;
- background-color: #106cc8;
- position: absolute;
- left: 0;
- top: 0;
- bottom: 0;
- width: 100%;
- height: 5px; }
- .datatable.material .datatable-footer {
- border-top: 1px solid rgba(0, 0, 0, 0.12);
- font-size: 16px; }
- .datatable.material .datatable-footer .page-count {
- line-height: 50px;
- height: 50px;
- padding: 0 1.2rem; }
- .datatable.material .datatable-footer .datatable-pager {
- margin: 0 10px; }
- .datatable.material .datatable-footer .datatable-pager li {
- vertical-align: middle; }
- .datatable.material .datatable-footer .datatable-pager li.disabled a {
- color: rgba(0, 0, 0, 0.26) !important;
- background-color: transparent !important; }
- .datatable.material .datatable-footer .datatable-pager li.active a {
- background-color: rgba(158, 158, 158, 0.2);
- font-weight: bold; }
- .datatable.material .datatable-footer .datatable-pager a {
- height: 22px;
- min-width: 24px;
- line-height: 22px;
- padding: 0 6px;
- border-radius: 3px;
- margin: 6px 3px;
- text-align: center;
- vertical-align: top;
- color: rgba(0, 0, 0, 0.54);
- text-decoration: none;
- vertical-align: bottom; }
- .datatable.material .datatable-footer .datatable-pager a:hover {
- color: rgba(0, 0, 0, 0.75);
- background-color: rgba(158, 158, 158, 0.2); }
- .datatable.material .datatable-footer .datatable-pager .icon-left,
- .datatable.material .datatable-footer .datatable-pager .icon-skip,
- .datatable.material .datatable-footer .datatable-pager .icon-right,
- .datatable.material .datatable-footer .datatable-pager .icon-prev {
- font-size: 20px;
- line-height: 20px;
- padding: 0 3px; }
-
-/**
- * Progress bar animations
- */
-@-webkit-keyframes query {
- 0% {
- opacity: 1;
- -webkit-transform: translateX(35%) scale(0.3, 1);
- transform: translateX(35%) scale(0.3, 1); }
- 100% {
- opacity: 0;
- -webkit-transform: translateX(-50%) scale(0, 1);
- transform: translateX(-50%) scale(0, 1); } }
-
-@keyframes query {
- 0% {
- opacity: 1;
- -webkit-transform: translateX(35%) scale(0.3, 1);
- transform: translateX(35%) scale(0.3, 1); }
- 100% {
- opacity: 0;
- -webkit-transform: translateX(-50%) scale(0, 1);
- transform: translateX(-50%) scale(0, 1); } }
-
-/*# sourceMappingURL=app.map*/
\ No newline at end of file
diff --git a/release/app.js b/release/app.js
deleted file mode 100644
index 1c51dba22..000000000
--- a/release/app.js
+++ /dev/null
@@ -1,6277 +0,0 @@
-/**
- * angular2-data-table v"1.6.0" (https://github.com/swimlane/angular2-data-table)
- * Copyright 2016
- * Licensed under MIT
- */
-(function webpackUniversalModuleDefinition(root, factory) {
- if(typeof exports === 'object' && typeof module === 'object')
- module.exports = factory(require("@angular/common"), require("@angular/core"), require("@angular/platform-browser"), require("@angular/platform-browser-dynamic"), require("rxjs/Rx"));
- else if(typeof define === 'function' && define.amd)
- define("angular2-data-table", ["@angular/common", "@angular/core", "@angular/platform-browser", "@angular/platform-browser-dynamic", "rxjs/Rx"], factory);
- else if(typeof exports === 'object')
- exports["angular2-data-table"] = factory(require("@angular/common"), require("@angular/core"), require("@angular/platform-browser"), require("@angular/platform-browser-dynamic"), require("rxjs/Rx"));
- else
- root["angular2-data-table"] = factory(root["@angular/common"], root["@angular/core"], root["@angular/platform-browser"], root["@angular/platform-browser-dynamic"], root["rxjs/Rx"]);
-})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_0__, __WEBPACK_EXTERNAL_MODULE_4__, __WEBPACK_EXTERNAL_MODULE_3__, __WEBPACK_EXTERNAL_MODULE_1__) {
-return /******/ (function(modules) { // webpackBootstrap
-/******/ // The module cache
-/******/ var installedModules = {};
-/******/
-/******/ // The require function
-/******/ function __webpack_require__(moduleId) {
-/******/
-/******/ // Check if module is in cache
-/******/ if(installedModules[moduleId])
-/******/ return installedModules[moduleId].exports;
-/******/
-/******/ // Create a new module (and put it into the cache)
-/******/ var module = installedModules[moduleId] = {
-/******/ i: moduleId,
-/******/ l: false,
-/******/ exports: {}
-/******/ };
-/******/
-/******/ // Execute the module function
-/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-/******/
-/******/ // Flag the module as loaded
-/******/ module.l = true;
-/******/
-/******/ // Return the exports of the module
-/******/ return module.exports;
-/******/ }
-/******/
-/******/
-/******/ // expose the modules object (__webpack_modules__)
-/******/ __webpack_require__.m = modules;
-/******/
-/******/ // expose the module cache
-/******/ __webpack_require__.c = installedModules;
-/******/
-/******/ // identity function for calling harmory imports with the correct context
-/******/ __webpack_require__.i = function(value) { return value; };
-/******/
-/******/ // define getter function for harmory exports
-/******/ __webpack_require__.d = function(exports, name, getter) {
-/******/ Object.defineProperty(exports, name, {
-/******/ configurable: false,
-/******/ enumerable: true,
-/******/ get: getter
-/******/ });
-/******/ };
-/******/
-/******/ // getDefaultExport function for compatibility with non-harmony modules
-/******/ __webpack_require__.n = function(module) {
-/******/ var getter = module && module.__esModule ?
-/******/ function getDefault() { return module['default']; } :
-/******/ function getModuleExports() { return module; };
-/******/ __webpack_require__.d(getter, 'a', getter);
-/******/ return getter;
-/******/ };
-/******/
-/******/ // Object.prototype.hasOwnProperty.call
-/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
-/******/
-/******/ // __webpack_public_path__
-/******/ __webpack_require__.p = "";
-/******/
-/******/ // Load entry module and return exports
-/******/ return __webpack_require__(__webpack_require__.s = "./demo/bootstrap.ts");
-/******/ })
-/************************************************************************/
-/******/ ({
-
-/***/ "./demo/app.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var AppComponent = (function () {
- function AppComponent() {
- this.version = "1.6.0";
- }
- Object.defineProperty(AppComponent.prototype, "state", {
- get: function () {
- return window.state;
- },
- set: function (state) {
- window.state = state;
- },
- enumerable: true,
- configurable: true
- });
- AppComponent = __decorate([
- core_1.Component({
- selector: 'app',
- template: "\n
\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n\n \n \n \n \n \n \n \n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], AppComponent);
- return AppComponent;
-}());
-exports.AppComponent = AppComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/basic-auto.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var BasicAutoComponent = (function () {
- function BasicAutoComponent() {
- var _this = this;
- this.rows = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Gender' },
- { name: 'Company' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- BasicAutoComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- BasicAutoComponent = __decorate([
- core_1.Component({
- selector: 'basic-auto-demo',
- template: "\n \n
Fluid Row Heights
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], BasicAutoComponent);
- return BasicAutoComponent;
-}());
-exports.BasicAutoComponent = BasicAutoComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/basic-fixed.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var BasicFixedComponent = (function () {
- function BasicFixedComponent() {
- var _this = this;
- this.rows = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- BasicFixedComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- BasicFixedComponent = __decorate([
- core_1.Component({
- selector: 'basic-fixed-demo',
- template: "\n \n
Fix Row Height
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], BasicFixedComponent);
- return BasicFixedComponent;
-}());
-exports.BasicFixedComponent = BasicFixedComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/filter.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var FilterBarComponent = (function () {
- function FilterBarComponent() {
- var _this = this;
- this.rows = [];
- this.temp = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- // cache our list
- _this.temp = data.slice();
- // push our inital complete list
- _this.rows = data;
- });
- }
- FilterBarComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- FilterBarComponent.prototype.updateFilter = function (event) {
- var val = event.target.value;
- // filter our data
- var temp = this.temp.filter(function (d) {
- return d.name.toLowerCase().indexOf(val) !== -1 || !val;
- });
- // update the rows
- this.rows = temp;
- };
- FilterBarComponent = __decorate([
- core_1.Component({
- selector: 'filter-demo',
- template: "\n \n
Client-side Search and Filtering
\n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], FilterBarComponent);
- return FilterBarComponent;
-}());
-exports.FilterBarComponent = FilterBarComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/fullscreen.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var FullScreenComponent = (function () {
- function FullScreenComponent() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- FullScreenComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/100k.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- FullScreenComponent = __decorate([
- core_1.Component({
- selector: 'full-screen-demo',
- template: "\n \n
Full Screen
\n \n \n \n \n \n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], FullScreenComponent);
- return FullScreenComponent;
-}());
-exports.FullScreenComponent = FullScreenComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/inline.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var InlineEditComponent = (function () {
- function InlineEditComponent() {
- var _this = this;
- this.editing = {};
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- InlineEditComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- InlineEditComponent.prototype.updateValue = function (event, cell, cellValue, row) {
- this.editing[row.$$index + '-' + cell] = false;
- this.rows[row.$$index][cell] = event.target.value;
- };
- InlineEditComponent = __decorate([
- core_1.Component({
- selector: 'inline-edit-demo',
- template: "\n \n
Inline Editing
\n \n \n \n \n {{value}}\n \n \n \n \n \n \n \n {{value}}\n \n \n \n \n \n \n {{value}}\n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], InlineEditComponent);
- return InlineEditComponent;
-}());
-exports.InlineEditComponent = InlineEditComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/live.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var LiveDataComponent = (function () {
- function LiveDataComponent() {
- var _this = this;
- this.rows = [];
- this.active = true;
- this.cols = [
- 'Type', 'Organization', 'DateAdded', 'Tags'
- ];
- this.fetch(function (data) {
- _this.rows = data.map(function (d) {
- d.updated = Date.now().toString();
- return d;
- });
- });
- this.start();
- }
- LiveDataComponent.prototype.randomNum = function (start, end) {
- return Math.floor(Math.random() * end) + start;
- };
- LiveDataComponent.prototype.start = function () {
- if (!this.active)
- return;
- setTimeout(this.updateRandom.bind(this), 50);
- };
- LiveDataComponent.prototype.stop = function () {
- this.active = false;
- };
- LiveDataComponent.prototype.updateRandom = function () {
- var rowNum = this.randomNum(0, 5);
- var cellNum = this.randomNum(0, 4);
- var newRow = this.randomNum(0, 100);
- var prop = this.cols[cellNum];
- if (this.rows.length) {
- // let rows = [...this.rows];
- var row = this.rows[rowNum];
- row[prop] = Date.now().toString(); // this.rows[newRow][prop];
- row.updated = Date.now().toString();
- }
- this.start();
- };
- LiveDataComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/security.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- LiveDataComponent = __decorate([
- core_1.Component({
- selector: 'live-data-demo',
- template: "\n \n
\n Live Data Demo ( not working ATM )\n \n Start\n Stop\n \n
\n
\n \n \n \n \n \n {{value}}\n \n \n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [])
- ], LiveDataComponent);
- return LiveDataComponent;
-}());
-exports.LiveDataComponent = LiveDataComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/multiple.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var MultipleTablesComponent = (function () {
- function MultipleTablesComponent() {
- this.columns1 = [
- { prop: 'name' },
- { name: 'Gender' },
- { name: 'Company' }
- ];
- this.columns2 = [
- { prop: 'name', Name: '^^NAME^^' },
- { name: 'Gender' }
- ];
- this.rows1 = [
- { name: 'Larry', gender: 'Male', company: 'Cisco' },
- { name: 'Lauren', gender: 'Female', company: 'HP' }
- ];
- this.rows2 = [
- { name: 'Callie', gender: 'Female' },
- { name: 'Maggie', gender: 'Female' }
- ];
- }
- MultipleTablesComponent = __decorate([
- core_1.Component({
- selector: 'multiple-tables-demo',
- template: "\n \n
Multiple Tables
\n \n \n
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], MultipleTablesComponent);
- return MultipleTablesComponent;
-}());
-exports.MultipleTablesComponent = MultipleTablesComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/row-detail.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var RowDetailsComponent = (function () {
- function RowDetailsComponent() {
- var _this = this;
- this.rows = [];
- this.expanded = {};
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- RowDetailsComponent.prototype.onPage = function (event) {
- clearTimeout(this.timeout);
- this.timeout = setTimeout(function () {
- console.log('paged!', event);
- }, 100);
- };
- RowDetailsComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/100k.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- RowDetailsComponent.prototype.toggleExpandRow = function (row) {
- console.log('Toggled Expand Row!', row);
- this.table.toggleExpandRow(row);
- };
- __decorate([
- core_1.ViewChild('mydatatable'),
- __metadata('design:type', Object)
- ], RowDetailsComponent.prototype, "table", void 0);
- RowDetailsComponent = __decorate([
- core_1.Component({
- selector: 'row-details-demo',
- template: "\n \n
\n
\n \n \n \n
Address
\n
{{row.address.city}}, {{row.address.state}}
\n
\n \n \n \n \n \n \n \n \n \n \n {{row.$$index}}\n \n \n \n \n {{row.$$expanded === 1}}\n \n \n \n \n {{value}}\n \n \n \n \n and {{value}}\n \n \n \n \n
\n ",
- encapsulation: core_1.ViewEncapsulation.None
- }),
- __metadata('design:paramtypes', [])
- ], RowDetailsComponent);
- return RowDetailsComponent;
-}());
-exports.RowDetailsComponent = RowDetailsComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/scrolling.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var HorzVertScrolling = (function () {
- function HorzVertScrolling() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- HorzVertScrolling.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/100k.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- HorzVertScrolling = __decorate([
- core_1.Component({
- selector: 'horz-vert-scrolling-demo',
- template: "\n \n
Horizontal and Vertical Scrolling
\n \n \n \n \n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], HorzVertScrolling);
- return HorzVertScrolling;
-}());
-exports.HorzVertScrolling = HorzVertScrolling;
-
-
-/***/ },
-
-/***/ "./demo/basic/tabs.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var TabsDemoComponent = (function () {
- function TabsDemoComponent() {
- var _this = this;
- this.rows = [];
- this.tab1 = true;
- this.tab2 = false;
- this.tab3 = false;
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- TabsDemoComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/100k.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- TabsDemoComponent = __decorate([
- core_1.Component({
- selector: 'tabs-demo',
- template: "\n \n
Hidden By Default
\n\n
\n
\n \n \n \n
\n\n
\n
Click a button to toggle table visibilities
\n
\n\n
\n
hidden Table
\n \n \n \n \n \n \n\n
\n
ngIf Table
\n \n \n \n \n \n \n
\n\n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], TabsDemoComponent);
- return TabsDemoComponent;
-}());
-exports.TabsDemoComponent = TabsDemoComponent;
-
-
-/***/ },
-
-/***/ "./demo/basic/virtual.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var VirtualScrollComponent = (function () {
- function VirtualScrollComponent() {
- var _this = this;
- this.rows = [];
- this.expanded = {};
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- VirtualScrollComponent.prototype.onPage = function (event) {
- clearTimeout(this.timeout);
- this.timeout = setTimeout(function () {
- console.log('paged!', event);
- }, 100);
- };
- VirtualScrollComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/100k.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- VirtualScrollComponent = __decorate([
- core_1.Component({
- selector: 'virtual-scroll-demo',
- template: "\n \n
Virtual Scrolling with 100k Rows
\n \n \n \n {{value}}\n \n \n \n \n and {{value}}\n \n \n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], VirtualScrollComponent);
- return VirtualScrollComponent;
-}());
-exports.VirtualScrollComponent = VirtualScrollComponent;
-
-
-/***/ },
-
-/***/ "./demo/bootstrap.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-var platform_browser_dynamic_1 = __webpack_require__(3);
-var hmr_1 = __webpack_require__("./node_modules/@angularclass/hmr/dist/index.js");
-var module_1 = __webpack_require__("./demo/module.ts");
-function main() {
- return platform_browser_dynamic_1.platformBrowserDynamic()
- .bootstrapModule(module_1.AppModule)
- .catch(function (err) { return console.error(err); });
-}
-exports.main = main;
-if (undefined)
- hmr_1.bootloader(main);
-if (!undefined)
- main();
-
-
-/***/ },
-
-/***/ "./demo/columns/column-flex.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ColumnFlexComponent = (function () {
- function ColumnFlexComponent() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data.splice(0, 5);
- });
- }
- ColumnFlexComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- ColumnFlexComponent = __decorate([
- core_1.Component({
- selector: 'column-flex-demo',
- template: "\n \n
Flex Column Width Distribution
\n \n \n \n {{value}}\n \n \n \n \n {{value}}\n \n \n \n \n {{value}}\n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ColumnFlexComponent);
- return ColumnFlexComponent;
-}());
-exports.ColumnFlexComponent = ColumnFlexComponent;
-
-
-/***/ },
-
-/***/ "./demo/columns/column-force.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ColumnForceComponent = (function () {
- function ColumnForceComponent() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data.splice(0, 5);
- });
- }
- ColumnForceComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- ColumnForceComponent = __decorate([
- core_1.Component({
- selector: 'column-force-demo',
- template: "\n \n
Force Fill Column Width Distribution
\n \n \n \n {{value}}\n \n \n \n \n {{value}}\n \n \n \n \n {{value}}\n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ColumnForceComponent);
- return ColumnForceComponent;
-}());
-exports.ColumnForceComponent = ColumnForceComponent;
-
-
-/***/ },
-
-/***/ "./demo/columns/column-standard.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ColumnStandardComponent = (function () {
- function ColumnStandardComponent() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data.splice(0, 5);
- });
- }
- ColumnStandardComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- ColumnStandardComponent = __decorate([
- core_1.Component({
- selector: 'column-standard-demo',
- template: "\n \n
Fixed Column Widths
\n \n \n \n {{value}}\n \n \n \n \n {{value}}\n \n \n \n \n {{value}}\n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ColumnStandardComponent);
- return ColumnStandardComponent;
-}());
-exports.ColumnStandardComponent = ColumnStandardComponent;
-
-
-/***/ },
-
-/***/ "./demo/columns/column-toggle.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ColumnToggleComponent = (function () {
- function ColumnToggleComponent() {
- this.rows = [
- {
- name: 'Claudine Neal',
- gender: 'female',
- company: 'Sealoud'
- },
- {
- name: 'Beryl Rice',
- gender: 'female',
- company: 'Velity'
- }
- ];
- this.columns = [
- { name: 'Name' },
- { name: 'Gender' },
- { name: 'Company' }
- ];
- this.allColumns = [
- { name: 'Name' },
- { name: 'Gender' },
- { name: 'Company' }
- ];
- }
- ColumnToggleComponent.prototype.toggle = function (col) {
- var isChecked = this.isChecked(col);
- if (isChecked) {
- this.columns = this.columns.filter(function (c) {
- return c.name !== col.name;
- });
- }
- else {
- this.columns = this.columns.concat([col]);
- }
- };
- ColumnToggleComponent.prototype.isChecked = function (col) {
- return this.columns.find(function (c) {
- return c.name === col.name;
- });
- };
- ColumnToggleComponent = __decorate([
- core_1.Component({
- selector: 'column-toggle-demo',
- template: "\n \n
Column Toggling
\n
\n \n \n
\n
\n
Available Columns
\n
\n
\n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], ColumnToggleComponent);
- return ColumnToggleComponent;
-}());
-exports.ColumnToggleComponent = ColumnToggleComponent;
-
-
-/***/ },
-
-/***/ "./demo/columns/pinning.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ColumnPinningComponent = (function () {
- function ColumnPinningComponent() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- ColumnPinningComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/100k.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- ColumnPinningComponent = __decorate([
- core_1.Component({
- selector: 'column-pinning-demo',
- template: "\n \n
Column Pinning
\n \n \n \n \n \n \n \n \n \n \n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ColumnPinningComponent);
- return ColumnPinningComponent;
-}());
-exports.ColumnPinningComponent = ColumnPinningComponent;
-
-
-/***/ },
-
-/***/ "./demo/module.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var platform_browser_1 = __webpack_require__(4);
-var hmr_1 = __webpack_require__("./node_modules/@angularclass/hmr/dist/index.js");
-var src_1 = __webpack_require__("./src/index.ts");
-var app_component_1 = __webpack_require__("./demo/app.component.ts");
-__webpack_require__("./src/components/datatable.scss");
-__webpack_require__("./src/themes/material.scss");
-// -- Basic
-var basic_fixed_1 = __webpack_require__("./demo/basic/basic-fixed.ts");
-var basic_auto_1 = __webpack_require__("./demo/basic/basic-auto.ts");
-var virtual_1 = __webpack_require__("./demo/basic/virtual.ts");
-var inline_1 = __webpack_require__("./demo/basic/inline.ts");
-var scrolling_1 = __webpack_require__("./demo/basic/scrolling.ts");
-var multiple_1 = __webpack_require__("./demo/basic/multiple.ts");
-var fullscreen_1 = __webpack_require__("./demo/basic/fullscreen.ts");
-var row_detail_1 = __webpack_require__("./demo/basic/row-detail.ts");
-var filter_1 = __webpack_require__("./demo/basic/filter.ts");
-var tabs_1 = __webpack_require__("./demo/basic/tabs.ts");
-var live_1 = __webpack_require__("./demo/basic/live.ts");
-// -- Paging
-var paging_client_1 = __webpack_require__("./demo/paging/paging-client.ts");
-var paging_server_1 = __webpack_require__("./demo/paging/paging-server.ts");
-// -- Sorting
-var sorting_comparator_1 = __webpack_require__("./demo/sorting/sorting-comparator.ts");
-var sorting_server_1 = __webpack_require__("./demo/sorting/sorting-server.ts");
-var sorting_client_1 = __webpack_require__("./demo/sorting/sorting-client.ts");
-// -- Templates
-var template_dom_1 = __webpack_require__("./demo/templates/template-dom.ts");
-var template_obj_1 = __webpack_require__("./demo/templates/template-obj.ts");
-// -- Selection
-var selection_cell_1 = __webpack_require__("./demo/selection/selection-cell.ts");
-var selection_multi_1 = __webpack_require__("./demo/selection/selection-multi.ts");
-var selection_single_1 = __webpack_require__("./demo/selection/selection-single.ts");
-var selection_shift_1 = __webpack_require__("./demo/selection/selection-shift.ts");
-var selection_disabled_1 = __webpack_require__("./demo/selection/selection-disabled.ts");
-// -- Columns
-var column_toggle_1 = __webpack_require__("./demo/columns/column-toggle.ts");
-var column_standard_1 = __webpack_require__("./demo/columns/column-standard.ts");
-var column_force_1 = __webpack_require__("./demo/columns/column-force.ts");
-var column_flex_1 = __webpack_require__("./demo/columns/column-flex.ts");
-var pinning_1 = __webpack_require__("./demo/columns/pinning.ts");
-var AppModule = (function () {
- function AppModule(appRef) {
- this.appRef = appRef;
- }
- AppModule.prototype.hmrOnDestroy = function (store) {
- var cmpLocation = this.appRef.components.map(function (cmp) { return cmp.location.nativeElement; });
- store.disposeOldHosts = hmr_1.createNewHosts(cmpLocation);
- hmr_1.removeNgStyles();
- };
- AppModule.prototype.hmrAfterDestroy = function (store) {
- store.disposeOldHosts();
- delete store.disposeOldHosts;
- };
- AppModule = __decorate([
- core_1.NgModule({
- declarations: [
- app_component_1.AppComponent,
- basic_auto_1.BasicAutoComponent,
- basic_fixed_1.BasicFixedComponent,
- fullscreen_1.FullScreenComponent,
- inline_1.InlineEditComponent,
- virtual_1.VirtualScrollComponent,
- scrolling_1.HorzVertScrolling,
- multiple_1.MultipleTablesComponent,
- row_detail_1.RowDetailsComponent,
- paging_client_1.ClientPagingComponent,
- paging_server_1.ServerPagingComponent,
- sorting_client_1.ClientSortingComponent,
- sorting_server_1.ServerSortingComponent,
- sorting_comparator_1.SortingComparatorComponent,
- selection_cell_1.CellSelectionComponent,
- selection_multi_1.MultiSelectionComponent,
- template_dom_1.InlineTemplatesComponent,
- template_obj_1.TemplateRefTemplatesComponent,
- column_flex_1.ColumnFlexComponent,
- column_toggle_1.ColumnToggleComponent,
- column_standard_1.ColumnStandardComponent,
- column_force_1.ColumnForceComponent,
- pinning_1.ColumnPinningComponent,
- filter_1.FilterBarComponent,
- tabs_1.TabsDemoComponent,
- selection_single_1.SingleSelectionComponent,
- live_1.LiveDataComponent,
- selection_shift_1.MultiShiftSelectionComponent,
- selection_disabled_1.MultiDisableSelectionComponent
- ],
- imports: [platform_browser_1.BrowserModule, src_1.Angular2DataTableModule],
- bootstrap: [app_component_1.AppComponent]
- }),
- __metadata('design:paramtypes', [core_1.ApplicationRef])
- ], AppModule);
- return AppModule;
-}());
-exports.AppModule = AppModule;
-
-
-/***/ },
-
-/***/ "./demo/paging/paging-client.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ClientPagingComponent = (function () {
- function ClientPagingComponent() {
- var _this = this;
- this.rows = [];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- ClientPagingComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- ClientPagingComponent = __decorate([
- core_1.Component({
- selector: 'client-paging-demo',
- template: "\n \n
Client-side Paging
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ClientPagingComponent);
- return ClientPagingComponent;
-}());
-exports.ClientPagingComponent = ClientPagingComponent;
-
-
-/***/ },
-
-/***/ "./demo/paging/paging-server.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ServerPagingComponent = (function () {
- function ServerPagingComponent() {
- this.rows = [];
- this.count = 0;
- this.offset = 0;
- this.limit = 10;
- }
- ServerPagingComponent.prototype.ngOnInit = function () {
- this.page(this.offset, this.limit);
- };
- ServerPagingComponent.prototype.page = function (offset, limit) {
- var _this = this;
- this.fetch(function (results) {
- _this.count = results.length;
- var start = offset * limit;
- var end = start + limit;
- var rows = _this.rows.slice();
- for (var i = start; i < end; i++) {
- rows[i] = results[i];
- }
- _this.rows = rows;
- console.log('Page Results', start, end, rows);
- });
- };
- ServerPagingComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- ServerPagingComponent.prototype.onPage = function (event) {
- console.log('Page Event', event);
- this.page(event.offset, event.limit);
- };
- ServerPagingComponent = __decorate([
- core_1.Component({
- selector: 'server-paging-demo',
- template: "\n \n
Server-side Paging
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ServerPagingComponent);
- return ServerPagingComponent;
-}());
-exports.ServerPagingComponent = ServerPagingComponent;
-
-
-/***/ },
-
-/***/ "./demo/selection/selection-cell.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var CellSelectionComponent = (function () {
- function CellSelectionComponent() {
- var _this = this;
- this.rows = [];
- this.selected = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- CellSelectionComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- CellSelectionComponent.prototype.onSelect = function (event) {
- console.log('Event: select', event, this.selected);
- };
- CellSelectionComponent.prototype.onActivate = function (event) {
- console.log('Event: activate', event);
- };
- CellSelectionComponent = __decorate([
- core_1.Component({
- selector: 'cell-selection-demo',
- template: "\n \n
Cell Selection
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], CellSelectionComponent);
- return CellSelectionComponent;
-}());
-exports.CellSelectionComponent = CellSelectionComponent;
-
-
-/***/ },
-
-/***/ "./demo/selection/selection-disabled.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var MultiDisableSelectionComponent = (function () {
- function MultiDisableSelectionComponent() {
- var _this = this;
- this.rows = [];
- this.selected = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- MultiDisableSelectionComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- MultiDisableSelectionComponent.prototype.onSelect = function (_a) {
- var selected = _a.selected;
- console.log('Select Event', selected, this.selected);
- this.selected.splice(0, this.selected.length);
- (_b = this.selected).push.apply(_b, selected);
- var _b;
- };
- MultiDisableSelectionComponent.prototype.onActivate = function (event) {
- console.log('Activate Event', event);
- };
- MultiDisableSelectionComponent.prototype.checkSelectable = function (event) {
- console.log('Checking if selectable', event);
- return event.name !== 'Ethel Price';
- };
- MultiDisableSelectionComponent = __decorate([
- core_1.Component({
- selector: 'multidisable-selection-demo',
- template: "\n \n
Selection Callback to Disable Selections
\n
\n \n \n
\n\n
\n
Selections
\n
\n - \n {{sel.name}}\n
\n - No Selections
\n
\n
\n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], MultiDisableSelectionComponent);
- return MultiDisableSelectionComponent;
-}());
-exports.MultiDisableSelectionComponent = MultiDisableSelectionComponent;
-
-
-/***/ },
-
-/***/ "./demo/selection/selection-multi.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var MultiSelectionComponent = (function () {
- function MultiSelectionComponent() {
- var _this = this;
- this.rows = [];
- this.selected = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- MultiSelectionComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- MultiSelectionComponent.prototype.onSelect = function (_a) {
- var selected = _a.selected;
- console.log('Select Event', selected, this.selected);
- this.selected.splice(0, this.selected.length);
- (_b = this.selected).push.apply(_b, selected);
- var _b;
- };
- MultiSelectionComponent.prototype.onActivate = function (event) {
- console.log('Activate Event', event);
- };
- MultiSelectionComponent = __decorate([
- core_1.Component({
- selector: 'multi-selection-demo',
- template: "\n \n
Multi Select via Click
\n
\n \n \n
\n\n
\n
Selections
\n
\n - \n {{sel.name}}\n
\n - No Selections
\n
\n
\n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], MultiSelectionComponent);
- return MultiSelectionComponent;
-}());
-exports.MultiSelectionComponent = MultiSelectionComponent;
-
-
-/***/ },
-
-/***/ "./demo/selection/selection-shift.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var MultiShiftSelectionComponent = (function () {
- function MultiShiftSelectionComponent() {
- var _this = this;
- this.rows = [];
- this.selected = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- MultiShiftSelectionComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- MultiShiftSelectionComponent.prototype.onSelect = function (_a) {
- var selected = _a.selected;
- console.log('Select Event', selected, this.selected);
- this.selected.splice(0, this.selected.length);
- (_b = this.selected).push.apply(_b, selected);
- var _b;
- };
- MultiShiftSelectionComponent.prototype.onActivate = function (event) {
- console.log('Activate Event', event);
- };
- MultiShiftSelectionComponent = __decorate([
- core_1.Component({
- selector: 'multishift-selection-demo',
- template: "\n \n
Multi Select via Shift
\n
\n \n \n
\n\n
\n
Selections
\n
\n - \n {{sel.name}}\n
\n - No Selections
\n
\n
\n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], MultiShiftSelectionComponent);
- return MultiShiftSelectionComponent;
-}());
-exports.MultiShiftSelectionComponent = MultiShiftSelectionComponent;
-
-
-/***/ },
-
-/***/ "./demo/selection/selection-single.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var SingleSelectionComponent = (function () {
- function SingleSelectionComponent() {
- var _this = this;
- this.rows = [];
- this.selected = [];
- this.columns = [
- { prop: 'name' },
- { name: 'Company' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- SingleSelectionComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- SingleSelectionComponent.prototype.onSelect = function (_a) {
- var selected = _a.selected;
- console.log('Select Event', selected, this.selected);
- this.selected.splice(0, this.selected.length);
- (_b = this.selected).push.apply(_b, selected);
- var _b;
- };
- SingleSelectionComponent.prototype.onActivate = function (event) {
- console.log('Activate Event', event);
- };
- SingleSelectionComponent = __decorate([
- core_1.Component({
- selector: 'single-selection-demo',
- template: "\n \n
Single Row Selection
\n
\n \n \n
\n\n
\n
Selections
\n
\n - \n {{sel.name}}\n
\n - No Selections
\n
\n
\n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], SingleSelectionComponent);
- return SingleSelectionComponent;
-}());
-exports.SingleSelectionComponent = SingleSelectionComponent;
-
-
-/***/ },
-
-/***/ "./demo/sorting/sorting-client.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ClientSortingComponent = (function () {
- function ClientSortingComponent() {
- var _this = this;
- this.rows = [];
- this.columns = [
- { name: 'Company' },
- { name: 'Name' },
- { name: 'Gender' }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- ClientSortingComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- var data = JSON.parse(req.response);
- cb(data);
- };
- req.send();
- };
- ClientSortingComponent = __decorate([
- core_1.Component({
- selector: 'client-sorting-demo',
- template: "\n \n
Client-side Sorting
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ClientSortingComponent);
- return ClientSortingComponent;
-}());
-exports.ClientSortingComponent = ClientSortingComponent;
-
-
-/***/ },
-
-/***/ "./demo/sorting/sorting-comparator.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var SortingComparatorComponent = (function () {
- function SortingComparatorComponent() {
- var _this = this;
- this.rows = [];
- this.columns = [
- { name: 'Company', comparator: this.companyComparator.bind(this) },
- { name: 'Name', sortable: false },
- { name: 'Gender', sortable: false }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- SortingComparatorComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- var data = JSON.parse(req.response);
- cb(data.splice(0, 20));
- };
- req.send();
- };
- SortingComparatorComponent.prototype.companyComparator = function (propA, propB) {
- console.log('Sorting Comparator', propA, propB);
- // Just a simple sort function comparisoins
- if (propA.toLowerCase() < propB.toLowerCase())
- return -1;
- if (propA.toLowerCase() > propB.toLowerCase())
- return 1;
- };
- SortingComparatorComponent = __decorate([
- core_1.Component({
- selector: 'comparator-sorting-demo',
- template: "\n \n
Custom Sorting Comparator
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], SortingComparatorComponent);
- return SortingComparatorComponent;
-}());
-exports.SortingComparatorComponent = SortingComparatorComponent;
-
-
-/***/ },
-
-/***/ "./demo/sorting/sorting-server.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ServerSortingComponent = (function () {
- function ServerSortingComponent() {
- var _this = this;
- this.loading = false;
- this.rows = [];
- this.columns = [
- // we pass false to bypass the default
- // comparator function and use the event to sort
- { name: 'Company', sortable: true },
- { name: 'Name', sortable: true },
- { name: 'Gender', sortable: true }
- ];
- this.fetch(function (data) {
- _this.rows = data;
- });
- }
- ServerSortingComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- var data = JSON.parse(req.response);
- cb(data.splice(0, 20));
- };
- req.send();
- };
- ServerSortingComponent.prototype.onSort = function (event) {
- var _this = this;
- // event was triggered, start sort sequence
- console.log('Sort Event', event);
- this.loading = true;
- // emulate a server request with a timeout
- setTimeout(function () {
- var rows = _this.rows.slice();
- // this is only for demo purposes, normally
- // your server would return the result for
- // you and you would just set the rows prop
- var sort = event.sorts[0];
- rows.sort(function (a, b) {
- return a[sort.prop].localeCompare(b[sort.prop]) * (sort.dir === 'desc' ? -1 : 1);
- });
- _this.rows = rows;
- _this.loading = false;
- }, 1000);
- };
- ServerSortingComponent = __decorate([
- core_1.Component({
- selector: 'server-sorting-demo',
- template: "\n \n
Server-side Sorting
\n \n \n \n "
- }),
- __metadata('design:paramtypes', [])
- ], ServerSortingComponent);
- return ServerSortingComponent;
-}());
-exports.ServerSortingComponent = ServerSortingComponent;
-
-
-/***/ },
-
-/***/ "./demo/templates/template-dom.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var InlineTemplatesComponent = (function () {
- function InlineTemplatesComponent() {
- var _this = this;
- this.rows = [];
- this.joke = 'knock knock';
- this.fetch(function (data) {
- _this.rows = data.splice(0, 5);
- });
- }
- InlineTemplatesComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- InlineTemplatesComponent = __decorate([
- core_1.Component({
- selector: 'inline-templates-demo',
- template: "\n \n
Expressive Templates
\n
\n \n \n Holla! {{column.name}}\n \n \n Hi: {{value}}\n \n \n \n \n My name is: and {{value}}\n {{joke}}
\n \n \n \n \n \n \n \n \n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], InlineTemplatesComponent);
- return InlineTemplatesComponent;
-}());
-exports.InlineTemplatesComponent = InlineTemplatesComponent;
-
-
-/***/ },
-
-/***/ "./demo/templates/template-obj.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var TemplateRefTemplatesComponent = (function () {
- function TemplateRefTemplatesComponent() {
- var _this = this;
- this.rows = [];
- this.columns = [];
- this.fetch(function (data) {
- _this.rows = data.splice(0, 5);
- });
- }
- TemplateRefTemplatesComponent.prototype.ngOnInit = function () {
- this.columns = [{
- cellTemplate: this.editTmpl,
- headerTemplate: this.hdrTpl,
- name: 'Gender'
- }];
- };
- TemplateRefTemplatesComponent.prototype.fetch = function (cb) {
- var req = new XMLHttpRequest();
- req.open('GET', "assets/data/company.json");
- req.onload = function () {
- cb(JSON.parse(req.response));
- };
- req.send();
- };
- __decorate([
- core_1.ViewChild('editTmpl'),
- __metadata('design:type', core_1.TemplateRef)
- ], TemplateRefTemplatesComponent.prototype, "editTmpl", void 0);
- __decorate([
- core_1.ViewChild('hdrTpl'),
- __metadata('design:type', core_1.TemplateRef)
- ], TemplateRefTemplatesComponent.prototype, "hdrTpl", void 0);
- TemplateRefTemplatesComponent = __decorate([
- core_1.Component({
- selector: 'template-ref-demo',
- template: "\n \n
TemplateRef via Column Property
\n
\n \n\n
\n Fancy: {{column.name}} !!\n \n\n
\n \n \n \n
\n "
- }),
- __metadata('design:paramtypes', [])
- ], TemplateRefTemplatesComponent);
- return TemplateRefTemplatesComponent;
-}());
-exports.TemplateRefTemplatesComponent = TemplateRefTemplatesComponent;
-
-
-/***/ },
-
-/***/ "./node_modules/@angularclass/hmr/dist/helpers.js":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-// Hot Module Replacement
-function bootloader(main) {
- if (document.readyState === 'complete') {
- main();
- }
- else {
- document.addEventListener('DOMContentLoaded', main);
- }
-}
-exports.bootloader = bootloader;
-// create new elements
-function createNewHosts(cmps) {
- var components = cmps.map(function (componentNode) {
- var newNode = document.createElement(componentNode.tagName);
- // display none
- var currentDisplay = newNode.style.display;
- newNode.style.display = 'none';
- var parentNode = componentNode.parentNode;
- parentNode.insertBefore(newNode, componentNode);
- return { currentDisplay: currentDisplay, newNode: newNode };
- });
- return function () {
- components.forEach(function (cmp) {
- cmp.newNode.style.display = cmp.currentDisplay;
- cmp.newNode = null;
- cmp.currentDisplay = null;
- });
- };
-}
-exports.createNewHosts = createNewHosts;
-// remove old styles
-function removeNgStyles() {
- Array.prototype.slice.call(document.head.querySelectorAll('style'), 0)
- .filter(function (style) { return style.innerText.indexOf('_ng') !== -1; })
- .map(function (el) { return el.remove(); });
-}
-exports.removeNgStyles = removeNgStyles;
-// get input values
-function getInputValues() {
- var inputs = document.querySelectorAll('input');
- return Array.prototype.slice.call(inputs).map(function (input) { return input.value; });
-}
-exports.getInputValues = getInputValues;
-// set input values
-function setInputValues($inputs) {
- var inputs = document.querySelectorAll('input');
- if ($inputs && inputs.length === $inputs.length) {
- $inputs.forEach(function (value, i) {
- var el = inputs[i];
- el.value = value;
- el.dispatchEvent(new CustomEvent('input', { detail: el.value }));
- });
- }
-}
-exports.setInputValues = setInputValues;
-// get/set input values
-function createInputTransfer() {
- var $inputs = getInputValues();
- return function restoreInputValues() {
- setInputValues($inputs);
- };
-}
-exports.createInputTransfer = createInputTransfer;
-//# sourceMappingURL=helpers.js.map
-
-/***/ },
-
-/***/ "./node_modules/@angularclass/hmr/dist/index.js":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-// Hot Module Replacement
-__export(__webpack_require__("./node_modules/@angularclass/hmr/dist/helpers.js"));
-//# sourceMappingURL=index.js.map
-
-/***/ },
-
-/***/ "./src/components/body/body-cell.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var types_1 = __webpack_require__("./src/types/index.ts");
-var DataTableBodyCellComponent = (function () {
- function DataTableBodyCellComponent(element, renderer) {
- this.activate = new core_1.EventEmitter();
- this.isFocused = false;
- this.element = element.nativeElement;
- renderer.setElementClass(this.element, 'datatable-body-cell', true);
- }
- Object.defineProperty(DataTableBodyCellComponent.prototype, "sorts", {
- get: function () {
- return this._sorts;
- },
- set: function (val) {
- this._sorts = val;
- this.calcSortDir = this.calcSortDir(val);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyCellComponent.prototype, "isSortActive", {
- get: function () {
- return !this.sortDir;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyCellComponent.prototype, "isSortAscending", {
- get: function () {
- return this.sortDir === types_1.SortDirection.asc;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyCellComponent.prototype, "isSortDescending", {
- get: function () {
- return this.sortDir === types_1.SortDirection.desc;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyCellComponent.prototype, "width", {
- get: function () {
- return this.column.width;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyCellComponent.prototype, "height", {
- get: function () {
- var height = this.rowHeight;
- if (isNaN(height))
- return height;
- return height + 'px';
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyCellComponent.prototype, "value", {
- get: function () {
- if (!this.row || !this.column)
- return '';
- var prop = utils_1.deepValueGetter(this.row, this.column.prop);
- var userPipe = this.column.pipe;
- return userPipe ? userPipe.transform(prop) : prop;
- },
- enumerable: true,
- configurable: true
- });
- DataTableBodyCellComponent.prototype.onFocus = function (event) {
- this.isFocused = true;
- };
- DataTableBodyCellComponent.prototype.onBlur = function (event) {
- this.isFocused = false;
- };
- DataTableBodyCellComponent.prototype.onClick = function (event) {
- this.activate.emit({
- type: 'click',
- event: event,
- row: this.row,
- column: this.column,
- value: this.value,
- cellElement: this.element
- });
- };
- DataTableBodyCellComponent.prototype.onDblClick = function (event) {
- this.activate.emit({
- type: 'dblclick',
- event: event,
- row: this.row,
- column: this.column,
- value: this.value,
- cellElement: this.element
- });
- };
- DataTableBodyCellComponent.prototype.onKeyDown = function (event) {
- var keyCode = event.keyCode;
- var isTargetCell = event.target === this.element;
- var isAction = keyCode === utils_1.Keys.return ||
- keyCode === utils_1.Keys.down ||
- keyCode === utils_1.Keys.up ||
- keyCode === utils_1.Keys.left ||
- keyCode === utils_1.Keys.right;
- if (isAction && isTargetCell) {
- event.preventDefault();
- event.stopPropagation();
- this.activate.emit({
- type: 'keydown',
- event: event,
- row: this.row,
- column: this.column,
- value: this.value,
- cellElement: this.element
- });
- }
- };
- DataTableBodyCellComponent.prototype.calcSortDir = function (sorts) {
- var _this = this;
- if (!sorts)
- return;
- var sort = sorts.find(function (s) {
- return s.prop === _this.column.prop;
- });
- if (sort)
- return sort.dir;
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyCellComponent.prototype, "row", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyCellComponent.prototype, "column", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyCellComponent.prototype, "rowHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DataTableBodyCellComponent.prototype, "sorts", null);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyCellComponent.prototype, "activate", void 0);
- __decorate([
- core_1.HostBinding('class.active'),
- __metadata('design:type', Boolean)
- ], DataTableBodyCellComponent.prototype, "isFocused", void 0);
- __decorate([
- core_1.HostBinding('class.sort-active'),
- __metadata('design:type', Boolean)
- ], DataTableBodyCellComponent.prototype, "isSortActive", null);
- __decorate([
- core_1.HostBinding('class.sort-asc'),
- __metadata('design:type', Boolean)
- ], DataTableBodyCellComponent.prototype, "isSortAscending", null);
- __decorate([
- core_1.HostBinding('class.sort-desc'),
- __metadata('design:type', Boolean)
- ], DataTableBodyCellComponent.prototype, "isSortDescending", null);
- __decorate([
- core_1.HostBinding('style.width.px'),
- __metadata('design:type', Number)
- ], DataTableBodyCellComponent.prototype, "width", null);
- __decorate([
- core_1.HostBinding('style.height'),
- __metadata('design:type', Object)
- ], DataTableBodyCellComponent.prototype, "height", null);
- __decorate([
- core_1.HostListener('focus', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DataTableBodyCellComponent.prototype, "onFocus", null);
- __decorate([
- core_1.HostListener('blur', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DataTableBodyCellComponent.prototype, "onBlur", null);
- __decorate([
- core_1.HostListener('click', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DataTableBodyCellComponent.prototype, "onClick", null);
- __decorate([
- core_1.HostListener('dblclick', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DataTableBodyCellComponent.prototype, "onDblClick", null);
- __decorate([
- core_1.HostListener('keydown', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DataTableBodyCellComponent.prototype, "onKeyDown", null);
- DataTableBodyCellComponent = __decorate([
- core_1.Component({
- selector: 'datatable-body-cell',
- template: "\n \n \n \n \n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTableBodyCellComponent);
- return DataTableBodyCellComponent;
-}());
-exports.DataTableBodyCellComponent = DataTableBodyCellComponent;
-
-
-/***/ },
-
-/***/ "./src/components/body/body-row-wrapper.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var DataTableRowWrapperComponent = (function () {
- function DataTableRowWrapperComponent(element, renderer) {
- this.expanded = false;
- renderer.setElementClass(element.nativeElement, 'datatable-row-wrapper', true);
- }
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableRowWrapperComponent.prototype, "rowDetailTemplate", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableRowWrapperComponent.prototype, "detailRowHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableRowWrapperComponent.prototype, "expanded", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableRowWrapperComponent.prototype, "row", void 0);
- DataTableRowWrapperComponent = __decorate([
- core_1.Component({
- selector: 'datatable-row-wrapper',
- template: "\n \n \n \n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTableRowWrapperComponent);
- return DataTableRowWrapperComponent;
-}());
-exports.DataTableRowWrapperComponent = DataTableRowWrapperComponent;
-
-
-/***/ },
-
-/***/ "./src/components/body/body-row.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var DataTableBodyRowComponent = (function () {
- function DataTableBodyRowComponent(element, renderer) {
- this.activate = new core_1.EventEmitter();
- this.element = element.nativeElement;
- renderer.setElementClass(this.element, 'datatable-body-row', true);
- }
- Object.defineProperty(DataTableBodyRowComponent.prototype, "columns", {
- get: function () {
- return this._columns;
- },
- set: function (val) {
- this._columns = val;
- this.recalculateColumns(val);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyRowComponent.prototype, "innerWidth", {
- get: function () {
- return this._innerWidth;
- },
- set: function (val) {
- this._innerWidth = val;
- this.recalculateColumns();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyRowComponent.prototype, "isEvenRow", {
- get: function () {
- return this.row.$$index % 2 === 0;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyRowComponent.prototype, "isOddRow", {
- get: function () {
- return this.row.$$index % 2 !== 0;
- },
- enumerable: true,
- configurable: true
- });
- DataTableBodyRowComponent.prototype.stylesByGroup = function (group) {
- var widths = this.columnGroupWidths;
- var offsetX = this.offsetX;
- var styles = {
- width: widths[group] + "px"
- };
- if (group === 'left') {
- utils_1.translateXY(styles, offsetX, 0);
- }
- else if (group === 'right') {
- var bodyWidth = parseInt(this.innerWidth + '', 0);
- var totalDiff = widths.total - bodyWidth;
- var offsetDiff = totalDiff - offsetX;
- var offset = (offsetDiff + utils_1.scrollbarWidth) * -1;
- utils_1.translateXY(styles, offset, 0);
- }
- return styles;
- };
- DataTableBodyRowComponent.prototype.onActivate = function (event, index) {
- event.cellIndex = index;
- event.rowElement = this.element;
- this.activate.emit(event);
- };
- DataTableBodyRowComponent.prototype.onKeyDown = function (event) {
- var keyCode = event.keyCode;
- var isTargetRow = event.target === this.element;
- var isAction = keyCode === utils_1.Keys.return ||
- keyCode === utils_1.Keys.down ||
- keyCode === utils_1.Keys.up ||
- keyCode === utils_1.Keys.left ||
- keyCode === utils_1.Keys.right;
- if (isAction && isTargetRow) {
- event.preventDefault();
- event.stopPropagation();
- this.activate.emit({
- type: 'keydown',
- event: event,
- row: this.row,
- rowElement: this.element
- });
- }
- };
- DataTableBodyRowComponent.prototype.recalculateColumns = function (val) {
- if (val === void 0) { val = this.columns; }
- var colsByPin = utils_1.columnsByPin(val);
- this.columnsByPin = utils_1.columnsByPinArr(val);
- this.columnGroupWidths = utils_1.columnGroupWidths(colsByPin, val);
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DataTableBodyRowComponent.prototype, "columns", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTableBodyRowComponent.prototype, "innerWidth", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyRowComponent.prototype, "row", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyRowComponent.prototype, "offsetX", void 0);
- __decorate([
- core_1.HostBinding('style.height.px'),
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyRowComponent.prototype, "rowHeight", void 0);
- __decorate([
- core_1.HostBinding('class.active'),
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableBodyRowComponent.prototype, "isSelected", void 0);
- __decorate([
- core_1.HostBinding('class.datatable-row-even'),
- __metadata('design:type', Boolean)
- ], DataTableBodyRowComponent.prototype, "isEvenRow", null);
- __decorate([
- core_1.HostBinding('class.datatable-row-odd'),
- __metadata('design:type', Boolean)
- ], DataTableBodyRowComponent.prototype, "isOddRow", null);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyRowComponent.prototype, "activate", void 0);
- __decorate([
- core_1.HostListener('keydown', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DataTableBodyRowComponent.prototype, "onKeyDown", null);
- DataTableBodyRowComponent = __decorate([
- core_1.Component({
- selector: 'datatable-body-row',
- template: "\n \n \n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTableBodyRowComponent);
- return DataTableBodyRowComponent;
-}());
-exports.DataTableBodyRowComponent = DataTableBodyRowComponent;
-
-
-/***/ },
-
-/***/ "./src/components/body/body.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var types_1 = __webpack_require__("./src/types/index.ts");
-var scroller_component_1 = __webpack_require__("./src/components/body/scroller.component.ts");
-var DataTableBodyComponent = (function () {
- function DataTableBodyComponent(element, renderer) {
- this.selected = [];
- this.scroll = new core_1.EventEmitter();
- this.page = new core_1.EventEmitter();
- this.activate = new core_1.EventEmitter();
- this.select = new core_1.EventEmitter();
- this.detailToggle = new core_1.EventEmitter();
- this.rowHeightsCache = new utils_1.RowHeightCache();
- this.temp = [];
- this.offsetY = 0;
- this.indexes = {};
- renderer.setElementClass(element.nativeElement, 'datatable-body', true);
- // declare fn here so we can get access to the `this` property
- this.rowTrackingFn = function (index, row) {
- if (this.trackByProp) {
- return row.$$index + "-" + this.trackByProp;
- }
- else {
- return row.$$index;
- }
- }.bind(this);
- }
- Object.defineProperty(DataTableBodyComponent.prototype, "pageSize", {
- get: function () {
- return this._pageSize;
- },
- set: function (val) {
- this._pageSize = val;
- this.recalcLayout();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "rows", {
- get: function () {
- return this._rows;
- },
- set: function (val) {
- this._rows = val;
- this.recalcLayout();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "columns", {
- get: function () {
- return this._columns;
- },
- set: function (val) {
- this._columns = val;
- var colsByPin = utils_1.columnsByPin(val);
- this.columnGroupWidths = utils_1.columnGroupWidths(colsByPin, val);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "offset", {
- get: function () {
- return this._offset;
- },
- set: function (val) {
- this._offset = val;
- this.recalcLayout();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "rowCount", {
- get: function () {
- return this._rowCount;
- },
- set: function (val) {
- this._rowCount = val;
- this.recalcLayout();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "bodyWidth", {
- get: function () {
- if (this.scrollbarH) {
- return this.innerWidth + 'px';
- }
- else {
- return '100%';
- }
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "bodyHeight", {
- get: function () {
- return this._bodyHeight;
- },
- set: function (val) {
- if (this.scrollbarV) {
- this._bodyHeight = val + 'px';
- }
- else {
- this._bodyHeight = 'auto';
- }
- this.recalcLayout();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "selectEnabled", {
- get: function () {
- return !!this.selectionType;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableBodyComponent.prototype, "scrollHeight", {
- /**
- * Property that would calculate the height of scroll bar
- * based on the row heights cache for virtual scroll. Other scenarios
- * calculate scroll height automatically (as height will be undefined).
- */
- get: function () {
- if (this.scrollbarV) {
- return this.rowHeightsCache.query(this.rowCount - 1);
- }
- },
- enumerable: true,
- configurable: true
- });
- DataTableBodyComponent.prototype.updateOffsetY = function (offset) {
- if (this.scrollbarV && offset) {
- // First get the row Index that we need to move to.
- var rowIndex = this.pageSize * offset;
- offset = this.rowHeightsCache.query(rowIndex - 1);
- }
- this.scroller.setOffset(offset || 0);
- };
- DataTableBodyComponent.prototype.onBodyScroll = function (_a) {
- var scrollYPos = _a.scrollYPos, scrollXPos = _a.scrollXPos, direction = _a.direction;
- // if scroll change, trigger update
- // this is mainly used for header cell positions
- if (this.offsetY !== scrollYPos || this.offsetX !== scrollXPos) {
- this.scroll.emit({
- offsetY: scrollYPos,
- offsetX: scrollXPos
- });
- }
- this.offsetY = scrollYPos;
- this.offsetX = scrollXPos;
- this.updateIndexes();
- this.updatePage(direction);
- this.updateRows();
- };
- DataTableBodyComponent.prototype.updatePage = function (direction) {
- var offset = this.indexes.first / this.pageSize;
- if (direction === 'up') {
- offset = Math.floor(offset);
- }
- else if (direction === 'down') {
- offset = Math.ceil(offset);
- }
- if (direction !== undefined && !isNaN(offset)) {
- this.page.emit({ offset: offset });
- }
- };
- DataTableBodyComponent.prototype.updateRows = function () {
- var _a = this.indexes, first = _a.first, last = _a.last;
- var rowIndex = first;
- var idx = 0;
- var temp = [];
- while (rowIndex < last && rowIndex < this.rowCount) {
- var row = this.rows[rowIndex];
- if (row) {
- row.$$index = rowIndex;
- temp[idx] = row;
- }
- idx++;
- rowIndex++;
- }
- this.temp = temp;
- };
- /**
- * Calculate row height based on the expanded state of the row.
- *
- * @param row the row for which the height need to be calculated.
- * @returns {number} height of the row.
- */
- DataTableBodyComponent.prototype.getRowHeight = function (row) {
- // Adding detail row height if its expanded.
- return this.rowHeight +
- (row.$$expanded === 1 ? this.detailRowHeight : 0);
- };
- /**
- * Calculates the styles for the row so that the rows can be moved in 2D space
- * during virtual scroll inside the DOM. In the below case the Y position is
- * manipulated. As an example, if the height of row 0 is 30 px and row 1 is
- * 100 px then following styles are generated:
- *
- * transform: translate3d(0px, 0px, 0px); -> row0
- * transform: translate3d(0px, 30px, 0px); -> row1
- * transform: translate3d(0px, 130px, 0px); -> row2
- *
- * Row heights have to be calculated based on the row heights cache as we wont
- * be able to determine which row is of what height before hand. In the above
- * case the positionY of the translate3d for row2 would be the sum of all the
- * heights of the rows before it (i.e. row0 and row1).
- *
- * @param row The row that needs to be placed in the 2D space.
- * @returns {{styles: string}} Returns the CSS3 style to be applied
- */
- DataTableBodyComponent.prototype.getRowsStyles = function (row) {
- var rowHeight = this.getRowHeight(row);
- var styles = {
- height: rowHeight + 'px'
- };
- if (this.scrollbarV) {
- var idx = row ? row.$$index : 0;
- // const pos = idx * rowHeight;
- // The position of this row would be the sum of all row heights
- // until the previous row position.
- var pos = this.rowHeightsCache.query(idx - 1);
- utils_1.translateXY(styles, 0, pos);
- }
- return styles;
- };
- DataTableBodyComponent.prototype.hideIndicator = function () {
- var _this = this;
- setTimeout(function () { return _this.loadingIndicator = false; }, 500);
- };
- DataTableBodyComponent.prototype.updateIndexes = function () {
- var first = 0;
- var last = 0;
- if (this.scrollbarV) {
- // Calculation of the first and last indexes will be based on where the
- // scrollY position would be at. The last index would be the one
- // that shows up inside the view port the last.
- var height = parseInt(this.bodyHeight, 0);
- first = this.rowHeightsCache.getRowIndex(this.offsetY);
- last = this.rowHeightsCache.getRowIndex(height + this.offsetY) + 1;
- }
- else {
- first = Math.max(this.offset * this.pageSize, 0);
- last = Math.min((first + this.pageSize), this.rowCount);
- }
- this.indexes = { first: first, last: last };
- };
- /**
- * Refreshes the full Row Height cache. Should be used
- * when the entire row array state has changed.
- */
- DataTableBodyComponent.prototype.refreshRowHeightCache = function () {
- if (!this.scrollbarV)
- return;
- // clear the previous row height cache if already present.
- // this is useful during sorts, filters where the state of the
- // rows array is changed.
- this.rowHeightsCache.clearCache();
- // Initialize the tree only if there are rows inside the tree.
- if (this.rows && this.rows.length) {
- this.rowHeightsCache.initCache(this.rows, this.rowHeight, this.detailRowHeight);
- }
- };
- DataTableBodyComponent.prototype.getAdjustedViewPortIndex = function () {
- // Capture the row index of the first row that is visible on the viewport.
- // If the scroll bar is just below the row which is highlighted then make that as the
- // first index.
- var viewPortFirstRowIndex = this.indexes.first;
- if (this.scrollbarV) {
- var offsetScroll = this.rowHeightsCache.query(viewPortFirstRowIndex - 1);
- return offsetScroll <= this.offsetY ? viewPortFirstRowIndex - 1 : viewPortFirstRowIndex;
- }
- return viewPortFirstRowIndex;
- };
- /**
- * Toggle the Expansion of the row i.e. if the row is expanded then it will
- * collapse and vice versa. Note that the expanded status is stored as
- * a part of the row object itself as we have to preserve the expanded row
- * status in case of sorting and filtering of the row set.
- *
- * @param row The row for which the expansion needs to be toggled.
- */
- DataTableBodyComponent.prototype.toggleRowExpansion = function (row) {
- // Capture the row index of the first row that is visible on the viewport.
- var viewPortFirstRowIndex = this.getAdjustedViewPortIndex();
- // If the detailRowHeight is auto --> only in case of non-virtualized scroll
- if (this.scrollbarV) {
- var detailRowHeight = this.detailRowHeight * (row.$$expanded ? -1 : 1);
- this.rowHeightsCache.update(row.$$index, detailRowHeight);
- }
- // Update the toggled row and update the heights in the cache.
- row.$$expanded ^= 1;
- this.detailToggle.emit({
- rows: [row],
- currentIndex: viewPortFirstRowIndex
- });
- };
- /**
- * Expand/Collapse all the rows no matter what their state is.
- * @param expanded When true, all rows are expanded and when false, all rows will be collapsed.
- */
- DataTableBodyComponent.prototype.toggleAllRows = function (expanded) {
- var rowExpanded = expanded ? 1 : 0;
- // Capture the row index of the first row that is visible on the viewport.
- var viewPortFirstRowIndex = this.getAdjustedViewPortIndex();
- for (var _i = 0, _a = this.rows; _i < _a.length; _i++) {
- var row = _a[_i];
- row.$$expanded = rowExpanded;
- }
- if (this.scrollbarV) {
- // Refresh the full row heights cache since every row was affected.
- this.refreshRowHeightCache();
- }
- // Emit all rows that have been expanded.
- this.detailToggle.emit({
- rows: this.rows,
- currentIndex: viewPortFirstRowIndex
- });
- };
- DataTableBodyComponent.prototype.recalcLayout = function () {
- this.refreshRowHeightCache();
- this.updateIndexes();
- this.updateRows();
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableBodyComponent.prototype, "scrollbarV", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableBodyComponent.prototype, "scrollbarH", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableBodyComponent.prototype, "loadingIndicator", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyComponent.prototype, "rowHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyComponent.prototype, "offsetX", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyComponent.prototype, "detailRowHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableBodyComponent.prototype, "emptyMessage", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyComponent.prototype, "selectionType", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array)
- ], DataTableBodyComponent.prototype, "selected", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyComponent.prototype, "rowIdentity", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyComponent.prototype, "rowDetailTemplate", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableBodyComponent.prototype, "selectCheck", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableBodyComponent.prototype, "trackByProp", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTableBodyComponent.prototype, "pageSize", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DataTableBodyComponent.prototype, "rows", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DataTableBodyComponent.prototype, "columns", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTableBodyComponent.prototype, "offset", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTableBodyComponent.prototype, "rowCount", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableBodyComponent.prototype, "innerWidth", void 0);
- __decorate([
- core_1.HostBinding('style.width'),
- __metadata('design:type', String)
- ], DataTableBodyComponent.prototype, "bodyWidth", null);
- __decorate([
- core_1.Input(),
- core_1.HostBinding('style.height'),
- __metadata('design:type', Object),
- __metadata('design:paramtypes', [Object])
- ], DataTableBodyComponent.prototype, "bodyHeight", null);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyComponent.prototype, "scroll", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyComponent.prototype, "page", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyComponent.prototype, "activate", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyComponent.prototype, "select", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableBodyComponent.prototype, "detailToggle", void 0);
- __decorate([
- core_1.ViewChild(scroller_component_1.ScrollerComponent),
- __metadata('design:type', scroller_component_1.ScrollerComponent)
- ], DataTableBodyComponent.prototype, "scroller", void 0);
- DataTableBodyComponent = __decorate([
- core_1.Component({
- selector: 'datatable-body',
- template: "\n \n \n \n \n \n \n \n \n \n \n
\n \n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTableBodyComponent);
- return DataTableBodyComponent;
-}());
-exports.DataTableBodyComponent = DataTableBodyComponent;
-
-
-/***/ },
-
-/***/ "./src/components/body/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/components/body/body.component.ts"));
-__export(__webpack_require__("./src/components/body/body-cell.component.ts"));
-__export(__webpack_require__("./src/components/body/body-row.component.ts"));
-__export(__webpack_require__("./src/components/body/progress-bar.component.ts"));
-__export(__webpack_require__("./src/components/body/scroller.component.ts"));
-__export(__webpack_require__("./src/components/body/body-row-wrapper.component.ts"));
-__export(__webpack_require__("./src/components/body/selection.component.ts"));
-
-
-/***/ },
-
-/***/ "./src/components/body/progress-bar.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ProgressBarComponent = (function () {
- function ProgressBarComponent() {
- }
- ProgressBarComponent = __decorate([
- core_1.Component({
- selector: 'datatable-progress',
- template: "\n \n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [])
- ], ProgressBarComponent);
- return ProgressBarComponent;
-}());
-exports.ProgressBarComponent = ProgressBarComponent;
-
-
-/***/ },
-
-/***/ "./src/components/body/scroller.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var ScrollerComponent = (function () {
- function ScrollerComponent(element) {
- this.scrollbarV = false;
- this.scrollbarH = false;
- this.scroll = new core_1.EventEmitter();
- this.scrollYPos = 0;
- this.scrollXPos = 0;
- this.prevScrollYPos = 0;
- this.prevScrollXPos = 0;
- this.element = element.nativeElement;
- this.element.classList.add('datatable-scroll');
- }
- ScrollerComponent.prototype.ngOnInit = function () {
- // manual bind so we don't always listen
- if (this.scrollbarV || this.scrollbarH) {
- this.parentElement = this.element.parentElement.parentElement;
- this.parentElement.addEventListener('scroll', this.onScrolled.bind(this));
- }
- };
- ScrollerComponent.prototype.ngOnDestroy = function () {
- if (this.scrollbarV || this.scrollbarH) {
- this.parentElement.removeEventListener('scroll');
- }
- };
- ScrollerComponent.prototype.setOffset = function (offsetY) {
- if (this.parentElement) {
- this.parentElement.scrollTop = offsetY;
- }
- };
- ScrollerComponent.prototype.onScrolled = function (event) {
- var dom = event.currentTarget;
- this.scrollYPos = dom.scrollTop;
- this.scrollXPos = dom.scrollLeft;
- requestAnimationFrame(this.updateOffset.bind(this));
- };
- ScrollerComponent.prototype.updateOffset = function () {
- var direction;
- if (this.scrollYPos < this.prevScrollYPos) {
- direction = 'down';
- }
- else if (this.scrollYPos > this.prevScrollYPos) {
- direction = 'up';
- }
- this.scroll.emit({
- direction: direction,
- scrollYPos: this.scrollYPos,
- scrollXPos: this.scrollXPos
- });
- this.prevScrollYPos = this.scrollYPos;
- this.prevScrollXPos = this.scrollXPos;
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], ScrollerComponent.prototype, "scrollbarV", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], ScrollerComponent.prototype, "scrollbarH", void 0);
- __decorate([
- core_1.HostBinding('style.height.px'),
- core_1.Input(),
- __metadata('design:type', Number)
- ], ScrollerComponent.prototype, "scrollHeight", void 0);
- __decorate([
- core_1.HostBinding('style.width.px'),
- core_1.Input(),
- __metadata('design:type', Number)
- ], ScrollerComponent.prototype, "scrollWidth", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], ScrollerComponent.prototype, "scroll", void 0);
- ScrollerComponent = __decorate([
- core_1.Component({
- selector: 'datatable-scroller',
- template: "\n \n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef])
- ], ScrollerComponent);
- return ScrollerComponent;
-}());
-exports.ScrollerComponent = ScrollerComponent;
-
-
-/***/ },
-
-/***/ "./src/components/body/selection.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var types_1 = __webpack_require__("./src/types/index.ts");
-var DataTableSelectionComponent = (function () {
- function DataTableSelectionComponent() {
- this.activate = new core_1.EventEmitter();
- this.select = new core_1.EventEmitter();
- }
- DataTableSelectionComponent.prototype.selectRow = function (event, index, row) {
- if (!this.selectEnabled)
- return;
- var multiShift = this.selectionType === types_1.SelectionType.multiShift;
- var multiClick = this.selectionType === types_1.SelectionType.multi;
- var selected = [];
- if (multiShift || multiClick) {
- if (multiShift && event.shiftKey) {
- var newSelected = this.selected.slice();
- selected = utils_1.selectRowsBetween(newSelected, this.rows, index, this.prevIndex, this.getRowSelectedIdx.bind(this));
- }
- else if (multiShift && !event.shiftKey) {
- selected.push(row);
- }
- else {
- var newSelected = this.selected.slice();
- selected = utils_1.selectRows(newSelected, row, this.getRowSelectedIdx.bind(this));
- }
- }
- else {
- selected.push(row);
- }
- if (this.selectCheck) {
- selected = selected.filter(this.selectCheck.bind(this));
- }
- this.selected = selected;
- this.prevIndex = index;
- this.select.emit({
- selected: selected
- });
- };
- DataTableSelectionComponent.prototype.onActivate = function (model, index) {
- var type = model.type, event = model.event, row = model.row;
- if (type === 'click' || type === 'dblclick') {
- this.selectRow(event, index, row);
- }
- else if (type === 'keydown') {
- if (event.keyCode === utils_1.Keys.return) {
- this.selectRow(event, index, row);
- }
- else {
- this.onKeyboardFocus(model);
- }
- }
- this.activate.emit(model);
- };
- DataTableSelectionComponent.prototype.onKeyboardFocus = function (model) {
- var keyCode = model.event.keyCode;
- var shouldFocus = keyCode === utils_1.Keys.up ||
- keyCode === utils_1.Keys.down ||
- keyCode === utils_1.Keys.right ||
- keyCode === utils_1.Keys.left;
- if (shouldFocus) {
- var isCellSelection = this.selectionType === types_1.SelectionType.cell;
- if (!model.cellElement || !isCellSelection) {
- this.focusRow(model.rowElement, keyCode);
- }
- else if (isCellSelection) {
- this.focusCell(model.cellElement, model.rowElement, keyCode, model.cellIndex);
- }
- }
- };
- DataTableSelectionComponent.prototype.focusRow = function (rowElement, keyCode) {
- var nextRowElement = this.getPrevNextRow(rowElement, keyCode);
- if (nextRowElement)
- nextRowElement.focus();
- };
- DataTableSelectionComponent.prototype.getPrevNextRow = function (rowElement, keyCode) {
- var parentElement = rowElement.parentElement;
- if (parentElement) {
- var focusElement = void 0;
- if (keyCode === utils_1.Keys.up) {
- focusElement = parentElement.previousElementSibling;
- }
- else if (keyCode === utils_1.Keys.down) {
- focusElement = parentElement.nextElementSibling;
- }
- if (focusElement && focusElement.children.length) {
- return focusElement.children[0];
- }
- }
- };
- DataTableSelectionComponent.prototype.focusCell = function (cellElement, rowElement, keyCode, cellIndex) {
- var nextCellElement;
- if (keyCode === utils_1.Keys.left) {
- nextCellElement = cellElement.previousElementSibling;
- }
- else if (keyCode === utils_1.Keys.right) {
- nextCellElement = cellElement.nextElementSibling;
- }
- else if (keyCode === utils_1.Keys.up || keyCode === utils_1.Keys.down) {
- var nextRowElement = this.getPrevNextRow(rowElement, keyCode);
- if (nextRowElement) {
- var children = nextRowElement.getElementsByClassName('datatable-body-cell');
- if (children.length)
- nextCellElement = children[cellIndex];
- }
- }
- if (nextCellElement)
- nextCellElement.focus();
- };
- DataTableSelectionComponent.prototype.getRowSelected = function (row) {
- return this.getRowSelectedIdx(row, this.selected) > -1;
- };
- DataTableSelectionComponent.prototype.getRowSelectedIdx = function (row, selected) {
- var _this = this;
- if (!selected || !selected.length)
- return -1;
- var rowId = this.rowIdentity(row);
- return selected.findIndex(function (r) {
- var id = _this.rowIdentity(r);
- return id === rowId;
- });
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array)
- ], DataTableSelectionComponent.prototype, "rows", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array)
- ], DataTableSelectionComponent.prototype, "selected", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableSelectionComponent.prototype, "selectEnabled", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableSelectionComponent.prototype, "selectionType", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableSelectionComponent.prototype, "rowIdentity", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableSelectionComponent.prototype, "selectCheck", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableSelectionComponent.prototype, "activate", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableSelectionComponent.prototype, "select", void 0);
- DataTableSelectionComponent = __decorate([
- core_1.Component({
- selector: 'datatable-selection',
- template: "\n \n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [])
- ], DataTableSelectionComponent);
- return DataTableSelectionComponent;
-}());
-exports.DataTableSelectionComponent = DataTableSelectionComponent;
-
-
-/***/ },
-
-/***/ "./src/components/column.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var DataTableColumnDirective = (function () {
- function DataTableColumnDirective() {
- }
- Object.defineProperty(DataTableColumnDirective.prototype, "hasHeaderTemplate", {
- get: function () {
- // this is a tad nasty but can't think of a better way
- // to differate if the prop is header vs cell
- return this.templates.length === 2;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableColumnDirective.prototype, "headerTemplate", {
- get: function () {
- if (!this.hasHeaderTemplate)
- return undefined;
- return this.templates.first;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableColumnDirective.prototype, "cellTemplate", {
- get: function () {
- if (this.hasHeaderTemplate)
- return this.templates.last;
- return this.templates.first;
- },
- enumerable: true,
- configurable: true
- });
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "name", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "prop", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "frozenLeft", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "frozenRight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "flexGrow", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "resizeable", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "comparator", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "pipe", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "sortable", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "draggable", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "canAutoResize", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "minWidth", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "width", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableColumnDirective.prototype, "maxWidth", void 0);
- __decorate([
- core_1.ContentChildren(core_1.TemplateRef),
- __metadata('design:type', core_1.QueryList)
- ], DataTableColumnDirective.prototype, "templates", void 0);
- DataTableColumnDirective = __decorate([
- core_1.Directive({
- selector: 'datatable-column',
- }),
- __metadata('design:paramtypes', [])
- ], DataTableColumnDirective);
- return DataTableColumnDirective;
-}());
-exports.DataTableColumnDirective = DataTableColumnDirective;
-
-
-/***/ },
-
-/***/ "./src/components/datatable.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var types_1 = __webpack_require__("./src/types/index.ts");
-var body_1 = __webpack_require__("./src/components/body/index.ts");
-var column_directive_1 = __webpack_require__("./src/components/column.directive.ts");
-var row_detail_directive_1 = __webpack_require__("./src/components/row-detail.directive.ts");
-var utils_2 = __webpack_require__("./src/utils/index.ts");
-var DatatableComponent = (function () {
- function DatatableComponent(renderer, element) {
- // Enable vertical scrollbars
- this.scrollbarV = false;
- // Enable horz scrollbars
- this.scrollbarH = false;
- // The row height; which is necessary
- // to calculate the height for the lazy rendering.
- this.rowHeight = 30;
- // The detail row height is required especially when virtual scroll is enabled.
- this.detailRowHeight = 0;
- // Type of column width distribution.
- // Example: flex, force, standard
- this.columnMode = types_1.ColumnMode.standard;
- // The minimum header height in pixels.
- // pass falsey for no header
- // note: number|string does not work right
- this.headerHeight = 30;
- // The minimum footer height in pixels.
- // pass falsey for no footer
- this.footerHeight = 0;
- // if external paging is turned on
- this.externalPaging = false;
- // if external sorting is turned on
- this.externalSorting = false;
- // Page size
- this.limit = undefined;
- // Total count
- this.count = 0;
- // Page offset
- this.offset = 0;
- // Loading indicator
- this.loadingIndicator = false;
- // if you can reorder columns
- this.reorderable = true;
- // type of sorting
- this.sortType = types_1.SortType.single;
- // sorts
- this.sorts = [];
- // css class overrides
- this.cssClasses = {
- sortAscending: 'icon-down',
- sortDescending: 'icon-up',
- pagerLeftArrow: 'icon-left',
- pagerRightArrow: 'icon-right',
- pagerPrevious: 'icon-prev',
- pagerNext: 'icon-skip'
- };
- // message overrides for localization
- this.messages = {
- // Message to show when array is presented
- // but contains no values
- emptyMessage: 'No data to display',
- // Footer total message
- totalMessage: 'total'
- };
- // This will be used when displaying or selecting rows:
- // when tracking/comparing them, we'll use the value of this fn,
- // (`fn(x) === fn(y)` instead of `x === y`)
- this.rowIdentity = (function (x) { return x; });
- this.scroll = new core_1.EventEmitter();
- this.activate = new core_1.EventEmitter();
- this.select = new core_1.EventEmitter();
- this.sort = new core_1.EventEmitter();
- this.page = new core_1.EventEmitter();
- this.detailToggle = new core_1.EventEmitter();
- this.reorder = new core_1.EventEmitter();
- this.resize = new core_1.EventEmitter();
- this.offsetX = 0;
- this.element = element.nativeElement;
- renderer.setElementClass(this.element, 'datatable', true);
- }
- Object.defineProperty(DatatableComponent.prototype, "rows", {
- get: function () {
- return this._rows;
- },
- // Rows
- set: function (val) {
- if (!this.externalSorting) {
- val = utils_1.sortRows(val, this.columns, this.sorts);
- }
- this._rows = val;
- this.recalculate();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "columns", {
- get: function () {
- return this._columns;
- },
- // Columns
- set: function (val) {
- if (val) {
- utils_2.setColumnDefaults(val);
- this.recalculateColumns(val);
- }
- this._columns = val;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "isFixedHeader", {
- get: function () {
- var headerHeight = this.headerHeight;
- return (typeof headerHeight === 'string') ?
- headerHeight !== 'auto' : true;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "isFixedRow", {
- get: function () {
- var rowHeight = this.rowHeight;
- return (typeof rowHeight === 'string') ?
- rowHeight !== 'auto' : true;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "isVertScroll", {
- get: function () {
- return this.scrollbarV;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "isHorScroll", {
- get: function () {
- return this.scrollbarH;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "isSelectable", {
- get: function () {
- return this.selectionType !== undefined;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "columnTemplates", {
- get: function () {
- return this._columnTemplates;
- },
- set: function (val) {
- this._columnTemplates = val;
- if (val) {
- // only set this if results were brought back
- var arr = val.toArray();
- if (arr.length) {
- // translate them to normal objects
- this.columns = utils_2.translateTemplates(arr);
- }
- }
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DatatableComponent.prototype, "rowDetailTemplateChild", {
- get: function () {
- return this._rowDetailTemplateChild;
- },
- set: function (val) {
- this._rowDetailTemplateChild = val;
- if (val)
- this.rowDetailTemplate = val.rowDetailTemplate;
- },
- enumerable: true,
- configurable: true
- });
- DatatableComponent.prototype.ngOnInit = function () {
- // need to call this immediatly to size
- // if the table is hidden the visibility
- // listener will invoke this itself upon show
- this.recalculate();
- };
- DatatableComponent.prototype.ngAfterViewInit = function () {
- this.recalculate();
- };
- /**
- * Toggle the expansion of the row
- *
- * @param rowIndex
- */
- DatatableComponent.prototype.toggleExpandRow = function (row) {
- // Should we write a guard here??
- this.bodyComponent.toggleRowExpansion(row);
- };
- /**
- * API method to expand all the rows.
- */
- DatatableComponent.prototype.expandAllRows = function () {
- this.bodyComponent.toggleAllRows(true);
- };
- /**
- * API method to collapse all the rows.
- */
- DatatableComponent.prototype.collapseAllRows = function () {
- this.bodyComponent.toggleAllRows(false);
- };
- DatatableComponent.prototype.recalculate = function () {
- this.recalculateDims();
- this.recalculateColumns();
- };
- DatatableComponent.prototype.recalculateColumns = function (columns, forceIdx) {
- if (columns === void 0) { columns = this.columns; }
- if (!columns)
- return;
- var width = this.innerWidth;
- if (this.scrollbarV) {
- width = width - utils_2.scrollbarWidth;
- }
- if (this.columnMode === types_1.ColumnMode.force) {
- utils_1.forceFillColumnWidths(columns, width, forceIdx);
- }
- else if (this.columnMode === types_1.ColumnMode.flex) {
- utils_1.adjustColumnWidths(columns, width);
- }
- return columns;
- };
- DatatableComponent.prototype.recalculateDims = function () {
- var _a = this.element.getBoundingClientRect(), height = _a.height, width = _a.width;
- this.innerWidth = Math.floor(width);
- if (this.scrollbarV) {
- if (this.headerHeight)
- height = height - this.headerHeight;
- if (this.footerHeight)
- height = height - this.footerHeight;
- this.bodyHeight = height;
- }
- this.pageSize = this.calcPageSize();
- this.rowCount = this.calcRowCount();
- };
- DatatableComponent.prototype.onBodyPage = function (_a) {
- var offset = _a.offset;
- this.offset = offset;
- this.page.emit({
- count: this.count,
- pageSize: this.pageSize,
- limit: this.limit,
- offset: this.offset
- });
- };
- DatatableComponent.prototype.onBodyScroll = function (event) {
- this.offsetX = event.offsetX;
- this.scroll.emit(event);
- };
- DatatableComponent.prototype.onFooterPage = function (event) {
- this.offset = event.page - 1;
- this.bodyComponent.updateOffsetY(this.offset);
- this.page.emit({
- count: this.count,
- pageSize: this.pageSize,
- limit: this.limit,
- offset: this.offset
- });
- };
- DatatableComponent.prototype.calcPageSize = function (val) {
- if (val === void 0) { val = this.rows; }
- // Keep the page size constant even if the row has been expanded.
- // This is because an expanded row is still considered to be a child of
- // the original row. Hence calculation would use rowHeight only.
- if (this.scrollbarV)
- return Math.ceil(this.bodyHeight / this.rowHeight);
- // if limit is passed, we are paging
- if (this.limit !== undefined)
- return this.limit;
- // otherwise use row length
- if (val)
- return val.length;
- // other empty :(
- return 0;
- };
- DatatableComponent.prototype.calcRowCount = function (val) {
- if (val === void 0) { val = this.rows; }
- if (!this.externalPaging) {
- if (!val)
- return 0;
- return val.length;
- }
- return this.count;
- };
- DatatableComponent.prototype.onColumnResize = function (_a) {
- var column = _a.column, newValue = _a.newValue;
- var idx;
- var cols = this.columns.map(function (c, i) {
- c = Object.assign({}, c);
- if (c.$$id === column.$$id) {
- idx = i;
- c.width = newValue;
- // set this so we can force the column
- // width distribution to be to this value
- c.$$oldWidth = newValue;
- }
- return c;
- });
- this.recalculateColumns(cols, idx);
- this.columns = cols;
- this.resize.emit({
- column: column,
- newValue: newValue
- });
- };
- DatatableComponent.prototype.onColumnReorder = function (_a) {
- var column = _a.column, newValue = _a.newValue, prevValue = _a.prevValue;
- var cols = this.columns.map(function (c) {
- return Object.assign({}, c);
- });
- cols.splice(prevValue, 1);
- cols.splice(newValue, 0, column);
- this.columns = cols;
- this.reorder.emit({
- column: column,
- newValue: newValue,
- prevValue: prevValue
- });
- };
- DatatableComponent.prototype.onColumnSort = function (event) {
- var sorts = event.sorts;
- // this could be optimized better since it will resort
- // the rows again on the 'push' detection...
- if (this.externalSorting === false) {
- this.rows = utils_1.sortRows(this.rows, this.columns, sorts);
- }
- this.sorts = sorts;
- this.bodyComponent.updateOffsetY(0);
- this.sort.emit(event);
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DatatableComponent.prototype, "rows", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DatatableComponent.prototype, "columns", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array)
- ], DatatableComponent.prototype, "selected", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DatatableComponent.prototype, "scrollbarV", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DatatableComponent.prototype, "scrollbarH", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "rowHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "detailRowHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "columnMode", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "headerHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "footerHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DatatableComponent.prototype, "externalPaging", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DatatableComponent.prototype, "externalSorting", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "limit", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "count", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "offset", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DatatableComponent.prototype, "loadingIndicator", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "selectionType", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DatatableComponent.prototype, "reorderable", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DatatableComponent.prototype, "sortType", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array)
- ], DatatableComponent.prototype, "sorts", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', core_1.TemplateRef)
- ], DatatableComponent.prototype, "rowDetailTemplate", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "cssClasses", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "messages", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "rowIdentity", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "selectCheck", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DatatableComponent.prototype, "trackByProp", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "scroll", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "activate", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "select", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "sort", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "page", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "detailToggle", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "reorder", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DatatableComponent.prototype, "resize", void 0);
- __decorate([
- core_1.HostBinding('class.fixed-header'),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "isFixedHeader", null);
- __decorate([
- core_1.HostBinding('class.fixed-row'),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "isFixedRow", null);
- __decorate([
- core_1.HostBinding('class.scroll-vertical'),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "isVertScroll", null);
- __decorate([
- core_1.HostBinding('class.scroll-horz'),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "isHorScroll", null);
- __decorate([
- core_1.HostBinding('class.selectable'),
- __metadata('design:type', Object)
- ], DatatableComponent.prototype, "isSelectable", null);
- __decorate([
- core_1.ContentChildren(column_directive_1.DataTableColumnDirective),
- __metadata('design:type', core_1.QueryList),
- __metadata('design:paramtypes', [core_1.QueryList])
- ], DatatableComponent.prototype, "columnTemplates", null);
- __decorate([
- core_1.ContentChild(row_detail_directive_1.DatatableRowDetailDirective),
- __metadata('design:type', row_detail_directive_1.DatatableRowDetailDirective),
- __metadata('design:paramtypes', [row_detail_directive_1.DatatableRowDetailDirective])
- ], DatatableComponent.prototype, "rowDetailTemplateChild", null);
- __decorate([
- core_1.ViewChild(body_1.DataTableBodyComponent),
- __metadata('design:type', body_1.DataTableBodyComponent)
- ], DatatableComponent.prototype, "bodyComponent", void 0);
- __decorate([
- core_1.HostListener('window:resize'),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', []),
- __metadata('design:returntype', void 0)
- ], DatatableComponent.prototype, "recalculate", null);
- DatatableComponent = __decorate([
- core_1.Component({
- selector: 'datatable',
- template: "\n \n \n \n \n \n \n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.Renderer, core_1.ElementRef])
- ], DatatableComponent);
- return DatatableComponent;
-}());
-exports.DatatableComponent = DatatableComponent;
-
-
-/***/ },
-
-/***/ "./src/components/datatable.scss":
-/***/ function(module, exports) {
-
-// removed by extract-text-webpack-plugin
-
-/***/ },
-
-/***/ "./src/components/footer/footer.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var DataTableFooterComponent = (function () {
- function DataTableFooterComponent(element, renderer) {
- this.page = new core_1.EventEmitter();
- renderer.setElementClass(element.nativeElement, 'datatable-footer', true);
- }
- Object.defineProperty(DataTableFooterComponent.prototype, "isVisible", {
- get: function () {
- return (this.rowCount / this.pageSize) > 1;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableFooterComponent.prototype, "curPage", {
- get: function () {
- return this.offset + 1;
- },
- enumerable: true,
- configurable: true
- });
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableFooterComponent.prototype, "footerHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableFooterComponent.prototype, "rowCount", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableFooterComponent.prototype, "pageSize", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableFooterComponent.prototype, "offset", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableFooterComponent.prototype, "pagerLeftArrowIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableFooterComponent.prototype, "pagerRightArrowIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableFooterComponent.prototype, "pagerPreviousIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableFooterComponent.prototype, "pagerNextIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableFooterComponent.prototype, "totalMessage", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableFooterComponent.prototype, "page", void 0);
- DataTableFooterComponent = __decorate([
- core_1.Component({
- selector: 'datatable-footer',
- template: "\n \n
{{rowCount.toLocaleString()}} {{totalMessage}}
\n
\n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTableFooterComponent);
- return DataTableFooterComponent;
-}());
-exports.DataTableFooterComponent = DataTableFooterComponent;
-
-
-/***/ },
-
-/***/ "./src/components/footer/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/components/footer/footer.component.ts"));
-__export(__webpack_require__("./src/components/footer/pager.component.ts"));
-
-
-/***/ },
-
-/***/ "./src/components/footer/pager.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var DataTablePagerComponent = (function () {
- function DataTablePagerComponent(element, renderer) {
- this.change = new core_1.EventEmitter();
- this._count = 0;
- this._page = 1;
- this._size = 0;
- renderer.setElementClass(element.nativeElement, 'datatable-pager', true);
- }
- Object.defineProperty(DataTablePagerComponent.prototype, "size", {
- get: function () {
- return this._size;
- },
- set: function (val) {
- this._size = val;
- this.pages = this.calcPages();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTablePagerComponent.prototype, "count", {
- get: function () {
- return this._count;
- },
- set: function (val) {
- this._count = val;
- this.pages = this.calcPages();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTablePagerComponent.prototype, "page", {
- get: function () {
- return this._page;
- },
- set: function (val) {
- this._page = val;
- this.pages = this.calcPages();
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTablePagerComponent.prototype, "totalPages", {
- get: function () {
- var count = this.size < 1 ? 1 : Math.ceil(this.count / this.size);
- return Math.max(count || 0, 1);
- },
- enumerable: true,
- configurable: true
- });
- DataTablePagerComponent.prototype.canPrevious = function () {
- return this.page > 1;
- };
- DataTablePagerComponent.prototype.canNext = function () {
- return this.page < this.totalPages;
- };
- DataTablePagerComponent.prototype.prevPage = function () {
- this.selectPage(this.page - 1);
- };
- DataTablePagerComponent.prototype.nextPage = function () {
- this.selectPage(this.page + 1);
- };
- DataTablePagerComponent.prototype.selectPage = function (page) {
- if (page > 0 && page <= this.totalPages && page !== this.page) {
- this.page = page;
- this.change.emit({
- page: page
- });
- }
- };
- DataTablePagerComponent.prototype.calcPages = function (page) {
- var pages = [];
- var startPage = 1;
- var endPage = this.totalPages;
- var maxSize = 5;
- var isMaxSized = maxSize < this.totalPages;
- page = page || this.page;
- if (isMaxSized) {
- startPage = ((Math.ceil(page / maxSize) - 1) * maxSize) + 1;
- endPage = Math.min(startPage + maxSize - 1, this.totalPages);
- }
- for (var num = startPage; num <= endPage; num++) {
- pages.push({
- number: num,
- text: num
- });
- }
- return pages;
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTablePagerComponent.prototype, "pagerLeftArrowIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTablePagerComponent.prototype, "pagerRightArrowIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTablePagerComponent.prototype, "pagerPreviousIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTablePagerComponent.prototype, "pagerNextIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTablePagerComponent.prototype, "size", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTablePagerComponent.prototype, "count", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number),
- __metadata('design:paramtypes', [Number])
- ], DataTablePagerComponent.prototype, "page", null);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTablePagerComponent.prototype, "change", void 0);
- DataTablePagerComponent = __decorate([
- core_1.Component({
- selector: 'datatable-pager',
- template: "\n \n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTablePagerComponent);
- return DataTablePagerComponent;
-}());
-exports.DataTablePagerComponent = DataTablePagerComponent;
-
-
-/***/ },
-
-/***/ "./src/components/header/header-cell.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var types_1 = __webpack_require__("./src/types/index.ts");
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var DataTableHeaderCellComponent = (function () {
- function DataTableHeaderCellComponent() {
- this.sort = new core_1.EventEmitter();
- }
- Object.defineProperty(DataTableHeaderCellComponent.prototype, "sorts", {
- get: function () {
- return this._sorts;
- },
- set: function (val) {
- this._sorts = val;
- this.sortDir = this.calcSortDir(val);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderCellComponent.prototype, "columnCssClasses", {
- get: function () {
- var cls = 'datatable-header-cell';
- if (this.column.sortable)
- cls += ' sortable';
- if (this.column.resizeable)
- cls += ' resizeable';
- var sortDir = this.sortDir;
- if (sortDir) {
- cls += " sort-active sort-" + sortDir;
- }
- return cls;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderCellComponent.prototype, "name", {
- get: function () {
- return this.column.name || this.column.prop;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderCellComponent.prototype, "minWidth", {
- get: function () {
- return this.column.minWidth;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderCellComponent.prototype, "maxWidth", {
- get: function () {
- return this.column.maxWidth;
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderCellComponent.prototype, "width", {
- get: function () {
- return this.column.width;
- },
- enumerable: true,
- configurable: true
- });
- DataTableHeaderCellComponent.prototype.sortClasses = function (dir) {
- var result = {};
- if (dir === types_1.SortDirection.asc) {
- result[("sort-asc " + this.sortAscendingIcon)] = true;
- }
- else if (dir === types_1.SortDirection.desc) {
- result[("sort-desc " + this.sortDescendingIcon)] = true;
- }
- return result;
- };
- DataTableHeaderCellComponent.prototype.calcSortDir = function (sorts) {
- var _this = this;
- if (sorts && this.column) {
- var sort = sorts.find(function (s) {
- return s.prop === _this.column.prop;
- });
- if (sort)
- return sort.dir;
- }
- };
- DataTableHeaderCellComponent.prototype.onSort = function () {
- if (!this.column.sortable)
- return;
- var newValue = utils_1.nextSortDir(this.sortType, this.sortDir);
- this.sort.emit({
- column: this.column,
- prevValue: this.sortDir,
- newValue: newValue
- });
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableHeaderCellComponent.prototype, "sortType", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableHeaderCellComponent.prototype, "column", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableHeaderCellComponent.prototype, "sortAscendingIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', String)
- ], DataTableHeaderCellComponent.prototype, "sortDescendingIcon", void 0);
- __decorate([
- core_1.HostBinding('style.height.px'),
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableHeaderCellComponent.prototype, "headerHeight", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DataTableHeaderCellComponent.prototype, "sorts", null);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableHeaderCellComponent.prototype, "sort", void 0);
- __decorate([
- core_1.HostBinding('class'),
- __metadata('design:type', Object)
- ], DataTableHeaderCellComponent.prototype, "columnCssClasses", null);
- __decorate([
- core_1.HostBinding('attr.title'),
- __metadata('design:type', String)
- ], DataTableHeaderCellComponent.prototype, "name", null);
- __decorate([
- core_1.HostBinding('style.minWidth.px'),
- __metadata('design:type', Number)
- ], DataTableHeaderCellComponent.prototype, "minWidth", null);
- __decorate([
- core_1.HostBinding('style.maxWidth.px'),
- __metadata('design:type', Number)
- ], DataTableHeaderCellComponent.prototype, "maxWidth", null);
- __decorate([
- core_1.HostBinding('style.width.px'),
- __metadata('design:type', Number)
- ], DataTableHeaderCellComponent.prototype, "width", null);
- DataTableHeaderCellComponent = __decorate([
- core_1.Component({
- selector: 'datatable-header-cell',
- template: "\n \n \n \n \n \n \n
\n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [])
- ], DataTableHeaderCellComponent);
- return DataTableHeaderCellComponent;
-}());
-exports.DataTableHeaderCellComponent = DataTableHeaderCellComponent;
-
-
-/***/ },
-
-/***/ "./src/components/header/header.component.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var types_1 = __webpack_require__("./src/types/index.ts");
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-var DataTableHeaderComponent = (function () {
- function DataTableHeaderComponent(element, renderer) {
- this.sort = new core_1.EventEmitter();
- this.reorder = new core_1.EventEmitter();
- this.resize = new core_1.EventEmitter();
- renderer.setElementClass(element.nativeElement, 'datatable-header', true);
- }
- Object.defineProperty(DataTableHeaderComponent.prototype, "headerHeight", {
- get: function () {
- return this._headerHeight;
- },
- set: function (val) {
- if (val !== 'auto') {
- this._headerHeight = val + "px";
- }
- else {
- this._headerHeight = val;
- }
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderComponent.prototype, "columns", {
- get: function () {
- return this._columns;
- },
- set: function (val) {
- this._columns = val;
- var colsByPin = utils_1.columnsByPin(val);
- this.columnsByPin = utils_1.columnsByPinArr(val);
- this.columnGroupWidths = utils_1.columnGroupWidths(colsByPin, val);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DataTableHeaderComponent.prototype, "headerWidth", {
- get: function () {
- if (this.scrollbarH) {
- return this.innerWidth + 'px';
- }
- return '100%';
- },
- enumerable: true,
- configurable: true
- });
- DataTableHeaderComponent.prototype.onColumnResized = function (width, column) {
- if (width <= column.minWidth) {
- width = column.minWidth;
- }
- else if (width >= column.maxWidth) {
- width = column.maxWidth;
- }
- this.resize.emit({
- column: column,
- prevValue: column.width,
- newValue: width
- });
- };
- DataTableHeaderComponent.prototype.onColumnReordered = function (_a) {
- var prevIndex = _a.prevIndex, newIndex = _a.newIndex, model = _a.model;
- this.reorder.emit({
- column: model,
- prevValue: prevIndex,
- newValue: newIndex
- });
- };
- DataTableHeaderComponent.prototype.onSort = function (_a) {
- var column = _a.column, prevValue = _a.prevValue, newValue = _a.newValue;
- var sorts = this.calcNewSorts(column, prevValue, newValue);
- this.sort.emit({
- sorts: sorts,
- column: column,
- prevValue: prevValue,
- newValue: newValue
- });
- };
- DataTableHeaderComponent.prototype.calcNewSorts = function (column, prevValue, newValue) {
- var idx = 0;
- var sorts = this.sorts.map(function (s, i) {
- s = Object.assign({}, s);
- if (s.prop === column.prop)
- idx = i;
- return s;
- });
- if (newValue === undefined) {
- sorts.splice(idx, 1);
- }
- else if (prevValue) {
- sorts[idx].dir = newValue;
- }
- else {
- if (this.sortType === types_1.SortType.single) {
- sorts.splice(0, this.sorts.length);
- }
- sorts.push({ dir: newValue, prop: column.prop });
- }
- return sorts;
- };
- DataTableHeaderComponent.prototype.stylesByGroup = function (group) {
- var widths = this.columnGroupWidths;
- var offsetX = this.offsetX;
- var styles = {
- width: widths[group] + "px"
- };
- if (group === 'center') {
- utils_1.translateXY(styles, offsetX * -1, 0);
- }
- else if (group === 'right') {
- var totalDiff = widths.total - this.innerWidth;
- var offset = totalDiff * -1;
- utils_1.translateXY(styles, offset, 0);
- }
- return styles;
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableHeaderComponent.prototype, "sortAscendingIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DataTableHeaderComponent.prototype, "sortDescendingIcon", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DataTableHeaderComponent.prototype, "scrollbarH", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableHeaderComponent.prototype, "innerWidth", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableHeaderComponent.prototype, "offsetX", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array)
- ], DataTableHeaderComponent.prototype, "sorts", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], DataTableHeaderComponent.prototype, "sortType", void 0);
- __decorate([
- core_1.HostBinding('style.height'),
- core_1.Input(),
- __metadata('design:type', Object),
- __metadata('design:paramtypes', [Object])
- ], DataTableHeaderComponent.prototype, "headerHeight", null);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Array),
- __metadata('design:paramtypes', [Array])
- ], DataTableHeaderComponent.prototype, "columns", null);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableHeaderComponent.prototype, "sort", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableHeaderComponent.prototype, "reorder", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DataTableHeaderComponent.prototype, "resize", void 0);
- __decorate([
- core_1.HostBinding('style.width'),
- __metadata('design:type', String)
- ], DataTableHeaderComponent.prototype, "headerWidth", null);
- DataTableHeaderComponent = __decorate([
- core_1.Component({
- selector: 'datatable-header',
- template: "\n \n ",
- changeDetection: core_1.ChangeDetectionStrategy.OnPush
- }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
- ], DataTableHeaderComponent);
- return DataTableHeaderComponent;
-}());
-exports.DataTableHeaderComponent = DataTableHeaderComponent;
-
-
-/***/ },
-
-/***/ "./src/components/header/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/components/header/header.component.ts"));
-__export(__webpack_require__("./src/components/header/header-cell.component.ts"));
-
-
-/***/ },
-
-/***/ "./src/components/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/components/datatable.component.ts"));
-__export(__webpack_require__("./src/components/column.directive.ts"));
-__export(__webpack_require__("./src/components/row-detail.directive.ts"));
-__export(__webpack_require__("./src/components/header/index.ts"));
-__export(__webpack_require__("./src/components/body/index.ts"));
-__export(__webpack_require__("./src/components/footer/index.ts"));
-
-
-/***/ },
-
-/***/ "./src/components/row-detail.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var DatatableRowDetailDirective = (function () {
- function DatatableRowDetailDirective() {
- }
- Object.defineProperty(DatatableRowDetailDirective.prototype, "rowDetailTemplate", {
- get: function () {
- return this.template;
- },
- enumerable: true,
- configurable: true
- });
- __decorate([
- core_1.ContentChild(core_1.TemplateRef),
- __metadata('design:type', core_1.TemplateRef)
- ], DatatableRowDetailDirective.prototype, "template", void 0);
- DatatableRowDetailDirective = __decorate([
- core_1.Directive({
- selector: 'datatable-row-detail-template'
- }),
- __metadata('design:paramtypes', [])
- ], DatatableRowDetailDirective);
- return DatatableRowDetailDirective;
-}());
-exports.DatatableRowDetailDirective = DatatableRowDetailDirective;
-
-
-/***/ },
-
-/***/ "./src/datatable.module.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var common_1 = __webpack_require__(2);
-var components_1 = __webpack_require__("./src/components/index.ts");
-var directives_1 = __webpack_require__("./src/directives/index.ts");
-var Angular2DataTableModule = (function () {
- function Angular2DataTableModule() {
- }
- Angular2DataTableModule = __decorate([
- core_1.NgModule({
- imports: [
- common_1.CommonModule
- ],
- declarations: [
- directives_1.VisibilityDirective,
- directives_1.DraggableDirective,
- directives_1.ResizeableDirective,
- directives_1.OrderableDirective,
- directives_1.LongPressDirective,
- components_1.ScrollerComponent,
- components_1.DatatableComponent,
- components_1.DataTableColumnDirective,
- components_1.DataTableHeaderComponent,
- components_1.DataTableHeaderCellComponent,
- components_1.DataTableBodyComponent,
- components_1.DataTableFooterComponent,
- components_1.DataTablePagerComponent,
- components_1.ProgressBarComponent,
- components_1.DataTableBodyRowComponent,
- components_1.DataTableRowWrapperComponent,
- components_1.DatatableRowDetailDirective,
- components_1.DataTableBodyCellComponent,
- components_1.DataTableSelectionComponent
- ],
- exports: [
- components_1.DatatableComponent,
- components_1.DatatableRowDetailDirective,
- components_1.DataTableColumnDirective
- ]
- }),
- __metadata('design:paramtypes', [])
- ], Angular2DataTableModule);
- return Angular2DataTableModule;
-}());
-exports.Angular2DataTableModule = Angular2DataTableModule;
-
-
-/***/ },
-
-/***/ "./src/directives/draggable.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var Rx_1 = __webpack_require__(1);
-/**
- * Draggable Directive for Angular2
- *
- * Inspiration:
- * https://github.com/AngularClass/angular2-examples/blob/master/rx-draggable/directives/draggable.ts
- * http://stackoverflow.com/questions/35662530/how-to-implement-drag-and-drop-in-angular2
- *
- */
-var DraggableDirective = (function () {
- function DraggableDirective(element) {
- this.dragX = true;
- this.dragY = true;
- this.dragStart = new core_1.EventEmitter();
- this.dragging = new core_1.EventEmitter();
- this.dragEnd = new core_1.EventEmitter();
- this.isDragging = false;
- this.element = element.nativeElement;
- }
- DraggableDirective.prototype.ngOnDestroy = function () {
- if (this.subscription) {
- this.subscription.unsubscribe();
- }
- };
- DraggableDirective.prototype.onMouseup = function (event) {
- this.isDragging = false;
- this.element.classList.remove('dragging');
- if (this.subscription) {
- this.subscription.unsubscribe();
- this.dragEnd.emit({
- event: event,
- element: this.element,
- model: this.dragModel
- });
- }
- };
- DraggableDirective.prototype.onMousedown = function (event) {
- var _this = this;
- if (event.target.classList.contains('draggable')) {
- event.preventDefault();
- this.isDragging = true;
- var mouseDownPos_1 = { x: event.clientX, y: event.clientY };
- this.subscription = Rx_1.Observable.fromEvent(document, 'mousemove')
- .subscribe(function (ev) { return _this.move(ev, mouseDownPos_1); });
- this.dragStart.emit({
- event: event,
- element: this.element,
- model: this.dragModel
- });
- }
- };
- DraggableDirective.prototype.move = function (event, mouseDownPos) {
- if (!this.dragging)
- return;
- var x = event.clientX - mouseDownPos.x;
- var y = event.clientY - mouseDownPos.y;
- if (this.dragX)
- this.element.style.left = x + "px";
- if (this.dragY)
- this.element.style.top = y + "px";
- if (this.dragX || this.dragY) {
- this.element.classList.add('dragging');
- this.dragging.emit({
- event: event,
- element: this.element,
- model: this.dragModel
- });
- }
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Object)
- ], DraggableDirective.prototype, "dragModel", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DraggableDirective.prototype, "dragX", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], DraggableDirective.prototype, "dragY", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DraggableDirective.prototype, "dragStart", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DraggableDirective.prototype, "dragging", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], DraggableDirective.prototype, "dragEnd", void 0);
- __decorate([
- core_1.HostListener('document:mouseup', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DraggableDirective.prototype, "onMouseup", null);
- __decorate([
- core_1.HostListener('mousedown', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], DraggableDirective.prototype, "onMousedown", null);
- DraggableDirective = __decorate([
- core_1.Directive({ selector: '[draggable]' }),
- __metadata('design:paramtypes', [core_1.ElementRef])
- ], DraggableDirective);
- return DraggableDirective;
-}());
-exports.DraggableDirective = DraggableDirective;
-
-
-/***/ },
-
-/***/ "./src/directives/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/directives/draggable.directive.ts"));
-__export(__webpack_require__("./src/directives/long-press.directive.ts"));
-__export(__webpack_require__("./src/directives/orderable.directive.ts"));
-__export(__webpack_require__("./src/directives/resizeable.directive.ts"));
-__export(__webpack_require__("./src/directives/visibility.directive.ts"));
-
-
-/***/ },
-
-/***/ "./src/directives/long-press.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var LongPressDirective = (function () {
- function LongPressDirective() {
- this.duration = 500;
- this.longPress = new core_1.EventEmitter();
- this.longPressing = new core_1.EventEmitter();
- this.longPressEnd = new core_1.EventEmitter();
- this.mouseX = 0;
- this.mouseY = 0;
- }
- Object.defineProperty(LongPressDirective.prototype, "press", {
- get: function () { return this.pressing; },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(LongPressDirective.prototype, "isLongPress", {
- get: function () { return this.longPressing; },
- enumerable: true,
- configurable: true
- });
- LongPressDirective.prototype.onMouseDown = function (event) {
- var _this = this;
- // don't do right/middle clicks
- if (event.which !== 1)
- return;
- this.mouseX = event.clientX;
- this.mouseY = event.clientY;
- this.pressing = true;
- this.isLongPressing = false;
- this.timeout = setTimeout(function () {
- _this.isLongPressing = true;
- _this.longPress.emit(event);
- _this.loop(event);
- }, this.duration);
- this.loop(event);
- };
- LongPressDirective.prototype.onMouseMove = function (event) {
- if (this.pressing && !this.longPressing) {
- var xThres = (event.clientX - this.mouseX) > 10;
- var yThres = (event.clientY - this.mouseY) > 10;
- if (xThres || yThres) {
- this.endPress();
- }
- }
- };
- LongPressDirective.prototype.loop = function (event) {
- var _this = this;
- if (this.longPressing) {
- this.timeout = setTimeout(function () {
- _this.longPressing.emit(event);
- _this.loop(event);
- }, 50);
- }
- };
- LongPressDirective.prototype.endPress = function () {
- clearTimeout(this.timeout);
- this.isLongPressing = false;
- this.pressing = false;
- this.longPressEnd.emit(true);
- };
- LongPressDirective.prototype.onMouseUp = function () { this.endPress(); };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], LongPressDirective.prototype, "duration", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], LongPressDirective.prototype, "longPress", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], LongPressDirective.prototype, "longPressing", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], LongPressDirective.prototype, "longPressEnd", void 0);
- __decorate([
- core_1.HostBinding('class.press'),
- __metadata('design:type', Object)
- ], LongPressDirective.prototype, "press", null);
- __decorate([
- core_1.HostBinding('class.longpress'),
- __metadata('design:type', Object)
- ], LongPressDirective.prototype, "isLongPress", null);
- __decorate([
- core_1.HostListener('mousedown', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], LongPressDirective.prototype, "onMouseDown", null);
- __decorate([
- core_1.HostListener('mousemove', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], LongPressDirective.prototype, "onMouseMove", null);
- __decorate([
- core_1.HostListener('mouseup'),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', []),
- __metadata('design:returntype', void 0)
- ], LongPressDirective.prototype, "onMouseUp", null);
- LongPressDirective = __decorate([
- core_1.Directive({ selector: '[long-press]' }),
- __metadata('design:paramtypes', [])
- ], LongPressDirective);
- return LongPressDirective;
-}());
-exports.LongPressDirective = LongPressDirective;
-
-
-/***/ },
-
-/***/ "./src/directives/orderable.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var draggable_directive_1 = __webpack_require__("./src/directives/draggable.directive.ts");
-var OrderableDirective = (function () {
- function OrderableDirective(differs) {
- this.reorder = new core_1.EventEmitter();
- this.differ = differs.find({}).create(null);
- }
- OrderableDirective.prototype.ngAfterContentInit = function () {
- // HACK: Investigate Better Way
- this.updateSubscriptions();
- this.draggables.changes.subscribe(this.updateSubscriptions.bind(this));
- };
- OrderableDirective.prototype.ngOnDestroy = function () {
- this.draggables.forEach(function (d) {
- d.dragStart.unsubscribe();
- d.dragEnd.unsubscribe();
- });
- };
- OrderableDirective.prototype.updateSubscriptions = function () {
- var _this = this;
- var diffs = this.differ.diff(this.draggables.toArray());
- if (diffs) {
- var subscribe = function (_a) {
- var currentValue = _a.currentValue, previousValue = _a.previousValue;
- unsubscribe_1({ previousValue: previousValue });
- if (currentValue) {
- currentValue.dragStart.subscribe(_this.onDragStart.bind(_this));
- currentValue.dragEnd.subscribe(_this.onDragEnd.bind(_this));
- }
- };
- var unsubscribe_1 = function (_a) {
- var previousValue = _a.previousValue;
- if (previousValue) {
- previousValue.dragStart.unsubscribe();
- previousValue.dragEnd.unsubscribe();
- }
- };
- diffs.forEachAddedItem(subscribe.bind(this));
- diffs.forEachChangedItem(subscribe.bind(this));
- diffs.forEachRemovedItem(unsubscribe_1.bind(this));
- }
- };
- OrderableDirective.prototype.onDragStart = function () {
- this.positions = {};
- var i = 0;
- for (var _i = 0, _a = this.draggables.toArray(); _i < _a.length; _i++) {
- var dragger = _a[_i];
- var elm = dragger.element;
- this.positions[dragger.dragModel.prop] = {
- left: parseInt(elm.offsetLeft.toString(), 0),
- index: i++
- };
- }
- };
- OrderableDirective.prototype.onDragEnd = function (_a) {
- var element = _a.element, model = _a.model;
- var newPos = parseInt(element.offsetLeft.toString(), 0);
- var prevPos = this.positions[model.prop];
- var i = 0;
- for (var prop in this.positions) {
- var pos = this.positions[prop];
- var movedLeft = newPos < pos.left && prevPos.left > pos.left;
- var movedRight = newPos > pos.left && prevPos.left < pos.left;
- if (movedLeft || movedRight) {
- this.reorder.emit({
- prevIndex: prevPos.index,
- newIndex: i,
- model: model
- });
- }
- i++;
- }
- element.style.left = 'auto';
- };
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], OrderableDirective.prototype, "reorder", void 0);
- __decorate([
- core_1.ContentChildren(draggable_directive_1.DraggableDirective, { descendants: true }),
- __metadata('design:type', core_1.QueryList)
- ], OrderableDirective.prototype, "draggables", void 0);
- OrderableDirective = __decorate([
- core_1.Directive({ selector: '[orderable]' }),
- __metadata('design:paramtypes', [core_1.KeyValueDiffers])
- ], OrderableDirective);
- return OrderableDirective;
-}());
-exports.OrderableDirective = OrderableDirective;
-
-
-/***/ },
-
-/***/ "./src/directives/resizeable.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var Rx_1 = __webpack_require__(1);
-var ResizeableDirective = (function () {
- function ResizeableDirective(element) {
- this.resizeEnabled = true;
- this.resize = new core_1.EventEmitter();
- this.resizing = false;
- this.element = element.nativeElement;
- if (this.resizeEnabled) {
- var node = document.createElement('span');
- node.classList.add('resize-handle');
- this.element.appendChild(node);
- }
- }
- ResizeableDirective.prototype.ngOnDestroy = function () {
- if (this.subscription) {
- this.subscription.unsubscribe();
- }
- };
- ResizeableDirective.prototype.onMouseup = function () {
- this.resizing = false;
- if (this.subscription && !this.subscription.closed) {
- this.subscription.unsubscribe();
- this.resize.emit(this.element.clientWidth);
- }
- };
- ResizeableDirective.prototype.onMousedown = function (event) {
- var _this = this;
- var isHandle = event.target.classList.contains('resize-handle');
- var initialWidth = this.element.clientWidth;
- var mouseDownScreenX = event.screenX;
- if (isHandle) {
- event.stopPropagation();
- this.resizing = true;
- this.subscription = Rx_1.Observable.fromEvent(document, 'mousemove')
- .subscribe(function (e) { return _this.move(e, initialWidth, mouseDownScreenX); });
- }
- };
- ResizeableDirective.prototype.move = function (event, initialWidth, mouseDownScreenX) {
- var movementX = event.screenX - mouseDownScreenX;
- var newWidth = initialWidth + movementX;
- var overMinWidth = !this.minWidth || newWidth >= this.minWidth;
- var underMaxWidth = !this.maxWidth || newWidth <= this.maxWidth;
- if (overMinWidth && underMaxWidth) {
- this.element.style.width = newWidth + "px";
- }
- };
- __decorate([
- core_1.Input(),
- __metadata('design:type', Boolean)
- ], ResizeableDirective.prototype, "resizeEnabled", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], ResizeableDirective.prototype, "minWidth", void 0);
- __decorate([
- core_1.Input(),
- __metadata('design:type', Number)
- ], ResizeableDirective.prototype, "maxWidth", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], ResizeableDirective.prototype, "resize", void 0);
- __decorate([
- core_1.HostListener('document:mouseup', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', []),
- __metadata('design:returntype', void 0)
- ], ResizeableDirective.prototype, "onMouseup", null);
- __decorate([
- core_1.HostListener('mousedown', ['$event']),
- __metadata('design:type', Function),
- __metadata('design:paramtypes', [Object]),
- __metadata('design:returntype', void 0)
- ], ResizeableDirective.prototype, "onMousedown", null);
- ResizeableDirective = __decorate([
- core_1.Directive({
- selector: '[resizeable]',
- host: {
- '[class.resizeable]': 'resizeEnabled'
- }
- }),
- __metadata('design:paramtypes', [core_1.ElementRef])
- ], ResizeableDirective);
- return ResizeableDirective;
-}());
-exports.ResizeableDirective = ResizeableDirective;
-
-
-/***/ },
-
-/***/ "./src/directives/visibility.directive.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-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);
-};
-var core_1 = __webpack_require__(0);
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-/**
- * Visibility Observer Directive
- *
- * Usage:
- *
- *
- *
- *
- */
-var VisibilityDirective = (function () {
- function VisibilityDirective(element, zone) {
- this.isVisible = false;
- this.visible = new core_1.EventEmitter();
- utils_1.checkVisibility(element.nativeElement, this.visbilityChange.bind(this), zone);
- }
- VisibilityDirective.prototype.visbilityChange = function () {
- var _this = this;
- // trigger zone recalc for columns
- setTimeout(function () {
- _this.isVisible = true;
- _this.visible.emit(true);
- });
- };
- __decorate([
- core_1.HostBinding('class.visible'),
- __metadata('design:type', Boolean)
- ], VisibilityDirective.prototype, "isVisible", void 0);
- __decorate([
- core_1.Output(),
- __metadata('design:type', core_1.EventEmitter)
- ], VisibilityDirective.prototype, "visible", void 0);
- VisibilityDirective = __decorate([
- core_1.Directive({ selector: '[visibility-observer]' }),
- __metadata('design:paramtypes', [core_1.ElementRef, core_1.NgZone])
- ], VisibilityDirective);
- return VisibilityDirective;
-}());
-exports.VisibilityDirective = VisibilityDirective;
-
-
-/***/ },
-
-/***/ "./src/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/datatable.module.ts"));
-__export(__webpack_require__("./src/types/index.ts"));
-__export(__webpack_require__("./src/components/index.ts"));
-
-
-/***/ },
-
-/***/ "./src/themes/material.scss":
-/***/ function(module, exports) {
-
-// removed by extract-text-webpack-plugin
-
-/***/ },
-
-/***/ "./src/types/click.type.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-(function (ClickType) {
- ClickType[ClickType["single"] = 'single'] = "single";
- ClickType[ClickType["double"] = 'double'] = "double";
-})(exports.ClickType || (exports.ClickType = {}));
-var ClickType = exports.ClickType;
-
-
-/***/ },
-
-/***/ "./src/types/column-mode.type.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-(function (ColumnMode) {
- ColumnMode[ColumnMode["standard"] = 'standard'] = "standard";
- ColumnMode[ColumnMode["flex"] = 'flex'] = "flex";
- ColumnMode[ColumnMode["force"] = 'force'] = "force";
-})(exports.ColumnMode || (exports.ColumnMode = {}));
-var ColumnMode = exports.ColumnMode;
-
-
-/***/ },
-
-/***/ "./src/types/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/types/column-mode.type.ts"));
-__export(__webpack_require__("./src/types/sort.type.ts"));
-__export(__webpack_require__("./src/types/sort-direction.type.ts"));
-__export(__webpack_require__("./src/types/selection.type.ts"));
-__export(__webpack_require__("./src/types/click.type.ts"));
-
-
-/***/ },
-
-/***/ "./src/types/selection.type.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-(function (SelectionType) {
- SelectionType[SelectionType["single"] = 'single'] = "single";
- SelectionType[SelectionType["multi"] = 'multi'] = "multi";
- SelectionType[SelectionType["multiShift"] = 'multiShift'] = "multiShift";
- SelectionType[SelectionType["cell"] = 'cell'] = "cell";
-})(exports.SelectionType || (exports.SelectionType = {}));
-var SelectionType = exports.SelectionType;
-
-
-/***/ },
-
-/***/ "./src/types/sort-direction.type.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-(function (SortDirection) {
- SortDirection[SortDirection["asc"] = 'asc'] = "asc";
- SortDirection[SortDirection["desc"] = 'desc'] = "desc";
-})(exports.SortDirection || (exports.SortDirection = {}));
-var SortDirection = exports.SortDirection;
-
-
-/***/ },
-
-/***/ "./src/types/sort.type.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-(function (SortType) {
- SortType[SortType["single"] = 'single'] = "single";
- SortType[SortType["multi"] = 'multi'] = "multi";
-})(exports.SortType || (exports.SortType = {}));
-var SortType = exports.SortType;
-
-
-/***/ },
-
-/***/ "./src/utils/camel-case.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * Converts strings from something to camel case
- * http://stackoverflow.com/questions/10425287/convert-dash-separated-string-to-camelcase
- * @param {string} str
- * @return {string} camel case string
- */
-function camelCase(str) {
- // Replace special characters with a space
- str = str.replace(/[^a-zA-Z0-9 ]/g, ' ');
- // put a space before an uppercase letter
- str = str.replace(/([a-z](?=[A-Z]))/g, '$1 ');
- // Lower case first character and some other stuff
- str = str.replace(/([^a-zA-Z0-9 ])|^[0-9]+/g, '').trim().toLowerCase();
- // uppercase characters preceded by a space or number
- str = str.replace(/([ 0-9]+)([a-zA-Z])/g, function (a, b, c) {
- return b.trim() + c.toUpperCase();
- });
- return str;
-}
-exports.camelCase = camelCase;
-/**
- * Converts strings from camel case to words
- * http://stackoverflow.com/questions/7225407/convert-camelcasetext-to-camel-case-text
- *
- * @export
- * @param {any} str
- * @returns string
- */
-function deCamelCase(str) {
- return str
- .replace(/([A-Z])/g, function (match) { return (" " + match); })
- .replace(/^./, function (match) { return match.toUpperCase(); });
-}
-exports.deCamelCase = deCamelCase;
-
-
-/***/ },
-
-/***/ "./src/utils/column-helper.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-var utils_1 = __webpack_require__("./src/utils/index.ts");
-function setColumnDefaults(columns) {
- if (!columns)
- return;
- for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {
- var column = columns_1[_i];
- if (!column.$$id) {
- column.$$id = utils_1.id();
- }
- // translate name => prop
- if (!column.prop && column.name) {
- column.prop = utils_1.camelCase(column.name);
- }
- // format props if no name passed
- if (column.prop && !column.name) {
- column.name = utils_1.deCamelCase(column.prop);
- }
- if (!column.hasOwnProperty('resizeable')) {
- column.resizeable = true;
- }
- if (!column.hasOwnProperty('sortable')) {
- column.sortable = true;
- }
- if (!column.hasOwnProperty('draggable')) {
- column.draggable = true;
- }
- if (!column.hasOwnProperty('canAutoResize')) {
- column.canAutoResize = true;
- }
- if (!column.hasOwnProperty('width')) {
- column.width = 150;
- }
- }
-}
-exports.setColumnDefaults = setColumnDefaults;
-function translateTemplates(templates) {
- var result = [];
- for (var _i = 0, templates_1 = templates; _i < templates_1.length; _i++) {
- var temp = templates_1[_i];
- var col = {};
- var props = Object.getOwnPropertyNames(temp);
- for (var _a = 0, props_1 = props; _a < props_1.length; _a++) {
- var prop = props_1[_a];
- col[prop] = temp[prop];
- }
- if (temp.headerTemplate) {
- col.headerTemplate = temp.headerTemplate;
- }
- if (temp.cellTemplate) {
- col.cellTemplate = temp.cellTemplate;
- }
- result.push(col);
- }
- return result;
-}
-exports.translateTemplates = translateTemplates;
-
-
-/***/ },
-
-/***/ "./src/utils/column.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * Returns the columns by pin.
- * @param {array} cols
- */
-function columnsByPin(cols) {
- var ret = {
- left: [],
- center: [],
- right: []
- };
- if (cols) {
- for (var _i = 0, cols_1 = cols; _i < cols_1.length; _i++) {
- var col = cols_1[_i];
- if (col.frozenLeft) {
- ret.left.push(col);
- }
- else if (col.frozenRight) {
- ret.right.push(col);
- }
- else {
- ret.center.push(col);
- }
- }
- }
- return ret;
-}
-exports.columnsByPin = columnsByPin;
-/**
- * Returns the widths of all group sets of a column
- * @param {object} groups
- * @param {array} all
- */
-function columnGroupWidths(groups, all) {
- return {
- left: columnTotalWidth(groups.left),
- center: columnTotalWidth(groups.center),
- right: columnTotalWidth(groups.right),
- total: columnTotalWidth(all)
- };
-}
-exports.columnGroupWidths = columnGroupWidths;
-/**
- * Calculates the total width of all columns and their groups
- * @param {array} columns
- * @param {string} prop width to get
- */
-function columnTotalWidth(columns, prop) {
- var totalWidth = 0;
- if (columns) {
- for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {
- var c = columns_1[_i];
- var has = prop && c[prop];
- var width = has ? c[prop] : c.width;
- totalWidth = totalWidth + parseInt(width, 0);
- }
- }
- return totalWidth;
-}
-exports.columnTotalWidth = columnTotalWidth;
-/**
- * Calculates the total width of all columns and their groups
- * @param {array} columns
- * @param {string} property width to get
- */
-function columnsTotalWidth(columns, prop) {
- var totalWidth = 0;
- for (var _i = 0, columns_2 = columns; _i < columns_2.length; _i++) {
- var column = columns_2[_i];
- var has = prop && column[prop];
- totalWidth = totalWidth + (has ? column[prop] : column.width);
- }
- return totalWidth;
-}
-exports.columnsTotalWidth = columnsTotalWidth;
-function columnsByPinArr(val) {
- var colsByPinArr = [];
- var colsByPin = columnsByPin(val);
- colsByPinArr.push({ type: 'left', columns: colsByPin['left'] });
- colsByPinArr.push({ type: 'center', columns: colsByPin['center'] });
- colsByPinArr.push({ type: 'right', columns: colsByPin['right'] });
- return colsByPinArr;
-}
-exports.columnsByPinArr = columnsByPinArr;
-
-
-/***/ },
-
-/***/ "./src/utils/debounce.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * Debounce a function
- * @param {any} func function to executoe
- * @param {number} wait wait duration
- * @param {boolean} immediate wait or immediate executue
- */
-function debounce(func, wait, immediate) {
- var timeout;
- var args;
- var context;
- var timestamp;
- var result;
- return function () {
- context = this;
- args = arguments;
- timestamp = new Date();
- function later() {
- var last = +new Date() - timestamp;
- if (last < wait) {
- timeout = setTimeout(later, wait - last);
- }
- else {
- timeout = null;
- if (!immediate) {
- result = func.apply(context, args);
- }
- }
- }
- var callNow = immediate && !timeout;
- if (!timeout) {
- timeout = setTimeout(later, wait);
- }
- if (callNow) {
- result = func.apply(context, args);
- }
- return result;
- };
-}
-exports.debounce = debounce;
-/**
- * Debounce decorator
- *
- * class MyClass {
- * debounceable(10)
- * myFn() { ... }
- * }
- */
-function debounceable(duration, immediate) {
- return function innerDecorator(target, key, descriptor) {
- return {
- configurable: true,
- enumerable: descriptor.enumerable,
- get: function getter() {
- Object.defineProperty(this, key, {
- configurable: true,
- enumerable: descriptor.enumerable,
- value: debounce(descriptor.value, duration, immediate)
- });
- return this[key];
- }
- };
- };
-}
-exports.debounceable = debounceable;
-
-
-/***/ },
-
-/***/ "./src/utils/deep-getter.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * Returns a deep object given a string. zoo['animal.type']
- * @param {object} obj
- * @param {string} path
- */
-function deepValueGetter(obj, path) {
- if (!obj || !path)
- return obj;
- var current = obj;
- var split = path.split('.');
- if (split.length) {
- for (var i = 0, len = split.length; i < len; i++) {
- current = current[split[i]];
- // if found undefined, return empty string
- if (current === undefined || current === null)
- return '';
- }
- }
- return current;
-}
-exports.deepValueGetter = deepValueGetter;
-
-
-/***/ },
-
-/***/ "./src/utils/id.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * Creates a unique object id.
- * http://stackoverflow.com/questions/6248666/how-to-generate-short-uid-like-ax4j9z-in-js
- */
-function id() {
- return ('0000' + (Math.random() * Math.pow(36, 4) << 0).toString(36)).slice(-4);
-}
-exports.id = id;
-
-
-/***/ },
-
-/***/ "./src/utils/index.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-function __export(m) {
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-__export(__webpack_require__("./src/utils/id.ts"));
-__export(__webpack_require__("./src/utils/column.ts"));
-__export(__webpack_require__("./src/utils/deep-getter.ts"));
-__export(__webpack_require__("./src/utils/camel-case.ts"));
-__export(__webpack_require__("./src/utils/keys.ts"));
-__export(__webpack_require__("./src/utils/math.ts"));
-__export(__webpack_require__("./src/utils/prefixes.ts"));
-__export(__webpack_require__("./src/utils/scrollbar-width.ts"));
-__export(__webpack_require__("./src/utils/selection.ts"));
-__export(__webpack_require__("./src/utils/translate.ts"));
-__export(__webpack_require__("./src/utils/visibility-observer.ts"));
-__export(__webpack_require__("./src/utils/debounce.ts"));
-__export(__webpack_require__("./src/utils/sort.ts"));
-__export(__webpack_require__("./src/utils/row-height-cache.ts"));
-__export(__webpack_require__("./src/utils/column-helper.ts"));
-
-
-/***/ },
-
-/***/ "./src/utils/keys.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-(function (Keys) {
- Keys[Keys["up"] = 38] = "up";
- Keys[Keys["down"] = 40] = "down";
- Keys[Keys["return"] = 13] = "return";
- Keys[Keys["escape"] = 27] = "escape";
- Keys[Keys["left"] = 37] = "left";
- Keys[Keys["right"] = 39] = "right";
-})(exports.Keys || (exports.Keys = {}));
-var Keys = exports.Keys;
-
-
-/***/ },
-
-/***/ "./src/utils/math.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-var column_1 = __webpack_require__("./src/utils/column.ts");
-/**
- * Calculates the Total Flex Grow
- * @param {array}
- */
-function getTotalFlexGrow(columns) {
- var totalFlexGrow = 0;
- for (var _i = 0, columns_1 = columns; _i < columns_1.length; _i++) {
- var c = columns_1[_i];
- totalFlexGrow += c.flexGrow || 0;
- }
- return totalFlexGrow;
-}
-exports.getTotalFlexGrow = getTotalFlexGrow;
-/**
- * Adjusts the column widths.
- * Inspired by: https://github.com/facebook/fixed-data-table/blob/master/src/FixedDataTableWidthHelper.js
- * @param {array} all columns
- * @param {int} width
- */
-function adjustColumnWidths(allColumns, expectedWidth) {
- var columnsWidth = column_1.columnsTotalWidth(allColumns);
- var totalFlexGrow = getTotalFlexGrow(allColumns);
- var colsByGroup = column_1.columnsByPin(allColumns);
- if (columnsWidth !== expectedWidth) {
- scaleColumns(colsByGroup, expectedWidth, totalFlexGrow);
- }
-}
-exports.adjustColumnWidths = adjustColumnWidths;
-/**
- * Resizes columns based on the flexGrow property, while respecting manually set widths
- * @param {array} colsByGroup
- * @param {int} maxWidth
- * @param {int} totalFlexGrow
- */
-function scaleColumns(colsByGroup, maxWidth, totalFlexGrow) {
- // calculate total width and flexgrow points for coulumns that can be resized
- for (var attr in colsByGroup) {
- for (var _i = 0, _a = colsByGroup[attr]; _i < _a.length; _i++) {
- var column = _a[_i];
- if (!column.canAutoResize) {
- maxWidth -= column.width;
- totalFlexGrow -= column.flexGrow;
- }
- else {
- column.width = 0;
- }
- }
- }
- var hasMinWidth = {};
- var remainingWidth = maxWidth;
- // resize columns until no width is left to be distributed
- do {
- var widthPerFlexPoint = remainingWidth / totalFlexGrow;
- remainingWidth = 0;
- for (var attr in colsByGroup) {
- for (var _b = 0, _c = colsByGroup[attr]; _b < _c.length; _b++) {
- var column = _c[_b];
- // if the column can be resize and it hasn't reached its minimum width yet
- if (column.canAutoResize && !hasMinWidth[column.prop]) {
- var newWidth = column.width + column.flexGrow * widthPerFlexPoint;
- if (column.minWidth !== undefined && newWidth < column.minWidth) {
- remainingWidth += newWidth - column.minWidth;
- column.width = column.minWidth;
- hasMinWidth[column.prop] = true;
- }
- else {
- column.width = newWidth;
- }
- }
- }
- }
- } while (remainingWidth !== 0);
-}
-/**
- * Forces the width of the columns to
- * distribute equally but overflowing when nesc.
- *
- * Rules:
- *
- * - If combined withs are less than the total width of the grid,
- * proporation the widths given the min / max / noraml widths to fill the width.
- *
- * - If the combined widths, exceed the total width of the grid,
- * use the standard widths.
- *
- * - If a column is resized, it should always use that width
- *
- * - The proporational widths should never fall below min size if specified.
- *
- * - If the grid starts off small but then becomes greater than the size ( + / - )
- * the width should use the orginial width; not the newly proporatied widths.
- *
- * @param {array} allColumns
- * @param {int} expectedWidth
- */
-function forceFillColumnWidths(allColumns, expectedWidth, startIdx, defaultColWidth) {
- if (defaultColWidth === void 0) { defaultColWidth = 300; }
- var columnsToResize = startIdx > -1 ?
- allColumns.slice(startIdx, allColumns.length).filter(function (c) { return c.canAutoResize !== false; }) :
- allColumns.filter(function (c) { return c.canAutoResize !== false; });
- for (var _i = 0, columnsToResize_1 = columnsToResize; _i < columnsToResize_1.length; _i++) {
- var column = columnsToResize_1[_i];
- if (!column.$$oldWidth) {
- column.$$oldWidth = column.width;
- }
- // Initialize the starting width to original
- // width whenever there is a resize/initialize event.
- column.width = column.$$oldWidth;
- }
- var additionWidthPerColumn = 0;
- var exceedsWindow = false;
- var contentWidth = getContentWidth(allColumns, defaultColWidth);
- var remainingWidth = expectedWidth - contentWidth;
- var columnsProcessed = [];
- // This loop takes care of the
- do {
- additionWidthPerColumn = remainingWidth / columnsToResize.length;
- exceedsWindow = contentWidth >= expectedWidth;
- for (var _a = 0, columnsToResize_2 = columnsToResize; _a < columnsToResize_2.length; _a++) {
- var column = columnsToResize_2[_a];
- if (exceedsWindow) {
- column.width = column.$$oldWidth || column.width || defaultColWidth;
- }
- else {
- var newSize = (column.width || defaultColWidth) + additionWidthPerColumn;
- if (column.minWidth && newSize < column.minWidth) {
- column.width = column.minWidth;
- columnsProcessed.push(column);
- }
- else if (column.maxWidth && newSize > column.maxWidth) {
- column.width = column.maxWidth;
- columnsProcessed.push(column);
- }
- else {
- column.width = newSize;
- }
- }
- }
- contentWidth = getContentWidth(allColumns);
- remainingWidth = expectedWidth - contentWidth;
- removeProcessedColumns(columnsToResize, columnsProcessed);
- } while (remainingWidth > 0 && columnsToResize.length !== 0);
-}
-exports.forceFillColumnWidths = forceFillColumnWidths;
-/**
- * Remove the processed columns from the current active columns.
- *
- * @param columnsToResize Array containing the columns that need to be resized.
- * @param columnsProcessed Array containing the columns that have already been processed.
- */
-function removeProcessedColumns(columnsToResize, columnsProcessed) {
- for (var _i = 0, columnsProcessed_1 = columnsProcessed; _i < columnsProcessed_1.length; _i++) {
- var column = columnsProcessed_1[_i];
- var index = columnsToResize.indexOf(column);
- columnsToResize.splice(index, 1);
- }
-}
-/**
- * Gets the width of the columns
- *
- * @param {array} allColumns
- * @param {number} [defaultColWidth=300]
- * @returns {number}
- */
-function getContentWidth(allColumns, defaultColWidth) {
- if (defaultColWidth === void 0) { defaultColWidth = 300; }
- var contentWidth = 0;
- for (var _i = 0, allColumns_1 = allColumns; _i < allColumns_1.length; _i++) {
- var column = allColumns_1[_i];
- contentWidth += (column.width || defaultColWidth);
- }
- return contentWidth;
-}
-
-
-/***/ },
-
-/***/ "./src/utils/prefixes.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-var camel_case_1 = __webpack_require__("./src/utils/camel-case.ts");
-var cache = {};
-var testStyle = document.createElement('div').style;
-// Get Prefix
-// http://davidwalsh.name/vendor-prefix
-var prefix = (function () {
- var styles = window.getComputedStyle(document.documentElement, '');
- var pre = (Array.prototype.slice.call(styles).join('').match(/-(moz|webkit|ms)-/))[1];
- var dom = ('WebKit|Moz|MS|O').match(new RegExp('(' + pre + ')', 'i'))[1];
- return {
- dom: dom,
- lowercase: pre,
- css: "-" + pre + "-",
- js: pre[0].toUpperCase() + pre.substr(1)
- };
-})();
-function getVendorPrefixedName(property) {
- var name = camel_case_1.camelCase(property);
- if (!cache[name]) {
- if (testStyle[prefix.css + property] !== undefined) {
- cache[name] = prefix.css + property;
- }
- else if (testStyle[property] !== undefined) {
- cache[name] = property;
- }
- }
- return cache[name];
-}
-exports.getVendorPrefixedName = getVendorPrefixedName;
-
-
-/***/ },
-
-/***/ "./src/utils/row-height-cache.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * This object contains the cache of the various row heights that are present inside
- * the data table. Its based on Fenwick tree data structure that helps with
- * querying sums that have time complexity of log n.
- *
- * Fenwick Tree Credits: http://petr-mitrichev.blogspot.com/2013/05/fenwick-tree-range-updates.html
- * https://github.com/mikolalysenko/fenwick-tree
- *
- */
-var RowHeightCache = (function () {
- function RowHeightCache() {
- /**
- * Tree Array stores the cumulative information of the row heights to perform efficient
- * range queries and updates. Currently the tree is initialized to the base row
- * height instead of the detail row height.
- */
- this.treeArray = [];
- }
- /**
- * Clear the Tree array.
- */
- RowHeightCache.prototype.clearCache = function () {
- this.treeArray = [];
- };
- /**
- * Initialize the Fenwick tree with row Heights.
- *
- * @param rows The array of rows which contain the expanded status.
- * @param rowHeight The row height.
- * @param detailRowHeight The detail row height.
- */
- RowHeightCache.prototype.initCache = function (rows, rowHeight, detailRowHeight) {
- if (isNaN(rowHeight)) {
- throw new Error("Row Height cache initialization failed. Please ensure that 'rowHeight' is a\n valid number value: (" + rowHeight + ") when 'scrollbarV' is enabled.");
- }
- // Add this additional guard in case detailRowHeight is set to 'auto' as it wont work.
- if (isNaN(detailRowHeight)) {
- throw new Error("Row Height cache initialization failed. Please ensure that 'detailRowHeight' is a\n valid number value: (" + detailRowHeight + ") when 'scrollbarV' is enabled.");
- }
- var n = rows.length;
- this.treeArray = new Array(n);
- for (var i = 0; i < n; ++i) {
- this.treeArray[i] = 0;
- }
- for (var i = 0; i < n; ++i) {
- var currentRowHeight = rowHeight;
- // Add the detail row height to the already expanded rows.
- // This is useful for the table that goes through a filter or sort.
- if (rows[i] && rows[i].$$expanded === 1) {
- currentRowHeight += detailRowHeight;
- }
- this.update(i, currentRowHeight);
- }
- };
- /**
- * Given the ScrollY position i.e. sum, provide the rowIndex
- * that is present in the current view port. Below handles edge cases.
- *
- * @param scrollY - The scrollY position.
- * @returns {number} - Index representing the first row visible in the viewport
- */
- RowHeightCache.prototype.getRowIndex = function (scrollY) {
- if (scrollY === 0)
- return 0;
- return this.calcRowIndex(scrollY);
- };
- /**
- * When a row is expanded or rowHeight is changed, update the height. This can
- * be utilized in future when Angular Data table supports dynamic row heights.
- *
- *
- * @param atRowIndex Update the data at this index row in the grid.
- * @param byRowHeight Update by the rowHeight provided.
- */
- RowHeightCache.prototype.update = function (atRowIndex, byRowHeight) {
- if (!this.treeArray.length) {
- throw new Error("Update at index " + atRowIndex + " with value " + byRowHeight + " failed:\n Row Height cache not initialized.");
- }
- var n = this.treeArray.length;
- atRowIndex |= 0;
- while (atRowIndex < n) {
- this.treeArray[atRowIndex] += byRowHeight;
- atRowIndex |= (atRowIndex + 1);
- }
- };
- /**
- * Range Sum query from 1 to the rowIndex
- *
- * @param atIndex The row index until which the total height needs to be obtained.
- * @returns {number} The total height from row 1 to the rowIndex.
- */
- RowHeightCache.prototype.query = function (atIndex) {
- if (!this.treeArray.length) {
- throw new Error("query at index " + atIndex + " failed: Fenwick tree array not initialized.");
- }
- var sum = 0;
- atIndex |= 0;
- while (atIndex >= 0) {
- sum += this.treeArray[atIndex];
- atIndex = (atIndex & (atIndex + 1)) - 1;
- }
- return sum;
- };
- /**
- * Find the total height between 2 row indexes
- * @param atIndexA The row index from
- * @param atIndexB The row index to
- * @returns {number} total pixel height between 2 row indexes.
- */
- RowHeightCache.prototype.queryBetween = function (atIndexA, atIndexB) {
- return this.query(atIndexB) - this.query(atIndexA - 1);
- };
- /**
- * Given the ScrollY position i.e. sum, provide the rowIndex
- * that is present in the current view port.
- *
- * @param sum - The scrollY position.
- * @returns {number} - Index representing the first row visible in the viewport
- */
- RowHeightCache.prototype.calcRowIndex = function (sum) {
- if (!this.treeArray.length)
- return 0;
- var pos = -1;
- var dataLength = this.treeArray.length;
- // Get the highest bit for the block size.
- var highestBit = Math.pow(2, dataLength.toString(2).length - 1);
- for (var blockSize = highestBit; blockSize !== 0; blockSize >>= 1) {
- var nextPos = pos + blockSize;
- if (nextPos < dataLength && sum >= this.treeArray[nextPos]) {
- sum -= this.treeArray[nextPos];
- pos = nextPos;
- }
- }
- return pos + 1;
- };
- return RowHeightCache;
-}());
-exports.RowHeightCache = RowHeightCache;
-
-
-/***/ },
-
-/***/ "./src/utils/scrollbar-width.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-/**
- * Gets the width of the scrollbar. Nesc for windows
- * http://stackoverflow.com/a/13382873/888165
- * @return {int} width
- */
-function getScrollBarWidth() {
- var outer = document.createElement('div');
- outer.style.visibility = 'hidden';
- outer.style.width = '100px';
- outer.style.msOverflowStyle = 'scrollbar';
- document.body.appendChild(outer);
- var widthNoScroll = outer.offsetWidth;
- outer.style.overflow = 'scroll';
- var inner = document.createElement('div');
- inner.style.width = '100%';
- outer.appendChild(inner);
- var widthWithScroll = inner.offsetWidth;
- outer.parentNode.removeChild(outer);
- return widthNoScroll - widthWithScroll;
-}
-exports.getScrollBarWidth = getScrollBarWidth;
-;
-exports.scrollbarWidth = getScrollBarWidth();
-
-
-/***/ },
-
-/***/ "./src/utils/selection.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-function selectRows(selected, row, comparefn) {
- var selectedIndex = comparefn(row, selected);
- if (selectedIndex > -1) {
- selected.splice(selectedIndex, 1);
- }
- else {
- selected.push(row);
- }
- return selected;
-}
-exports.selectRows = selectRows;
-function selectRowsBetween(selected, rows, index, prevIndex, comparefn) {
- var reverse = index < prevIndex;
- for (var i = 0, len = rows.length; i < len; i++) {
- var row = rows[i];
- var greater = i >= prevIndex && i <= index;
- var lesser = i <= prevIndex && i >= index;
- var range = { start: 0, end: 0 };
- if (reverse) {
- range = {
- start: index,
- end: (prevIndex - index)
- };
- }
- else {
- range = {
- start: prevIndex,
- end: index + 1
- };
- }
- if ((reverse && lesser) || (!reverse && greater)) {
- var idx = comparefn(row, selected);
- // if reverse shift selection (unselect) and the
- // row is already selected, remove it from selected
- if (reverse && idx > -1) {
- selected.splice(idx, 1);
- continue;
- }
- // if in the positive range to be added to `selected`, and
- // not already in the selected array, add it
- if (i >= range.start && i < range.end) {
- if (idx === -1) {
- selected.push(row);
- }
- }
- }
- }
- return selected;
-}
-exports.selectRowsBetween = selectRowsBetween;
-
-
-/***/ },
-
-/***/ "./src/utils/sort.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-var types_1 = __webpack_require__("./src/types/index.ts");
-var deep_getter_1 = __webpack_require__("./src/utils/deep-getter.ts");
-/**
- * Gets the next sort direction
- * @param {SortType} sortType
- * @param {SortDirection} currentSort
- * @return {SortDirection}
- */
-function nextSortDir(sortType, current) {
- if (sortType === types_1.SortType.single) {
- if (current === types_1.SortDirection.asc) {
- return types_1.SortDirection.desc;
- }
- else {
- return types_1.SortDirection.asc;
- }
- }
- else {
- if (!current) {
- return types_1.SortDirection.asc;
- }
- else if (current === types_1.SortDirection.asc) {
- return types_1.SortDirection.desc;
- }
- else if (current === types_1.SortDirection.desc) {
- return undefined;
- }
- }
-}
-exports.nextSortDir = nextSortDir;
-;
-/**
- * Adapted from fueld-ui on 6/216
- * https://github.com/FuelInteractive/fuel-ui/tree/master/src/pipes/OrderBy
- * @param {any} a
- * @param {any} b
- * @return {number} position
- */
-function orderByComparator(a, b) {
- if (a === null || typeof a === 'undefined')
- a = 0;
- if (b === null || typeof b === 'undefined')
- b = 0;
- if ((isNaN(parseFloat(a)) || !isFinite(a)) || (isNaN(parseFloat(b)) || !isFinite(b))) {
- // Convert to string in case of a=0 or b=0
- a = String(a);
- b = String(b);
- // Isn't a number so lowercase the string to properly compare
- if (a.toLowerCase() < b.toLowerCase())
- return -1;
- if (a.toLowerCase() > b.toLowerCase())
- return 1;
- }
- else {
- // Parse strings as numbers to compare properly
- if (parseFloat(a) < parseFloat(b))
- return -1;
- if (parseFloat(a) > parseFloat(b))
- return 1;
- }
- // equal each other
- return 0;
-}
-exports.orderByComparator = orderByComparator;
-/**
- * Sorts the rows
- *
- * @export
- * @param {any[]} rows
- * @param {any[]} columns
- * @param {any[]} dirs
- * @returns
- */
-function sortRows(rows, columns, dirs) {
- if (!rows || !dirs || !columns)
- return rows;
- var cols = columns.reduce(function (obj, col) {
- if (col.comparator && typeof col.comparator === 'function') {
- obj[col.prop] = col.comparator;
- }
- return obj;
- }, {});
- return rows.slice().sort(function (a, b) {
- for (var _i = 0, dirs_1 = dirs; _i < dirs_1.length; _i++) {
- var _a = dirs_1[_i], prop = _a.prop, dir = _a.dir;
- var propA = deep_getter_1.deepValueGetter(a, prop);
- var propB = deep_getter_1.deepValueGetter(b, prop);
- var compareFn = cols[prop] || orderByComparator;
- var comparison = dir !== types_1.SortDirection.desc ?
- compareFn(propA, propB) :
- -compareFn(propA, propB);
- // Don't return 0 yet in case of needing to sort by next property
- if (comparison !== 0)
- return comparison;
- }
- // equal each other
- return 0;
- });
-}
-exports.sortRows = sortRows;
-
-
-/***/ },
-
-/***/ "./src/utils/translate.ts":
-/***/ function(module, exports, __webpack_require__) {
-
-"use strict";
-"use strict";
-var prefixes_1 = __webpack_require__("./src/utils/prefixes.ts");
-var camel_case_1 = __webpack_require__("./src/utils/camel-case.ts");
-// browser detection and prefixing tools
-var transform = prefixes_1.getVendorPrefixedName('transform');
-var backfaceVisibility = prefixes_1.getVendorPrefixedName('backfaceVisibility');
-var hasCSSTransforms = !!prefixes_1.getVendorPrefixedName('transform');
-var hasCSS3DTransforms = !!prefixes_1.getVendorPrefixedName('perspective');
-var ua = window.navigator.userAgent;
-var isSafari = (/Safari\//).test(ua) && !(/Chrome\//).test(ua);
-function translateXY(styles, x, y) {
- if (hasCSSTransforms) {
- if (!isSafari && hasCSS3DTransforms) {
- styles[transform] = "translate3d(" + x + "px, " + y + "px, 0)";
- styles[backfaceVisibility] = 'hidden';
- }
- else {
- styles[camel_case_1.camelCase(transform)] = "translate(" + x + "px, " + y + "px)";
- }
- }
- else {
- styles.top = y + "px";
- styles.left = x + "px";
- }
-}
-exports.translateXY = translateXY;
-
-
-/***/ },
-
-/***/ "./src/utils/visibility-observer.ts":
-/***/ function(module, exports) {
-
-"use strict";
-"use strict";
-function checkVisibility(element, callback, zone) {
- var timeout;
- function check() {
- // https://davidwalsh.name/offsetheight-visibility
- var offsetHeight = element.offsetHeight, offsetWidth = element.offsetWidth;
- if (offsetHeight && offsetWidth) {
- clearTimeout(timeout);
- if (callback)
- zone.run(function () { return callback(); });
- }
- else {
- clearTimeout(timeout);
- zone.runOutsideAngular(function () {
- timeout = setTimeout(function () { return check(); }, 50);
- });
- }
- }
- check();
-}
-exports.checkVisibility = checkVisibility;
-
-
-/***/ },
-
-/***/ 0:
-/***/ function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE_0__;
-
-/***/ },
-
-/***/ 1:
-/***/ function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE_1__;
-
-/***/ },
-
-/***/ 2:
-/***/ function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE_2__;
-
-/***/ },
-
-/***/ 3:
-/***/ function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE_3__;
-
-/***/ },
-
-/***/ 4:
-/***/ function(module, exports) {
-
-module.exports = __WEBPACK_EXTERNAL_MODULE_4__;
-
-/***/ }
-
-/******/ })
-});
-;
-//# sourceMappingURL=app.map
\ No newline at end of file
diff --git a/release/app.map b/release/app.map
deleted file mode 100644
index db12bc374..000000000
--- a/release/app.map
+++ /dev/null
@@ -1 +0,0 @@
-{"version":3,"sources":["webpack:///webpack:///src/components/src/components/datatable.scss","webpack:///webpack:///src/themes/src/themes/material.scss"],"names":[],"mappings":";;;;;AAAA;EACE,eAAe;EACf,iBAAgB;EAChB,yBAAwB;MAAxB,sBAAwB;UAAxB,wBAAwB;EACxB,mBAAmB;EAYnB;;KAEG;EAWH;;KAEG;EAOH;;KAEG;EAcH;;KAEG;EAiBH;;KAEG;EA6CH;;KAEG;EAgDH;;KAEG;EA2CH;;KAEG,EA+CJ;EAxQD;IAOI,yBAAyB,EAC1B;EARH;IAaI,uBAAuB,EACxB;EAdH;IAqBM,iBAAgB,EAKjB;IA1BL;MAuBQ,mBAAmB,EACpB;EAxBP;IAkCM,iBAAgB,EACjB;EAnCL;IA4CQ,oBAAoB,EAMrB;IAlDP;MA8CU,oBAAoB;MACpB,iBAAiB;MACjB,wBAAwB,EACzB;EAjDT;IA2DM,oBAAoB,EAWrB;IAtEL;MA8DQ,oBAAoB,EAOrB;MArEP;QAiEU,iBAAiB;QACjB,oBAAoB;QACpB,wBAAwB,EACzB;EApET;;IA8EI,qBAAqB;IAErB,qBAAqB;IAErB,cAAc;IAEd,+BAAoB;IAApB,8BAAoB;QAApB,wBAAoB;YAApB,oBAAoB;IAGpB,mBAAmB;IACnB,kBAAkB;IAClB,eAAe,EAChB;EA1FH;;IA8FI,oBAAoB;IACpB,sBAAsB;IACtB,mBAAmB;IAEnB,0BAA0B;IAC1B,uBAAuB;IACvB,sBAAsB;IACtB,qBAAqB;IACrB,kBAAkB,EAKnB;IA3GH;;MAyGM,cAAc,EACf;EA1GL;;IA+GI,WAAW,EACZ;EAhHH;;;IAqHI,mBAAkB,EACnB;EAtHH;IA4HI,eAAe;IACf,iBAAiB,EA2ClB;IAxKH;MAgIM,2BAAqB;UAArB,wBAAqB;cAArB,qBAAqB;MACrB,6BAA6B,EAC9B;IAlIL;MAqIM,mBAAmB;MACnB,sBAAsB,EAiCvB;MAvKL;QAyIQ,aAAa,EACd;MA1IP;QA6IQ,gBAAgB,EACjB;MA9IP;QAiJQ,kBAAkB;QAClB,uBAAuB;QACvB,sBAAsB,EACvB;MApJP;QAuJQ,sBAAsB;QACtB,mBAAmB;QACnB,SAAS;QACT,OAAO;QACP,UAAU;QACV,WAAW;QACX,eAAe;QACf,mBAAmB;QACnB,kBAAkB,EACnB;MAhKP;QAoKU,oBAAoB,EACrB;EArKT;IA8KI,mBAAmB;IACnB,YAAY;IACZ,eAAe,EAqChB;IArNH;MAmLM,sBAAsB,EACvB;IApLL;MAuLM,mBAAmB,EACpB;IAxLL;MA2LM,qBAAqB;MAErB,qBAAqB;MAErB,cAAc;MAEd,6BAA6B;MAC7B,8BAA8B;MAI9B,2BAA2B;MAC3B,uBAAuB,EACxB;IAxML;MA2MM,cAAa,EASd;MApNL;QA8MQ,qBAAqB;QAErB,qBAAqB;QAErB,cAAc,EACf;EAnNP;IA2NI,eAAe;IACf,YAAY,EA2Cb;IAvQH;MA+NM,qBAAc;MAAd,qBAAc;MAAd,cAAc;MACd,0BAAoB;UAApB,uBAAoB;cAApB,oBAAoB;MACpB,YAAY,EACb;IAlOL;MAqOM,sBAAsB;MACtB,oBAAc;UAAd,kBAAc;cAAd,cAAc,EACf;IAvOL;MA0OM,sBAAsB;MACtB,oBAAc;UAAd,kBAAc;cAAd,cAAc;MACd,kBAAkB,EA0BnB;MAtQL;;QAgPQ,WAAW;QACX,UAAU;QACV,sBAAsB;QACtB,iBAAiB,EAClB;MApPP;QAwPU,cAAc,EACf;MAzPT;QA6PY,gBAAgB;QAChB,sBAAsB,EACvB;MA/PX;QAkQY,oBAAoB,EACrB;ACnQX;EACC,iBAAgB;EAGf,6EAA6D;EAQ9D;;IAEG;EAgBH;;IAEG;EAkBH;;IAEG;EA2BH;;IAEG;EA+FH;;IAEG,EA0DH;EA5OD;IAQG,iBAAiB,EACjB;EATH;IAgBG,aAAY;IACZ,iBAAiB;IACjB,sBAAsB;IACtB,oBAAoB;IACpB,cAAc,EACf;EArBF;IAwBG,iBAAiB;IACjB,sBAAsB;IACtB,oBAAoB;IACpB,cAAc,EACf;EA5BF;;IAoCG,uBAAuB;IACvB,4BAA4B;IAC5B,4BAA4B;IAC5B,0JAAyJ,EACzJ;EAxCH;;IA2CG,yBAAyB;IACvB,uBAAuB;IACvB,4BAA4B;IAC5B,0JAAyJ,EAC3J;EA/CH;IAsDI,6CAA6B,EAuB9B;IA7EH;MAyDM,iBAAiB;MACjB,sBAAsB;MACtB,iBAAiB;MACjB,eAAe;MACf,uBAAuB,EAWxB;MAxEL;QAgEI,eAAc,EACd;MAjEJ;QAqEK,mBAAmB,EACnB;IAtEL;MA2EM,6BAA4B,EAC7B;EA5EL;IAoFG,oBAAoB;IACpB,cAAc,EACd;EAtFH;IA0FO,iBAAiB;IACjB,sBAAsB;IACtB,oBAAoB;IACpB,cAAc;IAEd,oCAAoC;IAEpC,4BAA4B,EAM7B;EAvGN;;IA2GO,uBAAuB;IACvB,wCAAgC;IAAhC,gCAAgC;IAChC,iCAAyB;YAAzB,yBAAyB;IACzB,2CAAmC;YAAnC,mCAAmC,EACpC;EA/GN;;IAmHI,uBAAuB,EACvB;EApHJ;;IAwHI,0BAA0B;IACtB,YAAY,EAChB;EA1HJ;;IA8HI,0BAA0B;IACtB,YAAY,EAChB;EAhIJ;;IAoII,0BAA0B;IACpB,YAAY,EAClB;EAtIJ;IA0II,eAAe;IACf,mBAAmB;IACnB,YAAY;IACZ,YAAY;IACZ,WAAW;IACX,UAAU;IACR,mBAAmB,EA6BtB;IA7KH;MAmJK,eAAe;MACf,mBAAmB;MACnB,iBAAiB;MACjB,YAAY;MACZ,YAAY;MACZ,+CAAuC;MACvC,uCAA+B;MAC/B,0BAAqB,EAkBtB;MA5KJ;QA6JM,mCAA2B;QAA3B,2BAA2B;QAC3B,2EAAkD;QAClD,mEAA0C;QAE1C,yCAAyC;QACzC,iDAAiC;QAAjC,iCAAiC;QAAjC,+DAAiC;QACjC,0BAAqB;QAErB,mBAAmB;QACnB,QAAQ;QACR,OAAO;QACP,UAAU;QACV,YAAY;QACZ,YAAY,EACb;EA3KL;IAoLE,0CAA0B;IAC1B,gBAAe,EAsDf;IA3OF;MAwLG,kBAAkB;MAClB,aAAY;MACZ,kBAAkB,EAClB;IA3LH;MA8LG,eAAe,EA4Cf;MA1OH;QAkMM,uBAAuB,EAWzB;QA7MJ;UAqMK,sCAAoC;UACpC,yCAAyC,EACzC;QAvML;UA0MK,2CAAsB;UACtB,kBAAkB,EAClB;MA5ML;QAgNI,aAAa;QACb,gBAAgB;QAChB,kBAAkB;QAClB,eAAe;QACf,mBAAmB;QACnB,gBAAgB;QAChB,mBAAmB;QACnB,oBAAoB;QACpB,2BAAW;QACX,sBAAsB;QACpB,uBAAuB,EAMzB;QAhOJ;UA6NK,2BAAW;UACX,2CAAsB,EACtB;MA/NL;;;;QAsOI,gBAAe;QACf,kBAAkB;QAClB,eAAc,EACd;;AAKJ;;GAEG;AACH;EACE;IACE,WAAW;IACX,iDAAwC;IAChC,yCAAgC;EAE1C;IACE,WAAW;IACX,gDAAyC;IACjC,wCAAiC;;AAE7C;EACE;IACE,WAAW;IACX,iDAAwC;IAChC,yCAAgC;EAE1C;IACE,WAAW;IACX,gDAAyC;IACjC,wCAAiC","file":"app.css","sourcesContent":[".datatable {\n display: block;\n overflow:hidden;\n justify-content: center;\n position: relative;\n\n [hidden] {\n display: none !important;\n }\n\n *, *:before, *:after {\n -moz-box-sizing: border-box;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n }\n\n /**\n * Vertical Scrolling Adjustments\n */\n &.scroll-vertical {\n .datatable-body {\n overflow-y:auto;\n .datatable-row-wrapper {\n position: absolute;\n }\n\n }\n }\n\n /**\n * Horizontal Scrolling Adjustments\n */\n &.scroll-horz {\n .datatable-body {\n overflow-x:auto;\n }\n }\n\n /**\n * Fixed Header Height Adjustments\n */\n &.fixed-header {\n .datatable-header {\n .datatable-header-inner{\n white-space: nowrap;\n .datatable-header-cell{\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n }\n }\n }\n\n /**\n * Fixed row height adjustments\n */\n &.fixed-row {\n .datatable-scroll{\n white-space: nowrap;\n \n .datatable-body-row {\n white-space: nowrap;\n\n .datatable-body-cell {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n }\n }\n }\n\n /**\n * Shared Styles\n */\n .datatable-body-row,\n .datatable-header-inner {\n display: -webkit-box;\n display: -moz-box;\n display: -ms-flexbox;\n display: -webkit-flex;\n display: flex;\n\n flex-direction: row;\n -webkit-flex-flow: row;\n -moz-flex-flow: row;\n -ms-flex-flow: row;\n -o-flex-flow: row;\n flex-flow: row;\n }\n\n .datatable-body-cell,\n .datatable-header-cell {\n vertical-align: top;\n display: inline-block;\n line-height: 1.625;\n\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n -o-user-select: none;\n user-select: none;\n \n &:focus {\n outline: none;\n }\n }\n\n .datatable-row-left,\n .datatable-row-right {\n z-index: 9;\n }\n\n .datatable-row-left,\n .datatable-row-center,\n .datatable-row-right {\n position:relative;\n }\n\n /**\n * Header Styles\n */\n .datatable-header {\n display: block;\n overflow: hidden;\n\n .datatable-header-inner{\n align-items: stretch;\n -webkit-align-items: stretch;\n }\n\n .datatable-header-cell {\n position: relative;\n display: inline-block;\n\n &.longpress {\n cursor: move;\n }\n\n &.sortable {\n cursor: pointer;\n }\n\n .sort-btn {\n line-height: 100%;\n vertical-align: middle;\n display: inline-block;\n }\n\n .resize-handle{\n display: inline-block;\n position: absolute;\n right: 0;\n top: 0;\n bottom: 0;\n width: 5px;\n padding: 0 8px;\n visibility: hidden;\n cursor: ew-resize;\n }\n\n &.resizeable:hover {\n .resize-handle{\n visibility: visible;\n }\n }\n }\n }\n\n /**\n * Body Styles\n */\n .datatable-body {\n position: relative;\n z-index: 10;\n display: block;\n\n .datatable-scroll{\n display: inline-block;\n }\n\n .datatable-row-detail {\n overflow-y: hidden;\n }\n\n .datatable-row-wrapper {\n display: -webkit-box;\n display: -moz-box;\n display: -ms-flexbox;\n display: -webkit-flex;\n display: flex;\n\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -webkit-flex-direction: column;\n -moz-box-orient: vertical;\n -moz-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n }\n\n .datatable-body-row {\n outline:none;\n\n > div {\n display: -webkit-box;\n display: -moz-box;\n display: -ms-flexbox;\n display: -webkit-flex;\n display: flex;\n }\n }\n }\n\n /**\n * Footer Styles\n */\n .datatable-footer {\n display: block;\n width: 100%;\n\n > div {\n display: flex;\n align-items: center;\n width: 100%;\n }\n\n .page-count{\n display: inline-block;\n flex: 1 1 20%;\n }\n\n .datatable-pager{\n display: inline-block;\n flex: 1 1 80%;\n text-align: right;\n\n .pager,\n .pager li {\n padding: 0;\n margin: 0;\n display: inline-block;\n list-style: none;\n }\n\n .pager {\n li, li a{\n outline: none;\n }\n\n li {\n a {\n cursor: pointer;\n display: inline-block;\n }\n\n &.disabled a {\n cursor: not-allowed;\n }\n }\n }\n }\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// webpack:///src/components/src/components/datatable.scss",".datatable.material {\n\tbackground:#FFF;\n -webkit-box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 1px 2px 0 rgba(0, 0, 0, 0.24);\n -moz-box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 1px 2px 0 rgba(0, 0, 0, 0.24);\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 1px 2px 0 rgba(0, 0, 0, 0.24);\n\n\t&.striped {\n\t\t.datatable-row-odd {\n\t\t\tbackground: #eee;\n\t\t}\n\t}\n\n\t/**\n\t * Shared Styles\n\t */\n\t.empty-row{\n\t\t height:50px;\n\t\t text-align: left;\n\t\t padding: .5rem 1.2rem;\n\t\t vertical-align: top;\n\t\t border-top: 0;\n\t}\n\n\t.loading-row{\n\t\t text-align: left;\n\t\t padding: .5rem 1.2rem;\n\t\t vertical-align: top;\n\t\t border-top: 0;\n\t}\n\n\t/**\n\t * Global Row Styles\n\t */\n\t .datatable-header,\n\t .datatable-body {\n\t\t .datatable-row-left {\n\t\t\tbackground-color: #FFF;\n\t\t\tbackground-position: 100% 0;\n\t\t\tbackground-repeat: repeat-y;\n\t\t\tbackground-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAABCAYAAAD5PA/NAAAAFklEQVQIHWPSkNeSBmJhTQVtbiDNCgASagIIuJX8OgAAAABJRU5ErkJggg==);\n\t\t}\n\n\t\t.datatable-row-right {\n\t\t\tbackground-position: 0 0;\n\t background-color: #fff;\n\t background-repeat: repeat-y;\n\t background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAABCAYAAAD5PA/NAAAAFklEQVQI12PQkNdi1VTQ5gbSwkAsDQARLAIGtOSFUAAAAABJRU5ErkJggg==);\n\t\t}\n\t}\n\n\t/**\n\t * Header Styles\n\t */\n\t.datatable-header {\n border-bottom: 1px solid rgba(0, 0, 0, 0.12);\n\n .datatable-header-cell {\n text-align: left;\n padding: .5rem 1.2rem;\n font-weight: 400;\n color: #757575;\n vertical-align: bottom;\n\n\t\t\t&.longpress {\n\t\t\t\tcolor:#00E676;\n\t\t\t}\n\n\t\t\t&.dragging {\n\t\t\t\t.resize-handle {\n\t\t\t\t\tborder-right: none;\n\t\t\t\t}\n\t\t\t}\n }\n\n .resize-handle {\n border-right:solid 1px #eee;\n }\n }\n\n\t/**\n\t * Body Styles\n\t */\n\t.datatable-body {\n\t\t.datatable-row-detail {\n\t\t\tbackground: #f5f5f5;\n\t\t\tpadding: 10px;\n\t\t}\n\n\t .datatable-body-row {\n\t .datatable-body-cell {\n\t text-align: left;\n\t padding: .5rem 1.2rem;\n\t vertical-align: top;\n\t border-top: 0;\n\n\t -webkit-transition: width 0.3s ease;\n\t -o-transition: width 0.3s ease;\n\t transition: width 0.3s ease;\n\n // cell active class\n // &.active {\n // background: #0829e0\n // }\n\t }\n\n\t &:hover,\n\t\t\t&:hover .datatable-row-group {\n\t background-color: #eee;\n\t transition-property: background;\n\t transition-duration: .3s;\n\t transition-timing-function: linear;\n\t }\n\n\t\t\t&:focus,\n\t\t\t&:focus .datatable-row-group {\n\t\t\t\tbackground-color: #ddd;\n\t\t\t}\n\n\t\t\t&.active,\n\t\t\t&.active .datatable-row-group {\n\t\t\t\tbackground-color: #304FFE;\n color: #FFF;\n\t\t\t}\n\n\t\t\t&.active:hover,\n\t\t\t&.active:hover .datatable-row-group {\n\t\t\t\tbackground-color: #193AE4;\n color: #FFF;\n\t\t\t}\n\n\t\t\t&.active:focus,\n\t\t\t&.active:focus .datatable-row-group {\n\t\t\t\tbackground-color: #2041EF;\n \t\tcolor: #FFF;\n\t\t\t}\n\t }\n\n\t\t.progress-linear {\n\t\t display: block;\n\t\t position: relative;\n\t\t width: 100%;\n\t\t height: 5px;\n\t\t padding: 0;\n\t\t margin: 0;\n position: absolute;\n\n\t\t\t.container {\n\t\t\t display: block;\n\t\t\t position: relative;\n\t\t\t overflow: hidden;\n\t\t\t width: 100%;\n\t\t\t height: 5px;\n\t\t\t -webkit-transform: translate(0,0) scale(1,1);\n\t\t\t transform: translate(0,0) scale(1,1);\n\t\t\t background-color: rgb(170,209,249);\n\n\t\t\t\t.bar {\n\t\t\t\t transition: all .2s linear;\n\t\t\t\t -webkit-animation: query .8s infinite cubic-bezier(.39,.575,.565,1);\n\t\t\t\t animation: query .8s infinite cubic-bezier(.39,.575,.565,1);\n\n\t\t\t\t transition: -webkit-transform .2s linear;\n\t\t\t\t transition: transform .2s linear;\n\t\t\t\t background-color: rgb(16,108,200);\n\n\t\t\t\t position: absolute;\n\t\t\t\t left: 0;\n\t\t\t\t top: 0;\n\t\t\t\t bottom: 0;\n\t\t\t\t width: 100%;\n\t\t\t\t height: 5px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Footer Styles\n\t */\n\t.datatable-footer {\n\t\tborder-top: 1px solid rgba(0, 0, 0, 0.12);\n\t\tfont-size:16px;\n\n\t\t.page-count{\n\t\t\tline-height: 50px;\n\t\t\theight:50px;\n\t\t\tpadding: 0 1.2rem;\n\t\t}\n\n\t\t.datatable-pager {\n\t\t\tmargin: 0 10px;\n\t //line-height: 50px;\n\n\t\t\tli {\n\t \tvertical-align: middle;\n\n\t\t\t\t&.disabled a{\n\t\t\t\t\tcolor:rgba(0, 0, 0, 0.26) !important;\n\t\t\t\t\tbackground-color: transparent !important;\n\t\t\t\t}\n\n\t\t\t\t&.active a{\n\t\t\t\t\tbackground-color: rgba(158,158,158,0.2);\n\t\t\t\t\tfont-weight: bold;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\ta {\n\t\t\t\theight: 22px;\n\t\t\t\tmin-width: 24px;\n\t\t\t\tline-height: 22px;\n\t\t\t\tpadding: 0 6px;\n\t\t\t\tborder-radius: 3px;\n\t\t\t\tmargin: 6px 3px;\n\t\t\t\ttext-align: center;\n\t\t\t\tvertical-align: top;\n\t\t\t\tcolor: rgba(0,0,0,.54);\n\t\t\t\ttext-decoration: none;\n\t\t vertical-align: bottom;\n\n\t\t\t\t&:hover{\n\t\t\t\t\tcolor: rgba(0,0,0,.75);\n\t\t\t\t\tbackground-color: rgba(158,158,158,0.2);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t.icon-left,\n\t\t\t.icon-skip,\n\t\t\t.icon-right,\n\t\t\t.icon-prev{\n\t\t\t\tfont-size:20px;\n\t\t\t\tline-height: 20px;\n\t\t\t\tpadding:0 3px;\n\t\t\t}\n\t\t}\n\t}\n}\n\n/**\n * Progress bar animations\n */\n@-webkit-keyframes query {\n 0% {\n opacity: 1;\n -webkit-transform: translateX(35%) scale(.3, 1);\n transform: translateX(35%) scale(.3, 1); }\n\n 100% {\n opacity: 0;\n -webkit-transform: translateX(-50%) scale(0, 1);\n transform: translateX(-50%) scale(0, 1); } }\n\n@keyframes query {\n 0% {\n opacity: 1;\n -webkit-transform: translateX(35%) scale(.3, 1);\n transform: translateX(35%) scale(.3, 1); }\n\n 100% {\n opacity: 0;\n -webkit-transform: translateX(-50%) scale(0, 1);\n transform: translateX(-50%) scale(0, 1); } }\n\n\n\n// WEBPACK FOOTER //\n// webpack:///src/themes/src/themes/material.scss"],"sourceRoot":""}
\ No newline at end of file
diff --git a/release/components/body/body-cell.component.ngfactory.ts b/release/components/body/body-cell.component.ngfactory.ts
index 859646732..bdba2d147 100644
--- a/release/components/body/body-cell.component.ngfactory.ts
+++ b/release/components/body/body-cell.component.ngfactory.ts
@@ -1,29 +1,30 @@
/**
- * This file is generated by the Angular 2 template compiler.
+ * @fileoverview This file is generated by the Angular 2 template compiler.
* Do not edit.
+ * @suppress {suspiciousCode,uselessCode,missingProperties}
*/
/* tslint:disable */
import * as import0 from '../../../../src/components/body/body-cell.component';
import * as import1 from '@angular/core/src/change_detection/change_detection';
-import * as import2 from '@angular/core/src/linker/view_utils';
-import * as import3 from '@angular/core/src/linker/view';
+import * as import2 from '@angular/core/src/linker/view';
+import * as import3 from '@angular/core/src/linker/view_utils';
import * as import4 from '@angular/core/src/security';
import * as import5 from '@angular/core/src/render/api';
-import * as import6 from '@angular/core/src/linker/element';
-import * as import7 from '@angular/core/src/di/injector';
-import * as import8 from '@angular/core/src/linker/view_type';
+import * as import6 from '@angular/core/src/metadata/view';
+import * as import7 from '@angular/core/src/linker/view_type';
+import * as import8 from '@angular/core/src/linker/component_factory';
import * as import9 from '@angular/core/src/linker/element_ref';
-import * as import10 from '@angular/core/src/metadata/view';
-import * as import11 from '@angular/core/src/linker/component_factory';
-import * as import12 from '../../../node_modules/@angular/common/src/directives/ng_if.ngfactory';
-import * as import13 from '@angular/core/src/linker/template_ref';
-import * as import14 from '@angular/common/src/directives/ng_if';
-import * as import15 from '../../../node_modules/@angular/common/src/directives/ng_template_outlet.ngfactory';
-import * as import16 from '@angular/common/src/directives/ng_template_outlet';
+import * as import10 from '@angular/core/src/linker/view_container';
+import * as import11 from '../../../node_modules/@angular/common/src/directives/ng_if.ngfactory';
+import * as import12 from '@angular/core/src/linker/template_ref';
+import * as import13 from '@angular/common/src/directives/ng_if';
+import * as import14 from '../../../node_modules/@angular/common/src/directives/ng_template_outlet.ngfactory';
+import * as import15 from '@angular/common/src/directives/ng_template_outlet';
export class Wrapper_DataTableBodyCellComponent {
+ /*private*/ _eventHandler:Function;
context:import0.DataTableBodyCellComponent;
- changed:boolean;
+ /*private*/ _changed:boolean;
/*private*/ _expr_0:any;
/*private*/ _expr_1:any;
/*private*/ _expr_2:any;
@@ -34,8 +35,9 @@ export class Wrapper_DataTableBodyCellComponent {
/*private*/ _expr_7:any;
/*private*/ _expr_8:any;
/*private*/ _expr_9:any;
+ subscription0:any;
constructor(p0:any,p1:any) {
- this.changed = false;
+ this._changed = false;
this.context = new import0.DataTableBodyCellComponent(p0,p1);
this._expr_0 = import1.UNINITIALIZED;
this._expr_1 = import1.UNINITIALIZED;
@@ -48,180 +50,183 @@ export class Wrapper_DataTableBodyCellComponent {
this._expr_8 = import1.UNINITIALIZED;
this._expr_9 = import1.UNINITIALIZED;
}
+ ngOnDetach(view:import2.AppView,componentView:import2.AppView,el:any):void {
+ }
+ ngOnDestroy():void {
+ (this.subscription0 && this.subscription0.unsubscribe());
+ }
check_row(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_0,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_0,currValue))) {
+ this._changed = true;
this.context.row = currValue;
this._expr_0 = currValue;
}
}
check_column(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_1,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_1,currValue))) {
+ this._changed = true;
this.context.column = currValue;
this._expr_1 = currValue;
}
}
check_rowHeight(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_2,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_2,currValue))) {
+ this._changed = true;
this.context.rowHeight = currValue;
this._expr_2 = currValue;
}
}
check_sorts(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_3,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_3,currValue))) {
+ this._changed = true;
this.context.sorts = currValue;
this._expr_3 = currValue;
}
}
- detectChangesInInputProps(view:import3.AppView,el:any,throwOnChange:boolean):boolean {
- var changed:any = this.changed;
- this.changed = false;
+ ngDoCheck(view:import2.AppView,el:any,throwOnChange:boolean):boolean {
+ var changed:any = this._changed;
+ this._changed = false;
return changed;
}
- detectChangesInHostProps(view:import3.AppView,el:any,throwOnChange:boolean):void {
+ checkHost(view:import2.AppView,componentView:import2.AppView,el:any,throwOnChange:boolean):void {
const currVal_4:any = this.context.isFocused;
- if (import2.checkBinding(throwOnChange,this._expr_4,currVal_4)) {
+ if (import3.checkBinding(throwOnChange,this._expr_4,currVal_4)) {
view.renderer.setElementClass(el,'active',currVal_4);
this._expr_4 = currVal_4;
}
const currVal_5:any = this.context.isSortActive;
- if (import2.checkBinding(throwOnChange,this._expr_5,currVal_5)) {
+ if (import3.checkBinding(throwOnChange,this._expr_5,currVal_5)) {
view.renderer.setElementClass(el,'sort-active',currVal_5);
this._expr_5 = currVal_5;
}
const currVal_6:any = this.context.isSortAscending;
- if (import2.checkBinding(throwOnChange,this._expr_6,currVal_6)) {
+ if (import3.checkBinding(throwOnChange,this._expr_6,currVal_6)) {
view.renderer.setElementClass(el,'sort-asc',currVal_6);
this._expr_6 = currVal_6;
}
const currVal_7:any = this.context.isSortDescending;
- if (import2.checkBinding(throwOnChange,this._expr_7,currVal_7)) {
+ if (import3.checkBinding(throwOnChange,this._expr_7,currVal_7)) {
view.renderer.setElementClass(el,'sort-desc',currVal_7);
this._expr_7 = currVal_7;
}
const currVal_8:any = this.context.width;
- if (import2.checkBinding(throwOnChange,this._expr_8,currVal_8)) {
- view.renderer.setElementStyle(el,'width',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_8) == (null as any))? (null as any): (view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_8).toString() + 'px')));
+ if (import3.checkBinding(throwOnChange,this._expr_8,currVal_8)) {
+ view.renderer.setElementStyle(el,'width',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_8) == null)? (null as any): (view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_8).toString() + 'px')));
this._expr_8 = currVal_8;
}
const currVal_9:any = this.context.height;
- if (import2.checkBinding(throwOnChange,this._expr_9,currVal_9)) {
- view.renderer.setElementStyle(el,'height',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_9) == (null as any))? (null as any): view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_9).toString()));
+ if (import3.checkBinding(throwOnChange,this._expr_9,currVal_9)) {
+ view.renderer.setElementStyle(el,'height',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_9) == null)? (null as any): view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_9).toString()));
this._expr_9 = currVal_9;
}
}
+ handleEvent(eventName:string,$event:any):boolean {
+ var result:boolean = true;
+ if ((eventName == 'focus')) {
+ const pd_sub_0:any = ((this.context.onFocus($event)) !== false);
+ result = (pd_sub_0 && result);
+ }
+ if ((eventName == 'blur')) {
+ const pd_sub_1:any = ((this.context.onBlur($event)) !== false);
+ result = (pd_sub_1 && result);
+ }
+ if ((eventName == 'click')) {
+ const pd_sub_2:any = ((this.context.onClick($event)) !== false);
+ result = (pd_sub_2 && result);
+ }
+ if ((eventName == 'dblclick')) {
+ const pd_sub_3:any = ((this.context.onDblClick($event)) !== false);
+ result = (pd_sub_3 && result);
+ }
+ if ((eventName == 'keydown')) {
+ const pd_sub_4:any = ((this.context.onKeyDown($event)) !== false);
+ result = (pd_sub_4 && result);
+ }
+ return result;
+ }
+ subscribe(view:import2.AppView,_eventHandler:any,emit0:boolean):void {
+ this._eventHandler = _eventHandler;
+ if (emit0) { (this.subscription0 = this.context.activate.subscribe(_eventHandler.bind(view,'activate'))); }
+ }
}
-var renderType_DataTableBodyCellComponent_Host:import5.RenderComponentType = (null as any);
-class _View_DataTableBodyCellComponent_Host0 extends import3.AppView {
+var renderType_DataTableBodyCellComponent_Host:import5.RenderComponentType = import3.createRenderComponentType('',0,import6.ViewEncapsulation.None,([] as any[]),{});
+class View_DataTableBodyCellComponent_Host0 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _DataTableBodyCellComponent_0_4:Wrapper_DataTableBodyCellComponent;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyCellComponent_Host0,renderType_DataTableBodyCellComponent_Host,import8.ViewType.HOST,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.selectOrCreateRenderHostElement(this.renderer,'datatable-body-cell',import2.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = viewFactory_DataTableBodyCellComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._DataTableBodyCellComponent_0_4 = new Wrapper_DataTableBodyCellComponent(new import9.ElementRef(this._el_0),this.renderer);
- this._appEl_0.initComponent(this._DataTableBodyCellComponent_0_4.context,([] as any[]),compView_0);
- compView_0.create(this._DataTableBodyCellComponent_0_4.context,this.projectableNodes,(null as any));
- var disposable_0:Function = this.renderer.listen(this._el_0,'focus',this.eventHandler(this._handle_focus_0_0.bind(this)));
- var disposable_1:Function = this.renderer.listen(this._el_0,'blur',this.eventHandler(this._handle_blur_0_1.bind(this)));
- var disposable_2:Function = this.renderer.listen(this._el_0,'click',this.eventHandler(this._handle_click_0_2.bind(this)));
- var disposable_3:Function = this.renderer.listen(this._el_0,'dblclick',this.eventHandler(this._handle_dblclick_0_3.bind(this)));
- var disposable_4:Function = this.renderer.listen(this._el_0,'keydown',this.eventHandler(this._handle_keydown_0_4.bind(this)));
- this.init(([] as any[]).concat([this._el_0]),[this._el_0],[
- disposable_0,
- disposable_1,
- disposable_2,
- disposable_3,
- disposable_4
- ]
- ,([] as any[]));
- return this._appEl_0;
+ compView_0:import2.AppView;
+ _DataTableBodyCellComponent_0_3:Wrapper_DataTableBodyCellComponent;
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableBodyCellComponent_Host0,renderType_DataTableBodyCellComponent_Host,import7.ViewType.HOST,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.selectOrCreateRenderHostElement(this.renderer,'datatable-body-cell',import3.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
+ this.compView_0 = new View_DataTableBodyCellComponent0(this.viewUtils,this,0,this._el_0);
+ this._DataTableBodyCellComponent_0_3 = new Wrapper_DataTableBodyCellComponent(new import9.ElementRef(this._el_0),this.renderer);
+ this.compView_0.create(this._DataTableBodyCellComponent_0_3.context);
+ var disposable_0:Function = import3.subscribeToRenderElement(this,this._el_0,new import3.InlineArray16(10,'focus',(null as any),'blur',(null as any),'click',(null as any),'dblclick',(null as any),'keydown',(null as any)),this.eventHandler(this.handleEvent_0));
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [this._el_0]),[disposable_0]);
+ return new import8.ComponentRef_(0,this,this._el_0,this._DataTableBodyCellComponent_0_3.context);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import0.DataTableBodyCellComponent) && (0 === requestNodeIndex))) { return this._DataTableBodyCellComponent_0_4.context; }
+ if (((token === import0.DataTableBodyCellComponent) && (0 === requestNodeIndex))) { return this._DataTableBodyCellComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- if (this._DataTableBodyCellComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._DataTableBodyCellComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
- }
- private _handle_focus_0_0($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onFocus($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_blur_0_1($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onBlur($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_click_0_2($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onClick($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_dblclick_0_3($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onDblClick($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_keydown_0_4($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onKeyDown($event)) !== false);
- return (true && pd_0_0);
+ if (this._DataTableBodyCellComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this._DataTableBodyCellComponent_0_3.checkHost(this,this.compView_0,this._el_0,throwOnChange);
+ this.compView_0.detectChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this.compView_0.destroy();
+ this._DataTableBodyCellComponent_0_3.ngOnDestroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ handleEvent_0(eventName:string,$event:any):boolean {
+ this.compView_0.markPathToRootAsCheckOnce();
+ var result:boolean = true;
+ result = (this._DataTableBodyCellComponent_0_3.handleEvent(eventName,$event) && result);
+ return result;
}
}
-function viewFactory_DataTableBodyCellComponent_Host0(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- if ((renderType_DataTableBodyCellComponent_Host === (null as any))) { (renderType_DataTableBodyCellComponent_Host = viewUtils.createRenderComponentType('',0,import10.ViewEncapsulation.None,([] as any[]),{})); }
- return new _View_DataTableBodyCellComponent_Host0(viewUtils,parentInjector,declarationEl);
-}
-export const DataTableBodyCellComponentNgFactory:import11.ComponentFactory = new import11.ComponentFactory('datatable-body-cell',viewFactory_DataTableBodyCellComponent_Host0,import0.DataTableBodyCellComponent);
+export const DataTableBodyCellComponentNgFactory:import8.ComponentFactory = new import8.ComponentFactory('datatable-body-cell',View_DataTableBodyCellComponent_Host0,import0.DataTableBodyCellComponent);
const styles_DataTableBodyCellComponent:any[] = ([] as any[]);
-var renderType_DataTableBodyCellComponent:import5.RenderComponentType = (null as any);
-class _View_DataTableBodyCellComponent0 extends import3.AppView {
+var renderType_DataTableBodyCellComponent:import5.RenderComponentType = import3.createRenderComponentType('',0,import6.ViewEncapsulation.None,styles_DataTableBodyCellComponent,{});
+export class View_DataTableBodyCellComponent0 extends import2.AppView {
_text_0:any;
_el_1:any;
_text_2:any;
_anchor_3:any;
- /*private*/ _appEl_3:import6.AppElement;
+ /*private*/ _vc_3:import10.ViewContainer;
_TemplateRef_3_5:any;
- _NgIf_3_6:import12.Wrapper_NgIf;
+ _NgIf_3_6:import11.Wrapper_NgIf;
_text_4:any;
_anchor_5:any;
- /*private*/ _appEl_5:import6.AppElement;
+ /*private*/ _vc_5:import10.ViewContainer;
_TemplateRef_5_5:any;
- _NgIf_5_6:import12.Wrapper_NgIf;
+ _NgIf_5_6:import11.Wrapper_NgIf;
_text_6:any;
_text_7:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyCellComponent0,renderType_DataTableBodyCellComponent,import8.ViewType.COMPONENT,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckOnce);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableBodyCellComponent0,renderType_DataTableBodyCellComponent,import7.ViewType.COMPONENT,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckOnce);
}
- createInternal(rootSelector:string):import6.AppElement {
- const parentRenderNode:any = this.renderer.createViewRoot(this.declarationAppElement.nativeElement);
+ createInternal(rootSelector:string):import8.ComponentRef {
+ const parentRenderNode:any = this.renderer.createViewRoot(this.parentElement);
this._text_0 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this._el_1 = import2.createRenderElement(this.renderer,parentRenderNode,'div',new import2.InlineArray2(2,'class','datatable-body-cell-label'),(null as any));
+ this._el_1 = import3.createRenderElement(this.renderer,parentRenderNode,'div',new import3.InlineArray2(2,'class','datatable-body-cell-label'),(null as any));
this._text_2 = this.renderer.createText(this._el_1,'\n ',(null as any));
this._anchor_3 = this.renderer.createTemplateAnchor(this._el_1,(null as any));
- this._appEl_3 = new import6.AppElement(3,1,this,this._anchor_3);
- this._TemplateRef_3_5 = new import13.TemplateRef_(this._appEl_3,viewFactory_DataTableBodyCellComponent1);
- this._NgIf_3_6 = new import12.Wrapper_NgIf(this._appEl_3.vcRef,this._TemplateRef_3_5);
+ this._vc_3 = new import10.ViewContainer(3,1,this,this._anchor_3);
+ this._TemplateRef_3_5 = new import12.TemplateRef_(this,3,this._anchor_3);
+ this._NgIf_3_6 = new import11.Wrapper_NgIf(this._vc_3.vcRef,this._TemplateRef_3_5);
this._text_4 = this.renderer.createText(this._el_1,'\n ',(null as any));
this._anchor_5 = this.renderer.createTemplateAnchor(this._el_1,(null as any));
- this._appEl_5 = new import6.AppElement(5,1,this,this._anchor_5);
- this._TemplateRef_5_5 = new import13.TemplateRef_(this._appEl_5,viewFactory_DataTableBodyCellComponent2);
- this._NgIf_5_6 = new import12.Wrapper_NgIf(this._appEl_5.vcRef,this._TemplateRef_5_5);
+ this._vc_5 = new import10.ViewContainer(5,1,this,this._anchor_5);
+ this._TemplateRef_5_5 = new import12.TemplateRef_(this,5,this._anchor_5);
+ this._NgIf_5_6 = new import11.Wrapper_NgIf(this._vc_5.vcRef,this._TemplateRef_5_5);
this._text_6 = this.renderer.createText(this._el_1,'\n ',(null as any));
this._text_7 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this.init(([] as any[]),[
+ this.init((null as any),((this.renderer).directRenderer? (null as any): [
this._text_0,
this._el_1,
this._text_2,
@@ -231,71 +236,75 @@ class _View_DataTableBodyCellComponent0 extends import3.AppView {
+ if ((nodeIndex == 3)) { return new View_DataTableBodyCellComponent1(this.viewUtils,this,3,this._anchor_3,this._vc_3); }
+ if ((nodeIndex == 5)) { return new View_DataTableBodyCellComponent2(this.viewUtils,this,5,this._anchor_5,this._vc_5); }
+ return (null as any);
}
}
-export function viewFactory_DataTableBodyCellComponent0(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- if ((renderType_DataTableBodyCellComponent === (null as any))) { (renderType_DataTableBodyCellComponent = viewUtils.createRenderComponentType('',0,import10.ViewEncapsulation.None,styles_DataTableBodyCellComponent,{})); }
- return new _View_DataTableBodyCellComponent0(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyCellComponent1 extends import3.AppView {
+class View_DataTableBodyCellComponent1 extends import2.AppView {
_el_0:any;
_text_1:any;
/*private*/ _expr_2:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyCellComponent1,renderType_DataTableBodyCellComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import10.ViewContainer) {
+ super(View_DataTableBodyCellComponent1,renderType_DataTableBodyCellComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
this._expr_2 = import1.UNINITIALIZED;
}
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'span',import2.EMPTY_INLINE_ARRAY,(null as any));
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'span',import3.EMPTY_INLINE_ARRAY,(null as any));
this._text_1 = this.renderer.createText(this._el_0,'\n ',(null as any));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
detectChangesInternal(throwOnChange:boolean):void {
- this.detectContentChildrenChanges(throwOnChange);
- const currVal_2:any = this.parent.context.value;
- if (import2.checkBinding(throwOnChange,this._expr_2,currVal_2)) {
+ const currVal_2:any = this.parentView.context.value;
+ if (import3.checkBinding(throwOnChange,this._expr_2,currVal_2)) {
this.renderer.setElementProperty(this._el_0,'innerHTML',this.viewUtils.sanitizer.sanitize(import4.SecurityContext.HTML,currVal_2));
this._expr_2 = currVal_2;
}
- this.detectViewChildrenChanges(throwOnChange);
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
}
}
-function viewFactory_DataTableBodyCellComponent1(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyCellComponent1(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyCellComponent2 extends import3.AppView {
+class View_DataTableBodyCellComponent2 extends import2.AppView {
_anchor_0:any;
- /*private*/ _appEl_0:import6.AppElement;
+ /*private*/ _vc_0:import10.ViewContainer;
_TemplateRef_0_5:any;
- _NgTemplateOutlet_0_6:import15.Wrapper_NgTemplateOutlet;
- _map_4:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyCellComponent2,renderType_DataTableBodyCellComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- this._map_4 = import2.pureProxy3((p0:any,p1:any,p2:any):{[key: string]:any} => {
+ _NgTemplateOutlet_0_6:import14.Wrapper_NgTemplateOutlet;
+ _el_1:any;
+ _map_5:any;
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import10.ViewContainer) {
+ super(View_DataTableBodyCellComponent2,renderType_DataTableBodyCellComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
+ this._map_5 = import3.pureProxy3((p0:any,p1:any,p2:any):{[key: string]:any} => {
return {
value: p0,
row: p1,
@@ -304,43 +313,52 @@ class _View_DataTableBodyCellComponent2 extends import3.AppView {
;
});
}
- createInternal(rootSelector:string):import6.AppElement {
+ createInternal(rootSelector:string):import8.ComponentRef {
this._anchor_0 = this.renderer.createTemplateAnchor((null as any),(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._anchor_0);
- this._TemplateRef_0_5 = new import13.TemplateRef_(this._appEl_0,viewFactory_DataTableBodyCellComponent3);
- this._NgTemplateOutlet_0_6 = new import15.Wrapper_NgTemplateOutlet(this._appEl_0.vcRef);
- this.init(([] as any[]).concat([this._appEl_0]),[this._anchor_0],([] as any[]),([] as any[]));
+ this._vc_0 = new import10.ViewContainer(0,(null as any),this,this._anchor_0);
+ this._TemplateRef_0_5 = new import12.TemplateRef_(this,0,this._anchor_0);
+ this._NgTemplateOutlet_0_6 = new import14.Wrapper_NgTemplateOutlet(this._vc_0.vcRef);
+ this._el_1 = this.renderer.createTemplateAnchor((null as any),(null as any));
+ this.init(this._el_1,((this.renderer).directRenderer? (null as any): [this._anchor_0]),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import13.TemplateRef) && (0 === requestNodeIndex))) { return this._TemplateRef_0_5; }
- if (((token === import16.NgTemplateOutlet) && (0 === requestNodeIndex))) { return this._NgTemplateOutlet_0_6.context; }
+ if (((token === import12.TemplateRef) && (0 === requestNodeIndex))) { return this._TemplateRef_0_5; }
+ if (((token === import15.NgTemplateOutlet) && (0 === requestNodeIndex))) { return this._NgTemplateOutlet_0_6.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_0_0_0:any = this._map_4(this.parent.context.value,this.parent.context.row,this.parent.context.column);
+ const currVal_0_0_0:any = this._map_5(this.parentView.context.value,this.parentView.context.row,this.parentView.context.column);
this._NgTemplateOutlet_0_6.check_ngOutletContext(currVal_0_0_0,throwOnChange,false);
- const currVal_0_0_1:any = this.parent.context.column.cellTemplate;
+ const currVal_0_0_1:any = this.parentView.context.column.cellTemplate;
this._NgTemplateOutlet_0_6.check_ngTemplateOutlet(currVal_0_0_1,throwOnChange,false);
- this._NgTemplateOutlet_0_6.detectChangesInInputProps(this,this._anchor_0,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ this._NgTemplateOutlet_0_6.ngDoCheck(this,this._anchor_0,throwOnChange);
+ this._vc_0.detectChangesInNestedViews(throwOnChange);
+ }
+ destroyInternal():void {
+ this._vc_0.destroyNestedViews();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._vc_0.nativeElement,ctx);
+ this._vc_0.visitNestedViewRootNodes(cb,ctx);
+ cb(this._el_1,ctx);
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 0)) { return new View_DataTableBodyCellComponent3(this.viewUtils,this,0,this._anchor_0,this._vc_0); }
+ return (null as any);
}
}
-function viewFactory_DataTableBodyCellComponent2(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyCellComponent2(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyCellComponent3 extends import3.AppView {
+class View_DataTableBodyCellComponent3 extends import2.AppView {
_text_0:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyCellComponent3,renderType_DataTableBodyCellComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import10.ViewContainer) {
+ super(View_DataTableBodyCellComponent3,renderType_DataTableBodyCellComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
}
- createInternal(rootSelector:string):import6.AppElement {
+ createInternal(rootSelector:string):import8.ComponentRef {
this._text_0 = this.renderer.createText((null as any),'\n ',(null as any));
- this.init(([] as any[]).concat([this._text_0]),[this._text_0],([] as any[]),([] as any[]));
+ this.init(this._text_0,((this.renderer).directRenderer? (null as any): [this._text_0]),(null as any));
return (null as any);
}
-}
-function viewFactory_DataTableBodyCellComponent3(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyCellComponent3(viewUtils,parentInjector,declarationEl);
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._text_0,ctx);
+ }
}
\ No newline at end of file
diff --git a/release/components/body/body-row-wrapper.component.ngfactory.ts b/release/components/body/body-row-wrapper.component.ngfactory.ts
index cdadc0009..32e862f5f 100644
--- a/release/components/body/body-row-wrapper.component.ngfactory.ts
+++ b/release/components/body/body-row-wrapper.component.ngfactory.ts
@@ -1,260 +1,291 @@
/**
- * This file is generated by the Angular 2 template compiler.
+ * @fileoverview This file is generated by the Angular 2 template compiler.
* Do not edit.
+ * @suppress {suspiciousCode,uselessCode,missingProperties}
*/
/* tslint:disable */
import * as import0 from '../../../../src/components/body/body-row-wrapper.component';
import * as import1 from '@angular/core/src/change_detection/change_detection';
-import * as import2 from '@angular/core/src/linker/view_utils';
-import * as import3 from '@angular/core/src/linker/view';
+import * as import2 from '@angular/core/src/linker/view';
+import * as import3 from '@angular/core/src/linker/view_utils';
import * as import4 from '@angular/core/src/render/api';
-import * as import5 from '@angular/core/src/linker/element';
-import * as import6 from '@angular/core/src/di/injector';
-import * as import7 from '@angular/core/src/linker/view_type';
+import * as import5 from '@angular/core/src/metadata/view';
+import * as import6 from '@angular/core/src/linker/view_type';
+import * as import7 from '@angular/core/src/linker/component_factory';
import * as import8 from '@angular/core/src/linker/element_ref';
-import * as import9 from '@angular/core/src/metadata/view';
-import * as import10 from '@angular/core/src/linker/component_factory';
-import * as import11 from '../../../node_modules/@angular/common/src/directives/ng_if.ngfactory';
-import * as import12 from '@angular/core/src/linker/template_ref';
-import * as import13 from '@angular/common/src/directives/ng_if';
-import * as import14 from '@angular/core/src/security';
-import * as import15 from '../../../node_modules/@angular/common/src/directives/ng_template_outlet.ngfactory';
-import * as import16 from '@angular/common/src/directives/ng_template_outlet';
+import * as import9 from '@angular/core/src/linker/view_container';
+import * as import10 from '../../../node_modules/@angular/common/src/directives/ng_if.ngfactory';
+import * as import11 from '@angular/core/src/linker/template_ref';
+import * as import12 from '@angular/common/src/directives/ng_if';
+import * as import13 from '@angular/core/src/security';
+import * as import14 from '../../../node_modules/@angular/common/src/directives/ng_template_outlet.ngfactory';
+import * as import15 from '@angular/common/src/directives/ng_template_outlet';
export class Wrapper_DataTableRowWrapperComponent {
+ /*private*/ _eventHandler:Function;
context:import0.DataTableRowWrapperComponent;
- changed:boolean;
+ /*private*/ _changed:boolean;
/*private*/ _expr_0:any;
/*private*/ _expr_1:any;
/*private*/ _expr_2:any;
/*private*/ _expr_3:any;
constructor(p0:any,p1:any) {
- this.changed = false;
+ this._changed = false;
this.context = new import0.DataTableRowWrapperComponent(p0,p1);
this._expr_0 = import1.UNINITIALIZED;
this._expr_1 = import1.UNINITIALIZED;
this._expr_2 = import1.UNINITIALIZED;
this._expr_3 = import1.UNINITIALIZED;
}
+ ngOnDetach(view:import2.AppView,componentView:import2.AppView,el:any):void {
+ }
+ ngOnDestroy():void {
+ }
check_rowDetailTemplate(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_0,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_0,currValue))) {
+ this._changed = true;
this.context.rowDetailTemplate = currValue;
this._expr_0 = currValue;
}
}
check_detailRowHeight(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_1,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_1,currValue))) {
+ this._changed = true;
this.context.detailRowHeight = currValue;
this._expr_1 = currValue;
}
}
check_expanded(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_2,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_2,currValue))) {
+ this._changed = true;
this.context.expanded = currValue;
this._expr_2 = currValue;
}
}
check_row(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_3,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_3,currValue))) {
+ this._changed = true;
this.context.row = currValue;
this._expr_3 = currValue;
}
}
- detectChangesInInputProps(view:import3.AppView,el:any,throwOnChange:boolean):boolean {
- var changed:any = this.changed;
- this.changed = false;
+ ngDoCheck(view:import2.AppView,el:any,throwOnChange:boolean):boolean {
+ var changed:any = this._changed;
+ this._changed = false;
return changed;
}
- detectChangesInHostProps(view:import3.AppView,el:any,throwOnChange:boolean):void {
+ checkHost(view:import2.AppView,componentView:import2.AppView,el:any,throwOnChange:boolean):void {
+ }
+ handleEvent(eventName:string,$event:any):boolean {
+ var result:boolean = true;
+ return result;
+ }
+ subscribe(view:import2.AppView,_eventHandler:any):void {
+ this._eventHandler = _eventHandler;
}
}
-var renderType_DataTableRowWrapperComponent_Host:import4.RenderComponentType = (null as any);
-class _View_DataTableRowWrapperComponent_Host0 extends import3.AppView {
+var renderType_DataTableRowWrapperComponent_Host:import4.RenderComponentType = import3.createRenderComponentType('',0,import5.ViewEncapsulation.None,([] as any[]),{});
+class View_DataTableRowWrapperComponent_Host0 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import5.AppElement;
- _DataTableRowWrapperComponent_0_4:Wrapper_DataTableRowWrapperComponent;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement) {
- super(_View_DataTableRowWrapperComponent_Host0,renderType_DataTableRowWrapperComponent_Host,import7.ViewType.HOST,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import5.AppElement {
- this._el_0 = import2.selectOrCreateRenderHostElement(this.renderer,'datatable-row-wrapper',import2.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
- this._appEl_0 = new import5.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = viewFactory_DataTableRowWrapperComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._DataTableRowWrapperComponent_0_4 = new Wrapper_DataTableRowWrapperComponent(new import8.ElementRef(this._el_0),this.renderer);
- this._appEl_0.initComponent(this._DataTableRowWrapperComponent_0_4.context,([] as any[]),compView_0);
- compView_0.create(this._DataTableRowWrapperComponent_0_4.context,this.projectableNodes,(null as any));
- this.init(([] as any[]).concat([this._el_0]),[this._el_0],([] as any[]),([] as any[]));
- return this._appEl_0;
+ compView_0:import2.AppView;
+ _DataTableRowWrapperComponent_0_3:Wrapper_DataTableRowWrapperComponent;
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableRowWrapperComponent_Host0,renderType_DataTableRowWrapperComponent_Host,import6.ViewType.HOST,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways);
+ }
+ createInternal(rootSelector:string):import7.ComponentRef {
+ this._el_0 = import3.selectOrCreateRenderHostElement(this.renderer,'datatable-row-wrapper',import3.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
+ this.compView_0 = new View_DataTableRowWrapperComponent0(this.viewUtils,this,0,this._el_0);
+ this._DataTableRowWrapperComponent_0_3 = new Wrapper_DataTableRowWrapperComponent(new import8.ElementRef(this._el_0),this.renderer);
+ this.compView_0.create(this._DataTableRowWrapperComponent_0_3.context);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [this._el_0]),(null as any));
+ return new import7.ComponentRef_(0,this,this._el_0,this._DataTableRowWrapperComponent_0_3.context);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import0.DataTableRowWrapperComponent) && (0 === requestNodeIndex))) { return this._DataTableRowWrapperComponent_0_4.context; }
+ if (((token === import0.DataTableRowWrapperComponent) && (0 === requestNodeIndex))) { return this._DataTableRowWrapperComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- if (this._DataTableRowWrapperComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._DataTableRowWrapperComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ if (this._DataTableRowWrapperComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this.compView_0.detectChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this.compView_0.destroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ visitProjectableNodesInternal(nodeIndex:number,ngContentIndex:number,cb:any,ctx:any):void {
+ if (((nodeIndex == 0) && (ngContentIndex == 0))) { }
}
}
-function viewFactory_DataTableRowWrapperComponent_Host0(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement):import3.AppView {
- if ((renderType_DataTableRowWrapperComponent_Host === (null as any))) { (renderType_DataTableRowWrapperComponent_Host = viewUtils.createRenderComponentType('',0,import9.ViewEncapsulation.None,([] as any[]),{})); }
- return new _View_DataTableRowWrapperComponent_Host0(viewUtils,parentInjector,declarationEl);
-}
-export const DataTableRowWrapperComponentNgFactory:import10.ComponentFactory = new import10.ComponentFactory('datatable-row-wrapper',viewFactory_DataTableRowWrapperComponent_Host0,import0.DataTableRowWrapperComponent);
+export const DataTableRowWrapperComponentNgFactory:import7.ComponentFactory = new import7.ComponentFactory('datatable-row-wrapper',View_DataTableRowWrapperComponent_Host0,import0.DataTableRowWrapperComponent);
const styles_DataTableRowWrapperComponent:any[] = ([] as any[]);
-var renderType_DataTableRowWrapperComponent:import4.RenderComponentType = (null as any);
-class _View_DataTableRowWrapperComponent0 extends import3.AppView {
+var renderType_DataTableRowWrapperComponent:import4.RenderComponentType = import3.createRenderComponentType('',1,import5.ViewEncapsulation.None,styles_DataTableRowWrapperComponent,{});
+export class View_DataTableRowWrapperComponent0 extends import2.AppView {
_text_0:any;
_text_1:any;
_anchor_2:any;
- /*private*/ _appEl_2:import5.AppElement;
+ /*private*/ _vc_2:import9.ViewContainer;
_TemplateRef_2_5:any;
- _NgIf_2_6:import11.Wrapper_NgIf;
+ _NgIf_2_6:import10.Wrapper_NgIf;
_text_3:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement) {
- super(_View_DataTableRowWrapperComponent0,renderType_DataTableRowWrapperComponent,import7.ViewType.COMPONENT,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckOnce);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableRowWrapperComponent0,renderType_DataTableRowWrapperComponent,import6.ViewType.COMPONENT,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckOnce);
}
- createInternal(rootSelector:string):import5.AppElement {
- const parentRenderNode:any = this.renderer.createViewRoot(this.declarationAppElement.nativeElement);
+ createInternal(rootSelector:string):import7.ComponentRef {
+ const parentRenderNode:any = this.renderer.createViewRoot(this.parentElement);
this._text_0 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this.renderer.projectNodes(parentRenderNode,import2.flattenNestedViewRenderNodes(this.projectableNodes[0]));
+ this.projectNodes(parentRenderNode,0);
this._text_1 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
this._anchor_2 = this.renderer.createTemplateAnchor(parentRenderNode,(null as any));
- this._appEl_2 = new import5.AppElement(2,(null as any),this,this._anchor_2);
- this._TemplateRef_2_5 = new import12.TemplateRef_(this._appEl_2,viewFactory_DataTableRowWrapperComponent1);
- this._NgIf_2_6 = new import11.Wrapper_NgIf(this._appEl_2.vcRef,this._TemplateRef_2_5);
+ this._vc_2 = new import9.ViewContainer(2,(null as any),this,this._anchor_2);
+ this._TemplateRef_2_5 = new import11.TemplateRef_(this,2,this._anchor_2);
+ this._NgIf_2_6 = new import10.Wrapper_NgIf(this._vc_2.vcRef,this._TemplateRef_2_5);
this._text_3 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this.init(([] as any[]),[
+ this.init((null as any),((this.renderer).directRenderer? (null as any): [
this._text_0,
this._text_1,
this._anchor_2,
this._text_3
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import12.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
- if (((token === import13.NgIf) && (2 === requestNodeIndex))) { return this._NgIf_2_6.context; }
+ if (((token === import11.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
+ if (((token === import12.NgIf) && (2 === requestNodeIndex))) { return this._NgIf_2_6.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
const currVal_2_0_0:any = this.context.expanded;
this._NgIf_2_6.check_ngIf(currVal_2_0_0,throwOnChange,false);
- this._NgIf_2_6.detectChangesInInputProps(this,this._anchor_2,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ this._NgIf_2_6.ngDoCheck(this,this._anchor_2,throwOnChange);
+ this._vc_2.detectChangesInNestedViews(throwOnChange);
+ }
+ destroyInternal():void {
+ this._vc_2.destroyNestedViews();
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 2)) { return new View_DataTableRowWrapperComponent1(this.viewUtils,this,2,this._anchor_2,this._vc_2); }
+ return (null as any);
}
}
-export function viewFactory_DataTableRowWrapperComponent0(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement):import3.AppView {
- if ((renderType_DataTableRowWrapperComponent === (null as any))) { (renderType_DataTableRowWrapperComponent = viewUtils.createRenderComponentType('',1,import9.ViewEncapsulation.None,styles_DataTableRowWrapperComponent,{})); }
- return new _View_DataTableRowWrapperComponent0(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableRowWrapperComponent1 extends import3.AppView {
+class View_DataTableRowWrapperComponent1 extends import2.AppView {
_el_0:any;
_text_1:any;
_anchor_2:any;
- /*private*/ _appEl_2:import5.AppElement;
+ /*private*/ _vc_2:import9.ViewContainer;
_TemplateRef_2_5:any;
- _NgIf_2_6:import11.Wrapper_NgIf;
+ _NgIf_2_6:import10.Wrapper_NgIf;
_text_3:any;
/*private*/ _expr_7:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement) {
- super(_View_DataTableRowWrapperComponent1,renderType_DataTableRowWrapperComponent,import7.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import9.ViewContainer) {
+ super(View_DataTableRowWrapperComponent1,renderType_DataTableRowWrapperComponent,import6.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
this._expr_7 = import1.UNINITIALIZED;
}
- createInternal(rootSelector:string):import5.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'div',new import2.InlineArray2(2,'class','datatable-row-detail'),(null as any));
+ createInternal(rootSelector:string):import7.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'div',new import3.InlineArray2(2,'class','datatable-row-detail'),(null as any));
this._text_1 = this.renderer.createText(this._el_0,'\n ',(null as any));
this._anchor_2 = this.renderer.createTemplateAnchor(this._el_0,(null as any));
- this._appEl_2 = new import5.AppElement(2,0,this,this._anchor_2);
- this._TemplateRef_2_5 = new import12.TemplateRef_(this._appEl_2,viewFactory_DataTableRowWrapperComponent2);
- this._NgIf_2_6 = new import11.Wrapper_NgIf(this._appEl_2.vcRef,this._TemplateRef_2_5);
+ this._vc_2 = new import9.ViewContainer(2,0,this,this._anchor_2);
+ this._TemplateRef_2_5 = new import11.TemplateRef_(this,2,this._anchor_2);
+ this._NgIf_2_6 = new import10.Wrapper_NgIf(this._vc_2.vcRef,this._TemplateRef_2_5);
this._text_3 = this.renderer.createText(this._el_0,'\n ',(null as any));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1,
this._anchor_2,
this._text_3
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import12.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
- if (((token === import13.NgIf) && (2 === requestNodeIndex))) { return this._NgIf_2_6.context; }
+ if (((token === import11.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
+ if (((token === import12.NgIf) && (2 === requestNodeIndex))) { return this._NgIf_2_6.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_2_0_0:any = this.parent.context.rowDetailTemplate;
+ const currVal_2_0_0:any = this.parentView.context.rowDetailTemplate;
this._NgIf_2_6.check_ngIf(currVal_2_0_0,throwOnChange,false);
- this._NgIf_2_6.detectChangesInInputProps(this,this._anchor_2,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- const currVal_7:any = this.parent.context.detailRowHeight;
- if (import2.checkBinding(throwOnChange,this._expr_7,currVal_7)) {
- this.renderer.setElementStyle(this._el_0,'height',((this.viewUtils.sanitizer.sanitize(import14.SecurityContext.STYLE,currVal_7) == (null as any))? (null as any): (this.viewUtils.sanitizer.sanitize(import14.SecurityContext.STYLE,currVal_7).toString() + 'px')));
+ this._NgIf_2_6.ngDoCheck(this,this._anchor_2,throwOnChange);
+ this._vc_2.detectChangesInNestedViews(throwOnChange);
+ const currVal_7:any = this.parentView.context.detailRowHeight;
+ if (import3.checkBinding(throwOnChange,this._expr_7,currVal_7)) {
+ this.renderer.setElementStyle(this._el_0,'height',((this.viewUtils.sanitizer.sanitize(import13.SecurityContext.STYLE,currVal_7) == null)? (null as any): (this.viewUtils.sanitizer.sanitize(import13.SecurityContext.STYLE,currVal_7).toString() + 'px')));
this._expr_7 = currVal_7;
}
- this.detectViewChildrenChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this._vc_2.destroyNestedViews();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 2)) { return new View_DataTableRowWrapperComponent2(this.viewUtils,this,2,this._anchor_2,this._vc_2); }
+ return (null as any);
}
}
-function viewFactory_DataTableRowWrapperComponent1(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement):import3.AppView {
- return new _View_DataTableRowWrapperComponent1(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableRowWrapperComponent2 extends import3.AppView {
+class View_DataTableRowWrapperComponent2 extends import2.AppView {
_anchor_0:any;
- /*private*/ _appEl_0:import5.AppElement;
+ /*private*/ _vc_0:import9.ViewContainer;
_TemplateRef_0_5:any;
- _NgTemplateOutlet_0_6:import15.Wrapper_NgTemplateOutlet;
- _map_4:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement) {
- super(_View_DataTableRowWrapperComponent2,renderType_DataTableRowWrapperComponent,import7.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- this._map_4 = import2.pureProxy1((p0:any):{[key: string]:any} => {
+ _NgTemplateOutlet_0_6:import14.Wrapper_NgTemplateOutlet;
+ _el_1:any;
+ _map_5:any;
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import9.ViewContainer) {
+ super(View_DataTableRowWrapperComponent2,renderType_DataTableRowWrapperComponent,import6.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
+ this._map_5 = import3.pureProxy1((p0:any):{[key: string]:any} => {
return {row: p0};
});
}
- createInternal(rootSelector:string):import5.AppElement {
+ createInternal(rootSelector:string):import7.ComponentRef {
this._anchor_0 = this.renderer.createTemplateAnchor((null as any),(null as any));
- this._appEl_0 = new import5.AppElement(0,(null as any),this,this._anchor_0);
- this._TemplateRef_0_5 = new import12.TemplateRef_(this._appEl_0,viewFactory_DataTableRowWrapperComponent3);
- this._NgTemplateOutlet_0_6 = new import15.Wrapper_NgTemplateOutlet(this._appEl_0.vcRef);
- this.init(([] as any[]).concat([this._appEl_0]),[this._anchor_0],([] as any[]),([] as any[]));
+ this._vc_0 = new import9.ViewContainer(0,(null as any),this,this._anchor_0);
+ this._TemplateRef_0_5 = new import11.TemplateRef_(this,0,this._anchor_0);
+ this._NgTemplateOutlet_0_6 = new import14.Wrapper_NgTemplateOutlet(this._vc_0.vcRef);
+ this._el_1 = this.renderer.createTemplateAnchor((null as any),(null as any));
+ this.init(this._el_1,((this.renderer).directRenderer? (null as any): [this._anchor_0]),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import12.TemplateRef) && (0 === requestNodeIndex))) { return this._TemplateRef_0_5; }
- if (((token === import16.NgTemplateOutlet) && (0 === requestNodeIndex))) { return this._NgTemplateOutlet_0_6.context; }
+ if (((token === import11.TemplateRef) && (0 === requestNodeIndex))) { return this._TemplateRef_0_5; }
+ if (((token === import15.NgTemplateOutlet) && (0 === requestNodeIndex))) { return this._NgTemplateOutlet_0_6.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_0_0_0:any = this._map_4(this.parent.parent.context.row);
+ const currVal_0_0_0:any = this._map_5(this.parentView.parentView.context.row);
this._NgTemplateOutlet_0_6.check_ngOutletContext(currVal_0_0_0,throwOnChange,false);
- const currVal_0_0_1:any = this.parent.parent.context.rowDetailTemplate;
+ const currVal_0_0_1:any = this.parentView.parentView.context.rowDetailTemplate;
this._NgTemplateOutlet_0_6.check_ngTemplateOutlet(currVal_0_0_1,throwOnChange,false);
- this._NgTemplateOutlet_0_6.detectChangesInInputProps(this,this._anchor_0,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ this._NgTemplateOutlet_0_6.ngDoCheck(this,this._anchor_0,throwOnChange);
+ this._vc_0.detectChangesInNestedViews(throwOnChange);
+ }
+ destroyInternal():void {
+ this._vc_0.destroyNestedViews();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._vc_0.nativeElement,ctx);
+ this._vc_0.visitNestedViewRootNodes(cb,ctx);
+ cb(this._el_1,ctx);
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 0)) { return new View_DataTableRowWrapperComponent3(this.viewUtils,this,0,this._anchor_0,this._vc_0); }
+ return (null as any);
}
}
-function viewFactory_DataTableRowWrapperComponent2(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement):import3.AppView {
- return new _View_DataTableRowWrapperComponent2(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableRowWrapperComponent3 extends import3.AppView {
+class View_DataTableRowWrapperComponent3 extends import2.AppView {
_text_0:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement) {
- super(_View_DataTableRowWrapperComponent3,renderType_DataTableRowWrapperComponent,import7.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import9.ViewContainer) {
+ super(View_DataTableRowWrapperComponent3,renderType_DataTableRowWrapperComponent,import6.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
}
- createInternal(rootSelector:string):import5.AppElement {
+ createInternal(rootSelector:string):import7.ComponentRef {
this._text_0 = this.renderer.createText((null as any),'\n ',(null as any));
- this.init(([] as any[]).concat([this._text_0]),[this._text_0],([] as any[]),([] as any[]));
+ this.init(this._text_0,((this.renderer).directRenderer? (null as any): [this._text_0]),(null as any));
return (null as any);
}
-}
-function viewFactory_DataTableRowWrapperComponent3(viewUtils:import2.ViewUtils,parentInjector:import6.Injector,declarationEl:import5.AppElement):import3.AppView {
- return new _View_DataTableRowWrapperComponent3(viewUtils,parentInjector,declarationEl);
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._text_0,ctx);
+ }
}
\ No newline at end of file
diff --git a/release/components/body/body-row.component.ngfactory.ts b/release/components/body/body-row.component.ngfactory.ts
index e15ffff58..369b06e21 100644
--- a/release/components/body/body-row.component.ngfactory.ts
+++ b/release/components/body/body-row.component.ngfactory.ts
@@ -1,33 +1,34 @@
/**
- * This file is generated by the Angular 2 template compiler.
+ * @fileoverview This file is generated by the Angular 2 template compiler.
* Do not edit.
+ * @suppress {suspiciousCode,uselessCode,missingProperties}
*/
/* tslint:disable */
import * as import0 from '../../../../src/components/body/body-row.component';
import * as import1 from '@angular/core/src/change_detection/change_detection';
-import * as import2 from '@angular/core/src/linker/view_utils';
-import * as import3 from '@angular/core/src/linker/view';
+import * as import2 from '@angular/core/src/linker/view';
+import * as import3 from '@angular/core/src/linker/view_utils';
import * as import4 from '@angular/core/src/security';
import * as import5 from '@angular/core/src/render/api';
-import * as import6 from '@angular/core/src/linker/element';
-import * as import7 from '@angular/core/src/di/injector';
-import * as import8 from '@angular/core/src/linker/view_type';
+import * as import6 from '@angular/core/src/metadata/view';
+import * as import7 from '@angular/core/src/linker/view_type';
+import * as import8 from '@angular/core/src/linker/component_factory';
import * as import9 from '@angular/core/src/linker/element_ref';
-import * as import10 from '@angular/core/src/metadata/view';
-import * as import11 from '@angular/core/src/linker/component_factory';
-import * as import12 from '../../../node_modules/@angular/common/src/directives/ng_for.ngfactory';
-import * as import13 from '@angular/core/src/linker/template_ref';
-import * as import14 from '@angular/core/src/change_detection/differs/iterable_differs';
-import * as import15 from '@angular/common/src/directives/ng_for';
-import * as import16 from '../../../node_modules/@angular/common/src/directives/ng_style.ngfactory';
-import * as import17 from '@angular/core/src/change_detection/differs/keyvalue_differs';
-import * as import18 from '@angular/common/src/directives/ng_style';
+import * as import10 from '@angular/core/src/linker/view_container';
+import * as import11 from '../../../node_modules/@angular/common/src/directives/ng_for.ngfactory';
+import * as import12 from '@angular/core/src/linker/template_ref';
+import * as import13 from '@angular/core/src/change_detection/differs/iterable_differs';
+import * as import14 from '@angular/common/src/directives/ng_for';
+import * as import15 from '../../../node_modules/@angular/common/src/directives/ng_style.ngfactory';
+import * as import16 from '@angular/core/src/change_detection/differs/keyvalue_differs';
+import * as import17 from '@angular/common/src/directives/ng_style';
+import * as import18 from '../../../../src/components/body/body-cell.component';
import * as import19 from './body-cell.component.ngfactory';
-import * as import20 from '../../../../src/components/body/body-cell.component';
export class Wrapper_DataTableBodyRowComponent {
+ /*private*/ _eventHandler:Function;
context:import0.DataTableBodyRowComponent;
- changed:boolean;
+ /*private*/ _changed:boolean;
/*private*/ _expr_0:any;
/*private*/ _expr_1:any;
/*private*/ _expr_2:any;
@@ -38,8 +39,9 @@ export class Wrapper_DataTableBodyRowComponent {
/*private*/ _expr_7:any;
/*private*/ _expr_8:any;
/*private*/ _expr_9:any;
+ subscription0:any;
constructor(p0:any,p1:any) {
- this.changed = false;
+ this._changed = false;
this.context = new import0.DataTableBodyRowComponent(p0,p1);
this._expr_0 = import1.UNINITIALIZED;
this._expr_1 = import1.UNINITIALIZED;
@@ -52,308 +54,301 @@ export class Wrapper_DataTableBodyRowComponent {
this._expr_8 = import1.UNINITIALIZED;
this._expr_9 = import1.UNINITIALIZED;
}
+ ngOnDetach(view:import2.AppView,componentView:import2.AppView,el:any):void {
+ }
+ ngOnDestroy():void {
+ (this.subscription0 && this.subscription0.unsubscribe());
+ }
check_columns(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_0,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_0,currValue))) {
+ this._changed = true;
this.context.columns = currValue;
this._expr_0 = currValue;
}
}
check_innerWidth(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_1,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_1,currValue))) {
+ this._changed = true;
this.context.innerWidth = currValue;
this._expr_1 = currValue;
}
}
check_row(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_2,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_2,currValue))) {
+ this._changed = true;
this.context.row = currValue;
this._expr_2 = currValue;
}
}
check_offsetX(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_3,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_3,currValue))) {
+ this._changed = true;
this.context.offsetX = currValue;
this._expr_3 = currValue;
}
}
check_rowHeight(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_4,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_4,currValue))) {
+ this._changed = true;
this.context.rowHeight = currValue;
this._expr_4 = currValue;
}
}
check_isSelected(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_5,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_5,currValue))) {
+ this._changed = true;
this.context.isSelected = currValue;
this._expr_5 = currValue;
}
}
- detectChangesInInputProps(view:import3.AppView,el:any,throwOnChange:boolean):boolean {
- var changed:any = this.changed;
- this.changed = false;
+ ngDoCheck(view:import2.AppView,el:any,throwOnChange:boolean):boolean {
+ var changed:any = this._changed;
+ this._changed = false;
return changed;
}
- detectChangesInHostProps(view:import3.AppView,el:any,throwOnChange:boolean):void {
+ checkHost(view:import2.AppView,componentView:import2.AppView,el:any,throwOnChange:boolean):void {
const currVal_6:any = this.context.rowHeight;
- if (import2.checkBinding(throwOnChange,this._expr_6,currVal_6)) {
- view.renderer.setElementStyle(el,'height',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_6) == (null as any))? (null as any): (view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_6).toString() + 'px')));
+ if (import3.checkBinding(throwOnChange,this._expr_6,currVal_6)) {
+ view.renderer.setElementStyle(el,'height',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_6) == null)? (null as any): (view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_6).toString() + 'px')));
this._expr_6 = currVal_6;
}
const currVal_7:any = this.context.isSelected;
- if (import2.checkBinding(throwOnChange,this._expr_7,currVal_7)) {
+ if (import3.checkBinding(throwOnChange,this._expr_7,currVal_7)) {
view.renderer.setElementClass(el,'active',currVal_7);
this._expr_7 = currVal_7;
}
const currVal_8:any = this.context.isEvenRow;
- if (import2.checkBinding(throwOnChange,this._expr_8,currVal_8)) {
+ if (import3.checkBinding(throwOnChange,this._expr_8,currVal_8)) {
view.renderer.setElementClass(el,'datatable-row-even',currVal_8);
this._expr_8 = currVal_8;
}
const currVal_9:any = this.context.isOddRow;
- if (import2.checkBinding(throwOnChange,this._expr_9,currVal_9)) {
+ if (import3.checkBinding(throwOnChange,this._expr_9,currVal_9)) {
view.renderer.setElementClass(el,'datatable-row-odd',currVal_9);
this._expr_9 = currVal_9;
}
}
+ handleEvent(eventName:string,$event:any):boolean {
+ var result:boolean = true;
+ if ((eventName == 'keydown')) {
+ const pd_sub_0:any = ((this.context.onKeyDown($event)) !== false);
+ result = (pd_sub_0 && result);
+ }
+ return result;
+ }
+ subscribe(view:import2.AppView,_eventHandler:any,emit0:boolean):void {
+ this._eventHandler = _eventHandler;
+ if (emit0) { (this.subscription0 = this.context.activate.subscribe(_eventHandler.bind(view,'activate'))); }
+ }
}
-var renderType_DataTableBodyRowComponent_Host:import5.RenderComponentType = (null as any);
-class _View_DataTableBodyRowComponent_Host0 extends import3.AppView {
+var renderType_DataTableBodyRowComponent_Host:import5.RenderComponentType = import3.createRenderComponentType('',0,import6.ViewEncapsulation.None,([] as any[]),{});
+class View_DataTableBodyRowComponent_Host0 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _DataTableBodyRowComponent_0_4:Wrapper_DataTableBodyRowComponent;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyRowComponent_Host0,renderType_DataTableBodyRowComponent_Host,import8.ViewType.HOST,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.selectOrCreateRenderHostElement(this.renderer,'datatable-body-row',import2.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = viewFactory_DataTableBodyRowComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._DataTableBodyRowComponent_0_4 = new Wrapper_DataTableBodyRowComponent(new import9.ElementRef(this._el_0),this.renderer);
- this._appEl_0.initComponent(this._DataTableBodyRowComponent_0_4.context,([] as any[]),compView_0);
- compView_0.create(this._DataTableBodyRowComponent_0_4.context,this.projectableNodes,(null as any));
- var disposable_0:Function = this.renderer.listen(this._el_0,'keydown',this.eventHandler(this._handle_keydown_0_0.bind(this)));
- this.init(([] as any[]).concat([this._el_0]),[this._el_0],[disposable_0],([] as any[]));
- return this._appEl_0;
+ compView_0:import2.AppView;
+ _DataTableBodyRowComponent_0_3:Wrapper_DataTableBodyRowComponent;
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableBodyRowComponent_Host0,renderType_DataTableBodyRowComponent_Host,import7.ViewType.HOST,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.selectOrCreateRenderHostElement(this.renderer,'datatable-body-row',import3.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
+ this.compView_0 = new View_DataTableBodyRowComponent0(this.viewUtils,this,0,this._el_0);
+ this._DataTableBodyRowComponent_0_3 = new Wrapper_DataTableBodyRowComponent(new import9.ElementRef(this._el_0),this.renderer);
+ this.compView_0.create(this._DataTableBodyRowComponent_0_3.context);
+ var disposable_0:Function = import3.subscribeToRenderElement(this,this._el_0,new import3.InlineArray2(2,'keydown',(null as any)),this.eventHandler(this.handleEvent_0));
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [this._el_0]),[disposable_0]);
+ return new import8.ComponentRef_(0,this,this._el_0,this._DataTableBodyRowComponent_0_3.context);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import0.DataTableBodyRowComponent) && (0 === requestNodeIndex))) { return this._DataTableBodyRowComponent_0_4.context; }
+ if (((token === import0.DataTableBodyRowComponent) && (0 === requestNodeIndex))) { return this._DataTableBodyRowComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- if (this._DataTableBodyRowComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._DataTableBodyRowComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ if (this._DataTableBodyRowComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this._DataTableBodyRowComponent_0_3.checkHost(this,this.compView_0,this._el_0,throwOnChange);
+ this.compView_0.detectChanges(throwOnChange);
}
- private _handle_keydown_0_0($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyRowComponent_0_4.context.onKeyDown($event)) !== false);
- return (true && pd_0_0);
+ destroyInternal():void {
+ this.compView_0.destroy();
+ this._DataTableBodyRowComponent_0_3.ngOnDestroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ handleEvent_0(eventName:string,$event:any):boolean {
+ this.compView_0.markPathToRootAsCheckOnce();
+ var result:boolean = true;
+ result = (this._DataTableBodyRowComponent_0_3.handleEvent(eventName,$event) && result);
+ return result;
}
}
-function viewFactory_DataTableBodyRowComponent_Host0(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- if ((renderType_DataTableBodyRowComponent_Host === (null as any))) { (renderType_DataTableBodyRowComponent_Host = viewUtils.createRenderComponentType('',0,import10.ViewEncapsulation.None,([] as any[]),{})); }
- return new _View_DataTableBodyRowComponent_Host0(viewUtils,parentInjector,declarationEl);
-}
-export const DataTableBodyRowComponentNgFactory:import11.ComponentFactory = new import11.ComponentFactory('datatable-body-row',viewFactory_DataTableBodyRowComponent_Host0,import0.DataTableBodyRowComponent);
+export const DataTableBodyRowComponentNgFactory:import8.ComponentFactory = new import8.ComponentFactory('datatable-body-row',View_DataTableBodyRowComponent_Host0,import0.DataTableBodyRowComponent);
const styles_DataTableBodyRowComponent:any[] = ([] as any[]);
-var renderType_DataTableBodyRowComponent:import5.RenderComponentType = (null as any);
-class _View_DataTableBodyRowComponent0 extends import3.AppView {
+var renderType_DataTableBodyRowComponent:import5.RenderComponentType = import3.createRenderComponentType('',0,import6.ViewEncapsulation.None,styles_DataTableBodyRowComponent,{});
+export class View_DataTableBodyRowComponent0 extends import2.AppView {
_text_0:any;
_anchor_1:any;
- /*private*/ _appEl_1:import6.AppElement;
+ /*private*/ _vc_1:import10.ViewContainer;
_TemplateRef_1_5:any;
- _NgFor_1_6:import12.Wrapper_NgFor;
+ _NgFor_1_6:import11.Wrapper_NgFor;
_text_2:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyRowComponent0,renderType_DataTableBodyRowComponent,import8.ViewType.COMPONENT,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckOnce);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableBodyRowComponent0,renderType_DataTableBodyRowComponent,import7.ViewType.COMPONENT,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckOnce);
}
- createInternal(rootSelector:string):import6.AppElement {
- const parentRenderNode:any = this.renderer.createViewRoot(this.declarationAppElement.nativeElement);
+ createInternal(rootSelector:string):import8.ComponentRef {
+ const parentRenderNode:any = this.renderer.createViewRoot(this.parentElement);
this._text_0 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
this._anchor_1 = this.renderer.createTemplateAnchor(parentRenderNode,(null as any));
- this._appEl_1 = new import6.AppElement(1,(null as any),this,this._anchor_1);
- this._TemplateRef_1_5 = new import13.TemplateRef_(this._appEl_1,viewFactory_DataTableBodyRowComponent1);
- this._NgFor_1_6 = new import12.Wrapper_NgFor(this._appEl_1.vcRef,this._TemplateRef_1_5,this.parentInjector.get(import14.IterableDiffers),this.ref);
+ this._vc_1 = new import10.ViewContainer(1,(null as any),this,this._anchor_1);
+ this._TemplateRef_1_5 = new import12.TemplateRef_(this,1,this._anchor_1);
+ this._NgFor_1_6 = new import11.Wrapper_NgFor(this._vc_1.vcRef,this._TemplateRef_1_5,this.parentView.injectorGet(import13.IterableDiffers,this.parentIndex),this.ref);
this._text_2 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this.init(([] as any[]),[
+ this.init((null as any),((this.renderer).directRenderer? (null as any): [
this._text_0,
this._anchor_1,
this._text_2
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import13.TemplateRef) && (1 === requestNodeIndex))) { return this._TemplateRef_1_5; }
- if (((token === import15.NgFor) && (1 === requestNodeIndex))) { return this._NgFor_1_6.context; }
+ if (((token === import12.TemplateRef) && (1 === requestNodeIndex))) { return this._TemplateRef_1_5; }
+ if (((token === import14.NgFor) && (1 === requestNodeIndex))) { return this._NgFor_1_6.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
const currVal_1_0_0:any = this.context.columnsByPin;
this._NgFor_1_6.check_ngForOf(currVal_1_0_0,throwOnChange,false);
- const currVal_1_0_1:any = ((this.context.$colGroup == (null as any))? (null as any): this.context.$colGroup.type);
+ const currVal_1_0_1:any = ((this.context.$colGroup == null)? (null as any): this.context.$colGroup.type);
this._NgFor_1_6.check_ngForTrackBy(currVal_1_0_1,throwOnChange,false);
- this._NgFor_1_6.detectChangesInInputProps(this,this._anchor_1,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ this._NgFor_1_6.ngDoCheck(this,this._anchor_1,throwOnChange);
+ this._vc_1.detectChangesInNestedViews(throwOnChange);
+ }
+ destroyInternal():void {
+ this._vc_1.destroyNestedViews();
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 1)) { return new View_DataTableBodyRowComponent1(this.viewUtils,this,1,this._anchor_1,this._vc_1); }
+ return (null as any);
}
}
-export function viewFactory_DataTableBodyRowComponent0(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- if ((renderType_DataTableBodyRowComponent === (null as any))) { (renderType_DataTableBodyRowComponent = viewUtils.createRenderComponentType('',0,import10.ViewEncapsulation.None,styles_DataTableBodyRowComponent,{})); }
- return new _View_DataTableBodyRowComponent0(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyRowComponent1 extends import3.AppView {
+class View_DataTableBodyRowComponent1 extends import2.AppView {
_el_0:any;
- _NgStyle_0_3:import16.Wrapper_NgStyle;
+ _NgStyle_0_3:import15.Wrapper_NgStyle;
_text_1:any;
_anchor_2:any;
- /*private*/ _appEl_2:import6.AppElement;
+ /*private*/ _vc_2:import10.ViewContainer;
_TemplateRef_2_5:any;
- _NgFor_2_6:import12.Wrapper_NgFor;
+ _NgFor_2_6:import11.Wrapper_NgFor;
_text_3:any;
/*private*/ _expr_8:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyRowComponent1,renderType_DataTableBodyRowComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import10.ViewContainer) {
+ super(View_DataTableBodyRowComponent1,renderType_DataTableBodyRowComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
this._expr_8 = import1.UNINITIALIZED;
}
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'div',import2.EMPTY_INLINE_ARRAY,(null as any));
- this._NgStyle_0_3 = new import16.Wrapper_NgStyle(this.parentInjector.get(import17.KeyValueDiffers),new import9.ElementRef(this._el_0),this.renderer);
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'div',import3.EMPTY_INLINE_ARRAY,(null as any));
+ this._NgStyle_0_3 = new import15.Wrapper_NgStyle(this.parentView.injectorGet(import16.KeyValueDiffers,this.parentIndex),new import9.ElementRef(this._el_0),this.renderer);
this._text_1 = this.renderer.createText(this._el_0,'\n ',(null as any));
this._anchor_2 = this.renderer.createTemplateAnchor(this._el_0,(null as any));
- this._appEl_2 = new import6.AppElement(2,0,this,this._anchor_2);
- this._TemplateRef_2_5 = new import13.TemplateRef_(this._appEl_2,viewFactory_DataTableBodyRowComponent2);
- this._NgFor_2_6 = new import12.Wrapper_NgFor(this._appEl_2.vcRef,this._TemplateRef_2_5,this.parentInjector.get(import14.IterableDiffers),this.parent.ref);
+ this._vc_2 = new import10.ViewContainer(2,0,this,this._anchor_2);
+ this._TemplateRef_2_5 = new import12.TemplateRef_(this,2,this._anchor_2);
+ this._NgFor_2_6 = new import11.Wrapper_NgFor(this._vc_2.vcRef,this._TemplateRef_2_5,this.parentView.injectorGet(import13.IterableDiffers,this.parentIndex),this.parentView.ref);
this._text_3 = this.renderer.createText(this._el_0,'\n ',(null as any));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1,
this._anchor_2,
this._text_3
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import13.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
- if (((token === import15.NgFor) && (2 === requestNodeIndex))) { return this._NgFor_2_6.context; }
- if (((token === import18.NgStyle) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 3)))) { return this._NgStyle_0_3.context; }
+ if (((token === import12.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
+ if (((token === import14.NgFor) && (2 === requestNodeIndex))) { return this._NgFor_2_6.context; }
+ if (((token === import17.NgStyle) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 3)))) { return this._NgStyle_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_0_0_0:any = this.parent.context.stylesByGroup(this.context.$implicit.type);
+ const currVal_0_0_0:any = this.parentView.context.stylesByGroup(this.context.$implicit.type);
this._NgStyle_0_3.check_ngStyle(currVal_0_0_0,throwOnChange,false);
- this._NgStyle_0_3.detectChangesInInputProps(this,this._el_0,throwOnChange);
+ this._NgStyle_0_3.ngDoCheck(this,this._el_0,throwOnChange);
const currVal_2_0_0:any = this.context.$implicit.columns;
this._NgFor_2_6.check_ngForOf(currVal_2_0_0,throwOnChange,false);
- const currVal_2_0_1:any = ((this.parent.context.column == (null as any))? (null as any): this.parent.context.column.$$id);
+ const currVal_2_0_1:any = ((this.parentView.context.column == null)? (null as any): this.parentView.context.column.$$id);
this._NgFor_2_6.check_ngForTrackBy(currVal_2_0_1,throwOnChange,false);
- this._NgFor_2_6.detectChangesInInputProps(this,this._anchor_2,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- const currVal_8:any = import2.interpolate(1,'datatable-row-',this.context.$implicit.type,' datatable-row-group');
- if (import2.checkBinding(throwOnChange,this._expr_8,currVal_8)) {
+ this._NgFor_2_6.ngDoCheck(this,this._anchor_2,throwOnChange);
+ this._vc_2.detectChangesInNestedViews(throwOnChange);
+ const currVal_8:any = import3.inlineInterpolate(1,'datatable-row-',this.context.$implicit.type,' datatable-row-group');
+ if (import3.checkBinding(throwOnChange,this._expr_8,currVal_8)) {
this.renderer.setElementProperty(this._el_0,'className',currVal_8);
this._expr_8 = currVal_8;
}
- this._NgStyle_0_3.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this._vc_2.destroyNestedViews();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 2)) { return new View_DataTableBodyRowComponent2(this.viewUtils,this,2,this._anchor_2,this._vc_2); }
+ return (null as any);
}
}
-function viewFactory_DataTableBodyRowComponent1(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyRowComponent1(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyRowComponent2 extends import3.AppView {
+class View_DataTableBodyRowComponent2 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _DataTableBodyCellComponent_0_4:import19.Wrapper_DataTableBodyCellComponent;
+ compView_0:import2.AppView;
+ _DataTableBodyCellComponent_0_3:import19.Wrapper_DataTableBodyCellComponent;
_text_1:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyRowComponent2,renderType_DataTableBodyRowComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'datatable-body-cell',new import2.InlineArray2(2,'tabindex','-1'),(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = import19.viewFactory_DataTableBodyCellComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._DataTableBodyCellComponent_0_4 = new import19.Wrapper_DataTableBodyCellComponent(new import9.ElementRef(this._el_0),this.renderer);
- this._appEl_0.initComponent(this._DataTableBodyCellComponent_0_4.context,([] as any[]),compView_0);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import10.ViewContainer) {
+ super(View_DataTableBodyRowComponent2,renderType_DataTableBodyRowComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'datatable-body-cell',new import3.InlineArray2(2,'tabindex','-1'),(null as any));
+ this.compView_0 = new import19.View_DataTableBodyCellComponent0(this.viewUtils,this,0,this._el_0);
+ this._DataTableBodyCellComponent_0_3 = new import19.Wrapper_DataTableBodyCellComponent(new import9.ElementRef(this._el_0),this.renderer);
this._text_1 = this.renderer.createText((null as any),'\n ',(null as any));
- compView_0.create(this._DataTableBodyCellComponent_0_4.context,([] as any[]),(null as any));
- var disposable_0:Function = this.renderer.listen(this._el_0,'activate',this.eventHandler(this._handle_activate_0_0.bind(this)));
- var disposable_1:Function = this.renderer.listen(this._el_0,'focus',this.eventHandler(this._handle_focus_0_1.bind(this)));
- var disposable_2:Function = this.renderer.listen(this._el_0,'blur',this.eventHandler(this._handle_blur_0_2.bind(this)));
- var disposable_3:Function = this.renderer.listen(this._el_0,'click',this.eventHandler(this._handle_click_0_3.bind(this)));
- var disposable_4:Function = this.renderer.listen(this._el_0,'dblclick',this.eventHandler(this._handle_dblclick_0_4.bind(this)));
- var disposable_5:Function = this.renderer.listen(this._el_0,'keydown',this.eventHandler(this._handle_keydown_0_5.bind(this)));
- const subscription_0:any = this._DataTableBodyCellComponent_0_4.context.activate.subscribe(this.eventHandler(this._handle_activate_0_0.bind(this)));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.compView_0.create(this._DataTableBodyCellComponent_0_3.context);
+ var disposable_0:Function = import3.subscribeToRenderElement(this,this._el_0,new import3.InlineArray16(12,'activate',(null as any),'focus',(null as any),'blur',(null as any),'click',(null as any),'dblclick',(null as any),'keydown',(null as any)),this.eventHandler(this.handleEvent_0));
+ this._DataTableBodyCellComponent_0_3.subscribe(this,this.eventHandler(this.handleEvent_0),true);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1
]
- ,[
- disposable_0,
- disposable_1,
- disposable_2,
- disposable_3,
- disposable_4,
- disposable_5
- ]
- ,[subscription_0]);
+ ),[disposable_0]);
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import20.DataTableBodyCellComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 1)))) { return this._DataTableBodyCellComponent_0_4.context; }
+ if (((token === import18.DataTableBodyCellComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 1)))) { return this._DataTableBodyCellComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_0_0_0:any = this.parent.parent.context.row;
- this._DataTableBodyCellComponent_0_4.check_row(currVal_0_0_0,throwOnChange,false);
+ const currVal_0_0_0:any = this.parentView.parentView.context.row;
+ this._DataTableBodyCellComponent_0_3.check_row(currVal_0_0_0,throwOnChange,false);
const currVal_0_0_1:any = this.context.$implicit;
- this._DataTableBodyCellComponent_0_4.check_column(currVal_0_0_1,throwOnChange,false);
- const currVal_0_0_2:any = this.parent.parent.context.rowHeight;
- this._DataTableBodyCellComponent_0_4.check_rowHeight(currVal_0_0_2,throwOnChange,false);
- if (this._DataTableBodyCellComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._DataTableBodyCellComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
- }
- private _handle_activate_0_0($event:any):boolean {
- this.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this.parent.parent.context.onActivate($event,this.context.index)) !== false);
- return (true && pd_0_0);
- }
- private _handle_focus_0_1($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onFocus($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_blur_0_2($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onBlur($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_click_0_3($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onClick($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_dblclick_0_4($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onDblClick($event)) !== false);
- return (true && pd_0_0);
- }
- private _handle_keydown_0_5($event:any):boolean {
- this._appEl_0.componentView.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this._DataTableBodyCellComponent_0_4.context.onKeyDown($event)) !== false);
- return (true && pd_0_0);
+ this._DataTableBodyCellComponent_0_3.check_column(currVal_0_0_1,throwOnChange,false);
+ const currVal_0_0_2:any = this.parentView.parentView.context.rowHeight;
+ this._DataTableBodyCellComponent_0_3.check_rowHeight(currVal_0_0_2,throwOnChange,false);
+ if (this._DataTableBodyCellComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this._DataTableBodyCellComponent_0_3.checkHost(this,this.compView_0,this._el_0,throwOnChange);
+ this.compView_0.detectChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this.compView_0.destroy();
+ this._DataTableBodyCellComponent_0_3.ngOnDestroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ handleEvent_0(eventName:string,$event:any):boolean {
+ this.compView_0.markPathToRootAsCheckOnce();
+ var result:boolean = true;
+ result = (this._DataTableBodyCellComponent_0_3.handleEvent(eventName,$event) && result);
+ if ((eventName == 'activate')) {
+ const pd_sub_0:any = ((this.parentView.parentView.context.onActivate($event,this.context.index)) !== false);
+ result = (pd_sub_0 && result);
+ }
+ return result;
}
-}
-function viewFactory_DataTableBodyRowComponent2(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyRowComponent2(viewUtils,parentInjector,declarationEl);
}
\ No newline at end of file
diff --git a/release/components/body/body.component.js b/release/components/body/body.component.js
index c7b7ad63a..0518b5c83 100644
--- a/release/components/body/body.component.js
+++ b/release/components/body/body.component.js
@@ -327,7 +327,7 @@ var DataTableBodyComponent = (function () {
DataTableBodyComponent.decorators = [
{ type: core_1.Component, args: [{
selector: 'datatable-body',
- template: "\n \n \n \n \n \n \n \n \n \n \n
\n \n ",
+ template: "\n \n \n \n \n \n \n \n \n \n \n
\n \n ",
changeDetection: core_1.ChangeDetectionStrategy.OnPush
},] },
];
diff --git a/release/components/body/body.component.js.map b/release/components/body/body.component.js.map
index adab71cc6..b71e08578 100644
--- a/release/components/body/body.component.js.map
+++ b/release/components/body/body.component.js.map
@@ -1 +1 @@
-{"version":3,"file":"body.component.js","sourceRoot":"","sources":["../../../src/components/body/body.component.ts"],"names":[],"mappings":"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"}
\ No newline at end of file
+{"version":3,"file":"body.component.js","sourceRoot":"","sources":["../../../src/components/body/body.component.ts"],"names":[],"mappings":";AAAA,qBAGO,eAAe,CAAC,CAAA;AACvB,sBAA6E,aAAa,CAAC,CAAA;AAE3F,mCAAkC,sBAAsB,CAAC,CAAA;AAGzD;IA+HE,gCAAY,OAAmB,EAAE,QAAkB;QArHlD,aAAQ,GAAU,EAAE,CAAC;QAgFrB,WAAM,GAAsB,IAAI,mBAAY,EAAE,CAAC;QAC/C,SAAI,GAAsB,IAAI,mBAAY,EAAE,CAAC;QAC7C,aAAQ,GAAsB,IAAI,mBAAY,EAAE,CAAC;QACjD,WAAM,GAAsB,IAAI,mBAAY,EAAE,CAAC;QAC/C,iBAAY,GAAsB,IAAI,mBAAY,EAAE,CAAC;QAQ9C,oBAAe,GAAmB,IAAI,sBAAc,EAAE,CAAC;QACvD,SAAI,GAAU,EAAE,CAAC;QACjB,YAAO,GAAW,CAAC,CAAC;QACpB,YAAO,GAAQ,EAAE,CAAC;QAuBxB,QAAQ,CAAC,eAAe,CAAC,OAAO,CAAC,aAAa,EAAE,gBAAgB,EAAE,IAAI,CAAC,CAAC;QAExE,8DAA8D;QAC9D,IAAI,CAAC,aAAa,GAAG,UAAS,KAAa,EAAE,GAAQ;YACnD,EAAE,CAAA,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;gBACpB,MAAM,CAAI,GAAG,CAAC,OAAO,SAAI,IAAI,CAAC,WAAa,CAAC;YAC9C,CAAC;YAAC,IAAI,CAAC,CAAC;gBACN,MAAM,CAAC,GAAG,CAAC,OAAO,CAAC;YACrB,CAAC;QACH,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACf,CAAC;IA1HA,sBAAI,4CAAQ;aAKb;YACE,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC;QACxB,CAAC;aAPA,UAAa,GAAW;YACvB,IAAI,CAAC,SAAS,GAAG,GAAG,CAAC;YACrB,IAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC;;;OAAA;IAMA,sBAAI,wCAAI;aAKT;YACE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;QACpB,CAAC;aAPA,UAAS,GAAU;YAClB,IAAI,CAAC,KAAK,GAAG,GAAG,CAAC;YACjB,IAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC;;;OAAA;IAMA,sBAAI,2CAAO;aAOZ;YACE,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC;QACvB,CAAC;aATA,UAAY,GAAU;YACrB,IAAI,CAAC,QAAQ,GAAG,GAAG,CAAC;YAEpB,IAAM,SAAS,GAAG,oBAAY,CAAC,GAAG,CAAC,CAAC;YACpC,IAAI,CAAC,iBAAiB,GAAG,yBAAiB,CAAC,SAAS,EAAE,GAAG,CAAC,CAAC;QAC7D,CAAC;;;OAAA;IAMA,sBAAI,0CAAM;aAKX;YACE,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC;QACtB,CAAC;aAPA,UAAW,GAAW;YACrB,IAAI,CAAC,OAAO,GAAG,GAAG,CAAC;YACnB,IAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC;;;OAAA;IAMA,sBAAI,4CAAQ;aAKb;YACE,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC;QACxB,CAAC;aAPA,UAAa,GAAW;YACvB,IAAI,CAAC,SAAS,GAAG,GAAG,CAAC;YACrB,IAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC;;;OAAA;IASD,sBAAI,6CAAS;aAAb;YACE,EAAE,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;gBACpB,MAAM,CAAC,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;YAChC,CAAC;YAAC,IAAI,CAAC,CAAC;gBACN,MAAM,CAAC,MAAM,CAAC;YAChB,CAAC;QACH,CAAC;;;OAAA;IAID,sBAAI,8CAAU;aAUd;YACE,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC;QAC1B,CAAC;aAZD,UAAe,GAAG;YAChB,EAAE,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;gBACpB,IAAI,CAAC,WAAW,GAAG,GAAG,GAAG,IAAI,CAAC;YAChC,CAAC;YAAC,IAAI,CAAC,CAAC;gBACN,IAAI,CAAC,WAAW,GAAG,MAAM,CAAC;YAC5B,CAAC;YAED,IAAI,CAAC,YAAY,EAAE,CAAC;QACtB,CAAC;;;OAAA;IAcD,sBAAI,iDAAa;aAAjB;YACE,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC;QAC9B,CAAC;;;OAAA;IAqBD,sBAAI,gDAAY;QALhB;;;;WAIG;aACH;YACE,EAAE,CAAA,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;gBACnB,MAAM,CAAC,IAAI,CAAC,eAAe,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAC,CAAC;YACvD,CAAC;QACH,CAAC;;;OAAA;IAeD,8CAAa,GAAb,UAAc,MAAe;QAC3B,EAAE,CAAA,CAAC,IAAI,CAAC,UAAU,IAAI,MAAM,CAAC,CAAC,CAAC;YAC7B,mDAAmD;YACnD,IAAM,QAAQ,GAAG,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC;YACxC,MAAM,GAAG,IAAI,CAAC,eAAe,CAAC,KAAK,CAAC,QAAQ,GAAG,CAAC,CAAC,CAAC;QACpD,CAAC;QAED,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC;IACvC,CAAC;IAED,6CAAY,GAAZ,UAAa,EAAqC;YAAnC,0BAAU,EAAE,0BAAU,EAAE,wBAAS;QAC9C,mCAAmC;QACnC,gDAAgD;QAChD,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,KAAK,UAAU,IAAI,IAAI,CAAC,OAAO,KAAK,UAAU,CAAC,CAAC,CAAC;YAC9D,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;gBACf,OAAO,EAAE,UAAU;gBACnB,OAAO,EAAE,UAAU;aACpB,CAAC,CAAC;QACL,CAAC;QAED,IAAI,CAAC,OAAO,GAAG,UAAU,CAAC;QAC1B,IAAI,CAAC,OAAO,GAAG,UAAU,CAAC;QAE1B,IAAI,CAAC,aAAa,EAAE,CAAC;QACrB,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;QAC3B,IAAI,CAAC,UAAU,EAAE,CAAC;IACpB,CAAC;IAED,2CAAU,GAAV,UAAW,SAAS;QAClB,IAAI,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,GAAG,IAAI,CAAC,QAAQ,CAAC;QAEhD,EAAE,CAAA,CAAC,SAAS,KAAK,IAAI,CAAC,CAAC,CAAC;YACtB,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QAC9B,CAAC;QAAC,IAAI,CAAC,EAAE,CAAA,CAAC,SAAS,KAAK,MAAM,CAAC,CAAC,CAAC;YAC/B,MAAM,GAAG,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAC7B,CAAC;QAED,EAAE,CAAA,CAAC,SAAS,KAAK,SAAS,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;YAC7C,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,cAAM,EAAE,CAAC,CAAC;QAC7B,CAAC;IACH,CAAC;IAED,2CAAU,GAAV;QACE,IAAA,iBAAoC,EAA5B,gBAAK,EAAE,cAAI,CAAkB;QACrC,IAAI,QAAQ,GAAG,KAAK,CAAC;QACrB,IAAI,GAAG,GAAG,CAAC,CAAC;QACZ,IAAI,IAAI,GAAG,EAAE,CAAC;QAEd,OAAO,QAAQ,GAAG,IAAI,IAAI,QAAQ,GAAG,IAAI,CAAC,QAAQ,EAAE,CAAC;YACnD,IAAI,GAAG,GAAG,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;YAE9B,EAAE,CAAA,CAAC,GAAG,CAAC,CAAC,CAAC;gBACP,GAAG,CAAC,OAAO,GAAG,QAAQ,CAAC;gBACvB,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC;YAClB,CAAC;YAED,GAAG,EAAE,CAAC;YACN,QAAQ,EAAE,CAAC;QACb,CAAC;QAED,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;IACnB,CAAC;IAED;;;;;OAKG;IACH,6CAAY,GAAZ,UAAa,GAAQ;QACnB,4CAA4C;QAC5C,MAAM,CAAC,IAAI,CAAC,SAAS;YACnB,CAAC,GAAG,CAAC,UAAU,KAAK,CAAC,GAAG,IAAI,CAAC,eAAe,GAAG,CAAC,CAAC,CAAC;IACtD,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,8CAAa,GAAb,UAAc,GAAG;QACf,IAAM,SAAS,GAAG,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC;QAEzC,IAAI,MAAM,GAAG;YACX,MAAM,EAAE,SAAS,GAAG,IAAI;SACzB,CAAC;QAEF,EAAE,CAAA,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;YACnB,IAAM,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC,OAAO,GAAG,CAAC,CAAC;YAElC,+BAA+B;YAC/B,+DAA+D;YAC/D,mCAAmC;YACnC,IAAM,GAAG,GAAG,IAAI,CAAC,eAAe,CAAC,KAAK,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC;YAEhD,mBAAW,CAAC,MAAM,EAAE,CAAC,EAAE,GAAG,CAAC,CAAC;QAC9B,CAAC;QAED,MAAM,CAAC,MAAM,CAAC;IAChB,CAAC;IAED,8CAAa,GAAb;QAAA,iBAEC;QADC,UAAU,CAAC,cAAM,OAAA,KAAI,CAAC,gBAAgB,GAAG,KAAK,EAA7B,CAA6B,EAAE,GAAG,CAAC,CAAC;IACvD,CAAC;IAED,8CAAa,GAAb;QACE,IAAI,KAAK,GAAG,CAAC,CAAC;QACd,IAAI,IAAI,GAAG,CAAC,CAAC;QAEb,EAAE,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;YACpB,uEAAuE;YACvE,iEAAiE;YACjE,+CAA+C;YAC/C,IAAM,MAAM,GAAG,QAAQ,CAAC,IAAI,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;YAC5C,KAAK,GAAG,IAAI,CAAC,eAAe,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YACvD,IAAI,GAAG,IAAI,CAAC,eAAe,CAAC,WAAW,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QACrE,CAAC;QAAC,IAAI,CAAC,CAAC;YACN,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;YACjD,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,KAAK,GAAG,IAAI,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC1D,CAAC;QAED,IAAI,CAAC,OAAO,GAAG,EAAE,YAAK,EAAE,UAAI,EAAE,CAAC;IACjC,CAAC;IAED;;;OAGG;IACH,sDAAqB,GAArB;QACE,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC;YAAC,MAAM,CAAC;QAE5B,0DAA0D;QAC1D,8DAA8D;QAC9D,yBAAyB;QACzB,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;QAElC,8DAA8D;QAC9D,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;YAClC,IAAI,CAAC,eAAe,CAAC,SAAS,CAC5B,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,eAAe,CAAC,CAAC;QACrD,CAAC;IACH,CAAC;IAED,yDAAwB,GAAxB;QACE,0EAA0E;QAC1E,qFAAqF;QACrF,eAAe;QACf,IAAI,qBAAqB,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC;QAE/C,EAAE,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;YACpB,IAAM,YAAY,GAAG,IAAI,CAAC,eAAe,CAAC,KAAK,CAAC,qBAAqB,GAAG,CAAC,CAAC,CAAC;YAC3E,MAAM,CAAC,YAAY,IAAI,IAAI,CAAC,OAAO,GAAG,qBAAqB,GAAG,CAAC,GAAG,qBAAqB,CAAC;QAC1F,CAAC;QAED,MAAM,CAAC,qBAAqB,CAAC;IAC/B,CAAC;IAED;;;;;;;OAOG;IACH,mDAAkB,GAAlB,UAAmB,GAAQ;QACzB,0EAA0E;QAC1E,IAAI,qBAAqB,GAAG,IAAI,CAAC,wBAAwB,EAAE,CAAC;QAE5D,4EAA4E;QAC5E,EAAE,CAAA,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;YACnB,IAAM,eAAe,GAAG,IAAI,CAAC,eAAe,GAAG,CAAC,GAAG,CAAC,UAAU,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;YACzE,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,GAAG,CAAC,OAAO,EAAE,eAAe,CAAC,CAAC;QAC5D,CAAC;QAED,8DAA8D;QAC9D,GAAG,CAAC,UAAU,IAAI,CAAC,CAAC;QAEpB,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC;YACrB,IAAI,EAAE,CAAC,GAAG,CAAC;YACX,YAAY,EAAE,qBAAqB;SACpC,CAAC,CAAC;IACL,CAAC;IAED;;;OAGG;IACH,8CAAa,GAAb,UAAc,QAAiB;QAC7B,IAAI,WAAW,GAAG,QAAQ,GAAG,CAAC,GAAG,CAAC,CAAC;QAEnC,0EAA0E;QAC1E,IAAI,qBAAqB,GAAG,IAAI,CAAC,wBAAwB,EAAE,CAAC;QAE5D,GAAG,CAAA,CAAY,UAAS,EAAT,KAAA,IAAI,CAAC,IAAI,EAAT,cAAS,EAAT,IAAS,CAAC;YAArB,IAAI,GAAG,SAAA;YACT,GAAG,CAAC,UAAU,GAAG,WAAW,CAAC;SAC9B;QAED,EAAE,CAAA,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC;YACnB,mEAAmE;YACnE,IAAI,CAAC,qBAAqB,EAAE,CAAC;QAC/B,CAAC;QAED,yCAAyC;QACzC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC;YACrB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,YAAY,EAAE,qBAAqB;SACpC,CAAC,CAAC;IACL,CAAC;IAED,6CAAY,GAAZ;QACE,IAAI,CAAC,qBAAqB,EAAE,CAAC;QAC7B,IAAI,CAAC,aAAa,EAAE,CAAC;QACrB,IAAI,CAAC,UAAU,EAAE,CAAC;IACpB,CAAC;IAEI,iCAAU,GAA0B;QAC3C,EAAE,IAAI,EAAE,gBAAS,EAAE,IAAI,EAAE,CAAC;oBACxB,QAAQ,EAAE,gBAAgB;oBAC1B,QAAQ,EAAE,2mDA8CT;oBACD,eAAe,EAAE,8BAAuB,CAAC,MAAM;iBAChD,EAAG,EAAE;KACL,CAAC;IACF,kBAAkB;IACX,qCAAc,GAA6D;QAClF,EAAC,IAAI,EAAE,iBAAU,GAAG;QACpB,EAAC,IAAI,EAAE,eAAQ,GAAG;KACjB,CAAC;IACK,qCAAc,GAA2C;QAChE,YAAY,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAChC,YAAY,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAChC,kBAAkB,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACtC,WAAW,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC/B,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC7B,iBAAiB,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACrC,cAAc,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAClC,eAAe,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACnC,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC9B,aAAa,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACjC,mBAAmB,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACvC,aAAa,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACjC,aAAa,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QACjC,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC9B,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC1B,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC7B,QAAQ,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC5B,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC9B,YAAY,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAChC,WAAW,EAAE,CAAC,EAAE,IAAI,EAAE,kBAAW,EAAE,IAAI,EAAE,CAAC,aAAa,EAAG,EAAE,EAAE;QAC9D,YAAY,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAC,EAAE,IAAI,EAAE,kBAAW,EAAE,IAAI,EAAE,CAAC,cAAc,EAAG,EAAE,EAAE;QAChF,QAAQ,EAAE,CAAC,EAAE,IAAI,EAAE,aAAM,EAAE,EAAE;QAC7B,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,aAAM,EAAE,EAAE;QAC3B,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,aAAM,EAAE,EAAE;QAC/B,QAAQ,EAAE,CAAC,EAAE,IAAI,EAAE,aAAM,EAAE,EAAE;QAC7B,cAAc,EAAE,CAAC,EAAE,IAAI,EAAE,aAAM,EAAE,EAAE;QACnC,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,gBAAS,EAAE,IAAI,EAAE,CAAC,sCAAiB,EAAG,EAAE,EAAE;KAC9D,CAAC;IACF,6BAAC;AAAD,CAAC,AAxcD,IAwcC;AAxcY,8BAAsB,yBAwclC,CAAA"}
\ No newline at end of file
diff --git a/release/components/body/body.component.metadata.json b/release/components/body/body.component.metadata.json
index eee01f137..cbd10bc93 100644
--- a/release/components/body/body.component.metadata.json
+++ b/release/components/body/body.component.metadata.json
@@ -1 +1 @@
-{"__symbolic":"module","version":1,"metadata":{"DataTableBodyComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component"},"arguments":[{"selector":"datatable-body","template":"\n \n \n \n \n \n \n \n \n \n \n
\n \n ","changeDetection":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectionStrategy"},"member":"OnPush"}}]}],"members":{"scrollbarV":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"scrollbarH":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"loadingIndicator":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowHeight":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"offsetX":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"detailRowHeight":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"emptyMessage":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"selectionType":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"selected":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowIdentity":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowDetailTemplate":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"selectCheck":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"trackByProp":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"pageSize":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rows":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"columns":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"offset":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowCount":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"innerWidth":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"bodyWidth":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostBinding"},"arguments":["style.width"]}]}],"bodyHeight":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostBinding"},"arguments":["style.height"]}]}],"scroll":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"page":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"activate":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"select":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"detailToggle":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"scroller":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"ViewChild"},"arguments":[{"__symbolic":"reference","module":"./scroller.component","name":"ScrollerComponent"}]}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"},{"__symbolic":"reference","module":"@angular/core","name":"Renderer"}]}],"updateOffsetY":[{"__symbolic":"method"}],"onBodyScroll":[{"__symbolic":"method"}],"updatePage":[{"__symbolic":"method"}],"updateRows":[{"__symbolic":"method"}],"getRowHeight":[{"__symbolic":"method"}],"getRowsStyles":[{"__symbolic":"method"}],"hideIndicator":[{"__symbolic":"method"}],"updateIndexes":[{"__symbolic":"method"}],"refreshRowHeightCache":[{"__symbolic":"method"}],"getAdjustedViewPortIndex":[{"__symbolic":"method"}],"toggleRowExpansion":[{"__symbolic":"method"}],"toggleAllRows":[{"__symbolic":"method"}],"recalcLayout":[{"__symbolic":"method"}]}}}}
\ No newline at end of file
+{"__symbolic":"module","version":1,"metadata":{"DataTableBodyComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component"},"arguments":[{"selector":"datatable-body","template":"\n \n \n \n \n \n \n \n \n \n \n
\n \n ","changeDetection":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectionStrategy"},"member":"OnPush"}}]}],"members":{"scrollbarV":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"scrollbarH":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"loadingIndicator":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowHeight":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"offsetX":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"detailRowHeight":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"emptyMessage":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"selectionType":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"selected":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowIdentity":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowDetailTemplate":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"selectCheck":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"trackByProp":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"pageSize":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rows":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"columns":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"offset":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"rowCount":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"innerWidth":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"bodyWidth":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostBinding"},"arguments":["style.width"]}]}],"bodyHeight":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostBinding"},"arguments":["style.height"]}]}],"scroll":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"page":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"activate":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"select":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"detailToggle":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output"}}]}],"scroller":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"ViewChild"},"arguments":[{"__symbolic":"reference","module":"./scroller.component","name":"ScrollerComponent"}]}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ElementRef"},{"__symbolic":"reference","module":"@angular/core","name":"Renderer"}]}],"updateOffsetY":[{"__symbolic":"method"}],"onBodyScroll":[{"__symbolic":"method"}],"updatePage":[{"__symbolic":"method"}],"updateRows":[{"__symbolic":"method"}],"getRowHeight":[{"__symbolic":"method"}],"getRowsStyles":[{"__symbolic":"method"}],"hideIndicator":[{"__symbolic":"method"}],"updateIndexes":[{"__symbolic":"method"}],"refreshRowHeightCache":[{"__symbolic":"method"}],"getAdjustedViewPortIndex":[{"__symbolic":"method"}],"toggleRowExpansion":[{"__symbolic":"method"}],"toggleAllRows":[{"__symbolic":"method"}],"recalcLayout":[{"__symbolic":"method"}]}}}}
\ No newline at end of file
diff --git a/release/components/body/body.component.ngfactory.ts b/release/components/body/body.component.ngfactory.ts
index e0280463e..44c7bc422 100644
--- a/release/components/body/body.component.ngfactory.ts
+++ b/release/components/body/body.component.ngfactory.ts
@@ -1,44 +1,45 @@
/**
- * This file is generated by the Angular 2 template compiler.
+ * @fileoverview This file is generated by the Angular 2 template compiler.
* Do not edit.
+ * @suppress {suspiciousCode,uselessCode,missingProperties}
*/
/* tslint:disable */
import * as import0 from '../../../../src/components/body/body.component';
import * as import1 from '@angular/core/src/change_detection/change_detection';
-import * as import2 from '@angular/core/src/linker/view_utils';
-import * as import3 from '@angular/core/src/linker/view';
+import * as import2 from '@angular/core/src/linker/view';
+import * as import3 from '@angular/core/src/linker/view_utils';
import * as import4 from '@angular/core/src/security';
import * as import5 from '@angular/core/src/render/api';
-import * as import6 from '@angular/core/src/linker/element';
-import * as import7 from '@angular/core/src/di/injector';
-import * as import8 from '@angular/core/src/linker/view_type';
+import * as import6 from '@angular/core/src/metadata/view';
+import * as import7 from '@angular/core/src/linker/view_type';
+import * as import8 from '@angular/core/src/linker/component_factory';
import * as import9 from '@angular/core/src/linker/element_ref';
-import * as import10 from '@angular/core/src/metadata/view';
-import * as import11 from '@angular/core/src/linker/component_factory';
-import * as import12 from '@angular/core/src/linker/query_list';
-import * as import13 from './selection.component.ngfactory';
+import * as import10 from '@angular/core/src/linker/query_list';
+import * as import11 from '../../../../src/components/body/selection.component';
+import * as import12 from './selection.component.ngfactory';
+import * as import13 from '@angular/core/src/linker/view_container';
import * as import14 from '../../../node_modules/@angular/common/src/directives/ng_if.ngfactory';
import * as import15 from '@angular/core/src/linker/template_ref';
import * as import16 from '@angular/common/src/directives/ng_if';
-import * as import17 from '../../../../src/components/body/selection.component';
+import * as import17 from '../../../../src/components/body/progress-bar.component';
import * as import18 from './progress-bar.component.ngfactory';
-import * as import19 from '../../../../src/components/body/progress-bar.component';
+import * as import19 from '../../../../src/components/body/scroller.component';
import * as import20 from './scroller.component.ngfactory';
import * as import21 from '../../../node_modules/@angular/common/src/directives/ng_for.ngfactory';
import * as import22 from '@angular/core/src/change_detection/differs/iterable_differs';
import * as import23 from '@angular/common/src/directives/ng_for';
-import * as import24 from '../../../../src/components/body/scroller.component';
+import * as import24 from '../../../../src/components/body/body-row-wrapper.component';
import * as import25 from '../../../node_modules/@angular/common/src/directives/ng_style.ngfactory';
import * as import26 from './body-row-wrapper.component.ngfactory';
-import * as import27 from './body-row.component.ngfactory';
-import * as import28 from '@angular/core/src/change_detection/differs/keyvalue_differs';
-import * as import29 from '../../../../src/components/body/body-row.component';
+import * as import27 from '../../../../src/components/body/body-row.component';
+import * as import28 from './body-row.component.ngfactory';
+import * as import29 from '@angular/core/src/change_detection/differs/keyvalue_differs';
import * as import30 from '@angular/common/src/directives/ng_style';
-import * as import31 from '../../../../src/components/body/body-row-wrapper.component';
export class Wrapper_DataTableBodyComponent {
+ /*private*/ _eventHandler:Function;
context:import0.DataTableBodyComponent;
- changed:boolean;
+ /*private*/ _changed:boolean;
/*private*/ _expr_0:any;
/*private*/ _expr_1:any;
/*private*/ _expr_2:any;
@@ -61,8 +62,13 @@ export class Wrapper_DataTableBodyComponent {
/*private*/ _expr_19:any;
/*private*/ _expr_20:any;
/*private*/ _expr_21:any;
+ subscription0:any;
+ subscription1:any;
+ subscription2:any;
+ subscription3:any;
+ subscription4:any;
constructor(p0:any,p1:any) {
- this.changed = false;
+ this._changed = false;
this.context = new import0.DataTableBodyComponent(p0,p1);
this._expr_0 = import1.UNINITIALIZED;
this._expr_1 = import1.UNINITIALIZED;
@@ -87,267 +93,275 @@ export class Wrapper_DataTableBodyComponent {
this._expr_20 = import1.UNINITIALIZED;
this._expr_21 = import1.UNINITIALIZED;
}
+ ngOnDetach(view:import2.AppView,componentView:import2.AppView,el:any):void {
+ }
+ ngOnDestroy():void {
+ (this.subscription0 && this.subscription0.unsubscribe());
+ (this.subscription1 && this.subscription1.unsubscribe());
+ (this.subscription2 && this.subscription2.unsubscribe());
+ (this.subscription3 && this.subscription3.unsubscribe());
+ (this.subscription4 && this.subscription4.unsubscribe());
+ }
check_scrollbarV(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_0,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_0,currValue))) {
+ this._changed = true;
this.context.scrollbarV = currValue;
this._expr_0 = currValue;
}
}
check_scrollbarH(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_1,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_1,currValue))) {
+ this._changed = true;
this.context.scrollbarH = currValue;
this._expr_1 = currValue;
}
}
check_loadingIndicator(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_2,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_2,currValue))) {
+ this._changed = true;
this.context.loadingIndicator = currValue;
this._expr_2 = currValue;
}
}
check_rowHeight(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_3,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_3,currValue))) {
+ this._changed = true;
this.context.rowHeight = currValue;
this._expr_3 = currValue;
}
}
check_offsetX(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_4,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_4,currValue))) {
+ this._changed = true;
this.context.offsetX = currValue;
this._expr_4 = currValue;
}
}
check_detailRowHeight(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_5,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_5,currValue))) {
+ this._changed = true;
this.context.detailRowHeight = currValue;
this._expr_5 = currValue;
}
}
check_emptyMessage(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_6,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_6,currValue))) {
+ this._changed = true;
this.context.emptyMessage = currValue;
this._expr_6 = currValue;
}
}
check_selectionType(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_7,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_7,currValue))) {
+ this._changed = true;
this.context.selectionType = currValue;
this._expr_7 = currValue;
}
}
check_selected(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_8,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_8,currValue))) {
+ this._changed = true;
this.context.selected = currValue;
this._expr_8 = currValue;
}
}
check_rowIdentity(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_9,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_9,currValue))) {
+ this._changed = true;
this.context.rowIdentity = currValue;
this._expr_9 = currValue;
}
}
check_rowDetailTemplate(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_10,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_10,currValue))) {
+ this._changed = true;
this.context.rowDetailTemplate = currValue;
this._expr_10 = currValue;
}
}
check_selectCheck(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_11,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_11,currValue))) {
+ this._changed = true;
this.context.selectCheck = currValue;
this._expr_11 = currValue;
}
}
check_trackByProp(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_12,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_12,currValue))) {
+ this._changed = true;
this.context.trackByProp = currValue;
this._expr_12 = currValue;
}
}
check_pageSize(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_13,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_13,currValue))) {
+ this._changed = true;
this.context.pageSize = currValue;
this._expr_13 = currValue;
}
}
check_rows(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_14,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_14,currValue))) {
+ this._changed = true;
this.context.rows = currValue;
this._expr_14 = currValue;
}
}
check_columns(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_15,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_15,currValue))) {
+ this._changed = true;
this.context.columns = currValue;
this._expr_15 = currValue;
}
}
check_offset(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_16,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_16,currValue))) {
+ this._changed = true;
this.context.offset = currValue;
this._expr_16 = currValue;
}
}
check_rowCount(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_17,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_17,currValue))) {
+ this._changed = true;
this.context.rowCount = currValue;
this._expr_17 = currValue;
}
}
check_innerWidth(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_18,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_18,currValue))) {
+ this._changed = true;
this.context.innerWidth = currValue;
this._expr_18 = currValue;
}
}
check_bodyHeight(currValue:any,throwOnChange:boolean,forceUpdate:boolean):void {
- if ((forceUpdate || import2.checkBinding(throwOnChange,this._expr_19,currValue))) {
- this.changed = true;
+ if ((forceUpdate || import3.checkBinding(throwOnChange,this._expr_19,currValue))) {
+ this._changed = true;
this.context.bodyHeight = currValue;
this._expr_19 = currValue;
}
}
- detectChangesInInputProps(view:import3.AppView,el:any,throwOnChange:boolean):boolean {
- var changed:any = this.changed;
- this.changed = false;
+ ngDoCheck(view:import2.AppView,el:any,throwOnChange:boolean):boolean {
+ var changed:any = this._changed;
+ this._changed = false;
return changed;
}
- detectChangesInHostProps(view:import3.AppView,el:any,throwOnChange:boolean):void {
+ checkHost(view:import2.AppView,componentView:import2.AppView,el:any,throwOnChange:boolean):void {
const currVal_20:any = this.context.bodyWidth;
- if (import2.checkBinding(throwOnChange,this._expr_20,currVal_20)) {
- view.renderer.setElementStyle(el,'width',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_20) == (null as any))? (null as any): view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_20).toString()));
+ if (import3.checkBinding(throwOnChange,this._expr_20,currVal_20)) {
+ view.renderer.setElementStyle(el,'width',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_20) == null)? (null as any): view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_20).toString()));
this._expr_20 = currVal_20;
}
const currVal_21:any = this.context.bodyHeight;
- if (import2.checkBinding(throwOnChange,this._expr_21,currVal_21)) {
- view.renderer.setElementStyle(el,'height',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_21) == (null as any))? (null as any): view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_21).toString()));
+ if (import3.checkBinding(throwOnChange,this._expr_21,currVal_21)) {
+ view.renderer.setElementStyle(el,'height',((view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_21) == null)? (null as any): view.viewUtils.sanitizer.sanitize(import4.SecurityContext.STYLE,currVal_21).toString()));
this._expr_21 = currVal_21;
}
}
+ handleEvent(eventName:string,$event:any):boolean {
+ var result:boolean = true;
+ return result;
+ }
+ subscribe(view:import2.AppView,_eventHandler:any,emit0:boolean,emit1:boolean,emit2:boolean,emit3:boolean,emit4:boolean):void {
+ this._eventHandler = _eventHandler;
+ if (emit0) { (this.subscription0 = this.context.scroll.subscribe(_eventHandler.bind(view,'scroll'))); }
+ if (emit1) { (this.subscription1 = this.context.page.subscribe(_eventHandler.bind(view,'page'))); }
+ if (emit2) { (this.subscription2 = this.context.activate.subscribe(_eventHandler.bind(view,'activate'))); }
+ if (emit3) { (this.subscription3 = this.context.select.subscribe(_eventHandler.bind(view,'select'))); }
+ if (emit4) { (this.subscription4 = this.context.detailToggle.subscribe(_eventHandler.bind(view,'detailToggle'))); }
+ }
}
-var renderType_DataTableBodyComponent_Host:import5.RenderComponentType = (null as any);
-class _View_DataTableBodyComponent_Host0 extends import3.AppView {
+var renderType_DataTableBodyComponent_Host:import5.RenderComponentType = import3.createRenderComponentType('',0,import6.ViewEncapsulation.None,([] as any[]),{});
+class View_DataTableBodyComponent_Host0 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _DataTableBodyComponent_0_4:Wrapper_DataTableBodyComponent;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyComponent_Host0,renderType_DataTableBodyComponent_Host,import8.ViewType.HOST,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.selectOrCreateRenderHostElement(this.renderer,'datatable-body',import2.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = viewFactory_DataTableBodyComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._DataTableBodyComponent_0_4 = new Wrapper_DataTableBodyComponent(new import9.ElementRef(this._el_0),this.renderer);
- this._appEl_0.initComponent(this._DataTableBodyComponent_0_4.context,([] as any[]),compView_0);
- compView_0.create(this._DataTableBodyComponent_0_4.context,this.projectableNodes,(null as any));
- this.init(([] as any[]).concat([this._el_0]),[this._el_0],([] as any[]),([] as any[]));
- return this._appEl_0;
+ compView_0:import2.AppView;
+ _DataTableBodyComponent_0_3:Wrapper_DataTableBodyComponent;
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableBodyComponent_Host0,renderType_DataTableBodyComponent_Host,import7.ViewType.HOST,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.selectOrCreateRenderHostElement(this.renderer,'datatable-body',import3.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
+ this.compView_0 = new View_DataTableBodyComponent0(this.viewUtils,this,0,this._el_0);
+ this._DataTableBodyComponent_0_3 = new Wrapper_DataTableBodyComponent(new import9.ElementRef(this._el_0),this.renderer);
+ this.compView_0.create(this._DataTableBodyComponent_0_3.context);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [this._el_0]),(null as any));
+ return new import8.ComponentRef_(0,this,this._el_0,this._DataTableBodyComponent_0_3.context);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import0.DataTableBodyComponent) && (0 === requestNodeIndex))) { return this._DataTableBodyComponent_0_4.context; }
+ if (((token === import0.DataTableBodyComponent) && (0 === requestNodeIndex))) { return this._DataTableBodyComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- if (this._DataTableBodyComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._DataTableBodyComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ if (this._DataTableBodyComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this._DataTableBodyComponent_0_3.checkHost(this,this.compView_0,this._el_0,throwOnChange);
+ this.compView_0.detectChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this.compView_0.destroy();
+ this._DataTableBodyComponent_0_3.ngOnDestroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
}
}
-function viewFactory_DataTableBodyComponent_Host0(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- if ((renderType_DataTableBodyComponent_Host === (null as any))) { (renderType_DataTableBodyComponent_Host = viewUtils.createRenderComponentType('',0,import10.ViewEncapsulation.None,([] as any[]),{})); }
- return new _View_DataTableBodyComponent_Host0(viewUtils,parentInjector,declarationEl);
-}
-export const DataTableBodyComponentNgFactory:import11.ComponentFactory = new import11.ComponentFactory('datatable-body',viewFactory_DataTableBodyComponent_Host0,import0.DataTableBodyComponent);
+export const DataTableBodyComponentNgFactory:import8.ComponentFactory = new import8.ComponentFactory('datatable-body',View_DataTableBodyComponent_Host0,import0.DataTableBodyComponent);
const styles_DataTableBodyComponent:any[] = ([] as any[]);
-var renderType_DataTableBodyComponent:import5.RenderComponentType = (null as any);
-class _View_DataTableBodyComponent0 extends import3.AppView {
- _viewQuery_ScrollerComponent_0:import12.QueryList;
+var renderType_DataTableBodyComponent:import5.RenderComponentType = import3.createRenderComponentType('',0,import6.ViewEncapsulation.None,styles_DataTableBodyComponent,{});
+export class View_DataTableBodyComponent0 extends import2.AppView {
+ _viewQuery_ScrollerComponent_0:import10.QueryList;
_text_0:any;
_el_1:any;
- /*private*/ _appEl_1:import6.AppElement;
- _DataTableSelectionComponent_1_4:import13.Wrapper_DataTableSelectionComponent;
+ compView_1:import2.AppView;
+ _DataTableSelectionComponent_1_3:import12.Wrapper_DataTableSelectionComponent;
_text_2:any;
_anchor_3:any;
- /*private*/ _appEl_3:import6.AppElement;
+ /*private*/ _vc_3:import13.ViewContainer;
_TemplateRef_3_5:any;
_NgIf_3_6:import14.Wrapper_NgIf;
_text_4:any;
_anchor_5:any;
- /*private*/ _appEl_5:import6.AppElement;
+ /*private*/ _vc_5:import13.ViewContainer;
_TemplateRef_5_5:any;
_NgIf_5_6:import14.Wrapper_NgIf;
_text_6:any;
_anchor_7:any;
- /*private*/ _appEl_7:import6.AppElement;
+ /*private*/ _vc_7:import13.ViewContainer;
_TemplateRef_7_5:any;
_NgIf_7_6:import14.Wrapper_NgIf;
_text_8:any;
_text_9:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyComponent0,renderType_DataTableBodyComponent,import8.ViewType.COMPONENT,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckOnce);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any) {
+ super(View_DataTableBodyComponent0,renderType_DataTableBodyComponent,import7.ViewType.COMPONENT,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckOnce);
}
- createInternal(rootSelector:string):import6.AppElement {
- const parentRenderNode:any = this.renderer.createViewRoot(this.declarationAppElement.nativeElement);
- this._viewQuery_ScrollerComponent_0 = new import12.QueryList();
+ createInternal(rootSelector:string):import8.ComponentRef {
+ const parentRenderNode:any = this.renderer.createViewRoot(this.parentElement);
+ this._viewQuery_ScrollerComponent_0 = new import10.QueryList();
this._text_0 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this._el_1 = import2.createRenderElement(this.renderer,parentRenderNode,'datatable-selection',import2.EMPTY_INLINE_ARRAY,(null as any));
- this._appEl_1 = new import6.AppElement(1,(null as any),this,this._el_1);
- var compView_1:any = import13.viewFactory_DataTableSelectionComponent0(this.viewUtils,this.injector(1),this._appEl_1);
- this._DataTableSelectionComponent_1_4 = new import13.Wrapper_DataTableSelectionComponent();
- this._appEl_1.initComponent(this._DataTableSelectionComponent_1_4.context,([] as any[]),compView_1);
+ this._el_1 = import3.createRenderElement(this.renderer,parentRenderNode,'datatable-selection',import3.EMPTY_INLINE_ARRAY,(null as any));
+ this.compView_1 = new import12.View_DataTableSelectionComponent0(this.viewUtils,this,1,this._el_1);
+ this._DataTableSelectionComponent_1_3 = new import12.Wrapper_DataTableSelectionComponent();
this._text_2 = this.renderer.createText((null as any),'\n ',(null as any));
this._anchor_3 = this.renderer.createTemplateAnchor((null as any),(null as any));
- this._appEl_3 = new import6.AppElement(3,1,this,this._anchor_3);
- this._TemplateRef_3_5 = new import15.TemplateRef_(this._appEl_3,viewFactory_DataTableBodyComponent1);
- this._NgIf_3_6 = new import14.Wrapper_NgIf(this._appEl_3.vcRef,this._TemplateRef_3_5);
+ this._vc_3 = new import13.ViewContainer(3,1,this,this._anchor_3);
+ this._TemplateRef_3_5 = new import15.TemplateRef_(this,3,this._anchor_3);
+ this._NgIf_3_6 = new import14.Wrapper_NgIf(this._vc_3.vcRef,this._TemplateRef_3_5);
this._text_4 = this.renderer.createText((null as any),'\n ',(null as any));
this._anchor_5 = this.renderer.createTemplateAnchor((null as any),(null as any));
- this._appEl_5 = new import6.AppElement(5,1,this,this._anchor_5);
- this._TemplateRef_5_5 = new import15.TemplateRef_(this._appEl_5,viewFactory_DataTableBodyComponent2);
- this._NgIf_5_6 = new import14.Wrapper_NgIf(this._appEl_5.vcRef,this._TemplateRef_5_5);
+ this._vc_5 = new import13.ViewContainer(5,1,this,this._anchor_5);
+ this._TemplateRef_5_5 = new import15.TemplateRef_(this,5,this._anchor_5);
+ this._NgIf_5_6 = new import14.Wrapper_NgIf(this._vc_5.vcRef,this._TemplateRef_5_5);
this._text_6 = this.renderer.createText((null as any),'\n ',(null as any));
this._anchor_7 = this.renderer.createTemplateAnchor((null as any),(null as any));
- this._appEl_7 = new import6.AppElement(7,1,this,this._anchor_7);
- this._TemplateRef_7_5 = new import15.TemplateRef_(this._appEl_7,viewFactory_DataTableBodyComponent4);
- this._NgIf_7_6 = new import14.Wrapper_NgIf(this._appEl_7.vcRef,this._TemplateRef_7_5);
+ this._vc_7 = new import13.ViewContainer(7,1,this,this._anchor_7);
+ this._TemplateRef_7_5 = new import15.TemplateRef_(this,7,this._anchor_7);
+ this._NgIf_7_6 = new import14.Wrapper_NgIf(this._vc_7.vcRef,this._TemplateRef_7_5);
this._text_8 = this.renderer.createText((null as any),'\n ',(null as any));
- compView_1.create(this._DataTableSelectionComponent_1_4.context,[([] as any[]).concat([
- this._text_2,
- this._appEl_3,
- this._text_4,
- this._appEl_5,
- this._text_6,
- this._appEl_7,
- this._text_8
- ]
- )],(null as any));
+ this.compView_1.create(this._DataTableSelectionComponent_1_3.context);
this._text_9 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- var disposable_0:Function = this.renderer.listen(this._el_1,'select',this.eventHandler(this._handle_select_1_0.bind(this)));
- var disposable_1:Function = this.renderer.listen(this._el_1,'activate',this.eventHandler(this._handle_activate_1_1.bind(this)));
- const subscription_0:any = this._DataTableSelectionComponent_1_4.context.activate.subscribe(this.eventHandler(this._handle_activate_1_1.bind(this)));
- const subscription_1:any = this._DataTableSelectionComponent_1_4.context.select.subscribe(this.eventHandler(this._handle_select_1_0.bind(this)));
- this.init(([] as any[]),[
+ var disposable_0:Function = import3.subscribeToRenderElement(this,this._el_1,new import3.InlineArray4(4,'select',(null as any),'activate',(null as any)),this.eventHandler(this.handleEvent_1));
+ this._DataTableSelectionComponent_1_3.subscribe(this,this.eventHandler(this.handleEvent_1),true,true);
+ this.init((null as any),((this.renderer).directRenderer? (null as any): [
this._text_0,
this._el_1,
this._text_2,
@@ -359,15 +373,7 @@ class _View_DataTableBodyComponent0 extends import3.AppView {
- return [nestedView._ScrollerComponent_0_4.context];
+ this._viewQuery_ScrollerComponent_0.reset([this._vc_5.mapNestedViews(View_DataTableBodyComponent2,(nestedView:View_DataTableBodyComponent2):any => {
+ return [nestedView._ScrollerComponent_0_3.context];
})]);
this.context.scroller = this._viewQuery_ScrollerComponent_0.first;
} }
}
- private _handle_select_1_0($event:any):boolean {
- this.markPathToRootAsCheckOnce();
- const pd_1_0:any = ((this.context.select.emit($event)) !== false);
- return (true && pd_1_0);
+ destroyInternal():void {
+ this._vc_3.destroyNestedViews();
+ this._vc_5.destroyNestedViews();
+ this._vc_7.destroyNestedViews();
+ this.compView_1.destroy();
+ this._DataTableSelectionComponent_1_3.ngOnDestroy();
+ }
+ visitProjectableNodesInternal(nodeIndex:number,ngContentIndex:number,cb:any,ctx:any):void {
+ if (((nodeIndex == 1) && (ngContentIndex == 0))) {
+ cb(this._text_2,ctx);
+ cb(this._vc_3.nativeElement,ctx);
+ this._vc_3.visitNestedViewRootNodes(cb,ctx);
+ cb(this._text_4,ctx);
+ cb(this._vc_5.nativeElement,ctx);
+ this._vc_5.visitNestedViewRootNodes(cb,ctx);
+ cb(this._text_6,ctx);
+ cb(this._vc_7.nativeElement,ctx);
+ this._vc_7.visitNestedViewRootNodes(cb,ctx);
+ cb(this._text_8,ctx);
+ }
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 3)) { return new View_DataTableBodyComponent1(this.viewUtils,this,3,this._anchor_3,this._vc_3); }
+ if ((nodeIndex == 5)) { return new View_DataTableBodyComponent2(this.viewUtils,this,5,this._anchor_5,this._vc_5); }
+ if ((nodeIndex == 7)) { return new View_DataTableBodyComponent4(this.viewUtils,this,7,this._anchor_7,this._vc_7); }
+ return (null as any);
}
- private _handle_activate_1_1($event:any):boolean {
+ handleEvent_1(eventName:string,$event:any):boolean {
this.markPathToRootAsCheckOnce();
- const pd_1_0:any = ((this.context.activate.emit($event)) !== false);
- return (true && pd_1_0);
+ var result:boolean = true;
+ if ((eventName == 'select')) {
+ const pd_sub_0:any = ((this.context.select.emit($event)) !== false);
+ result = (pd_sub_0 && result);
+ }
+ if ((eventName == 'activate')) {
+ const pd_sub_1:any = ((this.context.activate.emit($event)) !== false);
+ result = (pd_sub_1 && result);
+ }
+ return result;
}
}
-export function viewFactory_DataTableBodyComponent0(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- if ((renderType_DataTableBodyComponent === (null as any))) { (renderType_DataTableBodyComponent = viewUtils.createRenderComponentType('',0,import10.ViewEncapsulation.None,styles_DataTableBodyComponent,{})); }
- return new _View_DataTableBodyComponent0(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyComponent1 extends import3.AppView {
+class View_DataTableBodyComponent1 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _ProgressBarComponent_0_4:import18.Wrapper_ProgressBarComponent;
+ compView_0:import2.AppView;
+ _ProgressBarComponent_0_3:import18.Wrapper_ProgressBarComponent;
_text_1:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyComponent1,renderType_DataTableBodyComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'datatable-progress',import2.EMPTY_INLINE_ARRAY,(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = import18.viewFactory_ProgressBarComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._ProgressBarComponent_0_4 = new import18.Wrapper_ProgressBarComponent();
- this._appEl_0.initComponent(this._ProgressBarComponent_0_4.context,([] as any[]),compView_0);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import13.ViewContainer) {
+ super(View_DataTableBodyComponent1,renderType_DataTableBodyComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'datatable-progress',import3.EMPTY_INLINE_ARRAY,(null as any));
+ this.compView_0 = new import18.View_ProgressBarComponent0(this.viewUtils,this,0,this._el_0);
+ this._ProgressBarComponent_0_3 = new import18.Wrapper_ProgressBarComponent();
this._text_1 = this.renderer.createText((null as any),'\n ',(null as any));
- compView_0.create(this._ProgressBarComponent_0_4.context,([] as any[]),(null as any));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.compView_0.create(this._ProgressBarComponent_0_3.context);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import19.ProgressBarComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 1)))) { return this._ProgressBarComponent_0_4.context; }
+ if (((token === import17.ProgressBarComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 1)))) { return this._ProgressBarComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- if (this._ProgressBarComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._ProgressBarComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ if (this._ProgressBarComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this.compView_0.detectChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this.compView_0.destroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
}
}
-function viewFactory_DataTableBodyComponent1(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyComponent1(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyComponent2 extends import3.AppView {
+class View_DataTableBodyComponent2 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _ScrollerComponent_0_4:import20.Wrapper_ScrollerComponent;
+ compView_0:import2.AppView;
+ _ScrollerComponent_0_3:import20.Wrapper_ScrollerComponent;
_text_1:any;
_anchor_2:any;
- /*private*/ _appEl_2:import6.AppElement;
+ /*private*/ _vc_2:import13.ViewContainer;
_TemplateRef_2_5:any;
_NgFor_2_6:import21.Wrapper_NgFor;
_text_3:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyComponent2,renderType_DataTableBodyComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'datatable-scroller',import2.EMPTY_INLINE_ARRAY,(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = import20.viewFactory_ScrollerComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._ScrollerComponent_0_4 = new import20.Wrapper_ScrollerComponent(new import9.ElementRef(this._el_0));
- this._appEl_0.initComponent(this._ScrollerComponent_0_4.context,([] as any[]),compView_0);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import13.ViewContainer) {
+ super(View_DataTableBodyComponent2,renderType_DataTableBodyComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'datatable-scroller',import3.EMPTY_INLINE_ARRAY,(null as any));
+ this.compView_0 = new import20.View_ScrollerComponent0(this.viewUtils,this,0,this._el_0);
+ this._ScrollerComponent_0_3 = new import20.Wrapper_ScrollerComponent(new import9.ElementRef(this._el_0));
this._text_1 = this.renderer.createText((null as any),'\n ',(null as any));
this._anchor_2 = this.renderer.createTemplateAnchor((null as any),(null as any));
- this._appEl_2 = new import6.AppElement(2,0,this,this._anchor_2);
- this._TemplateRef_2_5 = new import15.TemplateRef_(this._appEl_2,viewFactory_DataTableBodyComponent3);
- this._NgFor_2_6 = new import21.Wrapper_NgFor(this._appEl_2.vcRef,this._TemplateRef_2_5,this.parent.parentInjector.get(import22.IterableDiffers),this.parent.ref);
+ this._vc_2 = new import13.ViewContainer(2,0,this,this._anchor_2);
+ this._TemplateRef_2_5 = new import15.TemplateRef_(this,2,this._anchor_2);
+ this._NgFor_2_6 = new import21.Wrapper_NgFor(this._vc_2.vcRef,this._TemplateRef_2_5,this.parentView.parentView.injectorGet(import22.IterableDiffers,this.parentView.parentIndex),this.parentView.ref);
this._text_3 = this.renderer.createText((null as any),'\n ',(null as any));
- compView_0.create(this._ScrollerComponent_0_4.context,[([] as any[]).concat([
- this._text_1,
- this._appEl_2,
- this._text_3
- ]
- )],(null as any));
- var disposable_0:Function = this.renderer.listen(this._el_0,'scroll',this.eventHandler(this._handle_scroll_0_0.bind(this)));
- const subscription_0:any = this._ScrollerComponent_0_4.context.scroll.subscribe(this.eventHandler(this._handle_scroll_0_0.bind(this)));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.compView_0.create(this._ScrollerComponent_0_3.context);
+ var disposable_0:Function = import3.subscribeToRenderElement(this,this._el_0,new import3.InlineArray2(2,'scroll',(null as any)),this.eventHandler(this.handleEvent_0));
+ this._ScrollerComponent_0_3.subscribe(this,this.eventHandler(this.handleEvent_0),true);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1,
this._anchor_2,
this._text_3
]
- ,[disposable_0],[subscription_0]);
+ ),[disposable_0]);
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
if (((token === import15.TemplateRef) && (2 === requestNodeIndex))) { return this._TemplateRef_2_5; }
if (((token === import23.NgFor) && (2 === requestNodeIndex))) { return this._NgFor_2_6.context; }
- if (((token === import24.ScrollerComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 3)))) { return this._ScrollerComponent_0_4.context; }
+ if (((token === import19.ScrollerComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 3)))) { return this._ScrollerComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_0_0_0:any = this.parent.context.scrollbarV;
- this._ScrollerComponent_0_4.check_scrollbarV(currVal_0_0_0,throwOnChange,false);
- const currVal_0_0_1:any = this.parent.context.scrollbarH;
- this._ScrollerComponent_0_4.check_scrollbarH(currVal_0_0_1,throwOnChange,false);
- const currVal_0_0_2:any = this.parent.context.scrollHeight;
- this._ScrollerComponent_0_4.check_scrollHeight(currVal_0_0_2,throwOnChange,false);
- const currVal_0_0_3:any = this.parent.context.columnGroupWidths.total;
- this._ScrollerComponent_0_4.check_scrollWidth(currVal_0_0_3,throwOnChange,false);
- if (this._ScrollerComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- const currVal_2_0_0:any = this.parent.context.temp;
+ const currVal_0_0_0:any = this.parentView.context.scrollbarV;
+ this._ScrollerComponent_0_3.check_scrollbarV(currVal_0_0_0,throwOnChange,false);
+ const currVal_0_0_1:any = this.parentView.context.scrollbarH;
+ this._ScrollerComponent_0_3.check_scrollbarH(currVal_0_0_1,throwOnChange,false);
+ const currVal_0_0_2:any = this.parentView.context.scrollHeight;
+ this._ScrollerComponent_0_3.check_scrollHeight(currVal_0_0_2,throwOnChange,false);
+ const currVal_0_0_3:any = this.parentView.context.columnGroupWidths.total;
+ this._ScrollerComponent_0_3.check_scrollWidth(currVal_0_0_3,throwOnChange,false);
+ if (this._ScrollerComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ const currVal_2_0_0:any = this.parentView.context.temp;
this._NgFor_2_6.check_ngForOf(currVal_2_0_0,throwOnChange,false);
- const currVal_2_0_1:any = this.parent.context.rowTrackingFn;
+ const currVal_2_0_1:any = this.parentView.context.rowTrackingFn;
this._NgFor_2_6.check_ngForTrackBy(currVal_2_0_1,throwOnChange,false);
- this._NgFor_2_6.detectChangesInInputProps(this,this._anchor_2,throwOnChange);
- this.detectContentChildrenChanges(throwOnChange);
- this._ScrollerComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ this._NgFor_2_6.ngDoCheck(this,this._anchor_2,throwOnChange);
+ this._vc_2.detectChangesInNestedViews(throwOnChange);
+ this._ScrollerComponent_0_3.checkHost(this,this.compView_0,this._el_0,throwOnChange);
+ this.compView_0.detectChanges(throwOnChange);
}
dirtyParentQueriesInternal():void {
- (<_View_DataTableBodyComponent0>this.parent)._viewQuery_ScrollerComponent_0.setDirty();
+ (this.parentView)._viewQuery_ScrollerComponent_0.setDirty();
}
destroyInternal():void {
- this._ScrollerComponent_0_4.context.ngOnDestroy();
+ this._vc_2.destroyNestedViews();
+ this.compView_0.destroy();
+ this._ScrollerComponent_0_3.ngOnDestroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ visitProjectableNodesInternal(nodeIndex:number,ngContentIndex:number,cb:any,ctx:any):void {
+ if (((nodeIndex == 0) && (ngContentIndex == 0))) {
+ cb(this._text_1,ctx);
+ cb(this._vc_2.nativeElement,ctx);
+ this._vc_2.visitNestedViewRootNodes(cb,ctx);
+ cb(this._text_3,ctx);
+ }
+ }
+ createEmbeddedViewInternal(nodeIndex:number):import2.AppView {
+ if ((nodeIndex == 2)) { return new View_DataTableBodyComponent3(this.viewUtils,this,2,this._anchor_2,this._vc_2); }
+ return (null as any);
}
- private _handle_scroll_0_0($event:any):boolean {
+ handleEvent_0(eventName:string,$event:any):boolean {
this.markPathToRootAsCheckOnce();
- const pd_0_0:any = ((this.parent.context.onBodyScroll($event)) !== false);
- return (true && pd_0_0);
+ var result:boolean = true;
+ if ((eventName == 'scroll')) {
+ const pd_sub_0:any = ((this.parentView.context.onBodyScroll($event)) !== false);
+ result = (pd_sub_0 && result);
+ }
+ return result;
}
}
-function viewFactory_DataTableBodyComponent2(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyComponent2(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyComponent3 extends import3.AppView {
+class View_DataTableBodyComponent3 extends import2.AppView {
_el_0:any;
- /*private*/ _appEl_0:import6.AppElement;
- _NgStyle_0_4:import25.Wrapper_NgStyle;
- _DataTableRowWrapperComponent_0_5:import26.Wrapper_DataTableRowWrapperComponent;
+ compView_0:import2.AppView;
+ _NgStyle_0_3:import25.Wrapper_NgStyle;
+ _DataTableRowWrapperComponent_0_4:import26.Wrapper_DataTableRowWrapperComponent;
_text_1:any;
_el_2:any;
- /*private*/ _appEl_2:import6.AppElement;
- _DataTableBodyRowComponent_2_4:import27.Wrapper_DataTableBodyRowComponent;
+ compView_2:import2.AppView;
+ _DataTableBodyRowComponent_2_3:import28.Wrapper_DataTableBodyRowComponent;
_text_3:any;
_text_4:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyComponent3,renderType_DataTableBodyComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
- }
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'datatable-row-wrapper',import2.EMPTY_INLINE_ARRAY,(null as any));
- this._appEl_0 = new import6.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = import26.viewFactory_DataTableRowWrapperComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._NgStyle_0_4 = new import25.Wrapper_NgStyle(this.parent.parent.parentInjector.get(import28.KeyValueDiffers),new import9.ElementRef(this._el_0),this.renderer);
- this._DataTableRowWrapperComponent_0_5 = new import26.Wrapper_DataTableRowWrapperComponent(new import9.ElementRef(this._el_0),this.renderer);
- this._appEl_0.initComponent(this._DataTableRowWrapperComponent_0_5.context,([] as any[]),compView_0);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import13.ViewContainer) {
+ super(View_DataTableBodyComponent3,renderType_DataTableBodyComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
+ }
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'datatable-row-wrapper',import3.EMPTY_INLINE_ARRAY,(null as any));
+ this.compView_0 = new import26.View_DataTableRowWrapperComponent0(this.viewUtils,this,0,this._el_0);
+ this._NgStyle_0_3 = new import25.Wrapper_NgStyle(this.parentView.parentView.parentView.injectorGet(import29.KeyValueDiffers,this.parentView.parentView.parentIndex),new import9.ElementRef(this._el_0),this.renderer);
+ this._DataTableRowWrapperComponent_0_4 = new import26.Wrapper_DataTableRowWrapperComponent(new import9.ElementRef(this._el_0),this.renderer);
this._text_1 = this.renderer.createText((null as any),'\n ',(null as any));
- this._el_2 = import2.createRenderElement(this.renderer,(null as any),'datatable-body-row',new import2.InlineArray2(2,'tabindex','-1'),(null as any));
- this._appEl_2 = new import6.AppElement(2,0,this,this._el_2);
- var compView_2:any = import27.viewFactory_DataTableBodyRowComponent0(this.viewUtils,this.injector(2),this._appEl_2);
- this._DataTableBodyRowComponent_2_4 = new import27.Wrapper_DataTableBodyRowComponent(new import9.ElementRef(this._el_2),this.renderer);
- this._appEl_2.initComponent(this._DataTableBodyRowComponent_2_4.context,([] as any[]),compView_2);
+ this._el_2 = import3.createRenderElement(this.renderer,(null as any),'datatable-body-row',new import3.InlineArray2(2,'tabindex','-1'),(null as any));
+ this.compView_2 = new import28.View_DataTableBodyRowComponent0(this.viewUtils,this,2,this._el_2);
+ this._DataTableBodyRowComponent_2_3 = new import28.Wrapper_DataTableBodyRowComponent(new import9.ElementRef(this._el_2),this.renderer);
this._text_3 = this.renderer.createText((null as any),'\n ',(null as any));
- compView_2.create(this._DataTableBodyRowComponent_2_4.context,([] as any[]),(null as any));
+ this.compView_2.create(this._DataTableBodyRowComponent_2_3.context);
this._text_4 = this.renderer.createText((null as any),'\n ',(null as any));
- compView_0.create(this._DataTableRowWrapperComponent_0_5.context,[([] as any[]).concat([
- this._text_1,
- this._el_2,
- this._text_4
- ]
- )],(null as any));
- var disposable_0:Function = this.renderer.listen(this._el_2,'activate',this.eventHandler(this._handle_activate_2_0.bind(this)));
- var disposable_1:Function = this.renderer.listen(this._el_2,'keydown',this.eventHandler(this._handle_keydown_2_1.bind(this)));
- const subscription_0:any = this._DataTableBodyRowComponent_2_4.context.activate.subscribe(this.eventHandler(this._handle_activate_2_0.bind(this)));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.compView_0.create(this._DataTableRowWrapperComponent_0_4.context);
+ var disposable_0:Function = import3.subscribeToRenderElement(this,this._el_2,new import3.InlineArray4(4,'activate',(null as any),'keydown',(null as any)),this.eventHandler(this.handleEvent_2));
+ this._DataTableBodyRowComponent_2_3.subscribe(this,this.eventHandler(this.handleEvent_2),true);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1,
this._el_2,
this._text_3,
this._text_4
]
- ,[
- disposable_0,
- disposable_1
- ]
- ,[subscription_0]);
+ ),[disposable_0]);
return (null as any);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import29.DataTableBodyRowComponent) && ((2 <= requestNodeIndex) && (requestNodeIndex <= 3)))) { return this._DataTableBodyRowComponent_2_4.context; }
- if (((token === import30.NgStyle) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 4)))) { return this._NgStyle_0_4.context; }
- if (((token === import31.DataTableRowWrapperComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 4)))) { return this._DataTableRowWrapperComponent_0_5.context; }
+ if (((token === import27.DataTableBodyRowComponent) && ((2 <= requestNodeIndex) && (requestNodeIndex <= 3)))) { return this._DataTableBodyRowComponent_2_3.context; }
+ if (((token === import30.NgStyle) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 4)))) { return this._NgStyle_0_3.context; }
+ if (((token === import24.DataTableRowWrapperComponent) && ((0 <= requestNodeIndex) && (requestNodeIndex <= 4)))) { return this._DataTableRowWrapperComponent_0_4.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- const currVal_0_0_0:any = this.parent.parent.context.getRowsStyles(this.context.$implicit);
- this._NgStyle_0_4.check_ngStyle(currVal_0_0_0,throwOnChange,false);
- this._NgStyle_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange);
- const currVal_0_1_0:any = this.parent.parent.context.rowDetailTemplate;
- this._DataTableRowWrapperComponent_0_5.check_rowDetailTemplate(currVal_0_1_0,throwOnChange,false);
- const currVal_0_1_1:any = this.parent.parent.context.detailRowHeight;
- this._DataTableRowWrapperComponent_0_5.check_detailRowHeight(currVal_0_1_1,throwOnChange,false);
+ const currVal_0_0_0:any = this.parentView.parentView.context.getRowsStyles(this.context.$implicit);
+ this._NgStyle_0_3.check_ngStyle(currVal_0_0_0,throwOnChange,false);
+ this._NgStyle_0_3.ngDoCheck(this,this._el_0,throwOnChange);
+ const currVal_0_1_0:any = this.parentView.parentView.context.rowDetailTemplate;
+ this._DataTableRowWrapperComponent_0_4.check_rowDetailTemplate(currVal_0_1_0,throwOnChange,false);
+ const currVal_0_1_1:any = this.parentView.parentView.context.detailRowHeight;
+ this._DataTableRowWrapperComponent_0_4.check_detailRowHeight(currVal_0_1_1,throwOnChange,false);
const currVal_0_1_2:any = (this.context.$implicit.$$expanded === 1);
- this._DataTableRowWrapperComponent_0_5.check_expanded(currVal_0_1_2,throwOnChange,false);
+ this._DataTableRowWrapperComponent_0_4.check_expanded(currVal_0_1_2,throwOnChange,false);
const currVal_0_1_3:any = this.context.$implicit;
- this._DataTableRowWrapperComponent_0_5.check_row(currVal_0_1_3,throwOnChange,false);
- if (this._DataTableRowWrapperComponent_0_5.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- const currVal_2_0_0:any = this.parent.parent.context.columns;
- this._DataTableBodyRowComponent_2_4.check_columns(currVal_2_0_0,throwOnChange,false);
- const currVal_2_0_1:any = this.parent.parent.context.innerWidth;
- this._DataTableBodyRowComponent_2_4.check_innerWidth(currVal_2_0_1,throwOnChange,false);
+ this._DataTableRowWrapperComponent_0_4.check_row(currVal_0_1_3,throwOnChange,false);
+ if (this._DataTableRowWrapperComponent_0_4.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ const currVal_2_0_0:any = this.parentView.parentView.context.columns;
+ this._DataTableBodyRowComponent_2_3.check_columns(currVal_2_0_0,throwOnChange,false);
+ const currVal_2_0_1:any = this.parentView.parentView.context.innerWidth;
+ this._DataTableBodyRowComponent_2_3.check_innerWidth(currVal_2_0_1,throwOnChange,false);
const currVal_2_0_2:any = this.context.$implicit;
- this._DataTableBodyRowComponent_2_4.check_row(currVal_2_0_2,throwOnChange,false);
- const currVal_2_0_3:any = this.parent.parent.context.offsetX;
- this._DataTableBodyRowComponent_2_4.check_offsetX(currVal_2_0_3,throwOnChange,false);
- const currVal_2_0_4:any = this.parent.parent.context.rowHeight;
- this._DataTableBodyRowComponent_2_4.check_rowHeight(currVal_2_0_4,throwOnChange,false);
- const currVal_2_0_5:any = (<_View_DataTableBodyComponent0>this.parent.parent)._DataTableSelectionComponent_1_4.context.getRowSelected(this.context.$implicit);
- this._DataTableBodyRowComponent_2_4.check_isSelected(currVal_2_0_5,throwOnChange,false);
- if (this._DataTableBodyRowComponent_2_4.detectChangesInInputProps(this,this._el_2,throwOnChange)) { this._appEl_2.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._NgStyle_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this._DataTableRowWrapperComponent_0_5.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this._DataTableBodyRowComponent_2_4.detectChangesInHostProps(this,this._el_2,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
- }
- private _handle_activate_2_0($event:any):boolean {
- this.markPathToRootAsCheckOnce();
- const pd_2_0:any = (((<_View_DataTableBodyComponent0>this.parent.parent)._DataTableSelectionComponent_1_4.context.onActivate($event,this.context.index)) !== false);
- return (true && pd_2_0);
+ this._DataTableBodyRowComponent_2_3.check_row(currVal_2_0_2,throwOnChange,false);
+ const currVal_2_0_3:any = this.parentView.parentView.context.offsetX;
+ this._DataTableBodyRowComponent_2_3.check_offsetX(currVal_2_0_3,throwOnChange,false);
+ const currVal_2_0_4:any = this.parentView.parentView.context.rowHeight;
+ this._DataTableBodyRowComponent_2_3.check_rowHeight(currVal_2_0_4,throwOnChange,false);
+ const currVal_2_0_5:any = (this.parentView.parentView)._DataTableSelectionComponent_1_3.context.getRowSelected(this.context.$implicit);
+ this._DataTableBodyRowComponent_2_3.check_isSelected(currVal_2_0_5,throwOnChange,false);
+ if (this._DataTableBodyRowComponent_2_3.ngDoCheck(this,this._el_2,throwOnChange)) { this.compView_2.markAsCheckOnce(); }
+ this._DataTableBodyRowComponent_2_3.checkHost(this,this.compView_2,this._el_2,throwOnChange);
+ this.compView_0.detectChanges(throwOnChange);
+ this.compView_2.detectChanges(throwOnChange);
}
- private _handle_keydown_2_1($event:any):boolean {
- this._appEl_2.componentView.markPathToRootAsCheckOnce();
- const pd_2_0:any = ((this._DataTableBodyRowComponent_2_4.context.onKeyDown($event)) !== false);
- return (true && pd_2_0);
+ destroyInternal():void {
+ this.compView_0.destroy();
+ this.compView_2.destroy();
+ this._DataTableBodyRowComponent_2_3.ngOnDestroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
+ visitProjectableNodesInternal(nodeIndex:number,ngContentIndex:number,cb:any,ctx:any):void {
+ if (((nodeIndex == 0) && (ngContentIndex == 0))) {
+ cb(this._text_1,ctx);
+ cb(this._el_2,ctx);
+ cb(this._text_4,ctx);
+ }
+ }
+ handleEvent_2(eventName:string,$event:any):boolean {
+ this.compView_2.markPathToRootAsCheckOnce();
+ var result:boolean = true;
+ result = (this._DataTableBodyRowComponent_2_3.handleEvent(eventName,$event) && result);
+ if ((eventName == 'activate')) {
+ const pd_sub_0:any = (((this.parentView.parentView)._DataTableSelectionComponent_1_3.context.onActivate($event,this.context.index)) !== false);
+ result = (pd_sub_0 && result);
+ }
+ return result;
}
}
-function viewFactory_DataTableBodyComponent3(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyComponent3(viewUtils,parentInjector,declarationEl);
-}
-class _View_DataTableBodyComponent4 extends import3.AppView {
+class View_DataTableBodyComponent4 extends import2.AppView {
_el_0:any;
_text_1:any;
/*private*/ _expr_2:any;
- constructor(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement) {
- super(_View_DataTableBodyComponent4,renderType_DataTableBodyComponent,import8.ViewType.EMBEDDED,viewUtils,parentInjector,declarationEl,import1.ChangeDetectorStatus.CheckAlways);
+ constructor(viewUtils:import3.ViewUtils,parentView:import2.AppView,parentIndex:number,parentElement:any,declaredViewContainer:import13.ViewContainer) {
+ super(View_DataTableBodyComponent4,renderType_DataTableBodyComponent,import7.ViewType.EMBEDDED,viewUtils,parentView,parentIndex,parentElement,import1.ChangeDetectorStatus.CheckAlways,declaredViewContainer);
this._expr_2 = import1.UNINITIALIZED;
}
- createInternal(rootSelector:string):import6.AppElement {
- this._el_0 = import2.createRenderElement(this.renderer,(null as any),'div',new import2.InlineArray2(2,'class','empty-row'),(null as any));
+ createInternal(rootSelector:string):import8.ComponentRef {
+ this._el_0 = import3.createRenderElement(this.renderer,(null as any),'div',new import3.InlineArray2(2,'class','empty-row'),(null as any));
this._text_1 = this.renderer.createText(this._el_0,'\n ',(null as any));
- this.init(([] as any[]).concat([this._el_0]),[
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [
this._el_0,
this._text_1
]
- ,([] as any[]),([] as any[]));
+ ),(null as any));
return (null as any);
}
detectChangesInternal(throwOnChange:boolean):void {
- this.detectContentChildrenChanges(throwOnChange);
- const currVal_2:any = this.parent.context.emptyMessage;
- if (import2.checkBinding(throwOnChange,this._expr_2,currVal_2)) {
+ const currVal_2:any = this.parentView.context.emptyMessage;
+ if (import3.checkBinding(throwOnChange,this._expr_2,currVal_2)) {
this.renderer.setElementProperty(this._el_0,'innerHTML',this.viewUtils.sanitizer.sanitize(import4.SecurityContext.HTML,currVal_2));
this._expr_2 = currVal_2;
}
- this.detectViewChildrenChanges(throwOnChange);
}
-}
-function viewFactory_DataTableBodyComponent4(viewUtils:import2.ViewUtils,parentInjector:import7.Injector,declarationEl:import6.AppElement):import3.AppView {
- return new _View_DataTableBodyComponent4(viewUtils,parentInjector,declarationEl);
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
+ }
}
\ No newline at end of file
diff --git a/release/components/body/progress-bar.component.ngfactory.ts b/release/components/body/progress-bar.component.ngfactory.ts
index 105083d21..a15dc4e7d 100644
--- a/release/components/body/progress-bar.component.ngfactory.ts
+++ b/release/components/body/progress-bar.component.ngfactory.ts
@@ -1,71 +1,80 @@
/**
- * This file is generated by the Angular 2 template compiler.
+ * @fileoverview This file is generated by the Angular 2 template compiler.
* Do not edit.
+ * @suppress {suspiciousCode,uselessCode,missingProperties}
*/
/* tslint:disable */
import * as import0 from '../../../../src/components/body/progress-bar.component';
import * as import1 from '@angular/core/src/linker/view';
import * as import2 from '@angular/core/src/render/api';
-import * as import3 from '@angular/core/src/linker/element';
-import * as import4 from '@angular/core/src/linker/view_utils';
-import * as import5 from '@angular/core/src/di/injector';
-import * as import6 from '@angular/core/src/linker/view_type';
-import * as import7 from '@angular/core/src/change_detection/change_detection';
-import * as import8 from '@angular/core/src/metadata/view';
-import * as import9 from '@angular/core/src/linker/component_factory';
+import * as import3 from '@angular/core/src/linker/view_utils';
+import * as import4 from '@angular/core/src/metadata/view';
+import * as import5 from '@angular/core/src/linker/view_type';
+import * as import6 from '@angular/core/src/change_detection/change_detection';
+import * as import7 from '@angular/core/src/linker/component_factory';
export class Wrapper_ProgressBarComponent {
+ /*private*/ _eventHandler:Function;
context:import0.ProgressBarComponent;
- changed:boolean;
+ /*private*/ _changed:boolean;
constructor() {
- this.changed = false;
+ this._changed = false;
this.context = new import0.ProgressBarComponent();
}
- detectChangesInInputProps(view:import1.AppView,el:any,throwOnChange:boolean):boolean {
- var changed:any = this.changed;
- this.changed = false;
+ ngOnDetach(view:import1.AppView,componentView:import1.AppView,el:any):void {
+ }
+ ngOnDestroy():void {
+ }
+ ngDoCheck(view:import1.AppView,el:any,throwOnChange:boolean):boolean {
+ var changed:any = this._changed;
+ this._changed = false;
return changed;
}
- detectChangesInHostProps(view:import1.AppView,el:any,throwOnChange:boolean):void {
+ checkHost(view:import1.AppView,componentView:import1.AppView,el:any,throwOnChange:boolean):void {
+ }
+ handleEvent(eventName:string,$event:any):boolean {
+ var result:boolean = true;
+ return result;
+ }
+ subscribe(view:import1.AppView,_eventHandler:any):void {
+ this._eventHandler = _eventHandler;
}
}
-var renderType_ProgressBarComponent_Host:import2.RenderComponentType = (null as any);
-class _View_ProgressBarComponent_Host0 extends import1.AppView {
+var renderType_ProgressBarComponent_Host:import2.RenderComponentType = import3.createRenderComponentType('',0,import4.ViewEncapsulation.None,([] as any[]),{});
+class View_ProgressBarComponent_Host0 extends import1.AppView {
_el_0:any;
- /*private*/ _appEl_0:import3.AppElement;
- _ProgressBarComponent_0_4:Wrapper_ProgressBarComponent;
- constructor(viewUtils:import4.ViewUtils,parentInjector:import5.Injector,declarationEl:import3.AppElement) {
- super(_View_ProgressBarComponent_Host0,renderType_ProgressBarComponent_Host,import6.ViewType.HOST,viewUtils,parentInjector,declarationEl,import7.ChangeDetectorStatus.CheckAlways);
+ compView_0:import1.AppView;
+ _ProgressBarComponent_0_3:Wrapper_ProgressBarComponent;
+ constructor(viewUtils:import3.ViewUtils,parentView:import1.AppView,parentIndex:number,parentElement:any) {
+ super(View_ProgressBarComponent_Host0,renderType_ProgressBarComponent_Host,import5.ViewType.HOST,viewUtils,parentView,parentIndex,parentElement,import6.ChangeDetectorStatus.CheckAlways);
}
- createInternal(rootSelector:string):import3.AppElement {
- this._el_0 = import4.selectOrCreateRenderHostElement(this.renderer,'datatable-progress',import4.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
- this._appEl_0 = new import3.AppElement(0,(null as any),this,this._el_0);
- var compView_0:any = viewFactory_ProgressBarComponent0(this.viewUtils,this.injector(0),this._appEl_0);
- this._ProgressBarComponent_0_4 = new Wrapper_ProgressBarComponent();
- this._appEl_0.initComponent(this._ProgressBarComponent_0_4.context,([] as any[]),compView_0);
- compView_0.create(this._ProgressBarComponent_0_4.context,this.projectableNodes,(null as any));
- this.init(([] as any[]).concat([this._el_0]),[this._el_0],([] as any[]),([] as any[]));
- return this._appEl_0;
+ createInternal(rootSelector:string):import7.ComponentRef {
+ this._el_0 = import3.selectOrCreateRenderHostElement(this.renderer,'datatable-progress',import3.EMPTY_INLINE_ARRAY,rootSelector,(null as any));
+ this.compView_0 = new View_ProgressBarComponent0(this.viewUtils,this,0,this._el_0);
+ this._ProgressBarComponent_0_3 = new Wrapper_ProgressBarComponent();
+ this.compView_0.create(this._ProgressBarComponent_0_3.context);
+ this.init(this._el_0,((this.renderer).directRenderer? (null as any): [this._el_0]),(null as any));
+ return new import7.ComponentRef_(0,this,this._el_0,this._ProgressBarComponent_0_3.context);
}
injectorGetInternal(token:any,requestNodeIndex:number,notFoundResult:any):any {
- if (((token === import0.ProgressBarComponent) && (0 === requestNodeIndex))) { return this._ProgressBarComponent_0_4.context; }
+ if (((token === import0.ProgressBarComponent) && (0 === requestNodeIndex))) { return this._ProgressBarComponent_0_3.context; }
return notFoundResult;
}
detectChangesInternal(throwOnChange:boolean):void {
- if (this._ProgressBarComponent_0_4.detectChangesInInputProps(this,this._el_0,throwOnChange)) { this._appEl_0.componentView.markAsCheckOnce(); }
- this.detectContentChildrenChanges(throwOnChange);
- this._ProgressBarComponent_0_4.detectChangesInHostProps(this,this._el_0,throwOnChange);
- this.detectViewChildrenChanges(throwOnChange);
+ if (this._ProgressBarComponent_0_3.ngDoCheck(this,this._el_0,throwOnChange)) { this.compView_0.markAsCheckOnce(); }
+ this.compView_0.detectChanges(throwOnChange);
+ }
+ destroyInternal():void {
+ this.compView_0.destroy();
+ }
+ visitRootNodesInternal(cb:any,ctx:any):void {
+ cb(this._el_0,ctx);
}
}
-function viewFactory_ProgressBarComponent_Host0(viewUtils:import4.ViewUtils,parentInjector:import5.Injector,declarationEl:import3.AppElement):import1.AppView {
- if ((renderType_ProgressBarComponent_Host === (null as any))) { (renderType_ProgressBarComponent_Host = viewUtils.createRenderComponentType('',0,import8.ViewEncapsulation.None,([] as any[]),{})); }
- return new _View_ProgressBarComponent_Host0(viewUtils,parentInjector,declarationEl);
-}
-export const ProgressBarComponentNgFactory:import9.ComponentFactory = new import9.ComponentFactory('datatable-progress',viewFactory_ProgressBarComponent_Host0,import0.ProgressBarComponent);
+export const ProgressBarComponentNgFactory:import7.ComponentFactory = new import7.ComponentFactory('datatable-progress',View_ProgressBarComponent_Host0,import0.ProgressBarComponent);
const styles_ProgressBarComponent:any[] = ([] as any[]);
-var renderType_ProgressBarComponent:import2.RenderComponentType = (null as any);
-class _View_ProgressBarComponent0 extends import1.AppView {
+var renderType_ProgressBarComponent:import2.RenderComponentType = import3.createRenderComponentType('',0,import4.ViewEncapsulation.None,styles_ProgressBarComponent,{});
+export class View_ProgressBarComponent0 extends import1.AppView {
_text_0:any;
_el_1:any;
_text_2:any;
@@ -75,21 +84,21 @@ class _View_ProgressBarComponent0 extends import1.AppView,parentIndex:number,parentElement:any) {
+ super(View_ProgressBarComponent0,renderType_ProgressBarComponent,import5.ViewType.COMPONENT,viewUtils,parentView,parentIndex,parentElement,import6.ChangeDetectorStatus.CheckOnce);
}
- createInternal(rootSelector:string):import3.AppElement {
- const parentRenderNode:any = this.renderer.createViewRoot(this.declarationAppElement.nativeElement);
+ createInternal(rootSelector:string):import7.ComponentRef {
+ const parentRenderNode:any = this.renderer.createViewRoot(this.parentElement);
this._text_0 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this._el_1 = import4.createRenderElement(this.renderer,parentRenderNode,'div',new import4.InlineArray4(4,'class','progress-linear','role','progressbar'),(null as any));
+ this._el_1 = import3.createRenderElement(this.renderer,parentRenderNode,'div',new import3.InlineArray4(4,'class','progress-linear','role','progressbar'),(null as any));
this._text_2 = this.renderer.createText(this._el_1,'\n ',(null as any));
- this._el_3 = import4.createRenderElement(this.renderer,this._el_1,'div',new import4.InlineArray2(2,'class','container'),(null as any));
+ this._el_3 = import3.createRenderElement(this.renderer,this._el_1,'div',new import3.InlineArray2(2,'class','container'),(null as any));
this._text_4 = this.renderer.createText(this._el_3,'\n ',(null as any));
- this._el_5 = import4.createRenderElement(this.renderer,this._el_3,'div',new import4.InlineArray2(2,'class','bar'),(null as any));
+ this._el_5 = import3.createRenderElement(this.renderer,this._el_3,'div',new import3.InlineArray2(2,'class','bar'),(null as any));
this._text_6 = this.renderer.createText(this._el_3,'\n ',(null as any));
this._text_7 = this.renderer.createText(this._el_1,'\n ',(null as any));
this._text_8 = this.renderer.createText(parentRenderNode,'\n ',(null as any));
- this.init(([] as any[]),[
+ this.init((null as any),((this.renderer).directRenderer? (null as any): [
this._text_0,
this._el_1,
this._text_2,
@@ -100,11 +109,7 @@ class _View_ProgressBarComponent0 extends import1.AppView