@wiris/mathtype-tinymce6 8.5.0 → 8.7.0

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.
@@ -136,6 +136,19 @@ export class TinyMceIntegration extends IntegrationModel {
136
136
  super.updateFormula(mathml);
137
137
  }
138
138
 
139
+ /** @inheritdoc */
140
+ insertFormula(focusElement, windowTarget, mathml, wirisProperties) {
141
+ // Due to insertFormula adds an image using pure JavaScript functions,
142
+ // it is needed notificate to the editorObject that placeholder status
143
+ // has to be updated.
144
+ const obj = super.insertFormula(focusElement, windowTarget, mathml, wirisProperties);
145
+
146
+ // Add formula to undo & redo
147
+ this.editorObject.undoManager.add(obj);
148
+
149
+ return obj;
150
+ }
151
+
139
152
  /**
140
153
  * Set Moodle configuration on plugin.
141
154
  * @param {string} editor - Editor instance.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wiris/mathtype-tinymce6",
3
- "version": "8.5.0",
3
+ "version": "8.7.0",
4
4
  "description": "MathType Web for TinyMCE6 editor",
5
5
  "keywords": [
6
6
  "chem",
@@ -32,7 +32,7 @@
32
32
  "prepack": "yarn && npm run build"
33
33
  },
34
34
  "dependencies": {
35
- "@wiris/mathtype-html-integration-devkit": "1.13.0"
35
+ "@wiris/mathtype-html-integration-devkit": "1.14.1"
36
36
  },
37
37
  "devDependencies": {
38
38
  "@babel/core": "^7.15.0",