UNPKG

@atlaskit/editor-core

Version:

A package contains Atlassian editor core functionality

24 lines 773 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var tslib_1 = require("tslib"); var React = require("react"); var react_1 = require("react"); var isSub = function (type) { return type === 'sub'; }; var SubSup = (function (_super) { tslib_1.__extends(SubSup, _super); function SubSup() { return _super !== null && _super.apply(this, arguments) || this; } SubSup.prototype.render = function () { var props = this.props; if (isSub(props.type)) { return React.createElement("sub", null, props.children); } return React.createElement("sup", null, props.children); }; return SubSup; }(react_1.PureComponent)); exports.default = SubSup; //# sourceMappingURL=subsup.js.map