UNPKG

@signatu/policy

Version:
62 lines 2.47 kB
"use strict"; 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 (b.hasOwnProperty(p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); Object.defineProperty(exports, "__esModule", { value: true }); var policyContent_1 = require("./policyContent"); var common_lib_1 = require("@signatu/common-lib"); var FontIconContent = /** @class */ (function (_super) { __extends(FontIconContent, _super); function FontIconContent(title, cssClass) { var _this = _super.call(this, policyContent_1.ContentType.ICON, new common_lib_1.Language(common_lib_1.Language.ALL), cssClass) || this; _this.title = title; _this.cssClass = cssClass; _this.type = policyContent_1.ContentType.ICON; return _this; } Object.defineProperty(FontIconContent.prototype, "class", { // Properties get: function () { return this.cssClass; }, enumerable: true, configurable: true }); Object.defineProperty(FontIconContent.prototype, "value", { // Functions get: function () { return "<i class=\"" + this.cssClass + "\"></i>"; }, enumerable: true, configurable: true }); FontIconContent.fromJSON = function (json) { // We don't need the PolicyDataProcessing var fontIcon = new FontIconContent(json.title, json.cssClass); fontIcon.ref = json.ref; return fontIcon; }; FontIconContent.prototype.toJSON = function () { var json = _super.prototype.toJSON.call(this); json.title = this.title; return json; }; return FontIconContent; }(policyContent_1.PolicyContentBase)); exports.FontIconContent = FontIconContent; exports.StandardIcons = { SECURE: new FontIconContent('Secure', 'fa fa-lock'), SIGNATU_CONSENT: new FontIconContent('Consent', 'signatu-consent fa-3x'), SIGNATU_CONTROLLER: new FontIconContent('Controller', 'signatu-controller fa-3x') }; //# sourceMappingURL=fontIcon.js.map