UNPKG

angular-wrapper-kendo-ui

Version:

A simple library to wrapper Telerik Kendo UI jQuery controls in Angular 6 components.

275 lines (269 loc) 9.08 kB
(function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@progress/kendo-ui'), require('jquery')) : typeof define === 'function' && define.amd ? define('angular-wrapper-kendo-ui', ['exports', '@angular/core', '@progress/kendo-ui', 'jquery'], factory) : (global = global || self, factory(global['angular-wrapper-kendo-ui'] = {}, global.ng.core)); }(this, (function (exports, core) { 'use strict'; /** * @fileoverview added by tsickle * Generated from: lib/tree-list.component.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var TreeListComponent = /** @class */ (function () { function TreeListComponent(zone, elementRef) { this.zone = zone; this.elementRef = elementRef; } /** * @return {?} */ TreeListComponent.prototype.ngOnInit = /** * @return {?} */ function () { }; /** * @return {?} */ TreeListComponent.prototype.ngAfterViewInit = /** * @return {?} */ function () { var _this = this; /** @type {?} */ var treeList = kendo.jQuery(this.treelistEl.nativeElement); this.zone.runOutsideAngular((/** * @return {?} */ function () { _this._treelist = treeList .kendoTreeList(_this.options) .data('kendoTreeList'); })); }; /** * @return {?} */ TreeListComponent.prototype.ngOnDestroy = /** * @return {?} */ function () { kendo.destroy(this.elementRef.nativeElement); }; Object.defineProperty(TreeListComponent.prototype, "dataSource", { get: /** * @return {?} */ function () { return this._treelist && this._treelist.dataSource; }, enumerable: true, configurable: true }); Object.defineProperty(TreeListComponent.prototype, "content", { get: /** * @return {?} */ function () { return this._treelist && this._treelist.content; }, enumerable: true, configurable: true }); Object.defineProperty(TreeListComponent.prototype, "thead", { get: /** * @return {?} */ function () { return this._treelist && this._treelist.thead; }, enumerable: true, configurable: true }); Object.defineProperty(TreeListComponent.prototype, "tbody", { get: /** * @return {?} */ function () { return this._treelist && this._treelist.tbody; }, enumerable: true, configurable: true }); /** * @param {?=} parentRow * @return {?} */ TreeListComponent.prototype.addRow = /** * @param {?=} parentRow * @return {?} */ function (parentRow) { if (parentRow === void 0) { parentRow = ''; } return this._treelist && this._treelist.addRow(parentRow); }; /** * @param {?} row * @return {?} */ TreeListComponent.prototype.editRow = /** * @param {?} row * @return {?} */ function (row) { if (!row) { return; } /** @type {?} */ var internalRow = row instanceof jQuery ? row : kendo.jQuery(row); return this._treelist && this._treelist.editRow(internalRow); }; /** * @param {?} row * @return {?} */ TreeListComponent.prototype.removeRow = /** * @param {?} row * @return {?} */ function (row) { if (!row) { return; } /** @type {?} */ var internalRow = row instanceof jQuery ? row : kendo.jQuery(row); return this._treelist && this._treelist.removeRow(internalRow); }; /** * @param {?} row * @return {?} */ TreeListComponent.prototype.expand = /** * @param {?} row * @return {?} */ function (row) { if (!row) { return; } /** @type {?} */ var internalRow = row instanceof jQuery ? row : kendo.jQuery(row); return this._treelist && this._treelist.expand(internalRow); }; /** * @param {?} row * @return {?} */ TreeListComponent.prototype.select = /** * @param {?} row * @return {?} */ function (row) { if (!row) { return; } /** @type {?} */ var internalRow = row instanceof jQuery ? row : kendo.jQuery(row); return this._treelist && this._treelist.select(internalRow); }; /** * @param {?} model * @return {?} */ TreeListComponent.prototype.itemFor = /** * @param {?} model * @return {?} */ function (model) { if (!model) { return; } return this._treelist && this._treelist.itemFor(model); }; /** * @param {?} row * @return {?} */ TreeListComponent.prototype.dataItem = /** * @param {?} row * @return {?} */ function (row) { if (!row) { return; } /** @type {?} */ var internalRow = row instanceof jQuery ? row : kendo.jQuery(row); return this._treelist && this._treelist.dataItem(internalRow); }; /** * @return {?} */ TreeListComponent.prototype.clearSelection = /** * @return {?} */ function () { return this._treelist && this._treelist.clearSelection(); }; TreeListComponent.decorators = [ { type: core.Component, args: [{ // tslint:disable-next-line:component-selector selector: 'ng-treelist', template: "<div id=\"treelist\" #treelist></div>", encapsulation: core.ViewEncapsulation.None, changeDetection: core.ChangeDetectionStrategy.OnPush, styles: [""] }] } ]; /** @nocollapse */ TreeListComponent.ctorParameters = function () { return [ { type: core.NgZone }, { type: core.ElementRef } ]; }; TreeListComponent.propDecorators = { options: [{ type: core.Input }], treelistEl: [{ type: core.ViewChild, args: ['treelist', { static: false },] }] }; return TreeListComponent; }()); if (false) { /** @type {?} */ TreeListComponent.prototype.options; /** @type {?} */ TreeListComponent.prototype.treelistEl; /** * @type {?} * @private */ TreeListComponent.prototype._treelist; /** * @type {?} * @private */ TreeListComponent.prototype.zone; /** * @type {?} * @private */ TreeListComponent.prototype.elementRef; } /** * @fileoverview added by tsickle * Generated from: lib/angular-wrapper-kendo-ui.module.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var AngularWrapperKendoUiModule = /** @class */ (function () { function AngularWrapperKendoUiModule() { } AngularWrapperKendoUiModule.decorators = [ { type: core.NgModule, args: [{ imports: [], declarations: [TreeListComponent], exports: [TreeListComponent] },] } ]; return AngularWrapperKendoUiModule; }()); exports.AngularWrapperKendoUiModule = AngularWrapperKendoUiModule; exports.TreeListComponent = TreeListComponent; Object.defineProperty(exports, '__esModule', { value: true }); }))); //# sourceMappingURL=angular-wrapper-kendo-ui.umd.js.map