玛氪宕·梦魔(Markdown Memo),使用Markdown的云端备忘录,百度IFE的RIA启航班的不合格的作业,才……才没有什么阴谋呢! 源gitee链接https://gitee.com/arathi/MarkdownMemo?_from=gitee_search
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
21 KiB

/*! Editor.md v1.0.0 | editormd.min.js | A simple online markdown editor. | MIT License | By: Pandao | https://github.com/pandao/editor.md | 2015-02-08 */
!function(e){"use strict";"function"==typeof require&&"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define?define(["jquery"],e):window.editormd=e()}(function(){"use strict";var e=jQuery,t=function(e,i){return new t.fn.init(e,i)};return t.title="Editor.md",t.version="1.0.0",t.homePage="https://github.com/pandao/editor.md",t.description="A simple markdown doucment online editor.",t.classPrefix="editormd-",t.defaults={mode:"gfm",markdown:"",width:"100%",height:"100%",path:"./lib/",watch:!0,onload:function(){},onchange:function(){},onfullscreen:function(){},onfullscreenExit:function(){},toc:!0,tocStartLevel:2,fontSize:"13px",flowChart:!1,mathjax:!1,sequenceDiagram:!1,previewCodeHighlight:!0,inRequirejs:!1,toolbar:!0,toolbarIcons:["undo","redo","|","bold","del","italic","quote","|","h1","h2","h3","h4","h5","h6","|","list-ul","list-ol","hr","|","link","picture","code","code-block-tab","code-block","datetime","|","watch","preview","fullscreen","|","info"],toolbarIconsClass:{undo:"fa-undo",redo:"fa-repeat",bold:"fa-bold",del:"fa-strikethrough",italic:"fa-italic",quote:"fa-quote-left",h1:t.classPrefix+"bold",h2:t.classPrefix+"bold",h3:t.classPrefix+"bold",h4:t.classPrefix+"bold",h5:t.classPrefix+"bold",h6:t.classPrefix+"bold","list-ul":"fa-list-ul","list-ol":"fa-list-ol",hr:"fa-minus",link:"fa-link",picture:"fa-picture-o",code:"fa-code","code-block-tab":"fa-file-code-o","code-block":"fa-file-code-o",datetime:"fa-clock-o",watch:"fa-eye-slash",unwatch:"fa-eye",preview:"fa-search",fullscreen:"fa-arrows-alt",info:"fa-info-circle"},lang:{toolbar:{undo:"撤销",redo:"重做",bold:"粗体",del:"删除线",italic:"斜体",quote:"引用",h1:"标题1",h2:"标题2",h3:"标题3",h4:"标题4",h5:"标题5",h6:"标题6","list-ul":"无序列表","list-ol":"有序列表",hr:"横线",link:"链接",picture:"图片",code:"行内代码","code-block-tab":"代码块(缩进风格)","code-block":"代码块(多语言风格)",datetime:"日期时间",watch:"关闭实时预览",unwatch:"开启实时预览",preview:"预览HTML(按ESC还原)",fullscreen:"全屏(按ESC还原)",info:"关于"+t.title}},codemirror:{modes:["css","sass","shell","sql","clike","php","xml","markdown","javascript","htmlmixed","gfm","http","go","dart","coffeescript","nginx","python","perl","lua","ruby","rst","smartymixed","yaml"],addons:["edit/trailingspace","dialog/dialog","search/searchcursor","search/search","scroll/annotatescrollbar","search/matchesonscrollbar","display/placeholder","edit/closetag","fold/xml-fold","mode/overlay","selection/active-line","edit/closebrackets","display/fullscreen","search/searchcursor","search/match-highlighter"]}},t.$marked=null,t.$CodeMirror=null,t.$prettyPrint=null,t.prototype=t.fn={state:{preview:!1,fullscreen:!1},init:function(i,r){r=r||{};var o=this,a=this.classPrefix=t.classPrefix,n=this.editor=e("#"+i),s=this.settings=e.extend(!0,t.defaults,r),l=""===s.markdown?n.children('[type="text/markdown"]').html():s.markdown;this.id=i,this.classNames={textarea:{html:this.classPrefix+"html-textarea",markdown:this.classPrefix+"markdown-textarea"}},n.css({width:"number"==typeof s.width?s.width+"px":s.width,height:"number"==typeof s.height?s.height+"px":s.height}),n.children('[type="text/markdown"]').remove();var c=['<div class="'+a+"dialog "+a+'dialog-info">','<a href="javascript:;" class="fa fa-close '+a+'dialog-close"></a>','<div class="'+a+'dialog-container">','<h1><i class="fa fa-lg fa-edit"></i>'+t.title+"<small>v"+t.version+"</small></h1>","<p>"+t.description+"</p>",'<p>Home page: <a href="'+t.homePage+'" traget="_blank">'+t.homePage+"</a></p>","<p>License: MIT</p>","</div>","</div>"].join("\n"),d=['<div class="'+a+'toolbar"><div class="'+a+'toolbar-container"><ul class="'+a+'menu"></ul></div></div>','<textarea id="test123" class="'+this.classNames.textarea.markdown+'" name="'+i+'-markdown-doc" placeholder="now coding markdown...">'+l+"</textarea>",'<textarea class="'+this.classNames.textarea.html+'" name="'+i+'-html-code"></textarea>','<div class="'+a+'preview"><div class="markdown-body '+a+'preview-container"