Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,6 @@
// --- Workbench ---
// "application.experimental.rendererProfiling": true, // https://github.com/microsoft/vscode/issues/265654
"editor.aiStats.enabled": true, // Team selfhosting on ai stats
"chat.emptyState.history.enabled": true,
"chat.promptFilesRecommendations": {
"plan-fast": true,
"plan-deep": true
Expand Down
2 changes: 1 addition & 1 deletion src/vs/base/common/product.ts
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ export interface IProductConfiguration {
readonly commonlyUsedSettings?: string[];
readonly aiGeneratedWorkspaceTrust?: IAiGeneratedWorkspaceTrust;

readonly defaultChatAgent?: IDefaultChatAgent;
readonly defaultChatAgent: IDefaultChatAgent;
readonly chatParticipantRegistry?: string;
readonly chatSessionRecommendations?: IChatSessionRecommendation[];
readonly emergencyAlertUrl?: string;
Expand Down
1 change: 0 additions & 1 deletion src/vs/platform/actions/common/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,6 @@ export class MenuId {
static readonly ChatCodeBlock = new MenuId('ChatCodeblock');
static readonly ChatCompareBlock = new MenuId('ChatCompareBlock');
static readonly ChatMessageTitle = new MenuId('ChatMessageTitle');
static readonly ChatHistory = new MenuId('ChatHistory');
static readonly ChatWelcomeContext = new MenuId('ChatWelcomeContext');
static readonly ChatMessageFooter = new MenuId('ChatMessageFooter');
static readonly ChatExecute = new MenuId('ChatExecute');
Expand Down
34 changes: 1 addition & 33 deletions src/vs/workbench/contrib/chat/browser/actions/chatActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -512,21 +512,13 @@ export function registerChatActions() {
menu: [
{
id: MenuId.ViewTitle,
when: ContextKeyExpr.and(
ContextKeyExpr.equals('view', ChatViewId),
ChatContextKeys.inEmptyStateWithHistoryEnabled.negate()
),
when: ContextKeyExpr.equals('view', ChatViewId),
group: '2_history',
order: 1
},
{
id: MenuId.EditorTitle,
when: ActiveEditorContext.isEqualTo(ChatEditorInput.EditorID),
},
{
id: MenuId.ChatHistory,
when: ChatContextKeys.inEmptyStateWithHistoryEnabled,
group: 'navigation',
}
],
category: CHAT_CATEGORY,
Expand Down Expand Up @@ -1848,27 +1840,3 @@ registerAction2(class EditToolApproval extends Action2 {
confirmationService.manageConfirmationPreferences([...toolsService.getTools()], scope ? { defaultScope: scope } : undefined);
}
});

// Register actions for chat welcome history context menu
registerAction2(class ToggleChatHistoryVisibilityAction extends Action2 {
constructor() {
super({
id: 'workbench.action.chat.toggleChatHistoryVisibility',
title: localize2('chat.toggleChatHistoryVisibility.label', "Chat History"),
category: CHAT_CATEGORY,
precondition: ChatContextKeys.enabled,
toggled: ContextKeyExpr.equals('config.chat.emptyState.history.enabled', true),
menu: {
id: MenuId.ChatWelcomeContext,
group: '1_modify',
order: 1
}
});
}

async run(accessor: ServicesAccessor): Promise<void> {
const configurationService = accessor.get(IConfigurationService);
const current = configurationService.getValue<boolean>('chat.emptyState.history.enabled');
await configurationService.updateValue('chat.emptyState.history.enabled', !current);
}
});
6 changes: 0 additions & 6 deletions src/vs/workbench/contrib/chat/browser/chat.contribution.ts
Original file line number Diff line number Diff line change
Expand Up @@ -357,12 +357,6 @@ configurationRegistry.registerConfiguration({
enum: ['inline', 'hover', 'input', 'none'],
default: 'inline',
},
[ChatConfiguration.EmptyStateHistoryEnabled]: {
type: 'boolean',
default: product.quality === 'insiders',
description: nls.localize('chat.emptyState.history.enabled', "Show recent chat history on the empty chat state."),
tags: ['preview']
},
[ChatConfiguration.NotifyWindowOnResponseReceived]: {
type: 'boolean',
default: true,
Expand Down
337 changes: 9 additions & 328 deletions src/vs/workbench/contrib/chat/browser/chatWidget.ts

Large diffs are not rendered by default.

104 changes: 0 additions & 104 deletions src/vs/workbench/contrib/chat/browser/media/chatViewWelcome.css
Original file line number Diff line number Diff line change
Expand Up @@ -223,107 +223,3 @@ div.chat-welcome-view {
}
}

.chat-welcome-history-root {
width: 100%;
padding: 8px;

.chat-welcome-history-header {
display: flex;
align-items: center;
justify-content: space-between;
padding: 2px 4px 2px 4px;
font-size: 11px;
text-transform: uppercase;
letter-spacing: 0.5px;
min-height: 22px;
color: var(--vscode-descriptionForeground);

.chat-welcome-history-header-toolbar {
padding-right: 15px;
}
}

.chat-welcome-history-header-title {
font-size: 11px;
padding-left: 8px;
}

.chat-welcome-history-header-actions {
display: flex;
align-items: center;
gap: 4px;
padding-right: 16px;
}


.chat-welcome-history {
margin: 0 8px 8px 8px;
width: 100%;
}

.chat-welcome-history-list {
display: flex;
flex-direction: column;
border-radius: 4px;
overflow: hidden;
box-sizing: border-box;
padding: 0 16px 0 0;
}

.chat-welcome-history-item {
display: flex;
flex-direction: row;
border-radius: 4px;
align-items: center;
justify-content: space-between;
padding: 2px 12px 4px 12px;
gap: 8px;
outline: none;

.chat-welcome-history-title {
font-size: 13px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
flex: 1 1 auto;
}

.chat-welcome-history-date {
font-size: 11px;
color: var(--vscode-descriptionForeground);
flex: 0 0 auto;
margin-left: 8px;
}
}

.chat-welcome-history-more {
color: var(--vscode-textLink-foreground);
text-decoration: none;
cursor: pointer;
padding: 2px 12px 4px 12px;
border: none;
background: none;
text-align: left;
height: 22px;
display: flex;
align-items: center;
border-radius: 4px;
box-sizing: border-box;
margin-right: 14px;

&:hover {
background: var(--vscode-list-hoverBackground);
}

&:focus {
outline: 1px solid var(--vscode-focusBorder);
outline-offset: -1px;
}
}
}

/* Chat history hover tooltip styling */
.chat-history-item-hover {
max-width: 300px;
word-wrap: break-word;
}
2 changes: 0 additions & 2 deletions src/vs/workbench/contrib/chat/common/chatContextKeys.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,6 @@ export namespace ChatContextKeys {

export const panelLocation = new RawContextKey<ViewContainerLocation>('chatPanelLocation', undefined, { type: 'number', description: localize('chatPanelLocation', "The location of the chat panel.") });

export const inEmptyStateWithHistoryEnabled = new RawContextKey<boolean>('chatInEmptyStateWithHistoryEnabled', false, { type: 'boolean', description: localize('chatInEmptyStateWithHistoryEnabled', "True when chat empty state history is enabled AND chat is in empty state.") });

export const sessionType = new RawContextKey<string>('chatSessionType', '', { type: 'string', description: localize('chatSessionType', "The type of the current chat session item.") });
export const isArchivedItem = new RawContextKey<boolean>('chatIsArchivedItem', false, { type: 'boolean', description: localize('chatIsArchivedItem', "True when the chat session item is archived.") });
export const isCombinedSessionViewer = new RawContextKey<boolean>('chatIsCombinedSessionViewer', false, { type: 'boolean', description: localize('chatIsCombinedSessionViewer', "True when the chat session viewer uses the new combined style.") }); // TODO@bpasero eventually retire this context key
Expand Down
1 change: 0 additions & 1 deletion src/vs/workbench/contrib/chat/common/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ export enum ChatConfiguration {
ThinkingStyle = 'chat.agent.thinkingStyle',
TodosShowWidget = 'chat.tools.todos.showWidget',
ShowAgentSessionsViewDescription = 'chat.showAgentSessionsViewDescription',
EmptyStateHistoryEnabled = 'chat.emptyState.history.enabled',
NotifyWindowOnResponseReceived = 'chat.notifyWindowOnResponseReceived',
SubagentToolCustomAgents = 'chat.customAgentInSubagent.enabled',
ShowCodeBlockProgressAnimation = 'chat.agent.codeBlockProgress',
Expand Down
Loading