agents: enhance contrast agent feedback widget 6ce216a8 (#323040)

Agent Host changes for agents/enhance-contrast-agent-feedback-widget-6ce216a8
This commit is contained in:
Benjamin Christopher Simmonds
2026-06-26 10:22:29 +02:00
committed by GitHub
parent 9e4c163169
commit 263f339cfc
3 changed files with 27 additions and 7 deletions

View File

@@ -21,6 +21,8 @@
"--vscode-activityErrorBadge-foreground",
"--vscode-activityWarningBadge-background",
"--vscode-activityWarningBadge-foreground",
"--vscode-agentFeedbackEditorWidget-background",
"--vscode-agentFeedbackEditorWidget-border",
"--vscode-agentFeedbackInputWidget-border",
"--vscode-agentSessionReadIndicator-foreground",
"--vscode-agentSessionSelectedBadge-border",

View File

@@ -11,9 +11,10 @@
// for both the main workbench and the sessions workbench.
import { localize } from '../../nls.js';
import { registerColor, transparent } from '../../platform/theme/common/colorUtils.js';
import { Color } from '../../base/common/color.js';
import { darken, lighten, registerColor, transparent } from '../../platform/theme/common/colorUtils.js';
import { contrastBorder, focusBorder } from '../../platform/theme/common/colorRegistry.js';
import { editorWidgetBorder, editorBackground, toolbarHoverBackground } from '../../platform/theme/common/colors/editorColors.js';
import { editorWidgetBackground, editorWidgetBorder, editorBackground, toolbarHoverBackground } from '../../platform/theme/common/colors/editorColors.js';
import { foreground } from '../../platform/theme/common/colors/baseColors.js';
import { buttonBackground, buttonSecondaryBorder, inputBackground, inputBorder, inputForeground, inputPlaceholderForeground } from '../../platform/theme/common/colors/inputColors.js';
import { ACTIVITY_BAR_BADGE_BACKGROUND, ACTIVITY_BAR_BADGE_FOREGROUND, SIDE_BAR_BACKGROUND, SIDE_BAR_FOREGROUND } from '../../workbench/common/theme.js';
@@ -59,9 +60,21 @@ export const agentsGradientTintColor = registerColor(
);
// ============================================================================
// Agent feedback input widget
// Agent feedback editor widgets
// ============================================================================
export const agentFeedbackEditorWidgetBackground = registerColor(
'agentFeedbackEditorWidget.background',
{ dark: lighten(editorWidgetBackground, 0.08), light: darken(editorWidgetBackground, 0.04), hcDark: Color.black, hcLight: Color.white },
localize('agentFeedbackEditorWidget.background', 'Background color of the agent feedback widget shown in the editor.')
);
export const agentFeedbackEditorWidgetBorder = registerColor(
'agentFeedbackEditorWidget.border',
{ dark: transparent(foreground, 0.35), light: transparent(foreground, 0.35), hcDark: contrastBorder, hcLight: contrastBorder },
localize('agentFeedbackEditorWidget.border', 'Border color of the agent feedback widget shown in the editor.')
);
export const agentFeedbackInputWidgetBorder = registerColor(
'agentFeedbackInputWidget.border',
{ dark: editorWidgetBorder, light: editorWidgetBorder, hcDark: contrastBorder, hcLight: contrastBorder },

View File

@@ -8,8 +8,8 @@
position: absolute;
max-width: 280px;
min-width: 180px;
background-color: var(--vscode-editorWidget-background);
border: 1px solid var(--vscode-editorWidget-border, var(--vscode-contrastBorder));
background-color: var(--vscode-agentFeedbackEditorWidget-background, var(--vscode-editorWidget-background));
border: var(--vscode-strokeThickness) solid var(--vscode-agentFeedbackEditorWidget-border, var(--vscode-editorWidget-border, var(--vscode-contrastBorder)));
border-radius: var(--vscode-cornerRadius-large);
box-shadow: var(--vscode-shadow-lg);
font-size: var(--vscode-agents-fontSize-label1);
@@ -19,6 +19,11 @@
z-index: 10;
}
.hc-black .agent-feedback-widget,
.hc-light .agent-feedback-widget {
box-shadow: none;
}
.agent-feedback-widget.visible {
opacity: 1;
}
@@ -45,7 +50,7 @@
height: 0;
border-top: 6px solid transparent;
border-bottom: 6px solid transparent;
border-right: 6px solid var(--vscode-editorWidget-border, var(--vscode-contrastBorder));
border-right: 6px solid var(--vscode-agentFeedbackEditorWidget-border, var(--vscode-editorWidget-border, var(--vscode-contrastBorder)));
display: none;
}
@@ -62,7 +67,7 @@
height: 0;
border-top: 5px solid transparent;
border-bottom: 5px solid transparent;
border-right: 5px solid var(--vscode-editorWidget-background);
border-right: 5px solid var(--vscode-agentFeedbackEditorWidget-background, var(--vscode-editorWidget-background));
}
/* Header */