diff --git a/dist/Valine.Pure.min.js b/dist/Valine.Pure.min.js
index 08904091..785e9235 100644
--- a/dist/Valine.Pure.min.js
+++ b/dist/Valine.Pure.min.js
@@ -1,5 +1,5 @@
/*!
- * Valine v1.2.2
+ * Valine v1.2.3
* (c) 2017-2018 xCss
* Released under the GPL-2.0 License.
*/
@@ -8,4 +8,4 @@
license: MIT
http://www.jacklmoore.com/autosize
*/
-!function(n,a){i=[e,t],r=a,void 0!==(o="function"==typeof r?r.apply(t,i):r)&&(e.exports=o)}(0,function(e,t){"use strict";function n(e){function t(t){var n=e.style.width;e.style.width="0px",e.offsetWidth,e.style.width=n,e.style.overflowY=t}function n(e){for(var t=[];e&&e.parentNode&&e.parentNode instanceof Element;)e.parentNode.scrollTop&&t.push({node:e.parentNode,scrollTop:e.parentNode.scrollTop}),e=e.parentNode;return t}function r(){if(0!==e.scrollHeight){var t=n(e),r=document.documentElement&&document.documentElement.scrollTop;e.style.height="",e.style.height=e.scrollHeight+s+"px",l=e.clientWidth,t.forEach(function(e){e.node.scrollTop=e.scrollTop}),r&&(document.documentElement.scrollTop=r)}}function i(){r();var n=Math.round(parseFloat(e.style.height)),i=window.getComputedStyle(e,null),o="content-box"===i.boxSizing?Math.round(parseFloat(i.height)):e.offsetHeight;if(o
v1.2.3'+n+"
"),console)},r.prototype.installLocale=function(e,t){var n=this;return t=t||{},e&&(h[e]=t,n.locale=h[e]||h["zh-cn"]),n},r.prototype.setPath=function(e){return m=e||m,this},r.prototype.bind=function(e){var t=this,n=u.find(t.el,".vemojis"),r=u.find(t.el,".vpreview"),i=u.find(t.el,".vemoji-btn"),h=u.find(t.el,".vpreview-btn"),g=d.data;for(var x in g)g.hasOwnProperty(x)&&function(e,r){var i=u.create("i",{name:e,title:e});i.innerHTML=r,n.appendChild(i),u.on("click",i,function(e){var n=u.find(t.el,".veditor");E(n,r),k(n)})}(x,g[x]);t.emoji={show:function(){return t.preview.hide(),u.attr(i,"v",1),u.removeAttr(h,"v"),u.attr(n,"style","display:block"),t.emoji},hide:function(){return u.removeAttr(i,"v"),u.attr(n,"style","display:hide"),t.emoji}},t.preview={show:function(){return t.emoji.hide(),u.attr(h,"v",1),u.removeAttr(i,"v"),r.innerHTML=p.comment,u.attr(r,"style","display:block"),L(),t.preview},hide:function(){return u.removeAttr(h,"v"),u.attr(r,"style","display:none"),t.preview},empty:function(){return r.innerHtml="",t.preview}};var y=function(e){var t=u.create("div");t.innerHTML=e;var n=u.findAll(t,"*");return u.each(n,function(e,t){if(1!==t.nodeType)return!1;if("A"===t.nodeName){var n=u.attr(t,"href");u.attr(t,"href",n.replace(/(javascript|eval)/gi,""))}u.clearAttr(t)}),t.innerHTML},k=function(e){var t=e.value||"";t=d.parse(t),e.value=t,s(e);var n=y(a(t));p.comment=n,r.innerHTML=n};u.on("click",i,function(e){u.attr(i,"v")?t.emoji.hide():t.emoji.show()}),u.on("click",h,function(e){if(""!=p.comment){u.attr(h,"v")?t.preview.hide():t.preview.show()}});for(var w=e.meta,_={},$={veditor:"comment"},O=0,A=w.length;O0&&void 0!==arguments[0]?arguments[0]:1,i=e.pageSize,o=Number(u.find(t.el,".vnum").innerText);t.loading.show();var a=t.Q(m);a.limit(i),a.skip((r-1)*i),a.find().then(function(e){for(var a=e.length,s=[],l=0;l'+t.locale.ctrl.more+"":"";var p=u.find(d,".vmore");p&&u.on("click",p,function(e){d.innerHTML="",n(++r)}),t.loading.hide()}).catch(function(e){t.loading.hide().ErrorHandler(e.code)})};t.Q(m).count().then(function(e){e>0?(u.attr(u.find(t.el,".vinfo"),"style","display:block;"),u.find(t.el,".vcount").innerHTML=''+e+" "+t.locale.tips.comments,C()):t.loading.hide()}).catch(function(e){t.ErrorHandler(e.code)});var T=function(e,n,r){var i=u.create("div",{class:"vcard",id:e.id}),a=f.hide?"":'",s=e.get("ua")||"";if(s){s=c(s);s.browser,s.version,s.os,s.osVersion}var d="",p=e.get("link")||"";d=p?''+e.get("nick")+"":''+e.get("nick")+"",i.innerHTML=a+'\n
"+r.error,ctxt:t.locale.ctrl.ok}):H(n).then(function(t){e(n)}).catch(function(e){})})};u.on("click",Q,W),u.on("keydown",document,function(e){e=event||e;var n=e.keyCode||e.which||e.charCode;if(((e.ctrlKey||e.metaKey)&&13===n&&W(),9===n)&&"veditor"==(document.activeElement.id||"")){e.preventDefault();var r=u.find(t.el,".veditor");E(r," ")}})};var b={mail:function(e){return{k:/[\w-\.]+@([\w-]+\.)+[a-z]{2,3}/.test(e),v:e}},link:function(e){return e=e.length>0&&(/^https?/.test(e)?e:"http://"+e),{k:/^https?:\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:\/~\+#]*[\w\-\@?^=%&\/~\+#])?/.test(e),v:e}}};e.exports=i,e.exports.default=i},function(e,t,n){"use strict";var r={data:n(9),parse:function(e){return String(e).replace(/:(.+?):/g,function(e,t){return r.data[t]||e})}};e.exports=r},function(e,t,n){"use strict";function r(e){var t=this,n={Trident:e.indexOf("Trident")>-1||e.indexOf("NET CLR")>-1,Presto:e.indexOf("Presto")>-1,WebKit:e.indexOf("AppleWebKit")>-1,Gecko:e.indexOf("Gecko/")>-1,Safari:e.indexOf("Safari")>-1,Chrome:e.indexOf("Chrome")>-1||e.indexOf("CriOS")>-1,IE:e.indexOf("MSIE")>-1||e.indexOf("Trident")>-1,Edge:e.indexOf("Edge")>-1,Firefox:e.indexOf("Firefox")>-1||e.indexOf("FxiOS")>-1,"Firefox Focus":e.indexOf("Focus")>-1,Chromium:e.indexOf("Chromium")>-1,Opera:e.indexOf("Opera")>-1||e.indexOf("OPR")>-1,Vivaldi:e.indexOf("Vivaldi")>-1,Yandex:e.indexOf("YaBrowser")>-1,Kindle:e.indexOf("Kindle")>-1||e.indexOf("Silk/")>-1,360:e.indexOf("360EE")>-1||e.indexOf("360SE")>-1,UC:e.indexOf("UC")>-1||e.indexOf(" UBrowser")>-1,QQBrowser:e.indexOf("QQBrowser")>-1,QQ:e.indexOf("QQ/")>-1,Baidu:e.indexOf("Baidu")>-1||e.indexOf("BIDUBrowser")>-1,Maxthon:e.indexOf("Maxthon")>-1,Sogou:e.indexOf("MetaSr")>-1||e.indexOf("Sogou")>-1,LBBROWSER:e.indexOf("LBBROWSER")>-1,"2345Explorer":e.indexOf("2345Explorer")>-1,TheWorld:e.indexOf("TheWorld")>-1,XiaoMi:e.indexOf("MiuiBrowser")>-1,Quark:e.indexOf("Quark")>-1,Qiyu:e.indexOf("Qiyu")>-1,Wechat:e.indexOf("MicroMessenger")>-1,Taobao:e.indexOf("AliApp(TB")>-1,Alipay:e.indexOf("AliApp(AP")>-1,Weibo:e.indexOf("Weibo")>-1,Douban:e.indexOf("com.douban.frodo")>-1,Suning:e.indexOf("SNEBUY-APP")>-1,iQiYi:e.indexOf("IqiyiApp")>-1,Windows:e.indexOf("Windows")>-1,Linux:e.indexOf("Linux")>-1||e.indexOf("X11")>-1,"Mac OS":e.indexOf("Macintosh")>-1,Android:e.indexOf("Android")>-1||e.indexOf("Adr")>-1,Ubuntu:e.indexOf("Ubuntu")>-1,FreeBSD:e.indexOf("FreeBSD")>-1,Debian:e.indexOf("Debian")>-1,"Windows Phone":e.indexOf("IEMobile")>-1||e.indexOf("Windows Phone")>-1,BlackBerry:e.indexOf("BlackBerry")>-1||e.indexOf("RIM")>-1,MeeGo:e.indexOf("MeeGo")>-1,Symbian:e.indexOf("Symbian")>-1,iOS:e.indexOf("like Mac OS X")>-1,"Chrome OS":e.indexOf("CrOS")>-1,WebOS:e.indexOf("hpwOS")>-1,Mobile:e.indexOf("Mobi")>-1||e.indexOf("iPh")>-1||e.indexOf("480")>-1,Tablet:e.indexOf("Tablet")>-1||e.indexOf("Pad")>-1||e.indexOf("Nexus 7")>-1};n.Mobile&&(n.Mobile=!(e.indexOf("iPad")>-1));var r={engine:["WebKit","Trident","Gecko","Presto"],browser:["Safari","Chrome","Edge","IE","Firefox","Firefox Focus","Chromium","Opera","Vivaldi","Yandex","Kindle","360","UC","QQBrowser","QQ","Baidu","Maxthon","Sogou","LBBROWSER","2345Explorer","TheWorld","XiaoMi","Quark","Qiyu","Wechat","Taobao","Alipay","Weibo","Douban","Suning","iQiYi"],os:["Windows","Linux","Mac OS","Android","Ubuntu","FreeBSD","Debian","iOS","Windows Phone","BlackBerry","MeeGo","Symbian","Chrome OS","WebOS"],device:["Mobile","Tablet"]};t.device="PC";for(var i in r)for(var o=0;o
"+s(e.message+"",!0)+"";throw e}}var g={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:d,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,nptable:d,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|\\n*|\\n*|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$)|(?!script|pre|style)[a-z][\\w-]*\\s*>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,table:d,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading| {0,3}>|<\/?(?:tag)(?: +|\n|\/?>)|<(?:script|pre|style|!--))[^\n]+)*)/,text:/^[^\n]+/};g._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,g._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,g.def=c(g.def).replace("label",g._label).replace("title",g._title).getRegex(),g.bullet=/(?:[*+-]|\d+\.)/,g.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,g.item=c(g.item,"gm").replace(/bull/g,g.bullet).getRegex(),g.list=c(g.list).replace(/bull/g,g.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+g.def.source+")").getRegex(),g._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",g._comment=//,g.html=c(g.html,"i").replace("comment",g._comment).replace("tag",g._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),g.paragraph=c(g.paragraph).replace("hr",g.hr).replace("heading",g.heading).replace("lheading",g.lheading).replace("tag",g._tag).getRegex(),g.blockquote=c(g.blockquote).replace("paragraph",g.paragraph).getRegex(),g.normal=p({},g),g.gfm=p({},g.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\n? *\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),g.gfm.paragraph=c(g.paragraph).replace("(?!","(?!"+g.gfm.fences.source.replace("\\1","\\2")+"|"+g.list.source.replace("\\1","\\3")+"|").getRegex(),g.tables=p({},g.gfm,{nptable:/^ *([^|\n ].*\|.*)\n *([-:]+ *\|[-| :]*)(?:\n((?:.*[^>\n ].*(?:\n|$))*)\n*|$)/,table:/^ *\|(.+)\n *\|?( *[-:]+[-| :]*)(?:\n((?: *[^>\n ].*(?:\n|$))*)\n*|$)/}),g.pedantic=p({},g.normal,{html:c("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|
'+(n?e:s(e,!0))+"
\n":""+(n?e:s(e,!0))+"
"},i.prototype.blockquote=function(e){return"\n"+e+"\n"},i.prototype.html=function(e){return e},i.prototype.heading=function(e,t,n){return this.options.headerIds?"
"+e+"
\n"},i.prototype.table=function(e,t){return t&&(t=""+t+""),""+e+"
"},i.prototype.br=function(){return this.options.xhtml?"'+n+""),console)},r.prototype.installLocale=function(e,t){var n=this;return t=t||{},e&&(h[e]=t,n.locale=h[e]||h["zh-cn"]),n},r.prototype.setPath=function(e){return m=e||m,this},r.prototype.bind=function(e){var t=this,n=u.find(t.el,".vemojis"),r=u.find(t.el,".vpreview"),i=u.find(t.el,".vemoji-btn"),h=u.find(t.el,".vpreview-btn"),g=d.data;for(var x in g)g.hasOwnProperty(x)&&function(e,r){var i=u.create("i",{name:e,title:e});i.innerHTML=r,n.appendChild(i),u.on("click",i,function(e){var n=u.find(t.el,".veditor");E(n,r),k(n)})}(x,g[x]);t.emoji={show:function(){return t.preview.hide(),u.attr(i,"v",1),u.removeAttr(h,"v"),u.attr(n,"style","display:block"),t.emoji},hide:function(){return u.removeAttr(i,"v"),u.attr(n,"style","display:hide"),t.emoji}},t.preview={show:function(){return t.emoji.hide(),u.attr(h,"v",1),u.removeAttr(i,"v"),r.innerHTML=p.comment,u.attr(r,"style","display:block"),L(),t.preview},hide:function(){return u.removeAttr(h,"v"),u.attr(r,"style","display:none"),t.preview},empty:function(){return r.innerHtml="",t.preview}};var y=function(e){var t=u.create("div");t.innerHTML=e;var n=u.findAll(t,"*"),r=["INPUT","SCRIPT"];return u.each(n,function(e,n){if(1===n.nodeType){if(r.indexOf(n.nodeName)>-1&&("INPUT"===n.nodeName&&"checkbox"===u.attr(n,"type")?u.attr(n,"disabled","disabled"):u.remove(t,n)),"A"===n.nodeName){var i=u.attr(n,"href");i&&u.attr(n,"href",i.replace(/(javascript|eval)/gi,""))}u.clearAttr(n)}}),t.innerHTML},k=function(e){var t=e.value||"";t=d.parse(t),e.value=t,s(e);var n=a(y(t));p.comment=n,r.innerHTML=n};u.on("click",i,function(e){u.attr(i,"v")?t.emoji.hide():t.emoji.show()}),u.on("click",h,function(e){if(""!=p.comment){u.attr(h,"v")?t.preview.hide():t.preview.show()}});for(var w=e.meta,_={},O={veditor:"comment"},$=0,A=w.length;$0&&void 0!==arguments[0]?arguments[0]:1,i=e.pageSize,o=Number(u.find(t.el,".vnum").innerText);t.loading.show();var a=t.Q(m);a.limit(i),a.skip((r-1)*i),a.find().then(function(e){for(var a=e.length,s=[],l=0;l'+t.locale.ctrl.more+"":"";var p=u.find(d,".vmore");p&&u.on("click",p,function(e){d.innerHTML="",n(++r)}),t.loading.hide()}).catch(function(e){t.loading.hide().ErrorHandler(e.code)})};t.Q(m).count().then(function(e){e>0?(u.attr(u.find(t.el,".vinfo"),"style","display:block;"),u.find(t.el,".vcount").innerHTML=''+e+" "+t.locale.tips.comments,C()):t.loading.hide()}).catch(function(e){t.ErrorHandler(e.code)});var M=function(e,n,r){var i=u.create("div",{class:"vcard",id:e.id}),a=f.hide?"":'",s=e.get("ua")||"",d="";if(s){s=c(s);d=''+s.browser+" "+s.version+""+" "+(''+s.os+" "+s.osVersion+"")}var p="",h=e.get("link")||"";p=h?''+e.get("nick")+"":''+e.get("nick")+"",i.innerHTML=a+'\n
"+s(e.message+"",!0)+"";throw e}}var g={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:d,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,nptable:d,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|\\n*|\\n*|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$)|(?!script|pre|style)[a-z][\\w-]*\\s*>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,table:d,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading| {0,3}>|<\/?(?:tag)(?: +|\n|\/?>)|<(?:script|pre|style|!--))[^\n]+)*)/,text:/^[^\n]+/};g._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,g._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,g.def=c(g.def).replace("label",g._label).replace("title",g._title).getRegex(),g.bullet=/(?:[*+-]|\d+\.)/,g.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,g.item=c(g.item,"gm").replace(/bull/g,g.bullet).getRegex(),g.list=c(g.list).replace(/bull/g,g.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+g.def.source+")").getRegex(),g._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",g._comment=//,g.html=c(g.html,"i").replace("comment",g._comment).replace("tag",g._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),g.paragraph=c(g.paragraph).replace("hr",g.hr).replace("heading",g.heading).replace("lheading",g.lheading).replace("tag",g._tag).getRegex(),g.blockquote=c(g.blockquote).replace("paragraph",g.paragraph).getRegex(),g.normal=p({},g),g.gfm=p({},g.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\n? *\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),g.gfm.paragraph=c(g.paragraph).replace("(?!","(?!"+g.gfm.fences.source.replace("\\1","\\2")+"|"+g.list.source.replace("\\1","\\3")+"|").getRegex(),g.tables=p({},g.gfm,{nptable:/^ *([^|\n ].*\|.*)\n *([-:]+ *\|[-| :]*)(?:\n((?:.*[^>\n ].*(?:\n|$))*)\n*|$)/,table:/^ *\|(.+)\n *\|?( *[-:]+[-| :]*)(?:\n((?: *[^>\n ].*(?:\n|$))*)\n*|$)/}),g.pedantic=p({},g.normal,{html:c("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|
'+(n?e:s(e,!0))+"
\n":""+(n?e:s(e,!0))+"
"},i.prototype.blockquote=function(e){return"\n"+e+"\n"},i.prototype.html=function(e){return e},i.prototype.heading=function(e,t,n){return this.options.headerIds?"
"+e+"
\n"},i.prototype.table=function(e,t){return t&&(t=""+t+""),""+e+"
"},i.prototype.br=function(){return this.options.xhtml?"'+n+""),console)},r.prototype.installLocale=function(e,t){var n=this;return t=t||{},e&&(f[e]=t,n.locale=f[e]||f["zh-cn"]),n},r.prototype.setPath=function(e){return m=e||m,this},r.prototype.bind=function(e){var t=this,n=d.find(t.el,".vemojis"),r=d.find(t.el,".vpreview"),i=d.find(t.el,".vemoji-btn"),f=d.find(t.el,".vpreview-btn"),v=u.data;for(var b in v)v.hasOwnProperty(b)&&function(e,r){var i=d.create("i",{name:e,title:e});i.innerHTML=r,n.appendChild(i),d.on("click",i,function(e){var n=d.find(t.el,".veditor");C(n,r),w(n)})}(b,v[b]);t.emoji={show:function(){return t.preview.hide(),d.attr(i,"v",1),d.removeAttr(f,"v"),d.attr(n,"style","display:block"),t.emoji},hide:function(){return d.removeAttr(i,"v"),d.attr(n,"style","display:hide"),t.emoji}},t.preview={show:function(){return t.emoji.hide(),d.attr(f,"v",1),d.removeAttr(i,"v"),r.innerHTML=p.comment,d.attr(r,"style","display:block"),z(),t.preview},hide:function(){return d.removeAttr(f,"v"),d.attr(r,"style","display:none"),t.preview},empty:function(){return r.innerHtml="",t.preview}};var x=function(e){var t=d.create("div");t.innerHTML=e;var n=d.findAll(t,"*");return d.each(n,function(e,t){if(1!==t.nodeType)return!1;if("A"===t.nodeName){var n=d.attr(t,"href");d.attr(t,"href",n.replace(/(javascript|eval)/gi,""))}d.clearAttr(t)}),t.innerHTML},w=function(e){var t=e.value||"";t=u.parse(t),e.value=t,s(e);var n=x(a(t));p.comment=n,r.innerHTML=n};d.on("click",i,function(e){d.attr(i,"v")?t.emoji.hide():t.emoji.show()}),d.on("click",f,function(e){if(""!=p.comment){d.attr(f,"v")?t.preview.hide():t.preview.show()}});for(var k=e.meta,_={},O={veditor:"comment"},A=0,S=k.length;A
"+s(e.message+"",!0)+"";throw e}}var v={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:u,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,nptable:u,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|\\n*|\\n*|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$)|(?!script|pre|style)[a-z][\\w-]*\\s*>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,table:u,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading| {0,3}>|<\/?(?:tag)(?: +|\n|\/?>)|<(?:script|pre|style|!--))[^\n]+)*)/,text:/^[^\n]+/};v._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,v._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,v.def=c(v.def).replace("label",v._label).replace("title",v._title).getRegex(),v.bullet=/(?:[*+-]|\d+\.)/,v.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,v.item=c(v.item,"gm").replace(/bull/g,v.bullet).getRegex(),v.list=c(v.list).replace(/bull/g,v.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+v.def.source+")").getRegex(),v._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",v._comment=//,v.html=c(v.html,"i").replace("comment",v._comment).replace("tag",v._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),v.paragraph=c(v.paragraph).replace("hr",v.hr).replace("heading",v.heading).replace("lheading",v.lheading).replace("tag",v._tag).getRegex(),v.blockquote=c(v.blockquote).replace("paragraph",v.paragraph).getRegex(),v.normal=p({},v),v.gfm=p({},v.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\n? *\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),v.gfm.paragraph=c(v.paragraph).replace("(?!","(?!"+v.gfm.fences.source.replace("\\1","\\2")+"|"+v.list.source.replace("\\1","\\3")+"|").getRegex(),v.tables=p({},v.gfm,{nptable:/^ *([^|\n ].*\|.*)\n *([-:]+ *\|[-| :]*)(?:\n((?:.*[^>\n ].*(?:\n|$))*)\n*|$)/,table:/^ *\|(.+)\n *\|?( *[-:]+[-| :]*)(?:\n((?: *[^>\n ].*(?:\n|$))*)\n*|$)/}),v.pedantic=p({},v.normal,{html:c("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|
'+(n?e:s(e,!0))+"
\n":""+(n?e:s(e,!0))+"
"},i.prototype.blockquote=function(e){return"\n"+e+"\n"},i.prototype.html=function(e){return e},i.prototype.heading=function(e,t,n){return this.options.headerIds?"
"+e+"
\n"},i.prototype.table=function(e,t){return t&&(t=""+t+""),""+e+"
"},i.prototype.br=function(){return this.options.xhtml?"'+n+""),console)},r.prototype.installLocale=function(e,t){var n=this;return t=t||{},e&&(f[e]=t,n.locale=f[e]||f["zh-cn"]),n},r.prototype.setPath=function(e){return m=e||m,this},r.prototype.bind=function(e){var t=this,n=d.find(t.el,".vemojis"),r=d.find(t.el,".vpreview"),i=d.find(t.el,".vemoji-btn"),f=d.find(t.el,".vpreview-btn"),v=u.data;for(var b in v)v.hasOwnProperty(b)&&function(e,r){var i=d.create("i",{name:e,title:e});i.innerHTML=r,n.appendChild(i),d.on("click",i,function(e){var n=d.find(t.el,".veditor");C(n,r),w(n)})}(b,v[b]);t.emoji={show:function(){return t.preview.hide(),d.attr(i,"v",1),d.removeAttr(f,"v"),d.attr(n,"style","display:block"),t.emoji},hide:function(){return d.removeAttr(i,"v"),d.attr(n,"style","display:hide"),t.emoji}},t.preview={show:function(){return t.emoji.hide(),d.attr(f,"v",1),d.removeAttr(i,"v"),r.innerHTML=p.comment,d.attr(r,"style","display:block"),T(),t.preview},hide:function(){return d.removeAttr(f,"v"),d.attr(r,"style","display:none"),t.preview},empty:function(){return r.innerHtml="",t.preview}};var x=function(e){var t=d.create("div");t.innerHTML=e;var n=d.findAll(t,"*"),r=["INPUT","SCRIPT"];return d.each(n,function(e,n){if(1===n.nodeType){if(r.indexOf(n.nodeName)>-1&&("INPUT"===n.nodeName&&"checkbox"===d.attr(n,"type")?d.attr(n,"disabled","disabled"):d.remove(t,n)),"A"===n.nodeName){var i=d.attr(n,"href");i&&d.attr(n,"href",i.replace(/(javascript|eval)/gi,""))}d.clearAttr(n)}}),t.innerHTML},w=function(e){var t=e.value||"";t=u.parse(t),e.value=t,s(e);var n=a(x(t));p.comment=n,r.innerHTML=n};d.on("click",i,function(e){d.attr(i,"v")?t.emoji.hide():t.emoji.show()}),d.on("click",f,function(e){if(""!=p.comment){d.attr(f,"v")?t.preview.hide():t.preview.show()}});for(var k=e.meta,_={},O={veditor:"comment"},S=0,A=k.length;S0&&void 0!==arguments[0]?arguments[0]:1,i=e.pageSize,o=Number(d.find(t.el,".vnum").innerText);t.loading.show();var a=t.Q(m);a.limit(i),a.skip((r-1)*i),a.find().then(function(e){for(var a=e.length,s=[],l=0;l'+t.locale.ctrl.more+"":"";var p=d.find(u,".vmore");p&&d.on("click",p,function(e){u.innerHTML="",n(++r)}),t.loading.hide()}).catch(function(e){t.loading.hide().ErrorHandler(e.code)})};t.Q(m).count().then(function(e){e>0?(d.attr(d.find(t.el,".vinfo"),"style","display:block;"),d.find(t.el,".vcount").innerHTML=''+e+" "+t.locale.tips.comments,M()):t.loading.hide()}).catch(function(e){t.ErrorHandler(e.code)});var L=function(e,n,r){var i=d.create("div",{class:"vcard",id:e.id}),a=h.hide?"":'",s=e.get("ua")||"",u="";if(s){s=c(s);u=''+s.browser+" "+s.version+""+" "+(''+s.os+" "+s.osVersion+"")}var p="",f=e.get("link")||"";p=f?''+e.get("nick")+"":''+e.get("nick")+"",i.innerHTML=a+'\n
"+s(e.message+"",!0)+"";throw e}}var v={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:u,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,nptable:u,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|\\n*|\\n*|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$)|(?!script|pre|style)[a-z][\\w-]*\\s*>(?=\\h*\\n)[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,table:u,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading| {0,3}>|<\/?(?:tag)(?: +|\n|\/?>)|<(?:script|pre|style|!--))[^\n]+)*)/,text:/^[^\n]+/};v._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,v._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,v.def=c(v.def).replace("label",v._label).replace("title",v._title).getRegex(),v.bullet=/(?:[*+-]|\d+\.)/,v.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,v.item=c(v.item,"gm").replace(/bull/g,v.bullet).getRegex(),v.list=c(v.list).replace(/bull/g,v.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+v.def.source+")").getRegex(),v._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",v._comment=//,v.html=c(v.html,"i").replace("comment",v._comment).replace("tag",v._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),v.paragraph=c(v.paragraph).replace("hr",v.hr).replace("heading",v.heading).replace("lheading",v.lheading).replace("tag",v._tag).getRegex(),v.blockquote=c(v.blockquote).replace("paragraph",v.paragraph).getRegex(),v.normal=p({},v),v.gfm=p({},v.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\n? *\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),v.gfm.paragraph=c(v.paragraph).replace("(?!","(?!"+v.gfm.fences.source.replace("\\1","\\2")+"|"+v.list.source.replace("\\1","\\3")+"|").getRegex(),v.tables=p({},v.gfm,{nptable:/^ *([^|\n ].*\|.*)\n *([-:]+ *\|[-| :]*)(?:\n((?:.*[^>\n ].*(?:\n|$))*)\n*|$)/,table:/^ *\|(.+)\n *\|?( *[-:]+[-| :]*)(?:\n((?: *[^>\n ].*(?:\n|$))*)\n*|$)/}),v.pedantic=p({},v.normal,{html:c("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|
'+(n?e:s(e,!0))+"
\n":""+(n?e:s(e,!0))+"
"},i.prototype.blockquote=function(e){return"\n"+e+"\n"},i.prototype.html=function(e){return e},i.prototype.heading=function(e,t,n){return this.options.headerIds?"
"+e+"
\n"},i.prototype.table=function(e,t){return t&&(t=""+t+""),""+e+"
"},i.prototype.br=function(){return this.options.xhtml?"