Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/dev' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
88250 committed Apr 14, 2020
2 parents 4626a92 + 0f99591 commit 846641e
Show file tree
Hide file tree
Showing 10 changed files with 30 additions and 27 deletions.
2 changes: 1 addition & 1 deletion src/main/resources/js/admin/admin.min.js

Large diffs are not rendered by default.

39 changes: 21 additions & 18 deletions src/main/resources/js/admin/editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.5.0.0, Apr 12, 2020
* @version 1.5.1.0, Apr 13, 2020
*/
admin.editors = {}

Expand Down Expand Up @@ -83,8 +83,10 @@ $.extend(SoloEditor.prototype, {
url: Label.uploadURL,
token: Label.uploadToken,
filename: function (name) {
return name.replace(/[^(a-zA-Z0-9\u4e00-\u9fa5\.)]/g, '').replace(/[\?\\/:|<>\*\[\]\(\)\$%\{\}@~]/g, '').replace('/\\s/g', '')
}
return name.replace(/[^(a-zA-Z0-9\u4e00-\u9fa5\.)]/g, '').
replace(/[\?\\/:|<>\*\[\]\(\)\$%\{\}@~]/g, '').
replace('/\\s/g', '')
},
},
height: this.conf.height,
counter: {
Expand All @@ -100,35 +102,36 @@ $.extend(SoloEditor.prototype, {
emoji: Label.emoji,
},
toolbarConfig: {
pin: true
}
pin: true,
},
after: () => {
if (typeof this.conf.fun === 'function') {
this.conf.fun()
}
},
}

if ($(window).width() < 768) {
options.toolbar = [
"emoji",
"bold",
"link",
"list",
"edit-mode",
"preview",
"fullscreen",
'emoji',
'bold',
'link',
'list',
'edit-mode',
'preview',
'fullscreen',
]
options.resize.enable = false
options.toolbarConfig.pin = true;
options.toolbarConfig.pin = true
}

if (typeof Vditor === 'undefined') {
Util.loadVditor(() => {
this.editor = new Vditor(this.conf.id, options)
});
})
} else {
this.editor = new Vditor(this.conf.id, options)
}

if (typeof this.conf.fun === 'function') {
this.conf.fun()
}
},
/*
* @description 获取编辑器值
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/skins/Finding/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/Jane/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/Medium/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/NeoEase/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/Pinghsu/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/metro-hot/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/next/js/common.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main/resources/skins/nijigen/js/common.min.js

Large diffs are not rendered by default.

0 comments on commit 846641e

Please # to comment.