Skip to content

Commit 7468b02

Browse files
committed
Refine Chat Input copy actions and update the Browser Extension Message background styling
1 parent 4afdc13 commit 7468b02

3 files changed

Lines changed: 15 additions & 8 deletions

File tree

‎packages/ui/src/components/editor/panel/BrowserExtensionMessage/BrowserExtensionMessage.module.scss‎

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,13 @@
33
flex-direction: column;
44
align-items: flex-start;
55
gap: var(--padding-4px);
6-
padding: var(--padding-6px) var(--padding-8px);
6+
padding: var(--padding-6px) var(--padding-8px)
7+
calc(var(--padding-6px) + var(--padding-5px)) var(--padding-8px);
8+
margin-bottom: calc(var(--padding-5px) * -1);
79
background: linear-gradient(
8-
150deg,
9-
var(--vscode-inputOption-activeBackground),
10-
var(--vscode-sideBar-background)
10+
135deg,
11+
rgba(255, 0, 221, 0.1) 0%,
12+
rgba(37, 94, 209, 0.1) 100%
1113
);
1214
color: var(--vscode-inputOption-activeForeground);
1315
--border-radius: var(--border-radius-8px);

‎packages/ui/src/components/editor/panel/ChatInput/ChatInput.module.scss‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,10 @@
231231
&--chevron.codicon::before {
232232
font-size: 11px;
233233
}
234+
235+
&--copy {
236+
width: 20px;
237+
}
234238
}
235239

236240
&__dropdown {
@@ -258,7 +262,7 @@
258262

259263
&:hover {
260264
background-color: var(--vscode-menu-selectionBackground);
261-
color: var(--vscode-menu-selectionForeground);
265+
color: var(--vscode-menu-selectionForeground) !important;
262266
}
263267

264268
&__shortcut {

‎packages/ui/src/components/editor/panel/ChatInput/ChatInput.tsx‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ export const ChatInput: React.FC<ChatInputProps> = (props) => {
115115
const custom_handle_key_down = (
116116
e: React.KeyboardEvent<HTMLTextAreaElement>
117117
) => {
118-
if (e.key === 'Tab' && !e.shiftKey) {
118+
if (e.key == 'Tab' && !e.shiftKey) {
119119
const textarea = e.currentTarget
120120
const value = textarea.value
121121
const selection_start = textarea.selectionStart
@@ -310,7 +310,7 @@ export const ChatInput: React.FC<ChatInputProps> = (props) => {
310310
}
311311
onClick={handle_copy_click}
312312
>
313-
Copy
313+
Copy prompt
314314
<span
315315
className={
316316
styles[
@@ -330,14 +330,15 @@ export const ChatInput: React.FC<ChatInputProps> = (props) => {
330330
<button
331331
className={cn(
332332
styles['footer__right__submit__button'],
333+
styles['footer__right__submit__button--copy'],
333334
'codicon',
334335
'codicon-copy'
335336
)}
336337
onClick={(e) => {
337338
e.stopPropagation()
338339
props.on_copy()
339340
}}
340-
title="Copy to clipboard"
341+
title="Copy prompt"
341342
/>
342343
)}
343344
</div>

0 commit comments

Comments
 (0)