Adopt provideFollowups API change (#978)

This commit is contained in:
Rob Lourens
2024-03-01 11:33:06 -03:00
committed by GitHub
parent aa13e486da
commit d6a2d4f3bc
2 changed files with 3 additions and 3 deletions

View File

@ -72,7 +72,7 @@ export function activate(context: vscode.ExtensionContext) {
cat.isSticky = true; // Cat is persistant, whenever a user starts interacting with @cat, @cat will automatically be added to the following messages
cat.iconPath = vscode.Uri.joinPath(context.extensionUri, 'cat.jpeg');
cat.followupProvider = {
provideFollowups(result: ICatChatResult, token: vscode.CancellationToken) {
provideFollowups(result: ICatChatResult, context: vscode.ChatContext, token: vscode.CancellationToken) {
return [{
prompt: 'let us play',
label: vscode.l10n.t('Play with the cat'),

View File

@ -178,7 +178,7 @@ declare module 'vscode' {
* @param result This instance has the same properties as the result returned from the participant callback, including `metadata`, but is not the same instance.
* @param token A cancellation token.
*/
provideFollowups(result: ChatResult, token: CancellationToken): ProviderResult<ChatFollowup[]>;
provideFollowups(result: ChatResult, context: ChatContext, token: CancellationToken): ProviderResult<ChatFollowup[]>;
}
/**
@ -273,7 +273,7 @@ declare module 'vscode' {
/**
* The prompt as entered by the user.
*
* Information about variables used in this request are is stored in {@link ChatRequest.variables}.
* Information about variables used in this request is stored in {@link ChatRequest.variables}.
*
* *Note* that the {@link ChatParticipant.name name} of the participant and the {@link ChatCommand.name command}
* are not part of the prompt.