button color for enter button
This commit is contained in:
parent
98c84117cc
commit
ecdde46e91
4 changed files with 13 additions and 7 deletions
6
extensions/vscode/package-lock.json
generated
6
extensions/vscode/package-lock.json
generated
|
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "continue",
|
||||
"version": "1.1.10",
|
||||
"version": "1.1.11",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "continue",
|
||||
"version": "1.1.10",
|
||||
"version": "1.1.11",
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"@continuedev/fetch": "^1.0.3",
|
||||
|
|
@ -171,7 +171,7 @@
|
|||
"@babel/preset-env": "^7.24.7",
|
||||
"@biomejs/biome": "1.6.4",
|
||||
"@google/generative-ai": "^0.11.4",
|
||||
"@types/diff": "^5.2.2",
|
||||
"@types/diff": "^7.0.1",
|
||||
"@types/follow-redirects": "^1.14.4",
|
||||
"@types/jest": "^29.5.12",
|
||||
"@types/jquery": "^3.5.29",
|
||||
|
|
|
|||
2
gui/package-lock.json
generated
2
gui/package-lock.json
generated
|
|
@ -172,7 +172,7 @@
|
|||
"@babel/preset-env": "^7.24.7",
|
||||
"@biomejs/biome": "1.6.4",
|
||||
"@google/generative-ai": "^0.11.4",
|
||||
"@types/diff": "^5.2.2",
|
||||
"@types/diff": "^7.0.1",
|
||||
"@types/follow-redirects": "^1.14.4",
|
||||
"@types/jest": "^29.5.12",
|
||||
"@types/jquery": "^3.5.29",
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@ import styled from "styled-components";
|
|||
import {
|
||||
defaultBorderRadius,
|
||||
lightGray,
|
||||
vscButtonBackground,
|
||||
vscButtonForeground,
|
||||
vscForeground,
|
||||
vscInputBackground,
|
||||
} from "..";
|
||||
|
|
@ -46,14 +48,15 @@ const StyledDiv = styled.div<{ isHidden?: boolean }>`
|
|||
}
|
||||
`;
|
||||
|
||||
const EnterButton = styled.button`
|
||||
const EnterButton = styled.button<{ isPrimary?: boolean }>`
|
||||
all: unset;
|
||||
padding: 2px 4px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
background-color: ${lightGray}33;
|
||||
background-color: ${(props) =>
|
||||
props.isPrimary ? vscButtonBackground : lightGray + "33"};
|
||||
border-radius: ${defaultBorderRadius};
|
||||
color: ${vscForeground};
|
||||
color: ${(props) => (props.isPrimary ? vscButtonForeground : vscForeground)};
|
||||
cursor: pointer;
|
||||
|
||||
:disabled {
|
||||
|
|
@ -79,6 +82,7 @@ interface InputToolbarProps {
|
|||
activeKey: string | null;
|
||||
toolbarOptions?: ToolbarOptions;
|
||||
disabled?: boolean;
|
||||
isMainInput?: boolean;
|
||||
}
|
||||
|
||||
function InputToolbar(props: InputToolbarProps) {
|
||||
|
|
@ -207,6 +211,7 @@ function InputToolbar(props: InputToolbarProps) {
|
|||
)}
|
||||
|
||||
<EnterButton
|
||||
isPrimary={props.isMainInput}
|
||||
data-testid="submit-input-button"
|
||||
onClick={async (e) => {
|
||||
if (props.onEnter) {
|
||||
|
|
|
|||
|
|
@ -989,6 +989,7 @@ function TipTapEditor(props: TipTapEditorProps) {
|
|||
}}
|
||||
/>
|
||||
<InputToolbar
|
||||
isMainInput={props.isMainInput}
|
||||
toolbarOptions={props.toolbarOptions}
|
||||
activeKey={activeKey}
|
||||
hidden={shouldHideToolbar && !props.isMainInput}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue