sun-form-v3 1.0.70 → 1.0.72

Sign up to get free protection for your applications and to get access to all the features.
Files changed (157) hide show
  1. package/dist/abap-DfvySaIJ.js +1404 -0
  2. package/dist/apex-B__0irD3.js +332 -0
  3. package/dist/assets/css.worker-OK053IOu.js +84 -0
  4. package/dist/assets/editor.worker-D9iUZyMP.js +11 -0
  5. package/dist/assets/html.worker-CL40hqKM.js +458 -0
  6. package/dist/assets/json.worker-6f9bhSHY.js +42 -0
  7. package/dist/assets/ts.worker-B6g3wjaE.js +37021 -0
  8. package/dist/azcli-CDMGhRmx.js +74 -0
  9. package/dist/bat-0Mk8aqzx.js +106 -0
  10. package/dist/bicep-BBi_I06Z.js +108 -0
  11. package/dist/cameligo-D0G_Zm6X.js +180 -0
  12. package/dist/clojure-o2ZKLeMp.js +767 -0
  13. package/dist/coffee-DOQff5VC.js +238 -0
  14. package/dist/cpp-CQGJnWhD.js +395 -0
  15. package/dist/csharp-C1jLsHl8.js +332 -0
  16. package/dist/csp-C_ttMQaW.js +59 -0
  17. package/dist/css-BC202kVV.js +193 -0
  18. package/dist/cssMode-D3INtz5D.js +1541 -0
  19. package/dist/cypher-DwtEH7Fi.js +269 -0
  20. package/dist/dart-D9XknsP2.js +287 -0
  21. package/dist/dockerfile-DgsNjqqa.js +136 -0
  22. package/dist/ecl-BAMCHBl6.js +462 -0
  23. package/dist/elixir-CegIttP8.js +575 -0
  24. package/dist/favicon.ico +0 -0
  25. package/dist/flow9-9608t7UV.js +148 -0
  26. package/dist/freemarker2-hasIzj0A.js +995 -0
  27. package/dist/fsharp-CCtt9-1_.js +223 -0
  28. package/dist/go-CGUIPbct.js +224 -0
  29. package/dist/graphql-BNRIFFIn.js +157 -0
  30. package/dist/handlebars-Cqza9dif.js +425 -0
  31. package/dist/hcl-C__KLIXe.js +189 -0
  32. package/dist/html-QpDlLWtS.js +314 -0
  33. package/dist/htmlMode-3p93KT8l.js +1551 -0
  34. package/dist/index2-jkDcibEo.js +120443 -0
  35. package/dist/ini-CeKYn_zA.js +77 -0
  36. package/dist/java-Dm24deQl.js +238 -0
  37. package/dist/javascript-CSPB5Brm.js +76 -0
  38. package/dist/jsonMode-qA6pURD0.js +1957 -0
  39. package/dist/julia-BImNW7VE.js +517 -0
  40. package/dist/kotlin-BfE79GEb.js +259 -0
  41. package/dist/less-DglNOcaC.js +168 -0
  42. package/dist/lexon-BA0dRz9Q.js +163 -0
  43. package/dist/liquid-BWuASSim.js +246 -0
  44. package/dist/lua-DMkWzJcm.js +168 -0
  45. package/dist/m3-sA-5shO8.js +216 -0
  46. package/dist/markdown-OYRB1igA.js +235 -0
  47. package/dist/mdx-CnHJXO9F.js +171 -0
  48. package/dist/mips-rRzkJ_7G.js +204 -0
  49. package/dist/msdax-DoVJdUhd.js +381 -0
  50. package/dist/mysql-Ty44IHXo.js +884 -0
  51. package/dist/objective-c-VUfyhYrA.js +189 -0
  52. package/dist/pascal-DkASiYyw.js +257 -0
  53. package/dist/pascaligo-p-ELPlVO.js +170 -0
  54. package/dist/perl-Cjl1FxLZ.js +632 -0
  55. package/dist/pgsql-DjVenF7s.js +857 -0
  56. package/dist/php-CwvGzZOO.js +506 -0
  57. package/dist/pla-Br1iaBIV.js +143 -0
  58. package/dist/postiats-BaeP8zZY.js +913 -0
  59. package/dist/powerquery-CLCshuo8.js +896 -0
  60. package/dist/powershell-CZV50w5N.js +245 -0
  61. package/dist/protobuf-MV3XTewJ.js +426 -0
  62. package/dist/pug-DkDg4c4l.js +408 -0
  63. package/dist/python-CRYsEVap.js +282 -0
  64. package/dist/qsharp-BAtiKA97.js +291 -0
  65. package/dist/r-8ocrd-h-.js +249 -0
  66. package/dist/razor-DyEtGntt.js +556 -0
  67. package/dist/redis-9sZiddxc.js +308 -0
  68. package/dist/redshift-DQfTOGC0.js +815 -0
  69. package/dist/restructuredtext-DXU-vkgr.js +180 -0
  70. package/dist/ruby-DotfqwMf.js +517 -0
  71. package/dist/rust-BIauJ5KN.js +349 -0
  72. package/dist/sb-CmWMvDEV.js +121 -0
  73. package/dist/scala-C81brEbk.js +376 -0
  74. package/dist/scheme-D0pcFz2x.js +114 -0
  75. package/dist/scss-BOdN2fGG.js +268 -0
  76. package/dist/shell-6E09eAkU.js +227 -0
  77. package/dist/solidity-CWStzA1K.js +1373 -0
  78. package/dist/sophia-76Sb6CWe.js +205 -0
  79. package/dist/sparql-BmZTkOWT.js +207 -0
  80. package/dist/sql-Cs9TBAW5.js +859 -0
  81. package/dist/st-B-rqE1Bu.js +422 -0
  82. package/dist/style.css +1 -0
  83. package/dist/sun-form-v3.es.js +4 -0
  84. package/dist/sun-form-v3.umd.js +1902 -0
  85. package/dist/swift-Btsj6YxQ.js +318 -0
  86. package/dist/systemverilog-B3RHBRa2.js +582 -0
  87. package/dist/tcl-Dpj776pn.js +238 -0
  88. package/dist/tsMode-BrlIPEQw.js +885 -0
  89. package/dist/twig-Bb9JmBsE.js +398 -0
  90. package/dist/typescript-CYTudnTM.js +349 -0
  91. package/dist/typespec-CDWeg3SU.js +123 -0
  92. package/dist/vb-DEXnYwEI.js +378 -0
  93. package/dist/wgsl-D602c1lx.js +445 -0
  94. package/dist/xml-B-x5164u.js +101 -0
  95. package/dist/yaml-Buq2hM65.js +212 -0
  96. package/package.json +5 -8
  97. package/src/App.vue +0 -9
  98. package/src/assets/font/YouSheBiaoTiHei-2.ttf +0 -0
  99. package/src/assets/font/demo.css +0 -539
  100. package/src/assets/font/demo_index.html +0 -1200
  101. package/src/assets/font/iconfont.css +0 -191
  102. package/src/assets/font/iconfont.js +0 -1
  103. package/src/assets/font/iconfont.json +0 -317
  104. package/src/assets/font/iconfont.ttf +0 -0
  105. package/src/assets/font/iconfont.woff +0 -0
  106. package/src/assets/font/iconfont.woff2 +0 -0
  107. package/src/assets/img/bg_footer.png +0 -0
  108. package/src/assets/img/bg_title.png +0 -0
  109. package/src/assets/img/file.png +0 -0
  110. package/src/assets/img/logo.png +0 -0
  111. package/src/assets/img/logo2.png +0 -0
  112. package/src/assets/img/logo22.png +0 -0
  113. package/src/assets/img/logo23.png +0 -0
  114. package/src/assets/img/logo3.png +0 -0
  115. package/src/assets/img//347/237/251/345/275/242@2x.png +0 -0
  116. package/src/assets/logo.svg +0 -1
  117. package/src/assets/styles/element/index.scss +0 -15
  118. package/src/assets/styles/index.css +0 -3
  119. package/src/components/a.js +0 -14
  120. package/src/components/aDesigner/config.vue +0 -127
  121. package/src/components/aDesigner/design.vue +0 -20
  122. package/src/components/aDesigner/designer.js +0 -342
  123. package/src/components/aDesigner/http.js +0 -292
  124. package/src/components/aDesigner/index.vue +0 -144
  125. package/src/components/aDesigner/panel.vue +0 -144
  126. package/src/components/aDesigner/show.vue +0 -24
  127. package/src/components/widgetCommonComps/commonApiConfig/index.vue +0 -194
  128. package/src/components/widgetCommonComps/commonCard/index.vue +0 -36
  129. package/src/components/widgetCommonComps/commonCodeEditor/editor.vue +0 -219
  130. package/src/components/widgetCommonComps/commonCodeEditor/modalEditor.vue +0 -68
  131. package/src/components/widgetCommonComps/commonCollapseCard/index.vue +0 -10
  132. package/src/components/widgetCommonComps/commonContainer/index.vue +0 -95
  133. package/src/components/widgetCommonComps/commonJsonInput/index.vue +0 -59
  134. package/src/components/widgetCommonComps/commonLabelContainer/index.vue +0 -39
  135. package/src/components/widgetCommonComps/commonSidetree/index.vue +0 -61
  136. package/src/components/widgetCommonComps/commonTypeInput/index.vue +0 -75
  137. package/src/components/widgetCommonComps/commonWidgetLabelContainer/index.vue +0 -55
  138. package/src/components/widgetCommonComps/index copy.js +0 -17
  139. package/src/components/widgetCommonComps/index.js +0 -17
  140. package/src/components/widgetConfigComps/config-input/index.vue +0 -60
  141. package/src/components/widgetConfigComps/index copy.js +0 -13
  142. package/src/components/widgetConfigComps/index.js +0 -17
  143. package/src/components/widgetShowComps/index.js +0 -29
  144. package/src/components/widgetShowComps/widget-form/index.vue +0 -43
  145. package/src/components/widgetShowComps/widget-homepage/index.vue +0 -41
  146. package/src/components/widgetShowComps/widget-input/index.vue +0 -85
  147. package/src/components/widgetShowComps/widget-select/index.vue +0 -31
  148. package/src/designer.js +0 -342
  149. package/src/http.js +0 -293
  150. package/src/index.js +0 -24
  151. package/src/index2.js +0 -23
  152. package/src/main.js +0 -19
  153. package/src/remark.js +0 -708
  154. package/src/testBtn.vue +0 -11
  155. package/src/testInput.vue +0 -12
  156. package/src/util/jsformat.js +0 -568
  157. package/src/widgetConfig.js +0 -1112
@@ -0,0 +1,1957 @@
1
+ import { m as Ke } from "./index2-jkDcibEo.js";
2
+ /*!-----------------------------------------------------------------------------
3
+ * Copyright (c) Microsoft Corporation. All rights reserved.
4
+ * Version: 0.49.0(383fdf3fc0e1e1a024068b8d0fd4f3dcbae74d04)
5
+ * Released under the MIT license
6
+ * https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt
7
+ *-----------------------------------------------------------------------------*/
8
+ var et = Object.defineProperty, tt = Object.getOwnPropertyDescriptor, rt = Object.getOwnPropertyNames, nt = Object.prototype.hasOwnProperty, it = (e, n, i, r) => {
9
+ if (n && typeof n == "object" || typeof n == "function")
10
+ for (let t of rt(n))
11
+ !nt.call(e, t) && t !== i && et(e, t, { get: () => n[t], enumerable: !(r = tt(n, t)) || r.enumerable });
12
+ return e;
13
+ }, at = (e, n, i) => (it(e, n, "default"), i), f = {};
14
+ at(f, Ke);
15
+ var st = 2 * 60 * 1e3, ot = class {
16
+ constructor(e) {
17
+ this._defaults = e, this._worker = null, this._client = null, this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 30 * 1e3), this._lastUsedTime = 0, this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
18
+ }
19
+ _stopWorker() {
20
+ this._worker && (this._worker.dispose(), this._worker = null), this._client = null;
21
+ }
22
+ dispose() {
23
+ clearInterval(this._idleCheckInterval), this._configChangeListener.dispose(), this._stopWorker();
24
+ }
25
+ _checkIfIdle() {
26
+ if (!this._worker)
27
+ return;
28
+ Date.now() - this._lastUsedTime > st && this._stopWorker();
29
+ }
30
+ _getClient() {
31
+ return this._lastUsedTime = Date.now(), this._client || (this._worker = f.editor.createWebWorker({
32
+ // module that exports the create() method and returns a `JSONWorker` instance
33
+ moduleId: "vs/language/json/jsonWorker",
34
+ label: this._defaults.languageId,
35
+ // passed in to the create() method
36
+ createData: {
37
+ languageSettings: this._defaults.diagnosticsOptions,
38
+ languageId: this._defaults.languageId,
39
+ enableSchemaRequest: this._defaults.diagnosticsOptions.enableSchemaRequest
40
+ }
41
+ }), this._client = this._worker.getProxy()), this._client;
42
+ }
43
+ getLanguageServiceWorker(...e) {
44
+ let n;
45
+ return this._getClient().then((i) => {
46
+ n = i;
47
+ }).then((i) => {
48
+ if (this._worker)
49
+ return this._worker.withSyncedResources(e);
50
+ }).then((i) => n);
51
+ }
52
+ }, oe;
53
+ (function(e) {
54
+ e.MIN_VALUE = -2147483648, e.MAX_VALUE = 2147483647;
55
+ })(oe || (oe = {}));
56
+ var Y;
57
+ (function(e) {
58
+ e.MIN_VALUE = 0, e.MAX_VALUE = 2147483647;
59
+ })(Y || (Y = {}));
60
+ var T;
61
+ (function(e) {
62
+ function n(r, t) {
63
+ return r === Number.MAX_VALUE && (r = Y.MAX_VALUE), t === Number.MAX_VALUE && (t = Y.MAX_VALUE), { line: r, character: t };
64
+ }
65
+ e.create = n;
66
+ function i(r) {
67
+ var t = r;
68
+ return o.objectLiteral(t) && o.uinteger(t.line) && o.uinteger(t.character);
69
+ }
70
+ e.is = i;
71
+ })(T || (T = {}));
72
+ var _;
73
+ (function(e) {
74
+ function n(r, t, a, s) {
75
+ if (o.uinteger(r) && o.uinteger(t) && o.uinteger(a) && o.uinteger(s))
76
+ return { start: T.create(r, t), end: T.create(a, s) };
77
+ if (T.is(r) && T.is(t))
78
+ return { start: r, end: t };
79
+ throw new Error("Range#create called with invalid arguments[" + r + ", " + t + ", " + a + ", " + s + "]");
80
+ }
81
+ e.create = n;
82
+ function i(r) {
83
+ var t = r;
84
+ return o.objectLiteral(t) && T.is(t.start) && T.is(t.end);
85
+ }
86
+ e.is = i;
87
+ })(_ || (_ = {}));
88
+ var ee;
89
+ (function(e) {
90
+ function n(r, t) {
91
+ return { uri: r, range: t };
92
+ }
93
+ e.create = n;
94
+ function i(r) {
95
+ var t = r;
96
+ return o.defined(t) && _.is(t.range) && (o.string(t.uri) || o.undefined(t.uri));
97
+ }
98
+ e.is = i;
99
+ })(ee || (ee = {}));
100
+ var ue;
101
+ (function(e) {
102
+ function n(r, t, a, s) {
103
+ return { targetUri: r, targetRange: t, targetSelectionRange: a, originSelectionRange: s };
104
+ }
105
+ e.create = n;
106
+ function i(r) {
107
+ var t = r;
108
+ return o.defined(t) && _.is(t.targetRange) && o.string(t.targetUri) && (_.is(t.targetSelectionRange) || o.undefined(t.targetSelectionRange)) && (_.is(t.originSelectionRange) || o.undefined(t.originSelectionRange));
109
+ }
110
+ e.is = i;
111
+ })(ue || (ue = {}));
112
+ var te;
113
+ (function(e) {
114
+ function n(r, t, a, s) {
115
+ return {
116
+ red: r,
117
+ green: t,
118
+ blue: a,
119
+ alpha: s
120
+ };
121
+ }
122
+ e.create = n;
123
+ function i(r) {
124
+ var t = r;
125
+ return o.numberRange(t.red, 0, 1) && o.numberRange(t.green, 0, 1) && o.numberRange(t.blue, 0, 1) && o.numberRange(t.alpha, 0, 1);
126
+ }
127
+ e.is = i;
128
+ })(te || (te = {}));
129
+ var ce;
130
+ (function(e) {
131
+ function n(r, t) {
132
+ return {
133
+ range: r,
134
+ color: t
135
+ };
136
+ }
137
+ e.create = n;
138
+ function i(r) {
139
+ var t = r;
140
+ return _.is(t.range) && te.is(t.color);
141
+ }
142
+ e.is = i;
143
+ })(ce || (ce = {}));
144
+ var de;
145
+ (function(e) {
146
+ function n(r, t, a) {
147
+ return {
148
+ label: r,
149
+ textEdit: t,
150
+ additionalTextEdits: a
151
+ };
152
+ }
153
+ e.create = n;
154
+ function i(r) {
155
+ var t = r;
156
+ return o.string(t.label) && (o.undefined(t.textEdit) || R.is(t)) && (o.undefined(t.additionalTextEdits) || o.typedArray(t.additionalTextEdits, R.is));
157
+ }
158
+ e.is = i;
159
+ })(de || (de = {}));
160
+ var W;
161
+ (function(e) {
162
+ e.Comment = "comment", e.Imports = "imports", e.Region = "region";
163
+ })(W || (W = {}));
164
+ var fe;
165
+ (function(e) {
166
+ function n(r, t, a, s, u) {
167
+ var l = {
168
+ startLine: r,
169
+ endLine: t
170
+ };
171
+ return o.defined(a) && (l.startCharacter = a), o.defined(s) && (l.endCharacter = s), o.defined(u) && (l.kind = u), l;
172
+ }
173
+ e.create = n;
174
+ function i(r) {
175
+ var t = r;
176
+ return o.uinteger(t.startLine) && o.uinteger(t.startLine) && (o.undefined(t.startCharacter) || o.uinteger(t.startCharacter)) && (o.undefined(t.endCharacter) || o.uinteger(t.endCharacter)) && (o.undefined(t.kind) || o.string(t.kind));
177
+ }
178
+ e.is = i;
179
+ })(fe || (fe = {}));
180
+ var re;
181
+ (function(e) {
182
+ function n(r, t) {
183
+ return {
184
+ location: r,
185
+ message: t
186
+ };
187
+ }
188
+ e.create = n;
189
+ function i(r) {
190
+ var t = r;
191
+ return o.defined(t) && ee.is(t.location) && o.string(t.message);
192
+ }
193
+ e.is = i;
194
+ })(re || (re = {}));
195
+ var N;
196
+ (function(e) {
197
+ e.Error = 1, e.Warning = 2, e.Information = 3, e.Hint = 4;
198
+ })(N || (N = {}));
199
+ var le;
200
+ (function(e) {
201
+ e.Unnecessary = 1, e.Deprecated = 2;
202
+ })(le || (le = {}));
203
+ var ge;
204
+ (function(e) {
205
+ function n(i) {
206
+ var r = i;
207
+ return r != null && o.string(r.href);
208
+ }
209
+ e.is = n;
210
+ })(ge || (ge = {}));
211
+ var $;
212
+ (function(e) {
213
+ function n(r, t, a, s, u, l) {
214
+ var c = { range: r, message: t };
215
+ return o.defined(a) && (c.severity = a), o.defined(s) && (c.code = s), o.defined(u) && (c.source = u), o.defined(l) && (c.relatedInformation = l), c;
216
+ }
217
+ e.create = n;
218
+ function i(r) {
219
+ var t, a = r;
220
+ return o.defined(a) && _.is(a.range) && o.string(a.message) && (o.number(a.severity) || o.undefined(a.severity)) && (o.integer(a.code) || o.string(a.code) || o.undefined(a.code)) && (o.undefined(a.codeDescription) || o.string((t = a.codeDescription) === null || t === void 0 ? void 0 : t.href)) && (o.string(a.source) || o.undefined(a.source)) && (o.undefined(a.relatedInformation) || o.typedArray(a.relatedInformation, re.is));
221
+ }
222
+ e.is = i;
223
+ })($ || ($ = {}));
224
+ var V;
225
+ (function(e) {
226
+ function n(r, t) {
227
+ for (var a = [], s = 2; s < arguments.length; s++)
228
+ a[s - 2] = arguments[s];
229
+ var u = { title: r, command: t };
230
+ return o.defined(a) && a.length > 0 && (u.arguments = a), u;
231
+ }
232
+ e.create = n;
233
+ function i(r) {
234
+ var t = r;
235
+ return o.defined(t) && o.string(t.title) && o.string(t.command);
236
+ }
237
+ e.is = i;
238
+ })(V || (V = {}));
239
+ var R;
240
+ (function(e) {
241
+ function n(a, s) {
242
+ return { range: a, newText: s };
243
+ }
244
+ e.replace = n;
245
+ function i(a, s) {
246
+ return { range: { start: a, end: a }, newText: s };
247
+ }
248
+ e.insert = i;
249
+ function r(a) {
250
+ return { range: a, newText: "" };
251
+ }
252
+ e.del = r;
253
+ function t(a) {
254
+ var s = a;
255
+ return o.objectLiteral(s) && o.string(s.newText) && _.is(s.range);
256
+ }
257
+ e.is = t;
258
+ })(R || (R = {}));
259
+ var O;
260
+ (function(e) {
261
+ function n(r, t, a) {
262
+ var s = { label: r };
263
+ return t !== void 0 && (s.needsConfirmation = t), a !== void 0 && (s.description = a), s;
264
+ }
265
+ e.create = n;
266
+ function i(r) {
267
+ var t = r;
268
+ return t !== void 0 && o.objectLiteral(t) && o.string(t.label) && (o.boolean(t.needsConfirmation) || t.needsConfirmation === void 0) && (o.string(t.description) || t.description === void 0);
269
+ }
270
+ e.is = i;
271
+ })(O || (O = {}));
272
+ var w;
273
+ (function(e) {
274
+ function n(i) {
275
+ var r = i;
276
+ return typeof r == "string";
277
+ }
278
+ e.is = n;
279
+ })(w || (w = {}));
280
+ var P;
281
+ (function(e) {
282
+ function n(a, s, u) {
283
+ return { range: a, newText: s, annotationId: u };
284
+ }
285
+ e.replace = n;
286
+ function i(a, s, u) {
287
+ return { range: { start: a, end: a }, newText: s, annotationId: u };
288
+ }
289
+ e.insert = i;
290
+ function r(a, s) {
291
+ return { range: a, newText: "", annotationId: s };
292
+ }
293
+ e.del = r;
294
+ function t(a) {
295
+ var s = a;
296
+ return R.is(s) && (O.is(s.annotationId) || w.is(s.annotationId));
297
+ }
298
+ e.is = t;
299
+ })(P || (P = {}));
300
+ var G;
301
+ (function(e) {
302
+ function n(r, t) {
303
+ return { textDocument: r, edits: t };
304
+ }
305
+ e.create = n;
306
+ function i(r) {
307
+ var t = r;
308
+ return o.defined(t) && Q.is(t.textDocument) && Array.isArray(t.edits);
309
+ }
310
+ e.is = i;
311
+ })(G || (G = {}));
312
+ var H;
313
+ (function(e) {
314
+ function n(r, t, a) {
315
+ var s = {
316
+ kind: "create",
317
+ uri: r
318
+ };
319
+ return t !== void 0 && (t.overwrite !== void 0 || t.ignoreIfExists !== void 0) && (s.options = t), a !== void 0 && (s.annotationId = a), s;
320
+ }
321
+ e.create = n;
322
+ function i(r) {
323
+ var t = r;
324
+ return t && t.kind === "create" && o.string(t.uri) && (t.options === void 0 || (t.options.overwrite === void 0 || o.boolean(t.options.overwrite)) && (t.options.ignoreIfExists === void 0 || o.boolean(t.options.ignoreIfExists))) && (t.annotationId === void 0 || w.is(t.annotationId));
325
+ }
326
+ e.is = i;
327
+ })(H || (H = {}));
328
+ var z;
329
+ (function(e) {
330
+ function n(r, t, a, s) {
331
+ var u = {
332
+ kind: "rename",
333
+ oldUri: r,
334
+ newUri: t
335
+ };
336
+ return a !== void 0 && (a.overwrite !== void 0 || a.ignoreIfExists !== void 0) && (u.options = a), s !== void 0 && (u.annotationId = s), u;
337
+ }
338
+ e.create = n;
339
+ function i(r) {
340
+ var t = r;
341
+ return t && t.kind === "rename" && o.string(t.oldUri) && o.string(t.newUri) && (t.options === void 0 || (t.options.overwrite === void 0 || o.boolean(t.options.overwrite)) && (t.options.ignoreIfExists === void 0 || o.boolean(t.options.ignoreIfExists))) && (t.annotationId === void 0 || w.is(t.annotationId));
342
+ }
343
+ e.is = i;
344
+ })(z || (z = {}));
345
+ var B;
346
+ (function(e) {
347
+ function n(r, t, a) {
348
+ var s = {
349
+ kind: "delete",
350
+ uri: r
351
+ };
352
+ return t !== void 0 && (t.recursive !== void 0 || t.ignoreIfNotExists !== void 0) && (s.options = t), a !== void 0 && (s.annotationId = a), s;
353
+ }
354
+ e.create = n;
355
+ function i(r) {
356
+ var t = r;
357
+ return t && t.kind === "delete" && o.string(t.uri) && (t.options === void 0 || (t.options.recursive === void 0 || o.boolean(t.options.recursive)) && (t.options.ignoreIfNotExists === void 0 || o.boolean(t.options.ignoreIfNotExists))) && (t.annotationId === void 0 || w.is(t.annotationId));
358
+ }
359
+ e.is = i;
360
+ })(B || (B = {}));
361
+ var ne;
362
+ (function(e) {
363
+ function n(i) {
364
+ var r = i;
365
+ return r && (r.changes !== void 0 || r.documentChanges !== void 0) && (r.documentChanges === void 0 || r.documentChanges.every(function(t) {
366
+ return o.string(t.kind) ? H.is(t) || z.is(t) || B.is(t) : G.is(t);
367
+ }));
368
+ }
369
+ e.is = n;
370
+ })(ne || (ne = {}));
371
+ var J = (
372
+ /** @class */
373
+ function() {
374
+ function e(n, i) {
375
+ this.edits = n, this.changeAnnotations = i;
376
+ }
377
+ return e.prototype.insert = function(n, i, r) {
378
+ var t, a;
379
+ if (r === void 0 ? t = R.insert(n, i) : w.is(r) ? (a = r, t = P.insert(n, i, r)) : (this.assertChangeAnnotations(this.changeAnnotations), a = this.changeAnnotations.manage(r), t = P.insert(n, i, a)), this.edits.push(t), a !== void 0)
380
+ return a;
381
+ }, e.prototype.replace = function(n, i, r) {
382
+ var t, a;
383
+ if (r === void 0 ? t = R.replace(n, i) : w.is(r) ? (a = r, t = P.replace(n, i, r)) : (this.assertChangeAnnotations(this.changeAnnotations), a = this.changeAnnotations.manage(r), t = P.replace(n, i, a)), this.edits.push(t), a !== void 0)
384
+ return a;
385
+ }, e.prototype.delete = function(n, i) {
386
+ var r, t;
387
+ if (i === void 0 ? r = R.del(n) : w.is(i) ? (t = i, r = P.del(n, i)) : (this.assertChangeAnnotations(this.changeAnnotations), t = this.changeAnnotations.manage(i), r = P.del(n, t)), this.edits.push(r), t !== void 0)
388
+ return t;
389
+ }, e.prototype.add = function(n) {
390
+ this.edits.push(n);
391
+ }, e.prototype.all = function() {
392
+ return this.edits;
393
+ }, e.prototype.clear = function() {
394
+ this.edits.splice(0, this.edits.length);
395
+ }, e.prototype.assertChangeAnnotations = function(n) {
396
+ if (n === void 0)
397
+ throw new Error("Text edit change is not configured to manage change annotations.");
398
+ }, e;
399
+ }()
400
+ ), he = (
401
+ /** @class */
402
+ function() {
403
+ function e(n) {
404
+ this._annotations = n === void 0 ? /* @__PURE__ */ Object.create(null) : n, this._counter = 0, this._size = 0;
405
+ }
406
+ return e.prototype.all = function() {
407
+ return this._annotations;
408
+ }, Object.defineProperty(e.prototype, "size", {
409
+ get: function() {
410
+ return this._size;
411
+ },
412
+ enumerable: !1,
413
+ configurable: !0
414
+ }), e.prototype.manage = function(n, i) {
415
+ var r;
416
+ if (w.is(n) ? r = n : (r = this.nextId(), i = n), this._annotations[r] !== void 0)
417
+ throw new Error("Id " + r + " is already in use.");
418
+ if (i === void 0)
419
+ throw new Error("No annotation provided for id " + r);
420
+ return this._annotations[r] = i, this._size++, r;
421
+ }, e.prototype.nextId = function() {
422
+ return this._counter++, this._counter.toString();
423
+ }, e;
424
+ }()
425
+ );
426
+ /** @class */
427
+ (function() {
428
+ function e(n) {
429
+ var i = this;
430
+ this._textEditChanges = /* @__PURE__ */ Object.create(null), n !== void 0 ? (this._workspaceEdit = n, n.documentChanges ? (this._changeAnnotations = new he(n.changeAnnotations), n.changeAnnotations = this._changeAnnotations.all(), n.documentChanges.forEach(function(r) {
431
+ if (G.is(r)) {
432
+ var t = new J(r.edits, i._changeAnnotations);
433
+ i._textEditChanges[r.textDocument.uri] = t;
434
+ }
435
+ })) : n.changes && Object.keys(n.changes).forEach(function(r) {
436
+ var t = new J(n.changes[r]);
437
+ i._textEditChanges[r] = t;
438
+ })) : this._workspaceEdit = {};
439
+ }
440
+ return Object.defineProperty(e.prototype, "edit", {
441
+ /**
442
+ * Returns the underlying [WorkspaceEdit](#WorkspaceEdit) literal
443
+ * use to be returned from a workspace edit operation like rename.
444
+ */
445
+ get: function() {
446
+ return this.initDocumentChanges(), this._changeAnnotations !== void 0 && (this._changeAnnotations.size === 0 ? this._workspaceEdit.changeAnnotations = void 0 : this._workspaceEdit.changeAnnotations = this._changeAnnotations.all()), this._workspaceEdit;
447
+ },
448
+ enumerable: !1,
449
+ configurable: !0
450
+ }), e.prototype.getTextEditChange = function(n) {
451
+ if (Q.is(n)) {
452
+ if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0)
453
+ throw new Error("Workspace edit is not configured for document changes.");
454
+ var i = { uri: n.uri, version: n.version }, r = this._textEditChanges[i.uri];
455
+ if (!r) {
456
+ var t = [], a = {
457
+ textDocument: i,
458
+ edits: t
459
+ };
460
+ this._workspaceEdit.documentChanges.push(a), r = new J(t, this._changeAnnotations), this._textEditChanges[i.uri] = r;
461
+ }
462
+ return r;
463
+ } else {
464
+ if (this.initChanges(), this._workspaceEdit.changes === void 0)
465
+ throw new Error("Workspace edit is not configured for normal text edit changes.");
466
+ var r = this._textEditChanges[n];
467
+ if (!r) {
468
+ var t = [];
469
+ this._workspaceEdit.changes[n] = t, r = new J(t), this._textEditChanges[n] = r;
470
+ }
471
+ return r;
472
+ }
473
+ }, e.prototype.initDocumentChanges = function() {
474
+ this._workspaceEdit.documentChanges === void 0 && this._workspaceEdit.changes === void 0 && (this._changeAnnotations = new he(), this._workspaceEdit.documentChanges = [], this._workspaceEdit.changeAnnotations = this._changeAnnotations.all());
475
+ }, e.prototype.initChanges = function() {
476
+ this._workspaceEdit.documentChanges === void 0 && this._workspaceEdit.changes === void 0 && (this._workspaceEdit.changes = /* @__PURE__ */ Object.create(null));
477
+ }, e.prototype.createFile = function(n, i, r) {
478
+ if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0)
479
+ throw new Error("Workspace edit is not configured for document changes.");
480
+ var t;
481
+ O.is(i) || w.is(i) ? t = i : r = i;
482
+ var a, s;
483
+ if (t === void 0 ? a = H.create(n, r) : (s = w.is(t) ? t : this._changeAnnotations.manage(t), a = H.create(n, r, s)), this._workspaceEdit.documentChanges.push(a), s !== void 0)
484
+ return s;
485
+ }, e.prototype.renameFile = function(n, i, r, t) {
486
+ if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0)
487
+ throw new Error("Workspace edit is not configured for document changes.");
488
+ var a;
489
+ O.is(r) || w.is(r) ? a = r : t = r;
490
+ var s, u;
491
+ if (a === void 0 ? s = z.create(n, i, t) : (u = w.is(a) ? a : this._changeAnnotations.manage(a), s = z.create(n, i, t, u)), this._workspaceEdit.documentChanges.push(s), u !== void 0)
492
+ return u;
493
+ }, e.prototype.deleteFile = function(n, i, r) {
494
+ if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0)
495
+ throw new Error("Workspace edit is not configured for document changes.");
496
+ var t;
497
+ O.is(i) || w.is(i) ? t = i : r = i;
498
+ var a, s;
499
+ if (t === void 0 ? a = B.create(n, r) : (s = w.is(t) ? t : this._changeAnnotations.manage(t), a = B.create(n, r, s)), this._workspaceEdit.documentChanges.push(a), s !== void 0)
500
+ return s;
501
+ }, e;
502
+ })();
503
+ var ve;
504
+ (function(e) {
505
+ function n(r) {
506
+ return { uri: r };
507
+ }
508
+ e.create = n;
509
+ function i(r) {
510
+ var t = r;
511
+ return o.defined(t) && o.string(t.uri);
512
+ }
513
+ e.is = i;
514
+ })(ve || (ve = {}));
515
+ var pe;
516
+ (function(e) {
517
+ function n(r, t) {
518
+ return { uri: r, version: t };
519
+ }
520
+ e.create = n;
521
+ function i(r) {
522
+ var t = r;
523
+ return o.defined(t) && o.string(t.uri) && o.integer(t.version);
524
+ }
525
+ e.is = i;
526
+ })(pe || (pe = {}));
527
+ var Q;
528
+ (function(e) {
529
+ function n(r, t) {
530
+ return { uri: r, version: t };
531
+ }
532
+ e.create = n;
533
+ function i(r) {
534
+ var t = r;
535
+ return o.defined(t) && o.string(t.uri) && (t.version === null || o.integer(t.version));
536
+ }
537
+ e.is = i;
538
+ })(Q || (Q = {}));
539
+ var me;
540
+ (function(e) {
541
+ function n(r, t, a, s) {
542
+ return { uri: r, languageId: t, version: a, text: s };
543
+ }
544
+ e.create = n;
545
+ function i(r) {
546
+ var t = r;
547
+ return o.defined(t) && o.string(t.uri) && o.string(t.languageId) && o.integer(t.version) && o.string(t.text);
548
+ }
549
+ e.is = i;
550
+ })(me || (me = {}));
551
+ var q;
552
+ (function(e) {
553
+ e.PlainText = "plaintext", e.Markdown = "markdown";
554
+ })(q || (q = {}));
555
+ (function(e) {
556
+ function n(i) {
557
+ var r = i;
558
+ return r === e.PlainText || r === e.Markdown;
559
+ }
560
+ e.is = n;
561
+ })(q || (q = {}));
562
+ var ie;
563
+ (function(e) {
564
+ function n(i) {
565
+ var r = i;
566
+ return o.objectLiteral(i) && q.is(r.kind) && o.string(r.value);
567
+ }
568
+ e.is = n;
569
+ })(ie || (ie = {}));
570
+ var p;
571
+ (function(e) {
572
+ e.Text = 1, e.Method = 2, e.Function = 3, e.Constructor = 4, e.Field = 5, e.Variable = 6, e.Class = 7, e.Interface = 8, e.Module = 9, e.Property = 10, e.Unit = 11, e.Value = 12, e.Enum = 13, e.Keyword = 14, e.Snippet = 15, e.Color = 16, e.File = 17, e.Reference = 18, e.Folder = 19, e.EnumMember = 20, e.Constant = 21, e.Struct = 22, e.Event = 23, e.Operator = 24, e.TypeParameter = 25;
573
+ })(p || (p = {}));
574
+ var ae;
575
+ (function(e) {
576
+ e.PlainText = 1, e.Snippet = 2;
577
+ })(ae || (ae = {}));
578
+ var _e;
579
+ (function(e) {
580
+ e.Deprecated = 1;
581
+ })(_e || (_e = {}));
582
+ var ke;
583
+ (function(e) {
584
+ function n(r, t, a) {
585
+ return { newText: r, insert: t, replace: a };
586
+ }
587
+ e.create = n;
588
+ function i(r) {
589
+ var t = r;
590
+ return t && o.string(t.newText) && _.is(t.insert) && _.is(t.replace);
591
+ }
592
+ e.is = i;
593
+ })(ke || (ke = {}));
594
+ var we;
595
+ (function(e) {
596
+ e.asIs = 1, e.adjustIndentation = 2;
597
+ })(we || (we = {}));
598
+ var be;
599
+ (function(e) {
600
+ function n(i) {
601
+ return { label: i };
602
+ }
603
+ e.create = n;
604
+ })(be || (be = {}));
605
+ var Ce;
606
+ (function(e) {
607
+ function n(i, r) {
608
+ return { items: i || [], isIncomplete: !!r };
609
+ }
610
+ e.create = n;
611
+ })(Ce || (Ce = {}));
612
+ var Z;
613
+ (function(e) {
614
+ function n(r) {
615
+ return r.replace(/[\\`*_{}[\]()#+\-.!]/g, "\\$&");
616
+ }
617
+ e.fromPlainText = n;
618
+ function i(r) {
619
+ var t = r;
620
+ return o.string(t) || o.objectLiteral(t) && o.string(t.language) && o.string(t.value);
621
+ }
622
+ e.is = i;
623
+ })(Z || (Z = {}));
624
+ var Ee;
625
+ (function(e) {
626
+ function n(i) {
627
+ var r = i;
628
+ return !!r && o.objectLiteral(r) && (ie.is(r.contents) || Z.is(r.contents) || o.typedArray(r.contents, Z.is)) && (i.range === void 0 || _.is(i.range));
629
+ }
630
+ e.is = n;
631
+ })(Ee || (Ee = {}));
632
+ var Ae;
633
+ (function(e) {
634
+ function n(i, r) {
635
+ return r ? { label: i, documentation: r } : { label: i };
636
+ }
637
+ e.create = n;
638
+ })(Ae || (Ae = {}));
639
+ var Se;
640
+ (function(e) {
641
+ function n(i, r) {
642
+ for (var t = [], a = 2; a < arguments.length; a++)
643
+ t[a - 2] = arguments[a];
644
+ var s = { label: i };
645
+ return o.defined(r) && (s.documentation = r), o.defined(t) ? s.parameters = t : s.parameters = [], s;
646
+ }
647
+ e.create = n;
648
+ })(Se || (Se = {}));
649
+ var U;
650
+ (function(e) {
651
+ e.Text = 1, e.Read = 2, e.Write = 3;
652
+ })(U || (U = {}));
653
+ var Ie;
654
+ (function(e) {
655
+ function n(i, r) {
656
+ var t = { range: i };
657
+ return o.number(r) && (t.kind = r), t;
658
+ }
659
+ e.create = n;
660
+ })(Ie || (Ie = {}));
661
+ var m;
662
+ (function(e) {
663
+ e.File = 1, e.Module = 2, e.Namespace = 3, e.Package = 4, e.Class = 5, e.Method = 6, e.Property = 7, e.Field = 8, e.Constructor = 9, e.Enum = 10, e.Interface = 11, e.Function = 12, e.Variable = 13, e.Constant = 14, e.String = 15, e.Number = 16, e.Boolean = 17, e.Array = 18, e.Object = 19, e.Key = 20, e.Null = 21, e.EnumMember = 22, e.Struct = 23, e.Event = 24, e.Operator = 25, e.TypeParameter = 26;
664
+ })(m || (m = {}));
665
+ var ye;
666
+ (function(e) {
667
+ e.Deprecated = 1;
668
+ })(ye || (ye = {}));
669
+ var Te;
670
+ (function(e) {
671
+ function n(i, r, t, a, s) {
672
+ var u = {
673
+ name: i,
674
+ kind: r,
675
+ location: { uri: a, range: t }
676
+ };
677
+ return s && (u.containerName = s), u;
678
+ }
679
+ e.create = n;
680
+ })(Te || (Te = {}));
681
+ var Pe;
682
+ (function(e) {
683
+ function n(r, t, a, s, u, l) {
684
+ var c = {
685
+ name: r,
686
+ detail: t,
687
+ kind: a,
688
+ range: s,
689
+ selectionRange: u
690
+ };
691
+ return l !== void 0 && (c.children = l), c;
692
+ }
693
+ e.create = n;
694
+ function i(r) {
695
+ var t = r;
696
+ return t && o.string(t.name) && o.number(t.kind) && _.is(t.range) && _.is(t.selectionRange) && (t.detail === void 0 || o.string(t.detail)) && (t.deprecated === void 0 || o.boolean(t.deprecated)) && (t.children === void 0 || Array.isArray(t.children)) && (t.tags === void 0 || Array.isArray(t.tags));
697
+ }
698
+ e.is = i;
699
+ })(Pe || (Pe = {}));
700
+ var Re;
701
+ (function(e) {
702
+ e.Empty = "", e.QuickFix = "quickfix", e.Refactor = "refactor", e.RefactorExtract = "refactor.extract", e.RefactorInline = "refactor.inline", e.RefactorRewrite = "refactor.rewrite", e.Source = "source", e.SourceOrganizeImports = "source.organizeImports", e.SourceFixAll = "source.fixAll";
703
+ })(Re || (Re = {}));
704
+ var Me;
705
+ (function(e) {
706
+ function n(r, t) {
707
+ var a = { diagnostics: r };
708
+ return t != null && (a.only = t), a;
709
+ }
710
+ e.create = n;
711
+ function i(r) {
712
+ var t = r;
713
+ return o.defined(t) && o.typedArray(t.diagnostics, $.is) && (t.only === void 0 || o.typedArray(t.only, o.string));
714
+ }
715
+ e.is = i;
716
+ })(Me || (Me = {}));
717
+ var De;
718
+ (function(e) {
719
+ function n(r, t, a) {
720
+ var s = { title: r }, u = !0;
721
+ return typeof t == "string" ? (u = !1, s.kind = t) : V.is(t) ? s.command = t : s.edit = t, u && a !== void 0 && (s.kind = a), s;
722
+ }
723
+ e.create = n;
724
+ function i(r) {
725
+ var t = r;
726
+ return t && o.string(t.title) && (t.diagnostics === void 0 || o.typedArray(t.diagnostics, $.is)) && (t.kind === void 0 || o.string(t.kind)) && (t.edit !== void 0 || t.command !== void 0) && (t.command === void 0 || V.is(t.command)) && (t.isPreferred === void 0 || o.boolean(t.isPreferred)) && (t.edit === void 0 || ne.is(t.edit));
727
+ }
728
+ e.is = i;
729
+ })(De || (De = {}));
730
+ var Le;
731
+ (function(e) {
732
+ function n(r, t) {
733
+ var a = { range: r };
734
+ return o.defined(t) && (a.data = t), a;
735
+ }
736
+ e.create = n;
737
+ function i(r) {
738
+ var t = r;
739
+ return o.defined(t) && _.is(t.range) && (o.undefined(t.command) || V.is(t.command));
740
+ }
741
+ e.is = i;
742
+ })(Le || (Le = {}));
743
+ var Ne;
744
+ (function(e) {
745
+ function n(r, t) {
746
+ return { tabSize: r, insertSpaces: t };
747
+ }
748
+ e.create = n;
749
+ function i(r) {
750
+ var t = r;
751
+ return o.defined(t) && o.uinteger(t.tabSize) && o.boolean(t.insertSpaces);
752
+ }
753
+ e.is = i;
754
+ })(Ne || (Ne = {}));
755
+ var Oe;
756
+ (function(e) {
757
+ function n(r, t, a) {
758
+ return { range: r, target: t, data: a };
759
+ }
760
+ e.create = n;
761
+ function i(r) {
762
+ var t = r;
763
+ return o.defined(t) && _.is(t.range) && (o.undefined(t.target) || o.string(t.target));
764
+ }
765
+ e.is = i;
766
+ })(Oe || (Oe = {}));
767
+ var xe;
768
+ (function(e) {
769
+ function n(r, t) {
770
+ return { range: r, parent: t };
771
+ }
772
+ e.create = n;
773
+ function i(r) {
774
+ var t = r;
775
+ return t !== void 0 && _.is(t.range) && (t.parent === void 0 || e.is(t.parent));
776
+ }
777
+ e.is = i;
778
+ })(xe || (xe = {}));
779
+ var je;
780
+ (function(e) {
781
+ function n(a, s, u, l) {
782
+ return new ut(a, s, u, l);
783
+ }
784
+ e.create = n;
785
+ function i(a) {
786
+ var s = a;
787
+ return !!(o.defined(s) && o.string(s.uri) && (o.undefined(s.languageId) || o.string(s.languageId)) && o.uinteger(s.lineCount) && o.func(s.getText) && o.func(s.positionAt) && o.func(s.offsetAt));
788
+ }
789
+ e.is = i;
790
+ function r(a, s) {
791
+ for (var u = a.getText(), l = t(s, function(y, D) {
792
+ var x = y.range.start.line - D.range.start.line;
793
+ return x === 0 ? y.range.start.character - D.range.start.character : x;
794
+ }), c = u.length, v = l.length - 1; v >= 0; v--) {
795
+ var g = l[v], b = a.offsetAt(g.range.start), h = a.offsetAt(g.range.end);
796
+ if (h <= c)
797
+ u = u.substring(0, b) + g.newText + u.substring(h, u.length);
798
+ else
799
+ throw new Error("Overlapping edit");
800
+ c = b;
801
+ }
802
+ return u;
803
+ }
804
+ e.applyEdits = r;
805
+ function t(a, s) {
806
+ if (a.length <= 1)
807
+ return a;
808
+ var u = a.length / 2 | 0, l = a.slice(0, u), c = a.slice(u);
809
+ t(l, s), t(c, s);
810
+ for (var v = 0, g = 0, b = 0; v < l.length && g < c.length; ) {
811
+ var h = s(l[v], c[g]);
812
+ h <= 0 ? a[b++] = l[v++] : a[b++] = c[g++];
813
+ }
814
+ for (; v < l.length; )
815
+ a[b++] = l[v++];
816
+ for (; g < c.length; )
817
+ a[b++] = c[g++];
818
+ return a;
819
+ }
820
+ })(je || (je = {}));
821
+ var ut = (
822
+ /** @class */
823
+ function() {
824
+ function e(n, i, r, t) {
825
+ this._uri = n, this._languageId = i, this._version = r, this._content = t, this._lineOffsets = void 0;
826
+ }
827
+ return Object.defineProperty(e.prototype, "uri", {
828
+ get: function() {
829
+ return this._uri;
830
+ },
831
+ enumerable: !1,
832
+ configurable: !0
833
+ }), Object.defineProperty(e.prototype, "languageId", {
834
+ get: function() {
835
+ return this._languageId;
836
+ },
837
+ enumerable: !1,
838
+ configurable: !0
839
+ }), Object.defineProperty(e.prototype, "version", {
840
+ get: function() {
841
+ return this._version;
842
+ },
843
+ enumerable: !1,
844
+ configurable: !0
845
+ }), e.prototype.getText = function(n) {
846
+ if (n) {
847
+ var i = this.offsetAt(n.start), r = this.offsetAt(n.end);
848
+ return this._content.substring(i, r);
849
+ }
850
+ return this._content;
851
+ }, e.prototype.update = function(n, i) {
852
+ this._content = n.text, this._version = i, this._lineOffsets = void 0;
853
+ }, e.prototype.getLineOffsets = function() {
854
+ if (this._lineOffsets === void 0) {
855
+ for (var n = [], i = this._content, r = !0, t = 0; t < i.length; t++) {
856
+ r && (n.push(t), r = !1);
857
+ var a = i.charAt(t);
858
+ r = a === "\r" || a === `
859
+ `, a === "\r" && t + 1 < i.length && i.charAt(t + 1) === `
860
+ ` && t++;
861
+ }
862
+ r && i.length > 0 && n.push(i.length), this._lineOffsets = n;
863
+ }
864
+ return this._lineOffsets;
865
+ }, e.prototype.positionAt = function(n) {
866
+ n = Math.max(Math.min(n, this._content.length), 0);
867
+ var i = this.getLineOffsets(), r = 0, t = i.length;
868
+ if (t === 0)
869
+ return T.create(0, n);
870
+ for (; r < t; ) {
871
+ var a = Math.floor((r + t) / 2);
872
+ i[a] > n ? t = a : r = a + 1;
873
+ }
874
+ var s = r - 1;
875
+ return T.create(s, n - i[s]);
876
+ }, e.prototype.offsetAt = function(n) {
877
+ var i = this.getLineOffsets();
878
+ if (n.line >= i.length)
879
+ return this._content.length;
880
+ if (n.line < 0)
881
+ return 0;
882
+ var r = i[n.line], t = n.line + 1 < i.length ? i[n.line + 1] : this._content.length;
883
+ return Math.max(Math.min(r + n.character, t), r);
884
+ }, Object.defineProperty(e.prototype, "lineCount", {
885
+ get: function() {
886
+ return this.getLineOffsets().length;
887
+ },
888
+ enumerable: !1,
889
+ configurable: !0
890
+ }), e;
891
+ }()
892
+ ), o;
893
+ (function(e) {
894
+ var n = Object.prototype.toString;
895
+ function i(h) {
896
+ return typeof h < "u";
897
+ }
898
+ e.defined = i;
899
+ function r(h) {
900
+ return typeof h > "u";
901
+ }
902
+ e.undefined = r;
903
+ function t(h) {
904
+ return h === !0 || h === !1;
905
+ }
906
+ e.boolean = t;
907
+ function a(h) {
908
+ return n.call(h) === "[object String]";
909
+ }
910
+ e.string = a;
911
+ function s(h) {
912
+ return n.call(h) === "[object Number]";
913
+ }
914
+ e.number = s;
915
+ function u(h, y, D) {
916
+ return n.call(h) === "[object Number]" && y <= h && h <= D;
917
+ }
918
+ e.numberRange = u;
919
+ function l(h) {
920
+ return n.call(h) === "[object Number]" && -2147483648 <= h && h <= 2147483647;
921
+ }
922
+ e.integer = l;
923
+ function c(h) {
924
+ return n.call(h) === "[object Number]" && 0 <= h && h <= 2147483647;
925
+ }
926
+ e.uinteger = c;
927
+ function v(h) {
928
+ return n.call(h) === "[object Function]";
929
+ }
930
+ e.func = v;
931
+ function g(h) {
932
+ return h !== null && typeof h == "object";
933
+ }
934
+ e.objectLiteral = g;
935
+ function b(h, y) {
936
+ return Array.isArray(h) && h.every(y);
937
+ }
938
+ e.typedArray = b;
939
+ })(o || (o = {}));
940
+ var ct = class {
941
+ constructor(e, n, i) {
942
+ this._languageId = e, this._worker = n, this._disposables = [], this._listener = /* @__PURE__ */ Object.create(null);
943
+ const r = (a) => {
944
+ let s = a.getLanguageId();
945
+ if (s !== this._languageId)
946
+ return;
947
+ let u;
948
+ this._listener[a.uri.toString()] = a.onDidChangeContent(() => {
949
+ window.clearTimeout(u), u = window.setTimeout(() => this._doValidate(a.uri, s), 500);
950
+ }), this._doValidate(a.uri, s);
951
+ }, t = (a) => {
952
+ f.editor.setModelMarkers(a, this._languageId, []);
953
+ let s = a.uri.toString(), u = this._listener[s];
954
+ u && (u.dispose(), delete this._listener[s]);
955
+ };
956
+ this._disposables.push(f.editor.onDidCreateModel(r)), this._disposables.push(f.editor.onWillDisposeModel(t)), this._disposables.push(
957
+ f.editor.onDidChangeModelLanguage((a) => {
958
+ t(a.model), r(a.model);
959
+ })
960
+ ), this._disposables.push(
961
+ i((a) => {
962
+ f.editor.getModels().forEach((s) => {
963
+ s.getLanguageId() === this._languageId && (t(s), r(s));
964
+ });
965
+ })
966
+ ), this._disposables.push({
967
+ dispose: () => {
968
+ f.editor.getModels().forEach(t);
969
+ for (let a in this._listener)
970
+ this._listener[a].dispose();
971
+ }
972
+ }), f.editor.getModels().forEach(r);
973
+ }
974
+ dispose() {
975
+ this._disposables.forEach((e) => e && e.dispose()), this._disposables.length = 0;
976
+ }
977
+ _doValidate(e, n) {
978
+ this._worker(e).then((i) => i.doValidation(e.toString())).then((i) => {
979
+ const r = i.map((a) => ft(e, a));
980
+ let t = f.editor.getModel(e);
981
+ t && t.getLanguageId() === n && f.editor.setModelMarkers(t, n, r);
982
+ }).then(void 0, (i) => {
983
+ console.error(i);
984
+ });
985
+ }
986
+ };
987
+ function dt(e) {
988
+ switch (e) {
989
+ case N.Error:
990
+ return f.MarkerSeverity.Error;
991
+ case N.Warning:
992
+ return f.MarkerSeverity.Warning;
993
+ case N.Information:
994
+ return f.MarkerSeverity.Info;
995
+ case N.Hint:
996
+ return f.MarkerSeverity.Hint;
997
+ default:
998
+ return f.MarkerSeverity.Info;
999
+ }
1000
+ }
1001
+ function ft(e, n) {
1002
+ let i = typeof n.code == "number" ? String(n.code) : n.code;
1003
+ return {
1004
+ severity: dt(n.severity),
1005
+ startLineNumber: n.range.start.line + 1,
1006
+ startColumn: n.range.start.character + 1,
1007
+ endLineNumber: n.range.end.line + 1,
1008
+ endColumn: n.range.end.character + 1,
1009
+ message: n.message,
1010
+ code: i,
1011
+ source: n.source
1012
+ };
1013
+ }
1014
+ var lt = class {
1015
+ constructor(e, n) {
1016
+ this._worker = e, this._triggerCharacters = n;
1017
+ }
1018
+ get triggerCharacters() {
1019
+ return this._triggerCharacters;
1020
+ }
1021
+ provideCompletionItems(e, n, i, r) {
1022
+ const t = e.uri;
1023
+ return this._worker(t).then((a) => a.doComplete(t.toString(), M(n))).then((a) => {
1024
+ if (!a)
1025
+ return;
1026
+ const s = e.getWordUntilPosition(n), u = new f.Range(
1027
+ n.lineNumber,
1028
+ s.startColumn,
1029
+ n.lineNumber,
1030
+ s.endColumn
1031
+ ), l = a.items.map((c) => {
1032
+ const v = {
1033
+ label: c.label,
1034
+ insertText: c.insertText || c.label,
1035
+ sortText: c.sortText,
1036
+ filterText: c.filterText,
1037
+ documentation: c.documentation,
1038
+ detail: c.detail,
1039
+ command: vt(c.command),
1040
+ range: u,
1041
+ kind: ht(c.kind)
1042
+ };
1043
+ return c.textEdit && (gt(c.textEdit) ? v.range = {
1044
+ insert: C(c.textEdit.insert),
1045
+ replace: C(c.textEdit.replace)
1046
+ } : v.range = C(c.textEdit.range), v.insertText = c.textEdit.newText), c.additionalTextEdits && (v.additionalTextEdits = c.additionalTextEdits.map(X)), c.insertTextFormat === ae.Snippet && (v.insertTextRules = f.languages.CompletionItemInsertTextRule.InsertAsSnippet), v;
1047
+ });
1048
+ return {
1049
+ isIncomplete: a.isIncomplete,
1050
+ suggestions: l
1051
+ };
1052
+ });
1053
+ }
1054
+ };
1055
+ function M(e) {
1056
+ if (e)
1057
+ return { character: e.column - 1, line: e.lineNumber - 1 };
1058
+ }
1059
+ function ze(e) {
1060
+ if (e)
1061
+ return {
1062
+ start: {
1063
+ line: e.startLineNumber - 1,
1064
+ character: e.startColumn - 1
1065
+ },
1066
+ end: { line: e.endLineNumber - 1, character: e.endColumn - 1 }
1067
+ };
1068
+ }
1069
+ function C(e) {
1070
+ if (e)
1071
+ return new f.Range(
1072
+ e.start.line + 1,
1073
+ e.start.character + 1,
1074
+ e.end.line + 1,
1075
+ e.end.character + 1
1076
+ );
1077
+ }
1078
+ function gt(e) {
1079
+ return typeof e.insert < "u" && typeof e.replace < "u";
1080
+ }
1081
+ function ht(e) {
1082
+ const n = f.languages.CompletionItemKind;
1083
+ switch (e) {
1084
+ case p.Text:
1085
+ return n.Text;
1086
+ case p.Method:
1087
+ return n.Method;
1088
+ case p.Function:
1089
+ return n.Function;
1090
+ case p.Constructor:
1091
+ return n.Constructor;
1092
+ case p.Field:
1093
+ return n.Field;
1094
+ case p.Variable:
1095
+ return n.Variable;
1096
+ case p.Class:
1097
+ return n.Class;
1098
+ case p.Interface:
1099
+ return n.Interface;
1100
+ case p.Module:
1101
+ return n.Module;
1102
+ case p.Property:
1103
+ return n.Property;
1104
+ case p.Unit:
1105
+ return n.Unit;
1106
+ case p.Value:
1107
+ return n.Value;
1108
+ case p.Enum:
1109
+ return n.Enum;
1110
+ case p.Keyword:
1111
+ return n.Keyword;
1112
+ case p.Snippet:
1113
+ return n.Snippet;
1114
+ case p.Color:
1115
+ return n.Color;
1116
+ case p.File:
1117
+ return n.File;
1118
+ case p.Reference:
1119
+ return n.Reference;
1120
+ }
1121
+ return n.Property;
1122
+ }
1123
+ function X(e) {
1124
+ if (e)
1125
+ return {
1126
+ range: C(e.range),
1127
+ text: e.newText
1128
+ };
1129
+ }
1130
+ function vt(e) {
1131
+ return e && e.command === "editor.action.triggerSuggest" ? { id: e.command, title: e.title, arguments: e.arguments } : void 0;
1132
+ }
1133
+ var pt = class {
1134
+ constructor(e) {
1135
+ this._worker = e;
1136
+ }
1137
+ provideHover(e, n, i) {
1138
+ let r = e.uri;
1139
+ return this._worker(r).then((t) => t.doHover(r.toString(), M(n))).then((t) => {
1140
+ if (t)
1141
+ return {
1142
+ range: C(t.range),
1143
+ contents: _t(t.contents)
1144
+ };
1145
+ });
1146
+ }
1147
+ };
1148
+ function mt(e) {
1149
+ return e && typeof e == "object" && typeof e.kind == "string";
1150
+ }
1151
+ function Fe(e) {
1152
+ return typeof e == "string" ? {
1153
+ value: e
1154
+ } : mt(e) ? e.kind === "plaintext" ? {
1155
+ value: e.value.replace(/[\\`*_{}[\]()#+\-.!]/g, "\\$&")
1156
+ } : {
1157
+ value: e.value
1158
+ } : { value: "```" + e.language + `
1159
+ ` + e.value + "\n```\n" };
1160
+ }
1161
+ function _t(e) {
1162
+ if (e)
1163
+ return Array.isArray(e) ? e.map(Fe) : [Fe(e)];
1164
+ }
1165
+ var qt = class {
1166
+ constructor(e) {
1167
+ this._worker = e;
1168
+ }
1169
+ provideDocumentHighlights(e, n, i) {
1170
+ const r = e.uri;
1171
+ return this._worker(r).then((t) => t.findDocumentHighlights(r.toString(), M(n))).then((t) => {
1172
+ if (t)
1173
+ return t.map((a) => ({
1174
+ range: C(a.range),
1175
+ kind: kt(a.kind)
1176
+ }));
1177
+ });
1178
+ }
1179
+ };
1180
+ function kt(e) {
1181
+ switch (e) {
1182
+ case U.Read:
1183
+ return f.languages.DocumentHighlightKind.Read;
1184
+ case U.Write:
1185
+ return f.languages.DocumentHighlightKind.Write;
1186
+ case U.Text:
1187
+ return f.languages.DocumentHighlightKind.Text;
1188
+ }
1189
+ return f.languages.DocumentHighlightKind.Text;
1190
+ }
1191
+ var Xt = class {
1192
+ constructor(e) {
1193
+ this._worker = e;
1194
+ }
1195
+ provideDefinition(e, n, i) {
1196
+ const r = e.uri;
1197
+ return this._worker(r).then((t) => t.findDefinition(r.toString(), M(n))).then((t) => {
1198
+ if (t)
1199
+ return [Be(t)];
1200
+ });
1201
+ }
1202
+ };
1203
+ function Be(e) {
1204
+ return {
1205
+ uri: f.Uri.parse(e.uri),
1206
+ range: C(e.range)
1207
+ };
1208
+ }
1209
+ var Jt = class {
1210
+ constructor(e) {
1211
+ this._worker = e;
1212
+ }
1213
+ provideReferences(e, n, i, r) {
1214
+ const t = e.uri;
1215
+ return this._worker(t).then((a) => a.findReferences(t.toString(), M(n))).then((a) => {
1216
+ if (a)
1217
+ return a.map(Be);
1218
+ });
1219
+ }
1220
+ }, Yt = class {
1221
+ constructor(e) {
1222
+ this._worker = e;
1223
+ }
1224
+ provideRenameEdits(e, n, i, r) {
1225
+ const t = e.uri;
1226
+ return this._worker(t).then((a) => a.doRename(t.toString(), M(n), i)).then((a) => wt(a));
1227
+ }
1228
+ };
1229
+ function wt(e) {
1230
+ if (!e || !e.changes)
1231
+ return;
1232
+ let n = [];
1233
+ for (let i in e.changes) {
1234
+ const r = f.Uri.parse(i);
1235
+ for (let t of e.changes[i])
1236
+ n.push({
1237
+ resource: r,
1238
+ versionId: void 0,
1239
+ textEdit: {
1240
+ range: C(t.range),
1241
+ text: t.newText
1242
+ }
1243
+ });
1244
+ }
1245
+ return {
1246
+ edits: n
1247
+ };
1248
+ }
1249
+ var bt = class {
1250
+ constructor(e) {
1251
+ this._worker = e;
1252
+ }
1253
+ provideDocumentSymbols(e, n) {
1254
+ const i = e.uri;
1255
+ return this._worker(i).then((r) => r.findDocumentSymbols(i.toString())).then((r) => {
1256
+ if (r)
1257
+ return r.map((t) => Ct(t) ? qe(t) : {
1258
+ name: t.name,
1259
+ detail: "",
1260
+ containerName: t.containerName,
1261
+ kind: Xe(t.kind),
1262
+ range: C(t.location.range),
1263
+ selectionRange: C(t.location.range),
1264
+ tags: []
1265
+ });
1266
+ });
1267
+ }
1268
+ };
1269
+ function Ct(e) {
1270
+ return "children" in e;
1271
+ }
1272
+ function qe(e) {
1273
+ return {
1274
+ name: e.name,
1275
+ detail: e.detail ?? "",
1276
+ kind: Xe(e.kind),
1277
+ range: C(e.range),
1278
+ selectionRange: C(e.selectionRange),
1279
+ tags: e.tags ?? [],
1280
+ children: (e.children ?? []).map((n) => qe(n))
1281
+ };
1282
+ }
1283
+ function Xe(e) {
1284
+ let n = f.languages.SymbolKind;
1285
+ switch (e) {
1286
+ case m.File:
1287
+ return n.File;
1288
+ case m.Module:
1289
+ return n.Module;
1290
+ case m.Namespace:
1291
+ return n.Namespace;
1292
+ case m.Package:
1293
+ return n.Package;
1294
+ case m.Class:
1295
+ return n.Class;
1296
+ case m.Method:
1297
+ return n.Method;
1298
+ case m.Property:
1299
+ return n.Property;
1300
+ case m.Field:
1301
+ return n.Field;
1302
+ case m.Constructor:
1303
+ return n.Constructor;
1304
+ case m.Enum:
1305
+ return n.Enum;
1306
+ case m.Interface:
1307
+ return n.Interface;
1308
+ case m.Function:
1309
+ return n.Function;
1310
+ case m.Variable:
1311
+ return n.Variable;
1312
+ case m.Constant:
1313
+ return n.Constant;
1314
+ case m.String:
1315
+ return n.String;
1316
+ case m.Number:
1317
+ return n.Number;
1318
+ case m.Boolean:
1319
+ return n.Boolean;
1320
+ case m.Array:
1321
+ return n.Array;
1322
+ }
1323
+ return n.Function;
1324
+ }
1325
+ var $t = class {
1326
+ constructor(e) {
1327
+ this._worker = e;
1328
+ }
1329
+ provideLinks(e, n) {
1330
+ const i = e.uri;
1331
+ return this._worker(i).then((r) => r.findDocumentLinks(i.toString())).then((r) => {
1332
+ if (r)
1333
+ return {
1334
+ links: r.map((t) => ({
1335
+ range: C(t.range),
1336
+ url: t.target
1337
+ }))
1338
+ };
1339
+ });
1340
+ }
1341
+ }, Et = class {
1342
+ constructor(e) {
1343
+ this._worker = e;
1344
+ }
1345
+ provideDocumentFormattingEdits(e, n, i) {
1346
+ const r = e.uri;
1347
+ return this._worker(r).then((t) => t.format(r.toString(), null, Je(n)).then((a) => {
1348
+ if (!(!a || a.length === 0))
1349
+ return a.map(X);
1350
+ }));
1351
+ }
1352
+ }, At = class {
1353
+ constructor(e) {
1354
+ this._worker = e, this.canFormatMultipleRanges = !1;
1355
+ }
1356
+ provideDocumentRangeFormattingEdits(e, n, i, r) {
1357
+ const t = e.uri;
1358
+ return this._worker(t).then((a) => a.format(t.toString(), ze(n), Je(i)).then((s) => {
1359
+ if (!(!s || s.length === 0))
1360
+ return s.map(X);
1361
+ }));
1362
+ }
1363
+ };
1364
+ function Je(e) {
1365
+ return {
1366
+ tabSize: e.tabSize,
1367
+ insertSpaces: e.insertSpaces
1368
+ };
1369
+ }
1370
+ var St = class {
1371
+ constructor(e) {
1372
+ this._worker = e;
1373
+ }
1374
+ provideDocumentColors(e, n) {
1375
+ const i = e.uri;
1376
+ return this._worker(i).then((r) => r.findDocumentColors(i.toString())).then((r) => {
1377
+ if (r)
1378
+ return r.map((t) => ({
1379
+ color: t.color,
1380
+ range: C(t.range)
1381
+ }));
1382
+ });
1383
+ }
1384
+ provideColorPresentations(e, n, i) {
1385
+ const r = e.uri;
1386
+ return this._worker(r).then(
1387
+ (t) => t.getColorPresentations(r.toString(), n.color, ze(n.range))
1388
+ ).then((t) => {
1389
+ if (t)
1390
+ return t.map((a) => {
1391
+ let s = {
1392
+ label: a.label
1393
+ };
1394
+ return a.textEdit && (s.textEdit = X(a.textEdit)), a.additionalTextEdits && (s.additionalTextEdits = a.additionalTextEdits.map(X)), s;
1395
+ });
1396
+ });
1397
+ }
1398
+ }, It = class {
1399
+ constructor(e) {
1400
+ this._worker = e;
1401
+ }
1402
+ provideFoldingRanges(e, n, i) {
1403
+ const r = e.uri;
1404
+ return this._worker(r).then((t) => t.getFoldingRanges(r.toString(), n)).then((t) => {
1405
+ if (t)
1406
+ return t.map((a) => {
1407
+ const s = {
1408
+ start: a.startLine + 1,
1409
+ end: a.endLine + 1
1410
+ };
1411
+ return typeof a.kind < "u" && (s.kind = yt(a.kind)), s;
1412
+ });
1413
+ });
1414
+ }
1415
+ };
1416
+ function yt(e) {
1417
+ switch (e) {
1418
+ case W.Comment:
1419
+ return f.languages.FoldingRangeKind.Comment;
1420
+ case W.Imports:
1421
+ return f.languages.FoldingRangeKind.Imports;
1422
+ case W.Region:
1423
+ return f.languages.FoldingRangeKind.Region;
1424
+ }
1425
+ }
1426
+ var Tt = class {
1427
+ constructor(e) {
1428
+ this._worker = e;
1429
+ }
1430
+ provideSelectionRanges(e, n, i) {
1431
+ const r = e.uri;
1432
+ return this._worker(r).then(
1433
+ (t) => t.getSelectionRanges(
1434
+ r.toString(),
1435
+ n.map(M)
1436
+ )
1437
+ ).then((t) => {
1438
+ if (t)
1439
+ return t.map((a) => {
1440
+ const s = [];
1441
+ for (; a; )
1442
+ s.push({ range: C(a.range) }), a = a.parent;
1443
+ return s;
1444
+ });
1445
+ });
1446
+ }
1447
+ };
1448
+ function Pt(e, n) {
1449
+ n === void 0 && (n = !1);
1450
+ var i = e.length, r = 0, t = "", a = 0, s = 16, u = 0, l = 0, c = 0, v = 0, g = 0;
1451
+ function b(d, E) {
1452
+ for (var I = 0, A = 0; I < d || !E; ) {
1453
+ var k = e.charCodeAt(r);
1454
+ if (k >= 48 && k <= 57)
1455
+ A = A * 16 + k - 48;
1456
+ else if (k >= 65 && k <= 70)
1457
+ A = A * 16 + k - 65 + 10;
1458
+ else if (k >= 97 && k <= 102)
1459
+ A = A * 16 + k - 97 + 10;
1460
+ else
1461
+ break;
1462
+ r++, I++;
1463
+ }
1464
+ return I < d && (A = -1), A;
1465
+ }
1466
+ function h(d) {
1467
+ r = d, t = "", a = 0, s = 16, g = 0;
1468
+ }
1469
+ function y() {
1470
+ var d = r;
1471
+ if (e.charCodeAt(r) === 48)
1472
+ r++;
1473
+ else
1474
+ for (r++; r < e.length && L(e.charCodeAt(r)); )
1475
+ r++;
1476
+ if (r < e.length && e.charCodeAt(r) === 46)
1477
+ if (r++, r < e.length && L(e.charCodeAt(r)))
1478
+ for (r++; r < e.length && L(e.charCodeAt(r)); )
1479
+ r++;
1480
+ else
1481
+ return g = 3, e.substring(d, r);
1482
+ var E = r;
1483
+ if (r < e.length && (e.charCodeAt(r) === 69 || e.charCodeAt(r) === 101))
1484
+ if (r++, (r < e.length && e.charCodeAt(r) === 43 || e.charCodeAt(r) === 45) && r++, r < e.length && L(e.charCodeAt(r))) {
1485
+ for (r++; r < e.length && L(e.charCodeAt(r)); )
1486
+ r++;
1487
+ E = r;
1488
+ } else
1489
+ g = 3;
1490
+ return e.substring(d, E);
1491
+ }
1492
+ function D() {
1493
+ for (var d = "", E = r; ; ) {
1494
+ if (r >= i) {
1495
+ d += e.substring(E, r), g = 2;
1496
+ break;
1497
+ }
1498
+ var I = e.charCodeAt(r);
1499
+ if (I === 34) {
1500
+ d += e.substring(E, r), r++;
1501
+ break;
1502
+ }
1503
+ if (I === 92) {
1504
+ if (d += e.substring(E, r), r++, r >= i) {
1505
+ g = 2;
1506
+ break;
1507
+ }
1508
+ var A = e.charCodeAt(r++);
1509
+ switch (A) {
1510
+ case 34:
1511
+ d += '"';
1512
+ break;
1513
+ case 92:
1514
+ d += "\\";
1515
+ break;
1516
+ case 47:
1517
+ d += "/";
1518
+ break;
1519
+ case 98:
1520
+ d += "\b";
1521
+ break;
1522
+ case 102:
1523
+ d += "\f";
1524
+ break;
1525
+ case 110:
1526
+ d += `
1527
+ `;
1528
+ break;
1529
+ case 114:
1530
+ d += "\r";
1531
+ break;
1532
+ case 116:
1533
+ d += " ";
1534
+ break;
1535
+ case 117:
1536
+ var k = b(4, !0);
1537
+ k >= 0 ? d += String.fromCharCode(k) : g = 4;
1538
+ break;
1539
+ default:
1540
+ g = 5;
1541
+ }
1542
+ E = r;
1543
+ continue;
1544
+ }
1545
+ if (I >= 0 && I <= 31)
1546
+ if (j(I)) {
1547
+ d += e.substring(E, r), g = 2;
1548
+ break;
1549
+ } else
1550
+ g = 6;
1551
+ r++;
1552
+ }
1553
+ return d;
1554
+ }
1555
+ function x() {
1556
+ if (t = "", g = 0, a = r, l = u, v = c, r >= i)
1557
+ return a = i, s = 17;
1558
+ var d = e.charCodeAt(r);
1559
+ if (K(d)) {
1560
+ do
1561
+ r++, t += String.fromCharCode(d), d = e.charCodeAt(r);
1562
+ while (K(d));
1563
+ return s = 15;
1564
+ }
1565
+ if (j(d))
1566
+ return r++, t += String.fromCharCode(d), d === 13 && e.charCodeAt(r) === 10 && (r++, t += `
1567
+ `), u++, c = r, s = 14;
1568
+ switch (d) {
1569
+ case 123:
1570
+ return r++, s = 1;
1571
+ case 125:
1572
+ return r++, s = 2;
1573
+ case 91:
1574
+ return r++, s = 3;
1575
+ case 93:
1576
+ return r++, s = 4;
1577
+ case 58:
1578
+ return r++, s = 6;
1579
+ case 44:
1580
+ return r++, s = 5;
1581
+ case 34:
1582
+ return r++, t = D(), s = 10;
1583
+ case 47:
1584
+ var E = r - 1;
1585
+ if (e.charCodeAt(r + 1) === 47) {
1586
+ for (r += 2; r < i && !j(e.charCodeAt(r)); )
1587
+ r++;
1588
+ return t = e.substring(E, r), s = 12;
1589
+ }
1590
+ if (e.charCodeAt(r + 1) === 42) {
1591
+ r += 2;
1592
+ for (var I = i - 1, A = !1; r < I; ) {
1593
+ var k = e.charCodeAt(r);
1594
+ if (k === 42 && e.charCodeAt(r + 1) === 47) {
1595
+ r += 2, A = !0;
1596
+ break;
1597
+ }
1598
+ r++, j(k) && (k === 13 && e.charCodeAt(r) === 10 && r++, u++, c = r);
1599
+ }
1600
+ return A || (r++, g = 1), t = e.substring(E, r), s = 13;
1601
+ }
1602
+ return t += String.fromCharCode(d), r++, s = 16;
1603
+ case 45:
1604
+ if (t += String.fromCharCode(d), r++, r === i || !L(e.charCodeAt(r)))
1605
+ return s = 16;
1606
+ case 48:
1607
+ case 49:
1608
+ case 50:
1609
+ case 51:
1610
+ case 52:
1611
+ case 53:
1612
+ case 54:
1613
+ case 55:
1614
+ case 56:
1615
+ case 57:
1616
+ return t += y(), s = 11;
1617
+ default:
1618
+ for (; r < i && Qe(d); )
1619
+ r++, d = e.charCodeAt(r);
1620
+ if (a !== r) {
1621
+ switch (t = e.substring(a, r), t) {
1622
+ case "true":
1623
+ return s = 8;
1624
+ case "false":
1625
+ return s = 9;
1626
+ case "null":
1627
+ return s = 7;
1628
+ }
1629
+ return s = 16;
1630
+ }
1631
+ return t += String.fromCharCode(d), r++, s = 16;
1632
+ }
1633
+ }
1634
+ function Qe(d) {
1635
+ if (K(d) || j(d))
1636
+ return !1;
1637
+ switch (d) {
1638
+ case 125:
1639
+ case 93:
1640
+ case 123:
1641
+ case 91:
1642
+ case 34:
1643
+ case 58:
1644
+ case 44:
1645
+ case 47:
1646
+ return !1;
1647
+ }
1648
+ return !0;
1649
+ }
1650
+ function Ze() {
1651
+ var d;
1652
+ do
1653
+ d = x();
1654
+ while (d >= 12 && d <= 15);
1655
+ return d;
1656
+ }
1657
+ return {
1658
+ setPosition: h,
1659
+ getPosition: function() {
1660
+ return r;
1661
+ },
1662
+ scan: n ? Ze : x,
1663
+ getToken: function() {
1664
+ return s;
1665
+ },
1666
+ getTokenValue: function() {
1667
+ return t;
1668
+ },
1669
+ getTokenOffset: function() {
1670
+ return a;
1671
+ },
1672
+ getTokenLength: function() {
1673
+ return r - a;
1674
+ },
1675
+ getTokenStartLine: function() {
1676
+ return l;
1677
+ },
1678
+ getTokenStartCharacter: function() {
1679
+ return a - v;
1680
+ },
1681
+ getTokenError: function() {
1682
+ return g;
1683
+ }
1684
+ };
1685
+ }
1686
+ function K(e) {
1687
+ return e === 32 || e === 9 || e === 11 || e === 12 || e === 160 || e === 5760 || e >= 8192 && e <= 8203 || e === 8239 || e === 8287 || e === 12288 || e === 65279;
1688
+ }
1689
+ function j(e) {
1690
+ return e === 10 || e === 13 || e === 8232 || e === 8233;
1691
+ }
1692
+ function L(e) {
1693
+ return e >= 48 && e <= 57;
1694
+ }
1695
+ var We;
1696
+ (function(e) {
1697
+ e.DEFAULT = {
1698
+ allowTrailingComma: !1
1699
+ };
1700
+ })(We || (We = {}));
1701
+ var Rt = Pt;
1702
+ function Mt(e) {
1703
+ return {
1704
+ getInitialState: () => new $e(null, null, !1, null),
1705
+ tokenize: (n, i) => Vt(e, n, i)
1706
+ };
1707
+ }
1708
+ var Ue = "delimiter.bracket.json", Ve = "delimiter.array.json", Dt = "delimiter.colon.json", Lt = "delimiter.comma.json", Nt = "keyword.json", Ot = "keyword.json", xt = "string.value.json", jt = "number.json", Ft = "string.key.json", Wt = "comment.block.json", Ut = "comment.line.json", F = class Ye {
1709
+ constructor(n, i) {
1710
+ this.parent = n, this.type = i;
1711
+ }
1712
+ static pop(n) {
1713
+ return n ? n.parent : null;
1714
+ }
1715
+ static push(n, i) {
1716
+ return new Ye(n, i);
1717
+ }
1718
+ static equals(n, i) {
1719
+ if (!n && !i)
1720
+ return !0;
1721
+ if (!n || !i)
1722
+ return !1;
1723
+ for (; n && i; ) {
1724
+ if (n === i)
1725
+ return !0;
1726
+ if (n.type !== i.type)
1727
+ return !1;
1728
+ n = n.parent, i = i.parent;
1729
+ }
1730
+ return !0;
1731
+ }
1732
+ }, $e = class se {
1733
+ constructor(n, i, r, t) {
1734
+ this._state = n, this.scanError = i, this.lastWasColon = r, this.parents = t;
1735
+ }
1736
+ clone() {
1737
+ return new se(this._state, this.scanError, this.lastWasColon, this.parents);
1738
+ }
1739
+ equals(n) {
1740
+ return n === this ? !0 : !n || !(n instanceof se) ? !1 : this.scanError === n.scanError && this.lastWasColon === n.lastWasColon && F.equals(this.parents, n.parents);
1741
+ }
1742
+ getStateData() {
1743
+ return this._state;
1744
+ }
1745
+ setStateData(n) {
1746
+ this._state = n;
1747
+ }
1748
+ };
1749
+ function Vt(e, n, i, r = 0) {
1750
+ let t = 0, a = !1;
1751
+ switch (i.scanError) {
1752
+ case 2:
1753
+ n = '"' + n, t = 1;
1754
+ break;
1755
+ case 1:
1756
+ n = "/*" + n, t = 2;
1757
+ break;
1758
+ }
1759
+ const s = Rt(n);
1760
+ let u = i.lastWasColon, l = i.parents;
1761
+ const c = {
1762
+ tokens: [],
1763
+ endState: i.clone()
1764
+ };
1765
+ for (; ; ) {
1766
+ let v = r + s.getPosition(), g = "";
1767
+ const b = s.scan();
1768
+ if (b === 17)
1769
+ break;
1770
+ if (v === r + s.getPosition())
1771
+ throw new Error(
1772
+ "Scanner did not advance, next 3 characters are: " + n.substr(s.getPosition(), 3)
1773
+ );
1774
+ switch (a && (v -= t), a = t > 0, b) {
1775
+ case 1:
1776
+ l = F.push(
1777
+ l,
1778
+ 0
1779
+ /* Object */
1780
+ ), g = Ue, u = !1;
1781
+ break;
1782
+ case 2:
1783
+ l = F.pop(l), g = Ue, u = !1;
1784
+ break;
1785
+ case 3:
1786
+ l = F.push(
1787
+ l,
1788
+ 1
1789
+ /* Array */
1790
+ ), g = Ve, u = !1;
1791
+ break;
1792
+ case 4:
1793
+ l = F.pop(l), g = Ve, u = !1;
1794
+ break;
1795
+ case 6:
1796
+ g = Dt, u = !0;
1797
+ break;
1798
+ case 5:
1799
+ g = Lt, u = !1;
1800
+ break;
1801
+ case 8:
1802
+ case 9:
1803
+ g = Nt, u = !1;
1804
+ break;
1805
+ case 7:
1806
+ g = Ot, u = !1;
1807
+ break;
1808
+ case 10:
1809
+ const y = (l ? l.type : 0) === 1;
1810
+ g = u || y ? xt : Ft, u = !1;
1811
+ break;
1812
+ case 11:
1813
+ g = jt, u = !1;
1814
+ break;
1815
+ }
1816
+ switch (b) {
1817
+ case 12:
1818
+ g = Ut;
1819
+ break;
1820
+ case 13:
1821
+ g = Wt;
1822
+ break;
1823
+ }
1824
+ c.endState = new $e(
1825
+ i.getStateData(),
1826
+ s.getTokenError(),
1827
+ u,
1828
+ l
1829
+ ), c.tokens.push({
1830
+ startIndex: v,
1831
+ scopes: g
1832
+ });
1833
+ }
1834
+ return c;
1835
+ }
1836
+ var S;
1837
+ function Gt() {
1838
+ return new Promise((e, n) => {
1839
+ if (!S)
1840
+ return n("JSON not registered!");
1841
+ e(S);
1842
+ });
1843
+ }
1844
+ var Ht = class extends ct {
1845
+ constructor(e, n, i) {
1846
+ super(e, n, i.onDidChange), this._disposables.push(
1847
+ f.editor.onWillDisposeModel((r) => {
1848
+ this._resetSchema(r.uri);
1849
+ })
1850
+ ), this._disposables.push(
1851
+ f.editor.onDidChangeModelLanguage((r) => {
1852
+ this._resetSchema(r.model.uri);
1853
+ })
1854
+ );
1855
+ }
1856
+ _resetSchema(e) {
1857
+ this._worker().then((n) => {
1858
+ n.resetSchema(e.toString());
1859
+ });
1860
+ }
1861
+ };
1862
+ function Qt(e) {
1863
+ const n = [], i = [], r = new ot(e);
1864
+ n.push(r), S = (...s) => r.getLanguageServiceWorker(...s);
1865
+ function t() {
1866
+ const { languageId: s, modeConfiguration: u } = e;
1867
+ Ge(i), u.documentFormattingEdits && i.push(
1868
+ f.languages.registerDocumentFormattingEditProvider(
1869
+ s,
1870
+ new Et(S)
1871
+ )
1872
+ ), u.documentRangeFormattingEdits && i.push(
1873
+ f.languages.registerDocumentRangeFormattingEditProvider(
1874
+ s,
1875
+ new At(S)
1876
+ )
1877
+ ), u.completionItems && i.push(
1878
+ f.languages.registerCompletionItemProvider(
1879
+ s,
1880
+ new lt(S, [" ", ":", '"'])
1881
+ )
1882
+ ), u.hovers && i.push(
1883
+ f.languages.registerHoverProvider(s, new pt(S))
1884
+ ), u.documentSymbols && i.push(
1885
+ f.languages.registerDocumentSymbolProvider(
1886
+ s,
1887
+ new bt(S)
1888
+ )
1889
+ ), u.tokens && i.push(f.languages.setTokensProvider(s, Mt(!0))), u.colors && i.push(
1890
+ f.languages.registerColorProvider(
1891
+ s,
1892
+ new St(S)
1893
+ )
1894
+ ), u.foldingRanges && i.push(
1895
+ f.languages.registerFoldingRangeProvider(
1896
+ s,
1897
+ new It(S)
1898
+ )
1899
+ ), u.diagnostics && i.push(new Ht(s, S, e)), u.selectionRanges && i.push(
1900
+ f.languages.registerSelectionRangeProvider(
1901
+ s,
1902
+ new Tt(S)
1903
+ )
1904
+ );
1905
+ }
1906
+ t(), n.push(f.languages.setLanguageConfiguration(e.languageId, zt));
1907
+ let a = e.modeConfiguration;
1908
+ return e.onDidChange((s) => {
1909
+ s.modeConfiguration !== a && (a = s.modeConfiguration, t());
1910
+ }), n.push(He(i)), He(n);
1911
+ }
1912
+ function He(e) {
1913
+ return { dispose: () => Ge(e) };
1914
+ }
1915
+ function Ge(e) {
1916
+ for (; e.length; )
1917
+ e.pop().dispose();
1918
+ }
1919
+ var zt = {
1920
+ wordPattern: /(-?\d*\.\d\w*)|([^\[\{\]\}\:\"\,\s]+)/g,
1921
+ comments: {
1922
+ lineComment: "//",
1923
+ blockComment: ["/*", "*/"]
1924
+ },
1925
+ brackets: [
1926
+ ["{", "}"],
1927
+ ["[", "]"]
1928
+ ],
1929
+ autoClosingPairs: [
1930
+ { open: "{", close: "}", notIn: ["string"] },
1931
+ { open: "[", close: "]", notIn: ["string"] },
1932
+ { open: '"', close: '"', notIn: ["string"] }
1933
+ ]
1934
+ };
1935
+ export {
1936
+ lt as CompletionAdapter,
1937
+ Xt as DefinitionAdapter,
1938
+ ct as DiagnosticsAdapter,
1939
+ St as DocumentColorAdapter,
1940
+ Et as DocumentFormattingEditProvider,
1941
+ qt as DocumentHighlightAdapter,
1942
+ $t as DocumentLinkAdapter,
1943
+ At as DocumentRangeFormattingEditProvider,
1944
+ bt as DocumentSymbolAdapter,
1945
+ It as FoldingRangeAdapter,
1946
+ pt as HoverAdapter,
1947
+ Jt as ReferenceAdapter,
1948
+ Yt as RenameAdapter,
1949
+ Tt as SelectionRangeAdapter,
1950
+ ot as WorkerManager,
1951
+ M as fromPosition,
1952
+ ze as fromRange,
1953
+ Gt as getWorker,
1954
+ Qt as setupMode,
1955
+ C as toRange,
1956
+ X as toTextEdit
1957
+ };