mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-21 00:59:03 +01:00
@@ -191,7 +191,6 @@ export default class FileConfigurationManager extends Disposable {
|
||||
includeCompletionsWithClassMemberSnippets: config.get<boolean>('suggest.classMemberSnippets.enabled', true),
|
||||
includeCompletionsWithObjectLiteralMethodSnippets: config.get<boolean>('suggest.objectLiteralMethodSnippets.enabled', true),
|
||||
autoImportFileExcludePatterns: this.getAutoImportFileExcludePatternsPreference(preferencesConfig, vscode.workspace.getWorkspaceFolder(document.uri)?.uri),
|
||||
// @ts-expect-error until 5.3 #56090
|
||||
preferTypeOnlyAutoImports: preferencesConfig.get<boolean>('preferTypeOnlyAutoImports', false),
|
||||
useLabelDetailsInCompletionEntries: true,
|
||||
allowIncompleteCompletions: true,
|
||||
|
||||
@@ -19,70 +19,5 @@ declare module '../../../../node_modules/typescript/lib/typescript' {
|
||||
interface Response {
|
||||
readonly _serverType?: ServerType;
|
||||
}
|
||||
|
||||
//#region MapCode
|
||||
export interface MapCodeRequestArgs extends FileRequestArgs {
|
||||
/**
|
||||
* The files and changes to try and apply/map.
|
||||
*/
|
||||
mapping: MapCodeRequestDocumentMapping;
|
||||
}
|
||||
|
||||
export interface MapCodeRequestDocumentMapping {
|
||||
/**
|
||||
* The specific code to map/insert/replace in the file.
|
||||
*/
|
||||
contents: string[];
|
||||
|
||||
/**
|
||||
* Areas of "focus" to inform the code mapper with. For example, cursor
|
||||
* location, current selection, viewport, etc. Nested arrays denote
|
||||
* priority: toplevel arrays are more important than inner arrays, and
|
||||
* inner array priorities are based on items within that array. Items
|
||||
* earlier in the arrays have higher priority.
|
||||
*/
|
||||
focusLocations?: TextSpan[][];
|
||||
}
|
||||
|
||||
export interface MapCodeRequest extends FileRequest {
|
||||
command: 'mapCode';
|
||||
arguments: MapCodeRequestArgs;
|
||||
}
|
||||
|
||||
export interface MapCodeResponse extends Response {
|
||||
body: FileCodeEdits[]
|
||||
}
|
||||
//#endregion
|
||||
|
||||
//#region Paste
|
||||
export interface GetPasteEditsRequest extends Request {
|
||||
command: 'getPasteEdits';
|
||||
arguments: GetPasteEditsRequestArgs;
|
||||
}
|
||||
|
||||
export interface GetPasteEditsRequestArgs extends FileRequestArgs {
|
||||
/** The text that gets pasted in a file. */
|
||||
pastedText: string[];
|
||||
/** Locations of where the `pastedText` gets added in a file. If the length of the `pastedText` and `pastedLocations` are not the same,
|
||||
* then the `pastedText` is combined into one and added at all the `pastedLocations`.
|
||||
*/
|
||||
pasteLocations: TextSpan[];
|
||||
/** The source location of each `pastedText`. If present, the length of `spans` must be equal to the length of `pastedText`. */
|
||||
copiedFrom?: {
|
||||
file: string;
|
||||
spans: TextSpan[];
|
||||
};
|
||||
}
|
||||
|
||||
export interface GetPasteEditsResponse extends Response {
|
||||
body: PasteEditsAction;
|
||||
}
|
||||
export interface PasteEditsAction {
|
||||
edits: FileCodeEdits[];
|
||||
fixId?: {};
|
||||
}
|
||||
//#endregion
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user