diff --git a/packages/amazonq/src/lsp/chat/webviewProvider.ts b/packages/amazonq/src/lsp/chat/webviewProvider.ts index 7bfab17f3ae..e762b63f913 100644 --- a/packages/amazonq/src/lsp/chat/webviewProvider.ts +++ b/packages/amazonq/src/lsp/chat/webviewProvider.ts @@ -13,6 +13,7 @@ import { Uri, } from 'vscode' import { LanguageServerResolver } from 'aws-core-vscode/shared' +import { QuickActionCommandGroup } from '@aws/mynah-ui' export class AmazonQChatViewProvider implements WebviewViewProvider { public static readonly viewType = 'aws.amazonq.AmazonQChatView' @@ -21,6 +22,24 @@ export class AmazonQChatViewProvider implements WebviewViewProvider { webview: Webview | undefined + private readonly quickActionCommands: QuickActionCommandGroup[] = [ + { + groupName: 'Quick Actions', + commands: [ + { + command: '/help', + icon: 'help', + description: 'Learn more about Amazon Q', + }, + { + command: '/clear', + icon: 'trash', + description: 'Clear this session', + }, + ], + }, + ] + constructor(private readonly mynahUIPath: string) {} public resolveWebviewView(webviewView: WebviewView, context: WebviewViewResolveContext, _token: CancellationToken) { @@ -34,40 +53,40 @@ export class AmazonQChatViewProvider implements WebviewViewProvider { } const uiPath = webviewView.webview.asWebviewUri(Uri.parse(this.mynahUIPath)).toString() - webviewView.webview.html = getWebviewContent(uiPath) + webviewView.webview.html = this.getWebviewContent(uiPath) this.onDidResolveWebviewEmitter.fire() } -} -function getWebviewContent(mynahUIPath: string) { - return ` - - - - - - Chat - - - - - - - ` + private getWebviewContent(mynahUIPath: string) { + return ` + + + + + + Chat + + + + + + + ` + } }