@pie-element/complex-rubric 3.4.2-next.54 → 3.4.2-next.56
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/controller/package.json +1 -1
- package/module/configure.js +300 -203
- package/module/element.js +311 -214
- package/module/manifest.json +1 -1
- package/module/print.js +311 -214
- package/package.json +4 -4
package/controller/package.json
CHANGED
package/module/configure.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {_dll_react, _dll_prop_types, _dll_classnames, _dll_react_dom, _dll_debug, _dll_lodash, _dll_react_dom_server, _dll_pie_framework__mathquill} from "../../../@pie-lib/pie-toolbox-math-rendering-module@3.3.0/module/index.js";
|
|
2
2
|
import RubricConfigure from '@pie-element/rubric/configure/lib';
|
|
3
|
-
import {_dll_pie_lib__pie_toolbox_editable_html, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_config_ui} from "../../../@pie-lib/pie-toolbox-module@5.
|
|
3
|
+
import {_dll_pie_lib__pie_toolbox_editable_html, _dll_pie_lib__pie_toolbox_render_ui, _dll_pie_lib__pie_toolbox_config_ui} from "../../../@pie-lib/pie-toolbox-module@5.10.0/module/index.js";
|
|
4
4
|
function _mergeNamespaces(n, m) {
|
|
5
5
|
m.forEach(function (e) {
|
|
6
6
|
e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
|
|
@@ -6361,7 +6361,7 @@ function _typeof$q(obj) {
|
|
|
6361
6361
|
}
|
|
6362
6362
|
return _typeof$q(obj);
|
|
6363
6363
|
}
|
|
6364
|
-
function get$
|
|
6364
|
+
function get$2(obj, path, defaultValue) {
|
|
6365
6365
|
return path.split('.').reduce(function (a, c) {
|
|
6366
6366
|
return a && a[c] ? a[c] : defaultValue || null;
|
|
6367
6367
|
}, obj);
|
|
@@ -7341,7 +7341,7 @@ function reduce$3() {
|
|
|
7341
7341
|
dirtyHandlerIds: reduce$5(state.dirtyHandlerIds, {
|
|
7342
7342
|
type: action.type,
|
|
7343
7343
|
payload: _objectSpread$b(_objectSpread$b({}, action.payload), {}, {
|
|
7344
|
-
prevTargetIds: get$
|
|
7344
|
+
prevTargetIds: get$2(state, 'dragOperation.targetIds', [])
|
|
7345
7345
|
})
|
|
7346
7346
|
}),
|
|
7347
7347
|
dragOffset: reduce$8(state.dragOffset, action),
|
|
@@ -41681,7 +41681,7 @@ const require$$12$t = _dll_prop_types;
|
|
|
41681
41681
|
getDefaultExportFromCjs(feedback);
|
|
41682
41682
|
const require$$9$U = _dll_react;
|
|
41683
41683
|
const require$$10$T = _dll_prop_types;
|
|
41684
|
-
const require$$15$
|
|
41684
|
+
const require$$15$8 = _dll_debug;
|
|
41685
41685
|
var _interopRequireDefault$3s = interopRequireDefault.exports;
|
|
41686
41686
|
var _typeof$i = _typeof$s.exports;
|
|
41687
41687
|
Object.defineProperty(responseIndicators, "__esModule", {
|
|
@@ -41701,7 +41701,7 @@ var icons$5 = _interopRequireWildcard$6(icons$6);
|
|
|
41701
41701
|
var _Popover$1 = _interopRequireDefault$3s(Popover$2);
|
|
41702
41702
|
var _styles$a = styles$1J;
|
|
41703
41703
|
var _feedback = _interopRequireDefault$3s(feedback);
|
|
41704
|
-
var _debug$3 = _interopRequireDefault$3s(require$$15$
|
|
41704
|
+
var _debug$3 = _interopRequireDefault$3s(require$$15$8);
|
|
41705
41705
|
function _getRequireWildcardCache$3(nodeInterop) {
|
|
41706
41706
|
if (typeof WeakMap !== "function") return null;
|
|
41707
41707
|
var cacheBabelInterop = new WeakMap();
|
|
@@ -42066,6 +42066,45 @@ Collapse$1.default = _default$2V;
|
|
|
42066
42066
|
var index$1E = getDefaultExportFromCjs(Collapse$2);
|
|
42067
42067
|
var mathRendering = {};
|
|
42068
42068
|
var renderMath = {};
|
|
42069
|
+
var get$1 = {
|
|
42070
|
+
exports: {}
|
|
42071
|
+
};
|
|
42072
|
+
var superPropBase = {
|
|
42073
|
+
exports: {}
|
|
42074
|
+
};
|
|
42075
|
+
(function (module) {
|
|
42076
|
+
var getPrototypeOf = getPrototypeOf$1.exports;
|
|
42077
|
+
function _superPropBase(object, property) {
|
|
42078
|
+
while (!Object.prototype.hasOwnProperty.call(object, property)) {
|
|
42079
|
+
object = getPrototypeOf(object);
|
|
42080
|
+
if (object === null) break;
|
|
42081
|
+
}
|
|
42082
|
+
return object;
|
|
42083
|
+
}
|
|
42084
|
+
(module.exports = _superPropBase, module.exports.__esModule = true, module.exports["default"] = module.exports);
|
|
42085
|
+
})(superPropBase);
|
|
42086
|
+
getDefaultExportFromCjs(superPropBase.exports);
|
|
42087
|
+
(function (module) {
|
|
42088
|
+
var superPropBase$1 = superPropBase.exports;
|
|
42089
|
+
function _get() {
|
|
42090
|
+
if (typeof Reflect !== "undefined" && Reflect.get) {
|
|
42091
|
+
(module.exports = _get = Reflect.get, module.exports.__esModule = true, module.exports["default"] = module.exports);
|
|
42092
|
+
} else {
|
|
42093
|
+
(module.exports = _get = function _get(target, property, receiver) {
|
|
42094
|
+
var base = superPropBase$1(target, property);
|
|
42095
|
+
if (!base) return;
|
|
42096
|
+
var desc = Object.getOwnPropertyDescriptor(base, property);
|
|
42097
|
+
if (desc.get) {
|
|
42098
|
+
return desc.get.call(arguments.length < 3 ? target : receiver);
|
|
42099
|
+
}
|
|
42100
|
+
return desc.value;
|
|
42101
|
+
}, module.exports.__esModule = true, module.exports["default"] = module.exports);
|
|
42102
|
+
}
|
|
42103
|
+
return _get.apply(this, arguments);
|
|
42104
|
+
}
|
|
42105
|
+
(module.exports = _get, module.exports.__esModule = true, module.exports["default"] = module.exports);
|
|
42106
|
+
})(get$1);
|
|
42107
|
+
getDefaultExportFromCjs(get$1.exports);
|
|
42069
42108
|
var mathjax = {};
|
|
42070
42109
|
var version$4 = {};
|
|
42071
42110
|
Object.defineProperty(version$4, "__esModule", {
|
|
@@ -71665,10 +71704,198 @@ function MenuHandler(handler) {
|
|
|
71665
71704
|
return handler;
|
|
71666
71705
|
}
|
|
71667
71706
|
MenuHandler$1.MenuHandler = MenuHandler;
|
|
71707
|
+
var FindMathML$1 = {};
|
|
71708
|
+
var FindMath = {};
|
|
71709
|
+
Object.defineProperty(FindMath, "__esModule", {
|
|
71710
|
+
value: true
|
|
71711
|
+
});
|
|
71712
|
+
FindMath.AbstractFindMath = void 0;
|
|
71713
|
+
var Options_js_1$d = Options$2;
|
|
71714
|
+
var AbstractFindMath = (function () {
|
|
71715
|
+
function AbstractFindMath(options) {
|
|
71716
|
+
var CLASS = this.constructor;
|
|
71717
|
+
this.options = (0, Options_js_1$d.userOptions)((0, Options_js_1$d.defaultOptions)({}, CLASS.OPTIONS), options);
|
|
71718
|
+
}
|
|
71719
|
+
AbstractFindMath.OPTIONS = {};
|
|
71720
|
+
return AbstractFindMath;
|
|
71721
|
+
})();
|
|
71722
|
+
FindMath.AbstractFindMath = AbstractFindMath;
|
|
71723
|
+
var __extends$1m = commonjsGlobal && commonjsGlobal.__extends || (function () {
|
|
71724
|
+
var extendStatics = function (d, b) {
|
|
71725
|
+
extendStatics = Object.setPrototypeOf || ({
|
|
71726
|
+
__proto__: []
|
|
71727
|
+
}) instanceof Array && (function (d, b) {
|
|
71728
|
+
d.__proto__ = b;
|
|
71729
|
+
}) || (function (d, b) {
|
|
71730
|
+
for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p];
|
|
71731
|
+
});
|
|
71732
|
+
return extendStatics(d, b);
|
|
71733
|
+
};
|
|
71734
|
+
return function (d, b) {
|
|
71735
|
+
if (typeof b !== "function" && b !== null) throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
71736
|
+
extendStatics(d, b);
|
|
71737
|
+
function __() {
|
|
71738
|
+
this.constructor = d;
|
|
71739
|
+
}
|
|
71740
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
71741
|
+
};
|
|
71742
|
+
})();
|
|
71743
|
+
var __values$G = commonjsGlobal && commonjsGlobal.__values || (function (o) {
|
|
71744
|
+
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
71745
|
+
if (m) return m.call(o);
|
|
71746
|
+
if (o && typeof o.length === "number") return {
|
|
71747
|
+
next: function () {
|
|
71748
|
+
if (o && i >= o.length) o = void 0;
|
|
71749
|
+
return {
|
|
71750
|
+
value: o && o[i++],
|
|
71751
|
+
done: !o
|
|
71752
|
+
};
|
|
71753
|
+
}
|
|
71754
|
+
};
|
|
71755
|
+
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
71756
|
+
});
|
|
71757
|
+
Object.defineProperty(FindMathML$1, "__esModule", {
|
|
71758
|
+
value: true
|
|
71759
|
+
});
|
|
71760
|
+
FindMathML$1.FindMathML = void 0;
|
|
71761
|
+
var FindMath_js_1$1 = FindMath;
|
|
71762
|
+
var NAMESPACE = 'http://www.w3.org/1998/Math/MathML';
|
|
71763
|
+
var FindMathML = (function (_super) {
|
|
71764
|
+
__extends$1m(FindMathML, _super);
|
|
71765
|
+
function FindMathML() {
|
|
71766
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
71767
|
+
}
|
|
71768
|
+
FindMathML.prototype.findMath = function (node) {
|
|
71769
|
+
var set = new Set();
|
|
71770
|
+
this.findMathNodes(node, set);
|
|
71771
|
+
this.findMathPrefixed(node, set);
|
|
71772
|
+
var html = this.adaptor.root(this.adaptor.document);
|
|
71773
|
+
if (this.adaptor.kind(html) === 'html' && set.size === 0) {
|
|
71774
|
+
this.findMathNS(node, set);
|
|
71775
|
+
}
|
|
71776
|
+
return this.processMath(set);
|
|
71777
|
+
};
|
|
71778
|
+
FindMathML.prototype.findMathNodes = function (node, set) {
|
|
71779
|
+
var e_1, _a;
|
|
71780
|
+
try {
|
|
71781
|
+
for (var _b = __values$G(this.adaptor.tags(node, 'math')), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
71782
|
+
var math = _c.value;
|
|
71783
|
+
set.add(math);
|
|
71784
|
+
}
|
|
71785
|
+
} catch (e_1_1) {
|
|
71786
|
+
e_1 = {
|
|
71787
|
+
error: e_1_1
|
|
71788
|
+
};
|
|
71789
|
+
} finally {
|
|
71790
|
+
try {
|
|
71791
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
71792
|
+
} finally {
|
|
71793
|
+
if (e_1) throw e_1.error;
|
|
71794
|
+
}
|
|
71795
|
+
}
|
|
71796
|
+
};
|
|
71797
|
+
FindMathML.prototype.findMathPrefixed = function (node, set) {
|
|
71798
|
+
var e_2, _a, e_3, _b;
|
|
71799
|
+
var html = this.adaptor.root(this.adaptor.document);
|
|
71800
|
+
try {
|
|
71801
|
+
for (var _c = __values$G(this.adaptor.allAttributes(html)), _d = _c.next(); !_d.done; _d = _c.next()) {
|
|
71802
|
+
var attr = _d.value;
|
|
71803
|
+
if (attr.name.substr(0, 6) === 'xmlns:' && attr.value === NAMESPACE) {
|
|
71804
|
+
var prefix = attr.name.substr(6);
|
|
71805
|
+
try {
|
|
71806
|
+
for (var _e = (e_3 = void 0, __values$G(this.adaptor.tags(node, prefix + ':math'))), _f = _e.next(); !_f.done; _f = _e.next()) {
|
|
71807
|
+
var math = _f.value;
|
|
71808
|
+
set.add(math);
|
|
71809
|
+
}
|
|
71810
|
+
} catch (e_3_1) {
|
|
71811
|
+
e_3 = {
|
|
71812
|
+
error: e_3_1
|
|
71813
|
+
};
|
|
71814
|
+
} finally {
|
|
71815
|
+
try {
|
|
71816
|
+
if (_f && !_f.done && (_b = _e.return)) _b.call(_e);
|
|
71817
|
+
} finally {
|
|
71818
|
+
if (e_3) throw e_3.error;
|
|
71819
|
+
}
|
|
71820
|
+
}
|
|
71821
|
+
}
|
|
71822
|
+
}
|
|
71823
|
+
} catch (e_2_1) {
|
|
71824
|
+
e_2 = {
|
|
71825
|
+
error: e_2_1
|
|
71826
|
+
};
|
|
71827
|
+
} finally {
|
|
71828
|
+
try {
|
|
71829
|
+
if (_d && !_d.done && (_a = _c.return)) _a.call(_c);
|
|
71830
|
+
} finally {
|
|
71831
|
+
if (e_2) throw e_2.error;
|
|
71832
|
+
}
|
|
71833
|
+
}
|
|
71834
|
+
};
|
|
71835
|
+
FindMathML.prototype.findMathNS = function (node, set) {
|
|
71836
|
+
var e_4, _a;
|
|
71837
|
+
try {
|
|
71838
|
+
for (var _b = __values$G(this.adaptor.tags(node, 'math', NAMESPACE)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
71839
|
+
var math = _c.value;
|
|
71840
|
+
set.add(math);
|
|
71841
|
+
}
|
|
71842
|
+
} catch (e_4_1) {
|
|
71843
|
+
e_4 = {
|
|
71844
|
+
error: e_4_1
|
|
71845
|
+
};
|
|
71846
|
+
} finally {
|
|
71847
|
+
try {
|
|
71848
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
71849
|
+
} finally {
|
|
71850
|
+
if (e_4) throw e_4.error;
|
|
71851
|
+
}
|
|
71852
|
+
}
|
|
71853
|
+
};
|
|
71854
|
+
FindMathML.prototype.processMath = function (set) {
|
|
71855
|
+
var e_5, _a;
|
|
71856
|
+
var math = [];
|
|
71857
|
+
try {
|
|
71858
|
+
for (var _b = __values$G(Array.from(set)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
71859
|
+
var mml = _c.value;
|
|
71860
|
+
var display = this.adaptor.getAttribute(mml, 'display') === 'block' || this.adaptor.getAttribute(mml, 'mode') === 'display';
|
|
71861
|
+
var start = {
|
|
71862
|
+
node: mml,
|
|
71863
|
+
n: 0,
|
|
71864
|
+
delim: ''
|
|
71865
|
+
};
|
|
71866
|
+
var end = {
|
|
71867
|
+
node: mml,
|
|
71868
|
+
n: 0,
|
|
71869
|
+
delim: ''
|
|
71870
|
+
};
|
|
71871
|
+
math.push({
|
|
71872
|
+
math: this.adaptor.outerHTML(mml),
|
|
71873
|
+
start: start,
|
|
71874
|
+
end: end,
|
|
71875
|
+
display: display
|
|
71876
|
+
});
|
|
71877
|
+
}
|
|
71878
|
+
} catch (e_5_1) {
|
|
71879
|
+
e_5 = {
|
|
71880
|
+
error: e_5_1
|
|
71881
|
+
};
|
|
71882
|
+
} finally {
|
|
71883
|
+
try {
|
|
71884
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
71885
|
+
} finally {
|
|
71886
|
+
if (e_5) throw e_5.error;
|
|
71887
|
+
}
|
|
71888
|
+
}
|
|
71889
|
+
return math;
|
|
71890
|
+
};
|
|
71891
|
+
FindMathML.OPTIONS = {};
|
|
71892
|
+
return FindMathML;
|
|
71893
|
+
})(FindMath_js_1$1.AbstractFindMath);
|
|
71894
|
+
FindMathML$1.FindMathML = FindMathML;
|
|
71668
71895
|
var mathml = {};
|
|
71669
71896
|
var InputJax = {};
|
|
71670
71897
|
var FunctionList$1 = {};
|
|
71671
|
-
var __extends$
|
|
71898
|
+
var __extends$1l = commonjsGlobal && commonjsGlobal.__extends || (function () {
|
|
71672
71899
|
var extendStatics = function (d, b) {
|
|
71673
71900
|
extendStatics = Object.setPrototypeOf || ({
|
|
71674
71901
|
__proto__: []
|
|
@@ -71688,7 +71915,7 @@ var __extends$1m = commonjsGlobal && commonjsGlobal.__extends || (function () {
|
|
|
71688
71915
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
71689
71916
|
};
|
|
71690
71917
|
})();
|
|
71691
|
-
var __values$
|
|
71918
|
+
var __values$F = commonjsGlobal && commonjsGlobal.__values || (function (o) {
|
|
71692
71919
|
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
71693
71920
|
if (m) return m.call(o);
|
|
71694
71921
|
if (o && typeof o.length === "number") return {
|
|
@@ -71736,7 +71963,7 @@ Object.defineProperty(FunctionList$1, "__esModule", {
|
|
|
71736
71963
|
FunctionList$1.FunctionList = void 0;
|
|
71737
71964
|
var PrioritizedList_js_1 = PrioritizedList$1;
|
|
71738
71965
|
var FunctionList = (function (_super) {
|
|
71739
|
-
__extends$
|
|
71966
|
+
__extends$1l(FunctionList, _super);
|
|
71740
71967
|
function FunctionList() {
|
|
71741
71968
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
71742
71969
|
}
|
|
@@ -71747,7 +71974,7 @@ var FunctionList = (function (_super) {
|
|
|
71747
71974
|
data[_i] = arguments[_i];
|
|
71748
71975
|
}
|
|
71749
71976
|
try {
|
|
71750
|
-
for (var _b = __values$
|
|
71977
|
+
for (var _b = __values$F(this), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
71751
71978
|
var item = _c.value;
|
|
71752
71979
|
var result = item.item.apply(item, __spreadArray$s([], __read$P(data), false));
|
|
71753
71980
|
if (result === false) {
|
|
@@ -71801,7 +72028,7 @@ Object.defineProperty(InputJax, "__esModule", {
|
|
|
71801
72028
|
value: true
|
|
71802
72029
|
});
|
|
71803
72030
|
InputJax.AbstractInputJax = void 0;
|
|
71804
|
-
var Options_js_1$
|
|
72031
|
+
var Options_js_1$c = Options$2;
|
|
71805
72032
|
var FunctionList_js_1$2 = FunctionList$1;
|
|
71806
72033
|
var AbstractInputJax = (function () {
|
|
71807
72034
|
function AbstractInputJax(options) {
|
|
@@ -71811,7 +72038,7 @@ var AbstractInputJax = (function () {
|
|
|
71811
72038
|
this.adaptor = null;
|
|
71812
72039
|
this.mmlFactory = null;
|
|
71813
72040
|
var CLASS = this.constructor;
|
|
71814
|
-
this.options = (0, Options_js_1$
|
|
72041
|
+
this.options = (0, Options_js_1$c.userOptions)((0, Options_js_1$c.defaultOptions)({}, CLASS.OPTIONS), options);
|
|
71815
72042
|
this.preFilters = new FunctionList_js_1$2.FunctionList();
|
|
71816
72043
|
this.postFilters = new FunctionList_js_1$2.FunctionList();
|
|
71817
72044
|
}
|
|
@@ -71859,194 +72086,6 @@ var AbstractInputJax = (function () {
|
|
|
71859
72086
|
return AbstractInputJax;
|
|
71860
72087
|
})();
|
|
71861
72088
|
InputJax.AbstractInputJax = AbstractInputJax;
|
|
71862
|
-
var FindMathML$1 = {};
|
|
71863
|
-
var FindMath = {};
|
|
71864
|
-
Object.defineProperty(FindMath, "__esModule", {
|
|
71865
|
-
value: true
|
|
71866
|
-
});
|
|
71867
|
-
FindMath.AbstractFindMath = void 0;
|
|
71868
|
-
var Options_js_1$c = Options$2;
|
|
71869
|
-
var AbstractFindMath = (function () {
|
|
71870
|
-
function AbstractFindMath(options) {
|
|
71871
|
-
var CLASS = this.constructor;
|
|
71872
|
-
this.options = (0, Options_js_1$c.userOptions)((0, Options_js_1$c.defaultOptions)({}, CLASS.OPTIONS), options);
|
|
71873
|
-
}
|
|
71874
|
-
AbstractFindMath.OPTIONS = {};
|
|
71875
|
-
return AbstractFindMath;
|
|
71876
|
-
})();
|
|
71877
|
-
FindMath.AbstractFindMath = AbstractFindMath;
|
|
71878
|
-
var __extends$1l = commonjsGlobal && commonjsGlobal.__extends || (function () {
|
|
71879
|
-
var extendStatics = function (d, b) {
|
|
71880
|
-
extendStatics = Object.setPrototypeOf || ({
|
|
71881
|
-
__proto__: []
|
|
71882
|
-
}) instanceof Array && (function (d, b) {
|
|
71883
|
-
d.__proto__ = b;
|
|
71884
|
-
}) || (function (d, b) {
|
|
71885
|
-
for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p];
|
|
71886
|
-
});
|
|
71887
|
-
return extendStatics(d, b);
|
|
71888
|
-
};
|
|
71889
|
-
return function (d, b) {
|
|
71890
|
-
if (typeof b !== "function" && b !== null) throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
71891
|
-
extendStatics(d, b);
|
|
71892
|
-
function __() {
|
|
71893
|
-
this.constructor = d;
|
|
71894
|
-
}
|
|
71895
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
71896
|
-
};
|
|
71897
|
-
})();
|
|
71898
|
-
var __values$F = commonjsGlobal && commonjsGlobal.__values || (function (o) {
|
|
71899
|
-
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
71900
|
-
if (m) return m.call(o);
|
|
71901
|
-
if (o && typeof o.length === "number") return {
|
|
71902
|
-
next: function () {
|
|
71903
|
-
if (o && i >= o.length) o = void 0;
|
|
71904
|
-
return {
|
|
71905
|
-
value: o && o[i++],
|
|
71906
|
-
done: !o
|
|
71907
|
-
};
|
|
71908
|
-
}
|
|
71909
|
-
};
|
|
71910
|
-
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
71911
|
-
});
|
|
71912
|
-
Object.defineProperty(FindMathML$1, "__esModule", {
|
|
71913
|
-
value: true
|
|
71914
|
-
});
|
|
71915
|
-
FindMathML$1.FindMathML = void 0;
|
|
71916
|
-
var FindMath_js_1$1 = FindMath;
|
|
71917
|
-
var NAMESPACE = 'http://www.w3.org/1998/Math/MathML';
|
|
71918
|
-
var FindMathML = (function (_super) {
|
|
71919
|
-
__extends$1l(FindMathML, _super);
|
|
71920
|
-
function FindMathML() {
|
|
71921
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
71922
|
-
}
|
|
71923
|
-
FindMathML.prototype.findMath = function (node) {
|
|
71924
|
-
var set = new Set();
|
|
71925
|
-
this.findMathNodes(node, set);
|
|
71926
|
-
this.findMathPrefixed(node, set);
|
|
71927
|
-
var html = this.adaptor.root(this.adaptor.document);
|
|
71928
|
-
if (this.adaptor.kind(html) === 'html' && set.size === 0) {
|
|
71929
|
-
this.findMathNS(node, set);
|
|
71930
|
-
}
|
|
71931
|
-
return this.processMath(set);
|
|
71932
|
-
};
|
|
71933
|
-
FindMathML.prototype.findMathNodes = function (node, set) {
|
|
71934
|
-
var e_1, _a;
|
|
71935
|
-
try {
|
|
71936
|
-
for (var _b = __values$F(this.adaptor.tags(node, 'math')), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
71937
|
-
var math = _c.value;
|
|
71938
|
-
set.add(math);
|
|
71939
|
-
}
|
|
71940
|
-
} catch (e_1_1) {
|
|
71941
|
-
e_1 = {
|
|
71942
|
-
error: e_1_1
|
|
71943
|
-
};
|
|
71944
|
-
} finally {
|
|
71945
|
-
try {
|
|
71946
|
-
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
71947
|
-
} finally {
|
|
71948
|
-
if (e_1) throw e_1.error;
|
|
71949
|
-
}
|
|
71950
|
-
}
|
|
71951
|
-
};
|
|
71952
|
-
FindMathML.prototype.findMathPrefixed = function (node, set) {
|
|
71953
|
-
var e_2, _a, e_3, _b;
|
|
71954
|
-
var html = this.adaptor.root(this.adaptor.document);
|
|
71955
|
-
try {
|
|
71956
|
-
for (var _c = __values$F(this.adaptor.allAttributes(html)), _d = _c.next(); !_d.done; _d = _c.next()) {
|
|
71957
|
-
var attr = _d.value;
|
|
71958
|
-
if (attr.name.substr(0, 6) === 'xmlns:' && attr.value === NAMESPACE) {
|
|
71959
|
-
var prefix = attr.name.substr(6);
|
|
71960
|
-
try {
|
|
71961
|
-
for (var _e = (e_3 = void 0, __values$F(this.adaptor.tags(node, prefix + ':math'))), _f = _e.next(); !_f.done; _f = _e.next()) {
|
|
71962
|
-
var math = _f.value;
|
|
71963
|
-
set.add(math);
|
|
71964
|
-
}
|
|
71965
|
-
} catch (e_3_1) {
|
|
71966
|
-
e_3 = {
|
|
71967
|
-
error: e_3_1
|
|
71968
|
-
};
|
|
71969
|
-
} finally {
|
|
71970
|
-
try {
|
|
71971
|
-
if (_f && !_f.done && (_b = _e.return)) _b.call(_e);
|
|
71972
|
-
} finally {
|
|
71973
|
-
if (e_3) throw e_3.error;
|
|
71974
|
-
}
|
|
71975
|
-
}
|
|
71976
|
-
}
|
|
71977
|
-
}
|
|
71978
|
-
} catch (e_2_1) {
|
|
71979
|
-
e_2 = {
|
|
71980
|
-
error: e_2_1
|
|
71981
|
-
};
|
|
71982
|
-
} finally {
|
|
71983
|
-
try {
|
|
71984
|
-
if (_d && !_d.done && (_a = _c.return)) _a.call(_c);
|
|
71985
|
-
} finally {
|
|
71986
|
-
if (e_2) throw e_2.error;
|
|
71987
|
-
}
|
|
71988
|
-
}
|
|
71989
|
-
};
|
|
71990
|
-
FindMathML.prototype.findMathNS = function (node, set) {
|
|
71991
|
-
var e_4, _a;
|
|
71992
|
-
try {
|
|
71993
|
-
for (var _b = __values$F(this.adaptor.tags(node, 'math', NAMESPACE)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
71994
|
-
var math = _c.value;
|
|
71995
|
-
set.add(math);
|
|
71996
|
-
}
|
|
71997
|
-
} catch (e_4_1) {
|
|
71998
|
-
e_4 = {
|
|
71999
|
-
error: e_4_1
|
|
72000
|
-
};
|
|
72001
|
-
} finally {
|
|
72002
|
-
try {
|
|
72003
|
-
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
72004
|
-
} finally {
|
|
72005
|
-
if (e_4) throw e_4.error;
|
|
72006
|
-
}
|
|
72007
|
-
}
|
|
72008
|
-
};
|
|
72009
|
-
FindMathML.prototype.processMath = function (set) {
|
|
72010
|
-
var e_5, _a;
|
|
72011
|
-
var math = [];
|
|
72012
|
-
try {
|
|
72013
|
-
for (var _b = __values$F(Array.from(set)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
72014
|
-
var mml = _c.value;
|
|
72015
|
-
var display = this.adaptor.getAttribute(mml, 'display') === 'block' || this.adaptor.getAttribute(mml, 'mode') === 'display';
|
|
72016
|
-
var start = {
|
|
72017
|
-
node: mml,
|
|
72018
|
-
n: 0,
|
|
72019
|
-
delim: ''
|
|
72020
|
-
};
|
|
72021
|
-
var end = {
|
|
72022
|
-
node: mml,
|
|
72023
|
-
n: 0,
|
|
72024
|
-
delim: ''
|
|
72025
|
-
};
|
|
72026
|
-
math.push({
|
|
72027
|
-
math: this.adaptor.outerHTML(mml),
|
|
72028
|
-
start: start,
|
|
72029
|
-
end: end,
|
|
72030
|
-
display: display
|
|
72031
|
-
});
|
|
72032
|
-
}
|
|
72033
|
-
} catch (e_5_1) {
|
|
72034
|
-
e_5 = {
|
|
72035
|
-
error: e_5_1
|
|
72036
|
-
};
|
|
72037
|
-
} finally {
|
|
72038
|
-
try {
|
|
72039
|
-
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
72040
|
-
} finally {
|
|
72041
|
-
if (e_5) throw e_5.error;
|
|
72042
|
-
}
|
|
72043
|
-
}
|
|
72044
|
-
return math;
|
|
72045
|
-
};
|
|
72046
|
-
FindMathML.OPTIONS = {};
|
|
72047
|
-
return FindMathML;
|
|
72048
|
-
})(FindMath_js_1$1.AbstractFindMath);
|
|
72049
|
-
FindMathML$1.FindMathML = FindMathML;
|
|
72050
72089
|
var MathMLCompile$1 = {};
|
|
72051
72090
|
var Entities$1 = {};
|
|
72052
72091
|
var AsyncLoad = {};
|
|
@@ -114638,7 +114677,7 @@ var unWrapMath = function unWrapMath(content) {
|
|
|
114638
114677
|
};
|
|
114639
114678
|
};
|
|
114640
114679
|
normalization.unWrapMath = unWrapMath;
|
|
114641
|
-
const require$$
|
|
114680
|
+
const require$$22$2 = _dll_debug;
|
|
114642
114681
|
(function (exports) {
|
|
114643
114682
|
var _interopRequireDefault = interopRequireDefault.exports;
|
|
114644
114683
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -114648,10 +114687,17 @@ const require$$15$8 = _dll_debug;
|
|
|
114648
114687
|
var _toConsumableArray2 = _interopRequireDefault(toConsumableArray$3.exports);
|
|
114649
114688
|
var _typeof2 = _interopRequireDefault(_typeof$s.exports);
|
|
114650
114689
|
var _defineProperty2 = _interopRequireDefault(defineProperty$5.exports);
|
|
114690
|
+
var _classCallCheck2 = _interopRequireDefault(classCallCheck$4.exports);
|
|
114691
|
+
var _createClass2 = _interopRequireDefault(createClass$3.exports);
|
|
114692
|
+
var _get2 = _interopRequireDefault(get$1.exports);
|
|
114693
|
+
var _inherits2 = _interopRequireDefault(inherits$2.exports);
|
|
114694
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(possibleConstructorReturn$2.exports);
|
|
114695
|
+
var _getPrototypeOf2 = _interopRequireDefault(getPrototypeOf$1.exports);
|
|
114651
114696
|
var _mathjax = mathjax;
|
|
114652
114697
|
var _assistiveMml = assistiveMml;
|
|
114653
114698
|
var _semanticEnrich = semanticEnrich;
|
|
114654
114699
|
var _MenuHandler = MenuHandler$1;
|
|
114700
|
+
var _FindMathML2 = FindMathML$1;
|
|
114655
114701
|
var _mathml = mathml;
|
|
114656
114702
|
var _tex = tex$2;
|
|
114657
114703
|
var _chtml = chtml$1;
|
|
@@ -114659,12 +114705,13 @@ const require$$15$8 = _dll_debug;
|
|
|
114659
114705
|
var _browserAdaptor = browserAdaptor$1;
|
|
114660
114706
|
var _AllPackages = AllPackages;
|
|
114661
114707
|
var _mstack = mstack;
|
|
114662
|
-
var _debug = _interopRequireDefault(require$$
|
|
114708
|
+
var _debug = _interopRequireDefault(require$$22$2);
|
|
114663
114709
|
var _normalization = normalization;
|
|
114664
114710
|
var _MmlFactory = MmlFactory$1;
|
|
114665
114711
|
var _SerializedMmlVisitor = SerializedMmlVisitor;
|
|
114666
114712
|
var _WrapperFactory = WrapperFactory$2;
|
|
114667
114713
|
var _mspace = mspace$1;
|
|
114714
|
+
var _HTMLDomStrings = HTMLDomStrings$1;
|
|
114668
114715
|
function ownKeys(object, enumerableOnly) {
|
|
114669
114716
|
var keys = Object.keys(object);
|
|
114670
114717
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -114686,6 +114733,30 @@ const require$$15$8 = _dll_debug;
|
|
|
114686
114733
|
}
|
|
114687
114734
|
return target;
|
|
114688
114735
|
}
|
|
114736
|
+
function _createSuper(Derived) {
|
|
114737
|
+
var hasNativeReflectConstruct = _isNativeReflectConstruct();
|
|
114738
|
+
return function _createSuperInternal() {
|
|
114739
|
+
var Super = (0, _getPrototypeOf2["default"])(Derived), result;
|
|
114740
|
+
if (hasNativeReflectConstruct) {
|
|
114741
|
+
var NewTarget = (0, _getPrototypeOf2["default"])(this).constructor;
|
|
114742
|
+
result = Reflect.construct(Super, arguments, NewTarget);
|
|
114743
|
+
} else {
|
|
114744
|
+
result = Super.apply(this, arguments);
|
|
114745
|
+
}
|
|
114746
|
+
return (0, _possibleConstructorReturn2["default"])(this, result);
|
|
114747
|
+
};
|
|
114748
|
+
}
|
|
114749
|
+
function _isNativeReflectConstruct() {
|
|
114750
|
+
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
114751
|
+
if (Reflect.construct.sham) return false;
|
|
114752
|
+
if (typeof Proxy === "function") return true;
|
|
114753
|
+
try {
|
|
114754
|
+
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
114755
|
+
return true;
|
|
114756
|
+
} catch (e) {
|
|
114757
|
+
return false;
|
|
114758
|
+
}
|
|
114759
|
+
}
|
|
114689
114760
|
if (typeof window !== 'undefined') {
|
|
114690
114761
|
(0, _html.RegisterHTMLHandler)((0, _browserAdaptor.browserAdaptor)());
|
|
114691
114762
|
}
|
|
@@ -114740,6 +114811,28 @@ const require$$15$8 = _dll_debug;
|
|
|
114740
114811
|
return node.setAttribute('displaystyle', 'true');
|
|
114741
114812
|
});
|
|
114742
114813
|
};
|
|
114814
|
+
var myFindMathML = (function (_FindMathML) {
|
|
114815
|
+
(0, _inherits2["default"])(myFindMathML, _FindMathML);
|
|
114816
|
+
var _super = _createSuper(myFindMathML);
|
|
114817
|
+
function myFindMathML() {
|
|
114818
|
+
(0, _classCallCheck2["default"])(this, myFindMathML);
|
|
114819
|
+
return _super.apply(this, arguments);
|
|
114820
|
+
}
|
|
114821
|
+
(0, _createClass2["default"])(myFindMathML, [{
|
|
114822
|
+
key: "processMath",
|
|
114823
|
+
value: function processMath(set) {
|
|
114824
|
+
var adaptor = this.adaptor;
|
|
114825
|
+
for (var _i = 0, _Array$from = Array.from(set); _i < _Array$from.length; _i++) {
|
|
114826
|
+
var mml = _Array$from[_i];
|
|
114827
|
+
if (adaptor.kind(adaptor.parent(mml)) === 'mjx-assistive-mml') {
|
|
114828
|
+
set["delete"](mml);
|
|
114829
|
+
}
|
|
114830
|
+
}
|
|
114831
|
+
return (0, _get2["default"])((0, _getPrototypeOf2["default"])(myFindMathML.prototype), "processMath", this).call(this, set);
|
|
114832
|
+
}
|
|
114833
|
+
}]);
|
|
114834
|
+
return myFindMathML;
|
|
114835
|
+
})(_FindMathML2.FindMathML);
|
|
114743
114836
|
var createMathMLInstance = function createMathMLInstance(opts) {
|
|
114744
114837
|
var docProvided = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
|
114745
114838
|
opts = opts || defaultOpts();
|
|
@@ -114769,7 +114862,8 @@ const require$$15$8 = _dll_debug;
|
|
|
114769
114862
|
parseError: function parseError(node) {
|
|
114770
114863
|
console.log('error:', node);
|
|
114771
114864
|
this.error(this.adaptor.textContent(node).replace(/\n.*/g, ''));
|
|
114772
|
-
}
|
|
114865
|
+
},
|
|
114866
|
+
FindMathML: new myFindMathML()
|
|
114773
114867
|
};
|
|
114774
114868
|
var fontURL = ("https://unpkg.com/mathjax-full@").concat(_mathjax.mathjax.version, "/ts/output/chtml/fonts/tex-woff-v2");
|
|
114775
114869
|
var htmlConfig = {
|
|
@@ -114794,7 +114888,10 @@ const require$$15$8 = _dll_debug;
|
|
|
114794
114888
|
},
|
|
114795
114889
|
enrichSpeech: 'deep',
|
|
114796
114890
|
InputJax: [new _tex.TeX(texConfig), mml],
|
|
114797
|
-
OutputJax: new _chtml.CHTML(htmlConfig)
|
|
114891
|
+
OutputJax: new _chtml.CHTML(htmlConfig),
|
|
114892
|
+
DomStrings: new _HTMLDomStrings.HTMLDomStrings({
|
|
114893
|
+
skipHtmlTags: ['script', 'noscript', 'style', 'textarea', 'pre', 'code', 'annotation', 'annotation-xml', 'mjx-assistive-mml', 'mjx-container']
|
|
114894
|
+
})
|
|
114798
114895
|
});
|
|
114799
114896
|
mml.setMmlFactory(customMmlFactory);
|
|
114800
114897
|
return html;
|