text: !(function(a){"object"==typeof exports&&"object"==typeof module?a(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],a):a(CodeMirror)})((function(a){"use strict";function b(a,b){var d=b.line,e=0,f=0,g=c.exec(a.getLine(d)),h=g[1];do{e+=1;var i=d+e,j=a.getLine(i),k=c.exec(j);if(k){var l=k[1],m=parseInt(g[3],10)+e-f,n=parseInt(k[3],10),o=n;if(h!==l||isNaN(n)){if(h.length>l.length)return;if(h.length<l.length&&1===e)return;f+=1}else m===n&&(o=n+1),m>n&&(o=m+1),a.replaceRange(j.replace(c,l+o+k[4]+k[5]),{line:i,ch:0},{line:i,ch:j.length})}}while(k)}var c=/^(\s*)(>[> ]*|[*+-] \[[x ]\]\s|[*+-]\s|(\d+)([.)]))(\s*)/,d=/^(\s*)(>[> ]*|[*+-] \[[x ]\]|[*+-]|(\d+)[.)])(\s*)$/,e=/[*+-]\s/;a.commands.newlineAndIndentContinueMarkdownList=function(f){if(f.getOption("disableInput"))return a.Pass;for(var g=f.listSelections(),h=[],i=0;i<g.length;i++){var j=g[i].head,k=f.getStateAfter(j.line),l=k.list!==!1,m=0!==k.quote,n=f.getLine(j.line),o=c.exec(n),p=/^\s*$/.test(n.slice(0,j.ch));if(!g[i].empty()||!l&&!m||!o||p)return void f.execCommand("newlineAndIndent");if(d.test(n))/>\s*$/.test(n)||f.replaceRange("",{line:j.line,ch:0},{line:j.line,ch:j.ch+1}),h[i]="\n";else{var q=o[1],r=o[5],s=!(e.test(o[2])||o[2].indexOf(">")>=0),t=s?parseInt(o[3],10)+1+o[4]:o[2].replace("x"," ");h[i]="\n"+q+t+r,s&&b(f,j)}}f.replaceSelections(h)}}));