UNPKG

jpush-ui

Version:

极光大数据前端Angular组件(^6.1.0)

73 lines 2.12 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var core_1 = require("@angular/core"); /** * 用于记录一个dialog的信息 */ var /** * 用于记录一个dialog的信息 */ DialogData = /** @class */ (function () { function DialogData(portal, host, data) { this.portal = portal; this.host = host; this.data = data; } DialogData.prototype.open = function () { // console.log('open...'); this.host.attach(this.portal); }; DialogData.prototype.close = function () { // console.log('close...'); this.host.detach(); }; Object.defineProperty(DialogData.prototype, "onSure", { get: function () { return this.data.sure; }, enumerable: true, configurable: true }); Object.defineProperty(DialogData.prototype, "onClose", { get: function () { return this.data.sure; }, enumerable: true, configurable: true }); DialogData.prototype.setProperty = function (key, value) { if (!key || value === undefined) { return; } this.data[key] = value; }; return DialogData; }()); exports.DialogData = DialogData; var DialogModelBase = /** @class */ (function () { function DialogModelBase() { this.sure = new core_1.EventEmitter(); this.close = new core_1.EventEmitter(); this.validFields = [ 'isOpen', 'overlayClosable', 'width', 'height', 'sureTxt', 'minWidth' ]; this.isOpen = true; this.overlayClosable = false; this.sureTxt = '确定'; } Object.defineProperty(DialogModelBase.prototype, "baseStyle", { get: function () { return { 'width.px': this.width, 'height.px': this.height, 'min-width.px': this.minWidth, }; }, enumerable: true, configurable: true }); return DialogModelBase; }()); exports.DialogModelBase = DialogModelBase; //# sourceMappingURL=dialog.model.js.map