Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/sessions/contrib/agentFeedback/browser/media/agentFeedbackEditorWidget.css
13405 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
/* Main widget container - speech bubble style */
7
.agent-feedback-widget {
8
position: absolute;
9
max-width: 280px;
10
min-width: 180px;
11
background-color: var(--vscode-editorWidget-background);
12
border: 1px solid var(--vscode-editorWidget-border, var(--vscode-contrastBorder));
13
border-radius: 8px;
14
box-shadow: var(--vscode-shadow-lg);
15
font-size: 12px;
16
line-height: 1.4;
17
opacity: 0;
18
transition: opacity 0.2s ease-in-out;
19
z-index: 10;
20
}
21
22
.agent-feedback-widget.visible {
23
opacity: 1;
24
}
25
26
.agent-feedback-widget.fadeOut {
27
animation: agentFeedbackFadeOut 150ms ease-out forwards;
28
}
29
30
@keyframes agentFeedbackFadeOut {
31
from { opacity: 1; }
32
to { opacity: 0; }
33
}
34
35
/* Arrow pointer pointing left toward the code */
36
.agent-feedback-widget-arrow {
37
position: absolute;
38
left: -6px;
39
top: 11px;
40
width: 0;
41
height: 0;
42
border-top: 6px solid transparent;
43
border-bottom: 6px solid transparent;
44
border-right: 6px solid var(--vscode-editorWidget-border, var(--vscode-contrastBorder));
45
display: none;
46
}
47
48
.agent-feedback-widget.collapsed .agent-feedback-widget-arrow {
49
display: none;
50
}
51
52
.agent-feedback-widget-arrow::after {
53
content: '';
54
position: absolute;
55
left: 2px;
56
top: -5px;
57
width: 0;
58
height: 0;
59
border-top: 5px solid transparent;
60
border-bottom: 5px solid transparent;
61
border-right: 5px solid var(--vscode-editorWidget-background);
62
}
63
64
/* Header */
65
.agent-feedback-widget-header {
66
display: flex;
67
align-items: center;
68
padding: 4px 4px 4px 8px;
69
border-bottom: 1px solid var(--vscode-editorWidget-border, var(--vscode-widget-border));
70
border-radius: 8px 8px 0 0;
71
overflow: hidden;
72
cursor: pointer;
73
gap: 6px;
74
}
75
76
.agent-feedback-widget.collapsed .agent-feedback-widget-header {
77
border-bottom: none;
78
border-radius: 8px 8px 8px 8px;
79
}
80
81
.agent-feedback-widget-header:hover {
82
background-color: var(--vscode-list-hoverBackground);
83
}
84
85
/* Title */
86
.agent-feedback-widget-title {
87
font-weight: 500;
88
line-height: 12px;
89
color: var(--vscode-foreground);
90
white-space: nowrap;
91
overflow: hidden;
92
text-overflow: ellipsis;
93
min-width: 0;
94
}
95
96
/* Spacer to push buttons to the right */
97
.agent-feedback-widget-spacer {
98
flex: 1;
99
}
100
101
/* Toggle button */
102
.agent-feedback-widget-toggle {
103
display: flex;
104
align-items: center;
105
justify-content: center;
106
width: 22px;
107
height: 22px;
108
min-width: 22px;
109
border-radius: var(--vscode-cornerRadius-medium);
110
cursor: pointer;
111
color: var(--vscode-foreground);
112
opacity: 0.7;
113
transition: opacity 0.1s;
114
}
115
116
.agent-feedback-widget-toggle:hover {
117
opacity: 1;
118
background-color: var(--vscode-toolbar-hoverBackground);
119
}
120
121
/* Dismiss button */
122
/* Body - collapsible */
123
.agent-feedback-widget-body {
124
transition: max-height 0.2s ease-in-out, padding 0.2s ease-in-out;
125
border-radius: 0 0 8px 8px;
126
overflow: hidden;
127
}
128
129
.agent-feedback-widget-body.collapsed {
130
max-height: 0;
131
overflow: hidden;
132
padding: 0;
133
}
134
135
/* Individual feedback item */
136
.agent-feedback-widget-item {
137
display: flex;
138
flex-direction: column;
139
padding: 4px 4px 8px 8px;
140
border-bottom: 1px solid var(--vscode-editorWidget-border, var(--vscode-widget-border));
141
cursor: pointer;
142
position: relative;
143
gap: 6px;
144
}
145
146
.agent-feedback-widget-item:last-child {
147
border-bottom: none;
148
}
149
150
.agent-feedback-widget-item:hover {
151
background-color: var(--vscode-list-hoverBackground);
152
}
153
154
.agent-feedback-widget-item.focused {
155
background-color: var(--vscode-list-activeSelectionBackground);
156
color: var(--vscode-list-activeSelectionForeground);
157
}
158
159
.agent-feedback-widget-item-header {
160
display: flex;
161
align-items: center;
162
justify-content: space-between;
163
gap: 8px;
164
}
165
166
.agent-feedback-widget-item-meta {
167
display: flex;
168
align-items: center;
169
gap: 6px;
170
min-width: 0;
171
flex-wrap: wrap;
172
}
173
174
.agent-feedback-widget-item-actions {
175
margin-left: auto;
176
flex: 0 0 auto;
177
opacity: 0;
178
visibility: hidden;
179
pointer-events: none;
180
}
181
182
.agent-feedback-widget-item:hover .agent-feedback-widget-item-actions {
183
opacity: 1;
184
visibility: visible;
185
pointer-events: auto;
186
}
187
188
.agent-feedback-widget-item-type {
189
display: inline-flex;
190
align-items: center;
191
padding: 1px 6px;
192
border-radius: 4px;
193
font-size: 10px;
194
font-weight: 600;
195
letter-spacing: 0.2px;
196
background: color-mix(in srgb, var(--vscode-editorWidget-border, var(--vscode-widget-border)) 25%, transparent);
197
color: var(--vscode-descriptionForeground);
198
}
199
200
.agent-feedback-widget-item-codeReview .agent-feedback-widget-item-type {
201
background: color-mix(in srgb, var(--vscode-editorWarning-foreground) 22%, var(--vscode-editorWidget-background));
202
color: var(--vscode-editorWarning-foreground);
203
}
204
205
.agent-feedback-widget-item-prReview .agent-feedback-widget-item-type {
206
background: color-mix(in srgb, var(--vscode-editorInfo-foreground) 22%, var(--vscode-editorWidget-background));
207
color: var(--vscode-editorInfo-foreground);
208
}
209
210
/* Line info */
211
.agent-feedback-widget-line-info {
212
font-size: 10px;
213
font-weight: 600;
214
color: var(--vscode-descriptionForeground);
215
text-transform: uppercase;
216
letter-spacing: 0.5px;
217
}
218
219
/* Feedback text */
220
.agent-feedback-widget-text {
221
color: var(--vscode-foreground);
222
word-wrap: break-word;
223
}
224
225
.agent-feedback-widget-text .rendered-markdown p {
226
margin: 0;
227
}
228
229
.agent-feedback-widget-text .rendered-markdown code {
230
font-family: var(--monaco-monospace-font);
231
font-size: 11px;
232
padding: 1px 4px;
233
border-radius: 3px;
234
background: color-mix(in srgb, var(--vscode-editorWidget-border, var(--vscode-widget-border)) 25%, transparent);
235
}
236
237
.agent-feedback-widget-suggestion {
238
display: flex;
239
flex-direction: column;
240
gap: 6px;
241
margin-top: 8px;
242
padding: 0px 8px 4px 12px;
243
}
244
245
.agent-feedback-widget-item-codeReview .agent-feedback-widget-suggestion {
246
border-left: 1px solid color-mix(in srgb, var(--vscode-editorWarning-foreground) 50%, transparent);
247
}
248
249
.agent-feedback-widget-item-prReview .agent-feedback-widget-suggestion {
250
border-left: 1px solid color-mix(in srgb, var(--vscode-editorInfo-foreground) 50%, transparent);
251
}
252
253
.agent-feedback-widget-suggestion-header {
254
font-size: 10px;
255
font-weight: 600;
256
text-transform: uppercase;
257
letter-spacing: 0.4px;
258
color: var(--vscode-descriptionForeground);
259
}
260
261
.agent-feedback-widget-suggestion-edit {
262
display: flex;
263
flex-direction: column;
264
gap: 4px;
265
}
266
267
.agent-feedback-widget-suggestion-text {
268
margin: 0;
269
padding: 6px 8px;
270
border-radius: 4px;
271
overflow-x: auto;
272
white-space: pre-wrap;
273
font-family: var(--monaco-monospace-font);
274
font-size: 11px;
275
line-height: 1.45;
276
background: var(--vscode-editorWidget-background);
277
}
278
279
/* Gutter decoration for range indicator on hover */
280
.agent-feedback-widget-range-glyph {
281
margin-left: 8px;
282
z-index: 5;
283
border-left: 2px solid var(--vscode-editorGutter-modifiedBackground);
284
}
285
286
/* Inline edit textarea */
287
.agent-feedback-widget-text.editing {
288
padding: 0 4px 0 0;
289
}
290
291
.agent-feedback-widget-edit-textarea {
292
width: 100%;
293
min-height: 22px;
294
padding: 4px 6px;
295
border: 1px solid var(--vscode-focusBorder);
296
border-radius: 4px;
297
background: var(--vscode-input-background);
298
color: var(--vscode-input-foreground);
299
font: inherit;
300
font-size: 12px;
301
line-height: 1.4;
302
resize: none;
303
overflow: hidden;
304
box-sizing: border-box;
305
}
306
307
.agent-feedback-widget-edit-textarea:focus {
308
outline: none;
309
border-color: var(--vscode-focusBorder);
310
}
311
312