@khanacademy/perseus-editor 7.0.1 → 7.0.2
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/dist/es/index.js +1 -14
- package/dist/es/index.js.map +1 -1
- package/dist/index.js +1 -14
- package/dist/index.js.map +1 -1
- package/dist/widgets/interactive-graph-editor.d.ts +143 -210
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -81,7 +81,7 @@ var Banner__default = /*#__PURE__*/_interopDefaultLegacy(Banner);
|
|
|
81
81
|
|
|
82
82
|
// This file is processed by a Rollup plugin (replace) to inject the production
|
|
83
83
|
const libName = "@khanacademy/perseus-editor";
|
|
84
|
-
const libVersion = "7.0.
|
|
84
|
+
const libVersion = "7.0.2";
|
|
85
85
|
perseusCore.addLibraryVersionToPerseusDebug(libName, libVersion);
|
|
86
86
|
|
|
87
87
|
function _extends() {
|
|
@@ -31835,15 +31835,6 @@ class InteractiveGraphEditor extends React__namespace.Component {
|
|
|
31835
31835
|
UNSAFE_componentWillMount() {
|
|
31836
31836
|
DeprecationMixin.UNSAFE_componentWillMount.call(this);
|
|
31837
31837
|
}
|
|
31838
|
-
static buildGraphKey(correct) {
|
|
31839
|
-
const testGraphKey = [];
|
|
31840
|
-
for (const key in correct) {
|
|
31841
|
-
if (correct[key]) {
|
|
31842
|
-
typeof correct[key] === "number" || typeof correct[key] === "string" || typeof correct[key] === "boolean" ? testGraphKey.push(correct[key]) : testGraphKey.push(0);
|
|
31843
|
-
}
|
|
31844
|
-
}
|
|
31845
|
-
return testGraphKey.join(":");
|
|
31846
|
-
}
|
|
31847
31838
|
render() {
|
|
31848
31839
|
let graph;
|
|
31849
31840
|
let equationString;
|
|
@@ -31886,9 +31877,6 @@ class InteractiveGraphEditor extends React__namespace.Component {
|
|
|
31886
31877
|
});
|
|
31887
31878
|
}
|
|
31888
31879
|
};
|
|
31889
|
-
// This is used to force a remount of the graph component
|
|
31890
|
-
// when there's a significant change
|
|
31891
|
-
const graphKey = InteractiveGraphEditor.buildGraphKey(correct);
|
|
31892
31880
|
graph =
|
|
31893
31881
|
/*#__PURE__*/
|
|
31894
31882
|
// There are a bunch of props that renderer.jsx passes to widgets via
|
|
@@ -31896,7 +31884,6 @@ class InteractiveGraphEditor extends React__namespace.Component {
|
|
|
31896
31884
|
// bother passing.
|
|
31897
31885
|
// @ts-expect-error - TS2769 - No overload matches this call.
|
|
31898
31886
|
React__namespace.createElement(InteractiveGraph, _extends({}, graphProps, {
|
|
31899
|
-
key: graphKey,
|
|
31900
31887
|
containerSizeClass: sizeClass,
|
|
31901
31888
|
apiOptions: {
|
|
31902
31889
|
...this.props.apiOptions,
|