mirror of
https://github.com/the-djmaze/snappymail.git
synced 2025-01-27 09:08:26 +08:00
Enable Squire by default and put CKEditor as option
This commit is contained in:
parent
996c747e45
commit
6c6a5dd03b
4 changed files with 7 additions and 8 deletions
|
@ -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();
|
||||
|
|
|
@ -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');
|
||||
}
|
||||
|
||||
|
|
|
@ -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),
|
||||
|
|
8
vendors/squire/build/squire-raw.js
vendored
8
vendors/squire/build/squire-raw.js
vendored
|
@ -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' );
|
||||
|
|
Loading…
Reference in a new issue