Fix #1556 fix auto-detection of dark mode even when it is disabled

This commit is contained in:
Kijin Sung 2021-01-10 00:39:53 +09:00
parent e3fa780295
commit 44ecff5e55
3 changed files with 5 additions and 3 deletions

View file

@ -84,7 +84,8 @@ function getAutoSavedSrl(ret_obj, response_tags, c) {
var fo_obj = getCkFormInstance(editor_sequence);
this.ckeconfig = $.extend({}, default_ckeconfig, opts.ckeconfig || {});
this.ckeconfig.bodyClass = this.ckeconfig.bodyClass + ' color_scheme_' + getColorScheme();
this.ckeconfig.bodyClass = this.ckeconfig.bodyClass + ' color_scheme_' + getColorScheme() +
($('body').hasClass('cke_auto_dark_mode') ? ' cke_auto_dark_mode' : '');
this.editor_sequence = data.editorSequence;
$form.attr('editor_sequence', data.editorSequence);