ber-security.graylog.graylog-plugin-alert-wizard.5.2.1.source-code.5c84e28b79a13688792139cf8ef0afbd.js.map Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of graylog-plugin-alert-wizard Show documentation
Show all versions of graylog-plugin-alert-wizard Show documentation
Graylog ${project.artifactId} plugin.
The newest version!
{"version":3,"sources":["webpack://AlertWizard/5c84e28b79a13688792139cf8ef0afbd.js"],"sourcesContent":["ace.define(\"ace/snippets\",[\"require\",\"exports\",\"module\",\"ace/lib/dom\",\"ace/lib/oop\",\"ace/lib/event_emitter\",\"ace/lib/lang\",\"ace/range\",\"ace/range_list\",\"ace/keyboard/hash_handler\",\"ace/tokenizer\",\"ace/clipboard\",\"ace/editor\"], function(require, exports, module){\"use strict\";\nvar dom = require(\"./lib/dom\");\nvar oop = require(\"./lib/oop\");\nvar EventEmitter = require(\"./lib/event_emitter\").EventEmitter;\nvar lang = require(\"./lib/lang\");\nvar Range = require(\"./range\").Range;\nvar RangeList = require(\"./range_list\").RangeList;\nvar HashHandler = require(\"./keyboard/hash_handler\").HashHandler;\nvar Tokenizer = require(\"./tokenizer\").Tokenizer;\nvar clipboard = require(\"./clipboard\");\nvar VARIABLES = {\n CURRENT_WORD: function (editor) {\n return editor.session.getTextRange(editor.session.getWordRange());\n },\n SELECTION: function (editor, name, indentation) {\n var text = editor.session.getTextRange();\n if (indentation)\n return text.replace(/\\n\\r?([ \\t]*\\S)/g, \"\\n\" + indentation + \"$1\");\n return text;\n },\n CURRENT_LINE: function (editor) {\n return editor.session.getLine(editor.getCursorPosition().row);\n },\n PREV_LINE: function (editor) {\n return editor.session.getLine(editor.getCursorPosition().row - 1);\n },\n LINE_INDEX: function (editor) {\n return editor.getCursorPosition().row;\n },\n LINE_NUMBER: function (editor) {\n return editor.getCursorPosition().row + 1;\n },\n SOFT_TABS: function (editor) {\n return editor.session.getUseSoftTabs() ? \"YES\" : \"NO\";\n },\n TAB_SIZE: function (editor) {\n return editor.session.getTabSize();\n },\n CLIPBOARD: function (editor) {\n return clipboard.getText && clipboard.getText();\n },\n FILENAME: function (editor) {\n return /[^/\\\\]*$/.exec(this.FILEPATH(editor))[0];\n },\n FILENAME_BASE: function (editor) {\n return /[^/\\\\]*$/.exec(this.FILEPATH(editor))[0].replace(/\\.[^.]*$/, \"\");\n },\n DIRECTORY: function (editor) {\n return this.FILEPATH(editor).replace(/[^/\\\\]*$/, \"\");\n },\n FILEPATH: function (editor) { return \"/not implemented.txt\"; },\n WORKSPACE_NAME: function () { return \"Unknown\"; },\n FULLNAME: function () { return \"Unknown\"; },\n BLOCK_COMMENT_START: function (editor) {\n var mode = editor.session.$mode || {};\n return mode.blockComment && mode.blockComment.start || \"\";\n },\n BLOCK_COMMENT_END: function (editor) {\n var mode = editor.session.$mode || {};\n return mode.blockComment && mode.blockComment.end || \"\";\n },\n LINE_COMMENT: function (editor) {\n var mode = editor.session.$mode || {};\n return mode.lineCommentStart || \"\";\n },\n CURRENT_YEAR: date.bind(null, { year: \"numeric\" }),\n CURRENT_YEAR_SHORT: date.bind(null, { year: \"2-digit\" }),\n CURRENT_MONTH: date.bind(null, { month: \"numeric\" }),\n CURRENT_MONTH_NAME: date.bind(null, { month: \"long\" }),\n CURRENT_MONTH_NAME_SHORT: date.bind(null, { month: \"short\" }),\n CURRENT_DATE: date.bind(null, { day: \"2-digit\" }),\n CURRENT_DAY_NAME: date.bind(null, { weekday: \"long\" }),\n CURRENT_DAY_NAME_SHORT: date.bind(null, { weekday: \"short\" }),\n CURRENT_HOUR: date.bind(null, { hour: \"2-digit\", hour12: false }),\n CURRENT_MINUTE: date.bind(null, { minute: \"2-digit\" }),\n CURRENT_SECOND: date.bind(null, { second: \"2-digit\" })\n};\nVARIABLES.SELECTED_TEXT = VARIABLES.SELECTION;\nfunction date(dateFormat) {\n var str = new Date().toLocaleString(\"en-us\", dateFormat);\n return str.length == 1 ? \"0\" + str : str;\n}\nvar SnippetManager = function () {\n this.snippetMap = {};\n this.snippetNameMap = {};\n};\n(function () {\n oop.implement(this, EventEmitter);\n this.getTokenizer = function () {\n return SnippetManager.$tokenizer || this.createTokenizer();\n };\n this.createTokenizer = function () {\n function TabstopToken(str) {\n str = str.substr(1);\n if (/^\\d+$/.test(str))\n return [{ tabstopId: parseInt(str, 10) }];\n return [{ text: str }];\n }\n function escape(ch) {\n return \"(?:[^\\\\\\\\\" + ch + \"]|\\\\\\\\.)\";\n }\n var formatMatcher = {\n regex: \"/(\" + escape(\"/\") + \"+)/\",\n onMatch: function (val, state, stack) {\n var ts = stack[0];\n ts.fmtString = true;\n ts.guard = val.slice(1, -1);\n ts.flag = \"\";\n return \"\";\n },\n next: \"formatString\"\n };\n SnippetManager.$tokenizer = new Tokenizer({\n start: [\n { regex: /\\\\./, onMatch: function (val, state, stack) {\n var ch = val[1];\n if (ch == \"}\" && stack.length) {\n val = ch;\n }\n else if (\"`$\\\\\".indexOf(ch) != -1) {\n val = ch;\n }\n return [val];\n } },\n { regex: /}/, onMatch: function (val, state, stack) {\n return [stack.length ? stack.shift() : val];\n } },\n { regex: /\\$(?:\\d+|\\w+)/, onMatch: TabstopToken },\n { regex: /\\$\\{[\\dA-Z_a-z]+/, onMatch: function (str, state, stack) {\n var t = TabstopToken(str.substr(1));\n stack.unshift(t[0]);\n return t;\n }, next: \"snippetVar\" },\n { regex: /\\n/, token: \"newline\", merge: false }\n ],\n snippetVar: [\n { regex: \"\\\\|\" + escape(\"\\\\|\") + \"*\\\\|\", onMatch: function (val, state, stack) {\n var choices = val.slice(1, -1).replace(/\\\\[,|\\\\]|,/g, function (operator) {\n return operator.length == 2 ? operator[1] : \"\\x00\";\n }).split(\"\\x00\").map(function (value) {\n return { value: value };\n });\n stack[0].choices = choices;\n return [choices[0]];\n }, next: \"start\" },\n formatMatcher,\n { regex: \"([^:}\\\\\\\\]|\\\\\\\\.)*:?\", token: \"\", next: \"start\" }\n ],\n formatString: [\n { regex: /:/, onMatch: function (val, state, stack) {\n if (stack.length && stack[0].expectElse) {\n stack[0].expectElse = false;\n stack[0].ifEnd = { elseEnd: stack[0] };\n return [stack[0].ifEnd];\n }\n return \":\";\n } },\n { regex: /\\\\./, onMatch: function (val, state, stack) {\n var ch = val[1];\n if (ch == \"}\" && stack.length)\n val = ch;\n else if (\"`$\\\\\".indexOf(ch) != -1)\n val = ch;\n else if (ch == \"n\")\n val = \"\\n\";\n else if (ch == \"t\")\n val = \"\\t\";\n else if (\"ulULE\".indexOf(ch) != -1)\n val = { changeCase: ch, local: ch > \"a\" };\n return [val];\n } },\n { regex: \"/\\\\w*}\", onMatch: function (val, state, stack) {\n var next = stack.shift();\n if (next)\n next.flag = val.slice(1, -1);\n this.next = next && next.tabstopId ? \"start\" : \"\";\n return [next || val];\n }, next: \"start\" },\n { regex: /\\$(?:\\d+|\\w+)/, onMatch: function (val, state, stack) {\n return [{ text: val.slice(1) }];\n } },\n { regex: /\\${\\w+/, onMatch: function (val, state, stack) {\n var token = { text: val.slice(2) };\n stack.unshift(token);\n return [token];\n }, next: \"formatStringVar\" },\n { regex: /\\n/, token: \"newline\", merge: false },\n { regex: /}/, onMatch: function (val, state, stack) {\n var next = stack.shift();\n this.next = next && next.tabstopId ? \"start\" : \"\";\n return [next || val];\n }, next: \"start\" }\n ],\n formatStringVar: [\n { regex: /:\\/\\w+}/, onMatch: function (val, state, stack) {\n var ts = stack[0];\n ts.formatFunction = val.slice(2, -1);\n return [stack.shift()];\n }, next: \"formatString\" },\n formatMatcher,\n { regex: /:[\\?\\-+]?/, onMatch: function (val, state, stack) {\n if (val[1] == \"+\")\n stack[0].ifEnd = stack[0];\n if (val[1] == \"?\")\n stack[0].expectElse = true;\n }, next: \"formatString\" },\n { regex: \"([^:}\\\\\\\\]|\\\\\\\\.)*:?\", token: \"\", next: \"formatString\" }\n ]\n });\n return SnippetManager.$tokenizer;\n };\n this.tokenizeTmSnippet = function (str, startState) {\n return this.getTokenizer().getLineTokens(str, startState).tokens.map(function (x) {\n return x.value || x;\n });\n };\n this.getVariableValue = function (editor, name, indentation) {\n if (/^\\d+$/.test(name))\n return (this.variables.__ || {})[name] || \"\";\n if (/^[A-Z]\\d+$/.test(name))\n return (this.variables[name[0] + \"__\"] || {})[name.substr(1)] || \"\";\n name = name.replace(/^TM_/, \"\");\n if (!this.variables.hasOwnProperty(name))\n return \"\";\n var value = this.variables[name];\n if (typeof value == \"function\")\n value = this.variables[name](editor, name, indentation);\n return value == null ? \"\" : value;\n };\n this.variables = VARIABLES;\n this.tmStrFormat = function (str, ch, editor) {\n if (!ch.fmt)\n return str;\n var flag = ch.flag || \"\";\n var re = ch.guard;\n re = new RegExp(re, flag.replace(/[^gim]/g, \"\"));\n var fmtTokens = typeof ch.fmt == \"string\" ? this.tokenizeTmSnippet(ch.fmt, \"formatString\") : ch.fmt;\n var _self = this;\n var formatted = str.replace(re, function () {\n var oldArgs = _self.variables.__;\n _self.variables.__ = [].slice.call(arguments);\n var fmtParts = _self.resolveVariables(fmtTokens, editor);\n var gChangeCase = \"E\";\n for (var i = 0; i < fmtParts.length; i++) {\n var ch = fmtParts[i];\n if (typeof ch == \"object\") {\n fmtParts[i] = \"\";\n if (ch.changeCase && ch.local) {\n var next = fmtParts[i + 1];\n if (next && typeof next == \"string\") {\n if (ch.changeCase == \"u\")\n fmtParts[i] = next[0].toUpperCase();\n else\n fmtParts[i] = next[0].toLowerCase();\n fmtParts[i + 1] = next.substr(1);\n }\n }\n else if (ch.changeCase) {\n gChangeCase = ch.changeCase;\n }\n }\n else if (gChangeCase == \"U\") {\n fmtParts[i] = ch.toUpperCase();\n }\n else if (gChangeCase == \"L\") {\n fmtParts[i] = ch.toLowerCase();\n }\n }\n _self.variables.__ = oldArgs;\n return fmtParts.join(\"\");\n });\n return formatted;\n };\n this.tmFormatFunction = function (str, ch, editor) {\n if (ch.formatFunction == \"upcase\")\n return str.toUpperCase();\n if (ch.formatFunction == \"downcase\")\n return str.toLowerCase();\n return str;\n };\n this.resolveVariables = function (snippet, editor) {\n var result = [];\n var indentation = \"\";\n var afterNewLine = true;\n for (var i = 0; i < snippet.length; i++) {\n var ch = snippet[i];\n if (typeof ch == \"string\") {\n result.push(ch);\n if (ch == \"\\n\") {\n afterNewLine = true;\n indentation = \"\";\n }\n else if (afterNewLine) {\n indentation = /^\\t*/.exec(ch)[0];\n afterNewLine = /\\S/.test(ch);\n }\n continue;\n }\n if (!ch)\n continue;\n afterNewLine = false;\n if (ch.fmtString) {\n var j = snippet.indexOf(ch, i + 1);\n if (j == -1)\n j = snippet.length;\n ch.fmt = snippet.slice(i + 1, j);\n i = j;\n }\n if (ch.text) {\n var value = this.getVariableValue(editor, ch.text, indentation) + \"\";\n if (ch.fmtString)\n value = this.tmStrFormat(value, ch, editor);\n if (ch.formatFunction)\n value = this.tmFormatFunction(value, ch, editor);\n if (value && !ch.ifEnd) {\n result.push(value);\n gotoNext(ch);\n }\n else if (!value && ch.ifEnd) {\n gotoNext(ch.ifEnd);\n }\n }\n else if (ch.elseEnd) {\n gotoNext(ch.elseEnd);\n }\n else if (ch.tabstopId != null) {\n result.push(ch);\n }\n else if (ch.changeCase != null) {\n result.push(ch);\n }\n }\n function gotoNext(ch) {\n var i1 = snippet.indexOf(ch, i + 1);\n if (i1 != -1)\n i = i1;\n }\n return result;\n };\n var processSnippetText = function (editor, snippetText, replaceRange) {\n var cursor = editor.getCursorPosition();\n var line = editor.session.getLine(cursor.row);\n var tabString = editor.session.getTabString();\n var indentString = line.match(/^\\s*/)[0];\n if (cursor.column < indentString.length)\n indentString = indentString.slice(0, cursor.column);\n snippetText = snippetText.replace(/\\r/g, \"\");\n var tokens = this.tokenizeTmSnippet(snippetText);\n tokens = this.resolveVariables(tokens, editor);\n tokens = tokens.map(function (x) {\n if (x == \"\\n\")\n return x + indentString;\n if (typeof x == \"string\")\n return x.replace(/\\t/g, tabString);\n return x;\n });\n var tabstops = [];\n tokens.forEach(function (p, i) {\n if (typeof p != \"object\")\n return;\n var id = p.tabstopId;\n var ts = tabstops[id];\n if (!ts) {\n ts = tabstops[id] = [];\n ts.index = id;\n ts.value = \"\";\n ts.parents = {};\n }\n if (ts.indexOf(p) !== -1)\n return;\n if (p.choices && !ts.choices)\n ts.choices = p.choices;\n ts.push(p);\n var i1 = tokens.indexOf(p, i + 1);\n if (i1 === -1)\n return;\n var value = tokens.slice(i + 1, i1);\n var isNested = value.some(function (t) { return typeof t === \"object\"; });\n if (isNested && !ts.value) {\n ts.value = value;\n }\n else if (value.length && (!ts.value || typeof ts.value !== \"string\")) {\n ts.value = value.join(\"\");\n }\n });\n tabstops.forEach(function (ts) { ts.length = 0; });\n var expanding = {};\n function copyValue(val) {\n var copy = [];\n for (var i = 0; i < val.length; i++) {\n var p = val[i];\n if (typeof p == \"object\") {\n if (expanding[p.tabstopId])\n continue;\n var j = val.lastIndexOf(p, i - 1);\n p = copy[j] || { tabstopId: p.tabstopId };\n }\n copy[i] = p;\n }\n return copy;\n }\n for (var i = 0; i < tokens.length; i++) {\n var p = tokens[i];\n if (typeof p != \"object\")\n continue;\n var id = p.tabstopId;\n var ts = tabstops[id];\n var i1 = tokens.indexOf(p, i + 1);\n if (expanding[id]) {\n if (expanding[id] === p) {\n delete expanding[id];\n Object.keys(expanding).forEach(function (parentId) {\n ts.parents[parentId] = true;\n });\n }\n continue;\n }\n expanding[id] = p;\n var value = ts.value;\n if (typeof value !== \"string\")\n value = copyValue(value);\n else if (p.fmt)\n value = this.tmStrFormat(value, p, editor);\n tokens.splice.apply(tokens, [i + 1, Math.max(0, i1 - i)].concat(value, p));\n if (ts.indexOf(p) === -1)\n ts.push(p);\n }\n var row = 0, column = 0;\n var text = \"\";\n tokens.forEach(function (t) {\n if (typeof t === \"string\") {\n var lines = t.split(\"\\n\");\n if (lines.length > 1) {\n column = lines[lines.length - 1].length;\n row += lines.length - 1;\n }\n else\n column += t.length;\n text += t;\n }\n else if (t) {\n if (!t.start)\n t.start = { row: row, column: column };\n else\n t.end = { row: row, column: column };\n }\n });\n return {\n text: text,\n tabstops: tabstops,\n tokens: tokens\n };\n };\n this.getDisplayTextForSnippet = function (editor, snippetText) {\n var processedSnippet = processSnippetText.call(this, editor, snippetText);\n return processedSnippet.text;\n };\n this.insertSnippetForSelection = function (editor, snippetText, replaceRange) {\n var processedSnippet = processSnippetText.call(this, editor, snippetText);\n var range = editor.getSelectionRange();\n if (replaceRange && replaceRange.compareRange(range) === 0) {\n range = replaceRange;\n }\n var end = editor.session.replace(range, processedSnippet.text);\n var tabstopManager = new TabstopManager(editor);\n var selectionId = editor.inVirtualSelectionMode && editor.selection.index;\n tabstopManager.addTabstops(processedSnippet.tabstops, range.start, end, selectionId);\n };\n this.insertSnippet = function (editor, snippetText, replaceRange) {\n var self = this;\n if (editor.inVirtualSelectionMode)\n return self.insertSnippetForSelection(editor, snippetText, replaceRange);\n editor.forEachSelection(function () {\n self.insertSnippetForSelection(editor, snippetText, replaceRange);\n }, null, { keepOrder: true });\n if (editor.tabstopManager)\n editor.tabstopManager.tabNext();\n };\n this.$getScope = function (editor) {\n var scope = editor.session.$mode.$id || \"\";\n scope = scope.split(\"/\").pop();\n if (scope === \"html\" || scope === \"php\") {\n if (scope === \"php\" && !editor.session.$mode.inlinePhp)\n scope = \"html\";\n var c = editor.getCursorPosition();\n var state = editor.session.getState(c.row);\n if (typeof state === \"object\") {\n state = state[0];\n }\n if (state.substring) {\n if (state.substring(0, 3) == \"js-\")\n scope = \"javascript\";\n else if (state.substring(0, 4) == \"css-\")\n scope = \"css\";\n else if (state.substring(0, 4) == \"php-\")\n scope = \"php\";\n }\n }\n return scope;\n };\n this.getActiveScopes = function (editor) {\n var scope = this.$getScope(editor);\n var scopes = [scope];\n var snippetMap = this.snippetMap;\n if (snippetMap[scope] && snippetMap[scope].includeScopes) {\n scopes.push.apply(scopes, snippetMap[scope].includeScopes);\n }\n scopes.push(\"_\");\n return scopes;\n };\n this.expandWithTab = function (editor, options) {\n var self = this;\n var result = editor.forEachSelection(function () {\n return self.expandSnippetForSelection(editor, options);\n }, null, { keepOrder: true });\n if (result && editor.tabstopManager)\n editor.tabstopManager.tabNext();\n return result;\n };\n this.expandSnippetForSelection = function (editor, options) {\n var cursor = editor.getCursorPosition();\n var line = editor.session.getLine(cursor.row);\n var before = line.substring(0, cursor.column);\n var after = line.substr(cursor.column);\n var snippetMap = this.snippetMap;\n var snippet;\n this.getActiveScopes(editor).some(function (scope) {\n var snippets = snippetMap[scope];\n if (snippets)\n snippet = this.findMatchingSnippet(snippets, before, after);\n return !!snippet;\n }, this);\n if (!snippet)\n return false;\n if (options && options.dryRun)\n return true;\n editor.session.doc.removeInLine(cursor.row, cursor.column - snippet.replaceBefore.length, cursor.column + snippet.replaceAfter.length);\n this.variables.M__ = snippet.matchBefore;\n this.variables.T__ = snippet.matchAfter;\n this.insertSnippetForSelection(editor, snippet.content);\n this.variables.M__ = this.variables.T__ = null;\n return true;\n };\n this.findMatchingSnippet = function (snippetList, before, after) {\n for (var i = snippetList.length; i--;) {\n var s = snippetList[i];\n if (s.startRe && !s.startRe.test(before))\n continue;\n if (s.endRe && !s.endRe.test(after))\n continue;\n if (!s.startRe && !s.endRe)\n continue;\n s.matchBefore = s.startRe ? s.startRe.exec(before) : [\"\"];\n s.matchAfter = s.endRe ? s.endRe.exec(after) : [\"\"];\n s.replaceBefore = s.triggerRe ? s.triggerRe.exec(before)[0] : \"\";\n s.replaceAfter = s.endTriggerRe ? s.endTriggerRe.exec(after)[0] : \"\";\n return s;\n }\n };\n this.snippetMap = {};\n this.snippetNameMap = {};\n this.register = function (snippets, scope) {\n var snippetMap = this.snippetMap;\n var snippetNameMap = this.snippetNameMap;\n var self = this;\n if (!snippets)\n snippets = [];\n function wrapRegexp(src) {\n if (src && !/^\\^?\\(.*\\)\\$?$|^\\\\b$/.test(src))\n src = \"(?:\" + src + \")\";\n return src || \"\";\n }\n function guardedRegexp(re, guard, opening) {\n re = wrapRegexp(re);\n guard = wrapRegexp(guard);\n if (opening) {\n re = guard + re;\n if (re && re[re.length - 1] != \"$\")\n re = re + \"$\";\n }\n else {\n re = re + guard;\n if (re && re[0] != \"^\")\n re = \"^\" + re;\n }\n return new RegExp(re);\n }\n function addSnippet(s) {\n if (!s.scope)\n s.scope = scope || \"_\";\n scope = s.scope;\n if (!snippetMap[scope]) {\n snippetMap[scope] = [];\n snippetNameMap[scope] = {};\n }\n var map = snippetNameMap[scope];\n if (s.name) {\n var old = map[s.name];\n if (old)\n self.unregister(old);\n map[s.name] = s;\n }\n snippetMap[scope].push(s);\n if (s.prefix)\n s.tabTrigger = s.prefix;\n if (!s.content && s.body)\n s.content = Array.isArray(s.body) ? s.body.join(\"\\n\") : s.body;\n if (s.tabTrigger && !s.trigger) {\n if (!s.guard && /^\\w/.test(s.tabTrigger))\n s.guard = \"\\\\b\";\n s.trigger = lang.escapeRegExp(s.tabTrigger);\n }\n if (!s.trigger && !s.guard && !s.endTrigger && !s.endGuard)\n return;\n s.startRe = guardedRegexp(s.trigger, s.guard, true);\n s.triggerRe = new RegExp(s.trigger);\n s.endRe = guardedRegexp(s.endTrigger, s.endGuard, true);\n s.endTriggerRe = new RegExp(s.endTrigger);\n }\n if (Array.isArray(snippets)) {\n snippets.forEach(addSnippet);\n }\n else {\n Object.keys(snippets).forEach(function (key) {\n addSnippet(snippets[key]);\n });\n }\n this._signal(\"registerSnippets\", { scope: scope });\n };\n this.unregister = function (snippets, scope) {\n var snippetMap = this.snippetMap;\n var snippetNameMap = this.snippetNameMap;\n function removeSnippet(s) {\n var nameMap = snippetNameMap[s.scope || scope];\n if (nameMap && nameMap[s.name]) {\n delete nameMap[s.name];\n var map = snippetMap[s.scope || scope];\n var i = map && map.indexOf(s);\n if (i >= 0)\n map.splice(i, 1);\n }\n }\n if (snippets.content)\n removeSnippet(snippets);\n else if (Array.isArray(snippets))\n snippets.forEach(removeSnippet);\n };\n this.parseSnippetFile = function (str) {\n str = str.replace(/\\r/g, \"\");\n var list = [], snippet = {};\n var re = /^#.*|^({[\\s\\S]*})\\s*$|^(\\S+) (.*)$|^((?:\\n*\\t.*)+)/gm;\n var m;\n while (m = re.exec(str)) {\n if (m[1]) {\n try {\n snippet = JSON.parse(m[1]);\n list.push(snippet);\n }\n catch (e) { }\n }\n if (m[4]) {\n snippet.content = m[4].replace(/^\\t/gm, \"\");\n list.push(snippet);\n snippet = {};\n }\n else {\n var key = m[2], val = m[3];\n if (key == \"regex\") {\n var guardRe = /\\/((?:[^\\/\\\\]|\\\\.)*)|$/g;\n snippet.guard = guardRe.exec(val)[1];\n snippet.trigger = guardRe.exec(val)[1];\n snippet.endTrigger = guardRe.exec(val)[1];\n snippet.endGuard = guardRe.exec(val)[1];\n }\n else if (key == \"snippet\") {\n snippet.tabTrigger = val.match(/^\\S*/)[0];\n if (!snippet.name)\n snippet.name = val;\n }\n else if (key) {\n snippet[key] = val;\n }\n }\n }\n return list;\n };\n this.getSnippetByName = function (name, editor) {\n var snippetMap = this.snippetNameMap;\n var snippet;\n this.getActiveScopes(editor).some(function (scope) {\n var snippets = snippetMap[scope];\n if (snippets)\n snippet = snippets[name];\n return !!snippet;\n }, this);\n return snippet;\n };\n}).call(SnippetManager.prototype);\nvar TabstopManager = function (editor) {\n if (editor.tabstopManager)\n return editor.tabstopManager;\n editor.tabstopManager = this;\n this.$onChange = this.onChange.bind(this);\n this.$onChangeSelection = lang.delayedCall(this.onChangeSelection.bind(this)).schedule;\n this.$onChangeSession = this.onChangeSession.bind(this);\n this.$onAfterExec = this.onAfterExec.bind(this);\n this.attach(editor);\n};\n(function () {\n this.attach = function (editor) {\n this.index = 0;\n this.ranges = [];\n this.tabstops = [];\n this.$openTabstops = null;\n this.selectedTabstop = null;\n this.editor = editor;\n this.editor.on(\"change\", this.$onChange);\n this.editor.on(\"changeSelection\", this.$onChangeSelection);\n this.editor.on(\"changeSession\", this.$onChangeSession);\n this.editor.commands.on(\"afterExec\", this.$onAfterExec);\n this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);\n };\n this.detach = function () {\n this.tabstops.forEach(this.removeTabstopMarkers, this);\n this.ranges = null;\n this.tabstops = null;\n this.selectedTabstop = null;\n this.editor.removeListener(\"change\", this.$onChange);\n this.editor.removeListener(\"changeSelection\", this.$onChangeSelection);\n this.editor.removeListener(\"changeSession\", this.$onChangeSession);\n this.editor.commands.removeListener(\"afterExec\", this.$onAfterExec);\n this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler);\n this.editor.tabstopManager = null;\n this.editor = null;\n };\n this.onChange = function (delta) {\n var isRemove = delta.action[0] == \"r\";\n var selectedTabstop = this.selectedTabstop || {};\n var parents = selectedTabstop.parents || {};\n var tabstops = (this.tabstops || []).slice();\n for (var i = 0; i < tabstops.length; i++) {\n var ts = tabstops[i];\n var active = ts == selectedTabstop || parents[ts.index];\n ts.rangeList.$bias = active ? 0 : 1;\n if (delta.action == \"remove\" && ts !== selectedTabstop) {\n var parentActive = ts.parents && ts.parents[selectedTabstop.index];\n var startIndex = ts.rangeList.pointIndex(delta.start, parentActive);\n startIndex = startIndex < 0 ? -startIndex - 1 : startIndex + 1;\n var endIndex = ts.rangeList.pointIndex(delta.end, parentActive);\n endIndex = endIndex < 0 ? -endIndex - 1 : endIndex - 1;\n var toRemove = ts.rangeList.ranges.slice(startIndex, endIndex);\n for (var j = 0; j < toRemove.length; j++)\n this.removeRange(toRemove[j]);\n }\n ts.rangeList.$onChange(delta);\n }\n var session = this.editor.session;\n if (!this.$inChange && isRemove && session.getLength() == 1 && !session.getValue())\n this.detach();\n };\n this.updateLinkedFields = function () {\n var ts = this.selectedTabstop;\n if (!ts || !ts.hasLinkedRanges || !ts.firstNonLinked)\n return;\n this.$inChange = true;\n var session = this.editor.session;\n var text = session.getTextRange(ts.firstNonLinked);\n for (var i = 0; i < ts.length; i++) {\n var range = ts[i];\n if (!range.linked)\n continue;\n var original = range.original;\n var fmt = exports.snippetManager.tmStrFormat(text, original, this.editor);\n session.replace(range, fmt);\n }\n this.$inChange = false;\n };\n this.onAfterExec = function (e) {\n if (e.command && !e.command.readOnly)\n this.updateLinkedFields();\n };\n this.onChangeSelection = function () {\n if (!this.editor)\n return;\n var lead = this.editor.selection.lead;\n var anchor = this.editor.selection.anchor;\n var isEmpty = this.editor.selection.isEmpty();\n for (var i = 0; i < this.ranges.length; i++) {\n if (this.ranges[i].linked)\n continue;\n var containsLead = this.ranges[i].contains(lead.row, lead.column);\n var containsAnchor = isEmpty || this.ranges[i].contains(anchor.row, anchor.column);\n if (containsLead && containsAnchor)\n return;\n }\n this.detach();\n };\n this.onChangeSession = function () {\n this.detach();\n };\n this.tabNext = function (dir) {\n var max = this.tabstops.length;\n var index = this.index + (dir || 1);\n index = Math.min(Math.max(index, 1), max);\n if (index == max)\n index = 0;\n this.selectTabstop(index);\n if (index === 0)\n this.detach();\n };\n this.selectTabstop = function (index) {\n this.$openTabstops = null;\n var ts = this.tabstops[this.index];\n if (ts)\n this.addTabstopMarkers(ts);\n this.index = index;\n ts = this.tabstops[this.index];\n if (!ts || !ts.length)\n return;\n this.selectedTabstop = ts;\n var range = ts.firstNonLinked || ts;\n if (ts.choices)\n range.cursor = range.start;\n if (!this.editor.inVirtualSelectionMode) {\n var sel = this.editor.multiSelect;\n sel.toSingleRange(range);\n for (var i = 0; i < ts.length; i++) {\n if (ts.hasLinkedRanges && ts[i].linked)\n continue;\n sel.addRange(ts[i].clone(), true);\n }\n }\n else {\n this.editor.selection.fromOrientedRange(range);\n }\n this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);\n if (this.selectedTabstop && this.selectedTabstop.choices)\n this.editor.execCommand(\"startAutocomplete\", { matches: this.selectedTabstop.choices });\n };\n this.addTabstops = function (tabstops, start, end) {\n var useLink = this.useLink || !this.editor.getOption(\"enableMultiselect\");\n if (!this.$openTabstops)\n this.$openTabstops = [];\n if (!tabstops[0]) {\n var p = Range.fromPoints(end, end);\n moveRelative(p.start, start);\n moveRelative(p.end, start);\n tabstops[0] = [p];\n tabstops[0].index = 0;\n }\n var i = this.index;\n var arg = [i + 1, 0];\n var ranges = this.ranges;\n tabstops.forEach(function (ts, index) {\n var dest = this.$openTabstops[index] || ts;\n for (var i = 0; i < ts.length; i++) {\n var p = ts[i];\n var range = Range.fromPoints(p.start, p.end || p.start);\n movePoint(range.start, start);\n movePoint(range.end, start);\n range.original = p;\n range.tabstop = dest;\n ranges.push(range);\n if (dest != ts)\n dest.unshift(range);\n else\n dest[i] = range;\n if (p.fmtString || (dest.firstNonLinked && useLink)) {\n range.linked = true;\n dest.hasLinkedRanges = true;\n }\n else if (!dest.firstNonLinked)\n dest.firstNonLinked = range;\n }\n if (!dest.firstNonLinked)\n dest.hasLinkedRanges = false;\n if (dest === ts) {\n arg.push(dest);\n this.$openTabstops[index] = dest;\n }\n this.addTabstopMarkers(dest);\n dest.rangeList = dest.rangeList || new RangeList();\n dest.rangeList.$bias = 0;\n dest.rangeList.addList(dest);\n }, this);\n if (arg.length > 2) {\n if (this.tabstops.length)\n arg.push(arg.splice(2, 1)[0]);\n this.tabstops.splice.apply(this.tabstops, arg);\n }\n };\n this.addTabstopMarkers = function (ts) {\n var session = this.editor.session;\n ts.forEach(function (range) {\n if (!range.markerId)\n range.markerId = session.addMarker(range, \"ace_snippet-marker\", \"text\");\n });\n };\n this.removeTabstopMarkers = function (ts) {\n var session = this.editor.session;\n ts.forEach(function (range) {\n session.removeMarker(range.markerId);\n range.markerId = null;\n });\n };\n this.removeRange = function (range) {\n var i = range.tabstop.indexOf(range);\n if (i != -1)\n range.tabstop.splice(i, 1);\n i = this.ranges.indexOf(range);\n if (i != -1)\n this.ranges.splice(i, 1);\n i = range.tabstop.rangeList.ranges.indexOf(range);\n if (i != -1)\n range.tabstop.splice(i, 1);\n this.editor.session.removeMarker(range.markerId);\n if (!range.tabstop.length) {\n i = this.tabstops.indexOf(range.tabstop);\n if (i != -1)\n this.tabstops.splice(i, 1);\n if (!this.tabstops.length)\n this.detach();\n }\n };\n this.keyboardHandler = new HashHandler();\n this.keyboardHandler.bindKeys({\n \"Tab\": function (editor) {\n if (exports.snippetManager && exports.snippetManager.expandWithTab(editor))\n return;\n editor.tabstopManager.tabNext(1);\n editor.renderer.scrollCursorIntoView();\n },\n \"Shift-Tab\": function (editor) {\n editor.tabstopManager.tabNext(-1);\n editor.renderer.scrollCursorIntoView();\n },\n \"Esc\": function (editor) {\n editor.tabstopManager.detach();\n }\n });\n}).call(TabstopManager.prototype);\nvar movePoint = function (point, diff) {\n if (point.row == 0)\n point.column += diff.column;\n point.row += diff.row;\n};\nvar moveRelative = function (point, start) {\n if (point.row == start.row)\n point.column -= start.column;\n point.row -= start.row;\n};\ndom.importCssString(\"\\n.ace_snippet-marker {\\n -moz-box-sizing: border-box;\\n box-sizing: border-box;\\n background: rgba(194, 193, 208, 0.09);\\n border: 1px dotted rgba(211, 208, 235, 0.62);\\n position: absolute;\\n}\", \"snippets.css\", false);\nexports.snippetManager = new SnippetManager();\nvar Editor = require(\"./editor\").Editor;\n(function () {\n this.insertSnippet = function (content, options) {\n return exports.snippetManager.insertSnippet(this, content, options);\n };\n this.expandSnippet = function (options) {\n return exports.snippetManager.expandWithTab(this, options);\n };\n}).call(Editor.prototype);\n\n});\n\nace.define(\"ace/autocomplete/inline\",[\"require\",\"exports\",\"module\",\"ace/snippets\"], function(require, exports, module){\"use strict\";\nvar snippetManager = require(\"../snippets\").snippetManager;\nvar AceInline = /** @class */ (function () {\n function AceInline() {\n this.editor = null;\n }\n AceInline.prototype.show = function (editor, completion, prefix) {\n prefix = prefix || \"\";\n if (editor && this.editor && this.editor !== editor) {\n this.hide();\n this.editor = null;\n }\n if (!editor || !completion) {\n return false;\n }\n var displayText = completion.snippet ? snippetManager.getDisplayTextForSnippet(editor, completion.snippet) : completion.value;\n if (!displayText || !displayText.startsWith(prefix)) {\n return false;\n }\n this.editor = editor;\n displayText = displayText.slice(prefix.length);\n if (displayText === \"\") {\n editor.removeGhostText();\n }\n else {\n editor.setGhostText(displayText);\n }\n return true;\n };\n AceInline.prototype.isOpen = function () {\n if (!this.editor) {\n return false;\n }\n return !!this.editor.renderer.$ghostText;\n };\n AceInline.prototype.hide = function () {\n if (!this.editor) {\n return false;\n }\n this.editor.removeGhostText();\n return true;\n };\n AceInline.prototype.destroy = function () {\n this.hide();\n this.editor = null;\n };\n return AceInline;\n}());\nexports.AceInline = AceInline;\n\n});\n\nace.define(\"ace/autocomplete/popup\",[\"require\",\"exports\",\"module\",\"ace/virtual_renderer\",\"ace/editor\",\"ace/range\",\"ace/lib/event\",\"ace/lib/lang\",\"ace/lib/dom\"], function(require, exports, module){\"use strict\";\nvar Renderer = require(\"../virtual_renderer\").VirtualRenderer;\nvar Editor = require(\"../editor\").Editor;\nvar Range = require(\"../range\").Range;\nvar event = require(\"../lib/event\");\nvar lang = require(\"../lib/lang\");\nvar dom = require(\"../lib/dom\");\nvar getAriaId = function (index) {\n return \"suggest-aria-id:\".concat(index);\n};\nvar $singleLineEditor = function (el) {\n var renderer = new Renderer(el);\n renderer.$maxLines = 4;\n var editor = new Editor(renderer);\n editor.setHighlightActiveLine(false);\n editor.setShowPrintMargin(false);\n editor.renderer.setShowGutter(false);\n editor.renderer.setHighlightGutterLine(false);\n editor.$mouseHandler.$focusTimeout = 0;\n editor.$highlightTagPending = true;\n return editor;\n};\nvar AcePopup = /** @class */ (function () {\n function AcePopup(parentNode) {\n var el = dom.createElement(\"div\");\n var popup = new $singleLineEditor(el);\n if (parentNode)\n parentNode.appendChild(el);\n el.style.display = \"none\";\n popup.renderer.content.style.cursor = \"default\";\n popup.renderer.setStyle(\"ace_autocomplete\");\n popup.renderer.container.setAttribute(\"role\", \"listbox\");\n popup.renderer.container.setAttribute(\"aria-label\", \"Autocomplete suggestions\");\n popup.setOption(\"displayIndentGuides\", false);\n popup.setOption(\"dragDelay\", 150);\n var noop = function () { };\n popup.focus = noop;\n popup.$isFocused = true;\n popup.renderer.$cursorLayer.restartTimer = noop;\n popup.renderer.$cursorLayer.element.style.opacity = 0;\n popup.renderer.$maxLines = 8;\n popup.renderer.$keepTextAreaAtCursor = false;\n popup.setHighlightActiveLine(false);\n popup.session.highlight(\"\");\n popup.session.$searchHighlight.clazz = \"ace_highlight-marker\";\n popup.on(\"mousedown\", function (e) {\n var pos = e.getDocumentPosition();\n popup.selection.moveToPosition(pos);\n selectionMarker.start.row = selectionMarker.end.row = pos.row;\n e.stop();\n });\n var lastMouseEvent;\n var hoverMarker = new Range(-1, 0, -1, Infinity);\n var selectionMarker = new Range(-1, 0, -1, Infinity);\n selectionMarker.id = popup.session.addMarker(selectionMarker, \"ace_active-line\", \"fullLine\");\n popup.setSelectOnHover = function (val) {\n if (!val) {\n hoverMarker.id = popup.session.addMarker(hoverMarker, \"ace_line-hover\", \"fullLine\");\n }\n else if (hoverMarker.id) {\n popup.session.removeMarker(hoverMarker.id);\n hoverMarker.id = null;\n }\n };\n popup.setSelectOnHover(false);\n popup.on(\"mousemove\", function (e) {\n if (!lastMouseEvent) {\n lastMouseEvent = e;\n return;\n }\n if (lastMouseEvent.x == e.x && lastMouseEvent.y == e.y) {\n return;\n }\n lastMouseEvent = e;\n lastMouseEvent.scrollTop = popup.renderer.scrollTop;\n var row = lastMouseEvent.getDocumentPosition().row;\n if (hoverMarker.start.row != row) {\n if (!hoverMarker.id)\n popup.setRow(row);\n setHoverMarker(row);\n }\n });\n popup.renderer.on(\"beforeRender\", function () {\n if (lastMouseEvent && hoverMarker.start.row != -1) {\n lastMouseEvent.$pos = null;\n var row = lastMouseEvent.getDocumentPosition().row;\n if (!hoverMarker.id)\n popup.setRow(row);\n setHoverMarker(row, true);\n }\n });\n popup.renderer.on(\"afterRender\", function () {\n var row = popup.getRow();\n var t = popup.renderer.$textLayer;\n var selected = t.element.childNodes[row - t.config.firstRow];\n var el = document.activeElement; // Active element is textarea of main editor\n if (selected !== t.selectedNode && t.selectedNode) {\n dom.removeCssClass(t.selectedNode, \"ace_selected\");\n el.removeAttribute(\"aria-activedescendant\");\n t.selectedNode.removeAttribute(\"id\");\n }\n t.selectedNode = selected;\n if (selected) {\n dom.addCssClass(selected, \"ace_selected\");\n var ariaId = getAriaId(row);\n selected.id = ariaId;\n popup.renderer.container.setAttribute(\"aria-activedescendant\", ariaId);\n el.setAttribute(\"aria-activedescendant\", ariaId);\n selected.setAttribute(\"role\", \"option\");\n selected.setAttribute(\"aria-label\", popup.getData(row).value);\n selected.setAttribute(\"aria-setsize\", popup.data.length);\n selected.setAttribute(\"aria-posinset\", row);\n }\n });\n var hideHoverMarker = function () { setHoverMarker(-1); };\n var setHoverMarker = function (row, suppressRedraw) {\n if (row !== hoverMarker.start.row) {\n hoverMarker.start.row = hoverMarker.end.row = row;\n if (!suppressRedraw)\n popup.session._emit(\"changeBackMarker\");\n popup._emit(\"changeHoverMarker\");\n }\n };\n popup.getHoveredRow = function () {\n return hoverMarker.start.row;\n };\n event.addListener(popup.container, \"mouseout\", hideHoverMarker);\n popup.on(\"hide\", hideHoverMarker);\n popup.on(\"changeSelection\", hideHoverMarker);\n popup.session.doc.getLength = function () {\n return popup.data.length;\n };\n popup.session.doc.getLine = function (i) {\n var data = popup.data[i];\n if (typeof data == \"string\")\n return data;\n return (data && data.value) || \"\";\n };\n var bgTokenizer = popup.session.bgTokenizer;\n bgTokenizer.$tokenizeRow = function (row) {\n var data = popup.data[row];\n var tokens = [];\n if (!data)\n return tokens;\n if (typeof data == \"string\")\n data = { value: data };\n var caption = data.caption || data.value || data.name;\n function addToken(value, className) {\n value && tokens.push({\n type: (data.className || \"\") + (className || \"\"),\n value: value\n });\n }\n var lower = caption.toLowerCase();\n var filterText = (popup.filterText || \"\").toLowerCase();\n var lastIndex = 0;\n var lastI = 0;\n for (var i = 0; i <= filterText.length; i++) {\n if (i != lastI && (data.matchMask & (1 << i) || i == filterText.length)) {\n var sub = filterText.slice(lastI, i);\n lastI = i;\n var index = lower.indexOf(sub, lastIndex);\n if (index == -1)\n continue;\n addToken(caption.slice(lastIndex, index), \"\");\n lastIndex = index + sub.length;\n addToken(caption.slice(index, lastIndex), \"completion-highlight\");\n }\n }\n addToken(caption.slice(lastIndex, caption.length), \"\");\n if (data.meta)\n tokens.push({ type: \"completion-meta\", value: data.meta });\n if (data.message)\n tokens.push({ type: \"completion-message\", value: data.message });\n return tokens;\n };\n bgTokenizer.$updateOnChange = noop;\n bgTokenizer.start = noop;\n popup.session.$computeWidth = function () {\n return this.screenWidth = 0;\n };\n popup.isOpen = false;\n popup.isTopdown = false;\n popup.autoSelect = true;\n popup.filterText = \"\";\n popup.data = [];\n popup.setData = function (list, filterText) {\n popup.filterText = filterText || \"\";\n popup.setValue(lang.stringRepeat(\"\\n\", list.length), -1);\n popup.data = list || [];\n popup.setRow(0);\n };\n popup.getData = function (row) {\n return popup.data[row];\n };\n popup.getRow = function () {\n return selectionMarker.start.row;\n };\n popup.setRow = function (line) {\n line = Math.max(this.autoSelect ? 0 : -1, Math.min(this.data.length, line));\n if (selectionMarker.start.row != line) {\n popup.selection.clearSelection();\n selectionMarker.start.row = selectionMarker.end.row = line || 0;\n popup.session._emit(\"changeBackMarker\");\n popup.moveCursorTo(line || 0, 0);\n if (popup.isOpen)\n popup._signal(\"select\");\n }\n };\n popup.on(\"changeSelection\", function () {\n if (popup.isOpen)\n popup.setRow(popup.selection.lead.row);\n popup.renderer.scrollCursorIntoView();\n });\n popup.hide = function () {\n this.container.style.display = \"none\";\n popup.anchorPos = null;\n popup.anchor = null;\n if (popup.isOpen) {\n popup.isOpen = false;\n this._signal(\"hide\");\n }\n };\n popup.tryShow = function (pos, lineHeight, anchor, forceShow) {\n if (!forceShow && popup.isOpen && popup.anchorPos && popup.anchor &&\n popup.anchorPos.top === pos.top && popup.anchorPos.left === pos.left &&\n popup.anchor === anchor) {\n return true;\n }\n var el = this.container;\n var screenHeight = window.innerHeight;\n var screenWidth = window.innerWidth;\n var renderer = this.renderer;\n var maxH = renderer.$maxLines * lineHeight * 1.4;\n var dims = { top: 0, bottom: 0, left: 0 };\n var spaceBelow = screenHeight - pos.top - 3 * this.$borderSize - lineHeight;\n var spaceAbove = pos.top - 3 * this.$borderSize;\n if (!anchor) {\n if (spaceAbove <= spaceBelow || spaceBelow >= maxH) {\n anchor = \"bottom\";\n }\n else {\n anchor = \"top\";\n }\n }\n if (anchor === \"top\") {\n dims.bottom = pos.top - this.$borderSize;\n dims.top = dims.bottom - maxH;\n }\n else if (anchor === \"bottom\") {\n dims.top = pos.top + lineHeight + this.$borderSize;\n dims.bottom = dims.top + maxH;\n }\n var fitsX = dims.top >= 0 && dims.bottom <= screenHeight;\n if (!forceShow && !fitsX) {\n return false;\n }\n if (!fitsX) {\n if (anchor === \"top\") {\n renderer.$maxPixelHeight = spaceAbove;\n }\n else {\n renderer.$maxPixelHeight = spaceBelow;\n }\n }\n else {\n renderer.$maxPixelHeight = null;\n }\n if (anchor === \"top\") {\n el.style.top = \"\";\n el.style.bottom = (screenHeight - dims.bottom) + \"px\";\n popup.isTopdown = false;\n }\n else {\n el.style.top = dims.top + \"px\";\n el.style.bottom = \"\";\n popup.isTopdown = true;\n }\n el.style.display = \"\";\n var left = pos.left;\n if (left + el.offsetWidth > screenWidth)\n left = screenWidth - el.offsetWidth;\n el.style.left = left + \"px\";\n el.style.right = \"\";\n if (!popup.isOpen) {\n popup.isOpen = true;\n this._signal(\"show\");\n lastMouseEvent = null;\n }\n popup.anchorPos = pos;\n popup.anchor = anchor;\n return true;\n };\n popup.show = function (pos, lineHeight, topdownOnly) {\n this.tryShow(pos, lineHeight, topdownOnly ? \"bottom\" : undefined, true);\n };\n popup.goTo = function (where) {\n var row = this.getRow();\n var max = this.session.getLength() - 1;\n switch (where) {\n case \"up\":\n row = row <= 0 ? max : row - 1;\n break;\n case \"down\":\n row = row >= max ? -1 : row + 1;\n break;\n case \"start\":\n row = 0;\n break;\n case \"end\":\n row = max;\n break;\n }\n this.setRow(row);\n };\n popup.getTextLeftOffset = function () {\n return this.$borderSize + this.renderer.$padding + this.$imageSize;\n };\n popup.$imageSize = 0;\n popup.$borderSize = 1;\n return popup;\n }\n return AcePopup;\n}());\ndom.importCssString(\"\\n.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\\n background-color: #CAD6FA;\\n z-index: 1;\\n}\\n.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\\n background-color: #3a674e;\\n}\\n.ace_editor.ace_autocomplete .ace_line-hover {\\n border: 1px solid #abbffe;\\n margin-top: -1px;\\n background: rgba(233,233,253,0.4);\\n position: absolute;\\n z-index: 2;\\n}\\n.ace_dark.ace_editor.ace_autocomplete .ace_line-hover {\\n border: 1px solid rgba(109, 150, 13, 0.8);\\n background: rgba(58, 103, 78, 0.62);\\n}\\n.ace_completion-meta {\\n opacity: 0.5;\\n margin: 0 0.9em;\\n}\\n.ace_completion-message {\\n color: blue;\\n}\\n.ace_editor.ace_autocomplete .ace_completion-highlight{\\n color: #2d69c7;\\n}\\n.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{\\n color: #93ca12;\\n}\\n.ace_editor.ace_autocomplete {\\n width: 300px;\\n z-index: 200000;\\n border: 1px lightgray solid;\\n position: fixed;\\n box-shadow: 2px 3px 5px rgba(0,0,0,.2);\\n line-height: 1.4;\\n background: #fefefe;\\n color: #111;\\n}\\n.ace_dark.ace_editor.ace_autocomplete {\\n border: 1px #484747 solid;\\n box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);\\n line-height: 1.4;\\n background: #25282c;\\n color: #c1c1c1;\\n}\\n.ace_autocomplete_right .ace_text-layer {\\n width: calc(100% - 8px);\\n}\\n.ace_autocomplete_right .ace_line {\\n display: flex;\\n}\\n.ace_autocomplete_right .ace_completion-meta {\\n flex: 1;\\n text-align: right;\\n}\\n\", \"autocompletion.css\", false);\nexports.AcePopup = AcePopup;\nexports.$singleLineEditor = $singleLineEditor;\nexports.getAriaId = getAriaId;\n\n});\n\nace.define(\"ace/autocomplete/util\",[\"require\",\"exports\",\"module\"], function(require, exports, module){\"use strict\";\nexports.parForEach = function (array, fn, callback) {\n var completed = 0;\n var arLength = array.length;\n if (arLength === 0)\n callback();\n for (var i = 0; i < arLength; i++) {\n fn(array[i], function (result, err) {\n completed++;\n if (completed === arLength)\n callback(result, err);\n });\n }\n};\nvar ID_REGEX = /[a-zA-Z_0-9\\$\\-\\u00A2-\\u2000\\u2070-\\uFFFF]/;\nexports.retrievePrecedingIdentifier = function (text, pos, regex) {\n regex = regex || ID_REGEX;\n var buf = [];\n for (var i = pos - 1; i >= 0; i--) {\n if (regex.test(text[i]))\n buf.push(text[i]);\n else\n break;\n }\n return buf.reverse().join(\"\");\n};\nexports.retrieveFollowingIdentifier = function (text, pos, regex) {\n regex = regex || ID_REGEX;\n var buf = [];\n for (var i = pos; i < text.length; i++) {\n if (regex.test(text[i]))\n buf.push(text[i]);\n else\n break;\n }\n return buf;\n};\nexports.getCompletionPrefix = function (editor) {\n var pos = editor.getCursorPosition();\n var line = editor.session.getLine(pos.row);\n var prefix;\n editor.completers.forEach(function (completer) {\n if (completer.identifierRegexps) {\n completer.identifierRegexps.forEach(function (identifierRegex) {\n if (!prefix && identifierRegex)\n prefix = this.retrievePrecedingIdentifier(line, pos.column, identifierRegex);\n }.bind(this));\n }\n }.bind(this));\n return prefix || this.retrievePrecedingIdentifier(line, pos.column);\n};\n\n});\n\nace.define(\"ace/autocomplete\",[\"require\",\"exports\",\"module\",\"ace/keyboard/hash_handler\",\"ace/autocomplete/popup\",\"ace/autocomplete/inline\",\"ace/autocomplete/popup\",\"ace/autocomplete/util\",\"ace/lib/lang\",\"ace/lib/dom\",\"ace/snippets\",\"ace/config\"], function(require, exports, module){\"use strict\";\nvar HashHandler = require(\"./keyboard/hash_handler\").HashHandler;\nvar AcePopup = require(\"./autocomplete/popup\").AcePopup;\nvar AceInline = require(\"./autocomplete/inline\").AceInline;\nvar getAriaId = require(\"./autocomplete/popup\").getAriaId;\nvar util = require(\"./autocomplete/util\");\nvar lang = require(\"./lib/lang\");\nvar dom = require(\"./lib/dom\");\nvar snippetManager = require(\"./snippets\").snippetManager;\nvar config = require(\"./config\");\nvar destroyCompleter = function (e, editor) {\n editor.completer && editor.completer.destroy();\n};\nvar Autocomplete = /** @class */ (function () {\n function Autocomplete() {\n this.autoInsert = false;\n this.autoSelect = true;\n this.exactMatch = false;\n this.inlineEnabled = false;\n this.keyboardHandler = new HashHandler();\n this.keyboardHandler.bindKeys(this.commands);\n this.blurListener = this.blurListener.bind(this);\n this.changeListener = this.changeListener.bind(this);\n this.mousedownListener = this.mousedownListener.bind(this);\n this.mousewheelListener = this.mousewheelListener.bind(this);\n this.changeTimer = lang.delayedCall(function () {\n this.updateCompletions(true);\n }.bind(this));\n this.tooltipTimer = lang.delayedCall(this.updateDocTooltip.bind(this), 50);\n }\n Autocomplete.prototype.$init = function () {\n this.popup = new AcePopup(document.body || document.documentElement);\n this.popup.on(\"click\", function (e) {\n this.insertMatch();\n e.stop();\n }.bind(this));\n this.popup.focus = this.editor.focus.bind(this.editor);\n this.popup.on(\"show\", this.$onPopupChange.bind(this));\n this.popup.on(\"hide\", this.$onHidePopup.bind(this));\n this.popup.on(\"select\", this.$onPopupChange.bind(this));\n this.popup.on(\"changeHoverMarker\", this.tooltipTimer.bind(null, null));\n return this.popup;\n };\n Autocomplete.prototype.$initInline = function () {\n if (!this.inlineEnabled || this.inlineRenderer)\n return;\n this.inlineRenderer = new AceInline();\n return this.inlineRenderer;\n };\n Autocomplete.prototype.getPopup = function () {\n return this.popup || this.$init();\n };\n Autocomplete.prototype.$onHidePopup = function () {\n if (this.inlineRenderer) {\n this.inlineRenderer.hide();\n }\n this.hideDocTooltip();\n };\n Autocomplete.prototype.$onPopupChange = function (hide) {\n if (this.inlineRenderer && this.inlineEnabled) {\n var completion = hide ? null : this.popup.getData(this.popup.getRow());\n var prefix = util.getCompletionPrefix(this.editor);\n if (!this.inlineRenderer.show(this.editor, completion, prefix)) {\n this.inlineRenderer.hide();\n }\n this.$updatePopupPosition();\n }\n this.tooltipTimer.call(null, null);\n };\n Autocomplete.prototype.$updatePopupPosition = function () {\n var editor = this.editor;\n var renderer = editor.renderer;\n var lineHeight = renderer.layerConfig.lineHeight;\n var pos = renderer.$cursorLayer.getPixelPosition(this.base, true);\n pos.left -= this.popup.getTextLeftOffset();\n var rect = editor.container.getBoundingClientRect();\n pos.top += rect.top - renderer.layerConfig.offset;\n pos.left += rect.left - editor.renderer.scrollLeft;\n pos.left += renderer.gutterWidth;\n var posGhostText = {\n top: pos.top,\n left: pos.left\n };\n if (renderer.$ghostText && renderer.$ghostTextWidget) {\n if (this.base.row === renderer.$ghostText.position.row) {\n posGhostText.top += renderer.$ghostTextWidget.el.offsetHeight;\n }\n }\n if (this.popup.tryShow(posGhostText, lineHeight, \"bottom\")) {\n return;\n }\n if (this.popup.tryShow(pos, lineHeight, \"top\")) {\n return;\n }\n this.popup.show(pos, lineHeight);\n };\n Autocomplete.prototype.openPopup = function (editor, prefix, keepPopupPosition) {\n if (!this.popup)\n this.$init();\n if (this.inlineEnabled && !this.inlineRenderer)\n this.$initInline();\n this.popup.autoSelect = this.autoSelect;\n this.popup.setData(this.completions.filtered, this.completions.filterText);\n if (this.editor.textInput.setAriaOptions) {\n this.editor.textInput.setAriaOptions({\n activeDescendant: getAriaId(this.popup.getRow()),\n inline: this.inlineEnabled\n });\n }\n editor.keyBinding.addKeyboardHandler(this.keyboardHandler);\n this.popup.setRow(this.autoSelect ? 0 : -1);\n if (!keepPopupPosition) {\n this.popup.setTheme(editor.getTheme());\n this.popup.setFontSize(editor.getFontSize());\n this.$updatePopupPosition();\n if (this.tooltipNode) {\n this.updateDocTooltip();\n }\n }\n else if (keepPopupPosition && !prefix) {\n this.detach();\n }\n this.changeTimer.cancel();\n };\n Autocomplete.prototype.detach = function () {\n if (this.editor) {\n this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler);\n this.editor.off(\"changeSelection\", this.changeListener);\n this.editor.off(\"blur\", this.blurListener);\n this.editor.off(\"mousedown\", this.mousedownListener);\n this.editor.off(\"mousewheel\", this.mousewheelListener);\n }\n this.changeTimer.cancel();\n this.hideDocTooltip();\n if (this.completionProvider) {\n this.completionProvider.detach();\n }\n if (this.popup && this.popup.isOpen)\n this.popup.hide();\n if (this.base)\n this.base.detach();\n this.activated = false;\n this.completionProvider = this.completions = this.base = null;\n };\n Autocomplete.prototype.changeListener = function (e) {\n var cursor = this.editor.selection.lead;\n if (cursor.row != this.base.row || cursor.column < this.base.column) {\n this.detach();\n }\n if (this.activated)\n this.changeTimer.schedule();\n else\n this.detach();\n };\n Autocomplete.prototype.blurListener = function (e) {\n var el = document.activeElement;\n var text = this.editor.textInput.getElement();\n var fromTooltip = e.relatedTarget && this.tooltipNode && this.tooltipNode.contains(e.relatedTarget);\n var container = this.popup && this.popup.container;\n if (el != text && el.parentNode != container && !fromTooltip\n && el != this.tooltipNode && e.relatedTarget != text) {\n this.detach();\n }\n };\n Autocomplete.prototype.mousedownListener = function (e) {\n this.detach();\n };\n Autocomplete.prototype.mousewheelListener = function (e) {\n this.detach();\n };\n Autocomplete.prototype.goTo = function (where) {\n this.popup.goTo(where);\n };\n Autocomplete.prototype.insertMatch = function (data, options) {\n if (!data)\n data = this.popup.getData(this.popup.getRow());\n if (!data)\n return false;\n var completions = this.completions;\n var result = this.getCompletionProvider().insertMatch(this.editor, data, completions.filterText, options);\n if (this.completions == completions)\n this.detach();\n return result;\n };\n Autocomplete.prototype.showPopup = function (editor, options) {\n if (this.editor)\n this.detach();\n this.activated = true;\n this.editor = editor;\n if (editor.completer != this) {\n if (editor.completer)\n editor.completer.detach();\n editor.completer = this;\n }\n editor.on(\"changeSelection\", this.changeListener);\n editor.on(\"blur\", this.blurListener);\n editor.on(\"mousedown\", this.mousedownListener);\n editor.on(\"mousewheel\", this.mousewheelListener);\n this.updateCompletions(false, options);\n };\n Autocomplete.prototype.getCompletionProvider = function () {\n if (!this.completionProvider)\n this.completionProvider = new CompletionProvider();\n return this.completionProvider;\n };\n Autocomplete.prototype.gatherCompletions = function (editor, callback) {\n return this.getCompletionProvider().gatherCompletions(editor, callback);\n };\n Autocomplete.prototype.updateCompletions = function (keepPopupPosition, options) {\n if (keepPopupPosition && this.base && this.completions) {\n var pos = this.editor.getCursorPosition();\n var prefix = this.editor.session.getTextRange({ start: this.base, end: pos });\n if (prefix == this.completions.filterText)\n return;\n this.completions.setFilter(prefix);\n if (!this.completions.filtered.length)\n return this.detach();\n if (this.completions.filtered.length == 1\n && this.completions.filtered[0].value == prefix\n && !this.completions.filtered[0].snippet)\n return this.detach();\n this.openPopup(this.editor, prefix, keepPopupPosition);\n return;\n }\n if (options && options.matches) {\n var pos = this.editor.getSelectionRange().start;\n this.base = this.editor.session.doc.createAnchor(pos.row, pos.column);\n this.base.$insertRight = true;\n this.completions = new FilteredList(options.matches);\n return this.openPopup(this.editor, \"\", keepPopupPosition);\n }\n var session = this.editor.getSession();\n var pos = this.editor.getCursorPosition();\n var prefix = util.getCompletionPrefix(this.editor);\n this.base = session.doc.createAnchor(pos.row, pos.column - prefix.length);\n this.base.$insertRight = true;\n var completionOptions = { exactMatch: this.exactMatch };\n this.getCompletionProvider().provideCompletions(this.editor, completionOptions, function (err, completions, finished) {\n var filtered = completions.filtered;\n var prefix = util.getCompletionPrefix(this.editor);\n if (finished) {\n if (!filtered.length)\n return this.detach();\n if (filtered.length == 1 && filtered[0].value == prefix && !filtered[0].snippet)\n return this.detach();\n if (this.autoInsert && filtered.length == 1)\n return this.insertMatch(filtered[0]);\n }\n this.completions = completions;\n this.openPopup(this.editor, prefix, keepPopupPosition);\n }.bind(this));\n };\n Autocomplete.prototype.cancelContextMenu = function () {\n this.editor.$mouseHandler.cancelContextMenu();\n };\n Autocomplete.prototype.updateDocTooltip = function () {\n var popup = this.popup;\n var all = popup.data;\n var selected = all && (all[popup.getHoveredRow()] || all[popup.getRow()]);\n var doc = null;\n if (!selected || !this.editor || !this.popup.isOpen)\n return this.hideDocTooltip();\n var completersLength = this.editor.completers.length;\n for (var i = 0; i < completersLength; i++) {\n var completer = this.editor.completers[i];\n if (completer.getDocTooltip && selected.completerId === completer.id) {\n doc = completer.getDocTooltip(selected);\n break;\n }\n }\n if (!doc && typeof selected != \"string\")\n doc = selected;\n if (typeof doc == \"string\")\n doc = { docText: doc };\n if (!doc || !(doc.docHTML || doc.docText))\n return this.hideDocTooltip();\n this.showDocTooltip(doc);\n };\n Autocomplete.prototype.showDocTooltip = function (item) {\n if (!this.tooltipNode) {\n this.tooltipNode = dom.createElement(\"div\");\n this.tooltipNode.className = \"ace_tooltip ace_doc-tooltip\";\n this.tooltipNode.style.margin = 0;\n this.tooltipNode.style.pointerEvents = \"auto\";\n this.tooltipNode.tabIndex = -1;\n this.tooltipNode.onblur = this.blurListener.bind(this);\n this.tooltipNode.onclick = this.onTooltipClick.bind(this);\n }\n var tooltipNode = this.tooltipNode;\n if (item.docHTML) {\n tooltipNode.innerHTML = item.docHTML;\n }\n else if (item.docText) {\n tooltipNode.textContent = item.docText;\n }\n if (!tooltipNode.parentNode)\n document.body.appendChild(tooltipNode);\n var popup = this.popup;\n var rect = popup.container.getBoundingClientRect();\n tooltipNode.style.top = popup.container.style.top;\n tooltipNode.style.bottom = popup.container.style.bottom;\n tooltipNode.style.display = \"block\";\n if (window.innerWidth - rect.right < 320) {\n if (rect.left < 320) {\n if (popup.isTopdown) {\n tooltipNode.style.top = rect.bottom + \"px\";\n tooltipNode.style.left = rect.left + \"px\";\n tooltipNode.style.right = \"\";\n tooltipNode.style.bottom = \"\";\n }\n else {\n tooltipNode.style.top = popup.container.offsetTop - tooltipNode.offsetHeight + \"px\";\n tooltipNode.style.left = rect.left + \"px\";\n tooltipNode.style.right = \"\";\n tooltipNode.style.bottom = \"\";\n }\n }\n else {\n tooltipNode.style.right = window.innerWidth - rect.left + \"px\";\n tooltipNode.style.left = \"\";\n }\n }\n else {\n tooltipNode.style.left = (rect.right + 1) + \"px\";\n tooltipNode.style.right = \"\";\n }\n };\n Autocomplete.prototype.hideDocTooltip = function () {\n this.tooltipTimer.cancel();\n if (!this.tooltipNode)\n return;\n var el = this.tooltipNode;\n if (!this.editor.isFocused() && document.activeElement == el)\n this.editor.focus();\n this.tooltipNode = null;\n if (el.parentNode)\n el.parentNode.removeChild(el);\n };\n Autocomplete.prototype.onTooltipClick = function (e) {\n var a = e.target;\n while (a && a != this.tooltipNode) {\n if (a.nodeName == \"A\" && a.href) {\n a.rel = \"noreferrer\";\n a.target = \"_blank\";\n break;\n }\n a = a.parentNode;\n }\n };\n Autocomplete.prototype.destroy = function () {\n this.detach();\n if (this.popup) {\n this.popup.destroy();\n var el = this.popup.container;\n if (el && el.parentNode)\n el.parentNode.removeChild(el);\n }\n if (this.editor && this.editor.completer == this) {\n this.editor.off(\"destroy\", destroyCompleter);\n this.editor.completer = null;\n }\n this.inlineRenderer = this.popup = this.editor = null;\n };\n return Autocomplete;\n}());\nAutocomplete.prototype.commands = {\n \"Up\": function (editor) { editor.completer.goTo(\"up\"); },\n \"Down\": function (editor) { editor.completer.goTo(\"down\"); },\n \"Ctrl-Up|Ctrl-Home\": function (editor) { editor.completer.goTo(\"start\"); },\n \"Ctrl-Down|Ctrl-End\": function (editor) { editor.completer.goTo(\"end\"); },\n \"Esc\": function (editor) { editor.completer.detach(); },\n \"Return\": function (editor) { return editor.completer.insertMatch(); },\n \"Shift-Return\": function (editor) { editor.completer.insertMatch(null, { deleteSuffix: true }); },\n \"Tab\": function (editor) {\n var result = editor.completer.insertMatch();\n if (!result && !editor.tabstopManager)\n editor.completer.goTo(\"down\");\n else\n return result;\n },\n \"PageUp\": function (editor) { editor.completer.popup.gotoPageUp(); },\n \"PageDown\": function (editor) { editor.completer.popup.gotoPageDown(); }\n};\nAutocomplete.for = function (editor) {\n if (editor.completer instanceof Autocomplete) {\n return editor.completer;\n }\n if (editor.completer) {\n editor.completer.destroy();\n editor.completer = null;\n }\n if (config.get(\"sharedPopups\")) {\n if (!Autocomplete.$sharedInstance)\n Autocomplete.$sharedInstance = new Autocomplete();\n editor.completer = Autocomplete.$sharedInstance;\n }\n else {\n editor.completer = new Autocomplete();\n editor.once(\"destroy\", destroyCompleter);\n }\n return editor.completer;\n};\nAutocomplete.startCommand = {\n name: \"startAutocomplete\",\n exec: function (editor, options) {\n var completer = Autocomplete.for(editor);\n completer.autoInsert = false;\n completer.autoSelect = true;\n completer.showPopup(editor, options);\n completer.cancelContextMenu();\n },\n bindKey: \"Ctrl-Space|Ctrl-Shift-Space|Alt-Space\"\n};\nvar CompletionProvider = /** @class */ (function () {\n function CompletionProvider() {\n this.active = true;\n }\n CompletionProvider.prototype.insertByIndex = function (editor, index, options) {\n if (!this.completions || !this.completions.filtered) {\n return false;\n }\n return this.insertMatch(editor, this.completions.filtered[index], options);\n };\n CompletionProvider.prototype.insertMatch = function (editor, data, options) {\n if (!data)\n return false;\n editor.startOperation({ command: { name: \"insertMatch\" } });\n if (data.completer && data.completer.insertMatch) {\n data.completer.insertMatch(editor, data);\n }\n else {\n if (!this.completions)\n return false;\n if (this.completions.filterText) {\n var ranges = editor.selection.getAllRanges();\n for (var i = 0, range; range = ranges[i]; i++) {\n range.start.column -= this.completions.filterText.length;\n editor.session.remove(range);\n }\n }\n if (data.snippet)\n snippetManager.insertSnippet(editor, data.snippet, data.range);\n else {\n this.$insertString(editor, data);\n }\n if (data.command && data.command === \"startAutocomplete\") {\n editor.execCommand(data.command);\n }\n }\n editor.endOperation();\n return true;\n };\n CompletionProvider.prototype.$insertString = function (editor, data) {\n var text = data.value || data;\n if (data.range) {\n if (editor.inVirtualSelectionMode) {\n return editor.session.replace(data.range, text);\n }\n editor.forEachSelection(function () {\n var range = editor.getSelectionRange();\n if (data.range.compareRange(range) === 0) {\n editor.session.replace(data.range, text);\n }\n else {\n editor.insert(text);\n }\n }, null, { keepOrder: true });\n }\n else {\n editor.execCommand(\"insertstring\", text);\n }\n };\n CompletionProvider.prototype.gatherCompletions = function (editor, callback) {\n var session = editor.getSession();\n var pos = editor.getCursorPosition();\n var prefix = util.getCompletionPrefix(editor);\n var matches = [];\n var total = editor.completers.length;\n editor.completers.forEach(function (completer, i) {\n completer.getCompletions(editor, session, pos, prefix, function (err, results) {\n if (!err && results)\n matches = matches.concat(results);\n callback(null, {\n prefix: util.getCompletionPrefix(editor),\n matches: matches,\n finished: (--total === 0)\n });\n });\n });\n return true;\n };\n CompletionProvider.prototype.provideCompletions = function (editor, options, callback) {\n var processResults = function (results) {\n var prefix = results.prefix;\n var matches = results.matches;\n this.completions = new FilteredList(matches);\n if (options.exactMatch)\n this.completions.exactMatch = true;\n if (options.ignoreCaption)\n this.completions.ignoreCaption = true;\n this.completions.setFilter(prefix);\n if (results.finished || this.completions.filtered.length)\n callback(null, this.completions, results.finished);\n }.bind(this);\n var isImmediate = true;\n var immediateResults = null;\n this.gatherCompletions(editor, function (err, results) {\n if (!this.active) {\n return;\n }\n if (err) {\n callback(err, [], true);\n this.detach();\n }\n var prefix = results.prefix;\n if (prefix.indexOf(results.prefix) !== 0)\n return;\n if (isImmediate) {\n immediateResults = results;\n return;\n }\n processResults(results);\n }.bind(this));\n isImmediate = false;\n if (immediateResults) {\n var results = immediateResults;\n immediateResults = null;\n processResults(results);\n }\n };\n CompletionProvider.prototype.detach = function () {\n this.active = false;\n };\n return CompletionProvider;\n}());\nvar FilteredList = /** @class */ (function () {\n function FilteredList(array, filterText) {\n this.all = array;\n this.filtered = array;\n this.filterText = filterText || \"\";\n this.exactMatch = false;\n this.ignoreCaption = false;\n }\n FilteredList.prototype.setFilter = function (str) {\n if (str.length > this.filterText && str.lastIndexOf(this.filterText, 0) === 0)\n var matches = this.filtered;\n else\n var matches = this.all;\n this.filterText = str;\n matches = this.filterCompletions(matches, this.filterText);\n matches = matches.sort(function (a, b) {\n return b.exactMatch - a.exactMatch || b.$score - a.$score\n || (a.caption || a.value).localeCompare(b.caption || b.value);\n });\n var prev = null;\n matches = matches.filter(function (item) {\n var caption = item.snippet || item.caption || item.value;\n if (caption === prev)\n return false;\n prev = caption;\n return true;\n });\n this.filtered = matches;\n };\n FilteredList.prototype.filterCompletions = function (items, needle) {\n var results = [];\n var upper = needle.toUpperCase();\n var lower = needle.toLowerCase();\n loop: for (var i = 0, item; item = items[i]; i++) {\n var caption = (!this.ignoreCaption && item.caption) || item.value || item.snippet;\n if (!caption)\n continue;\n var lastIndex = -1;\n var matchMask = 0;\n var penalty = 0;\n var index, distance;\n if (this.exactMatch) {\n if (needle !== caption.substr(0, needle.length))\n continue loop;\n }\n else {\n var fullMatchIndex = caption.toLowerCase().indexOf(lower);\n if (fullMatchIndex > -1) {\n penalty = fullMatchIndex;\n }\n else {\n for (var j = 0; j < needle.length; j++) {\n var i1 = caption.indexOf(lower[j], lastIndex + 1);\n var i2 = caption.indexOf(upper[j], lastIndex + 1);\n index = (i1 >= 0) ? ((i2 < 0 || i1 < i2) ? i1 : i2) : i2;\n if (index < 0)\n continue loop;\n distance = index - lastIndex - 1;\n if (distance > 0) {\n if (lastIndex === -1)\n penalty += 10;\n penalty += distance;\n matchMask = matchMask | (1 << j);\n }\n lastIndex = index;\n }\n }\n }\n item.matchMask = matchMask;\n item.exactMatch = penalty ? 0 : 1;\n item.$score = (item.score || 0) - penalty;\n results.push(item);\n }\n return results;\n };\n return FilteredList;\n}());\nexports.Autocomplete = Autocomplete;\nexports.CompletionProvider = CompletionProvider;\nexports.FilteredList = FilteredList;\n\n});\n\nace.define(\"ace/autocomplete/text_completer\",[\"require\",\"exports\",\"module\",\"ace/range\"], function(require, exports, module){var Range = require(\"../range\").Range;\nvar splitRegex = /[^a-zA-Z_0-9\\$\\-\\u00C0-\\u1FFF\\u2C00-\\uD7FF\\w]+/;\nfunction getWordIndex(doc, pos) {\n var textBefore = doc.getTextRange(Range.fromPoints({\n row: 0,\n column: 0\n }, pos));\n return textBefore.split(splitRegex).length - 1;\n}\nfunction wordDistance(doc, pos) {\n var prefixPos = getWordIndex(doc, pos);\n var words = doc.getValue().split(splitRegex);\n var wordScores = Object.create(null);\n var currentWord = words[prefixPos];\n words.forEach(function (word, idx) {\n if (!word || word === currentWord)\n return;\n var distance = Math.abs(prefixPos - idx);\n var score = words.length - distance;\n if (wordScores[word]) {\n wordScores[word] = Math.max(score, wordScores[word]);\n }\n else {\n wordScores[word] = score;\n }\n });\n return wordScores;\n}\nexports.getCompletions = function (editor, session, pos, prefix, callback) {\n var wordScore = wordDistance(session, pos);\n var wordList = Object.keys(wordScore);\n callback(null, wordList.map(function (word) {\n return {\n caption: word,\n value: word,\n score: wordScore[word],\n meta: \"local\"\n };\n }));\n};\n\n});\n\nace.define(\"ace/ext/language_tools\",[\"require\",\"exports\",\"module\",\"ace/snippets\",\"ace/autocomplete\",\"ace/config\",\"ace/lib/lang\",\"ace/autocomplete/util\",\"ace/autocomplete/text_completer\",\"ace/editor\",\"ace/config\"], function(require, exports, module){\"use strict\";\nvar snippetManager = require(\"../snippets\").snippetManager;\nvar Autocomplete = require(\"../autocomplete\").Autocomplete;\nvar config = require(\"../config\");\nvar lang = require(\"../lib/lang\");\nvar util = require(\"../autocomplete/util\");\nvar textCompleter = require(\"../autocomplete/text_completer\");\nvar keyWordCompleter = {\n getCompletions: function (editor, session, pos, prefix, callback) {\n if (session.$mode.completer) {\n return session.$mode.completer.getCompletions(editor, session, pos, prefix, callback);\n }\n var state = editor.session.getState(pos.row);\n var completions = session.$mode.getCompletions(state, session, pos, prefix);\n completions = completions.map(function (el) {\n el.completerId = keyWordCompleter.id;\n return el;\n });\n callback(null, completions);\n },\n id: \"keywordCompleter\"\n};\nvar transformSnippetTooltip = function (str) {\n var record = {};\n return str.replace(/\\${(\\d+)(:(.*?))?}/g, function (_, p1, p2, p3) {\n return (record[p1] = p3 || '');\n }).replace(/\\$(\\d+?)/g, function (_, p1) {\n return record[p1];\n });\n};\nvar snippetCompleter = {\n getCompletions: function (editor, session, pos, prefix, callback) {\n var scopes = [];\n var token = session.getTokenAt(pos.row, pos.column);\n if (token && token.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\\.xml$/))\n scopes.push('html-tag');\n else\n scopes = snippetManager.getActiveScopes(editor);\n var snippetMap = snippetManager.snippetMap;\n var completions = [];\n scopes.forEach(function (scope) {\n var snippets = snippetMap[scope] || [];\n for (var i = snippets.length; i--;) {\n var s = snippets[i];\n var caption = s.name || s.tabTrigger;\n if (!caption)\n continue;\n completions.push({\n caption: caption,\n snippet: s.content,\n meta: s.tabTrigger && !s.name ? s.tabTrigger + \"\\u21E5 \" : \"snippet\",\n completerId: snippetCompleter.id\n });\n }\n }, this);\n callback(null, completions);\n },\n getDocTooltip: function (item) {\n if (item.snippet && !item.docHTML) {\n item.docHTML = [\n \"\", lang.escapeHTML(item.caption), \"\", \"
\",\n lang.escapeHTML(transformSnippetTooltip(item.snippet))\n ].join(\"\");\n }\n },\n id: \"snippetCompleter\"\n};\nvar completers = [snippetCompleter, textCompleter, keyWordCompleter];\nexports.setCompleters = function (val) {\n completers.length = 0;\n if (val)\n completers.push.apply(completers, val);\n};\nexports.addCompleter = function (completer) {\n completers.push(completer);\n};\nexports.textCompleter = textCompleter;\nexports.keyWordCompleter = keyWordCompleter;\nexports.snippetCompleter = snippetCompleter;\nvar expandSnippet = {\n name: \"expandSnippet\",\n exec: function (editor) {\n return snippetManager.expandWithTab(editor);\n },\n bindKey: \"Tab\"\n};\nvar onChangeMode = function (e, editor) {\n loadSnippetsForMode(editor.session.$mode);\n};\nvar loadSnippetsForMode = function (mode) {\n if (typeof mode == \"string\")\n mode = config.$modes[mode];\n if (!mode)\n return;\n if (!snippetManager.files)\n snippetManager.files = {};\n loadSnippetFile(mode.$id, mode.snippetFileId);\n if (mode.modes)\n mode.modes.forEach(loadSnippetsForMode);\n};\nvar loadSnippetFile = function (id, snippetFilePath) {\n if (!snippetFilePath || !id || snippetManager.files[id])\n return;\n snippetManager.files[id] = {};\n config.loadModule(snippetFilePath, function (m) {\n if (!m)\n return;\n snippetManager.files[id] = m;\n if (!m.snippets && m.snippetText)\n m.snippets = snippetManager.parseSnippetFile(m.snippetText);\n snippetManager.register(m.snippets || [], m.scope);\n if (m.includeScopes) {\n snippetManager.snippetMap[m.scope].includeScopes = m.includeScopes;\n m.includeScopes.forEach(function (x) {\n loadSnippetsForMode(\"ace/mode/\" + x);\n });\n }\n });\n};\nvar doLiveAutocomplete = function (e) {\n var editor = e.editor;\n var hasCompleter = editor.completer && editor.completer.activated;\n if (e.command.name === \"backspace\") {\n if (hasCompleter && !util.getCompletionPrefix(editor))\n editor.completer.detach();\n }\n else if (e.command.name === \"insertstring\") {\n var prefix = util.getCompletionPrefix(editor);\n if (prefix && !hasCompleter) {\n var completer = Autocomplete.for(editor);\n completer.autoInsert = false;\n completer.showPopup(editor);\n }\n }\n};\nvar Editor = require(\"../editor\").Editor;\nrequire(\"../config\").defineOptions(Editor.prototype, \"editor\", {\n enableBasicAutocompletion: {\n set: function (val) {\n if (val) {\n if (!this.completers)\n this.completers = Array.isArray(val) ? val : completers;\n this.commands.addCommand(Autocomplete.startCommand);\n }\n else {\n this.commands.removeCommand(Autocomplete.startCommand);\n }\n },\n value: false\n },\n enableLiveAutocompletion: {\n set: function (val) {\n if (val) {\n if (!this.completers)\n this.completers = Array.isArray(val) ? val : completers;\n this.commands.on('afterExec', doLiveAutocomplete);\n }\n else {\n this.commands.removeListener('afterExec', doLiveAutocomplete);\n }\n },\n value: false\n },\n enableSnippets: {\n set: function (val) {\n if (val) {\n this.commands.addCommand(expandSnippet);\n this.on(\"changeMode\", onChangeMode);\n onChangeMode(null, this);\n }\n else {\n this.commands.removeCommand(expandSnippet);\n this.off(\"changeMode\", onChangeMode);\n }\n },\n value: false\n }\n});\n\n});\n\nace.define(\"ace/ext/inline_autocomplete\",[\"require\",\"exports\",\"module\",\"ace/keyboard/hash_handler\",\"ace/autocomplete/inline\",\"ace/autocomplete\",\"ace/autocomplete\",\"ace/editor\",\"ace/autocomplete/util\",\"ace/lib/lang\",\"ace/lib/dom\",\"ace/lib/useragent\",\"ace/ext/language_tools\",\"ace/ext/language_tools\",\"ace/ext/language_tools\",\"ace/config\"], function(require, exports, module){\"use strict\";\nvar HashHandler = require(\"../keyboard/hash_handler\").HashHandler;\nvar AceInline = require(\"../autocomplete/inline\").AceInline;\nvar FilteredList = require(\"../autocomplete\").FilteredList;\nvar CompletionProvider = require(\"../autocomplete\").CompletionProvider;\nvar Editor = require(\"../editor\").Editor;\nvar util = require(\"../autocomplete/util\");\nvar lang = require(\"../lib/lang\");\nvar dom = require(\"../lib/dom\");\nvar useragent = require(\"../lib/useragent\");\nvar snippetCompleter = require(\"./language_tools\").snippetCompleter;\nvar textCompleter = require(\"./language_tools\").textCompleter;\nvar keyWordCompleter = require(\"./language_tools\").keyWordCompleter;\nvar destroyCompleter = function (e, editor) {\n editor.completer && editor.completer.destroy();\n};\nvar minPosition = function (posA, posB) {\n if (posB.row > posA.row) {\n return posA;\n }\n else if (posB.row === posA.row && posB.column > posA.column) {\n return posA;\n }\n return posB;\n};\nvar InlineAutocomplete = /** @class */ (function () {\n function InlineAutocomplete(editor) {\n this.editor = editor;\n this.tooltipEnabled = true;\n this.keyboardHandler = new HashHandler(this.commands);\n this.$index = -1;\n this.blurListener = this.blurListener.bind(this);\n this.changeListener = this.changeListener.bind(this);\n this.mousewheelListener = this.mousewheelListener.bind(this);\n this.changeTimer = lang.delayedCall(function () {\n this.updateCompletions();\n }.bind(this));\n }\n InlineAutocomplete.prototype.getInlineRenderer = function () {\n if (!this.inlineRenderer)\n this.inlineRenderer = new AceInline();\n return this.inlineRenderer;\n };\n InlineAutocomplete.prototype.getInlineTooltip = function () {\n if (!this.inlineTooltip) {\n this.inlineTooltip = new InlineTooltip(this.editor, document.body || document.documentElement);\n this.inlineTooltip.setCommands(this.commands);\n }\n return this.inlineTooltip;\n };\n InlineAutocomplete.prototype.show = function (options) {\n this.activated = true;\n if (this.editor.completer !== this) {\n if (this.editor.completer)\n this.editor.completer.detach();\n this.editor.completer = this;\n }\n this.editor.on(\"changeSelection\", this.changeListener);\n this.editor.on(\"blur\", this.blurListener);\n this.editor.on(\"mousewheel\", this.mousewheelListener);\n this.updateCompletions(options);\n };\n InlineAutocomplete.prototype.$open = function () {\n if (this.editor.textInput.setAriaOptions) {\n this.editor.textInput.setAriaOptions({});\n }\n if (this.tooltipEnabled) {\n this.getInlineTooltip().show(this.editor);\n }\n else if (this.tooltipEnabled === \"hover\") {\n }\n this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);\n if (this.$index === -1) {\n this.setIndex(0);\n }\n else {\n this.$showCompletion();\n }\n this.changeTimer.cancel();\n };\n InlineAutocomplete.prototype.insertMatch = function () {\n var result = this.getCompletionProvider().insertByIndex(this.editor, this.$index);\n this.detach();\n return result;\n };\n InlineAutocomplete.prototype.changeListener = function (e) {\n var cursor = this.editor.selection.lead;\n if (cursor.row != this.base.row || cursor.column < this.base.column) {\n this.detach();\n }\n if (this.activated)\n this.changeTimer.schedule();\n else\n this.detach();\n };\n InlineAutocomplete.prototype.blurListener = function (e) {\n this.detach();\n };\n InlineAutocomplete.prototype.mousewheelListener = function (e) {\n if (this.inlineTooltip && this.inlineTooltip.isShown()) {\n this.inlineTooltip.updatePosition();\n }\n };\n InlineAutocomplete.prototype.goTo = function (where) {\n if (!this.completions || !this.completions.filtered) {\n return;\n }\n switch (where.toLowerCase()) {\n case \"prev\":\n this.setIndex(Math.max(0, this.$index - 1));\n break;\n case \"next\":\n this.setIndex(this.$index + 1);\n break;\n case \"first\":\n this.setIndex(0);\n break;\n case \"last\":\n this.setIndex(this.completions.filtered.length - 1);\n break;\n }\n };\n InlineAutocomplete.prototype.getLength = function () {\n if (!this.completions || !this.completions.filtered) {\n return 0;\n }\n return this.completions.filtered.length;\n };\n InlineAutocomplete.prototype.getData = function (index) {\n if (index == undefined || index === null) {\n return this.completions.filtered[this.$index];\n }\n else {\n return this.completions.filtered[index];\n }\n };\n InlineAutocomplete.prototype.getIndex = function () {\n return this.$index;\n };\n InlineAutocomplete.prototype.isOpen = function () {\n return this.$index >= 0;\n };\n InlineAutocomplete.prototype.setIndex = function (value) {\n if (!this.completions || !this.completions.filtered) {\n return;\n }\n var newIndex = Math.max(-1, Math.min(this.completions.filtered.length - 1, value));\n if (newIndex !== this.$index) {\n this.$index = newIndex;\n this.$showCompletion();\n }\n };\n InlineAutocomplete.prototype.getCompletionProvider = function () {\n if (!this.completionProvider)\n this.completionProvider = new CompletionProvider();\n return this.completionProvider;\n };\n InlineAutocomplete.prototype.$showCompletion = function () {\n if (!this.getInlineRenderer().show(this.editor, this.completions.filtered[this.$index], this.completions.filterText)) {\n this.getInlineRenderer().hide();\n }\n if (this.inlineTooltip && this.inlineTooltip.isShown()) {\n this.inlineTooltip.updateButtons();\n }\n };\n InlineAutocomplete.prototype.$updatePrefix = function () {\n var pos = this.editor.getCursorPosition();\n var prefix = this.editor.session.getTextRange({ start: this.base, end: pos });\n this.completions.setFilter(prefix);\n if (!this.completions.filtered.length)\n return this.detach();\n if (this.completions.filtered.length == 1\n && this.completions.filtered[0].value == prefix\n && !this.completions.filtered[0].snippet)\n return this.detach();\n this.$open(this.editor, prefix);\n return prefix;\n };\n InlineAutocomplete.prototype.updateCompletions = function (options) {\n var prefix = \"\";\n if (options && options.matches) {\n var pos = this.editor.getSelectionRange().start;\n this.base = this.editor.session.doc.createAnchor(pos.row, pos.column);\n this.base.$insertRight = true;\n this.completions = new FilteredList(options.matches);\n return this.$open(this.editor, \"\");\n }\n if (this.base && this.completions) {\n prefix = this.$updatePrefix();\n }\n var session = this.editor.getSession();\n var pos = this.editor.getCursorPosition();\n var prefix = util.getCompletionPrefix(this.editor);\n this.base = session.doc.createAnchor(pos.row, pos.column - prefix.length);\n this.base.$insertRight = true;\n var options = {\n exactMatch: true,\n ignoreCaption: true\n };\n this.getCompletionProvider().provideCompletions(this.editor, options, function (err, completions, finished) {\n var filtered = completions.filtered;\n var prefix = util.getCompletionPrefix(this.editor);\n if (finished) {\n if (!filtered.length)\n return this.detach();\n if (filtered.length == 1 && filtered[0].value == prefix && !filtered[0].snippet)\n return this.detach();\n }\n this.completions = completions;\n this.$open(this.editor, prefix);\n }.bind(this));\n };\n InlineAutocomplete.prototype.detach = function () {\n if (this.editor) {\n this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler);\n this.editor.off(\"changeSelection\", this.changeListener);\n this.editor.off(\"blur\", this.blurListener);\n this.editor.off(\"mousewheel\", this.mousewheelListener);\n }\n this.changeTimer.cancel();\n if (this.inlineTooltip) {\n this.inlineTooltip.detach();\n }\n this.setIndex(-1);\n if (this.completionProvider) {\n this.completionProvider.detach();\n }\n if (this.inlineRenderer && this.inlineRenderer.isOpen()) {\n this.inlineRenderer.hide();\n }\n if (this.base)\n this.base.detach();\n this.activated = false;\n this.completionProvider = this.completions = this.base = null;\n };\n InlineAutocomplete.prototype.destroy = function () {\n this.detach();\n if (this.inlineRenderer)\n this.inlineRenderer.destroy();\n if (this.inlineTooltip)\n this.inlineTooltip.destroy();\n if (this.editor && this.editor.completer == this) {\n this.editor.off(\"destroy\", destroyCompleter);\n this.editor.completer = null;\n }\n this.inlineTooltip = this.editor = this.inlineRenderer = null;\n };\n return InlineAutocomplete;\n}());\nInlineAutocomplete.prototype.commands = {\n \"Previous\": {\n bindKey: \"Alt-[\",\n name: \"Previous\",\n exec: function (editor) {\n editor.completer.goTo(\"prev\");\n },\n enabled: function (editor) {\n return editor.completer.getIndex() > 0;\n },\n position: 10\n },\n \"Next\": {\n bindKey: \"Alt-]\",\n name: \"Next\",\n exec: function (editor) {\n editor.completer.goTo(\"next\");\n },\n enabled: function (editor) {\n return editor.completer.getIndex() < editor.completer.getLength() - 1;\n },\n position: 20\n },\n \"Accept\": {\n bindKey: { win: \"Tab|Ctrl-Right\", mac: \"Tab|Cmd-Right\" },\n name: \"Accept\",\n exec: function (editor) {\n return editor.completer.insertMatch();\n },\n enabled: function (editor) {\n return editor.completer.getIndex() >= 0;\n },\n position: 30\n },\n \"Close\": {\n bindKey: \"Esc\",\n name: \"Close\",\n exec: function (editor) {\n editor.completer.detach();\n },\n enabled: true,\n position: 40\n }\n};\nInlineAutocomplete.for = function (editor) {\n if (editor.completer instanceof InlineAutocomplete) {\n return editor.completer;\n }\n if (editor.completer) {\n editor.completer.destroy();\n editor.completer = null;\n }\n editor.completer = new InlineAutocomplete(editor);\n editor.once(\"destroy\", destroyCompleter);\n return editor.completer;\n};\nInlineAutocomplete.startCommand = {\n name: \"startInlineAutocomplete\",\n exec: function (editor, options) {\n var completer = InlineAutocomplete.for(editor);\n completer.show(options);\n },\n bindKey: { win: \"Alt-C\", mac: \"Option-C\" }\n};\nvar completers = [snippetCompleter, textCompleter, keyWordCompleter];\nrequire(\"../config\").defineOptions(Editor.prototype, \"editor\", {\n enableInlineAutocompletion: {\n set: function (val) {\n if (val) {\n if (!this.completers)\n this.completers = Array.isArray(val) ? val : completers;\n this.commands.addCommand(InlineAutocomplete.startCommand);\n }\n else {\n this.commands.removeCommand(InlineAutocomplete.startCommand);\n }\n },\n value: false\n }\n});\nvar ENTRY_CLASS_NAME = 'inline_autocomplete_tooltip_entry';\nvar BUTTON_CLASS_NAME = 'inline_autocomplete_tooltip_button';\nvar TOOLTIP_CLASS_NAME = 'ace_tooltip ace_inline_autocomplete_tooltip';\nvar TOOLTIP_ID = 'inline_autocomplete_tooltip';\nvar InlineTooltip = /** @class */ (function () {\n function InlineTooltip(editor, parentElement) {\n this.editor = editor;\n this.htmlElement = document.createElement('div');\n var el = this.htmlElement;\n el.style.display = 'none';\n if (parentElement) {\n parentElement.appendChild(el);\n }\n el.id = TOOLTIP_ID;\n el.style['pointer-events'] = 'auto';\n el.className = TOOLTIP_CLASS_NAME;\n this.commands = {};\n this.buttons = {};\n this.eventListeners = {};\n }\n InlineTooltip.prototype.setCommands = function (commands) {\n if (!commands || !this.htmlElement) {\n return;\n }\n this.detach();\n var el = this.htmlElement;\n while (el.hasChildNodes()) {\n el.removeChild(el.firstChild);\n }\n this.commands = commands;\n this.buttons = {};\n this.eventListeners = {};\n Object.keys(commands)\n .map(function (key) { return [key, commands[key]]; })\n .filter(function (entry) { return entry[1].position > 0; })\n .sort(function (a, b) { return a[1].position - b[1].position; })\n .forEach(function (entry) {\n var key = entry[0];\n var command = entry[1];\n dom.buildDom([\"div\", { class: ENTRY_CLASS_NAME }, [['div', { class: BUTTON_CLASS_NAME, ref: key }, this.buttons]]], el, this.buttons);\n var bindKey = command.bindKey;\n if (typeof bindKey === 'object') {\n bindKey = useragent.isMac ? bindKey.mac : bindKey.win;\n }\n bindKey = bindKey.replace(\"|\", \" / \");\n var buttonText = dom.createTextNode([command.name, \"(\", bindKey, \")\"].join(\" \"));\n this.buttons[key].appendChild(buttonText);\n }.bind(this));\n };\n InlineTooltip.prototype.show = function () {\n this.detach();\n this.htmlElement.style.display = '';\n this.htmlElement.addEventListener('mousedown', captureMousedown.bind(this));\n this.updatePosition();\n this.updateButtons(true);\n };\n InlineTooltip.prototype.isShown = function () {\n return !!this.htmlElement && window.getComputedStyle(this.htmlElement).display !== \"none\";\n };\n InlineTooltip.prototype.updatePosition = function () {\n if (!this.editor) {\n return;\n }\n var renderer = this.editor.renderer;\n var ranges;\n if (this.editor.selection.getAllRanges) {\n ranges = this.editor.selection.getAllRanges();\n }\n else {\n ranges = [this.editor.getSelection()];\n }\n if (!ranges.length) {\n return;\n }\n var minPos = minPosition(ranges[0].start, ranges[0].end);\n for (var i = 0, range; range = ranges[i]; i++) {\n minPos = minPosition(minPos, minPosition(range.start, range.end));\n }\n var pos = renderer.$cursorLayer.getPixelPosition(minPos, true);\n var el = this.htmlElement;\n var screenWidth = window.innerWidth;\n var rect = this.editor.container.getBoundingClientRect();\n pos.top += rect.top - renderer.layerConfig.offset;\n pos.left += rect.left - this.editor.renderer.scrollLeft;\n pos.left += renderer.gutterWidth;\n var top = pos.top - el.offsetHeight;\n el.style.top = top + \"px\";\n el.style.bottom = \"\";\n el.style.left = Math.min(screenWidth - el.offsetWidth, pos.left) + \"px\";\n };\n InlineTooltip.prototype.updateButtons = function (force) {\n Object.keys(this.buttons).forEach(function (key) {\n var commandEnabled = this.commands[key].enabled;\n if (typeof commandEnabled === 'function') {\n commandEnabled = commandEnabled(this.editor);\n }\n if (commandEnabled && (force || !this.eventListeners[key])) {\n this.buttons[key].className = BUTTON_CLASS_NAME;\n this.buttons[key].ariaDisabled = this.buttons[key].disabled = false;\n this.buttons[key].removeAttribute(\"disabled\");\n var eventListener = function (e) {\n this.commands[key].exec(this.editor);\n e.preventDefault();\n }.bind(this);\n this.eventListeners[key] = eventListener;\n this.buttons[key].addEventListener('mousedown', eventListener);\n }\n if (!commandEnabled && (force || this.eventListeners[key])) {\n this.buttons[key].className = BUTTON_CLASS_NAME + \"_disabled\";\n this.buttons[key].ariaDisabled = this.buttons[key].disabled = true;\n this.buttons[key].setAttribute(\"disabled\", \"\");\n this.buttons[key].removeEventListener('mousedown', this.eventListeners[key]);\n delete this.eventListeners[key];\n }\n }.bind(this));\n };\n InlineTooltip.prototype.detach = function () {\n var listenerKeys = Object.keys(this.eventListeners);\n if (this.eventListeners && listenerKeys.length) {\n listenerKeys.forEach(function (key) {\n this.buttons[key].removeEventListener('mousedown', this.eventListeners[key]);\n delete this.eventListeners[key];\n }.bind(this));\n }\n if (this.htmlElement) {\n this.htmlElement.removeEventListener('mousedown', captureMousedown.bind(this));\n this.htmlElement.style.display = 'none';\n }\n };\n InlineTooltip.prototype.destroy = function () {\n this.detach();\n if (this.htmlElement) {\n this.htmlElement.parentNode.removeChild(this.htmlElement);\n }\n this.editor = null;\n this.buttons = null;\n this.htmlElement = null;\n this.controls = null;\n };\n return InlineTooltip;\n}());\nvar captureMousedown = function (e) {\n e.preventDefault();\n};\ndom.importCssString(\"\\n.ace_inline_autocomplete_tooltip {\\n display: inline-block;\\n}\\n.\".concat(ENTRY_CLASS_NAME, \" {\\n display: inline-block;\\n padding: 0 5px;\\n}\\n\\n.\").concat(BUTTON_CLASS_NAME, \" {\\n display: inline-block;\\n cursor: pointer;\\n padding: 5px;\\n}\\n\\n.\").concat(BUTTON_CLASS_NAME, \":hover {\\n background-color: rgba(0, 0, 0, 0.1);\\n}\\n\\ndiv.\").concat(BUTTON_CLASS_NAME, \"_disabled {\\n display: inline-block;\\n padding: 5px;\\n cursor: default;\\n color: #777;\\n}\"), \"inlinetooltip.css\", false);\nexports.InlineAutocomplete = InlineAutocomplete;\nexports.InlineTooltip = InlineTooltip;\nexports.TOOLTIP_ID = TOOLTIP_ID;\nexports.BUTTON_CLASS_NAME = BUTTON_CLASS_NAME;\n\n}); (function() {\n ace.require([\"ace/ext/inline_autocomplete\"], function(m) {\n if (typeof module == \"object\" && typeof exports == \"object\" && module) {\n module.exports = m;\n }\n });\n })();\n "],"mappings":"oEAAA,IAAAA,EAAAC,EAAA,CAAAC,EAAAC,IAAA,KAAI,OAAO,eAAe,CAAC,UAAU,UAAU,SAAS,cAAc,cAAc,wBAAwB,eAAe,YAAY,iBAAiB,4BAA4B,gBAAgB,gBAAgB,YAAY,EAAG,SAASC,EAASF,EAASC,EAAO,CAAC,aACtQ,IAAIE,EAAMD,EAAQ,WAAW,EACzBE,EAAMF,EAAQ,WAAW,EACzBG,EAAeH,EAAQ,qBAAqB,EAAE,aAC9CI,EAAOJ,EAAQ,YAAY,EAC3BK,EAAQL,EAAQ,SAAS,EAAE,MAC3BM,EAAYN,EAAQ,cAAc,EAAE,UACpCO,EAAcP,EAAQ,yBAAyB,EAAE,YACjDQ,EAAYR,EAAQ,aAAa,EAAE,UACnCS,EAAYT,EAAQ,aAAa,EACjCU,EAAY,CACZ,aAAc,SAAUC,EAAQ,CAC5B,OAAOA,EAAO,QAAQ,aAAaA,EAAO,QAAQ,aAAa,CAAC,CACpE,EACA,UAAW,SAAUA,EAAQC,EAAMC,EAAa,CAC5C,IAAIC,EAAOH,EAAO,QAAQ,aAAa,EACvC,OAAIE,EACOC,EAAK,QAAQ,mBAAoB;AAAA,EAAOD,EAAc,IAAI,EAC9DC,CACX,EACA,aAAc,SAAUH,EAAQ,CAC5B,OAAOA,EAAO,QAAQ,QAAQA,EAAO,kBAAkB,EAAE,GAAG,CAChE,EACA,UAAW,SAAUA,EAAQ,CACzB,OAAOA,EAAO,QAAQ,QAAQA,EAAO,kBAAkB,EAAE,IAAM,CAAC,CACpE,EACA,WAAY,SAAUA,EAAQ,CAC1B,OAAOA,EAAO,kBAAkB,EAAE,GACtC,EACA,YAAa,SAAUA,EAAQ,CAC3B,OA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,CAAG,CAAC,EAC3E,OAAO,KAAK,eAAeA,CAAG,CAClC,EAAE,KAAK,IAAI,CAAC,EAEZ,KAAK,cACL,KAAK,YAAY,oBAAoB,YAAasL,EAAiB,KAAK,IAAI,CAAC,EAC7E,KAAK,YAAY,MAAM,QAAU,OAEzC,EACAZ,EAAc,UAAU,QAAU,UAAY,CAC1C,KAAK,OAAO,EACR,KAAK,aACL,KAAK,YAAY,WAAW,YAAY,KAAK,WAAW,EAE5D,KAAK,OAAS,KACd,KAAK,QAAU,KACf,KAAK,YAAc,KACnB,KAAK,SAAW,IACpB,EACOA,CACX,EAAE,EACEY,EAAmB,SAAUpK,EAAG,CAChCA,EAAE,eAAe,CACrB,EACAjH,EAAI,gBAAgB;AAAA;AAAA;AAAA;AAAA,GAAyE,OAAO2Q,EAAkB;AAAA;AAAA;AAAA;AAAA;AAAA,EAA6D,EAAE,OAAOC,EAAmB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAiF,EAAE,OAAOA,EAAmB;AAAA;AAAA;AAAA;AAAA,KAAgE,EAAE,OAAOA,EAAmB;AAAA;AAAA;AAAA;AAAA;AAAA,EAAuG,EAAG,oBAAqB,EAAK,EAC5hB/Q,EAAQ,mBAAqB2Q,EAC7B3Q,EAAQ,cAAgB4Q,EACxB5Q,EAAQ,WAAaiR,EACrBjR,EAAQ,kBAAoB+Q,CAE5B,CAAC,GAAmB,UAAW,CACX,IAAI,QAAQ,CAAC,6BAA6B,EAAG,SAASzK,EAAG,CACjD,OAAOrG,GAAU,UAAY,OAAOD,GAAW,UAAYC,IAC3DA,EAAO,QAAUqG,EAEzB,CAAC,CACL,GAAG","names":["require_c84e28b79a13688792139cf8ef0afbd","__commonJSMin","exports","module","require","dom","oop","EventEmitter","lang","Range","RangeList","HashHandler","Tokenizer","clipboard","VARIABLES","editor","name","indentation","text","mode","date","dateFormat","str","SnippetManager","TabstopToken","escape","ch","formatMatcher","val","state","stack","ts","t","choices","operator","value","next","token","startState","x","flag","re","fmtTokens","_self","formatted","oldArgs","fmtParts","gChangeCase","i","snippet","result","afterNewLine","j","gotoNext","i1","processSnippetText","snippetText","replaceRange","cursor","line","tabString","indentString","tokens","tabstops","p","id","isNested","expanding","copyValue","copy","parentId","row","column","lines","processedSnippet","range","end","tabstopManager","TabstopManager","selectionId","self","scope","c","scopes","snippetMap","options","before","after","snippets","snippetList","snippetNameMap","wrapRegexp","src","guardedRegexp","guard","opening","addSnippet","s","map","old","key","removeSnippet","nameMap","list","m","guardRe","delta","isRemove","selectedTabstop","parents","active","parentActive","startIndex","endIndex","toRemove","session","original","fmt","e","lead","anchor","isEmpty","containsLead","containsAnchor","dir","max","index","sel","start","useLink","moveRelative","arg","ranges","dest","movePoint","point","diff","Editor","content","snippetManager","AceInline","completion","prefix","displayText","Renderer","event","getAriaId","$singleLineEditor","el","renderer","AcePopup","parentNode","popup","noop","pos","selectionMarker","lastMouseEvent","hoverMarker","setHoverMarker","selected","ariaId","hideHoverMarker","suppressRedraw","data","bgTokenizer","caption","addToken","className","lower","filterText","lastIndex","lastI","sub","lineHeight","forceShow","screenHeight","screenWidth","maxH","dims","spaceBelow","spaceAbove","fitsX","left","topdownOnly","where","array","fn","callback","completed","arLength","err","ID_REGEX","regex","buf","completer","identifierRegex","util","config","destroyCompleter","Autocomplete","hide","rect","posGhostText","keepPopupPosition","fromTooltip","container","completions","CompletionProvider","FilteredList","completionOptions","finished","filtered","all","doc","completersLength","item","tooltipNode","a","matches","total","results","processResults","isImmediate","immediateResults","b","prev","items","needle","upper","loop","matchMask","penalty","distance","fullMatchIndex","i2","splitRegex","getWordIndex","textBefore","wordDistance","prefixPos","words","wordScores","currentWord","word","idx","score","wordScore","wordList","textCompleter","keyWordCompleter","transformSnippetTooltip","record","_","p1","p2","p3","snippetCompleter","completers","expandSnippet","onChangeMode","loadSnippetsForMode","loadSnippetFile","snippetFilePath","doLiveAutocomplete","hasCompleter","useragent","minPosition","posA","posB","InlineAutocomplete","InlineTooltip","newIndex","ENTRY_CLASS_NAME","BUTTON_CLASS_NAME","TOOLTIP_CLASS_NAME","TOOLTIP_ID","parentElement","commands","entry","command","bindKey","buttonText","captureMousedown","minPos","top","force","commandEnabled","eventListener","listenerKeys"],"sourceRoot":"","file":"5c84e28b79a13688792139cf8ef0afbd.js"}