mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-23 01:58:53 +01:00
Add SignatureInformation.activateParmater
For #94637 Allows the active paramter to be be specified per signature instead of for all signatures. If provided, this overrides `SignatureHelp.activeParamter`
This commit is contained in:
@@ -939,7 +939,8 @@ export namespace SignatureInformation {
|
||||
return {
|
||||
label: info.label,
|
||||
documentation: info.documentation ? MarkdownString.fromStrict(info.documentation) : undefined,
|
||||
parameters: Array.isArray(info.parameters) ? info.parameters.map(ParameterInformation.from) : []
|
||||
parameters: Array.isArray(info.parameters) ? info.parameters.map(ParameterInformation.from) : [],
|
||||
activeParameter: info.activeParameter,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -947,7 +948,8 @@ export namespace SignatureInformation {
|
||||
return {
|
||||
label: info.label,
|
||||
documentation: htmlContent.isMarkdownString(info.documentation) ? MarkdownString.to(info.documentation) : info.documentation,
|
||||
parameters: Array.isArray(info.parameters) ? info.parameters.map(ParameterInformation.to) : []
|
||||
parameters: Array.isArray(info.parameters) ? info.parameters.map(ParameterInformation.to) : [],
|
||||
activeParameter: info.activeParameter,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1291,6 +1291,7 @@ export class SignatureInformation {
|
||||
label: string;
|
||||
documentation?: string | MarkdownString;
|
||||
parameters: ParameterInformation[];
|
||||
activeParameter?: number;
|
||||
|
||||
constructor(label: string, documentation?: string | MarkdownString) {
|
||||
this.label = label;
|
||||
|
||||
Reference in New Issue
Block a user