diff --git a/resources/js/wysiwyg/plugin-codeeditor.js b/resources/js/wysiwyg/plugin-codeeditor.js index db4490215..82052a40d 100644 --- a/resources/js/wysiwyg/plugin-codeeditor.js +++ b/resources/js/wysiwyg/plugin-codeeditor.js @@ -165,7 +165,6 @@ function register(editor, url) { showPopup(editor, textContent, '', (newCode, newLang) => { const pre = doc.createElement('pre'); const code = doc.createElement('code'); - console.log(newCode); code.classList.add(`language-${newLang}`); code.innerText = newCode; pre.append(code); diff --git a/resources/js/wysiwyg/plugin-drawio.js b/resources/js/wysiwyg/plugin-drawio.js index 7d679d539..54a160921 100644 --- a/resources/js/wysiwyg/plugin-drawio.js +++ b/resources/js/wysiwyg/plugin-drawio.js @@ -106,6 +106,8 @@ export function getPlugin(providedOptions) { icon: 'diagram', onAction() { editor.execCommand('drawio'); + // Hack to de-focus the tinymce editor toolbar + window.document.body.dispatchEvent(new Event('mousedown', {bubbles: true})); }, fetch(callback) { callback([