Skip to content

Commit

Permalink
Update edits agent mode welcome view message
Browse files Browse the repository at this point in the history
Add "agent mode" subtitle
  • Loading branch information
roblourens committed Jan 29, 2025
1 parent 2c56755 commit 6c09b22
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
17 changes: 11 additions & 6 deletions src/vs/workbench/contrib/chat/browser/media/chatViewWelcome.css
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,18 @@ div.chat-welcome-view {
text-align: center;
}

& > .chat-welcome-view-indicator {
color: var(--vscode-badge-foreground);
background: var(--vscode-badge-background);
padding: 1px 8px;
border-radius: 14px;
& > .chat-welcome-view-indicator-container {
display: flex;
margin-top: 10px;
font-size: 11px;
gap: 9px;

& > .chat-welcome-view-indicator {
font-size: 11px;
color: var(--vscode-badge-foreground);
background: var(--vscode-badge-background);
padding: 1px 8px;
border-radius: 14px;
}
}

& > .chat-welcome-view-message {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,11 @@ export class ChatViewWelcomePart extends Disposable {
// Preview indicator
if (options?.location === ChatAgentLocation.EditingSession && typeof content.message !== 'function' && chatAgentService.toolsAgentModeEnabled) {
// Override welcome message for the agent. Sort of a hack, should it come from the participant? This case is different because the welcome content typically doesn't change per ChatWidget
content.message = new MarkdownString('Ask Copilot to edit your files in agent mode. Copilot will automatically use multiple requests to pick files to edit, run terminal commands, and iterate on errors.\n\nCopilot is powered by AI, so mistakes are possible. Review output carefully before use.');
const featureIndicator = dom.append(this.element, $('.chat-welcome-view-indicator'));
featureIndicator.textContent = localize('experimental', "EXPERIMENTAL");
const agentMessage = localize({ key: 'agentMessage', comment: ['{Locked="["}', '{Locked="]({0})"}'] }, "Ask Copilot to edit your files in [agent mode]({0}). Copilot will automatically use multiple requests to pick files to edit, run terminal commands, and iterate on errors.\n\nCopilot is powered by AI, so mistakes are possible. Review output carefully before use.", 'https://aka.ms/vscode-copilot-agent');
content.message = new MarkdownString(agentMessage);
const container = dom.append(this.element, $('.chat-welcome-view-indicator-container'));
dom.append(container, $('.chat-welcome-view-subtitle', undefined, localize('agentModeSubtitle', "Agent Mode")));
dom.append(container, $('.chat-welcome-view-indicator', undefined, localize('experimental', "EXPERIMENTAL")));
}

// Message
Expand Down

0 comments on commit 6c09b22

Please sign in to comment.