Improve switching of wysiwyg/plain composer

This commit is contained in:
djmaze 2021-02-02 12:23:32 +01:00
parent cd2b3ace89
commit 90ee39b114
7 changed files with 103 additions and 135 deletions

View file

@ -85,7 +85,7 @@ export function createCKEditor(element)
reader.onloadend = () => {
if (reader.result && 'wysiwyg' === editor.mode) {
try {
editor.setData(editor.getData().replace(imageId, `<img src="${reader.result}" />`));
editor.setData(editor.getData().replace(imageId, `<img src="${reader.result}"/>`));
} catch (e) {} // eslint-disable-line no-empty
}
};