6f83f577851a4d28026b21d2684d0441157a5206abc65e2f60216b618ba4e594.json 7.8 KB

1
  1. {"ast":null,"code":"\"use strict\";\n\nvar __extends = this && this.__extends || function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf || {\n __proto__: []\n } instanceof Array && function (d, b) {\n d.__proto__ = b;\n } || function (d, b) {\n for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p];\n };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null) throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() {\n this.constructor = d;\n }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n}();\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.CommonMtextMixin = void 0;\nfunction CommonMtextMixin(Base) {\n var _a;\n return _a = function (_super) {\n __extends(class_1, _super);\n function class_1() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n class_1.prototype.getVariant = function () {\n var options = this.jax.options;\n var data = this.jax.math.outputData;\n var merror = (!!data.merrorFamily || !!options.merrorFont) && this.node.Parent.isKind('merror');\n if (!!data.mtextFamily || !!options.mtextFont || merror) {\n var variant = this.node.attributes.get('mathvariant');\n var font = this.constructor.INHERITFONTS[variant] || this.jax.font.getCssFont(variant);\n var family = font[0] || (merror ? data.merrorFamily || options.merrorFont : data.mtextFamily || options.mtextFont);\n this.variant = this.explicitVariant(family, font[2] ? 'bold' : '', font[1] ? 'italic' : '');\n return;\n }\n _super.prototype.getVariant.call(this);\n };\n return class_1;\n }(Base), _a.INHERITFONTS = {\n normal: ['', false, false],\n bold: ['', false, true],\n italic: ['', true, false],\n 'bold-italic': ['', true, true]\n }, _a;\n}\nexports.CommonMtextMixin = CommonMtextMixin;","map":{"version":3,"names":["__extends","extendStatics","d","b","Object","setPrototypeOf","__proto__","Array","p","prototype","hasOwnProperty","call","TypeError","String","__","constructor","create","defineProperty","exports","value","CommonMtextMixin","Base","_a","_super","class_1","apply","arguments","getVariant","options","jax","data","math","outputData","merror","merrorFamily","merrorFont","node","Parent","isKind","mtextFamily","mtextFont","variant","attributes","get","font","INHERITFONTS","getCssFont","family","explicitVariant","normal","bold","italic"],"sources":["F:/workspace/202226701027/huinongbao-app/node_modules/mathjax-full/js/output/common/Wrappers/mtext.js"],"sourcesContent":["\"use strict\";\nvar __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.CommonMtextMixin = void 0;\nfunction CommonMtextMixin(Base) {\n var _a;\n return _a = (function (_super) {\n __extends(class_1, _super);\n function class_1() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n class_1.prototype.getVariant = function () {\n var options = this.jax.options;\n var data = this.jax.math.outputData;\n var merror = ((!!data.merrorFamily || !!options.merrorFont) && this.node.Parent.isKind('merror'));\n if (!!data.mtextFamily || !!options.mtextFont || merror) {\n var variant = this.node.attributes.get('mathvariant');\n var font = this.constructor.INHERITFONTS[variant] || this.jax.font.getCssFont(variant);\n var family = font[0] || (merror ? data.merrorFamily || options.merrorFont :\n data.mtextFamily || options.mtextFont);\n this.variant = this.explicitVariant(family, font[2] ? 'bold' : '', font[1] ? 'italic' : '');\n return;\n }\n _super.prototype.getVariant.call(this);\n };\n return class_1;\n }(Base)),\n _a.INHERITFONTS = {\n normal: ['', false, false],\n bold: ['', false, true],\n italic: ['', true, false],\n 'bold-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