mirror of https://github.com/mindoc-org/mindoc.git
feat:增加editor.md库的CDN
parent
327d6fb8d8
commit
19bf5a7389
|
@ -1,12 +1,12 @@
|
|||
$(function () {
|
||||
editormd.katexURL = {
|
||||
js : window.baseUrl + "/static/katex/katex",
|
||||
css : window.baseUrl + "/static/katex/katex"
|
||||
js : window.katex.js,
|
||||
css : window.katex.css
|
||||
};
|
||||
window.editor = editormd("docEditor", {
|
||||
width: "100%",
|
||||
height: "100%",
|
||||
path: window.baseUrl + "/static/editor.md/lib/",
|
||||
path: window.editormdLib,
|
||||
toolbar: true,
|
||||
placeholder: "本编辑器支持 Markdown 编辑,左边编写,右边预览。",
|
||||
imageUpload: true,
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
$(function () {
|
||||
editormd.katexURL = {
|
||||
js : window.baseUrl + "/static/katex/katex",
|
||||
css : window.baseUrl + "/static/katex/katex"
|
||||
js : window.katex.js,
|
||||
css : window.katex.css
|
||||
};
|
||||
window.addDocumentModalFormHtml = $(this).find("form").html();
|
||||
window.editor = editormd("docEditor", {
|
||||
width: "100%",
|
||||
height: "100%",
|
||||
path: window.baseUrl + "/static/editor.md/lib/",
|
||||
path: window.editormdLib,
|
||||
toolbar: true,
|
||||
placeholder: "本编辑器支持 Markdown 编辑,左边编写,右边预览。",
|
||||
imageUpload: true,
|
||||
|
|
|
@ -8,6 +8,8 @@
|
|||
<title>编辑文章 - Powered by MinDoc</title>
|
||||
<script type="text/javascript">
|
||||
window.baseUrl = "{{.BaseUrl}}";
|
||||
window.katex = { js: "{{cdnjs "/static/katex/katex"}}",css: "{{cdncss "/static/katex/katex"}}"};
|
||||
window.editormdLib = "{{cdnjs "/static/editor.md/lib/"}}";
|
||||
window.editor = null;
|
||||
window.editURL = "{{urlfor "BlogController.ManageEdit" "blogId" .Model.BlogId}}";
|
||||
window.imageUploadURL = "{{urlfor "BlogController.Upload" "blogId" .Model.BlogId}}";
|
||||
|
|
|
@ -8,6 +8,8 @@
|
|||
<title>编辑文档 - Powered by MinDoc</title>
|
||||
<script type="text/javascript">
|
||||
window.baseUrl = "{{.BaseUrl}}";
|
||||
window.katex = { js: "{{cdnjs "/static/katex/katex"}}",css: "{{cdncss "/static/katex/katex"}}"};
|
||||
window.editormdLib = "{{cdnjs "/static/editor.md/lib/"}}";
|
||||
window.editor = null;
|
||||
window.imageUploadURL = "{{urlfor "DocumentController.Upload" "identify" .Model.Identify}}";
|
||||
window.fileUploadURL = "{{urlfor "DocumentController.Upload" "identify" .Model.Identify}}";
|
||||
|
|
Loading…
Reference in New Issue