Skip to content

Commit bdf9f4d

Browse files
committed
remove border above input box
1 parent e4b7cbf commit bdf9f4d

File tree

2 files changed

+17
-18
lines changed

2 files changed

+17
-18
lines changed

.prettierrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
"trailingComma": "all",
55
"semi": true,
66
"singleQuote": false,
7-
"bracketSpacing": false,
7+
"bracketSpacing": true,
88
"plugins": ["prettier-plugin-tailwindcss"]
99
}

gui/src/pages/gui/Chat.tsx

+16-17
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import {
1212
useCallback,
1313
useContext,
1414
useEffect,
15-
useMemo,
1615
useRef,
1716
useState,
1817
} from "react";
@@ -150,16 +149,16 @@ export function Chat() {
150149
useHistory(dispatch);
151150

152151
const scrollToBottom = useCallback(() => {
153-
if (!topGuiDivRef.current) return
152+
if (!topGuiDivRef.current) return;
154153
const elem = topGuiDivRef.current;
155154
elem.scrollTop = elem.scrollHeight - elem.clientHeight;
156155

157156
setIsAtBottom(true);
158-
}, [topGuiDivRef, setIsAtBottom])
157+
}, [topGuiDivRef, setIsAtBottom]);
159158

160159
useEffect(() => {
161-
if (active) scrollToBottom()
162-
}, [active, scrollToBottom])
160+
if (active) scrollToBottom();
161+
}, [active, scrollToBottom]);
163162

164163
useEffect(() => {
165164
// Cmd + Backspace to delete current step
@@ -314,7 +313,7 @@ export function Chat() {
314313
return (
315314
<>
316315
<TopGuiDiv
317-
className={`${state.history.length > 0 ? 'h-full' : ''}`}
316+
className={`${state.history.length > 0 ? "h-full" : ""}`}
318317
ref={topGuiDivRef}
319318
onScroll={handleScroll}
320319
showScrollbar={state.config.ui?.showChatScrollbar || false}
@@ -371,7 +370,7 @@ export function Chat() {
371370
: true
372371
: stepsOpen[index]!
373372
}
374-
onToggle={() => { }}
373+
onToggle={() => {}}
375374
>
376375
<StepContainer
377376
index={index}
@@ -383,14 +382,14 @@ export function Chat() {
383382
: stepsOpen[index]!
384383
}
385384
key={index}
386-
onUserInput={(input: string) => { }}
385+
onUserInput={(input: string) => {}}
387386
item={item}
388-
onReverse={() => { }}
387+
onReverse={() => {}}
389388
onRetry={() => {
390389
streamResponse(
391390
state.history[index - 1].editorState,
392391
state.history[index - 1].modifiers ??
393-
defaultInputModifiers,
392+
defaultInputModifiers,
394393
ideMessenger,
395394
index - 1,
396395
);
@@ -427,8 +426,7 @@ export function Chat() {
427426
/>
428427
</TopGuiDiv>
429428

430-
431-
<div className={`relative ${state.history.length > 0 ? 'pt-1 border-0 border-t border-solid border-t-zinc-700' : ''}`}>
429+
<div className={`relative`}>
432430
<div className="absolute -top-8 right-2 z-30">
433431
{ttsActive && (
434432
<StopButton
@@ -463,10 +461,12 @@ export function Chat() {
463461
sendInput(editorContent, modifiers);
464462
}}
465463
/>
466-
<div style={{
467-
// opacity: active ? 0 : 1,
468-
pointerEvents: active ? 'none' : 'auto',
469-
}}>
464+
<div
465+
style={{
466+
// opacity: active ? 0 : 1,
467+
pointerEvents: active ? "none" : "auto",
468+
}}
469+
>
470470
{state.history.length > 0 ? (
471471
<div className="xs:inline mt-2 hidden">
472472
<NewSessionButton
@@ -516,4 +516,3 @@ export function Chat() {
516516
</>
517517
);
518518
}
519-

0 commit comments

Comments
 (0)