@infinilabs/discover 0.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/LICENSE +9 -0
- package/README.md +8 -0
- package/dist/abap-B988NUrV.js +122 -0
- package/dist/abap-obercqiY.cjs +1 -0
- package/dist/apex-B0_UGK1B.cjs +1 -0
- package/dist/apex-BlHPPQK-.js +168 -0
- package/dist/azcli-C7iyZFGk.js +53 -0
- package/dist/azcli-CEoytwx_.cjs +1 -0
- package/dist/bat-Buc0l0C3.js +123 -0
- package/dist/bat-D65OC-jj.cjs +1 -0
- package/dist/bicep-DvD_e5vW.cjs +2 -0
- package/dist/bicep-U66iJ-pV.js +219 -0
- package/dist/cameligo-C9Dwkdmm.js +189 -0
- package/dist/cameligo-DzMHfeEs.cjs +1 -0
- package/dist/chunk-BjqF3vbe.cjs +1 -0
- package/dist/chunk-CIp4IH9D.js +21 -0
- package/dist/classnames-BXjDNQ6Q.cjs +1 -0
- package/dist/classnames-eUba3oot.js +29 -0
- package/dist/clojure-BC7BzAFK.cjs +1 -0
- package/dist/clojure-DDWmWbSx.js +146 -0
- package/dist/coffee-7Sx2S8NH.js +260 -0
- package/dist/coffee-Ca9F0OWZ.cjs +1 -0
- package/dist/common-BeXEy5sz.cjs +18 -0
- package/dist/common-BlOHZJzI.js +64 -0
- package/dist/common-DuYIpe6b.cjs +1 -0
- package/dist/common-Tr1I-HCs.js +6725 -0
- package/dist/cpp-CHjqaSPQ.js +230 -0
- package/dist/cpp-DKy9h6xR.cjs +1 -0
- package/dist/createLucideIcon-239Z-2by.cjs +1 -0
- package/dist/createLucideIcon-BO6TDGE7.js +43 -0
- package/dist/csharp-CkbgT9vH.cjs +1 -0
- package/dist/csharp-jwStnVeK.js +260 -0
- package/dist/csp-C2qFd6iv.cjs +1 -0
- package/dist/csp-DkO8Np0h.js +46 -0
- package/dist/css-BFvwcljm.js +284 -0
- package/dist/css-DCKUCzD6.cjs +3 -0
- package/dist/cssMode-CU2AJQMM.js +1509 -0
- package/dist/cssMode-l7eR8WSG.cjs +4 -0
- package/dist/cypher-122TYSjJ.cjs +1 -0
- package/dist/cypher-DaQ7hFRL.js +212 -0
- package/dist/dart-D8p_2HKP.js +236 -0
- package/dist/dart-DshcPGU8.cjs +1 -0
- package/dist/dist-DCz_Qv0B.js +884 -0
- package/dist/dist-D_2dZQH5.cjs +11 -0
- package/dist/dockerfile-CL8dwZCe.cjs +1 -0
- package/dist/dockerfile-DKWOQrwp.js +191 -0
- package/dist/ecl-DP3PNWGB.js +226 -0
- package/dist/ecl-DVx2J_EE.cjs +1 -0
- package/dist/editor.api-CbUDOph7.js +70302 -0
- package/dist/editor.api-lY2thcaq.cjs +644 -0
- package/dist/elixir-Xgx_1krO.cjs +1 -0
- package/dist/elixir-e9tDp1p1.js +523 -0
- package/dist/filter_label-DRJC3vpe.js +58 -0
- package/dist/filter_label-DssaWGpx.cjs +1 -0
- package/dist/filter_operators-C-TaTcNc.js +70 -0
- package/dist/filter_operators-D0kyB-XI.cjs +1 -0
- package/dist/flow9-C9BjpX8h.js +176 -0
- package/dist/flow9-DR-EyjYV.cjs +1 -0
- package/dist/freemarker2-BTGUjvgA.cjs +3 -0
- package/dist/freemarker2-C6Iq5MB-.js +724 -0
- package/dist/fsharp-BWm_FISn.js +147 -0
- package/dist/fsharp-DaBEigN7.cjs +1 -0
- package/dist/go-Xyq33f0v.cjs +1 -0
- package/dist/go-cmqV0Vy_.js +165 -0
- package/dist/graphql-BkFHHVmI.js +174 -0
- package/dist/graphql-Cj7XAy25.cjs +1 -0
- package/dist/handlebars-B2b1q7PA.cjs +1 -0
- package/dist/handlebars-DGGN9u4Y.js +418 -0
- package/dist/hcl-5I-P7bYX.js +219 -0
- package/dist/hcl-C3dpBsgU.cjs +1 -0
- package/dist/html-RJa-j-qT.js +339 -0
- package/dist/html-qfcUzk8e.cjs +1 -0
- package/dist/htmlMode-CYIxo4hc.cjs +4 -0
- package/dist/htmlMode-DDZ48mdp.js +1520 -0
- package/dist/index.cjs +303 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +72895 -0
- package/dist/index_pattern_select--iGeA3sP.js +93 -0
- package/dist/index_pattern_select-BeN5049F.cjs +1 -0
- package/dist/ini-ChENqKh8.cjs +1 -0
- package/dist/ini-DSIAxBZt.js +94 -0
- package/dist/java-DGeAxsRb.js +173 -0
- package/dist/java-LZ6g7weJ.cjs +1 -0
- package/dist/javascript-CN5gTHH2.js +19 -0
- package/dist/javascript-CZ97a-BN.cjs +1 -0
- package/dist/jsonMode-BZDeJMLL.cjs +10 -0
- package/dist/jsonMode-DraOl-ka.js +1885 -0
- package/dist/julia-BeebccKw.cjs +1 -0
- package/dist/julia-CU4CtsP4.js +414 -0
- package/dist/kotlin-B8NxXJ89.js +183 -0
- package/dist/kotlin-M82nl514.cjs +1 -0
- package/dist/less-B4Q3fV9Y.cjs +2 -0
- package/dist/less-DbeQQzer.js +242 -0
- package/dist/lexon-CXQaaecE.cjs +1 -0
- package/dist/lexon-Cw9JuAKc.js +185 -0
- package/dist/lib-C9j_E-l0.js +47 -0
- package/dist/lib-Chy_6VKj.cjs +1 -0
- package/dist/liquid-BYNEOJvX.cjs +1 -0
- package/dist/liquid-DvB-d2w7.js +205 -0
- package/dist/lodash-C_2NO1eK.cjs +35 -0
- package/dist/lodash-D-qGlPRW.js +3769 -0
- package/dist/lua-CnG8Tpu2.cjs +1 -0
- package/dist/lua-yl5NzA_S.js +200 -0
- package/dist/m3-CVcm-OIn.cjs +1 -0
- package/dist/m3-CdNAqvIX.js +193 -0
- package/dist/markdown-C1h-EuiT.js +262 -0
- package/dist/markdown-DrRHDVSU.cjs +1 -0
- package/dist/mdx-BbiOYPr2.cjs +1 -0
- package/dist/mdx-Fk8VTCUK.js +335 -0
- package/dist/mips-DIWpzGF0.js +128 -0
- package/dist/mips-D_p8UYQb.cjs +1 -0
- package/dist/monaco.contribution-BpuUCejv.cjs +1 -0
- package/dist/monaco.contribution-Cq4QrMn0.js +134 -0
- package/dist/msdax-BiazpDQ1.js +156 -0
- package/dist/msdax-xM1_j20x.cjs +1 -0
- package/dist/mysql-DMsJkSnA.cjs +1 -0
- package/dist/mysql-DphBFJlP.js +168 -0
- package/dist/objective-c-BG02Lrht.cjs +1 -0
- package/dist/objective-c-DWZ8Qpyc.js +144 -0
- package/dist/pascal-BcvlMOdu.js +176 -0
- package/dist/pascal-CnP2Fqes.cjs +1 -0
- package/dist/pascaligo-BzDEm-l_.cjs +1 -0
- package/dist/pascaligo-DHEp4kzh.js +201 -0
- package/dist/perl-USYKPHpO.js +316 -0
- package/dist/perl-nIxw-e4R.cjs +1 -0
- package/dist/pgsql-Buk6XzVf.cjs +1 -0
- package/dist/pgsql-DzPhAh9W.js +158 -0
- package/dist/php-B3sFYUqV.cjs +1 -0
- package/dist/php-PfpSTefE.js +471 -0
- package/dist/pla-CZtnfWl6.cjs +1 -0
- package/dist/pla-DrFOZwDB.js +146 -0
- package/dist/postiats-4OGxVVUT.js +504 -0
- package/dist/postiats-CgJZf83Q.cjs +1 -0
- package/dist/powerquery-D9gzk2Dq.cjs +1 -0
- package/dist/powerquery-_h9-HEnY.js +190 -0
- package/dist/powershell-CZHaQY6z.cjs +1 -0
- package/dist/powershell-nOzcY8gy.js +211 -0
- package/dist/protobuf-DAgxhnea.js +659 -0
- package/dist/protobuf-D_C8Guej.cjs +2 -0
- package/dist/public-1PveQco4.js +1756 -0
- package/dist/public-D1K7oN7t.cjs +3 -0
- package/dist/pug-quEtG4rz.cjs +1 -0
- package/dist/pug-raGZNmZ1.js +300 -0
- package/dist/python-C45c7K7W.js +260 -0
- package/dist/python-CQX8JcT4.cjs +1 -0
- package/dist/qsharp-C2jz5tuo.js +143 -0
- package/dist/qsharp-CX1SSV_j.cjs +1 -0
- package/dist/query_bar_top_row-3UclS1nm.cjs +1 -0
- package/dist/query_bar_top_row-CfV4Iu71.cjs +1 -0
- package/dist/query_bar_top_row-D6a48VTk.js +11 -0
- package/dist/query_bar_top_row-DonV1OzY.js +2930 -0
- package/dist/query_string_input-75waAcWy.js +9 -0
- package/dist/query_string_input-CHG9w1ze.cjs +1 -0
- package/dist/query_string_input-CyPZVKif.js +366 -0
- package/dist/query_string_input-SOULY6dl.cjs +1 -0
- package/dist/r-CXkPcYYf.js +189 -0
- package/dist/r-DpVDQTST.cjs +1 -0
- package/dist/razor-BnoJmj1k.js +525 -0
- package/dist/razor-DYx4yJJn.cjs +1 -0
- package/dist/redis-DsCuCZIT.cjs +1 -0
- package/dist/redis-giKZvbbg.js +123 -0
- package/dist/redshift-qKVxBsP_.js +158 -0
- package/dist/redshift-z5_aUfdC.cjs +1 -0
- package/dist/restructuredtext-D0n4pabr.js +287 -0
- package/dist/restructuredtext-DdXoKocW.cjs +1 -0
- package/dist/ruby-BNrBlpcw.js +527 -0
- package/dist/ruby-Dj0sNBey.cjs +1 -0
- package/dist/rust-D6mpPoli.js +178 -0
- package/dist/rust-DjkW1U4M.cjs +1 -0
- package/dist/sb-BCN0JcpS.cjs +1 -0
- package/dist/sb-DhS9GhXl.js +143 -0
- package/dist/scala-BqxBEpi8.js +551 -0
- package/dist/scala-CyXWhZaJ.cjs +1 -0
- package/dist/scheme-Bh4oGAk3.js +170 -0
- package/dist/scheme-Cs9G6QEE.cjs +1 -0
- package/dist/scss-Byf08jwC.js +417 -0
- package/dist/scss-Fl7taPuq.cjs +3 -0
- package/dist/search_bar-Caqi1NVo.js +1815 -0
- package/dist/search_bar-DyO_WsC5.cjs +1 -0
- package/dist/services-9wPHk1eh.js +2350 -0
- package/dist/services-BPC3fXx4.cjs +7 -0
- package/dist/shard_failure_open_modal_button-BYTThYch.js +199 -0
- package/dist/shard_failure_open_modal_button-Dx8ML4VE.cjs +2 -0
- package/dist/shell-Cw5yNfC4.cjs +1 -0
- package/dist/shell-UoRv_tpG.js +223 -0
- package/dist/solidity-B5t7Lkol.js +147 -0
- package/dist/solidity-BoAzg9X_.cjs +1 -0
- package/dist/sophia-BrXXWhvp.js +147 -0
- package/dist/sophia-L84Jz6Ow.cjs +1 -0
- package/dist/sparql-B8ZTY48u.js +124 -0
- package/dist/sparql-D6lnG7vO.cjs +1 -0
- package/dist/sql-D_74hUL-.js +171 -0
- package/dist/sql-VXdYzIyz.cjs +1 -0
- package/dist/src/App.d.ts +2 -0
- package/dist/src/components/ResultHeader/Info.d.ts +30 -0
- package/dist/src/components/ResultHeader/index.d.ts +13 -0
- package/dist/src/components/context.d.ts +82 -0
- package/dist/src/components/euiicons.d.ts +1 -0
- package/dist/src/components/index.d.ts +8 -0
- package/dist/src/main.d.ts +1 -0
- package/dist/src/utils/request.d.ts +1 -0
- package/dist/src/utils/utils.d.ts +1 -0
- package/dist/st-CxJLwAAK.cjs +1 -0
- package/dist/st-D8Rdx9Bz.js +476 -0
- package/dist/suggestions_component-BBHwbjYT.js +1243 -0
- package/dist/suggestions_component-CF4sehth.cjs +77 -0
- package/dist/swift-ZBC6wQdc.cjs +1 -0
- package/dist/swift-s19Ivx3X.js +213 -0
- package/dist/systemverilog-DoSgAb1I.cjs +1 -0
- package/dist/systemverilog-fA72PnKj.js +298 -0
- package/dist/tcl-B8QLbcxi.js +223 -0
- package/dist/tcl-IXmy-lJ0.cjs +1 -0
- package/dist/tsMode-BrPRpJvb.js +597 -0
- package/dist/tsMode-CNvH6xuC.cjs +11 -0
- package/dist/tsup.config.d.ts +2 -0
- package/dist/twig-CT2RXmm0.cjs +1 -0
- package/dist/twig-Dy7NkzKI.js +388 -0
- package/dist/typescript-BRKHcp4S.js +263 -0
- package/dist/typescript-Bbw9fxuo.cjs +1 -0
- package/dist/typescript-CQjO9XnF.js +3 -0
- package/dist/typescript-D6q4AO2z.cjs +1 -0
- package/dist/typespec-CkKpvaMv.cjs +1 -0
- package/dist/typespec-ndyv0mQx.js +234 -0
- package/dist/vb-DET0NIW-.js +260 -0
- package/dist/vb-R3Kcrzvd.cjs +1 -0
- package/dist/vite.config.d.ts +2 -0
- package/dist/wgsl-D5TeQchR.js +145 -0
- package/dist/wgsl-FTDBzylH.cjs +298 -0
- package/dist/xml-BZjE3dtf.js +136 -0
- package/dist/xml-CxbMIueA.cjs +1 -0
- package/dist/yaml-Di_6aXC4.js +229 -0
- package/dist/yaml-DvaGkWBl.cjs +1 -0
- package/package.json +98 -0
|
@@ -0,0 +1,1520 @@
|
|
|
1
|
+
import { m as editor_api_exports } from "./editor.api-CbUDOph7.js";
|
|
2
|
+
var __defProp = Object.defineProperty, __getOwnPropDesc = Object.getOwnPropertyDescriptor, __getOwnPropNames = Object.getOwnPropertyNames, __hasOwnProp = Object.prototype.hasOwnProperty, __copyProps = (p, K, q, J) => {
|
|
3
|
+
if (K && typeof K == "object" || typeof K == "function") for (let Y of __getOwnPropNames(K)) !__hasOwnProp.call(p, Y) && Y !== q && __defProp(p, Y, {
|
|
4
|
+
get: () => K[Y],
|
|
5
|
+
enumerable: !(J = __getOwnPropDesc(K, Y)) || J.enumerable
|
|
6
|
+
});
|
|
7
|
+
return p;
|
|
8
|
+
}, __reExport = (p, H, U) => (__copyProps(p, H, "default"), U && __copyProps(U, H, "default")), monaco_editor_core_exports = {};
|
|
9
|
+
__reExport(monaco_editor_core_exports, editor_api_exports);
|
|
10
|
+
var STOP_WHEN_IDLE_FOR = 120 * 1e3, WorkerManager = class {
|
|
11
|
+
constructor(p) {
|
|
12
|
+
this._defaults = p, this._worker = null, this._client = null, this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 30 * 1e3), this._lastUsedTime = 0, this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
|
|
13
|
+
}
|
|
14
|
+
_stopWorker() {
|
|
15
|
+
this._worker &&= (this._worker.dispose(), null), this._client = null;
|
|
16
|
+
}
|
|
17
|
+
dispose() {
|
|
18
|
+
clearInterval(this._idleCheckInterval), this._configChangeListener.dispose(), this._stopWorker();
|
|
19
|
+
}
|
|
20
|
+
_checkIfIdle() {
|
|
21
|
+
this._worker && Date.now() - this._lastUsedTime > STOP_WHEN_IDLE_FOR && this._stopWorker();
|
|
22
|
+
}
|
|
23
|
+
_getClient() {
|
|
24
|
+
return this._lastUsedTime = Date.now(), this._client ||= (this._worker = monaco_editor_core_exports.editor.createWebWorker({
|
|
25
|
+
moduleId: "vs/language/html/htmlWorker",
|
|
26
|
+
createData: {
|
|
27
|
+
languageSettings: this._defaults.options,
|
|
28
|
+
languageId: this._defaults.languageId
|
|
29
|
+
},
|
|
30
|
+
label: this._defaults.languageId
|
|
31
|
+
}), this._worker.getProxy()), this._client;
|
|
32
|
+
}
|
|
33
|
+
getLanguageServiceWorker(...p) {
|
|
34
|
+
let H;
|
|
35
|
+
return this._getClient().then((p) => {
|
|
36
|
+
H = p;
|
|
37
|
+
}).then((H) => {
|
|
38
|
+
if (this._worker) return this._worker.withSyncedResources(p);
|
|
39
|
+
}).then((p) => H);
|
|
40
|
+
}
|
|
41
|
+
}, DocumentUri;
|
|
42
|
+
(function(p) {
|
|
43
|
+
function H(p) {
|
|
44
|
+
return typeof p == "string";
|
|
45
|
+
}
|
|
46
|
+
p.is = H;
|
|
47
|
+
})(DocumentUri ||= {});
|
|
48
|
+
var URI;
|
|
49
|
+
(function(p) {
|
|
50
|
+
function H(p) {
|
|
51
|
+
return typeof p == "string";
|
|
52
|
+
}
|
|
53
|
+
p.is = H;
|
|
54
|
+
})(URI ||= {});
|
|
55
|
+
var integer;
|
|
56
|
+
(function(p) {
|
|
57
|
+
p.MIN_VALUE = -2147483648, p.MAX_VALUE = 2147483647;
|
|
58
|
+
function H(H) {
|
|
59
|
+
return typeof H == "number" && p.MIN_VALUE <= H && H <= p.MAX_VALUE;
|
|
60
|
+
}
|
|
61
|
+
p.is = H;
|
|
62
|
+
})(integer ||= {});
|
|
63
|
+
var uinteger;
|
|
64
|
+
(function(p) {
|
|
65
|
+
p.MIN_VALUE = 0, p.MAX_VALUE = 2147483647;
|
|
66
|
+
function H(H) {
|
|
67
|
+
return typeof H == "number" && p.MIN_VALUE <= H && H <= p.MAX_VALUE;
|
|
68
|
+
}
|
|
69
|
+
p.is = H;
|
|
70
|
+
})(uinteger ||= {});
|
|
71
|
+
var Position;
|
|
72
|
+
(function(p) {
|
|
73
|
+
function H(p, H) {
|
|
74
|
+
return p === Number.MAX_VALUE && (p = uinteger.MAX_VALUE), H === Number.MAX_VALUE && (H = uinteger.MAX_VALUE), {
|
|
75
|
+
line: p,
|
|
76
|
+
character: H
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
p.create = H;
|
|
80
|
+
function U(p) {
|
|
81
|
+
let H = p;
|
|
82
|
+
return Is.objectLiteral(H) && Is.uinteger(H.line) && Is.uinteger(H.character);
|
|
83
|
+
}
|
|
84
|
+
p.is = U;
|
|
85
|
+
})(Position ||= {});
|
|
86
|
+
var Range;
|
|
87
|
+
(function(p) {
|
|
88
|
+
function H(p, H, U, W) {
|
|
89
|
+
if (Is.uinteger(p) && Is.uinteger(H) && Is.uinteger(U) && Is.uinteger(W)) return {
|
|
90
|
+
start: Position.create(p, H),
|
|
91
|
+
end: Position.create(U, W)
|
|
92
|
+
};
|
|
93
|
+
if (Position.is(p) && Position.is(H)) return {
|
|
94
|
+
start: p,
|
|
95
|
+
end: H
|
|
96
|
+
};
|
|
97
|
+
throw Error(`Range#create called with invalid arguments[${p}, ${H}, ${U}, ${W}]`);
|
|
98
|
+
}
|
|
99
|
+
p.create = H;
|
|
100
|
+
function U(p) {
|
|
101
|
+
let H = p;
|
|
102
|
+
return Is.objectLiteral(H) && Position.is(H.start) && Position.is(H.end);
|
|
103
|
+
}
|
|
104
|
+
p.is = U;
|
|
105
|
+
})(Range ||= {});
|
|
106
|
+
var Location;
|
|
107
|
+
(function(p) {
|
|
108
|
+
function H(p, H) {
|
|
109
|
+
return {
|
|
110
|
+
uri: p,
|
|
111
|
+
range: H
|
|
112
|
+
};
|
|
113
|
+
}
|
|
114
|
+
p.create = H;
|
|
115
|
+
function U(p) {
|
|
116
|
+
let H = p;
|
|
117
|
+
return Is.objectLiteral(H) && Range.is(H.range) && (Is.string(H.uri) || Is.undefined(H.uri));
|
|
118
|
+
}
|
|
119
|
+
p.is = U;
|
|
120
|
+
})(Location ||= {});
|
|
121
|
+
var LocationLink;
|
|
122
|
+
(function(p) {
|
|
123
|
+
function H(p, H, U, W) {
|
|
124
|
+
return {
|
|
125
|
+
targetUri: p,
|
|
126
|
+
targetRange: H,
|
|
127
|
+
targetSelectionRange: U,
|
|
128
|
+
originSelectionRange: W
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
p.create = H;
|
|
132
|
+
function U(p) {
|
|
133
|
+
let H = p;
|
|
134
|
+
return Is.objectLiteral(H) && Range.is(H.targetRange) && Is.string(H.targetUri) && Range.is(H.targetSelectionRange) && (Range.is(H.originSelectionRange) || Is.undefined(H.originSelectionRange));
|
|
135
|
+
}
|
|
136
|
+
p.is = U;
|
|
137
|
+
})(LocationLink ||= {});
|
|
138
|
+
var Color;
|
|
139
|
+
(function(p) {
|
|
140
|
+
function H(p, H, U, W) {
|
|
141
|
+
return {
|
|
142
|
+
red: p,
|
|
143
|
+
green: H,
|
|
144
|
+
blue: U,
|
|
145
|
+
alpha: W
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
p.create = H;
|
|
149
|
+
function U(p) {
|
|
150
|
+
let H = p;
|
|
151
|
+
return Is.objectLiteral(H) && Is.numberRange(H.red, 0, 1) && Is.numberRange(H.green, 0, 1) && Is.numberRange(H.blue, 0, 1) && Is.numberRange(H.alpha, 0, 1);
|
|
152
|
+
}
|
|
153
|
+
p.is = U;
|
|
154
|
+
})(Color ||= {});
|
|
155
|
+
var ColorInformation;
|
|
156
|
+
(function(p) {
|
|
157
|
+
function H(p, H) {
|
|
158
|
+
return {
|
|
159
|
+
range: p,
|
|
160
|
+
color: H
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
p.create = H;
|
|
164
|
+
function U(p) {
|
|
165
|
+
let H = p;
|
|
166
|
+
return Is.objectLiteral(H) && Range.is(H.range) && Color.is(H.color);
|
|
167
|
+
}
|
|
168
|
+
p.is = U;
|
|
169
|
+
})(ColorInformation ||= {});
|
|
170
|
+
var ColorPresentation;
|
|
171
|
+
(function(p) {
|
|
172
|
+
function H(p, H, U) {
|
|
173
|
+
return {
|
|
174
|
+
label: p,
|
|
175
|
+
textEdit: H,
|
|
176
|
+
additionalTextEdits: U
|
|
177
|
+
};
|
|
178
|
+
}
|
|
179
|
+
p.create = H;
|
|
180
|
+
function U(p) {
|
|
181
|
+
let H = p;
|
|
182
|
+
return Is.objectLiteral(H) && Is.string(H.label) && (Is.undefined(H.textEdit) || TextEdit.is(H)) && (Is.undefined(H.additionalTextEdits) || Is.typedArray(H.additionalTextEdits, TextEdit.is));
|
|
183
|
+
}
|
|
184
|
+
p.is = U;
|
|
185
|
+
})(ColorPresentation ||= {});
|
|
186
|
+
var FoldingRangeKind;
|
|
187
|
+
(function(p) {
|
|
188
|
+
p.Comment = "comment", p.Imports = "imports", p.Region = "region";
|
|
189
|
+
})(FoldingRangeKind ||= {});
|
|
190
|
+
var FoldingRange;
|
|
191
|
+
(function(p) {
|
|
192
|
+
function H(p, H, U, W, G, K) {
|
|
193
|
+
let q = {
|
|
194
|
+
startLine: p,
|
|
195
|
+
endLine: H
|
|
196
|
+
};
|
|
197
|
+
return Is.defined(U) && (q.startCharacter = U), Is.defined(W) && (q.endCharacter = W), Is.defined(G) && (q.kind = G), Is.defined(K) && (q.collapsedText = K), q;
|
|
198
|
+
}
|
|
199
|
+
p.create = H;
|
|
200
|
+
function U(p) {
|
|
201
|
+
let H = p;
|
|
202
|
+
return Is.objectLiteral(H) && Is.uinteger(H.startLine) && Is.uinteger(H.startLine) && (Is.undefined(H.startCharacter) || Is.uinteger(H.startCharacter)) && (Is.undefined(H.endCharacter) || Is.uinteger(H.endCharacter)) && (Is.undefined(H.kind) || Is.string(H.kind));
|
|
203
|
+
}
|
|
204
|
+
p.is = U;
|
|
205
|
+
})(FoldingRange ||= {});
|
|
206
|
+
var DiagnosticRelatedInformation;
|
|
207
|
+
(function(p) {
|
|
208
|
+
function H(p, H) {
|
|
209
|
+
return {
|
|
210
|
+
location: p,
|
|
211
|
+
message: H
|
|
212
|
+
};
|
|
213
|
+
}
|
|
214
|
+
p.create = H;
|
|
215
|
+
function U(p) {
|
|
216
|
+
let H = p;
|
|
217
|
+
return Is.defined(H) && Location.is(H.location) && Is.string(H.message);
|
|
218
|
+
}
|
|
219
|
+
p.is = U;
|
|
220
|
+
})(DiagnosticRelatedInformation ||= {});
|
|
221
|
+
var DiagnosticSeverity;
|
|
222
|
+
(function(p) {
|
|
223
|
+
p.Error = 1, p.Warning = 2, p.Information = 3, p.Hint = 4;
|
|
224
|
+
})(DiagnosticSeverity ||= {});
|
|
225
|
+
var DiagnosticTag;
|
|
226
|
+
(function(p) {
|
|
227
|
+
p.Unnecessary = 1, p.Deprecated = 2;
|
|
228
|
+
})(DiagnosticTag ||= {});
|
|
229
|
+
var CodeDescription;
|
|
230
|
+
(function(p) {
|
|
231
|
+
function H(p) {
|
|
232
|
+
let H = p;
|
|
233
|
+
return Is.objectLiteral(H) && Is.string(H.href);
|
|
234
|
+
}
|
|
235
|
+
p.is = H;
|
|
236
|
+
})(CodeDescription ||= {});
|
|
237
|
+
var Diagnostic;
|
|
238
|
+
(function(p) {
|
|
239
|
+
function H(p, H, U, W, G, K) {
|
|
240
|
+
let q = {
|
|
241
|
+
range: p,
|
|
242
|
+
message: H
|
|
243
|
+
};
|
|
244
|
+
return Is.defined(U) && (q.severity = U), Is.defined(W) && (q.code = W), Is.defined(G) && (q.source = G), Is.defined(K) && (q.relatedInformation = K), q;
|
|
245
|
+
}
|
|
246
|
+
p.create = H;
|
|
247
|
+
function U(p) {
|
|
248
|
+
let H = p;
|
|
249
|
+
return Is.defined(H) && Range.is(H.range) && Is.string(H.message) && (Is.number(H.severity) || Is.undefined(H.severity)) && (Is.integer(H.code) || Is.string(H.code) || Is.undefined(H.code)) && (Is.undefined(H.codeDescription) || Is.string(H.codeDescription?.href)) && (Is.string(H.source) || Is.undefined(H.source)) && (Is.undefined(H.relatedInformation) || Is.typedArray(H.relatedInformation, DiagnosticRelatedInformation.is));
|
|
250
|
+
}
|
|
251
|
+
p.is = U;
|
|
252
|
+
})(Diagnostic ||= {});
|
|
253
|
+
var Command;
|
|
254
|
+
(function(p) {
|
|
255
|
+
function H(p, H, ...U) {
|
|
256
|
+
let W = {
|
|
257
|
+
title: p,
|
|
258
|
+
command: H
|
|
259
|
+
};
|
|
260
|
+
return Is.defined(U) && U.length > 0 && (W.arguments = U), W;
|
|
261
|
+
}
|
|
262
|
+
p.create = H;
|
|
263
|
+
function U(p) {
|
|
264
|
+
let H = p;
|
|
265
|
+
return Is.defined(H) && Is.string(H.title) && Is.string(H.command);
|
|
266
|
+
}
|
|
267
|
+
p.is = U;
|
|
268
|
+
})(Command ||= {});
|
|
269
|
+
var TextEdit;
|
|
270
|
+
(function(p) {
|
|
271
|
+
function H(p, H) {
|
|
272
|
+
return {
|
|
273
|
+
range: p,
|
|
274
|
+
newText: H
|
|
275
|
+
};
|
|
276
|
+
}
|
|
277
|
+
p.replace = H;
|
|
278
|
+
function U(p, H) {
|
|
279
|
+
return {
|
|
280
|
+
range: {
|
|
281
|
+
start: p,
|
|
282
|
+
end: p
|
|
283
|
+
},
|
|
284
|
+
newText: H
|
|
285
|
+
};
|
|
286
|
+
}
|
|
287
|
+
p.insert = U;
|
|
288
|
+
function W(p) {
|
|
289
|
+
return {
|
|
290
|
+
range: p,
|
|
291
|
+
newText: ""
|
|
292
|
+
};
|
|
293
|
+
}
|
|
294
|
+
p.del = W;
|
|
295
|
+
function G(p) {
|
|
296
|
+
let H = p;
|
|
297
|
+
return Is.objectLiteral(H) && Is.string(H.newText) && Range.is(H.range);
|
|
298
|
+
}
|
|
299
|
+
p.is = G;
|
|
300
|
+
})(TextEdit ||= {});
|
|
301
|
+
var ChangeAnnotation;
|
|
302
|
+
(function(p) {
|
|
303
|
+
function H(p, H, U) {
|
|
304
|
+
let W = { label: p };
|
|
305
|
+
return H !== void 0 && (W.needsConfirmation = H), U !== void 0 && (W.description = U), W;
|
|
306
|
+
}
|
|
307
|
+
p.create = H;
|
|
308
|
+
function U(p) {
|
|
309
|
+
let H = p;
|
|
310
|
+
return Is.objectLiteral(H) && Is.string(H.label) && (Is.boolean(H.needsConfirmation) || H.needsConfirmation === void 0) && (Is.string(H.description) || H.description === void 0);
|
|
311
|
+
}
|
|
312
|
+
p.is = U;
|
|
313
|
+
})(ChangeAnnotation ||= {});
|
|
314
|
+
var ChangeAnnotationIdentifier;
|
|
315
|
+
(function(p) {
|
|
316
|
+
function H(p) {
|
|
317
|
+
let H = p;
|
|
318
|
+
return Is.string(H);
|
|
319
|
+
}
|
|
320
|
+
p.is = H;
|
|
321
|
+
})(ChangeAnnotationIdentifier ||= {});
|
|
322
|
+
var AnnotatedTextEdit;
|
|
323
|
+
(function(p) {
|
|
324
|
+
function H(p, H, U) {
|
|
325
|
+
return {
|
|
326
|
+
range: p,
|
|
327
|
+
newText: H,
|
|
328
|
+
annotationId: U
|
|
329
|
+
};
|
|
330
|
+
}
|
|
331
|
+
p.replace = H;
|
|
332
|
+
function U(p, H, U) {
|
|
333
|
+
return {
|
|
334
|
+
range: {
|
|
335
|
+
start: p,
|
|
336
|
+
end: p
|
|
337
|
+
},
|
|
338
|
+
newText: H,
|
|
339
|
+
annotationId: U
|
|
340
|
+
};
|
|
341
|
+
}
|
|
342
|
+
p.insert = U;
|
|
343
|
+
function W(p, H) {
|
|
344
|
+
return {
|
|
345
|
+
range: p,
|
|
346
|
+
newText: "",
|
|
347
|
+
annotationId: H
|
|
348
|
+
};
|
|
349
|
+
}
|
|
350
|
+
p.del = W;
|
|
351
|
+
function G(p) {
|
|
352
|
+
let H = p;
|
|
353
|
+
return TextEdit.is(H) && (ChangeAnnotation.is(H.annotationId) || ChangeAnnotationIdentifier.is(H.annotationId));
|
|
354
|
+
}
|
|
355
|
+
p.is = G;
|
|
356
|
+
})(AnnotatedTextEdit ||= {});
|
|
357
|
+
var TextDocumentEdit;
|
|
358
|
+
(function(p) {
|
|
359
|
+
function H(p, H) {
|
|
360
|
+
return {
|
|
361
|
+
textDocument: p,
|
|
362
|
+
edits: H
|
|
363
|
+
};
|
|
364
|
+
}
|
|
365
|
+
p.create = H;
|
|
366
|
+
function U(p) {
|
|
367
|
+
let H = p;
|
|
368
|
+
return Is.defined(H) && OptionalVersionedTextDocumentIdentifier.is(H.textDocument) && Array.isArray(H.edits);
|
|
369
|
+
}
|
|
370
|
+
p.is = U;
|
|
371
|
+
})(TextDocumentEdit ||= {});
|
|
372
|
+
var CreateFile;
|
|
373
|
+
(function(p) {
|
|
374
|
+
function H(p, H, U) {
|
|
375
|
+
let W = {
|
|
376
|
+
kind: "create",
|
|
377
|
+
uri: p
|
|
378
|
+
};
|
|
379
|
+
return H !== void 0 && (H.overwrite !== void 0 || H.ignoreIfExists !== void 0) && (W.options = H), U !== void 0 && (W.annotationId = U), W;
|
|
380
|
+
}
|
|
381
|
+
p.create = H;
|
|
382
|
+
function U(p) {
|
|
383
|
+
let H = p;
|
|
384
|
+
return H && H.kind === "create" && Is.string(H.uri) && (H.options === void 0 || (H.options.overwrite === void 0 || Is.boolean(H.options.overwrite)) && (H.options.ignoreIfExists === void 0 || Is.boolean(H.options.ignoreIfExists))) && (H.annotationId === void 0 || ChangeAnnotationIdentifier.is(H.annotationId));
|
|
385
|
+
}
|
|
386
|
+
p.is = U;
|
|
387
|
+
})(CreateFile ||= {});
|
|
388
|
+
var RenameFile;
|
|
389
|
+
(function(p) {
|
|
390
|
+
function H(p, H, U, W) {
|
|
391
|
+
let G = {
|
|
392
|
+
kind: "rename",
|
|
393
|
+
oldUri: p,
|
|
394
|
+
newUri: H
|
|
395
|
+
};
|
|
396
|
+
return U !== void 0 && (U.overwrite !== void 0 || U.ignoreIfExists !== void 0) && (G.options = U), W !== void 0 && (G.annotationId = W), G;
|
|
397
|
+
}
|
|
398
|
+
p.create = H;
|
|
399
|
+
function U(p) {
|
|
400
|
+
let H = p;
|
|
401
|
+
return H && H.kind === "rename" && Is.string(H.oldUri) && Is.string(H.newUri) && (H.options === void 0 || (H.options.overwrite === void 0 || Is.boolean(H.options.overwrite)) && (H.options.ignoreIfExists === void 0 || Is.boolean(H.options.ignoreIfExists))) && (H.annotationId === void 0 || ChangeAnnotationIdentifier.is(H.annotationId));
|
|
402
|
+
}
|
|
403
|
+
p.is = U;
|
|
404
|
+
})(RenameFile ||= {});
|
|
405
|
+
var DeleteFile;
|
|
406
|
+
(function(p) {
|
|
407
|
+
function H(p, H, U) {
|
|
408
|
+
let W = {
|
|
409
|
+
kind: "delete",
|
|
410
|
+
uri: p
|
|
411
|
+
};
|
|
412
|
+
return H !== void 0 && (H.recursive !== void 0 || H.ignoreIfNotExists !== void 0) && (W.options = H), U !== void 0 && (W.annotationId = U), W;
|
|
413
|
+
}
|
|
414
|
+
p.create = H;
|
|
415
|
+
function U(p) {
|
|
416
|
+
let H = p;
|
|
417
|
+
return H && H.kind === "delete" && Is.string(H.uri) && (H.options === void 0 || (H.options.recursive === void 0 || Is.boolean(H.options.recursive)) && (H.options.ignoreIfNotExists === void 0 || Is.boolean(H.options.ignoreIfNotExists))) && (H.annotationId === void 0 || ChangeAnnotationIdentifier.is(H.annotationId));
|
|
418
|
+
}
|
|
419
|
+
p.is = U;
|
|
420
|
+
})(DeleteFile ||= {});
|
|
421
|
+
var WorkspaceEdit;
|
|
422
|
+
(function(p) {
|
|
423
|
+
function H(p) {
|
|
424
|
+
let H = p;
|
|
425
|
+
return H && (H.changes !== void 0 || H.documentChanges !== void 0) && (H.documentChanges === void 0 || H.documentChanges.every((p) => Is.string(p.kind) ? CreateFile.is(p) || RenameFile.is(p) || DeleteFile.is(p) : TextDocumentEdit.is(p)));
|
|
426
|
+
}
|
|
427
|
+
p.is = H;
|
|
428
|
+
})(WorkspaceEdit ||= {});
|
|
429
|
+
var TextDocumentIdentifier;
|
|
430
|
+
(function(p) {
|
|
431
|
+
function H(p) {
|
|
432
|
+
return { uri: p };
|
|
433
|
+
}
|
|
434
|
+
p.create = H;
|
|
435
|
+
function U(p) {
|
|
436
|
+
let H = p;
|
|
437
|
+
return Is.defined(H) && Is.string(H.uri);
|
|
438
|
+
}
|
|
439
|
+
p.is = U;
|
|
440
|
+
})(TextDocumentIdentifier ||= {});
|
|
441
|
+
var VersionedTextDocumentIdentifier;
|
|
442
|
+
(function(p) {
|
|
443
|
+
function H(p, H) {
|
|
444
|
+
return {
|
|
445
|
+
uri: p,
|
|
446
|
+
version: H
|
|
447
|
+
};
|
|
448
|
+
}
|
|
449
|
+
p.create = H;
|
|
450
|
+
function U(p) {
|
|
451
|
+
let H = p;
|
|
452
|
+
return Is.defined(H) && Is.string(H.uri) && Is.integer(H.version);
|
|
453
|
+
}
|
|
454
|
+
p.is = U;
|
|
455
|
+
})(VersionedTextDocumentIdentifier ||= {});
|
|
456
|
+
var OptionalVersionedTextDocumentIdentifier;
|
|
457
|
+
(function(p) {
|
|
458
|
+
function H(p, H) {
|
|
459
|
+
return {
|
|
460
|
+
uri: p,
|
|
461
|
+
version: H
|
|
462
|
+
};
|
|
463
|
+
}
|
|
464
|
+
p.create = H;
|
|
465
|
+
function U(p) {
|
|
466
|
+
let H = p;
|
|
467
|
+
return Is.defined(H) && Is.string(H.uri) && (H.version === null || Is.integer(H.version));
|
|
468
|
+
}
|
|
469
|
+
p.is = U;
|
|
470
|
+
})(OptionalVersionedTextDocumentIdentifier ||= {});
|
|
471
|
+
var TextDocumentItem;
|
|
472
|
+
(function(p) {
|
|
473
|
+
function H(p, H, U, W) {
|
|
474
|
+
return {
|
|
475
|
+
uri: p,
|
|
476
|
+
languageId: H,
|
|
477
|
+
version: U,
|
|
478
|
+
text: W
|
|
479
|
+
};
|
|
480
|
+
}
|
|
481
|
+
p.create = H;
|
|
482
|
+
function U(p) {
|
|
483
|
+
let H = p;
|
|
484
|
+
return Is.defined(H) && Is.string(H.uri) && Is.string(H.languageId) && Is.integer(H.version) && Is.string(H.text);
|
|
485
|
+
}
|
|
486
|
+
p.is = U;
|
|
487
|
+
})(TextDocumentItem ||= {});
|
|
488
|
+
var MarkupKind;
|
|
489
|
+
(function(p) {
|
|
490
|
+
p.PlainText = "plaintext", p.Markdown = "markdown";
|
|
491
|
+
function H(H) {
|
|
492
|
+
let U = H;
|
|
493
|
+
return U === p.PlainText || U === p.Markdown;
|
|
494
|
+
}
|
|
495
|
+
p.is = H;
|
|
496
|
+
})(MarkupKind ||= {});
|
|
497
|
+
var MarkupContent;
|
|
498
|
+
(function(p) {
|
|
499
|
+
function H(p) {
|
|
500
|
+
let H = p;
|
|
501
|
+
return Is.objectLiteral(p) && MarkupKind.is(H.kind) && Is.string(H.value);
|
|
502
|
+
}
|
|
503
|
+
p.is = H;
|
|
504
|
+
})(MarkupContent ||= {});
|
|
505
|
+
var CompletionItemKind;
|
|
506
|
+
(function(p) {
|
|
507
|
+
p.Text = 1, p.Method = 2, p.Function = 3, p.Constructor = 4, p.Field = 5, p.Variable = 6, p.Class = 7, p.Interface = 8, p.Module = 9, p.Property = 10, p.Unit = 11, p.Value = 12, p.Enum = 13, p.Keyword = 14, p.Snippet = 15, p.Color = 16, p.File = 17, p.Reference = 18, p.Folder = 19, p.EnumMember = 20, p.Constant = 21, p.Struct = 22, p.Event = 23, p.Operator = 24, p.TypeParameter = 25;
|
|
508
|
+
})(CompletionItemKind ||= {});
|
|
509
|
+
var InsertTextFormat;
|
|
510
|
+
(function(p) {
|
|
511
|
+
p.PlainText = 1, p.Snippet = 2;
|
|
512
|
+
})(InsertTextFormat ||= {});
|
|
513
|
+
var CompletionItemTag;
|
|
514
|
+
(function(p) {
|
|
515
|
+
p.Deprecated = 1;
|
|
516
|
+
})(CompletionItemTag ||= {});
|
|
517
|
+
var InsertReplaceEdit;
|
|
518
|
+
(function(p) {
|
|
519
|
+
function H(p, H, U) {
|
|
520
|
+
return {
|
|
521
|
+
newText: p,
|
|
522
|
+
insert: H,
|
|
523
|
+
replace: U
|
|
524
|
+
};
|
|
525
|
+
}
|
|
526
|
+
p.create = H;
|
|
527
|
+
function U(p) {
|
|
528
|
+
let H = p;
|
|
529
|
+
return H && Is.string(H.newText) && Range.is(H.insert) && Range.is(H.replace);
|
|
530
|
+
}
|
|
531
|
+
p.is = U;
|
|
532
|
+
})(InsertReplaceEdit ||= {});
|
|
533
|
+
var InsertTextMode;
|
|
534
|
+
(function(p) {
|
|
535
|
+
p.asIs = 1, p.adjustIndentation = 2;
|
|
536
|
+
})(InsertTextMode ||= {});
|
|
537
|
+
var CompletionItemLabelDetails;
|
|
538
|
+
(function(p) {
|
|
539
|
+
function H(p) {
|
|
540
|
+
let H = p;
|
|
541
|
+
return H && (Is.string(H.detail) || H.detail === void 0) && (Is.string(H.description) || H.description === void 0);
|
|
542
|
+
}
|
|
543
|
+
p.is = H;
|
|
544
|
+
})(CompletionItemLabelDetails ||= {});
|
|
545
|
+
var CompletionItem;
|
|
546
|
+
(function(p) {
|
|
547
|
+
function H(p) {
|
|
548
|
+
return { label: p };
|
|
549
|
+
}
|
|
550
|
+
p.create = H;
|
|
551
|
+
})(CompletionItem ||= {});
|
|
552
|
+
var CompletionList;
|
|
553
|
+
(function(p) {
|
|
554
|
+
function H(p, H) {
|
|
555
|
+
return {
|
|
556
|
+
items: p || [],
|
|
557
|
+
isIncomplete: !!H
|
|
558
|
+
};
|
|
559
|
+
}
|
|
560
|
+
p.create = H;
|
|
561
|
+
})(CompletionList ||= {});
|
|
562
|
+
var MarkedString;
|
|
563
|
+
(function(p) {
|
|
564
|
+
function H(p) {
|
|
565
|
+
return p.replace(/[\\`*_{}[\]()#+\-.!]/g, "\\$&");
|
|
566
|
+
}
|
|
567
|
+
p.fromPlainText = H;
|
|
568
|
+
function U(p) {
|
|
569
|
+
let H = p;
|
|
570
|
+
return Is.string(H) || Is.objectLiteral(H) && Is.string(H.language) && Is.string(H.value);
|
|
571
|
+
}
|
|
572
|
+
p.is = U;
|
|
573
|
+
})(MarkedString ||= {});
|
|
574
|
+
var Hover;
|
|
575
|
+
(function(p) {
|
|
576
|
+
function H(p) {
|
|
577
|
+
let H = p;
|
|
578
|
+
return !!H && Is.objectLiteral(H) && (MarkupContent.is(H.contents) || MarkedString.is(H.contents) || Is.typedArray(H.contents, MarkedString.is)) && (p.range === void 0 || Range.is(p.range));
|
|
579
|
+
}
|
|
580
|
+
p.is = H;
|
|
581
|
+
})(Hover ||= {});
|
|
582
|
+
var ParameterInformation;
|
|
583
|
+
(function(p) {
|
|
584
|
+
function H(p, H) {
|
|
585
|
+
return H ? {
|
|
586
|
+
label: p,
|
|
587
|
+
documentation: H
|
|
588
|
+
} : { label: p };
|
|
589
|
+
}
|
|
590
|
+
p.create = H;
|
|
591
|
+
})(ParameterInformation ||= {});
|
|
592
|
+
var SignatureInformation;
|
|
593
|
+
(function(p) {
|
|
594
|
+
function H(p, H, ...U) {
|
|
595
|
+
let W = { label: p };
|
|
596
|
+
return Is.defined(H) && (W.documentation = H), Is.defined(U) ? W.parameters = U : W.parameters = [], W;
|
|
597
|
+
}
|
|
598
|
+
p.create = H;
|
|
599
|
+
})(SignatureInformation ||= {});
|
|
600
|
+
var DocumentHighlightKind;
|
|
601
|
+
(function(p) {
|
|
602
|
+
p.Text = 1, p.Read = 2, p.Write = 3;
|
|
603
|
+
})(DocumentHighlightKind ||= {});
|
|
604
|
+
var DocumentHighlight;
|
|
605
|
+
(function(p) {
|
|
606
|
+
function H(p, H) {
|
|
607
|
+
let U = { range: p };
|
|
608
|
+
return Is.number(H) && (U.kind = H), U;
|
|
609
|
+
}
|
|
610
|
+
p.create = H;
|
|
611
|
+
})(DocumentHighlight ||= {});
|
|
612
|
+
var SymbolKind;
|
|
613
|
+
(function(p) {
|
|
614
|
+
p.File = 1, p.Module = 2, p.Namespace = 3, p.Package = 4, p.Class = 5, p.Method = 6, p.Property = 7, p.Field = 8, p.Constructor = 9, p.Enum = 10, p.Interface = 11, p.Function = 12, p.Variable = 13, p.Constant = 14, p.String = 15, p.Number = 16, p.Boolean = 17, p.Array = 18, p.Object = 19, p.Key = 20, p.Null = 21, p.EnumMember = 22, p.Struct = 23, p.Event = 24, p.Operator = 25, p.TypeParameter = 26;
|
|
615
|
+
})(SymbolKind ||= {});
|
|
616
|
+
var SymbolTag;
|
|
617
|
+
(function(p) {
|
|
618
|
+
p.Deprecated = 1;
|
|
619
|
+
})(SymbolTag ||= {});
|
|
620
|
+
var SymbolInformation;
|
|
621
|
+
(function(p) {
|
|
622
|
+
function H(p, H, U, W, G) {
|
|
623
|
+
let K = {
|
|
624
|
+
name: p,
|
|
625
|
+
kind: H,
|
|
626
|
+
location: {
|
|
627
|
+
uri: W,
|
|
628
|
+
range: U
|
|
629
|
+
}
|
|
630
|
+
};
|
|
631
|
+
return G && (K.containerName = G), K;
|
|
632
|
+
}
|
|
633
|
+
p.create = H;
|
|
634
|
+
})(SymbolInformation ||= {});
|
|
635
|
+
var WorkspaceSymbol;
|
|
636
|
+
(function(p) {
|
|
637
|
+
function H(p, H, U, W) {
|
|
638
|
+
return W === void 0 ? {
|
|
639
|
+
name: p,
|
|
640
|
+
kind: H,
|
|
641
|
+
location: { uri: U }
|
|
642
|
+
} : {
|
|
643
|
+
name: p,
|
|
644
|
+
kind: H,
|
|
645
|
+
location: {
|
|
646
|
+
uri: U,
|
|
647
|
+
range: W
|
|
648
|
+
}
|
|
649
|
+
};
|
|
650
|
+
}
|
|
651
|
+
p.create = H;
|
|
652
|
+
})(WorkspaceSymbol ||= {});
|
|
653
|
+
var DocumentSymbol;
|
|
654
|
+
(function(p) {
|
|
655
|
+
function H(p, H, U, W, G, K) {
|
|
656
|
+
let q = {
|
|
657
|
+
name: p,
|
|
658
|
+
detail: H,
|
|
659
|
+
kind: U,
|
|
660
|
+
range: W,
|
|
661
|
+
selectionRange: G
|
|
662
|
+
};
|
|
663
|
+
return K !== void 0 && (q.children = K), q;
|
|
664
|
+
}
|
|
665
|
+
p.create = H;
|
|
666
|
+
function U(p) {
|
|
667
|
+
let H = p;
|
|
668
|
+
return H && Is.string(H.name) && Is.number(H.kind) && Range.is(H.range) && Range.is(H.selectionRange) && (H.detail === void 0 || Is.string(H.detail)) && (H.deprecated === void 0 || Is.boolean(H.deprecated)) && (H.children === void 0 || Array.isArray(H.children)) && (H.tags === void 0 || Array.isArray(H.tags));
|
|
669
|
+
}
|
|
670
|
+
p.is = U;
|
|
671
|
+
})(DocumentSymbol ||= {});
|
|
672
|
+
var CodeActionKind;
|
|
673
|
+
(function(p) {
|
|
674
|
+
p.Empty = "", p.QuickFix = "quickfix", p.Refactor = "refactor", p.RefactorExtract = "refactor.extract", p.RefactorInline = "refactor.inline", p.RefactorRewrite = "refactor.rewrite", p.Source = "source", p.SourceOrganizeImports = "source.organizeImports", p.SourceFixAll = "source.fixAll";
|
|
675
|
+
})(CodeActionKind ||= {});
|
|
676
|
+
var CodeActionTriggerKind;
|
|
677
|
+
(function(p) {
|
|
678
|
+
p.Invoked = 1, p.Automatic = 2;
|
|
679
|
+
})(CodeActionTriggerKind ||= {});
|
|
680
|
+
var CodeActionContext;
|
|
681
|
+
(function(p) {
|
|
682
|
+
function H(p, H, U) {
|
|
683
|
+
let W = { diagnostics: p };
|
|
684
|
+
return H != null && (W.only = H), U != null && (W.triggerKind = U), W;
|
|
685
|
+
}
|
|
686
|
+
p.create = H;
|
|
687
|
+
function U(p) {
|
|
688
|
+
let H = p;
|
|
689
|
+
return Is.defined(H) && Is.typedArray(H.diagnostics, Diagnostic.is) && (H.only === void 0 || Is.typedArray(H.only, Is.string)) && (H.triggerKind === void 0 || H.triggerKind === CodeActionTriggerKind.Invoked || H.triggerKind === CodeActionTriggerKind.Automatic);
|
|
690
|
+
}
|
|
691
|
+
p.is = U;
|
|
692
|
+
})(CodeActionContext ||= {});
|
|
693
|
+
var CodeAction;
|
|
694
|
+
(function(p) {
|
|
695
|
+
function H(p, H, U) {
|
|
696
|
+
let W = { title: p }, G = !0;
|
|
697
|
+
return typeof H == "string" ? (G = !1, W.kind = H) : Command.is(H) ? W.command = H : W.edit = H, G && U !== void 0 && (W.kind = U), W;
|
|
698
|
+
}
|
|
699
|
+
p.create = H;
|
|
700
|
+
function U(p) {
|
|
701
|
+
let H = p;
|
|
702
|
+
return H && Is.string(H.title) && (H.diagnostics === void 0 || Is.typedArray(H.diagnostics, Diagnostic.is)) && (H.kind === void 0 || Is.string(H.kind)) && (H.edit !== void 0 || H.command !== void 0) && (H.command === void 0 || Command.is(H.command)) && (H.isPreferred === void 0 || Is.boolean(H.isPreferred)) && (H.edit === void 0 || WorkspaceEdit.is(H.edit));
|
|
703
|
+
}
|
|
704
|
+
p.is = U;
|
|
705
|
+
})(CodeAction ||= {});
|
|
706
|
+
var CodeLens;
|
|
707
|
+
(function(p) {
|
|
708
|
+
function H(p, H) {
|
|
709
|
+
let U = { range: p };
|
|
710
|
+
return Is.defined(H) && (U.data = H), U;
|
|
711
|
+
}
|
|
712
|
+
p.create = H;
|
|
713
|
+
function U(p) {
|
|
714
|
+
let H = p;
|
|
715
|
+
return Is.defined(H) && Range.is(H.range) && (Is.undefined(H.command) || Command.is(H.command));
|
|
716
|
+
}
|
|
717
|
+
p.is = U;
|
|
718
|
+
})(CodeLens ||= {});
|
|
719
|
+
var FormattingOptions;
|
|
720
|
+
(function(p) {
|
|
721
|
+
function H(p, H) {
|
|
722
|
+
return {
|
|
723
|
+
tabSize: p,
|
|
724
|
+
insertSpaces: H
|
|
725
|
+
};
|
|
726
|
+
}
|
|
727
|
+
p.create = H;
|
|
728
|
+
function U(p) {
|
|
729
|
+
let H = p;
|
|
730
|
+
return Is.defined(H) && Is.uinteger(H.tabSize) && Is.boolean(H.insertSpaces);
|
|
731
|
+
}
|
|
732
|
+
p.is = U;
|
|
733
|
+
})(FormattingOptions ||= {});
|
|
734
|
+
var DocumentLink;
|
|
735
|
+
(function(p) {
|
|
736
|
+
function H(p, H, U) {
|
|
737
|
+
return {
|
|
738
|
+
range: p,
|
|
739
|
+
target: H,
|
|
740
|
+
data: U
|
|
741
|
+
};
|
|
742
|
+
}
|
|
743
|
+
p.create = H;
|
|
744
|
+
function U(p) {
|
|
745
|
+
let H = p;
|
|
746
|
+
return Is.defined(H) && Range.is(H.range) && (Is.undefined(H.target) || Is.string(H.target));
|
|
747
|
+
}
|
|
748
|
+
p.is = U;
|
|
749
|
+
})(DocumentLink ||= {});
|
|
750
|
+
var SelectionRange;
|
|
751
|
+
(function(p) {
|
|
752
|
+
function H(p, H) {
|
|
753
|
+
return {
|
|
754
|
+
range: p,
|
|
755
|
+
parent: H
|
|
756
|
+
};
|
|
757
|
+
}
|
|
758
|
+
p.create = H;
|
|
759
|
+
function U(H) {
|
|
760
|
+
let U = H;
|
|
761
|
+
return Is.objectLiteral(U) && Range.is(U.range) && (U.parent === void 0 || p.is(U.parent));
|
|
762
|
+
}
|
|
763
|
+
p.is = U;
|
|
764
|
+
})(SelectionRange ||= {});
|
|
765
|
+
var SemanticTokenTypes;
|
|
766
|
+
(function(p) {
|
|
767
|
+
p.namespace = "namespace", p.type = "type", p.class = "class", p.enum = "enum", p.interface = "interface", p.struct = "struct", p.typeParameter = "typeParameter", p.parameter = "parameter", p.variable = "variable", p.property = "property", p.enumMember = "enumMember", p.event = "event", p.function = "function", p.method = "method", p.macro = "macro", p.keyword = "keyword", p.modifier = "modifier", p.comment = "comment", p.string = "string", p.number = "number", p.regexp = "regexp", p.operator = "operator", p.decorator = "decorator";
|
|
768
|
+
})(SemanticTokenTypes ||= {});
|
|
769
|
+
var SemanticTokenModifiers;
|
|
770
|
+
(function(p) {
|
|
771
|
+
p.declaration = "declaration", p.definition = "definition", p.readonly = "readonly", p.static = "static", p.deprecated = "deprecated", p.abstract = "abstract", p.async = "async", p.modification = "modification", p.documentation = "documentation", p.defaultLibrary = "defaultLibrary";
|
|
772
|
+
})(SemanticTokenModifiers ||= {});
|
|
773
|
+
var SemanticTokens;
|
|
774
|
+
(function(p) {
|
|
775
|
+
function H(p) {
|
|
776
|
+
let H = p;
|
|
777
|
+
return Is.objectLiteral(H) && (H.resultId === void 0 || typeof H.resultId == "string") && Array.isArray(H.data) && (H.data.length === 0 || typeof H.data[0] == "number");
|
|
778
|
+
}
|
|
779
|
+
p.is = H;
|
|
780
|
+
})(SemanticTokens ||= {});
|
|
781
|
+
var InlineValueText;
|
|
782
|
+
(function(p) {
|
|
783
|
+
function H(p, H) {
|
|
784
|
+
return {
|
|
785
|
+
range: p,
|
|
786
|
+
text: H
|
|
787
|
+
};
|
|
788
|
+
}
|
|
789
|
+
p.create = H;
|
|
790
|
+
function U(p) {
|
|
791
|
+
let H = p;
|
|
792
|
+
return H != null && Range.is(H.range) && Is.string(H.text);
|
|
793
|
+
}
|
|
794
|
+
p.is = U;
|
|
795
|
+
})(InlineValueText ||= {});
|
|
796
|
+
var InlineValueVariableLookup;
|
|
797
|
+
(function(p) {
|
|
798
|
+
function H(p, H, U) {
|
|
799
|
+
return {
|
|
800
|
+
range: p,
|
|
801
|
+
variableName: H,
|
|
802
|
+
caseSensitiveLookup: U
|
|
803
|
+
};
|
|
804
|
+
}
|
|
805
|
+
p.create = H;
|
|
806
|
+
function U(p) {
|
|
807
|
+
let H = p;
|
|
808
|
+
return H != null && Range.is(H.range) && Is.boolean(H.caseSensitiveLookup) && (Is.string(H.variableName) || H.variableName === void 0);
|
|
809
|
+
}
|
|
810
|
+
p.is = U;
|
|
811
|
+
})(InlineValueVariableLookup ||= {});
|
|
812
|
+
var InlineValueEvaluatableExpression;
|
|
813
|
+
(function(p) {
|
|
814
|
+
function H(p, H) {
|
|
815
|
+
return {
|
|
816
|
+
range: p,
|
|
817
|
+
expression: H
|
|
818
|
+
};
|
|
819
|
+
}
|
|
820
|
+
p.create = H;
|
|
821
|
+
function U(p) {
|
|
822
|
+
let H = p;
|
|
823
|
+
return H != null && Range.is(H.range) && (Is.string(H.expression) || H.expression === void 0);
|
|
824
|
+
}
|
|
825
|
+
p.is = U;
|
|
826
|
+
})(InlineValueEvaluatableExpression ||= {});
|
|
827
|
+
var InlineValueContext;
|
|
828
|
+
(function(p) {
|
|
829
|
+
function H(p, H) {
|
|
830
|
+
return {
|
|
831
|
+
frameId: p,
|
|
832
|
+
stoppedLocation: H
|
|
833
|
+
};
|
|
834
|
+
}
|
|
835
|
+
p.create = H;
|
|
836
|
+
function U(p) {
|
|
837
|
+
let H = p;
|
|
838
|
+
return Is.defined(H) && Range.is(p.stoppedLocation);
|
|
839
|
+
}
|
|
840
|
+
p.is = U;
|
|
841
|
+
})(InlineValueContext ||= {});
|
|
842
|
+
var InlayHintKind;
|
|
843
|
+
(function(p) {
|
|
844
|
+
p.Type = 1, p.Parameter = 2;
|
|
845
|
+
function H(p) {
|
|
846
|
+
return p === 1 || p === 2;
|
|
847
|
+
}
|
|
848
|
+
p.is = H;
|
|
849
|
+
})(InlayHintKind ||= {});
|
|
850
|
+
var InlayHintLabelPart;
|
|
851
|
+
(function(p) {
|
|
852
|
+
function H(p) {
|
|
853
|
+
return { value: p };
|
|
854
|
+
}
|
|
855
|
+
p.create = H;
|
|
856
|
+
function U(p) {
|
|
857
|
+
let H = p;
|
|
858
|
+
return Is.objectLiteral(H) && (H.tooltip === void 0 || Is.string(H.tooltip) || MarkupContent.is(H.tooltip)) && (H.location === void 0 || Location.is(H.location)) && (H.command === void 0 || Command.is(H.command));
|
|
859
|
+
}
|
|
860
|
+
p.is = U;
|
|
861
|
+
})(InlayHintLabelPart ||= {});
|
|
862
|
+
var InlayHint;
|
|
863
|
+
(function(p) {
|
|
864
|
+
function H(p, H, U) {
|
|
865
|
+
let W = {
|
|
866
|
+
position: p,
|
|
867
|
+
label: H
|
|
868
|
+
};
|
|
869
|
+
return U !== void 0 && (W.kind = U), W;
|
|
870
|
+
}
|
|
871
|
+
p.create = H;
|
|
872
|
+
function U(p) {
|
|
873
|
+
let H = p;
|
|
874
|
+
return Is.objectLiteral(H) && Position.is(H.position) && (Is.string(H.label) || Is.typedArray(H.label, InlayHintLabelPart.is)) && (H.kind === void 0 || InlayHintKind.is(H.kind)) && H.textEdits === void 0 || Is.typedArray(H.textEdits, TextEdit.is) && (H.tooltip === void 0 || Is.string(H.tooltip) || MarkupContent.is(H.tooltip)) && (H.paddingLeft === void 0 || Is.boolean(H.paddingLeft)) && (H.paddingRight === void 0 || Is.boolean(H.paddingRight));
|
|
875
|
+
}
|
|
876
|
+
p.is = U;
|
|
877
|
+
})(InlayHint ||= {});
|
|
878
|
+
var StringValue;
|
|
879
|
+
(function(p) {
|
|
880
|
+
function H(p) {
|
|
881
|
+
return {
|
|
882
|
+
kind: "snippet",
|
|
883
|
+
value: p
|
|
884
|
+
};
|
|
885
|
+
}
|
|
886
|
+
p.createSnippet = H;
|
|
887
|
+
})(StringValue ||= {});
|
|
888
|
+
var InlineCompletionItem;
|
|
889
|
+
(function(p) {
|
|
890
|
+
function H(p, H, U, W) {
|
|
891
|
+
return {
|
|
892
|
+
insertText: p,
|
|
893
|
+
filterText: H,
|
|
894
|
+
range: U,
|
|
895
|
+
command: W
|
|
896
|
+
};
|
|
897
|
+
}
|
|
898
|
+
p.create = H;
|
|
899
|
+
})(InlineCompletionItem ||= {});
|
|
900
|
+
var InlineCompletionList;
|
|
901
|
+
(function(p) {
|
|
902
|
+
function H(p) {
|
|
903
|
+
return { items: p };
|
|
904
|
+
}
|
|
905
|
+
p.create = H;
|
|
906
|
+
})(InlineCompletionList ||= {});
|
|
907
|
+
var InlineCompletionTriggerKind;
|
|
908
|
+
(function(p) {
|
|
909
|
+
p.Invoked = 0, p.Automatic = 1;
|
|
910
|
+
})(InlineCompletionTriggerKind ||= {});
|
|
911
|
+
var SelectedCompletionInfo;
|
|
912
|
+
(function(p) {
|
|
913
|
+
function H(p, H) {
|
|
914
|
+
return {
|
|
915
|
+
range: p,
|
|
916
|
+
text: H
|
|
917
|
+
};
|
|
918
|
+
}
|
|
919
|
+
p.create = H;
|
|
920
|
+
})(SelectedCompletionInfo ||= {});
|
|
921
|
+
var InlineCompletionContext;
|
|
922
|
+
(function(p) {
|
|
923
|
+
function H(p, H) {
|
|
924
|
+
return {
|
|
925
|
+
triggerKind: p,
|
|
926
|
+
selectedCompletionInfo: H
|
|
927
|
+
};
|
|
928
|
+
}
|
|
929
|
+
p.create = H;
|
|
930
|
+
})(InlineCompletionContext ||= {});
|
|
931
|
+
var WorkspaceFolder;
|
|
932
|
+
(function(p) {
|
|
933
|
+
function H(p) {
|
|
934
|
+
let H = p;
|
|
935
|
+
return Is.objectLiteral(H) && URI.is(H.uri) && Is.string(H.name);
|
|
936
|
+
}
|
|
937
|
+
p.is = H;
|
|
938
|
+
})(WorkspaceFolder ||= {});
|
|
939
|
+
var TextDocument;
|
|
940
|
+
(function(p) {
|
|
941
|
+
function H(p, H, U, W) {
|
|
942
|
+
return new FullTextDocument(p, H, U, W);
|
|
943
|
+
}
|
|
944
|
+
p.create = H;
|
|
945
|
+
function U(p) {
|
|
946
|
+
let H = p;
|
|
947
|
+
return !!(Is.defined(H) && Is.string(H.uri) && (Is.undefined(H.languageId) || Is.string(H.languageId)) && Is.uinteger(H.lineCount) && Is.func(H.getText) && Is.func(H.positionAt) && Is.func(H.offsetAt));
|
|
948
|
+
}
|
|
949
|
+
p.is = U;
|
|
950
|
+
function W(p, H) {
|
|
951
|
+
let U = p.getText(), W = G(H, (p, H) => {
|
|
952
|
+
let U = p.range.start.line - H.range.start.line;
|
|
953
|
+
return U === 0 ? p.range.start.character - H.range.start.character : U;
|
|
954
|
+
}), K = U.length;
|
|
955
|
+
for (let H = W.length - 1; H >= 0; H--) {
|
|
956
|
+
let G = W[H], q = p.offsetAt(G.range.start), J = p.offsetAt(G.range.end);
|
|
957
|
+
if (J <= K) U = U.substring(0, q) + G.newText + U.substring(J, U.length);
|
|
958
|
+
else throw Error("Overlapping edit");
|
|
959
|
+
K = q;
|
|
960
|
+
}
|
|
961
|
+
return U;
|
|
962
|
+
}
|
|
963
|
+
p.applyEdits = W;
|
|
964
|
+
function G(p, H) {
|
|
965
|
+
if (p.length <= 1) return p;
|
|
966
|
+
let U = p.length / 2 | 0, W = p.slice(0, U), K = p.slice(U);
|
|
967
|
+
G(W, H), G(K, H);
|
|
968
|
+
let q = 0, J = 0, Y = 0;
|
|
969
|
+
for (; q < W.length && J < K.length;) H(W[q], K[J]) <= 0 ? p[Y++] = W[q++] : p[Y++] = K[J++];
|
|
970
|
+
for (; q < W.length;) p[Y++] = W[q++];
|
|
971
|
+
for (; J < K.length;) p[Y++] = K[J++];
|
|
972
|
+
return p;
|
|
973
|
+
}
|
|
974
|
+
})(TextDocument ||= {});
|
|
975
|
+
var FullTextDocument = class {
|
|
976
|
+
constructor(p, H, U, W) {
|
|
977
|
+
this._uri = p, this._languageId = H, this._version = U, this._content = W, this._lineOffsets = void 0;
|
|
978
|
+
}
|
|
979
|
+
get uri() {
|
|
980
|
+
return this._uri;
|
|
981
|
+
}
|
|
982
|
+
get languageId() {
|
|
983
|
+
return this._languageId;
|
|
984
|
+
}
|
|
985
|
+
get version() {
|
|
986
|
+
return this._version;
|
|
987
|
+
}
|
|
988
|
+
getText(p) {
|
|
989
|
+
if (p) {
|
|
990
|
+
let H = this.offsetAt(p.start), U = this.offsetAt(p.end);
|
|
991
|
+
return this._content.substring(H, U);
|
|
992
|
+
}
|
|
993
|
+
return this._content;
|
|
994
|
+
}
|
|
995
|
+
update(p, H) {
|
|
996
|
+
this._content = p.text, this._version = H, this._lineOffsets = void 0;
|
|
997
|
+
}
|
|
998
|
+
getLineOffsets() {
|
|
999
|
+
if (this._lineOffsets === void 0) {
|
|
1000
|
+
let p = [], H = this._content, U = !0;
|
|
1001
|
+
for (let W = 0; W < H.length; W++) {
|
|
1002
|
+
U &&= (p.push(W), !1);
|
|
1003
|
+
let G = H.charAt(W);
|
|
1004
|
+
U = G === "\r" || G === "\n", G === "\r" && W + 1 < H.length && H.charAt(W + 1) === "\n" && W++;
|
|
1005
|
+
}
|
|
1006
|
+
U && H.length > 0 && p.push(H.length), this._lineOffsets = p;
|
|
1007
|
+
}
|
|
1008
|
+
return this._lineOffsets;
|
|
1009
|
+
}
|
|
1010
|
+
positionAt(p) {
|
|
1011
|
+
p = Math.max(Math.min(p, this._content.length), 0);
|
|
1012
|
+
let H = this.getLineOffsets(), U = 0, W = H.length;
|
|
1013
|
+
if (W === 0) return Position.create(0, p);
|
|
1014
|
+
for (; U < W;) {
|
|
1015
|
+
let G = Math.floor((U + W) / 2);
|
|
1016
|
+
H[G] > p ? W = G : U = G + 1;
|
|
1017
|
+
}
|
|
1018
|
+
let G = U - 1;
|
|
1019
|
+
return Position.create(G, p - H[G]);
|
|
1020
|
+
}
|
|
1021
|
+
offsetAt(p) {
|
|
1022
|
+
let H = this.getLineOffsets();
|
|
1023
|
+
if (p.line >= H.length) return this._content.length;
|
|
1024
|
+
if (p.line < 0) return 0;
|
|
1025
|
+
let U = H[p.line], W = p.line + 1 < H.length ? H[p.line + 1] : this._content.length;
|
|
1026
|
+
return Math.max(Math.min(U + p.character, W), U);
|
|
1027
|
+
}
|
|
1028
|
+
get lineCount() {
|
|
1029
|
+
return this.getLineOffsets().length;
|
|
1030
|
+
}
|
|
1031
|
+
}, Is;
|
|
1032
|
+
(function(p) {
|
|
1033
|
+
let H = Object.prototype.toString;
|
|
1034
|
+
function U(p) {
|
|
1035
|
+
return p !== void 0;
|
|
1036
|
+
}
|
|
1037
|
+
p.defined = U;
|
|
1038
|
+
function W(p) {
|
|
1039
|
+
return p === void 0;
|
|
1040
|
+
}
|
|
1041
|
+
p.undefined = W;
|
|
1042
|
+
function G(p) {
|
|
1043
|
+
return p === !0 || p === !1;
|
|
1044
|
+
}
|
|
1045
|
+
p.boolean = G;
|
|
1046
|
+
function K(p) {
|
|
1047
|
+
return H.call(p) === "[object String]";
|
|
1048
|
+
}
|
|
1049
|
+
p.string = K;
|
|
1050
|
+
function q(p) {
|
|
1051
|
+
return H.call(p) === "[object Number]";
|
|
1052
|
+
}
|
|
1053
|
+
p.number = q;
|
|
1054
|
+
function J(p, U, W) {
|
|
1055
|
+
return H.call(p) === "[object Number]" && U <= p && p <= W;
|
|
1056
|
+
}
|
|
1057
|
+
p.numberRange = J;
|
|
1058
|
+
function Y(p) {
|
|
1059
|
+
return H.call(p) === "[object Number]" && -2147483648 <= p && p <= 2147483647;
|
|
1060
|
+
}
|
|
1061
|
+
p.integer = Y;
|
|
1062
|
+
function X(p) {
|
|
1063
|
+
return H.call(p) === "[object Number]" && 0 <= p && p <= 2147483647;
|
|
1064
|
+
}
|
|
1065
|
+
p.uinteger = X;
|
|
1066
|
+
function Z(p) {
|
|
1067
|
+
return H.call(p) === "[object Function]";
|
|
1068
|
+
}
|
|
1069
|
+
p.func = Z;
|
|
1070
|
+
function Q(p) {
|
|
1071
|
+
return typeof p == "object" && !!p;
|
|
1072
|
+
}
|
|
1073
|
+
p.objectLiteral = Q;
|
|
1074
|
+
function $(p, H) {
|
|
1075
|
+
return Array.isArray(p) && p.every(H);
|
|
1076
|
+
}
|
|
1077
|
+
p.typedArray = $;
|
|
1078
|
+
})(Is ||= {});
|
|
1079
|
+
var DiagnosticsAdapter = class {
|
|
1080
|
+
constructor(p, H, U) {
|
|
1081
|
+
this._languageId = p, this._worker = H, this._disposables = [], this._listener = /* @__PURE__ */ Object.create(null);
|
|
1082
|
+
let W = (p) => {
|
|
1083
|
+
let H = p.getLanguageId();
|
|
1084
|
+
if (H !== this._languageId) return;
|
|
1085
|
+
let U;
|
|
1086
|
+
this._listener[p.uri.toString()] = p.onDidChangeContent(() => {
|
|
1087
|
+
window.clearTimeout(U), U = window.setTimeout(() => this._doValidate(p.uri, H), 500);
|
|
1088
|
+
}), this._doValidate(p.uri, H);
|
|
1089
|
+
}, G = (p) => {
|
|
1090
|
+
monaco_editor_core_exports.editor.setModelMarkers(p, this._languageId, []);
|
|
1091
|
+
let H = p.uri.toString(), U = this._listener[H];
|
|
1092
|
+
U && (U.dispose(), delete this._listener[H]);
|
|
1093
|
+
};
|
|
1094
|
+
this._disposables.push(monaco_editor_core_exports.editor.onDidCreateModel(W)), this._disposables.push(monaco_editor_core_exports.editor.onWillDisposeModel(G)), this._disposables.push(monaco_editor_core_exports.editor.onDidChangeModelLanguage((p) => {
|
|
1095
|
+
G(p.model), W(p.model);
|
|
1096
|
+
})), this._disposables.push(U((p) => {
|
|
1097
|
+
monaco_editor_core_exports.editor.getModels().forEach((p) => {
|
|
1098
|
+
p.getLanguageId() === this._languageId && (G(p), W(p));
|
|
1099
|
+
});
|
|
1100
|
+
})), this._disposables.push({ dispose: () => {
|
|
1101
|
+
for (let p in monaco_editor_core_exports.editor.getModels().forEach(G), this._listener) this._listener[p].dispose();
|
|
1102
|
+
} }), monaco_editor_core_exports.editor.getModels().forEach(W);
|
|
1103
|
+
}
|
|
1104
|
+
dispose() {
|
|
1105
|
+
this._disposables.forEach((p) => p && p.dispose()), this._disposables.length = 0;
|
|
1106
|
+
}
|
|
1107
|
+
_doValidate(p, H) {
|
|
1108
|
+
this._worker(p).then((H) => H.doValidation(p.toString())).then((U) => {
|
|
1109
|
+
let W = U.map((H) => toDiagnostics(p, H)), G = monaco_editor_core_exports.editor.getModel(p);
|
|
1110
|
+
G && G.getLanguageId() === H && monaco_editor_core_exports.editor.setModelMarkers(G, H, W);
|
|
1111
|
+
}).then(void 0, (p) => {
|
|
1112
|
+
console.error(p);
|
|
1113
|
+
});
|
|
1114
|
+
}
|
|
1115
|
+
};
|
|
1116
|
+
function toSeverity(p) {
|
|
1117
|
+
switch (p) {
|
|
1118
|
+
case DiagnosticSeverity.Error: return monaco_editor_core_exports.MarkerSeverity.Error;
|
|
1119
|
+
case DiagnosticSeverity.Warning: return monaco_editor_core_exports.MarkerSeverity.Warning;
|
|
1120
|
+
case DiagnosticSeverity.Information: return monaco_editor_core_exports.MarkerSeverity.Info;
|
|
1121
|
+
case DiagnosticSeverity.Hint: return monaco_editor_core_exports.MarkerSeverity.Hint;
|
|
1122
|
+
default: return monaco_editor_core_exports.MarkerSeverity.Info;
|
|
1123
|
+
}
|
|
1124
|
+
}
|
|
1125
|
+
function toDiagnostics(p, H) {
|
|
1126
|
+
let U = typeof H.code == "number" ? String(H.code) : H.code;
|
|
1127
|
+
return {
|
|
1128
|
+
severity: toSeverity(H.severity),
|
|
1129
|
+
startLineNumber: H.range.start.line + 1,
|
|
1130
|
+
startColumn: H.range.start.character + 1,
|
|
1131
|
+
endLineNumber: H.range.end.line + 1,
|
|
1132
|
+
endColumn: H.range.end.character + 1,
|
|
1133
|
+
message: H.message,
|
|
1134
|
+
code: U,
|
|
1135
|
+
source: H.source
|
|
1136
|
+
};
|
|
1137
|
+
}
|
|
1138
|
+
var CompletionAdapter = class {
|
|
1139
|
+
constructor(p, H) {
|
|
1140
|
+
this._worker = p, this._triggerCharacters = H;
|
|
1141
|
+
}
|
|
1142
|
+
get triggerCharacters() {
|
|
1143
|
+
return this._triggerCharacters;
|
|
1144
|
+
}
|
|
1145
|
+
provideCompletionItems(p, H, U, W) {
|
|
1146
|
+
let G = p.uri;
|
|
1147
|
+
return this._worker(G).then((p) => p.doComplete(G.toString(), fromPosition(H))).then((U) => {
|
|
1148
|
+
if (!U) return;
|
|
1149
|
+
let W = p.getWordUntilPosition(H), G = new monaco_editor_core_exports.Range(H.lineNumber, W.startColumn, H.lineNumber, W.endColumn), K = U.items.map((p) => {
|
|
1150
|
+
let H = {
|
|
1151
|
+
label: p.label,
|
|
1152
|
+
insertText: p.insertText || p.label,
|
|
1153
|
+
sortText: p.sortText,
|
|
1154
|
+
filterText: p.filterText,
|
|
1155
|
+
documentation: p.documentation,
|
|
1156
|
+
detail: p.detail,
|
|
1157
|
+
command: toCommand(p.command),
|
|
1158
|
+
range: G,
|
|
1159
|
+
kind: toCompletionItemKind(p.kind)
|
|
1160
|
+
};
|
|
1161
|
+
return p.textEdit && (isInsertReplaceEdit(p.textEdit) ? H.range = {
|
|
1162
|
+
insert: toRange(p.textEdit.insert),
|
|
1163
|
+
replace: toRange(p.textEdit.replace)
|
|
1164
|
+
} : H.range = toRange(p.textEdit.range), H.insertText = p.textEdit.newText), p.additionalTextEdits && (H.additionalTextEdits = p.additionalTextEdits.map(toTextEdit)), p.insertTextFormat === InsertTextFormat.Snippet && (H.insertTextRules = monaco_editor_core_exports.languages.CompletionItemInsertTextRule.InsertAsSnippet), H;
|
|
1165
|
+
});
|
|
1166
|
+
return {
|
|
1167
|
+
isIncomplete: U.isIncomplete,
|
|
1168
|
+
suggestions: K
|
|
1169
|
+
};
|
|
1170
|
+
});
|
|
1171
|
+
}
|
|
1172
|
+
};
|
|
1173
|
+
function fromPosition(p) {
|
|
1174
|
+
if (p) return {
|
|
1175
|
+
character: p.column - 1,
|
|
1176
|
+
line: p.lineNumber - 1
|
|
1177
|
+
};
|
|
1178
|
+
}
|
|
1179
|
+
function fromRange(p) {
|
|
1180
|
+
if (p) return {
|
|
1181
|
+
start: {
|
|
1182
|
+
line: p.startLineNumber - 1,
|
|
1183
|
+
character: p.startColumn - 1
|
|
1184
|
+
},
|
|
1185
|
+
end: {
|
|
1186
|
+
line: p.endLineNumber - 1,
|
|
1187
|
+
character: p.endColumn - 1
|
|
1188
|
+
}
|
|
1189
|
+
};
|
|
1190
|
+
}
|
|
1191
|
+
function toRange(p) {
|
|
1192
|
+
if (p) return new monaco_editor_core_exports.Range(p.start.line + 1, p.start.character + 1, p.end.line + 1, p.end.character + 1);
|
|
1193
|
+
}
|
|
1194
|
+
function isInsertReplaceEdit(p) {
|
|
1195
|
+
return p.insert !== void 0 && p.replace !== void 0;
|
|
1196
|
+
}
|
|
1197
|
+
function toCompletionItemKind(p) {
|
|
1198
|
+
let H = monaco_editor_core_exports.languages.CompletionItemKind;
|
|
1199
|
+
switch (p) {
|
|
1200
|
+
case CompletionItemKind.Text: return H.Text;
|
|
1201
|
+
case CompletionItemKind.Method: return H.Method;
|
|
1202
|
+
case CompletionItemKind.Function: return H.Function;
|
|
1203
|
+
case CompletionItemKind.Constructor: return H.Constructor;
|
|
1204
|
+
case CompletionItemKind.Field: return H.Field;
|
|
1205
|
+
case CompletionItemKind.Variable: return H.Variable;
|
|
1206
|
+
case CompletionItemKind.Class: return H.Class;
|
|
1207
|
+
case CompletionItemKind.Interface: return H.Interface;
|
|
1208
|
+
case CompletionItemKind.Module: return H.Module;
|
|
1209
|
+
case CompletionItemKind.Property: return H.Property;
|
|
1210
|
+
case CompletionItemKind.Unit: return H.Unit;
|
|
1211
|
+
case CompletionItemKind.Value: return H.Value;
|
|
1212
|
+
case CompletionItemKind.Enum: return H.Enum;
|
|
1213
|
+
case CompletionItemKind.Keyword: return H.Keyword;
|
|
1214
|
+
case CompletionItemKind.Snippet: return H.Snippet;
|
|
1215
|
+
case CompletionItemKind.Color: return H.Color;
|
|
1216
|
+
case CompletionItemKind.File: return H.File;
|
|
1217
|
+
case CompletionItemKind.Reference: return H.Reference;
|
|
1218
|
+
}
|
|
1219
|
+
return H.Property;
|
|
1220
|
+
}
|
|
1221
|
+
function toTextEdit(p) {
|
|
1222
|
+
if (p) return {
|
|
1223
|
+
range: toRange(p.range),
|
|
1224
|
+
text: p.newText
|
|
1225
|
+
};
|
|
1226
|
+
}
|
|
1227
|
+
function toCommand(p) {
|
|
1228
|
+
return p && p.command === "editor.action.triggerSuggest" ? {
|
|
1229
|
+
id: p.command,
|
|
1230
|
+
title: p.title,
|
|
1231
|
+
arguments: p.arguments
|
|
1232
|
+
} : void 0;
|
|
1233
|
+
}
|
|
1234
|
+
var HoverAdapter = class {
|
|
1235
|
+
constructor(p) {
|
|
1236
|
+
this._worker = p;
|
|
1237
|
+
}
|
|
1238
|
+
provideHover(p, H, U) {
|
|
1239
|
+
let W = p.uri;
|
|
1240
|
+
return this._worker(W).then((p) => p.doHover(W.toString(), fromPosition(H))).then((p) => {
|
|
1241
|
+
if (p) return {
|
|
1242
|
+
range: toRange(p.range),
|
|
1243
|
+
contents: toMarkedStringArray(p.contents)
|
|
1244
|
+
};
|
|
1245
|
+
});
|
|
1246
|
+
}
|
|
1247
|
+
};
|
|
1248
|
+
function isMarkupContent(p) {
|
|
1249
|
+
return p && typeof p == "object" && typeof p.kind == "string";
|
|
1250
|
+
}
|
|
1251
|
+
function toMarkdownString(p) {
|
|
1252
|
+
return typeof p == "string" ? { value: p } : isMarkupContent(p) ? p.kind === "plaintext" ? { value: p.value.replace(/[\\`*_{}[\]()#+\-.!]/g, "\\$&") } : { value: p.value } : { value: "```" + p.language + "\n" + p.value + "\n```\n" };
|
|
1253
|
+
}
|
|
1254
|
+
function toMarkedStringArray(p) {
|
|
1255
|
+
if (p) return Array.isArray(p) ? p.map(toMarkdownString) : [toMarkdownString(p)];
|
|
1256
|
+
}
|
|
1257
|
+
var DocumentHighlightAdapter = class {
|
|
1258
|
+
constructor(p) {
|
|
1259
|
+
this._worker = p;
|
|
1260
|
+
}
|
|
1261
|
+
provideDocumentHighlights(p, H, U) {
|
|
1262
|
+
let W = p.uri;
|
|
1263
|
+
return this._worker(W).then((p) => p.findDocumentHighlights(W.toString(), fromPosition(H))).then((p) => {
|
|
1264
|
+
if (p) return p.map((p) => ({
|
|
1265
|
+
range: toRange(p.range),
|
|
1266
|
+
kind: toDocumentHighlightKind(p.kind)
|
|
1267
|
+
}));
|
|
1268
|
+
});
|
|
1269
|
+
}
|
|
1270
|
+
};
|
|
1271
|
+
function toDocumentHighlightKind(p) {
|
|
1272
|
+
switch (p) {
|
|
1273
|
+
case DocumentHighlightKind.Read: return monaco_editor_core_exports.languages.DocumentHighlightKind.Read;
|
|
1274
|
+
case DocumentHighlightKind.Write: return monaco_editor_core_exports.languages.DocumentHighlightKind.Write;
|
|
1275
|
+
case DocumentHighlightKind.Text: return monaco_editor_core_exports.languages.DocumentHighlightKind.Text;
|
|
1276
|
+
}
|
|
1277
|
+
return monaco_editor_core_exports.languages.DocumentHighlightKind.Text;
|
|
1278
|
+
}
|
|
1279
|
+
var DefinitionAdapter = class {
|
|
1280
|
+
constructor(p) {
|
|
1281
|
+
this._worker = p;
|
|
1282
|
+
}
|
|
1283
|
+
provideDefinition(p, H, U) {
|
|
1284
|
+
let W = p.uri;
|
|
1285
|
+
return this._worker(W).then((p) => p.findDefinition(W.toString(), fromPosition(H))).then((p) => {
|
|
1286
|
+
if (p) return [toLocation(p)];
|
|
1287
|
+
});
|
|
1288
|
+
}
|
|
1289
|
+
};
|
|
1290
|
+
function toLocation(p) {
|
|
1291
|
+
return {
|
|
1292
|
+
uri: monaco_editor_core_exports.Uri.parse(p.uri),
|
|
1293
|
+
range: toRange(p.range)
|
|
1294
|
+
};
|
|
1295
|
+
}
|
|
1296
|
+
var ReferenceAdapter = class {
|
|
1297
|
+
constructor(p) {
|
|
1298
|
+
this._worker = p;
|
|
1299
|
+
}
|
|
1300
|
+
provideReferences(p, H, U, W) {
|
|
1301
|
+
let G = p.uri;
|
|
1302
|
+
return this._worker(G).then((p) => p.findReferences(G.toString(), fromPosition(H))).then((p) => {
|
|
1303
|
+
if (p) return p.map(toLocation);
|
|
1304
|
+
});
|
|
1305
|
+
}
|
|
1306
|
+
}, RenameAdapter = class {
|
|
1307
|
+
constructor(p) {
|
|
1308
|
+
this._worker = p;
|
|
1309
|
+
}
|
|
1310
|
+
provideRenameEdits(p, H, U, W) {
|
|
1311
|
+
let G = p.uri;
|
|
1312
|
+
return this._worker(G).then((p) => p.doRename(G.toString(), fromPosition(H), U)).then((p) => toWorkspaceEdit(p));
|
|
1313
|
+
}
|
|
1314
|
+
};
|
|
1315
|
+
function toWorkspaceEdit(p) {
|
|
1316
|
+
if (!p || !p.changes) return;
|
|
1317
|
+
let H = [];
|
|
1318
|
+
for (let U in p.changes) {
|
|
1319
|
+
let W = monaco_editor_core_exports.Uri.parse(U);
|
|
1320
|
+
for (let G of p.changes[U]) H.push({
|
|
1321
|
+
resource: W,
|
|
1322
|
+
versionId: void 0,
|
|
1323
|
+
textEdit: {
|
|
1324
|
+
range: toRange(G.range),
|
|
1325
|
+
text: G.newText
|
|
1326
|
+
}
|
|
1327
|
+
});
|
|
1328
|
+
}
|
|
1329
|
+
return { edits: H };
|
|
1330
|
+
}
|
|
1331
|
+
var DocumentSymbolAdapter = class {
|
|
1332
|
+
constructor(p) {
|
|
1333
|
+
this._worker = p;
|
|
1334
|
+
}
|
|
1335
|
+
provideDocumentSymbols(p, H) {
|
|
1336
|
+
let U = p.uri;
|
|
1337
|
+
return this._worker(U).then((p) => p.findDocumentSymbols(U.toString())).then((p) => {
|
|
1338
|
+
if (p) return p.map((p) => isDocumentSymbol(p) ? toDocumentSymbol(p) : {
|
|
1339
|
+
name: p.name,
|
|
1340
|
+
detail: "",
|
|
1341
|
+
containerName: p.containerName,
|
|
1342
|
+
kind: toSymbolKind(p.kind),
|
|
1343
|
+
range: toRange(p.location.range),
|
|
1344
|
+
selectionRange: toRange(p.location.range),
|
|
1345
|
+
tags: []
|
|
1346
|
+
});
|
|
1347
|
+
});
|
|
1348
|
+
}
|
|
1349
|
+
};
|
|
1350
|
+
function isDocumentSymbol(p) {
|
|
1351
|
+
return "children" in p;
|
|
1352
|
+
}
|
|
1353
|
+
function toDocumentSymbol(p) {
|
|
1354
|
+
return {
|
|
1355
|
+
name: p.name,
|
|
1356
|
+
detail: p.detail ?? "",
|
|
1357
|
+
kind: toSymbolKind(p.kind),
|
|
1358
|
+
range: toRange(p.range),
|
|
1359
|
+
selectionRange: toRange(p.selectionRange),
|
|
1360
|
+
tags: p.tags ?? [],
|
|
1361
|
+
children: (p.children ?? []).map((p) => toDocumentSymbol(p))
|
|
1362
|
+
};
|
|
1363
|
+
}
|
|
1364
|
+
function toSymbolKind(p) {
|
|
1365
|
+
let H = monaco_editor_core_exports.languages.SymbolKind;
|
|
1366
|
+
switch (p) {
|
|
1367
|
+
case SymbolKind.File: return H.File;
|
|
1368
|
+
case SymbolKind.Module: return H.Module;
|
|
1369
|
+
case SymbolKind.Namespace: return H.Namespace;
|
|
1370
|
+
case SymbolKind.Package: return H.Package;
|
|
1371
|
+
case SymbolKind.Class: return H.Class;
|
|
1372
|
+
case SymbolKind.Method: return H.Method;
|
|
1373
|
+
case SymbolKind.Property: return H.Property;
|
|
1374
|
+
case SymbolKind.Field: return H.Field;
|
|
1375
|
+
case SymbolKind.Constructor: return H.Constructor;
|
|
1376
|
+
case SymbolKind.Enum: return H.Enum;
|
|
1377
|
+
case SymbolKind.Interface: return H.Interface;
|
|
1378
|
+
case SymbolKind.Function: return H.Function;
|
|
1379
|
+
case SymbolKind.Variable: return H.Variable;
|
|
1380
|
+
case SymbolKind.Constant: return H.Constant;
|
|
1381
|
+
case SymbolKind.String: return H.String;
|
|
1382
|
+
case SymbolKind.Number: return H.Number;
|
|
1383
|
+
case SymbolKind.Boolean: return H.Boolean;
|
|
1384
|
+
case SymbolKind.Array: return H.Array;
|
|
1385
|
+
}
|
|
1386
|
+
return H.Function;
|
|
1387
|
+
}
|
|
1388
|
+
var DocumentLinkAdapter = class {
|
|
1389
|
+
constructor(p) {
|
|
1390
|
+
this._worker = p;
|
|
1391
|
+
}
|
|
1392
|
+
provideLinks(p, H) {
|
|
1393
|
+
let U = p.uri;
|
|
1394
|
+
return this._worker(U).then((p) => p.findDocumentLinks(U.toString())).then((p) => {
|
|
1395
|
+
if (p) return { links: p.map((p) => ({
|
|
1396
|
+
range: toRange(p.range),
|
|
1397
|
+
url: p.target
|
|
1398
|
+
})) };
|
|
1399
|
+
});
|
|
1400
|
+
}
|
|
1401
|
+
}, DocumentFormattingEditProvider = class {
|
|
1402
|
+
constructor(p) {
|
|
1403
|
+
this._worker = p;
|
|
1404
|
+
}
|
|
1405
|
+
provideDocumentFormattingEdits(p, H, U) {
|
|
1406
|
+
let W = p.uri;
|
|
1407
|
+
return this._worker(W).then((p) => p.format(W.toString(), null, fromFormattingOptions(H)).then((p) => {
|
|
1408
|
+
if (!(!p || p.length === 0)) return p.map(toTextEdit);
|
|
1409
|
+
}));
|
|
1410
|
+
}
|
|
1411
|
+
}, DocumentRangeFormattingEditProvider = class {
|
|
1412
|
+
constructor(p) {
|
|
1413
|
+
this._worker = p, this.canFormatMultipleRanges = !1;
|
|
1414
|
+
}
|
|
1415
|
+
provideDocumentRangeFormattingEdits(p, H, U, W) {
|
|
1416
|
+
let G = p.uri;
|
|
1417
|
+
return this._worker(G).then((p) => p.format(G.toString(), fromRange(H), fromFormattingOptions(U)).then((p) => {
|
|
1418
|
+
if (!(!p || p.length === 0)) return p.map(toTextEdit);
|
|
1419
|
+
}));
|
|
1420
|
+
}
|
|
1421
|
+
};
|
|
1422
|
+
function fromFormattingOptions(p) {
|
|
1423
|
+
return {
|
|
1424
|
+
tabSize: p.tabSize,
|
|
1425
|
+
insertSpaces: p.insertSpaces
|
|
1426
|
+
};
|
|
1427
|
+
}
|
|
1428
|
+
var DocumentColorAdapter = class {
|
|
1429
|
+
constructor(p) {
|
|
1430
|
+
this._worker = p;
|
|
1431
|
+
}
|
|
1432
|
+
provideDocumentColors(p, H) {
|
|
1433
|
+
let U = p.uri;
|
|
1434
|
+
return this._worker(U).then((p) => p.findDocumentColors(U.toString())).then((p) => {
|
|
1435
|
+
if (p) return p.map((p) => ({
|
|
1436
|
+
color: p.color,
|
|
1437
|
+
range: toRange(p.range)
|
|
1438
|
+
}));
|
|
1439
|
+
});
|
|
1440
|
+
}
|
|
1441
|
+
provideColorPresentations(p, H, U) {
|
|
1442
|
+
let W = p.uri;
|
|
1443
|
+
return this._worker(W).then((p) => p.getColorPresentations(W.toString(), H.color, fromRange(H.range))).then((p) => {
|
|
1444
|
+
if (p) return p.map((p) => {
|
|
1445
|
+
let H = { label: p.label };
|
|
1446
|
+
return p.textEdit && (H.textEdit = toTextEdit(p.textEdit)), p.additionalTextEdits && (H.additionalTextEdits = p.additionalTextEdits.map(toTextEdit)), H;
|
|
1447
|
+
});
|
|
1448
|
+
});
|
|
1449
|
+
}
|
|
1450
|
+
}, FoldingRangeAdapter = class {
|
|
1451
|
+
constructor(p) {
|
|
1452
|
+
this._worker = p;
|
|
1453
|
+
}
|
|
1454
|
+
provideFoldingRanges(p, H, U) {
|
|
1455
|
+
let W = p.uri;
|
|
1456
|
+
return this._worker(W).then((p) => p.getFoldingRanges(W.toString(), H)).then((p) => {
|
|
1457
|
+
if (p) return p.map((p) => {
|
|
1458
|
+
let H = {
|
|
1459
|
+
start: p.startLine + 1,
|
|
1460
|
+
end: p.endLine + 1
|
|
1461
|
+
};
|
|
1462
|
+
return p.kind !== void 0 && (H.kind = toFoldingRangeKind(p.kind)), H;
|
|
1463
|
+
});
|
|
1464
|
+
});
|
|
1465
|
+
}
|
|
1466
|
+
};
|
|
1467
|
+
function toFoldingRangeKind(p) {
|
|
1468
|
+
switch (p) {
|
|
1469
|
+
case FoldingRangeKind.Comment: return monaco_editor_core_exports.languages.FoldingRangeKind.Comment;
|
|
1470
|
+
case FoldingRangeKind.Imports: return monaco_editor_core_exports.languages.FoldingRangeKind.Imports;
|
|
1471
|
+
case FoldingRangeKind.Region: return monaco_editor_core_exports.languages.FoldingRangeKind.Region;
|
|
1472
|
+
}
|
|
1473
|
+
}
|
|
1474
|
+
var SelectionRangeAdapter = class {
|
|
1475
|
+
constructor(p) {
|
|
1476
|
+
this._worker = p;
|
|
1477
|
+
}
|
|
1478
|
+
provideSelectionRanges(p, H, U) {
|
|
1479
|
+
let W = p.uri;
|
|
1480
|
+
return this._worker(W).then((p) => p.getSelectionRanges(W.toString(), H.map(fromPosition))).then((p) => {
|
|
1481
|
+
if (p) return p.map((p) => {
|
|
1482
|
+
let H = [];
|
|
1483
|
+
for (; p;) H.push({ range: toRange(p.range) }), p = p.parent;
|
|
1484
|
+
return H;
|
|
1485
|
+
});
|
|
1486
|
+
});
|
|
1487
|
+
}
|
|
1488
|
+
}, HTMLCompletionAdapter = class extends CompletionAdapter {
|
|
1489
|
+
constructor(p) {
|
|
1490
|
+
super(p, [
|
|
1491
|
+
".",
|
|
1492
|
+
":",
|
|
1493
|
+
"<",
|
|
1494
|
+
"\"",
|
|
1495
|
+
"=",
|
|
1496
|
+
"/"
|
|
1497
|
+
]);
|
|
1498
|
+
}
|
|
1499
|
+
};
|
|
1500
|
+
function setupMode1(p) {
|
|
1501
|
+
let H = new WorkerManager(p), U = (...p) => H.getLanguageServiceWorker(...p), W = p.languageId;
|
|
1502
|
+
monaco_editor_core_exports.languages.registerCompletionItemProvider(W, new HTMLCompletionAdapter(U)), monaco_editor_core_exports.languages.registerHoverProvider(W, new HoverAdapter(U)), monaco_editor_core_exports.languages.registerDocumentHighlightProvider(W, new DocumentHighlightAdapter(U)), monaco_editor_core_exports.languages.registerLinkProvider(W, new DocumentLinkAdapter(U)), monaco_editor_core_exports.languages.registerFoldingRangeProvider(W, new FoldingRangeAdapter(U)), monaco_editor_core_exports.languages.registerDocumentSymbolProvider(W, new DocumentSymbolAdapter(U)), monaco_editor_core_exports.languages.registerSelectionRangeProvider(W, new SelectionRangeAdapter(U)), monaco_editor_core_exports.languages.registerRenameProvider(W, new RenameAdapter(U)), W === "html" && (monaco_editor_core_exports.languages.registerDocumentFormattingEditProvider(W, new DocumentFormattingEditProvider(U)), monaco_editor_core_exports.languages.registerDocumentRangeFormattingEditProvider(W, new DocumentRangeFormattingEditProvider(U)));
|
|
1503
|
+
}
|
|
1504
|
+
function setupMode(p) {
|
|
1505
|
+
let H = [], U = [], W = new WorkerManager(p);
|
|
1506
|
+
H.push(W);
|
|
1507
|
+
let G = (...p) => W.getLanguageServiceWorker(...p);
|
|
1508
|
+
function K() {
|
|
1509
|
+
let { languageId: H, modeConfiguration: W } = p;
|
|
1510
|
+
disposeAll(U), W.completionItems && U.push(monaco_editor_core_exports.languages.registerCompletionItemProvider(H, new HTMLCompletionAdapter(G))), W.hovers && U.push(monaco_editor_core_exports.languages.registerHoverProvider(H, new HoverAdapter(G))), W.documentHighlights && U.push(monaco_editor_core_exports.languages.registerDocumentHighlightProvider(H, new DocumentHighlightAdapter(G))), W.links && U.push(monaco_editor_core_exports.languages.registerLinkProvider(H, new DocumentLinkAdapter(G))), W.documentSymbols && U.push(monaco_editor_core_exports.languages.registerDocumentSymbolProvider(H, new DocumentSymbolAdapter(G))), W.rename && U.push(monaco_editor_core_exports.languages.registerRenameProvider(H, new RenameAdapter(G))), W.foldingRanges && U.push(monaco_editor_core_exports.languages.registerFoldingRangeProvider(H, new FoldingRangeAdapter(G))), W.selectionRanges && U.push(monaco_editor_core_exports.languages.registerSelectionRangeProvider(H, new SelectionRangeAdapter(G))), W.documentFormattingEdits && U.push(monaco_editor_core_exports.languages.registerDocumentFormattingEditProvider(H, new DocumentFormattingEditProvider(G))), W.documentRangeFormattingEdits && U.push(monaco_editor_core_exports.languages.registerDocumentRangeFormattingEditProvider(H, new DocumentRangeFormattingEditProvider(G)));
|
|
1511
|
+
}
|
|
1512
|
+
return K(), H.push(asDisposable(U)), asDisposable(H);
|
|
1513
|
+
}
|
|
1514
|
+
function asDisposable(p) {
|
|
1515
|
+
return { dispose: () => disposeAll(p) };
|
|
1516
|
+
}
|
|
1517
|
+
function disposeAll(p) {
|
|
1518
|
+
for (; p.length;) p.pop().dispose();
|
|
1519
|
+
}
|
|
1520
|
+
export { CompletionAdapter, DefinitionAdapter, DiagnosticsAdapter, DocumentColorAdapter, DocumentFormattingEditProvider, DocumentHighlightAdapter, DocumentLinkAdapter, DocumentRangeFormattingEditProvider, DocumentSymbolAdapter, FoldingRangeAdapter, HoverAdapter, ReferenceAdapter, RenameAdapter, SelectionRangeAdapter, WorkerManager, fromPosition, fromRange, setupMode, setupMode1, toRange, toTextEdit };
|