var SimpleMDE=require("./../../simplemde-markdown-editor/dist/simplemde.min.js"),SMDCSS=require("./../../simplemde-markdown-editor/dist/simplemde.min.css"),Markdown={basic:function(e,i,r){var n,t=($.extend({server:null,width:null,height:100,ready:function(){}},i),"bold,italic,strikethrough,heading,code,quote,unordered-list,ordered-list,clean-block,link".split(","));t.push({name:"image",action:function(){return window.callback.editorUploadImage(function(e){for(var i=[],r=0;r<e.length;r++)i.push("![图片]("+e[r]+")");n.codemirror.replaceSelection(i.join(" "))}),!0},className:"fa fa-image",title:"图片"}),t.push("preview");var o=$.extend({element:document.getElementById(e),spellChecker:!1,toolbar:t,status:!1},r);return n=new SimpleMDE(o),n.codemirror.on("change",function(){$("#"+e).val(n.value())}),n},simple:function(e,i,r){return Markdown.basic(e,i,r)}};module.exports=Markdown;