Moved CKEditor to be plugin

This commit is contained in:
djmaze 2021-03-25 13:35:15 +01:00
parent 240b0381f9
commit af3c79ce80
217 changed files with 467 additions and 8683 deletions

View file

@ -1,5 +1,3 @@
import { createCKEditor } from 'External/CKEditor.js';
const
htmlre = /[&<>"']/g,
htmlmap = {
@ -180,11 +178,11 @@ class HtmlEditor {
this.onReady && this.onReady();
};
if (window.CKEDITOR) {
this.editor = createCKEditor(this.element);
this.editor.on('instanceReady', onReady);
} else {
this.editor = new SquireUI(this.element, this.editor);
if (rl.createWYSIWYG) {
this.editor = rl.createWYSIWYG(this.element, onReady);
}
if (!this.editor) {
this.editor = new SquireUI(this.element);
setTimeout(onReady,1);
}