diff --git a/dev/boot.js b/dev/boot.js index 88b7f1995..069a7b030 100644 --- a/dev/boot.js +++ b/dev/boot.js @@ -194,6 +194,7 @@ win.__initAppData = appData => { throw e; }) .then(() => { + // Enable the old CKEditor if (appData.Auth && appData.StaticEditorJsLink) { loadScript(appData.StaticEditorJsLink).then(() => { win.__initEditor && win.__initEditor(); diff --git a/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php b/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php index bbc5716bc..891aa12b8 100644 --- a/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php +++ b/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php @@ -1498,9 +1498,7 @@ NewThemeLink IncludeCss TemplatesLink LangLink IncludeBackground PluginsLink Aut $aResult['StaticAppJsLink'] = $this->StaticPath('js/'.($bAppJsDebug ? '' : 'min/'). ($bAdmin ? 'admin' : 'app').($bAppJsDebug ? '' : '.min').'.js'); - if ($this->Config()->Get('labs', 'use_squire_html_editor', false)) { - $aResult['StaticEditorJsLink'] = null; - } else { + if ($this->Config()->Get('labs', 'use_ck_html_editor', false)) { $aResult['StaticEditorJsLink'] = $this->StaticPath('ckeditor/ckeditor.js'); } diff --git a/rainloop/v/0.0.0/app/libraries/RainLoop/Config/Application.php b/rainloop/v/0.0.0/app/libraries/RainLoop/Config/Application.php index 42deb2185..f830e80fd 100644 --- a/rainloop/v/0.0.0/app/libraries/RainLoop/Config/Application.php +++ b/rainloop/v/0.0.0/app/libraries/RainLoop/Config/Application.php @@ -350,7 +350,7 @@ Enables caching in the system'), 'use_imap_thread' => array(true), 'use_imap_move' => array(false), 'use_imap_expunge_all_on_delete' => array(false), - 'use_squire_html_editor' => array(false), + 'use_ck_html_editor' => array(false), 'imap_forwarded_flag' => array('$Forwarded'), 'imap_read_receipt_flag' => array('$ReadReceipt'), 'imap_body_text_limit' => array(555000), diff --git a/vendors/squire/build/squire-raw.js b/vendors/squire/build/squire-raw.js index 56df4e9aa..a766d00a4 100644 --- a/vendors/squire/build/squire-raw.js +++ b/vendors/squire/build/squire-raw.js @@ -66,7 +66,7 @@ const }, inlineNodeNames = /^(?:#text|A|ABBR|ACRONYM|B|BR|BD[IO]|CITE|CODE|DATA|DEL|DFN|EM|FONT|HR|IMG|INPUT|INS|KBD|Q|RP|RT|RUBY|SAMP|SMALL|SPAN|STR(IKE|ONG)|SU[BP]|TIME|U|VAR|WBR)$/, - phrasingElements = 'ABBR,AUDIO,B,BDO,BR,BUTTON,CANVAS,CITE,CODE,COMMAND,DATA,DATALIST,DFN,EM,EMBED,I,IFRAME,IMG,INPUT,KBD,KEYGEN,LABEL,MARK,MATH,METER,NOSCRIPT,OBJECT,OUTPUT,PROGRESS,Q,RUBY,SAMP,SCRIPT,SELECT,SMALL,SPAN,STRONG,SUB,SUP,SVG,TEXTAREA,TIME,VAR,VIDEO,WBR', +// phrasingElements = 'ABBR,AUDIO,B,BDO,BR,BUTTON,CANVAS,CITE,CODE,COMMAND,DATA,DATALIST,DFN,EM,EMBED,I,IFRAME,IMG,INPUT,KBD,KEYGEN,LABEL,MARK,MATH,METER,NOSCRIPT,OBJECT,OUTPUT,PROGRESS,Q,RUBY,SAMP,SCRIPT,SELECT,SMALL,SPAN,STRONG,SUB,SUP,SVG,TEXTAREA,TIME,VAR,VIDEO,WBR', leafNodeNames = { BR: 1, @@ -304,7 +304,7 @@ const // Recursively examine container nodes and wrap any inline children. fixContainer = ( container, root ) => { - let children = container.children; + let children = container.childNodes; let wrapper = null; let i, l, child, isBR; @@ -312,7 +312,7 @@ const child = children[i]; isBR = child.nodeName === 'BR'; if ( !isBR && isInline( child ) - && (this._config.blockTag !== 'DIV' || !child.matches(phrasingElements)) +// && (root.__squire__._config.blockTag !== 'DIV' || (child.matches && !child.matches(phrasingElements))) ) { if ( !wrapper ) { wrapper = createElement( doc, 'div' ); @@ -343,7 +343,7 @@ const [...container.children].forEach(child => { isBR = child.nodeName === 'BR'; if ( !isBR && isInline( child ) - && (root.__squire__._config.blockTag !== 'DIV' || !child.matches(phrasingElements)) +// && (root.__squire__._config.blockTag !== 'DIV' || (child.matches && !child.matches(phrasingElements))) ) { if ( !wrapper ) { wrapper = createElement( doc, 'div' );