ion-oui
Version:
The client library of oui builder for ionic
84 lines (83 loc) • 4.14 kB
JavaScript
;
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
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;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.OUIIonDynamicTextParser = exports.OUIIonDynamicTextComponent = exports.OUIIonTextParser = exports.OUIIonTextComponent = void 0;
var core_1 = require("@angular/core");
var helpers_1 = require("../helpers");
var oui_element_1 = require("../oui-element");
var oui_parser_1 = require("../oui-parser");
var OUIIonTextComponent = /** @class */ (function (_super) {
__extends(OUIIonTextComponent, _super);
function OUIIonTextComponent() {
return _super !== null && _super.apply(this, arguments) || this;
}
OUIIonTextComponent = __decorate([
(0, core_1.Component)({
selector: 'app-ion-oui-text',
template: "\n <ion-text [mode]=\"mode\">\n {{data.data}}\n </ion-text>\n "
})
], OUIIonTextComponent);
return OUIIonTextComponent;
}(oui_element_1.OUIIonElement));
exports.OUIIonTextComponent = OUIIonTextComponent;
var OUIIonTextParser = /** @class */ (function (_super) {
__extends(OUIIonTextParser, _super);
function OUIIonTextParser() {
var _this = _super !== null && _super.apply(this, arguments) || this;
_this.type = 'Text';
_this.componentType = OUIIonTextComponent;
return _this;
}
return OUIIonTextParser;
}(oui_parser_1.OUIAbstractIonParser));
exports.OUIIonTextParser = OUIIonTextParser;
var OUIIonDynamicTextComponent = /** @class */ (function (_super) {
__extends(OUIIonDynamicTextComponent, _super);
function OUIIonDynamicTextComponent() {
var _this = _super !== null && _super.apply(this, arguments) || this;
_this.text = "";
return _this;
}
OUIIonDynamicTextComponent.prototype.ngOnInit = function () {
this.text = (0, helpers_1.tryParsingDynamicValue)(this.data.data);
};
OUIIonDynamicTextComponent = __decorate([
(0, core_1.Component)({
selector: 'app-ion-oui-dynamic-text',
template: "\n <ion-text [mode]=\"mode\">\n {{data.data | mevento: clickHandler}}\n </ion-text>\n "
})
], OUIIonDynamicTextComponent);
return OUIIonDynamicTextComponent;
}(oui_element_1.OUIIonElement));
exports.OUIIonDynamicTextComponent = OUIIonDynamicTextComponent;
var OUIIonDynamicTextParser = /** @class */ (function (_super) {
__extends(OUIIonDynamicTextParser, _super);
function OUIIonDynamicTextParser() {
var _this = _super !== null && _super.apply(this, arguments) || this;
_this.type = 'DynamicText';
_this.componentType = OUIIonDynamicTextComponent;
return _this;
}
return OUIIonDynamicTextParser;
}(oui_parser_1.OUIAbstractIonParser));
exports.OUIIonDynamicTextParser = OUIIonDynamicTextParser;