@kusto/monaco-kusto 11.4.0 → 12.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +25 -1
- package/package.json +3 -1
- package/release/dev/kustoMode-d3f9e09a.js +1818 -0
- package/release/dev/kustoMode.js +4 -2040
- package/release/dev/kustoWorker.js +49 -90
- package/release/dev/{main-1587ba64.js → main-f36cb42f.js} +2 -2
- package/release/dev/monaco.contribution.js +254 -214
- package/release/dev/{schema-a5230652.js → schema-077630e6.js} +13 -2
- package/release/esm/extendedGlobalApi/getRangeHtml.d.ts +2 -0
- package/release/esm/extendedGlobalApi/getRangeHtml.js +11 -0
- package/release/esm/extendedGlobalApi/index.d.ts +1 -0
- package/release/esm/extendedGlobalApi/index.js +1 -0
- package/release/esm/globals.d.ts +1 -0
- package/release/esm/globals.js +1 -0
- package/release/esm/kusto.worker.js +39 -91
- package/release/esm/kustoMode-349f5467.js +957 -0
- package/release/esm/kustoMode.d.ts +4 -8
- package/release/esm/kustoMode.js +94 -104
- package/release/esm/kustoWorker.d.ts +2 -5
- package/release/esm/kustoWorker.js +2 -5
- package/release/esm/languageFeatures.d.ts +1 -14
- package/release/esm/languageFeatures.js +0 -299
- package/release/esm/languageServiceManager/kustoLanguageService.d.ts +2 -4
- package/release/esm/languageServiceManager/kustoLanguageService.js +58 -71
- package/release/esm/languageServiceManager/schema.d.ts +2 -2
- package/release/esm/languageServiceManager/settings.d.ts +0 -2
- package/release/esm/monaco.contribution.d.ts +1 -6
- package/release/esm/monaco.contribution.js +64 -88
- package/release/esm/{schema-c006895b.js → schema-b8f0ba9b.js} +12 -2
- package/release/esm/syntaxHighlighting/SemanticTokensProvider.d.ts +18 -0
- package/release/esm/syntaxHighlighting/SemanticTokensProvider.js +78 -0
- package/release/esm/syntaxHighlighting/kustoMonarchLanguageDefinition.d.ts +2 -0
- package/release/esm/syntaxHighlighting/kustoMonarchLanguageDefinition.js +401 -0
- package/release/esm/syntaxHighlighting/semanticTokensProviderRegistrar.d.ts +6 -0
- package/release/esm/syntaxHighlighting/semanticTokensProviderRegistrar.js +23 -0
- package/release/esm/syntaxHighlighting/themes.d.ts +11 -0
- package/release/esm/syntaxHighlighting/themes.js +103 -0
- package/release/esm/syntaxHighlighting/types.d.ts +41 -0
- package/release/esm/syntaxHighlighting/types.js +55 -0
- package/release/min/kustoMode-2dd4a01e.js +7 -0
- package/release/min/kustoMode.js +2 -2
- package/release/min/kustoWorker.js +4 -4
- package/release/min/{main-75aa3e71.js → main-86d6c837.js} +2 -2
- package/release/min/monaco.contribution.js +2 -2
- package/release/min/schema-a60c216c.js +7 -0
- package/release/esm/languageServiceManager/kustoMonarchLanguageDefinition.d.ts +0 -2
- package/release/esm/languageServiceManager/kustoMonarchLanguageDefinition.js +0 -211
- package/release/min/schema-192b3175.js +0 -7
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!-----------------------------------------------------------------------------
|
|
2
2
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
-
* monaco-kusto version:
|
|
3
|
+
* monaco-kusto version: 12.0.1(56b90ce0fd31e7d6792f5098d1e8204274966b6e)
|
|
4
4
|
* Released under the MIT license
|
|
5
5
|
* https://https://github.com/Azure/monaco-kusto/blob/master/README.md
|
|
6
6
|
*-----------------------------------------------------------------------------*/
|
|
7
7
|
|
|
8
|
-
define('vs/language/kusto/kustoWorker', ['exports', './main-
|
|
8
|
+
define('vs/language/kusto/kustoWorker', ['exports', './main-f36cb42f', './schema-077630e6'], (function (exports, main, schema) { 'use strict';
|
|
9
9
|
|
|
10
10
|
function _slicedToArray$2(r, e) { return _arrayWithHoles$2(r) || _iterableToArrayLimit$2(r, e) || _unsupportedIterableToArray$3(r, e) || _nonIterableRest$2(); }
|
|
11
11
|
function _nonIterableRest$2() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -3473,6 +3473,9 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
3473
3473
|
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
3474
3474
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3475
3475
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
3476
|
+
function _regeneratorRuntime() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof$1(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof$1(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
3477
|
+
function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
|
|
3478
|
+
function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
|
|
3476
3479
|
function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray$1(r) || _nonIterableSpread(); }
|
|
3477
3480
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
3478
3481
|
function _unsupportedIterableToArray$1(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$1(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$1(r, a) : void 0; } }
|
|
@@ -3543,21 +3546,6 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
3543
3546
|
* This issue started happening once upgrading to 0.20.0 from 0.15.5.
|
|
3544
3547
|
*/
|
|
3545
3548
|
|
|
3546
|
-
/**
|
|
3547
|
-
* convert the bridge.net object to a plain javascript object that only contains data.
|
|
3548
|
-
* @param k2Classifications @kusto/language-service-next bridge.net object
|
|
3549
|
-
*/
|
|
3550
|
-
function toClassifiedRange(k2Classifications) {
|
|
3551
|
-
return k2Classifications.map(function (classification) {
|
|
3552
|
-
return {
|
|
3553
|
-
start: classification.Start,
|
|
3554
|
-
end: classification.End,
|
|
3555
|
-
length: classification.Length,
|
|
3556
|
-
kind: classification.Kind
|
|
3557
|
-
};
|
|
3558
|
-
});
|
|
3559
|
-
}
|
|
3560
|
-
|
|
3561
3549
|
/**
|
|
3562
3550
|
* colorization data for specific line range.
|
|
3563
3551
|
*/
|
|
@@ -3595,22 +3583,6 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
3595
3583
|
'3Dchart': k2.CompletionKind.RenderChart,
|
|
3596
3584
|
list: k2.CompletionKind.RenderChart
|
|
3597
3585
|
});
|
|
3598
|
-
_defineProperty(this, "disabledCompletionItemsV1", {
|
|
3599
|
-
capacity: k.OptionKind.Policy,
|
|
3600
|
-
callout: k.OptionKind.Policy,
|
|
3601
|
-
encoding: k.OptionKind.Policy,
|
|
3602
|
-
batching: k.OptionKind.Policy,
|
|
3603
|
-
querythrottling: k.OptionKind.Policy,
|
|
3604
|
-
merge: k.OptionKind.Policy,
|
|
3605
|
-
querylimit: k.OptionKind.Policy,
|
|
3606
|
-
rowstore: k.OptionKind.Policy,
|
|
3607
|
-
streamingingestion: k.OptionKind.Policy,
|
|
3608
|
-
restricted_view_access: k.OptionKind.Policy,
|
|
3609
|
-
sharding: k.OptionKind.Policy,
|
|
3610
|
-
'restricted-viewers': k.OptionKind.Policy,
|
|
3611
|
-
attach: k.OptionKind.Command,
|
|
3612
|
-
purge: k.OptionKind.Command
|
|
3613
|
-
});
|
|
3614
3586
|
_defineProperty(this, "_kustoKindtolsKind", (_defineProperty3 = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty3, k.OptionKind.None, main.CompletionItemKind.Interface), k.OptionKind.Operator, main.CompletionItemKind.Method), k.OptionKind.Command, main.CompletionItemKind.Method), k.OptionKind.Service, main.CompletionItemKind.Class), k.OptionKind.Policy, main.CompletionItemKind.Reference), k.OptionKind.Database, main.CompletionItemKind.Class), k.OptionKind.Table, main.CompletionItemKind.Class), k.OptionKind.DataType, main.CompletionItemKind.Class), k.OptionKind.Literal, main.CompletionItemKind.Property), k.OptionKind.Parameter, main.CompletionItemKind.Variable), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty3, k.OptionKind.IngestionMapping, main.CompletionItemKind.Variable), k.OptionKind.ExpressionFunction, main.CompletionItemKind.Variable), k.OptionKind.Option, main.CompletionItemKind.Interface), k.OptionKind.OptionKind, main.CompletionItemKind.Interface), k.OptionKind.OptionRender, main.CompletionItemKind.Interface), k.OptionKind.Column, main.CompletionItemKind.Function), k.OptionKind.ColumnString, main.CompletionItemKind.Field), k.OptionKind.ColumnNumeric, main.CompletionItemKind.Field), k.OptionKind.ColumnDateTime, main.CompletionItemKind.Field), k.OptionKind.ColumnTimespan, main.CompletionItemKind.Field), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty3, k.OptionKind.FunctionServerSide, main.CompletionItemKind.Field), k.OptionKind.FunctionAggregation, main.CompletionItemKind.Field), k.OptionKind.FunctionFilter, main.CompletionItemKind.Field), k.OptionKind.FunctionScalar, main.CompletionItemKind.Field), k.OptionKind.ClientDirective, main.CompletionItemKind.Enum)));
|
|
3615
3587
|
_defineProperty(this, "_kustoKindToLsKindV2", (_defineProperty4 = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty4, k2.CompletionKind.AggregateFunction, main.CompletionItemKind.Field), k2.CompletionKind.BuiltInFunction, main.CompletionItemKind.Field), k2.CompletionKind.Cluster, main.CompletionItemKind.Class), k2.CompletionKind.Column, main.CompletionItemKind.Function), k2.CompletionKind.CommandPrefix, main.CompletionItemKind.Field), k2.CompletionKind.Database, main.CompletionItemKind.Class), k2.CompletionKind.DatabaseFunction, main.CompletionItemKind.Field), k2.CompletionKind.Example, main.CompletionItemKind.Text), k2.CompletionKind.Identifier, main.CompletionItemKind.Method), k2.CompletionKind.Keyword, main.CompletionItemKind.Method), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty4, k2.CompletionKind.LocalFunction, main.CompletionItemKind.Field), k2.CompletionKind.MaterialiedView, main.CompletionItemKind.Class), k2.CompletionKind.Parameter, main.CompletionItemKind.Variable), k2.CompletionKind.Punctuation, main.CompletionItemKind.Interface), k2.CompletionKind.QueryPrefix, main.CompletionItemKind.Function), k2.CompletionKind.RenderChart, main.CompletionItemKind.Method), k2.CompletionKind.ScalarInfix, main.CompletionItemKind.Field), k2.CompletionKind.ScalarPrefix, main.CompletionItemKind.Field), k2.CompletionKind.ScalarType, main.CompletionItemKind.TypeParameter), k2.CompletionKind.Syntax, main.CompletionItemKind.Method), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty4, k2.CompletionKind.Table, main.CompletionItemKind.Class), k2.CompletionKind.TabularPrefix, main.CompletionItemKind.Field), k2.CompletionKind.TabularSuffix, main.CompletionItemKind.Field), k2.CompletionKind.Unknown, main.CompletionItemKind.Interface), k2.CompletionKind.Variable, main.CompletionItemKind.Variable), k2.CompletionKind.Option, main.CompletionItemKind.Text), k2.CompletionKind.Graph, main.CompletionItemKind.Class), k2.CompletionKind.EntityGroup, main.CompletionItemKind.Class)));
|
|
3616
3588
|
_defineProperty(this, "_tokenKindToClassificationKind", (_defineProperty5 = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty5, TokenKind.TableToken, k2.ClassificationKind.Table), TokenKind.TableColumnToken, k2.ClassificationKind.Column), TokenKind.OperatorToken, k2.ClassificationKind.QueryOperator), TokenKind.SubOperatorToken, k2.ClassificationKind.Function), TokenKind.CalculatedColumnToken, k2.ClassificationKind.Column), TokenKind.StringLiteralToken, k2.ClassificationKind.Literal), TokenKind.FunctionNameToken, k2.ClassificationKind.Function), TokenKind.UnknownToken, k2.ClassificationKind.PlainText), TokenKind.CommentToken, k2.ClassificationKind.Comment), TokenKind.PlainTextToken, k2.ClassificationKind.PlainText), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty5, TokenKind.DataTypeToken, k2.ClassificationKind.Type), TokenKind.ControlCommandToken, k2.ClassificationKind.PlainText), TokenKind.CommandPartToken, k2.ClassificationKind.PlainText), TokenKind.QueryParametersToken, k2.ClassificationKind.QueryParameter), TokenKind.CslCommandToken, k2.ClassificationKind.Keyword), TokenKind.LetVariablesToken, k2.ClassificationKind.Identifier), TokenKind.PluginToken, k2.ClassificationKind.Function), TokenKind.BracketRangeToken, k2.ClassificationKind.Keyword), TokenKind.ClientDirectiveToken, k2.ClassificationKind.Keyword)));
|
|
@@ -4072,52 +4044,48 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
4072
4044
|
return main.Diagnostic.create(range, diag.Message, severity, diag.Code);
|
|
4073
4045
|
});
|
|
4074
4046
|
}
|
|
4075
|
-
|
|
4076
|
-
/**
|
|
4077
|
-
* Colorize one or more kusto blocks (a.k.a commands), or just the entire document.
|
|
4078
|
-
* Supports multi-cursor editing (colorizes blocks on multiple changes).
|
|
4079
|
-
* @param document The document to colorize
|
|
4080
|
-
* @param changeIntervals an array containing 0 or more changed intervals. if the array is empty - just colorize the entire row.
|
|
4081
|
-
* if the array contains a single change - just color the kusto blocks that wraps this change. If multiple changes are provided,
|
|
4082
|
-
* colorize all blocks that intersect these changes.
|
|
4083
|
-
* The code will try to only parse once if this is the same command.
|
|
4084
|
-
*/
|
|
4085
4047
|
}, {
|
|
4086
|
-
key: "
|
|
4087
|
-
value: function
|
|
4088
|
-
var
|
|
4089
|
-
|
|
4090
|
-
|
|
4091
|
-
|
|
4092
|
-
|
|
4093
|
-
|
|
4094
|
-
|
|
4095
|
-
|
|
4096
|
-
|
|
4097
|
-
|
|
4098
|
-
|
|
4099
|
-
|
|
4100
|
-
|
|
4101
|
-
|
|
4102
|
-
|
|
4103
|
-
|
|
4104
|
-
|
|
4105
|
-
|
|
4048
|
+
key: "getClassifications",
|
|
4049
|
+
value: function () {
|
|
4050
|
+
var _getClassifications = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(document) {
|
|
4051
|
+
var _this4 = this;
|
|
4052
|
+
var codeScript, codeBlocks, classificationRanges;
|
|
4053
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
4054
|
+
while (1) switch (_context.prev = _context.next) {
|
|
4055
|
+
case 0:
|
|
4056
|
+
codeScript = this.parseDocumentV2(document);
|
|
4057
|
+
codeBlocks = this.toArray(codeScript.Blocks);
|
|
4058
|
+
classificationRanges = codeBlocks.map(function (block) {
|
|
4059
|
+
var _block$Service$GetCla = block.Service.GetClassifications(block.Start, block.Length),
|
|
4060
|
+
Classifications = _block$Service$GetCla.Classifications;
|
|
4061
|
+
return _this4.toArray(Classifications);
|
|
4062
|
+
});
|
|
4063
|
+
return _context.abrupt("return", classificationRanges.flatMap(function (ranges) {
|
|
4064
|
+
return ranges.map(function (range) {
|
|
4065
|
+
var _document$positionAt = document.positionAt(range.Start),
|
|
4066
|
+
line = _document$positionAt.line,
|
|
4067
|
+
character = _document$positionAt.character;
|
|
4068
|
+
var length = range.Length;
|
|
4069
|
+
var kind = range.Kind;
|
|
4070
|
+
return {
|
|
4071
|
+
line: line,
|
|
4072
|
+
character: character,
|
|
4073
|
+
length: length,
|
|
4074
|
+
kind: kind
|
|
4075
|
+
};
|
|
4076
|
+
});
|
|
4077
|
+
}));
|
|
4078
|
+
case 4:
|
|
4079
|
+
case "end":
|
|
4080
|
+
return _context.stop();
|
|
4081
|
+
}
|
|
4082
|
+
}, _callee, this);
|
|
4083
|
+
}));
|
|
4084
|
+
function getClassifications(_x) {
|
|
4085
|
+
return _getClassifications.apply(this, arguments);
|
|
4106
4086
|
}
|
|
4107
|
-
|
|
4108
|
-
|
|
4109
|
-
var blocks = this.toArray(script.Blocks);
|
|
4110
|
-
var classifications = blocks.map(function (block) {
|
|
4111
|
-
return _this4.toArray(block.Service.GetClassifications(block.Start, block.Length).Classifications);
|
|
4112
|
-
}).reduce(function (prev, curr) {
|
|
4113
|
-
return prev.concat(curr);
|
|
4114
|
-
}, []);
|
|
4115
|
-
return Promise.resolve([{
|
|
4116
|
-
classifications: toClassifiedRange(classifications),
|
|
4117
|
-
absoluteStart: 0,
|
|
4118
|
-
absoluteEnd: document.getText().length
|
|
4119
|
-
}]);
|
|
4120
|
-
}
|
|
4087
|
+
return getClassifications;
|
|
4088
|
+
}()
|
|
4121
4089
|
}, {
|
|
4122
4090
|
key: "getAffectedBlocks",
|
|
4123
4091
|
value: function getAffectedBlocks(blocks, changeIntervals) {
|
|
@@ -5023,8 +4991,7 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
5023
4991
|
}, {
|
|
5024
4992
|
key: "getCurrentCommandV2",
|
|
5025
4993
|
value: function getCurrentCommandV2(script, offset) {
|
|
5026
|
-
|
|
5027
|
-
return block;
|
|
4994
|
+
return script.GetBlockAtPosition(offset);
|
|
5028
4995
|
}
|
|
5029
4996
|
}, {
|
|
5030
4997
|
key: "getTextToInsert",
|
|
@@ -5383,7 +5350,6 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
5383
5350
|
}();
|
|
5384
5351
|
var languageService = new KustoLanguageService(KustoLanguageService.dummySchema, {
|
|
5385
5352
|
includeControlCommands: true,
|
|
5386
|
-
useSemanticColorization: true,
|
|
5387
5353
|
completionOptions: {
|
|
5388
5354
|
includeExtendedSyntax: false
|
|
5389
5355
|
}
|
|
@@ -5413,8 +5379,6 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
5413
5379
|
*/
|
|
5414
5380
|
|
|
5415
5381
|
var KustoWorkerImpl = /*#__PURE__*/function () {
|
|
5416
|
-
// --- model sync -----------------------
|
|
5417
|
-
|
|
5418
5382
|
function KustoWorkerImpl(ctx, createData) {
|
|
5419
5383
|
_classCallCheck(this, KustoWorkerImpl);
|
|
5420
5384
|
this._ctx = ctx;
|
|
@@ -5422,8 +5386,6 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
5422
5386
|
this._languageService = getKustoLanguageService();
|
|
5423
5387
|
this._languageService.configure(this._languageSettings);
|
|
5424
5388
|
}
|
|
5425
|
-
|
|
5426
|
-
// --- language service host ---------------
|
|
5427
5389
|
return _createClass(KustoWorkerImpl, [{
|
|
5428
5390
|
key: "setSchema",
|
|
5429
5391
|
value: function setSchema(schema) {
|
|
@@ -5645,14 +5607,11 @@ define('vs/language/kusto/kustoWorker', ['exports', './main-1587ba64', './schema
|
|
|
5645
5607
|
var formatted = this._languageService.doCurrentCommandFormat(document, caretPosition);
|
|
5646
5608
|
return formatted;
|
|
5647
5609
|
}
|
|
5648
|
-
|
|
5649
|
-
// Colorize document. if offsets provided, will only colorize commands at these offsets. otherwise - will color the entire document.
|
|
5650
5610
|
}, {
|
|
5651
|
-
key: "
|
|
5652
|
-
value: function
|
|
5611
|
+
key: "getClassifications",
|
|
5612
|
+
value: function getClassifications(uri) {
|
|
5653
5613
|
var document = this._getTextDocument(uri);
|
|
5654
|
-
|
|
5655
|
-
return colorizationInfo;
|
|
5614
|
+
return this._languageService.getClassifications(document);
|
|
5656
5615
|
}
|
|
5657
5616
|
}, {
|
|
5658
5617
|
key: "getClientDirective",
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!-----------------------------------------------------------------------------
|
|
2
2
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
-
* monaco-kusto version:
|
|
3
|
+
* monaco-kusto version: 12.0.1(56b90ce0fd31e7d6792f5098d1e8204274966b6e)
|
|
4
4
|
* Released under the MIT license
|
|
5
5
|
* https://https://github.com/Azure/monaco-kusto/blob/master/README.md
|
|
6
6
|
*-----------------------------------------------------------------------------*/
|
|
7
7
|
|
|
8
|
-
define('vs/language/kusto/main-
|
|
8
|
+
define('vs/language/kusto/main-f36cb42f', ['exports'], (function (exports) { 'use strict';
|
|
9
9
|
|
|
10
10
|
/* --------------------------------------------------------------------------------------------
|
|
11
11
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|