Liferay.Loader.define("journal-web$codemirror@5.65.12/addon/runmode/runmode",["module","exports","require","../../lib/codemirror"],(function(e,t,r){var n,o=void 0;window;n=function(e){"use strict";e.runMode=function(t,r,n,o){var a=e.getMode(e.defaults,r),d=o&&o.tabSize||e.defaults.tabSize;if(n.appendChild){var i=/MSIE \d/.test(navigator.userAgent)&&(null==document.documentMode||document.documentMode<9),c=n,u=0;c.textContent="",n=function(e,t){if("\n"==e)return c.appendChild(document.createTextNode(i?"\r":e)),void(u=0);for(var r="",n=0;;){var o=e.indexOf("\t",n);if(-1==o){r+=e.slice(n),u+=e.length-n;break}u+=o-n,r+=e.slice(n,o);var a=d-u%d;u+=a;for(var l=0;l<a;++l)r+=" ";n=o+1}if(t){var f=c.appendChild(document.createElement("span"));f.className="cm-"+t.replace(/ +/g," cm-"),f.appendChild(document.createTextNode(r))}else c.appendChild(document.createTextNode(r))}}for(var l=e.splitLines(t),f=o&&o.state||e.startState(a),s=0,m=l.length;s<m;++s){s&&n("\n");var p=new e.StringStream(l[s],null,{lookAhead:function(e){return l[s+e]},baseToken:function(){}});for(!p.string&&a.blankLine&&a.blankLine(f);!p.eol();){var v=a.token(p,f);n(p.current(),v,s,p.start,f,a),p.start=p.pos}}}},"object"==typeof t&&"object"==typeof e?n(r("../../lib/codemirror")):"function"==typeof o&&o.amd?o(["../../lib/codemirror"],n):n(CodeMirror)}));
//# sourceMappingURL=runmode.js.map