@volar/language-server 1.4.0-alpha.2 → 1.4.0-alpha.4
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/out/browser/fileSystems.js +1 -0
- package/out/browser/index.js +1 -0
- package/out/browser/typescript/core.js +1 -0
- package/out/browser/typescript/corePublic.js +1 -0
- package/out/browser/typescript/path.js +1 -0
- package/out/browser/typescript/types.js +1 -0
- package/out/browser/typescript/utilities.js +1 -0
- package/out/common/cancellationPipe.js +1 -0
- package/out/common/configurationHost.js +1 -0
- package/out/common/documents.js +1 -0
- package/out/common/features/customFeatures.js +1 -0
- package/out/common/features/languageFeatures.js +1 -13
- package/out/common/project.d.ts +5 -5
- package/out/common/project.js +3 -1
- package/out/common/schemaRequestHandlers/file.js +1 -0
- package/out/common/schemaRequestHandlers/http.js +1 -0
- package/out/common/server.js +8 -0
- package/out/common/utils/inferredCompilerOptions.js +1 -0
- package/out/common/utils/isFileInDir.js +1 -0
- package/out/common/utils/registerFeatures.js +4 -5
- package/out/common/utils/serverConfig.js +1 -0
- package/out/common/utils/uriMap.js +1 -0
- package/out/common/workspace.d.ts +47 -46
- package/out/common/workspace.js +20 -3
- package/out/common/workspaces.d.ts +55 -55
- package/out/common/workspaces.js +1 -0
- package/out/index.js +1 -0
- package/out/node/fileSystem.js +1 -0
- package/out/node/index.js +1 -0
- package/out/protocol.d.ts +0 -6
- package/out/protocol.js +2 -5
- package/out/types.js +1 -0
- package/package.json +4 -4
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="typesafe-path" />
|
|
2
|
+
import * as path from 'typesafe-path/posix';
|
|
2
3
|
import type * as ts from 'typescript/lib/tsserverlibrary';
|
|
3
4
|
import * as vscode from 'vscode-languageserver';
|
|
4
5
|
import { URI } from 'vscode-uri';
|
|
@@ -12,7 +13,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
12
13
|
projects: {
|
|
13
14
|
clear: () => void;
|
|
14
15
|
values: () => IterableIterator<Promise<{
|
|
15
|
-
tsConfig:
|
|
16
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
16
17
|
scripts: {
|
|
17
18
|
clear: () => void;
|
|
18
19
|
values: () => IterableIterator<{
|
|
@@ -71,13 +72,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
71
72
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
72
73
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
73
74
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
74
|
-
doValidation: (uri: string, mode: "
|
|
75
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
75
76
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
76
77
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
77
78
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
78
79
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
79
80
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
80
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
81
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
81
82
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
82
83
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
83
84
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -117,13 +118,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
117
118
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
118
119
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
119
120
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
120
|
-
doValidation: (uri: string, mode: "
|
|
121
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
121
122
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
122
123
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
123
124
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
124
125
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
125
126
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
126
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
127
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
127
128
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
128
129
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
129
130
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -154,7 +155,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
154
155
|
}>>;
|
|
155
156
|
uriDelete: (_uri: string) => boolean;
|
|
156
157
|
uriGet: (_uri: string) => Promise<{
|
|
157
|
-
tsConfig:
|
|
158
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
158
159
|
scripts: {
|
|
159
160
|
clear: () => void;
|
|
160
161
|
values: () => IterableIterator<{
|
|
@@ -213,13 +214,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
213
214
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
214
215
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
215
216
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
216
|
-
doValidation: (uri: string, mode: "
|
|
217
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
217
218
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
218
219
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
219
220
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
220
221
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
221
222
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
222
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
223
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
223
224
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
224
225
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
225
226
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -259,13 +260,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
259
260
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
260
261
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
261
262
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
262
|
-
doValidation: (uri: string, mode: "
|
|
263
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
263
264
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
264
265
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
265
266
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
266
267
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
267
268
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
268
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
269
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
269
270
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
270
271
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
271
272
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -296,7 +297,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
296
297
|
}> | undefined;
|
|
297
298
|
uriHas: (_uri: string) => boolean;
|
|
298
299
|
uriSet: (_uri: string, item: Promise<{
|
|
299
|
-
tsConfig:
|
|
300
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
300
301
|
scripts: {
|
|
301
302
|
clear: () => void;
|
|
302
303
|
values: () => IterableIterator<{
|
|
@@ -355,13 +356,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
355
356
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
356
357
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
357
358
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
358
|
-
doValidation: (uri: string, mode: "
|
|
359
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
359
360
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
360
361
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
361
362
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
362
363
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
363
364
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
364
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
365
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
365
366
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
366
367
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
367
368
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -401,13 +402,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
401
402
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
402
403
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
403
404
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
404
|
-
doValidation: (uri: string, mode: "
|
|
405
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
405
406
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
406
407
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
407
408
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
408
409
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
409
410
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
410
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
411
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
411
412
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
412
413
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
413
414
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -438,7 +439,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
438
439
|
}>) => void;
|
|
439
440
|
pathDelete: (path: string) => boolean;
|
|
440
441
|
pathGet: (path: string) => Promise<{
|
|
441
|
-
tsConfig:
|
|
442
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
442
443
|
scripts: {
|
|
443
444
|
clear: () => void;
|
|
444
445
|
values: () => IterableIterator<{
|
|
@@ -497,13 +498,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
497
498
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
498
499
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
499
500
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
500
|
-
doValidation: (uri: string, mode: "
|
|
501
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
501
502
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
502
503
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
503
504
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
504
505
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
505
506
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
506
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
507
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
507
508
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
508
509
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
509
510
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -543,13 +544,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
543
544
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
544
545
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
545
546
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
546
|
-
doValidation: (uri: string, mode: "
|
|
547
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
547
548
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
548
549
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
549
550
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
550
551
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
551
552
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
552
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
553
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
553
554
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
554
555
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
555
556
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -579,7 +580,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
579
580
|
dispose: () => void;
|
|
580
581
|
}> | undefined;
|
|
581
582
|
pathHas: (path: string) => Promise<{
|
|
582
|
-
tsConfig:
|
|
583
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
583
584
|
scripts: {
|
|
584
585
|
clear: () => void;
|
|
585
586
|
values: () => IterableIterator<{
|
|
@@ -638,13 +639,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
638
639
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
639
640
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
640
641
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
641
|
-
doValidation: (uri: string, mode: "
|
|
642
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
642
643
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
643
644
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
644
645
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
645
646
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
646
647
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
647
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
648
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
648
649
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
649
650
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
650
651
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -684,13 +685,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
684
685
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
685
686
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
686
687
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
687
|
-
doValidation: (uri: string, mode: "
|
|
688
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
688
689
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
689
690
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
690
691
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
691
692
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
692
693
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
693
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
694
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
694
695
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
695
696
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
696
697
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -720,7 +721,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
720
721
|
dispose: () => void;
|
|
721
722
|
}> | undefined;
|
|
722
723
|
pathSet: (path: string, item: Promise<{
|
|
723
|
-
tsConfig:
|
|
724
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
724
725
|
scripts: {
|
|
725
726
|
clear: () => void;
|
|
726
727
|
values: () => IterableIterator<{
|
|
@@ -779,13 +780,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
779
780
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
780
781
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
781
782
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
782
|
-
doValidation: (uri: string, mode: "
|
|
783
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
783
784
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
784
785
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
785
786
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
786
787
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
787
788
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
788
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
789
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
789
790
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
790
791
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
791
792
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -825,13 +826,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
825
826
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
826
827
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
827
828
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
828
|
-
doValidation: (uri: string, mode: "
|
|
829
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
829
830
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
830
831
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
831
832
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
832
833
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
833
834
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
834
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
835
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
835
836
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
836
837
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
837
838
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -865,7 +866,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
865
866
|
getProjectAndTsConfig: (uri: string) => Promise<{
|
|
866
867
|
tsconfig: string;
|
|
867
868
|
project: {
|
|
868
|
-
tsConfig:
|
|
869
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
869
870
|
scripts: {
|
|
870
871
|
clear: () => void;
|
|
871
872
|
values: () => IterableIterator<{
|
|
@@ -924,13 +925,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
924
925
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
925
926
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
926
927
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
927
|
-
doValidation: (uri: string, mode: "
|
|
928
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
928
929
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
929
930
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
930
931
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
931
932
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
932
933
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
933
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
934
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
934
935
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
935
936
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
936
937
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -970,13 +971,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
970
971
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
971
972
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
972
973
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
973
|
-
doValidation: (uri: string, mode: "
|
|
974
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
974
975
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
975
976
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
976
977
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
977
978
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
978
979
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
979
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
980
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
980
981
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
981
982
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
982
983
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -1007,7 +1008,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
1007
1008
|
} | undefined;
|
|
1008
1009
|
} | undefined>;
|
|
1009
1010
|
getInferredProject: () => Promise<{
|
|
1010
|
-
tsConfig:
|
|
1011
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
1011
1012
|
scripts: {
|
|
1012
1013
|
clear: () => void;
|
|
1013
1014
|
values: () => IterableIterator<{
|
|
@@ -1066,13 +1067,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
1066
1067
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
1067
1068
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
1068
1069
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
1069
|
-
doValidation: (uri: string, mode: "
|
|
1070
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
1070
1071
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
1071
1072
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
1072
1073
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1073
1074
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1074
1075
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1075
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
1076
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
1076
1077
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1077
1078
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1078
1079
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -1112,13 +1113,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
1112
1113
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
1113
1114
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
1114
1115
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
1115
|
-
doValidation: (uri: string, mode: "
|
|
1116
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
1116
1117
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
1117
1118
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
1118
1119
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1119
1120
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1120
1121
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1121
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
1122
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
1122
1123
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1123
1124
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1124
1125
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -1148,7 +1149,7 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
1148
1149
|
dispose: () => void;
|
|
1149
1150
|
}>;
|
|
1150
1151
|
getInferredProjectDontCreate: () => Promise<{
|
|
1151
|
-
tsConfig:
|
|
1152
|
+
tsConfig: import("typesafe-path").PosixPath | ts.CompilerOptions;
|
|
1152
1153
|
scripts: {
|
|
1153
1154
|
clear: () => void;
|
|
1154
1155
|
values: () => IterableIterator<{
|
|
@@ -1207,13 +1208,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
1207
1208
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
1208
1209
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
1209
1210
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
1210
|
-
doValidation: (uri: string, mode: "
|
|
1211
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
1211
1212
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
1212
1213
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
1213
1214
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1214
1215
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1215
1216
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1216
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
1217
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
1217
1218
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1218
1219
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1219
1220
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
|
@@ -1253,13 +1254,13 @@ export declare function createWorkspace(context: WorkspaceContext): Promise<{
|
|
|
1253
1254
|
findDocumentSymbols: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.DocumentSymbol[] | undefined>;
|
|
1254
1255
|
findDocumentColors: (uri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorInformation[] | undefined>;
|
|
1255
1256
|
getColorPresentations: (uri: string, color: vscode.Color, range: vscode.Range, token?: vscode.CancellationToken | undefined) => Promise<vscode.ColorPresentation[] | undefined>;
|
|
1256
|
-
doValidation: (uri: string, mode: "
|
|
1257
|
+
doValidation: (uri: string, mode: "semantic" | "all" | "syntactic", token?: vscode.CancellationToken | undefined, response?: ((result: vscode.Diagnostic[]) => void) | undefined) => Promise<vscode.Diagnostic[]>;
|
|
1257
1258
|
findReferences: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.Location[] | undefined>;
|
|
1258
1259
|
findFileReferences: (uri: string, token?: vscode.CancellationToken | undefined) => import("@volar/language-service").NullableResult<vscode.Location[]>;
|
|
1259
1260
|
findDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1260
1261
|
findTypeDefinition: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1261
1262
|
findImplementations: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<vscode.LocationLink[] | undefined>;
|
|
1262
|
-
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.
|
|
1263
|
+
prepareRename: (uri: string, position: vscode.Position, token?: vscode.CancellationToken | undefined) => Promise<NonNullable<vscode.ResponseError<void> | vscode.Range | null | undefined> | undefined>;
|
|
1263
1264
|
doRename: (uri: string, position: vscode.Position, newName: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1264
1265
|
getEditsForFileRename: (oldUri: string, newUri: string, token?: vscode.CancellationToken | undefined) => Promise<vscode.WorkspaceEdit | undefined>;
|
|
1265
1266
|
getSemanticTokens: (uri: string, range: vscode.Range | undefined, legend: vscode.SemanticTokensLegend, token?: vscode.CancellationToken | undefined, reportProgress?: ((tokens: vscode.SemanticTokens) => void) | undefined) => Promise<vscode.SemanticTokens | undefined>;
|
package/out/common/workspace.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
1
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2
3
|
exports.sortTsConfigs = exports.createWorkspace = exports.rootTsConfigNames = void 0;
|
|
3
|
-
const path = require("typesafe-path");
|
|
4
|
+
const path = require("typesafe-path/posix");
|
|
4
5
|
const vscode = require("vscode-languageserver");
|
|
5
6
|
const vscode_uri_1 = require("vscode-uri");
|
|
6
7
|
const project_1 = require("./project");
|
|
@@ -15,7 +16,8 @@ async function createWorkspace(context) {
|
|
|
15
16
|
const sys = context.workspaces.fileSystemHost?.getWorkspaceFileSystem(context.rootUri);
|
|
16
17
|
const documentRegistry = sys ? context.workspaces.ts?.createDocumentRegistry(sys.useCaseSensitiveFileNames, uriToFileName(context.rootUri.toString())) : undefined;
|
|
17
18
|
const projects = (0, uriMap_1.createUriMap)(fileNameToUri);
|
|
18
|
-
const rootTsConfigs = new Set(
|
|
19
|
+
const rootTsConfigs = new Set();
|
|
20
|
+
const searchedDirs = new Set();
|
|
19
21
|
const disposeTsConfigWatch = context.workspaces.fileSystemHost?.onDidChangeWatchedFiles(({ changes }) => {
|
|
20
22
|
for (const change of changes) {
|
|
21
23
|
if (exports.rootTsConfigNames.includes(change.uri.substring(change.uri.lastIndexOf('/') + 1))) {
|
|
@@ -83,6 +85,21 @@ async function createWorkspace(context) {
|
|
|
83
85
|
return inferredProject;
|
|
84
86
|
}
|
|
85
87
|
async function findMatchConfigs(uri) {
|
|
88
|
+
const filePath = uriToFileName(uri.toString());
|
|
89
|
+
let dir = path.dirname(filePath);
|
|
90
|
+
while (true) {
|
|
91
|
+
if (searchedDirs.has(dir)) {
|
|
92
|
+
break;
|
|
93
|
+
}
|
|
94
|
+
searchedDirs.add(dir);
|
|
95
|
+
for (const tsConfigName of exports.rootTsConfigNames) {
|
|
96
|
+
const tsconfigPath = path.join(dir, tsConfigName);
|
|
97
|
+
if (sys?.fileExists(tsconfigPath)) {
|
|
98
|
+
rootTsConfigs.add(tsconfigPath);
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
dir = path.dirname(dir);
|
|
102
|
+
}
|
|
86
103
|
await prepareClosestootParsedCommandLine();
|
|
87
104
|
return await findDirectIncludeTsconfig() ?? await findIndirectReferenceTsconfig();
|
|
88
105
|
async function prepareClosestootParsedCommandLine() {
|
|
@@ -142,7 +159,7 @@ async function createWorkspace(context) {
|
|
|
142
159
|
if (parsedCommandLine.projectReferences?.length) {
|
|
143
160
|
const newChains = [];
|
|
144
161
|
for (const projectReference of parsedCommandLine.projectReferences) {
|
|
145
|
-
let tsConfigPath = projectReference.path;
|
|
162
|
+
let tsConfigPath = projectReference.path.replace(/\\/g, '/');
|
|
146
163
|
// fix https://github.com/johnsoncodehk/volar/issues/712
|
|
147
164
|
if (sys && !sys.fileExists(tsConfigPath)) {
|
|
148
165
|
const newTsConfigPath = path.join(tsConfigPath, 'tsconfig.json');
|