Liferay.Loader.define("liferay!template-web$codemirror@5.65.2/addon/hint/anyword-hint",["module","exports","require","../../lib/codemirror"],(function(e,r,o){var i,t=void 0;window;i=function(e){"use strict";var r=/[\w$]+/;e.registerHelper("hint","anyword",(function(o,i){for(var t=i&&i.word||r,n=i&&i.range||500,a=o.getCursor(),l=o.getLine(a.line),c=a.ch,d=c;d&&t.test(l.charAt(d-1));)--d;for(var f=d!=c&&l.slice(d,c),s=i&&i.list||[],p={},u=new RegExp(t.source,"g"),m=-1;m<=1;m+=2)for(var h=a.line,w=Math.min(Math.max(h+m*n,o.firstLine()),o.lastLine())+m;h!=w;h+=m)for(var y,b=o.getLine(h);y=u.exec(b);)h==a.line&&y[0]===f||f&&0!=y[0].lastIndexOf(f,0)||Object.prototype.hasOwnProperty.call(p,y[0])||(p[y[0]]=!0,s.push(y[0]));return{list:s,from:e.Pos(a.line,d),to:e.Pos(a.line,c)}}))},"object"==typeof r&&"object"==typeof e?i(o("../../lib/codemirror")):"function"==typeof t&&t.amd?t(["../../lib/codemirror"],i):i(CodeMirror)}));
//# sourceMappingURL=anyword-hint.js.map