@ws-ui/code-editor 0.2.24 → 0.2.26
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/dist/editor/index.d.ts +1 -0
- package/dist/index.cjs.js +19 -19
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +506 -502
- package/dist/index.es.js.map +1 -1
- package/dist/studio/assets/css.worker.bundle.js +337 -206
- package/dist/studio/assets/editor.worker.bundle.js +331 -200
- package/dist/studio/assets/html.worker.bundle.js +334 -203
- package/dist/studio/assets/json.worker.bundle.js +334 -203
- package/dist/studio/assets/textmate.worker.bundle.js +367 -209
- package/dist/studio/assets/ts.worker.bundle.js +1282 -1151
- package/package.json +22 -22
|
@@ -339,6 +339,7 @@
|
|
|
339
339
|
};
|
|
340
340
|
|
|
341
341
|
// node_modules/vscode/vscode/src/vs/base/common/collections.js
|
|
342
|
+
var _a;
|
|
342
343
|
function groupBy(data, groupFn) {
|
|
343
344
|
const result = /* @__PURE__ */ Object.create(null);
|
|
344
345
|
for (const element of data) {
|
|
@@ -351,9 +352,58 @@
|
|
|
351
352
|
}
|
|
352
353
|
return result;
|
|
353
354
|
}
|
|
355
|
+
var SetWithKey = class {
|
|
356
|
+
static {
|
|
357
|
+
_a = Symbol.toStringTag;
|
|
358
|
+
}
|
|
359
|
+
constructor(values, toKey) {
|
|
360
|
+
this.toKey = toKey;
|
|
361
|
+
this._map = /* @__PURE__ */ new Map();
|
|
362
|
+
this[_a] = "SetWithKey";
|
|
363
|
+
for (const value of values) {
|
|
364
|
+
this.add(value);
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
get size() {
|
|
368
|
+
return this._map.size;
|
|
369
|
+
}
|
|
370
|
+
add(value) {
|
|
371
|
+
const key = this.toKey(value);
|
|
372
|
+
this._map.set(key, value);
|
|
373
|
+
return this;
|
|
374
|
+
}
|
|
375
|
+
delete(value) {
|
|
376
|
+
return this._map.delete(this.toKey(value));
|
|
377
|
+
}
|
|
378
|
+
has(value) {
|
|
379
|
+
return this._map.has(this.toKey(value));
|
|
380
|
+
}
|
|
381
|
+
*entries() {
|
|
382
|
+
for (const entry of this._map.values()) {
|
|
383
|
+
yield [entry, entry];
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
keys() {
|
|
387
|
+
return this.values();
|
|
388
|
+
}
|
|
389
|
+
*values() {
|
|
390
|
+
for (const entry of this._map.values()) {
|
|
391
|
+
yield entry;
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
clear() {
|
|
395
|
+
this._map.clear();
|
|
396
|
+
}
|
|
397
|
+
forEach(callbackfn, thisArg) {
|
|
398
|
+
this._map.forEach((entry) => callbackfn.call(thisArg, entry, entry, this));
|
|
399
|
+
}
|
|
400
|
+
[Symbol.iterator]() {
|
|
401
|
+
return this.values();
|
|
402
|
+
}
|
|
403
|
+
};
|
|
354
404
|
|
|
355
405
|
// node_modules/vscode/vscode/src/vs/base/common/map.js
|
|
356
|
-
var
|
|
406
|
+
var _a2;
|
|
357
407
|
var _b;
|
|
358
408
|
var _c;
|
|
359
409
|
var ResourceMapEntry = class {
|
|
@@ -370,7 +420,7 @@
|
|
|
370
420
|
this.defaultToKey = (resource) => resource.toString();
|
|
371
421
|
}
|
|
372
422
|
constructor(arg, toKey) {
|
|
373
|
-
this[
|
|
423
|
+
this[_a2] = "ResourceMap";
|
|
374
424
|
if (arg instanceof _ResourceMap) {
|
|
375
425
|
this.map = new Map(arg.map);
|
|
376
426
|
this.toKey = toKey ?? _ResourceMap.defaultToKey;
|
|
@@ -427,7 +477,7 @@
|
|
|
427
477
|
yield [entry.uri, entry.value];
|
|
428
478
|
}
|
|
429
479
|
}
|
|
430
|
-
*[(
|
|
480
|
+
*[(_a2 = Symbol.toStringTag, Symbol.iterator)]() {
|
|
431
481
|
for (const [, entry] of this.map) {
|
|
432
482
|
yield [entry.uri, entry.value];
|
|
433
483
|
}
|
|
@@ -949,8 +999,9 @@
|
|
|
949
999
|
}
|
|
950
1000
|
Iterable2.first = first;
|
|
951
1001
|
function some(iterable, predicate) {
|
|
1002
|
+
let i = 0;
|
|
952
1003
|
for (const element of iterable) {
|
|
953
|
-
if (predicate(element)) {
|
|
1004
|
+
if (predicate(element, i++)) {
|
|
954
1005
|
return true;
|
|
955
1006
|
}
|
|
956
1007
|
}
|
|
@@ -981,6 +1032,13 @@
|
|
|
981
1032
|
}
|
|
982
1033
|
}
|
|
983
1034
|
Iterable2.map = map;
|
|
1035
|
+
function* flatMap(iterable, fn) {
|
|
1036
|
+
let index = 0;
|
|
1037
|
+
for (const element of iterable) {
|
|
1038
|
+
yield* fn(element, index++);
|
|
1039
|
+
}
|
|
1040
|
+
}
|
|
1041
|
+
Iterable2.flatMap = flatMap;
|
|
984
1042
|
function* concat(...iterables) {
|
|
985
1043
|
for (const iterable of iterables) {
|
|
986
1044
|
yield* iterable;
|
|
@@ -1814,6 +1872,10 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
1814
1872
|
return result.event;
|
|
1815
1873
|
}
|
|
1816
1874
|
Event2.fromPromise = fromPromise;
|
|
1875
|
+
function forward(from, to) {
|
|
1876
|
+
return from((e) => to.fire(e));
|
|
1877
|
+
}
|
|
1878
|
+
Event2.forward = forward;
|
|
1817
1879
|
function runAndSubscribe(event, handler, initial) {
|
|
1818
1880
|
handler(initial);
|
|
1819
1881
|
return event((e) => handler(e));
|
|
@@ -1932,8 +1994,11 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
1932
1994
|
}
|
|
1933
1995
|
};
|
|
1934
1996
|
var _globalLeakWarningThreshold = -1;
|
|
1935
|
-
var LeakageMonitor = class {
|
|
1936
|
-
|
|
1997
|
+
var LeakageMonitor = class _LeakageMonitor {
|
|
1998
|
+
static {
|
|
1999
|
+
this._idPool = 1;
|
|
2000
|
+
}
|
|
2001
|
+
constructor(_errorHandler, threshold, name = (_LeakageMonitor._idPool++).toString(16).padStart(3, "0")) {
|
|
1937
2002
|
this._errorHandler = _errorHandler;
|
|
1938
2003
|
this.threshold = threshold;
|
|
1939
2004
|
this.name = name;
|
|
@@ -2226,43 +2291,6 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
2226
2291
|
return result;
|
|
2227
2292
|
}
|
|
2228
2293
|
|
|
2229
|
-
// node_modules/vscode/vscode/src/vs/nls.js
|
|
2230
|
-
var isPseudo = typeof document !== "undefined" && document.location && document.location.hash.indexOf("pseudo=true") >= 0;
|
|
2231
|
-
function _format(message, args) {
|
|
2232
|
-
let result;
|
|
2233
|
-
if (args.length === 0) {
|
|
2234
|
-
result = message;
|
|
2235
|
-
} else {
|
|
2236
|
-
result = message.replace(/\{(\d+)\}/g, (match, rest) => {
|
|
2237
|
-
const index = rest[0];
|
|
2238
|
-
const arg = args[index];
|
|
2239
|
-
let result2 = match;
|
|
2240
|
-
if (typeof arg === "string") {
|
|
2241
|
-
result2 = arg;
|
|
2242
|
-
} else if (typeof arg === "number" || typeof arg === "boolean" || arg === void 0 || arg === null) {
|
|
2243
|
-
result2 = String(arg);
|
|
2244
|
-
}
|
|
2245
|
-
return result2;
|
|
2246
|
-
});
|
|
2247
|
-
}
|
|
2248
|
-
if (isPseudo) {
|
|
2249
|
-
result = "\uFF3B" + result.replace(/[aouei]/g, "$&$&") + "\uFF3D";
|
|
2250
|
-
}
|
|
2251
|
-
return result;
|
|
2252
|
-
}
|
|
2253
|
-
var initialized = false;
|
|
2254
|
-
var locale = void 0;
|
|
2255
|
-
var translations = {};
|
|
2256
|
-
function localizeWithPath(path, data, defaultMessage, ...args) {
|
|
2257
|
-
initialized = true;
|
|
2258
|
-
const key = typeof data === "object" ? data.key : data;
|
|
2259
|
-
const message = (translations[path] ?? {})[key] ?? defaultMessage;
|
|
2260
|
-
return _format(message, args);
|
|
2261
|
-
}
|
|
2262
|
-
function getConfiguredDefaultLocale(_) {
|
|
2263
|
-
return locale;
|
|
2264
|
-
}
|
|
2265
|
-
|
|
2266
2294
|
// node_modules/vscode/vscode/src/vs/base/common/platform.js
|
|
2267
2295
|
var LANGUAGE_DEFAULT = "en";
|
|
2268
2296
|
var _isWindows = false;
|
|
@@ -2277,6 +2305,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
2277
2305
|
var _locale = void 0;
|
|
2278
2306
|
var _language = LANGUAGE_DEFAULT;
|
|
2279
2307
|
var _platformLocale = LANGUAGE_DEFAULT;
|
|
2308
|
+
var _translationsConfigFile = void 0;
|
|
2280
2309
|
var _userAgent = void 0;
|
|
2281
2310
|
var $globalThis = globalThis;
|
|
2282
2311
|
var nodeProcess = void 0;
|
|
@@ -2299,10 +2328,10 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
2299
2328
|
if (rawNlsConfig) {
|
|
2300
2329
|
try {
|
|
2301
2330
|
const nlsConfig = JSON.parse(rawNlsConfig);
|
|
2302
|
-
|
|
2303
|
-
_locale = nlsConfig.locale;
|
|
2331
|
+
_locale = nlsConfig.userLocale;
|
|
2304
2332
|
_platformLocale = nlsConfig.osLocale;
|
|
2305
|
-
_language =
|
|
2333
|
+
_language = nlsConfig.resolvedLanguage || LANGUAGE_DEFAULT;
|
|
2334
|
+
_translationsConfigFile = nlsConfig.languagePack?.translationsConfigFile;
|
|
2306
2335
|
} catch (e) {
|
|
2307
2336
|
}
|
|
2308
2337
|
}
|
|
@@ -2315,10 +2344,9 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
2315
2344
|
_isLinux = _userAgent.indexOf("Linux") >= 0;
|
|
2316
2345
|
_isMobile = _userAgent?.indexOf("Mobi") >= 0;
|
|
2317
2346
|
_isWeb = true;
|
|
2318
|
-
|
|
2319
|
-
_locale =
|
|
2320
|
-
|
|
2321
|
-
_platformLocale = navigator.language;
|
|
2347
|
+
_language = globalThis._VSCODE_NLS_LANGUAGE || LANGUAGE_DEFAULT;
|
|
2348
|
+
_locale = navigator.language.toLowerCase();
|
|
2349
|
+
_platformLocale = _locale;
|
|
2322
2350
|
} else {
|
|
2323
2351
|
console.error("Unable to resolve platform.");
|
|
2324
2352
|
}
|
|
@@ -3042,8 +3070,8 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
3042
3070
|
filteredLocales = ["_default"];
|
|
3043
3071
|
}
|
|
3044
3072
|
let languageSpecificMap = void 0;
|
|
3045
|
-
for (const
|
|
3046
|
-
const map2 = arrayToMap(data[
|
|
3073
|
+
for (const locale of filteredLocales) {
|
|
3074
|
+
const map2 = arrayToMap(data[locale]);
|
|
3047
3075
|
languageSpecificMap = intersectMaps(languageSpecificMap, map2);
|
|
3048
3076
|
}
|
|
3049
3077
|
const commonMap = arrayToMap(data["_common"]);
|
|
@@ -4333,7 +4361,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4333
4361
|
return sandboxProcess.cwd();
|
|
4334
4362
|
}
|
|
4335
4363
|
};
|
|
4336
|
-
} else if (typeof process !== "undefined") {
|
|
4364
|
+
} else if (typeof process !== "undefined" && typeof process?.versions?.node === "string") {
|
|
4337
4365
|
safeProcess = {
|
|
4338
4366
|
get platform() {
|
|
4339
4367
|
return process.platform;
|
|
@@ -4476,10 +4504,13 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4476
4504
|
}
|
|
4477
4505
|
return res;
|
|
4478
4506
|
}
|
|
4479
|
-
function
|
|
4507
|
+
function formatExt(ext) {
|
|
4508
|
+
return ext ? `${ext[0] === "." ? "" : "."}${ext}` : "";
|
|
4509
|
+
}
|
|
4510
|
+
function _format(sep2, pathObject) {
|
|
4480
4511
|
validateObject(pathObject, "pathObject");
|
|
4481
4512
|
const dir = pathObject.dir || pathObject.root;
|
|
4482
|
-
const base = pathObject.base || `${pathObject.name || ""}${pathObject.ext
|
|
4513
|
+
const base = pathObject.base || `${pathObject.name || ""}${formatExt(pathObject.ext)}`;
|
|
4483
4514
|
if (!dir) {
|
|
4484
4515
|
return base;
|
|
4485
4516
|
}
|
|
@@ -4494,7 +4525,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4494
4525
|
let path;
|
|
4495
4526
|
if (i >= 0) {
|
|
4496
4527
|
path = pathSegments[i];
|
|
4497
|
-
validateString(path,
|
|
4528
|
+
validateString(path, `paths[${i}]`);
|
|
4498
4529
|
if (path.length === 0) {
|
|
4499
4530
|
continue;
|
|
4500
4531
|
}
|
|
@@ -4862,9 +4893,9 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4862
4893
|
}
|
|
4863
4894
|
return path.slice(0, end);
|
|
4864
4895
|
},
|
|
4865
|
-
basename(path,
|
|
4866
|
-
if (
|
|
4867
|
-
validateString(
|
|
4896
|
+
basename(path, suffix) {
|
|
4897
|
+
if (suffix !== void 0) {
|
|
4898
|
+
validateString(suffix, "suffix");
|
|
4868
4899
|
}
|
|
4869
4900
|
validateString(path, "path");
|
|
4870
4901
|
let start = 0;
|
|
@@ -4874,11 +4905,11 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4874
4905
|
if (path.length >= 2 && isWindowsDeviceRoot(path.charCodeAt(0)) && path.charCodeAt(1) === CHAR_COLON) {
|
|
4875
4906
|
start = 2;
|
|
4876
4907
|
}
|
|
4877
|
-
if (
|
|
4878
|
-
if (
|
|
4908
|
+
if (suffix !== void 0 && suffix.length > 0 && suffix.length <= path.length) {
|
|
4909
|
+
if (suffix === path) {
|
|
4879
4910
|
return "";
|
|
4880
4911
|
}
|
|
4881
|
-
let extIdx =
|
|
4912
|
+
let extIdx = suffix.length - 1;
|
|
4882
4913
|
let firstNonSlashEnd = -1;
|
|
4883
4914
|
for (i = path.length - 1; i >= start; --i) {
|
|
4884
4915
|
const code = path.charCodeAt(i);
|
|
@@ -4893,7 +4924,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4893
4924
|
firstNonSlashEnd = i + 1;
|
|
4894
4925
|
}
|
|
4895
4926
|
if (extIdx >= 0) {
|
|
4896
|
-
if (code ===
|
|
4927
|
+
if (code === suffix.charCodeAt(extIdx)) {
|
|
4897
4928
|
if (--extIdx === -1) {
|
|
4898
4929
|
end = i;
|
|
4899
4930
|
}
|
|
@@ -4966,7 +4997,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
4966
4997
|
}
|
|
4967
4998
|
return path.slice(startDot, end);
|
|
4968
4999
|
},
|
|
4969
|
-
format:
|
|
5000
|
+
format: _format.bind(null, "\\"),
|
|
4970
5001
|
parse(path) {
|
|
4971
5002
|
validateString(path, "path");
|
|
4972
5003
|
const ret = { root: "", dir: "", base: "", ext: "", name: "" };
|
|
@@ -5093,7 +5124,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
5093
5124
|
let resolvedAbsolute = false;
|
|
5094
5125
|
for (let i = pathSegments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
|
|
5095
5126
|
const path = i >= 0 ? pathSegments[i] : posixCwd();
|
|
5096
|
-
validateString(path,
|
|
5127
|
+
validateString(path, `paths[${i}]`);
|
|
5097
5128
|
if (path.length === 0) {
|
|
5098
5129
|
continue;
|
|
5099
5130
|
}
|
|
@@ -5230,20 +5261,20 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
5230
5261
|
}
|
|
5231
5262
|
return path.slice(0, end);
|
|
5232
5263
|
},
|
|
5233
|
-
basename(path,
|
|
5234
|
-
if (
|
|
5235
|
-
validateString(
|
|
5264
|
+
basename(path, suffix) {
|
|
5265
|
+
if (suffix !== void 0) {
|
|
5266
|
+
validateString(suffix, "ext");
|
|
5236
5267
|
}
|
|
5237
5268
|
validateString(path, "path");
|
|
5238
5269
|
let start = 0;
|
|
5239
5270
|
let end = -1;
|
|
5240
5271
|
let matchedSlash = true;
|
|
5241
5272
|
let i;
|
|
5242
|
-
if (
|
|
5243
|
-
if (
|
|
5273
|
+
if (suffix !== void 0 && suffix.length > 0 && suffix.length <= path.length) {
|
|
5274
|
+
if (suffix === path) {
|
|
5244
5275
|
return "";
|
|
5245
5276
|
}
|
|
5246
|
-
let extIdx =
|
|
5277
|
+
let extIdx = suffix.length - 1;
|
|
5247
5278
|
let firstNonSlashEnd = -1;
|
|
5248
5279
|
for (i = path.length - 1; i >= 0; --i) {
|
|
5249
5280
|
const code = path.charCodeAt(i);
|
|
@@ -5258,7 +5289,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
5258
5289
|
firstNonSlashEnd = i + 1;
|
|
5259
5290
|
}
|
|
5260
5291
|
if (extIdx >= 0) {
|
|
5261
|
-
if (code ===
|
|
5292
|
+
if (code === suffix.charCodeAt(extIdx)) {
|
|
5262
5293
|
if (--extIdx === -1) {
|
|
5263
5294
|
end = i;
|
|
5264
5295
|
}
|
|
@@ -5327,7 +5358,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
5327
5358
|
}
|
|
5328
5359
|
return path.slice(startDot, end);
|
|
5329
5360
|
},
|
|
5330
|
-
format:
|
|
5361
|
+
format: _format.bind(null, "/"),
|
|
5331
5362
|
parse(path) {
|
|
5332
5363
|
validateString(path, "path");
|
|
5333
5364
|
const ret = { root: "", dir: "", base: "", ext: "", name: "" };
|
|
@@ -5595,6 +5626,9 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
5595
5626
|
return result;
|
|
5596
5627
|
}
|
|
5597
5628
|
}
|
|
5629
|
+
[Symbol.for("debug.description")]() {
|
|
5630
|
+
return `URI(${this.toString()})`;
|
|
5631
|
+
}
|
|
5598
5632
|
};
|
|
5599
5633
|
var _pathSepMarker = isWindows ? 1 : void 0;
|
|
5600
5634
|
var Uri = class extends URI {
|
|
@@ -8471,8 +8505,50 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
8471
8505
|
}
|
|
8472
8506
|
};
|
|
8473
8507
|
|
|
8508
|
+
// node_modules/vscode/vscode/src/vs/nls.js
|
|
8509
|
+
var isPseudo = globalThis._VSCODE_NLS_LANGUAGE === "pseudo" || typeof document !== "undefined" && document.location && document.location.hash.indexOf("pseudo=true") >= 0;
|
|
8510
|
+
function _format2(message, args) {
|
|
8511
|
+
let result;
|
|
8512
|
+
if (args.length === 0) {
|
|
8513
|
+
result = message;
|
|
8514
|
+
} else {
|
|
8515
|
+
result = message.replace(/\{(\d+)\}/g, (match, rest) => {
|
|
8516
|
+
const index = rest[0];
|
|
8517
|
+
const arg = args[index];
|
|
8518
|
+
let result2 = match;
|
|
8519
|
+
if (typeof arg === "string") {
|
|
8520
|
+
result2 = arg;
|
|
8521
|
+
} else if (typeof arg === "number" || typeof arg === "boolean" || arg === void 0 || arg === null) {
|
|
8522
|
+
result2 = String(arg);
|
|
8523
|
+
}
|
|
8524
|
+
return result2;
|
|
8525
|
+
});
|
|
8526
|
+
}
|
|
8527
|
+
if (isPseudo) {
|
|
8528
|
+
result = "\uFF3B" + result.replace(/[aouei]/g, "$&$&") + "\uFF3D";
|
|
8529
|
+
}
|
|
8530
|
+
return result;
|
|
8531
|
+
}
|
|
8532
|
+
var initialized = false;
|
|
8533
|
+
function localize(data, message, ...args) {
|
|
8534
|
+
if (typeof data === "number") {
|
|
8535
|
+
return _format2(lookupMessage(data, message), args);
|
|
8536
|
+
}
|
|
8537
|
+
return _format2(message, args);
|
|
8538
|
+
}
|
|
8539
|
+
function lookupMessage(index, fallback) {
|
|
8540
|
+
initialized = true;
|
|
8541
|
+
const message = globalThis._VSCODE_NLS_MESSAGES?.[index];
|
|
8542
|
+
if (typeof message !== "string") {
|
|
8543
|
+
if (typeof fallback === "string") {
|
|
8544
|
+
return fallback;
|
|
8545
|
+
}
|
|
8546
|
+
throw new Error(`!!! NLS MISSING: ${index} !!!`);
|
|
8547
|
+
}
|
|
8548
|
+
return message;
|
|
8549
|
+
}
|
|
8550
|
+
|
|
8474
8551
|
// node_modules/vscode/vscode/src/vs/editor/common/languages.js
|
|
8475
|
-
var _moduleId = "vs/editor/common/languages";
|
|
8476
8552
|
var Token = class {
|
|
8477
8553
|
constructor(offset, type, language2) {
|
|
8478
8554
|
this.offset = offset;
|
|
@@ -8680,32 +8756,32 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
8680
8756
|
SymbolKind4[SymbolKind4["TypeParameter"] = 25] = "TypeParameter";
|
|
8681
8757
|
})(SymbolKind || (SymbolKind = {}));
|
|
8682
8758
|
var symbolKindNames = {
|
|
8683
|
-
[SymbolKind.Array]:
|
|
8684
|
-
[SymbolKind.Boolean]:
|
|
8685
|
-
[SymbolKind.Class]:
|
|
8686
|
-
[SymbolKind.Constant]:
|
|
8687
|
-
[SymbolKind.Constructor]:
|
|
8688
|
-
[SymbolKind.Enum]:
|
|
8689
|
-
[SymbolKind.EnumMember]:
|
|
8690
|
-
[SymbolKind.Event]:
|
|
8691
|
-
[SymbolKind.Field]:
|
|
8692
|
-
[SymbolKind.File]:
|
|
8693
|
-
[SymbolKind.Function]:
|
|
8694
|
-
[SymbolKind.Interface]:
|
|
8695
|
-
[SymbolKind.Key]:
|
|
8696
|
-
[SymbolKind.Method]:
|
|
8697
|
-
[SymbolKind.Module]:
|
|
8698
|
-
[SymbolKind.Namespace]:
|
|
8699
|
-
[SymbolKind.Null]:
|
|
8700
|
-
[SymbolKind.Number]:
|
|
8701
|
-
[SymbolKind.Object]:
|
|
8702
|
-
[SymbolKind.Operator]:
|
|
8703
|
-
[SymbolKind.Package]:
|
|
8704
|
-
[SymbolKind.Property]:
|
|
8705
|
-
[SymbolKind.String]:
|
|
8706
|
-
[SymbolKind.Struct]:
|
|
8707
|
-
[SymbolKind.TypeParameter]:
|
|
8708
|
-
[SymbolKind.Variable]:
|
|
8759
|
+
[SymbolKind.Array]: localize(1658, "array"),
|
|
8760
|
+
[SymbolKind.Boolean]: localize(1659, "boolean"),
|
|
8761
|
+
[SymbolKind.Class]: localize(1660, "class"),
|
|
8762
|
+
[SymbolKind.Constant]: localize(1661, "constant"),
|
|
8763
|
+
[SymbolKind.Constructor]: localize(1662, "constructor"),
|
|
8764
|
+
[SymbolKind.Enum]: localize(1663, "enumeration"),
|
|
8765
|
+
[SymbolKind.EnumMember]: localize(1664, "enumeration member"),
|
|
8766
|
+
[SymbolKind.Event]: localize(1665, "event"),
|
|
8767
|
+
[SymbolKind.Field]: localize(1666, "field"),
|
|
8768
|
+
[SymbolKind.File]: localize(1667, "file"),
|
|
8769
|
+
[SymbolKind.Function]: localize(1668, "function"),
|
|
8770
|
+
[SymbolKind.Interface]: localize(1669, "interface"),
|
|
8771
|
+
[SymbolKind.Key]: localize(1670, "key"),
|
|
8772
|
+
[SymbolKind.Method]: localize(1671, "method"),
|
|
8773
|
+
[SymbolKind.Module]: localize(1672, "module"),
|
|
8774
|
+
[SymbolKind.Namespace]: localize(1673, "namespace"),
|
|
8775
|
+
[SymbolKind.Null]: localize(1674, "null"),
|
|
8776
|
+
[SymbolKind.Number]: localize(1675, "number"),
|
|
8777
|
+
[SymbolKind.Object]: localize(1676, "object"),
|
|
8778
|
+
[SymbolKind.Operator]: localize(1677, "operator"),
|
|
8779
|
+
[SymbolKind.Package]: localize(1678, "package"),
|
|
8780
|
+
[SymbolKind.Property]: localize(1679, "property"),
|
|
8781
|
+
[SymbolKind.String]: localize(1680, "string"),
|
|
8782
|
+
[SymbolKind.Struct]: localize(1681, "struct"),
|
|
8783
|
+
[SymbolKind.TypeParameter]: localize(1682, "type parameter"),
|
|
8784
|
+
[SymbolKind.Variable]: localize(1683, "variable")
|
|
8709
8785
|
};
|
|
8710
8786
|
var SymbolTag;
|
|
8711
8787
|
(function(SymbolTag4) {
|
|
@@ -9017,68 +9093,69 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
9017
9093
|
EditorOption2[EditorOption2["pasteAs"] = 85] = "pasteAs";
|
|
9018
9094
|
EditorOption2[EditorOption2["parameterHints"] = 86] = "parameterHints";
|
|
9019
9095
|
EditorOption2[EditorOption2["peekWidgetDefaultFocus"] = 87] = "peekWidgetDefaultFocus";
|
|
9020
|
-
EditorOption2[EditorOption2["
|
|
9021
|
-
EditorOption2[EditorOption2["
|
|
9022
|
-
EditorOption2[EditorOption2["
|
|
9023
|
-
EditorOption2[EditorOption2["
|
|
9024
|
-
EditorOption2[EditorOption2["
|
|
9025
|
-
EditorOption2[EditorOption2["
|
|
9026
|
-
EditorOption2[EditorOption2["
|
|
9027
|
-
EditorOption2[EditorOption2["
|
|
9028
|
-
EditorOption2[EditorOption2["
|
|
9029
|
-
EditorOption2[EditorOption2["
|
|
9030
|
-
EditorOption2[EditorOption2["
|
|
9031
|
-
EditorOption2[EditorOption2["
|
|
9032
|
-
EditorOption2[EditorOption2["
|
|
9033
|
-
EditorOption2[EditorOption2["
|
|
9034
|
-
EditorOption2[EditorOption2["
|
|
9035
|
-
EditorOption2[EditorOption2["
|
|
9036
|
-
EditorOption2[EditorOption2["
|
|
9037
|
-
EditorOption2[EditorOption2["
|
|
9038
|
-
EditorOption2[EditorOption2["
|
|
9039
|
-
EditorOption2[EditorOption2["
|
|
9040
|
-
EditorOption2[EditorOption2["
|
|
9041
|
-
EditorOption2[EditorOption2["
|
|
9042
|
-
EditorOption2[EditorOption2["
|
|
9043
|
-
EditorOption2[EditorOption2["
|
|
9044
|
-
EditorOption2[EditorOption2["
|
|
9045
|
-
EditorOption2[EditorOption2["
|
|
9046
|
-
EditorOption2[EditorOption2["
|
|
9047
|
-
EditorOption2[EditorOption2["
|
|
9048
|
-
EditorOption2[EditorOption2["
|
|
9049
|
-
EditorOption2[EditorOption2["
|
|
9050
|
-
EditorOption2[EditorOption2["
|
|
9051
|
-
EditorOption2[EditorOption2["
|
|
9052
|
-
EditorOption2[EditorOption2["
|
|
9053
|
-
EditorOption2[EditorOption2["
|
|
9054
|
-
EditorOption2[EditorOption2["
|
|
9055
|
-
EditorOption2[EditorOption2["
|
|
9056
|
-
EditorOption2[EditorOption2["
|
|
9057
|
-
EditorOption2[EditorOption2["
|
|
9058
|
-
EditorOption2[EditorOption2["
|
|
9059
|
-
EditorOption2[EditorOption2["
|
|
9060
|
-
EditorOption2[EditorOption2["
|
|
9061
|
-
EditorOption2[EditorOption2["
|
|
9062
|
-
EditorOption2[EditorOption2["
|
|
9063
|
-
EditorOption2[EditorOption2["
|
|
9064
|
-
EditorOption2[EditorOption2["
|
|
9065
|
-
EditorOption2[EditorOption2["
|
|
9066
|
-
EditorOption2[EditorOption2["
|
|
9067
|
-
EditorOption2[EditorOption2["
|
|
9068
|
-
EditorOption2[EditorOption2["
|
|
9069
|
-
EditorOption2[EditorOption2["
|
|
9070
|
-
EditorOption2[EditorOption2["
|
|
9071
|
-
EditorOption2[EditorOption2["
|
|
9072
|
-
EditorOption2[EditorOption2["
|
|
9073
|
-
EditorOption2[EditorOption2["
|
|
9074
|
-
EditorOption2[EditorOption2["
|
|
9075
|
-
EditorOption2[EditorOption2["
|
|
9076
|
-
EditorOption2[EditorOption2["
|
|
9077
|
-
EditorOption2[EditorOption2["
|
|
9078
|
-
EditorOption2[EditorOption2["
|
|
9079
|
-
EditorOption2[EditorOption2["
|
|
9080
|
-
EditorOption2[EditorOption2["
|
|
9081
|
-
EditorOption2[EditorOption2["
|
|
9096
|
+
EditorOption2[EditorOption2["placeholder"] = 88] = "placeholder";
|
|
9097
|
+
EditorOption2[EditorOption2["definitionLinkOpensInPeek"] = 89] = "definitionLinkOpensInPeek";
|
|
9098
|
+
EditorOption2[EditorOption2["quickSuggestions"] = 90] = "quickSuggestions";
|
|
9099
|
+
EditorOption2[EditorOption2["quickSuggestionsDelay"] = 91] = "quickSuggestionsDelay";
|
|
9100
|
+
EditorOption2[EditorOption2["readOnly"] = 92] = "readOnly";
|
|
9101
|
+
EditorOption2[EditorOption2["readOnlyMessage"] = 93] = "readOnlyMessage";
|
|
9102
|
+
EditorOption2[EditorOption2["renameOnType"] = 94] = "renameOnType";
|
|
9103
|
+
EditorOption2[EditorOption2["renderControlCharacters"] = 95] = "renderControlCharacters";
|
|
9104
|
+
EditorOption2[EditorOption2["renderFinalNewline"] = 96] = "renderFinalNewline";
|
|
9105
|
+
EditorOption2[EditorOption2["renderLineHighlight"] = 97] = "renderLineHighlight";
|
|
9106
|
+
EditorOption2[EditorOption2["renderLineHighlightOnlyWhenFocus"] = 98] = "renderLineHighlightOnlyWhenFocus";
|
|
9107
|
+
EditorOption2[EditorOption2["renderValidationDecorations"] = 99] = "renderValidationDecorations";
|
|
9108
|
+
EditorOption2[EditorOption2["renderWhitespace"] = 100] = "renderWhitespace";
|
|
9109
|
+
EditorOption2[EditorOption2["revealHorizontalRightPadding"] = 101] = "revealHorizontalRightPadding";
|
|
9110
|
+
EditorOption2[EditorOption2["roundedSelection"] = 102] = "roundedSelection";
|
|
9111
|
+
EditorOption2[EditorOption2["rulers"] = 103] = "rulers";
|
|
9112
|
+
EditorOption2[EditorOption2["scrollbar"] = 104] = "scrollbar";
|
|
9113
|
+
EditorOption2[EditorOption2["scrollBeyondLastColumn"] = 105] = "scrollBeyondLastColumn";
|
|
9114
|
+
EditorOption2[EditorOption2["scrollBeyondLastLine"] = 106] = "scrollBeyondLastLine";
|
|
9115
|
+
EditorOption2[EditorOption2["scrollPredominantAxis"] = 107] = "scrollPredominantAxis";
|
|
9116
|
+
EditorOption2[EditorOption2["selectionClipboard"] = 108] = "selectionClipboard";
|
|
9117
|
+
EditorOption2[EditorOption2["selectionHighlight"] = 109] = "selectionHighlight";
|
|
9118
|
+
EditorOption2[EditorOption2["selectOnLineNumbers"] = 110] = "selectOnLineNumbers";
|
|
9119
|
+
EditorOption2[EditorOption2["showFoldingControls"] = 111] = "showFoldingControls";
|
|
9120
|
+
EditorOption2[EditorOption2["showUnused"] = 112] = "showUnused";
|
|
9121
|
+
EditorOption2[EditorOption2["snippetSuggestions"] = 113] = "snippetSuggestions";
|
|
9122
|
+
EditorOption2[EditorOption2["smartSelect"] = 114] = "smartSelect";
|
|
9123
|
+
EditorOption2[EditorOption2["smoothScrolling"] = 115] = "smoothScrolling";
|
|
9124
|
+
EditorOption2[EditorOption2["stickyScroll"] = 116] = "stickyScroll";
|
|
9125
|
+
EditorOption2[EditorOption2["stickyTabStops"] = 117] = "stickyTabStops";
|
|
9126
|
+
EditorOption2[EditorOption2["stopRenderingLineAfter"] = 118] = "stopRenderingLineAfter";
|
|
9127
|
+
EditorOption2[EditorOption2["suggest"] = 119] = "suggest";
|
|
9128
|
+
EditorOption2[EditorOption2["suggestFontSize"] = 120] = "suggestFontSize";
|
|
9129
|
+
EditorOption2[EditorOption2["suggestLineHeight"] = 121] = "suggestLineHeight";
|
|
9130
|
+
EditorOption2[EditorOption2["suggestOnTriggerCharacters"] = 122] = "suggestOnTriggerCharacters";
|
|
9131
|
+
EditorOption2[EditorOption2["suggestSelection"] = 123] = "suggestSelection";
|
|
9132
|
+
EditorOption2[EditorOption2["tabCompletion"] = 124] = "tabCompletion";
|
|
9133
|
+
EditorOption2[EditorOption2["tabIndex"] = 125] = "tabIndex";
|
|
9134
|
+
EditorOption2[EditorOption2["unicodeHighlighting"] = 126] = "unicodeHighlighting";
|
|
9135
|
+
EditorOption2[EditorOption2["unusualLineTerminators"] = 127] = "unusualLineTerminators";
|
|
9136
|
+
EditorOption2[EditorOption2["useShadowDOM"] = 128] = "useShadowDOM";
|
|
9137
|
+
EditorOption2[EditorOption2["useTabStops"] = 129] = "useTabStops";
|
|
9138
|
+
EditorOption2[EditorOption2["wordBreak"] = 130] = "wordBreak";
|
|
9139
|
+
EditorOption2[EditorOption2["wordSegmenterLocales"] = 131] = "wordSegmenterLocales";
|
|
9140
|
+
EditorOption2[EditorOption2["wordSeparators"] = 132] = "wordSeparators";
|
|
9141
|
+
EditorOption2[EditorOption2["wordWrap"] = 133] = "wordWrap";
|
|
9142
|
+
EditorOption2[EditorOption2["wordWrapBreakAfterCharacters"] = 134] = "wordWrapBreakAfterCharacters";
|
|
9143
|
+
EditorOption2[EditorOption2["wordWrapBreakBeforeCharacters"] = 135] = "wordWrapBreakBeforeCharacters";
|
|
9144
|
+
EditorOption2[EditorOption2["wordWrapColumn"] = 136] = "wordWrapColumn";
|
|
9145
|
+
EditorOption2[EditorOption2["wordWrapOverride1"] = 137] = "wordWrapOverride1";
|
|
9146
|
+
EditorOption2[EditorOption2["wordWrapOverride2"] = 138] = "wordWrapOverride2";
|
|
9147
|
+
EditorOption2[EditorOption2["wrappingIndent"] = 139] = "wrappingIndent";
|
|
9148
|
+
EditorOption2[EditorOption2["wrappingStrategy"] = 140] = "wrappingStrategy";
|
|
9149
|
+
EditorOption2[EditorOption2["showDeprecated"] = 141] = "showDeprecated";
|
|
9150
|
+
EditorOption2[EditorOption2["inlayHints"] = 142] = "inlayHints";
|
|
9151
|
+
EditorOption2[EditorOption2["editorClassName"] = 143] = "editorClassName";
|
|
9152
|
+
EditorOption2[EditorOption2["pixelRatio"] = 144] = "pixelRatio";
|
|
9153
|
+
EditorOption2[EditorOption2["tabFocusMode"] = 145] = "tabFocusMode";
|
|
9154
|
+
EditorOption2[EditorOption2["layoutInfo"] = 146] = "layoutInfo";
|
|
9155
|
+
EditorOption2[EditorOption2["wrappingInfo"] = 147] = "wrappingInfo";
|
|
9156
|
+
EditorOption2[EditorOption2["defaultColorDecorators"] = 148] = "defaultColorDecorators";
|
|
9157
|
+
EditorOption2[EditorOption2["colorDecoratorsActivatedOn"] = 149] = "colorDecoratorsActivatedOn";
|
|
9158
|
+
EditorOption2[EditorOption2["inlineCompletionsAccessibilityVerbose"] = 150] = "inlineCompletionsAccessibilityVerbose";
|
|
9082
9159
|
})(EditorOption || (EditorOption = {}));
|
|
9083
9160
|
var EndOfLinePreference;
|
|
9084
9161
|
(function(EndOfLinePreference3) {
|
|
@@ -10478,7 +10555,35 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
10478
10555
|
));
|
|
10479
10556
|
}
|
|
10480
10557
|
}
|
|
10558
|
+
toRangeMapping2(original, modified) {
|
|
10559
|
+
if (isValidLineNumber(this.original.endLineNumberExclusive, original) && isValidLineNumber(this.modified.endLineNumberExclusive, modified)) {
|
|
10560
|
+
return new RangeMapping(new Range(this.original.startLineNumber, 1, this.original.endLineNumberExclusive, 1), new Range(this.modified.startLineNumber, 1, this.modified.endLineNumberExclusive, 1));
|
|
10561
|
+
}
|
|
10562
|
+
if (!this.original.isEmpty && !this.modified.isEmpty) {
|
|
10563
|
+
return new RangeMapping(Range.fromPositions(new Position(this.original.startLineNumber, 1), normalizePosition(new Position(this.original.endLineNumberExclusive - 1, Number.MAX_SAFE_INTEGER), original)), Range.fromPositions(new Position(this.modified.startLineNumber, 1), normalizePosition(new Position(this.modified.endLineNumberExclusive - 1, Number.MAX_SAFE_INTEGER), modified)));
|
|
10564
|
+
}
|
|
10565
|
+
if (this.original.startLineNumber > 1 && this.modified.startLineNumber > 1) {
|
|
10566
|
+
return new RangeMapping(Range.fromPositions(normalizePosition(new Position(this.original.startLineNumber - 1, Number.MAX_SAFE_INTEGER), original), normalizePosition(new Position(this.original.endLineNumberExclusive - 1, Number.MAX_SAFE_INTEGER), original)), Range.fromPositions(normalizePosition(new Position(this.modified.startLineNumber - 1, Number.MAX_SAFE_INTEGER), modified), normalizePosition(new Position(this.modified.endLineNumberExclusive - 1, Number.MAX_SAFE_INTEGER), modified)));
|
|
10567
|
+
}
|
|
10568
|
+
throw new BugIndicatingError();
|
|
10569
|
+
}
|
|
10481
10570
|
};
|
|
10571
|
+
function normalizePosition(position, content) {
|
|
10572
|
+
if (position.lineNumber < 1) {
|
|
10573
|
+
return new Position(1, 1);
|
|
10574
|
+
}
|
|
10575
|
+
if (position.lineNumber > content.length) {
|
|
10576
|
+
return new Position(content.length, content[content.length - 1].length + 1);
|
|
10577
|
+
}
|
|
10578
|
+
const line = content[position.lineNumber - 1];
|
|
10579
|
+
if (position.column > line.length + 1) {
|
|
10580
|
+
return new Position(position.lineNumber, line.length + 1);
|
|
10581
|
+
}
|
|
10582
|
+
return position;
|
|
10583
|
+
}
|
|
10584
|
+
function isValidLineNumber(lineNumber, lines) {
|
|
10585
|
+
return lineNumber >= 1 && lineNumber <= lines.length;
|
|
10586
|
+
}
|
|
10482
10587
|
var DetailedLineRangeMapping = class _DetailedLineRangeMapping extends LineRangeMapping {
|
|
10483
10588
|
static fromRangeMappings(rangeMappings) {
|
|
10484
10589
|
const originalRange = LineRange.join(rangeMappings.map((r) => LineRange.fromRangeInclusive(r.originalRange)));
|
|
@@ -10497,6 +10602,15 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
10497
10602
|
}
|
|
10498
10603
|
};
|
|
10499
10604
|
var RangeMapping = class _RangeMapping {
|
|
10605
|
+
static assertSorted(rangeMappings) {
|
|
10606
|
+
for (let i = 1; i < rangeMappings.length; i++) {
|
|
10607
|
+
const previous = rangeMappings[i - 1];
|
|
10608
|
+
const current = rangeMappings[i];
|
|
10609
|
+
if (!(previous.originalRange.getEndPosition().isBeforeOrEqual(current.originalRange.getStartPosition()) && previous.modifiedRange.getEndPosition().isBeforeOrEqual(current.modifiedRange.getStartPosition()))) {
|
|
10610
|
+
throw new BugIndicatingError("Range mappings must be sorted");
|
|
10611
|
+
}
|
|
10612
|
+
}
|
|
10613
|
+
}
|
|
10500
10614
|
constructor(originalRange, modifiedRange) {
|
|
10501
10615
|
this.originalRange = originalRange;
|
|
10502
10616
|
this.modifiedRange = modifiedRange;
|
|
@@ -11022,6 +11136,17 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
11022
11136
|
static fromOffsetPairs(start, endExclusive) {
|
|
11023
11137
|
return new _SequenceDiff(new OffsetRange(start.offset1, endExclusive.offset1), new OffsetRange(start.offset2, endExclusive.offset2));
|
|
11024
11138
|
}
|
|
11139
|
+
static assertSorted(sequenceDiffs) {
|
|
11140
|
+
let last = void 0;
|
|
11141
|
+
for (const cur of sequenceDiffs) {
|
|
11142
|
+
if (last) {
|
|
11143
|
+
if (!(last.seq1Range.endExclusive <= cur.seq1Range.start && last.seq2Range.endExclusive <= cur.seq2Range.start)) {
|
|
11144
|
+
throw new BugIndicatingError("Sequence diffs must be sorted");
|
|
11145
|
+
}
|
|
11146
|
+
}
|
|
11147
|
+
last = cur;
|
|
11148
|
+
}
|
|
11149
|
+
}
|
|
11025
11150
|
constructor(seq1Range, seq2Range) {
|
|
11026
11151
|
this.seq1Range = seq1Range;
|
|
11027
11152
|
this.seq2Range = seq2Range;
|
|
@@ -11395,41 +11520,39 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
11395
11520
|
|
|
11396
11521
|
// node_modules/vscode/vscode/src/vs/editor/common/diff/defaultLinesDiffComputer/linesSliceCharSequence.js
|
|
11397
11522
|
var LinesSliceCharSequence = class {
|
|
11398
|
-
constructor(lines,
|
|
11523
|
+
constructor(lines, range, considerWhitespaceChanges) {
|
|
11399
11524
|
this.lines = lines;
|
|
11525
|
+
this.range = range;
|
|
11400
11526
|
this.considerWhitespaceChanges = considerWhitespaceChanges;
|
|
11401
11527
|
this.elements = [];
|
|
11402
|
-
this.
|
|
11403
|
-
this.
|
|
11404
|
-
|
|
11405
|
-
|
|
11406
|
-
|
|
11407
|
-
|
|
11408
|
-
|
|
11409
|
-
|
|
11410
|
-
|
|
11411
|
-
|
|
11412
|
-
|
|
11413
|
-
|
|
11414
|
-
|
|
11415
|
-
|
|
11416
|
-
line = "";
|
|
11417
|
-
trimFirstLineFully = false;
|
|
11418
|
-
} else if (!considerWhitespaceChanges) {
|
|
11528
|
+
this.firstElementOffsetByLineIdx = [];
|
|
11529
|
+
this.lineStartOffsets = [];
|
|
11530
|
+
this.trimmedWsLengthsByLineIdx = [];
|
|
11531
|
+
this.firstElementOffsetByLineIdx.push(0);
|
|
11532
|
+
for (let lineNumber = this.range.startLineNumber; lineNumber <= this.range.endLineNumber; lineNumber++) {
|
|
11533
|
+
let line = lines[lineNumber - 1];
|
|
11534
|
+
let lineStartOffset = 0;
|
|
11535
|
+
if (lineNumber === this.range.startLineNumber && this.range.startColumn > 1) {
|
|
11536
|
+
lineStartOffset = this.range.startColumn - 1;
|
|
11537
|
+
line = line.substring(lineStartOffset);
|
|
11538
|
+
}
|
|
11539
|
+
this.lineStartOffsets.push(lineStartOffset);
|
|
11540
|
+
let trimmedWsLength = 0;
|
|
11541
|
+
if (!considerWhitespaceChanges) {
|
|
11419
11542
|
const trimmedStartLine = line.trimStart();
|
|
11420
|
-
|
|
11543
|
+
trimmedWsLength = line.length - trimmedStartLine.length;
|
|
11421
11544
|
line = trimmedStartLine.trimEnd();
|
|
11422
11545
|
}
|
|
11423
|
-
this.
|
|
11424
|
-
|
|
11425
|
-
|
|
11546
|
+
this.trimmedWsLengthsByLineIdx.push(trimmedWsLength);
|
|
11547
|
+
const lineLength = lineNumber === this.range.endLineNumber ? Math.min(this.range.endColumn - 1 - lineStartOffset - trimmedWsLength, line.length) : line.length;
|
|
11548
|
+
for (let i = 0; i < lineLength; i++) {
|
|
11549
|
+
this.elements.push(line.charCodeAt(i));
|
|
11426
11550
|
}
|
|
11427
|
-
if (
|
|
11551
|
+
if (lineNumber < this.range.endLineNumber) {
|
|
11428
11552
|
this.elements.push("\n".charCodeAt(0));
|
|
11429
|
-
this.
|
|
11553
|
+
this.firstElementOffsetByLineIdx.push(this.elements.length);
|
|
11430
11554
|
}
|
|
11431
11555
|
}
|
|
11432
|
-
this.additionalOffsetByLine.push(0);
|
|
11433
11556
|
}
|
|
11434
11557
|
toString() {
|
|
11435
11558
|
return `Slice: "${this.text}"`;
|
|
@@ -11466,18 +11589,21 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
11466
11589
|
score2 += getCategoryBoundaryScore(nextCategory);
|
|
11467
11590
|
return score2;
|
|
11468
11591
|
}
|
|
11469
|
-
translateOffset(offset) {
|
|
11470
|
-
|
|
11471
|
-
|
|
11472
|
-
}
|
|
11473
|
-
const i = findLastIdxMonotonous(this.firstCharOffsetByLine, (value) => value <= offset);
|
|
11592
|
+
translateOffset(offset, preference = "right") {
|
|
11593
|
+
const i = findLastIdxMonotonous(this.firstElementOffsetByLineIdx, (value) => value <= offset);
|
|
11594
|
+
const lineOffset = offset - this.firstElementOffsetByLineIdx[i];
|
|
11474
11595
|
return new Position(
|
|
11475
|
-
this.
|
|
11476
|
-
|
|
11596
|
+
this.range.startLineNumber + i,
|
|
11597
|
+
1 + this.lineStartOffsets[i] + lineOffset + (lineOffset === 0 && preference === "left" ? 0 : this.trimmedWsLengthsByLineIdx[i])
|
|
11477
11598
|
);
|
|
11478
11599
|
}
|
|
11479
11600
|
translateRange(range) {
|
|
11480
|
-
|
|
11601
|
+
const pos1 = this.translateOffset(range.start, "right");
|
|
11602
|
+
const pos2 = this.translateOffset(range.endExclusive, "left");
|
|
11603
|
+
if (pos2.isBefore(pos1)) {
|
|
11604
|
+
return Range.fromPositions(pos2, pos2);
|
|
11605
|
+
}
|
|
11606
|
+
return Range.fromPositions(pos1, pos2);
|
|
11481
11607
|
}
|
|
11482
11608
|
findWordContaining(offset) {
|
|
11483
11609
|
if (offset < 0 || offset >= this.elements.length) {
|
|
@@ -11503,8 +11629,8 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
11503
11629
|
return this.elements[offset1] === this.elements[offset2];
|
|
11504
11630
|
}
|
|
11505
11631
|
extendToFullLines(range) {
|
|
11506
|
-
const start = findLastMonotonous(this.
|
|
11507
|
-
const end = findFirstMonotonous(this.
|
|
11632
|
+
const start = findLastMonotonous(this.firstElementOffsetByLineIdx, (x) => x <= range.start) ?? 0;
|
|
11633
|
+
const end = findFirstMonotonous(this.firstElementOffsetByLineIdx, (x) => range.endExclusive <= x) ?? this.elements.length;
|
|
11508
11634
|
return new OffsetRange(start, end);
|
|
11509
11635
|
}
|
|
11510
11636
|
};
|
|
@@ -11749,7 +11875,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
11749
11875
|
return false;
|
|
11750
11876
|
}
|
|
11751
11877
|
const myersDiffingAlgorithm = new MyersDiffAlgorithm();
|
|
11752
|
-
const result = myersDiffingAlgorithm.compute(new LinesSliceCharSequence([line1], new
|
|
11878
|
+
const result = myersDiffingAlgorithm.compute(new LinesSliceCharSequence([line1], new Range(1, 1, 1, line1.length), false), new LinesSliceCharSequence([line2], new Range(1, 1, 1, line2.length), false), timeout);
|
|
11753
11879
|
let commonNonSpaceCharCount = 0;
|
|
11754
11880
|
const inverted = SequenceDiff.invert(result.diffs, line1.length);
|
|
11755
11881
|
for (const seq of inverted) {
|
|
@@ -12290,8 +12416,10 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
12290
12416
|
return movesWithDiffs;
|
|
12291
12417
|
}
|
|
12292
12418
|
refineDiff(originalLines, modifiedLines, diff, timeout, considerWhitespaceChanges) {
|
|
12293
|
-
const
|
|
12294
|
-
const
|
|
12419
|
+
const lineRangeMapping = toLineRangeMapping(diff);
|
|
12420
|
+
const rangeMapping = lineRangeMapping.toRangeMapping2(originalLines, modifiedLines);
|
|
12421
|
+
const slice1 = new LinesSliceCharSequence(originalLines, rangeMapping.originalRange, considerWhitespaceChanges);
|
|
12422
|
+
const slice2 = new LinesSliceCharSequence(modifiedLines, rangeMapping.modifiedRange, considerWhitespaceChanges);
|
|
12295
12423
|
const diffResult = slice1.length + slice2.length < 500 ? this.dynamicProgrammingDiffing.compute(slice1, slice2, timeout) : this.myersDiffingAlgorithm.compute(slice1, slice2, timeout);
|
|
12296
12424
|
let diffs = diffResult.diffs;
|
|
12297
12425
|
diffs = optimizeSequenceDiffs(slice1, slice2, diffs);
|
|
@@ -12348,6 +12476,9 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
12348
12476
|
);
|
|
12349
12477
|
return new DetailedLineRangeMapping(originalLineRange, modifiedLineRange, [rangeMapping]);
|
|
12350
12478
|
}
|
|
12479
|
+
function toLineRangeMapping(sequenceDiff) {
|
|
12480
|
+
return new LineRangeMapping(new LineRange(sequenceDiff.seq1Range.start + 1, sequenceDiff.seq1Range.endExclusive + 1), new LineRange(sequenceDiff.seq2Range.start + 1, sequenceDiff.seq2Range.endExclusive + 1));
|
|
12481
|
+
}
|
|
12351
12482
|
|
|
12352
12483
|
// node_modules/vscode/vscode/src/vs/editor/common/diff/linesDiffComputers.js
|
|
12353
12484
|
var linesDiffComputers = {
|
|
@@ -17950,7 +18081,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
17950
18081
|
}
|
|
17951
18082
|
return s;
|
|
17952
18083
|
}
|
|
17953
|
-
var
|
|
18084
|
+
var _a3 = "a".charCodeAt(0);
|
|
17954
18085
|
var _z = "z".charCodeAt(0);
|
|
17955
18086
|
var _A = "A".charCodeAt(0);
|
|
17956
18087
|
var _Z = "Z".charCodeAt(0);
|
|
@@ -17958,7 +18089,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
17958
18089
|
var _9 = "9".charCodeAt(0);
|
|
17959
18090
|
function isLetterOrDigit(text, index) {
|
|
17960
18091
|
const c = text.charCodeAt(index);
|
|
17961
|
-
return
|
|
18092
|
+
return _a3 <= c && c <= _z || _A <= c && c <= _Z || _0 <= c && c <= _9;
|
|
17962
18093
|
}
|
|
17963
18094
|
function isDefined(obj) {
|
|
17964
18095
|
return typeof obj !== "undefined";
|
|
@@ -29750,7 +29881,7 @@ ${stackTraceFormattedLines.join("\n")}
|
|
|
29750
29881
|
@codingame/monaco-vscode-standalone-html-language-features/worker.js:
|
|
29751
29882
|
(*!-----------------------------------------------------------------------------
|
|
29752
29883
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
29753
|
-
* Version: 0.
|
|
29884
|
+
* Version: 0.51.0(undefined)
|
|
29754
29885
|
* Released under the MIT license
|
|
29755
29886
|
* https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt
|
|
29756
29887
|
*-----------------------------------------------------------------------------*)
|