Commit c7158abd authored by Liang Ding's avatar Liang Ding

🎨 支持配置编辑器模式 #95

parent dcb10a17
......@@ -249,6 +249,7 @@ public class PreferenceConsole {
* "fixTermTypo": boolean, // Markdown 支持改进 https://github.com/88250/solo/issues/54
* "chinesePunct": boolean, // Markdown 支持改进 https://github.com/88250/solo/issues/54
* "inlineMathAllowDigitAfterOpenMarker": boolean, // Markdown 支持改进 https://github.com/88250/solo/issues/54
* "editorMode": "", // 支持配置编辑器模式 https://github.com/88250/solo/issues/95
* }
* }
* </pre>
......
......@@ -249,6 +249,11 @@
<div class="fn__clear"></div>
</div>
<div id="tabPreferencePanel_markdown" class="fn__none form">
${editorModeLabel}
<label><input name="editorMode" type="radio" value="wysiwyg">&nbsp;${editorModeWYSIWYGLabel} </label>
<label><input name="editorMode" type="radio" value="ir">&nbsp;${editorModeIRLabel} </label>
<label><input name="editorMode" type="radio" value="sv">&nbsp;${editorModeSVLabel} </label>
<#if !luteAvailable>
<div class="fn__clear">
${luteHTTPLabel}
......
......@@ -20,7 +20,7 @@
*
* @author <a href="http://vanessa.b3log.org">Liyuan Li</a>
* @author <a href="http://88250.b3log.org">Liang Ding</a>
* @version 1.3.0.4, Jan 24, 2020
* @version 1.3.0.5, Apr 6, 2020
*/
/* preference 相关操作 */
......@@ -200,8 +200,7 @@ admin.preference = {
'noticeBoard': $('#noticeBoard').val(),
'footerContent': $('#footerContent').val(),
'htmlHead': $('#htmlHead').val(),
'externalRelevantArticlesDisplayCount': $(
'#externalRelevantArticlesDisplayCount').val(),
'externalRelevantArticlesDisplayCount': $('#externalRelevantArticlesDisplayCount').val(),
'relevantArticlesDisplayCount': $('#relevantArticlesDisplayCount').val(),
'randomArticlesDisplayCount': $('#randomArticlesDisplayCount').val(),
'enableArticleUpdateHint': $('#enableArticleUpdateHint').prop('checked'),
......@@ -223,6 +222,7 @@ admin.preference = {
'fixTermTypo': $('#fixTermTypo').prop('checked'),
'chinesePunct': $('#chinesePunct').prop('checked'),
'inlineMathAllowDigitAfterOpenMarker': $('#inlineMathAllowDigitAfterOpenMarker').prop('checked'),
'editorMode': $("input[name='editorMode']:checked").val(),
},
}
......
......@@ -18,12 +18,16 @@
#
# Description: Solo language configurations(en_US).
# Version: 2.41.0.0, Apr 2, 2020
# Version: 2.42.0.0, Apr 6, 2020
# Author: Liang Ding
# Author: Liyuan Li
# Author: Dongxu Wang
#
editorModeSVLabel=Split View
editorModeIRLabel=Instant Rendering
editorModeWYSIWYGLabel=WYSIWYG
editorModeLabel=Editor Mode
viewLogLabel=View Log
categoryURIMustBeASCIILabel=Category URI only must be English char, digit or symbol, for example: programming-life
inlineMathAllowDigitAfterOpenMarkerLabel=Whether inline math formulas allow a starting $ followed by a number
......
......@@ -18,12 +18,16 @@
#
# Description: Solo default language configurations(zh_CN).
# Version: 2.41.0.0, Apr 2, 2020
# Version: 2.42.0.0, Apr 6, 2020
# Author: Liang Ding
# Author: Liyuan Li
# Author: Dongxu Wang
#
editorModeSVLabel=\u5206\u5C4F\u9884\u89C8
editorModeIRLabel=\u5373\u65F6\u6E32\u67D3
editorModeWYSIWYGLabel=\u6240\u89C1\u5373\u6240\u5F97
editorModeLabel=\u7F16\u8F91\u5668\u6A21\u5F0F
viewLogLabel=\u65E5\u5FD7\u6D4F\u89C8
categoryURIMustBeASCIILabel=\u5206\u7C7B URI \u53EA\u80FD\u4F7F\u7528\u82F1\u6587\u5B57\u6BCD\u3001\u6570\u5B57\u548C\u7B26\u53F7\uFF0C\u4F8B\u5982\uFF1Aprogramming-life
inlineMathAllowDigitAfterOpenMarkerLabel=\u5185\u8054\u6570\u5B66\u516C\u5F0F\u662F\u5426\u5141\u8BB8\u8D77\u59CB $ \u540E\u7D27\u8DDF\u6570\u5B57
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment