@vue/devtools
Version:
StandAlone vue-devtools
1 lines • 3.91 MB
JavaScript
"use strict";(self["webpackChunk_vue_devtools"]=self["webpackChunk_vue_devtools"]||[]).push([[9491],{19491:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval('// ESM COMPAT FLAG\n__webpack_require__.r(__webpack_exports__);\n\n// EXPORTS\n__webpack_require__.d(__webpack_exports__, {\n "setupMode": () => (/* binding */ setupMode)\n});\n\n// EXTERNAL MODULE: ../../node_modules/monaco-editor/esm/vs/language/css/fillers/monaco-editor-core.js\nvar monaco_editor_core = __webpack_require__(85244);\n;// CONCATENATED MODULE: ../../node_modules/monaco-editor/esm/vs/language/css/workerManager.js\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nvar STOP_WHEN_IDLE_FOR = 2 * 60 * 1000; // 2min\nvar WorkerManager = /** @class */ (function () {\n function WorkerManager(defaults) {\n var _this = this;\n this._defaults = defaults;\n this._worker = null;\n this._idleCheckInterval = window.setInterval(function () { return _this._checkIfIdle(); }, 30 * 1000);\n this._lastUsedTime = 0;\n this._configChangeListener = this._defaults.onDidChange(function () { return _this._stopWorker(); });\n }\n WorkerManager.prototype._stopWorker = function () {\n if (this._worker) {\n this._worker.dispose();\n this._worker = null;\n }\n this._client = null;\n };\n WorkerManager.prototype.dispose = function () {\n clearInterval(this._idleCheckInterval);\n this._configChangeListener.dispose();\n this._stopWorker();\n };\n WorkerManager.prototype._checkIfIdle = function () {\n if (!this._worker) {\n return;\n }\n var timePassedSinceLastUsed = Date.now() - this._lastUsedTime;\n if (timePassedSinceLastUsed > STOP_WHEN_IDLE_FOR) {\n this._stopWorker();\n }\n };\n WorkerManager.prototype._getClient = function () {\n this._lastUsedTime = Date.now();\n if (!this._client) {\n this._worker = monaco_editor_core/* editor.createWebWorker */.j6.createWebWorker({\n // module that exports the create() method and returns a `CSSWorker` instance\n moduleId: \'vs/language/css/cssWorker\',\n label: this._defaults.languageId,\n // passed in to the create() method\n createData: {\n languageSettings: this._defaults.diagnosticsOptions,\n languageId: this._defaults.languageId\n }\n });\n this._client = this._worker.getProxy();\n }\n return this._client;\n };\n WorkerManager.prototype.getLanguageServiceWorker = function () {\n var _this = this;\n var resources = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n resources[_i] = arguments[_i];\n }\n var _client;\n return this._getClient()\n .then(function (client) {\n _client = client;\n })\n .then(function (_) {\n return _this._worker.withSyncedResources(resources);\n })\n .then(function (_) { return _client; });\n };\n return WorkerManager;\n}());\n\n\n;// CONCATENATED MODULE: ../../node_modules/monaco-editor/esm/vs/language/css/_deps/vscode-css-languageservice/parser/cssScanner.js\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nvar cssScanner_TokenType;\n(function (TokenType) {\n TokenType[TokenType["Ident"] = 0] = "Ident";\n TokenType[TokenType["AtKeyword"] = 1] = "AtKeyword";\n TokenType[TokenType["String"] = 2] = "String";\n TokenType[TokenType["BadString"] = 3] = "BadString";\n TokenType[TokenType["UnquotedString"] = 4] = "UnquotedString";\n TokenType[TokenType["Hash"] = 5] = "Hash";\n TokenType[TokenType["Num"] = 6] = "Num";\n TokenType[TokenType["Percentage"] = 7] = "Percentage";\n TokenType[TokenType["Dimension"] = 8] = "Dimension";\n TokenType[TokenType["UnicodeRange"] = 9] = "UnicodeRange";\n TokenType[TokenType["CDO"] = 10] = "CDO";\n TokenType[TokenType["CDC"] = 11] = "CDC";\n TokenType[TokenType["Colon"] = 12] = "Colon";\n TokenType[TokenType["SemiColon"] = 13] = "SemiColon";\n TokenType[TokenType["CurlyL"] = 14] = "CurlyL";\n TokenType[TokenType["CurlyR"] = 15] = "CurlyR";\n TokenType[TokenType["ParenthesisL"] = 16] = "ParenthesisL";\n TokenType[TokenType["ParenthesisR"] = 17] = "ParenthesisR";\n TokenType[TokenType["BracketL"] = 18] = "BracketL";\n TokenType[TokenType["BracketR"] = 19] = "BracketR";\n TokenType[TokenType["Whitespace"] = 20] = "Whitespace";\n TokenType[TokenType["Includes"] = 21] = "Includes";\n TokenType[TokenType["Dashmatch"] = 22] = "Dashmatch";\n TokenType[TokenType["SubstringOperator"] = 23] = "SubstringOperator";\n TokenType[TokenType["PrefixOperator"] = 24] = "PrefixOperator";\n TokenType[TokenType["SuffixOperator"] = 25] = "SuffixOperator";\n TokenType[TokenType["Delim"] = 26] = "Delim";\n TokenType[TokenType["EMS"] = 27] = "EMS";\n TokenType[TokenType["EXS"] = 28] = "EXS";\n TokenType[TokenType["Length"] = 29] = "Length";\n TokenType[TokenType["Angle"] = 30] = "Angle";\n TokenType[TokenType["Time"] = 31] = "Time";\n TokenType[TokenType["Freq"] = 32] = "Freq";\n TokenType[TokenType["Exclamation"] = 33] = "Exclamation";\n TokenType[TokenType["Resolution"] = 34] = "Resolution";\n TokenType[TokenType["Comma"] = 35] = "Comma";\n TokenType[TokenType["Charset"] = 36] = "Charset";\n TokenType[TokenType["EscapedJavaScript"] = 37] = "EscapedJavaScript";\n TokenType[TokenType["BadEscapedJavaScript"] = 38] = "BadEscapedJavaScript";\n TokenType[TokenType["Comment"] = 39] = "Comment";\n TokenType[TokenType["SingleLineComment"] = 40] = "SingleLineComment";\n TokenType[TokenType["EOF"] = 41] = "EOF";\n TokenType[TokenType["CustomToken"] = 42] = "CustomToken";\n})(cssScanner_TokenType || (cssScanner_TokenType = {}));\nvar MultiLineStream = /** @class */ (function () {\n function MultiLineStream(source) {\n this.source = source;\n this.len = source.length;\n this.position = 0;\n }\n MultiLineStream.prototype.substring = function (from, to) {\n if (to === void 0) { to = this.position; }\n return this.source.substring(from, to);\n };\n MultiLineStream.prototype.eos = function () {\n return this.len <= this.position;\n };\n MultiLineStream.prototype.pos = function () {\n return this.position;\n };\n MultiLineStream.prototype.goBackTo = function (pos) {\n this.position = pos;\n };\n MultiLineStream.prototype.goBack = function (n) {\n this.position -= n;\n };\n MultiLineStream.prototype.advance = function (n) {\n this.position += n;\n };\n MultiLineStream.prototype.nextChar = function () {\n return this.source.charCodeAt(this.position++) || 0;\n };\n MultiLineStream.prototype.peekChar = function (n) {\n if (n === void 0) { n = 0; }\n return this.source.charCodeAt(this.position + n) || 0;\n };\n MultiLineStream.prototype.lookbackChar = function (n) {\n if (n === void 0) { n = 0; }\n return this.source.charCodeAt(this.position - n) || 0;\n };\n MultiLineStream.prototype.advanceIfChar = function (ch) {\n if (ch === this.source.charCodeAt(this.position)) {\n this.position++;\n return true;\n }\n return false;\n };\n MultiLineStream.prototype.advanceIfChars = function (ch) {\n if (this.position + ch.length > this.source.length) {\n return false;\n }\n var i = 0;\n for (; i < ch.length; i++) {\n if (this.source.charCodeAt(this.position + i) !== ch[i]) {\n return false;\n }\n }\n this.advance(i);\n return true;\n };\n MultiLineStream.prototype.advanceWhileChar = function (condition) {\n var posNow = this.position;\n while (this.position < this.len && condition(this.source.charCodeAt(this.position))) {\n this.position++;\n }\n return this.position - posNow;\n };\n return MultiLineStream;\n}());\n\nvar _a = \'a\'.charCodeAt(0);\nvar _f = \'f\'.charCodeAt(0);\nvar _z = \'z\'.charCodeAt(0);\nvar _A = \'A\'.charCodeAt(0);\nvar _F = \'F\'.charCodeAt(0);\nvar _Z = \'Z\'.charCodeAt(0);\nvar _0 = \'0\'.charCodeAt(0);\nvar _9 = \'9\'.charCodeAt(0);\nvar _TLD = \'~\'.charCodeAt(0);\nvar _HAT = \'^\'.charCodeAt(0);\nvar _EQS = \'=\'.charCodeAt(0);\nvar _PIP = \'|\'.charCodeAt(0);\nvar _MIN = \'-\'.charCodeAt(0);\nvar _USC = \'_\'.charCodeAt(0);\nvar _PRC = \'%\'.charCodeAt(0);\nvar _MUL = \'*\'.charCodeAt(0);\nvar _LPA = \'(\'.charCodeAt(0);\nvar _RPA = \')\'.charCodeAt(0);\nvar _LAN = \'<\'.charCodeAt(0);\nvar _RAN = \'>\'.charCodeAt(0);\nvar _ATS = \'@\'.charCodeAt(0);\nvar _HSH = \'#\'.charCodeAt(0);\nvar _DLR = \'$\'.charCodeAt(0);\nvar _BSL = \'\\\\\'.charCodeAt(0);\nvar _FSL = \'/\'.charCodeAt(0);\nvar _NWL = \'\\n\'.charCodeAt(0);\nvar _CAR = \'\\r\'.charCodeAt(0);\nvar _LFD = \'\\f\'.charCodeAt(0);\nvar _DQO = \'"\'.charCodeAt(0);\nvar _SQO = \'\\\'\'.charCodeAt(0);\nvar _WSP = \' \'.charCodeAt(0);\nvar _TAB = \'\\t\'.charCodeAt(0);\nvar _SEM = \';\'.charCodeAt(0);\nvar _COL = \':\'.charCodeAt(0);\nvar _CUL = \'{\'.charCodeAt(0);\nvar _CUR = \'}\'.charCodeAt(0);\nvar _BRL = \'[\'.charCodeAt(0);\nvar _BRR = \']\'.charCodeAt(0);\nvar _CMA = \',\'.charCodeAt(0);\nvar _DOT = \'.\'.charCodeAt(0);\nvar _BNG = \'!\'.charCodeAt(0);\nvar staticTokenTable = {};\nstaticTokenTable[_SEM] = cssScanner_TokenType.SemiColon;\nstaticTokenTable[_COL] = cssScanner_TokenType.Colon;\nstaticTokenTable[_CUL] = cssScanner_TokenType.CurlyL;\nstaticTokenTable[_CUR] = cssScanner_TokenType.CurlyR;\nstaticTokenTable[_BRR] = cssScanner_TokenType.BracketR;\nstaticTokenTable[_BRL] = cssScanner_TokenType.BracketL;\nstaticTokenTable[_LPA] = cssScanner_TokenType.ParenthesisL;\nstaticTokenTable[_RPA] = cssScanner_TokenType.ParenthesisR;\nstaticTokenTable[_CMA] = cssScanner_TokenType.Comma;\nvar staticUnitTable = {};\nstaticUnitTable[\'em\'] = cssScanner_TokenType.EMS;\nstaticUnitTable[\'ex\'] = cssScanner_TokenType.EXS;\nstaticUnitTable[\'px\'] = cssScanner_TokenType.Length;\nstaticUnitTable[\'cm\'] = cssScanner_TokenType.Length;\nstaticUnitTable[\'mm\'] = cssScanner_TokenType.Length;\nstaticUnitTable[\'in\'] = cssScanner_TokenType.Length;\nstaticUnitTable[\'pt\'] = cssScanner_TokenType.Length;\nstaticUnitTable[\'pc\'] = cssScanner_TokenType.Length;\nstaticUnitTable[\'deg\'] = cssScanner_TokenType.Angle;\nstaticUnitTable[\'rad\'] = cssScanner_TokenType.Angle;\nstaticUnitTable[\'grad\'] = cssScanner_TokenType.Angle;\nstaticUnitTable[\'ms\'] = cssScanner_TokenType.Time;\nstaticUnitTable[\'s\'] = cssScanner_TokenType.Time;\nstaticUnitTable[\'hz\'] = cssScanner_TokenType.Freq;\nstaticUnitTable[\'khz\'] = cssScanner_TokenType.Freq;\nstaticUnitTable[\'%\'] = cssScanner_TokenType.Percentage;\nstaticUnitTable[\'fr\'] = cssScanner_TokenType.Percentage;\nstaticUnitTable[\'dpi\'] = cssScanner_TokenType.Resolution;\nstaticUnitTable[\'dpcm\'] = cssScanner_TokenType.Resolution;\nvar cssScanner_Scanner = /** @class */ (function () {\n function Scanner() {\n this.stream = new MultiLineStream(\'\');\n this.ignoreComment = true;\n this.ignoreWhitespace = true;\n this.inURL = false;\n }\n Scanner.prototype.setSource = function (input) {\n this.stream = new MultiLineStream(input);\n };\n Scanner.prototype.finishToken = function (offset, type, text) {\n return {\n offset: offset,\n len: this.stream.pos() - offset,\n type: type,\n text: text || this.stream.substring(offset)\n };\n };\n Scanner.prototype.substring = function (offset, len) {\n return this.stream.substring(offset, offset + len);\n };\n Scanner.prototype.pos = function () {\n return this.stream.pos();\n };\n Scanner.prototype.goBackTo = function (pos) {\n this.stream.goBackTo(pos);\n };\n Scanner.prototype.scanUnquotedString = function () {\n var offset = this.stream.pos();\n var content = [];\n if (this._unquotedString(content)) {\n return this.finishToken(offset, cssScanner_TokenType.UnquotedString, content.join(\'\'));\n }\n return null;\n };\n Scanner.prototype.scan = function () {\n // processes all whitespaces and comments\n var triviaToken = this.trivia();\n if (triviaToken !== null) {\n return triviaToken;\n }\n var offset = this.stream.pos();\n // End of file/input\n if (this.stream.eos()) {\n return this.finishToken(offset, cssScanner_TokenType.EOF);\n }\n return this.scanNext(offset);\n };\n Scanner.prototype.scanNext = function (offset) {\n // CDO \x3c!--\n if (this.stream.advanceIfChars([_LAN, _BNG, _MIN, _MIN])) {\n return this.finishToken(offset, cssScanner_TokenType.CDO);\n }\n // CDC --\x3e\n if (this.stream.advanceIfChars([_MIN, _MIN, _RAN])) {\n return this.finishToken(offset, cssScanner_TokenType.CDC);\n }\n var content = [];\n if (this.ident(content)) {\n return this.finishToken(offset, cssScanner_TokenType.Ident, content.join(\'\'));\n }\n // at-keyword\n if (this.stream.advanceIfChar(_ATS)) {\n content = [\'@\'];\n if (this._name(content)) {\n var keywordText = content.join(\'\');\n if (keywordText === \'@charset\') {\n return this.finishToken(offset, cssScanner_TokenType.Charset, keywordText);\n }\n return this.finishToken(offset, cssScanner_TokenType.AtKeyword, keywordText);\n }\n else {\n return this.finishToken(offset, cssScanner_TokenType.Delim);\n }\n }\n // hash\n if (this.stream.advanceIfChar(_HSH)) {\n content = [\'#\'];\n if (this._name(content)) {\n return this.finishToken(offset, cssScanner_TokenType.Hash, content.join(\'\'));\n }\n else {\n return this.finishToken(offset, cssScanner_TokenType.Delim);\n }\n }\n // Important\n if (this.stream.advanceIfChar(_BNG)) {\n return this.finishToken(offset, cssScanner_TokenType.Exclamation);\n }\n // Numbers\n if (this._number()) {\n var pos = this.stream.pos();\n content = [this.stream.substring(offset, pos)];\n if (this.stream.advanceIfChar(_PRC)) {\n // Percentage 43%\n return this.finishToken(offset, cssScanner_TokenType.Percentage);\n }\n else if (this.ident(content)) {\n var dim = this.stream.substring(pos).toLowerCase();\n var tokenType_1 = staticUnitTable[dim];\n if (typeof tokenType_1 !== \'undefined\') {\n // Known dimension 43px\n return this.finishToken(offset, tokenType_1, content.join(\'\'));\n }\n else {\n // Unknown dimension 43ft\n return this.finishToken(offset, cssScanner_TokenType.Dimension, content.join(\'\'));\n }\n }\n return this.finishToken(offset, cssScanner_TokenType.Num);\n }\n // String, BadString\n content = [];\n var tokenType = this._string(content);\n if (tokenType !== null) {\n return this.finishToken(offset, tokenType, content.join(\'\'));\n }\n // single character tokens\n tokenType = staticTokenTable[this.stream.peekChar()];\n if (typeof tokenType !== \'undefined\') {\n this.stream.advance(1);\n return this.finishToken(offset, tokenType);\n }\n // includes ~=\n if (this.stream.peekChar(0) === _TLD && this.stream.peekChar(1) === _EQS) {\n this.stream.advance(2);\n return this.finishToken(offset, cssScanner_TokenType.Includes);\n }\n // DashMatch |=\n if (this.stream.peekChar(0) === _PIP && this.stream.peekChar(1) === _EQS) {\n this.stream.advance(2);\n return this.finishToken(offset, cssScanner_TokenType.Dashmatch);\n }\n // Substring operator *=\n if (this.stream.peekChar(0) === _MUL && this.stream.peekChar(1) === _EQS) {\n this.stream.advance(2);\n return this.finishToken(offset, cssScanner_TokenType.SubstringOperator);\n }\n // Substring operator ^=\n if (this.stream.peekChar(0) === _HAT && this.stream.peekChar(1) === _EQS) {\n this.stream.advance(2);\n return this.finishToken(offset, cssScanner_TokenType.PrefixOperator);\n }\n // Substring operator $=\n if (this.stream.peekChar(0) === _DLR && this.stream.peekChar(1) === _EQS) {\n this.stream.advance(2);\n return this.finishToken(offset, cssScanner_TokenType.SuffixOperator);\n }\n // Delim\n this.stream.nextChar();\n return this.finishToken(offset, cssScanner_TokenType.Delim);\n };\n Scanner.prototype.trivia = function () {\n while (true) {\n var offset = this.stream.pos();\n if (this._whitespace()) {\n if (!this.ignoreWhitespace) {\n return this.finishToken(offset, cssScanner_TokenType.Whitespace);\n }\n }\n else if (this.comment()) {\n if (!this.ignoreComment) {\n return this.finishToken(offset, cssScanner_TokenType.Comment);\n }\n }\n else {\n return null;\n }\n }\n };\n Scanner.prototype.comment = function () {\n if (this.stream.advanceIfChars([_FSL, _MUL])) {\n var success_1 = false, hot_1 = false;\n this.stream.advanceWhileChar(function (ch) {\n if (hot_1 && ch === _FSL) {\n success_1 = true;\n return false;\n }\n hot_1 = ch === _MUL;\n return true;\n });\n if (success_1) {\n this.stream.advance(1);\n }\n return true;\n }\n return false;\n };\n Scanner.prototype._number = function () {\n var npeek = 0, ch;\n if (this.stream.peekChar() === _DOT) {\n npeek = 1;\n }\n ch = this.stream.peekChar(npeek);\n if (ch >= _0 && ch <= _9) {\n this.stream.advance(npeek + 1);\n this.stream.advanceWhileChar(function (ch) {\n return ch >= _0 && ch <= _9 || npeek === 0 && ch === _DOT;\n });\n return true;\n }\n return false;\n };\n Scanner.prototype._newline = function (result) {\n var ch = this.stream.peekChar();\n switch (ch) {\n case _CAR:\n case _LFD:\n case _NWL:\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n if (ch === _CAR && this.stream.advanceIfChar(_NWL)) {\n result.push(\'\\n\');\n }\n return true;\n }\n return false;\n };\n Scanner.prototype._escape = function (result, includeNewLines) {\n var ch = this.stream.peekChar();\n if (ch === _BSL) {\n this.stream.advance(1);\n ch = this.stream.peekChar();\n var hexNumCount = 0;\n while (hexNumCount < 6 && (ch >= _0 && ch <= _9 || ch >= _a && ch <= _f || ch >= _A && ch <= _F)) {\n this.stream.advance(1);\n ch = this.stream.peekChar();\n hexNumCount++;\n }\n if (hexNumCount > 0) {\n try {\n var hexVal = parseInt(this.stream.substring(this.stream.pos() - hexNumCount), 16);\n if (hexVal) {\n result.push(String.fromCharCode(hexVal));\n }\n }\n catch (e) {\n // ignore\n }\n // optional whitespace or new line, not part of result text\n if (ch === _WSP || ch === _TAB) {\n this.stream.advance(1);\n }\n else {\n this._newline([]);\n }\n return true;\n }\n if (ch !== _CAR && ch !== _LFD && ch !== _NWL) {\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n return true;\n }\n else if (includeNewLines) {\n return this._newline(result);\n }\n }\n return false;\n };\n Scanner.prototype._stringChar = function (closeQuote, result) {\n // not closeQuote, not backslash, not newline\n var ch = this.stream.peekChar();\n if (ch !== 0 && ch !== closeQuote && ch !== _BSL && ch !== _CAR && ch !== _LFD && ch !== _NWL) {\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n return true;\n }\n return false;\n };\n Scanner.prototype._string = function (result) {\n if (this.stream.peekChar() === _SQO || this.stream.peekChar() === _DQO) {\n var closeQuote = this.stream.nextChar();\n result.push(String.fromCharCode(closeQuote));\n while (this._stringChar(closeQuote, result) || this._escape(result, true)) {\n // loop\n }\n if (this.stream.peekChar() === closeQuote) {\n this.stream.nextChar();\n result.push(String.fromCharCode(closeQuote));\n return cssScanner_TokenType.String;\n }\n else {\n return cssScanner_TokenType.BadString;\n }\n }\n return null;\n };\n Scanner.prototype._unquotedChar = function (result) {\n // not closeQuote, not backslash, not newline\n var ch = this.stream.peekChar();\n if (ch !== 0 && ch !== _BSL && ch !== _SQO && ch !== _DQO && ch !== _LPA && ch !== _RPA && ch !== _WSP && ch !== _TAB && ch !== _NWL && ch !== _LFD && ch !== _CAR) {\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n return true;\n }\n return false;\n };\n Scanner.prototype._unquotedString = function (result) {\n var hasContent = false;\n while (this._unquotedChar(result) || this._escape(result)) {\n hasContent = true;\n }\n return hasContent;\n };\n Scanner.prototype._whitespace = function () {\n var n = this.stream.advanceWhileChar(function (ch) {\n return ch === _WSP || ch === _TAB || ch === _NWL || ch === _LFD || ch === _CAR;\n });\n return n > 0;\n };\n Scanner.prototype._name = function (result) {\n var matched = false;\n while (this._identChar(result) || this._escape(result)) {\n matched = true;\n }\n return matched;\n };\n Scanner.prototype.ident = function (result) {\n var pos = this.stream.pos();\n var hasMinus = this._minus(result);\n if (hasMinus && this._minus(result) /* -- */) {\n if (this._identFirstChar(result) || this._escape(result)) {\n while (this._identChar(result) || this._escape(result)) {\n // loop\n }\n return true;\n }\n }\n else if (this._identFirstChar(result) || this._escape(result)) {\n while (this._identChar(result) || this._escape(result)) {\n // loop\n }\n return true;\n }\n this.stream.goBackTo(pos);\n return false;\n };\n Scanner.prototype._identFirstChar = function (result) {\n var ch = this.stream.peekChar();\n if (ch === _USC || // _\n ch >= _a && ch <= _z || // a-z\n ch >= _A && ch <= _Z || // A-Z\n ch >= 0x80 && ch <= 0xFFFF) { // nonascii\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n return true;\n }\n return false;\n };\n Scanner.prototype._minus = function (result) {\n var ch = this.stream.peekChar();\n if (ch === _MIN) {\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n return true;\n }\n return false;\n };\n Scanner.prototype._identChar = function (result) {\n var ch = this.stream.peekChar();\n if (ch === _USC || // _\n ch === _MIN || // -\n ch >= _a && ch <= _z || // a-z\n ch >= _A && ch <= _Z || // A-Z\n ch >= _0 && ch <= _9 || // 0/9\n ch >= 0x80 && ch <= 0xFFFF) { // nonascii\n this.stream.advance(1);\n result.push(String.fromCharCode(ch));\n return true;\n }\n return false;\n };\n return Scanner;\n}());\n\n\n;// CONCATENATED MODULE: ../../node_modules/monaco-editor/esm/vs/language/css/_deps/vscode-css-languageservice/utils/strings.js\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nfunction startsWith(haystack, needle) {\n if (haystack.length < needle.length) {\n return false;\n }\n for (var i = 0; i < needle.length; i++) {\n if (haystack[i] !== needle[i]) {\n return false;\n }\n }\n return true;\n}\n/**\n * Determines if haystack ends with needle.\n */\nfunction endsWith(haystack, needle) {\n var diff = haystack.length - needle.length;\n if (diff > 0) {\n return haystack.lastIndexOf(needle) === diff;\n }\n else if (diff === 0) {\n return haystack === needle;\n }\n else {\n return false;\n }\n}\n/**\n * Computes the difference score for two strings. More similar strings have a higher score.\n * We use largest common subsequence dynamic programming approach but penalize in the end for length differences.\n * Strings that have a large length difference will get a bad default score 0.\n * Complexity - both time and space O(first.length * second.length)\n * Dynamic programming LCS computation http://en.wikipedia.org/wiki/Longest_common_subsequence_problem\n *\n * @param first a string\n * @param second a string\n */\nfunction difference(first, second, maxLenDelta) {\n if (maxLenDelta === void 0) { maxLenDelta = 4; }\n var lengthDifference = Math.abs(first.length - second.length);\n // We only compute score if length of the currentWord and length of entry.name are similar.\n if (lengthDifference > maxLenDelta) {\n return 0;\n }\n // Initialize LCS (largest common subsequence) matrix.\n var LCS = [];\n var zeroArray = [];\n var i, j;\n for (i = 0; i < second.length + 1; ++i) {\n zeroArray.push(0);\n }\n for (i = 0; i < first.length + 1; ++i) {\n LCS.push(zeroArray);\n }\n for (i = 1; i < first.length + 1; ++i) {\n for (j = 1; j < second.length + 1; ++j) {\n if (first[i - 1] === second[j - 1]) {\n LCS[i][j] = LCS[i - 1][j - 1] + 1;\n }\n else {\n LCS[i][j] = Math.max(LCS[i - 1][j], LCS[i][j - 1]);\n }\n }\n }\n return LCS[first.length][second.length] - Math.sqrt(lengthDifference);\n}\n/**\n * Limit of string length.\n */\nfunction getLimitedString(str, ellipsis) {\n if (ellipsis === void 0) { ellipsis = true; }\n if (!str) {\n return \'\';\n }\n if (str.length < 140) {\n return str;\n }\n return str.slice(0, 140) + (ellipsis ? \'\\u2026\' : \'\');\n}\n/**\n * Limit of string length.\n */\nfunction trim(str, regexp) {\n var m = regexp.exec(str);\n if (m && m[0].length) {\n return str.substr(0, str.length - m[0].length);\n }\n return str;\n}\n\n;// CONCATENATED MODULE: ../../node_modules/monaco-editor/esm/vs/language/css/_deps/vscode-css-languageservice/parser/cssNodes.js\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nvar __extends = (undefined && undefined.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== "function" && b !== null)\n throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n\n/// <summary>\n/// Nodes for the css 2.1 specification. See for reference:\n/// http://www.w3.org/TR/CSS21/grammar.html#grammar\n/// </summary>\nvar cssNodes_NodeType;\n(function (NodeType) {\n NodeType[NodeType["Undefined"] = 0] = "Undefined";\n NodeType[NodeType["Identifier"] = 1] = "Identifier";\n NodeType[NodeType["Stylesheet"] = 2] = "Stylesheet";\n NodeType[NodeType["Ruleset"] = 3] = "Ruleset";\n NodeType[NodeType["Selector"] = 4] = "Selector";\n NodeType[NodeType["SimpleSelector"] = 5] = "SimpleSelector";\n NodeType[NodeType["SelectorInterpolation"] = 6] = "SelectorInterpolation";\n NodeType[NodeType["SelectorCombinator"] = 7] = "SelectorCombinator";\n NodeType[NodeType["SelectorCombinatorParent"] = 8] = "SelectorCombinatorParent";\n NodeType[NodeType["SelectorCombinatorSibling"] = 9] = "SelectorCombinatorSibling";\n NodeType[NodeType["SelectorCombinatorAllSiblings"] = 10] = "SelectorCombinatorAllSiblings";\n NodeType[NodeType["SelectorCombinatorShadowPiercingDescendant"] = 11] = "SelectorCombinatorShadowPiercingDescendant";\n NodeType[NodeType["Page"] = 12] = "Page";\n NodeType[NodeType["PageBoxMarginBox"] = 13] = "PageBoxMarginBox";\n NodeType[NodeType["ClassSelector"] = 14] = "ClassSelector";\n NodeType[NodeType["IdentifierSelector"] = 15] = "IdentifierSelector";\n NodeType[NodeType["ElementNameSelector"] = 16] = "ElementNameSelector";\n NodeType[NodeType["PseudoSelector"] = 17] = "PseudoSelector";\n NodeType[NodeType["AttributeSelector"] = 18] = "AttributeSelector";\n NodeType[NodeType["Declaration"] = 19] = "Declaration";\n NodeType[NodeType["Declarations"] = 20] = "Declarations";\n NodeType[NodeType["Property"] = 21] = "Property";\n NodeType[NodeType["Expression"] = 22] = "Expression";\n NodeType[NodeType["BinaryExpression"] = 23] = "BinaryExpression";\n NodeType[NodeType["Term"] = 24] = "Term";\n NodeType[NodeType["Operator"] = 25] = "Operator";\n NodeType[NodeType["Value"] = 26] = "Value";\n NodeType[NodeType["StringLiteral"] = 27] = "StringLiteral";\n NodeType[NodeType["URILiteral"] = 28] = "URILiteral";\n NodeType[NodeType["EscapedValue"] = 29] = "EscapedValue";\n NodeType[NodeType["Function"] = 30] = "Function";\n NodeType[NodeType["NumericValue"] = 31] = "NumericValue";\n NodeType[NodeType["HexColorValue"] = 32] = "HexColorValue";\n NodeType[NodeType["MixinDeclaration"] = 33] = "MixinDeclaration";\n NodeType[NodeType["MixinReference"] = 34] = "MixinReference";\n NodeType[NodeType["VariableName"] = 35] = "VariableName";\n NodeType[NodeType["VariableDeclaration"] = 36] = "VariableDeclaration";\n NodeType[NodeType["Prio"] = 37] = "Prio";\n NodeType[NodeType["Interpolation"] = 38] = "Interpolation";\n NodeType[NodeType["NestedProperties"] = 39] = "NestedProperties";\n NodeType[NodeType["ExtendsReference"] = 40] = "ExtendsReference";\n NodeType[NodeType["SelectorPlaceholder"] = 41] = "SelectorPlaceholder";\n NodeType[NodeType["Debug"] = 42] = "Debug";\n NodeType[NodeType["If"] = 43] = "If";\n NodeType[NodeType["Else"] = 44] = "Else";\n NodeType[NodeType["For"] = 45] = "For";\n NodeType[NodeType["Each"] = 46] = "Each";\n NodeType[NodeType["While"] = 47] = "While";\n NodeType[NodeType["MixinContentReference"] = 48] = "MixinContentReference";\n NodeType[NodeType["MixinContentDeclaration"] = 49] = "MixinContentDeclaration";\n NodeType[NodeType["Media"] = 50] = "Media";\n NodeType[NodeType["Keyframe"] = 51] = "Keyframe";\n NodeType[NodeType["FontFace"] = 52] = "FontFace";\n NodeType[NodeType["Import"] = 53] = "Import";\n NodeType[NodeType["Namespace"] = 54] = "Namespace";\n NodeType[NodeType["Invocation"] = 55] = "Invocation";\n NodeType[NodeType["FunctionDeclaration"] = 56] = "FunctionDeclaration";\n NodeType[NodeType["ReturnStatement"] = 57] = "ReturnStatement";\n NodeType[NodeType["MediaQuery"] = 58] = "MediaQuery";\n NodeType[NodeType["FunctionParameter"] = 59] = "FunctionParameter";\n NodeType[NodeType["FunctionArgument"] = 60] = "FunctionArgument";\n NodeType[NodeType["KeyframeSelector"] = 61] = "KeyframeSelector";\n NodeType[NodeType["ViewPort"] = 62] = "ViewPort";\n NodeType[NodeType["Document"] = 63] = "Document";\n NodeType[NodeType["AtApplyRule"] = 64] = "AtApplyRule";\n NodeType[NodeType["CustomPropertyDeclaration"] = 65] = "CustomPropertyDeclaration";\n NodeType[NodeType["CustomPropertySet"] = 66] = "CustomPropertySet";\n NodeType[NodeType["ListEntry"] = 67] = "ListEntry";\n NodeType[NodeType["Supports"] = 68] = "Supports";\n NodeType[NodeType["SupportsCondition"] = 69] = "SupportsCondition";\n NodeType[NodeType["NamespacePrefix"] = 70] = "NamespacePrefix";\n NodeType[NodeType["GridLine"] = 71] = "GridLine";\n NodeType[NodeType["Plugin"] = 72] = "Plugin";\n NodeType[NodeType["UnknownAtRule"] = 73] = "UnknownAtRule";\n NodeType[NodeType["Use"] = 74] = "Use";\n NodeType[NodeType["ModuleConfiguration"] = 75] = "ModuleConfiguration";\n NodeType[NodeType["Forward"] = 76] = "Forward";\n NodeType[NodeType["ForwardVisibility"] = 77] = "ForwardVisibility";\n NodeType[NodeType["Module"] = 78] = "Module";\n})(cssNodes_NodeType || (cssNodes_NodeType = {}));\nvar ReferenceType;\n(function (ReferenceType) {\n ReferenceType[ReferenceType["Mixin"] = 0] = "Mixin";\n ReferenceType[ReferenceType["Rule"] = 1] = "Rule";\n ReferenceType[ReferenceType["Variable"] = 2] = "Variable";\n ReferenceType[ReferenceType["Function"] = 3] = "Function";\n ReferenceType[ReferenceType["Keyframe"] = 4] = "Keyframe";\n ReferenceType[ReferenceType["Unknown"] = 5] = "Unknown";\n ReferenceType[ReferenceType["Module"] = 6] = "Module";\n ReferenceType[ReferenceType["Forward"] = 7] = "Forward";\n ReferenceType[ReferenceType["ForwardVisibility"] = 8] = "ForwardVisibility";\n})(ReferenceType || (ReferenceType = {}));\nfunction getNodeAtOffset(node, offset) {\n var candidate = null;\n if (!node || offset < node.offset || offset > node.end) {\n return null;\n }\n // Find the shortest node at the position\n node.accept(function (node) {\n if (node.offset === -1 && node.length === -1) {\n return true;\n }\n if (node.offset <= offset && node.end >= offset) {\n if (!candidate) {\n candidate = node;\n }\n else if (node.length <= candidate.length) {\n candidate = node;\n }\n return true;\n }\n return false;\n });\n return candidate;\n}\nfunction getNodePath(node, offset) {\n var candidate = getNodeAtOffset(node, offset);\n var path = [];\n while (candidate) {\n path.unshift(candidate);\n candidate = candidate.parent;\n }\n return path;\n}\nfunction getParentDeclaration(node) {\n var decl = node.findParent(cssNodes_NodeType.Declaration);\n var value = decl && decl.getValue();\n if (value && value.encloses(node)) {\n return decl;\n }\n return null;\n}\nvar Node = /** @class */ (function () {\n function Node(offset, len, nodeType) {\n if (offset === void 0) { offset = -1; }\n if (len === void 0) { len = -1; }\n this.parent = null;\n this.offset = offset;\n this.length = len;\n if (nodeType) {\n this.nodeType = nodeType;\n }\n }\n Object.defineProperty(Node.prototype, "end", {\n get: function () { return this.offset + this.length; },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(Node.prototype, "type", {\n get: function () {\n return this.nodeType || cssNodes_NodeType.Undefined;\n },\n set: function (type) {\n this.nodeType = type;\n },\n enumerable: false,\n configurable: true\n });\n Node.prototype.getTextProvider = function () {\n var node = this;\n while (node && !node.textProvider) {\n node = node.parent;\n }\n if (node) {\n return node.textProvider;\n }\n return function () { return \'unknown\'; };\n };\n Node.prototype.getText = function () {\n return this.getTextProvider()(this.offset, this.length);\n };\n Node.prototype.matches = function (str) {\n return this.length === str.length && this.getTextProvider()(this.offset, this.length) === str;\n };\n Node.prototype.startsWith = function (str) {\n return this.length >= str.length && this.getTextProvider()(this.offset, str.length) === str;\n };\n Node.prototype.endsWith = function (str) {\n return this.length >= str.length && this.getTextProvider()(this.end - str.length, str.length) === str;\n };\n Node.prototype.accept = function (visitor) {\n if (visitor(this) && this.children) {\n for (var _i = 0, _a = this.children; _i < _a.length; _i++) {\n var child = _a[_i];\n child.accept(visitor);\n }\n }\n };\n Node.prototype.acceptVisitor = function (visitor) {\n this.accept(visitor.visitNode.bind(visitor));\n };\n Node.prototype.adoptChild = function (node, index) {\n if (index === void 0) { index = -1; }\n if (node.parent && node.parent.children) {\n var idx = node.parent.children.indexOf(node);\n if (idx >= 0) {\n node.parent.children.splice(idx, 1);\n }\n }\n node.parent = this;\n var children = this.children;\n if (!children) {\n children = this.children = [];\n }\n if (index !== -1) {\n children.splice(index, 0, node);\n }\n else {\n children.push(node);\n }\n return node;\n };\n Node.prototype.attachTo = function (parent, index) {\n if (index === void 0) { index = -1; }\n if (parent) {\n parent.adoptChild(this, index);\n }\n return this;\n };\n Node.prototype.collectIssues = function (results) {\n if (this.issues) {\n results.push.apply(results, this.issues);\n }\n };\n Node.prototype.addIssue = function (issue) {\n if (!this.issues) {\n this.issues = [];\n }\n this.issues.push(issue);\n };\n Node.prototype.hasIssue = function (rule) {\n return Array.isArray(this.issues) && this.issues.some(function (i) { return i.getRule() === rule; });\n };\n Node.prototype.isErroneous = function (recursive) {\n if (recursive === void 0) { recursive = false; }\n if (this.issues && this.issues.length > 0) {\n return true;\n }\n return recursive && Array.isArray(this.children) && this.children.some(function (c) { return c.isErroneous(true); });\n };\n Node.prototype.setNode = function (field, node, index) {\n if (index === void 0) { index = -1; }\n if (node) {\n node.attachTo(this, index);\n this[field] = node;\n return true;\n }\n return false;\n };\n Node.prototype.addChild = function (node) {\n if (node) {\n if (!this.children) {\n this.children = [];\n }\n node.attachTo(this);\n this.updateOffsetAndLength(node);\n return true;\n }\n return false;\n };\n Node.prototype.updateOffsetAndLength = function (node) {\n if (node.offset < this.offset || this.offset === -1) {\n this.offset = node.offset;\n }\n var nodeEnd = node.end;\n if ((nodeEnd > this.end) || this.length === -1) {\n this.length = nodeEnd - this.offset;\n }\n };\n Node.prototype.hasChildren = function () {\n return !!this.children && this.children.length > 0;\n };\n Node.prototype.getChildren = function () {\n return this.children ? this.children.slice(0) : [];\n };\n Node.prototype.getChild = function (index) {\n if (this.children && index < this.children.length) {\n return this.children[index];\n }\n return null;\n };\n Node.prototype.addChildren = function (nodes) {\n for (var _i = 0, nodes_1 = nodes; _i < nodes_1.length; _i++) {\n var node = nodes_1[_i];\n this.addChild(node);\n }\n };\n Node.prototype.findFirstChildBeforeOffset = function (offset) {\n if (this.children) {\n var current = null;\n for (var i = this.children.length - 1; i >= 0; i--) {\n // iterate until we find a child that has a start offset smaller than the input offset\n current = this.children[i];\n if (current.offset <= offset) {\n return current;\n }\n }\n }\n return null;\n };\n Node.prototype.findChildAtOffset = function (offset, goDeep) {\n var current = this.findFirstChildBeforeOffset(offset);\n if (current && current.end >= offset) {\n if (goDeep) {\n return current.findChildAtOffset(offset, true) || current;\n }\n return current;\n }\n return null;\n };\n Node.prototype.encloses = function (candidate) {\n return this.offset <= candidate.offset && this.offset + this.length >= candidate.offset + candidate.length;\n };\n Node.prototype.getParent = function () {\n var result = this.parent;\n while (result instanceof Nodelist) {\n result = result.parent;\n }\n return result;\n };\n Node.prototype.findParent = function (type) {\n var result = this;\n while (result && result.type !== type) {\n result = result.parent;\n }\n return result;\n };\n Node.prototype.findAParent = function () {\n var types = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n types[_i] = arguments[_i];\n }\n var result = this;\n while (result && !types.some(function (t) { return result.type === t; })) {\n result = result.parent;\n }\n return result;\n };\n Node.prototype.setData = function (key, value) {\n if (!this.options) {\n this.options = {};\n }\n this.options[key] = value;\n };\n Node.prototype.getData = function (key) {\n if (!this.options || !this.options.hasOwnProperty(key)) {\n return null;\n }\n return this.options[key];\n };\n return Node;\n}());\n\nvar Nodelist = /** @class */ (function (_super) {\n __extends(Nodelist, _super);\n function Nodelist(parent, index) {\n if (index === void 0) { index = -1; }\n var _this = _super.call(this, -1, -1) || this;\n _this.attachTo(parent, index);\n _this.offset = -1;\n _this.length = -1;\n return _this;\n }\n return Nodelist;\n}(Node));\n\nvar Identifier = /** @class */ (function (_super) {\n __extends(Identifier, _super);\n function Identifier(offset, length) {\n var _this = _super.call(this, offset, length) || this;\n _this.isCustomProperty = false;\n return _this;\n }\n Object.defineProperty(Identifier.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.Identifier;\n },\n enumerable: false,\n configurable: true\n });\n Identifier.prototype.containsInterpolation = function () {\n return this.hasChildren();\n };\n return Identifier;\n}(Node));\n\nvar Stylesheet = /** @class */ (function (_super) {\n __extends(Stylesheet, _super);\n function Stylesheet(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n Object.defineProperty(Stylesheet.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.Stylesheet;\n },\n enumerable: false,\n configurable: true\n });\n return Stylesheet;\n}(Node));\n\nvar Declarations = /** @class */ (function (_super) {\n __extends(Declarations, _super);\n function Declarations(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n Object.defineProperty(Declarations.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.Declarations;\n },\n enumerable: false,\n configurable: true\n });\n return Declarations;\n}(Node));\n\nvar BodyDeclaration = /** @class */ (function (_super) {\n __extends(BodyDeclaration, _super);\n function BodyDeclaration(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n BodyDeclaration.prototype.getDeclarations = function () {\n return this.declarations;\n };\n BodyDeclaration.prototype.setDeclarations = function (decls) {\n return this.setNode(\'declarations\', decls);\n };\n return BodyDeclaration;\n}(Node));\n\nvar RuleSet = /** @class */ (function (_super) {\n __extends(RuleSet, _super);\n function RuleSet(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n Object.defineProperty(RuleSet.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.Ruleset;\n },\n enumerable: false,\n configurable: true\n });\n RuleSet.prototype.getSelectors = function () {\n if (!this.selectors) {\n this.selectors = new Nodelist(this);\n }\n return this.selectors;\n };\n RuleSet.prototype.isNested = function () {\n return !!this.parent && this.parent.findParent(cssNodes_NodeType.Declarations) !== null;\n };\n return RuleSet;\n}(BodyDeclaration));\n\nvar Selector = /** @class */ (function (_super) {\n __extends(Selector, _super);\n function Selector(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n Object.defineProperty(Selector.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.Selector;\n },\n enumerable: false,\n configurable: true\n });\n return Selector;\n}(Node));\n\nvar SimpleSelector = /** @class */ (function (_super) {\n __extends(SimpleSelector, _super);\n function SimpleSelector(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n Object.defineProperty(SimpleSelector.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.SimpleSelector;\n },\n enumerable: false,\n configurable: true\n });\n return SimpleSelector;\n}(Node));\n\nvar AtApplyRule = /** @class */ (function (_super) {\n __extends(AtApplyRule, _super);\n function AtApplyRule(offset, length) {\n return _super.call(this, offset, length) || this;\n }\n Object.defineProperty(AtApplyRule.prototype, "type", {\n get: function () {\n return cssNodes_NodeType.AtApplyRule;\n },\n enumerable: false,\n configurable: true\n });\n AtApplyRule.prototype.setIdentifier =