Liferay.Loader.define("portal-search-web$codemirror@5.62.0/addon/fold/comment-fold",["module","exports","require","../../lib/codemirror"],(function(e,t,o){window,function(e){"use strict";e.registerGlobalHelper("fold","comment",(function(e){return e.blockCommentStart&&e.blockCommentEnd}),(function(t,o){var r=t.getModeAt(o),n=r.blockCommentStart,i=r.blockCommentEnd;if(n&&i){for(var l,f=o.line,c=t.getLine(f),m=o.ch,a=0;;){var d=m<=0?-1:c.lastIndexOf(n,m-1);if(-1!=d){if(1==a&&d<o.ch)return;if(/comment/.test(t.getTokenTypeAt(e.Pos(f,d+1)))&&(0==d||c.slice(d-i.length,d)==i||!/comment/.test(t.getTokenTypeAt(e.Pos(f,d))))){l=d+n.length;break}m=d-1}else{if(1==a)return;a=1,m=c.length}}var s,b,g=1,u=t.lastLine();e:for(var h=f;h<=u;++h)for(var k=t.getLine(h),p=h==f?l:0;;){var v=k.indexOf(n,p),y=k.indexOf(i,p);if(v<0&&(v=k.length),y<0&&(y=k.length),(p=Math.min(v,y))==k.length)break;if(p==v)++g;else if(!--g){s=h,b=p;break e}++p}if(null!=s&&(f!=s||b!=l))return{from:e.Pos(f,l),to:e.Pos(s,b)}}}))}("object"==typeof t&&"object"==typeof e?o("../../lib/codemirror"):CodeMirror)}));
//# sourceMappingURL=comment-fold.js.map