UNPKG

my-test123

Version:
59 lines 2.05 kB
import { Component, Input, Output, EventEmitter } from '@angular/core'; import { ActivatedRoute } from '@angular/router'; import { WorkItemService } from './../../services/work-item.service'; var CardValue = /** @class */ (function () { function CardValue() { } return CardValue; }()); export { CardValue }; var CardComponent = /** @class */ (function () { function CardComponent(workItemService, route) { this.workItemService = workItemService; this.route = route; this.menuClickEvent = new EventEmitter(); this.urlListener = null; this.existingQueryParams = {}; } CardComponent.prototype.ngOnInit = function () { var _this = this; if (this.urlListener === null) { this.urlListener = this.route.queryParams.subscribe(function (params) { _this.existingQueryParams = params; }); } }; CardComponent.prototype.ngOnDestroy = function () { if (this.urlListener) { this.urlListener.unsubscribe(); this.urlListener = null; } }; CardComponent.prototype.kebabClick = function (event) { event.stopPropagation(); }; CardComponent.prototype.kebabMenuClick = function (event, menuId) { event.stopPropagation(); this.menuClickEvent.emit(menuId); }; CardComponent.decorators = [ { type: Component, args: [{ selector: 'card', template: require('./card.component.html'), styles: [require('./card.component.css').toString()] },] }, ]; /** @nocollapse */ CardComponent.ctorParameters = function () { return [ { type: WorkItemService, }, { type: ActivatedRoute, }, ]; }; CardComponent.propDecorators = { 'cardValue': [{ type: Input },], 'menuClickEvent': [{ type: Output },], }; return CardComponent; }()); export { CardComponent }; //# sourceMappingURL=card.component.js.map