Liferay.Loader.define("portal-search-web$codemirror@5.62.0/addon/mode/multiplex",["module","exports","require","../../lib/codemirror"],(function(e,n,r){window,function(e){"use strict";e.multiplexingMode=function(n){var r=Array.prototype.slice.call(arguments,1);function t(e,n,r,t){if("string"==typeof n){var i=e.indexOf(n,r);return t&&i>-1?i+n.length:i}var o=n.exec(r?e.slice(r):e);return o?o.index+r+(t?o[0].length:0):-1}return{startState:function(){return{outer:e.startState(n),innerActive:null,inner:null,startingInner:!1}},copyState:function(r){return{outer:e.copyState(n,r.outer),innerActive:r.innerActive,inner:r.innerActive&&e.copyState(r.innerActive.mode,r.inner),startingInner:r.startingInner}},token:function(i,o){if(o.innerActive){var l=o.innerActive;if(a=i.string,!l.close&&i.sol())return o.innerActive=o.inner=null,this.token(i,o);if((d=l.close&&!o.startingInner?t(a,l.close,i.pos,l.parseDelimiters):-1)==i.pos&&!l.parseDelimiters)return i.match(l.close),o.innerActive=o.inner=null,l.delimStyle&&l.delimStyle+" "+l.delimStyle+"-close";d>-1&&(i.string=a.slice(0,d));var c=l.mode.token(i,o.inner);return d>-1?i.string=a:i.pos>i.start&&(o.startingInner=!1),d==i.pos&&l.parseDelimiters&&(o.innerActive=o.inner=null),l.innerStyle&&(c=c?c+" "+l.innerStyle:l.innerStyle),c}for(var s=1/0,a=i.string,u=0;u<r.length;++u){var d,v=r[u];if((d=t(a,v.open,i.pos))==i.pos){v.parseDelimiters||i.match(v.open),o.startingInner=!!v.parseDelimiters,o.innerActive=v;var m=0;if(n.indent){var p=n.indent(o.outer,"","");p!==e.Pass&&(m=p)}return o.inner=e.startState(v.mode,m),v.delimStyle&&v.delimStyle+" "+v.delimStyle+"-open"}-1!=d&&d<s&&(s=d)}s!=1/0&&(i.string=a.slice(0,s));var f=n.token(i,o.outer);return s!=1/0&&(i.string=a),f},indent:function(r,t,i){var o=r.innerActive?r.innerActive.mode:n;return o.indent?o.indent(r.innerActive?r.inner:r.outer,t,i):e.Pass},blankLine:function(t){var i=t.innerActive?t.innerActive.mode:n;if(i.blankLine&&i.blankLine(t.innerActive?t.inner:t.outer),t.innerActive)"\n"===t.innerActive.close&&(t.innerActive=t.inner=null);else for(var o=0;o<r.length;++o){var l=r[o];"\n"===l.open&&(t.innerActive=l,t.inner=e.startState(l.mode,i.indent?i.indent(t.outer,"",""):0))}},electricChars:n.electricChars,innerMode:function(e){return e.inner?{state:e.inner,mode:e.innerActive.mode}:{state:e.outer,mode:n}}}}}("object"==typeof n&&"object"==typeof e?r("../../lib/codemirror"):CodeMirror)}));
//# sourceMappingURL=multiplex.js.map