]> BookStack Code Mirror - bookstack/blobdiff - resources/js/wysiwyg-tinymce/fixes.js
respective book and chapter structure added.
[bookstack] / resources / js / wysiwyg-tinymce / fixes.js
index b6d627ff79652b39a74a5d8a2b3986294597f8de..9e5cce43c50a5f195d9d68eb130653ac480a137e 100644 (file)
@@ -144,11 +144,13 @@ export function handleTableCellRangeEvents(editor) {
             cell.removeAttribute('align');
             cleanChildAlignment(cell);
         },
-        JustifyRight: this.JustifyLeft,
-        JustifyCenter: this.JustifyLeft,
-        JustifyFull: this.JustifyLeft,
     };
 
+    // Copy justify left action to other alignment actions
+    actionByCommand.JustifyRight = actionByCommand.JustifyLeft;
+    actionByCommand.JustifyCenter = actionByCommand.JustifyLeft;
+    actionByCommand.JustifyFull = actionByCommand.JustifyLeft;
+
     editor.on('ExecCommand', event => {
         const action = actionByCommand[event.command];
         if (action) {