@@ -103,6 +103,7 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
103103 const [ intendedCursorPosition , setIntendedCursorPosition ] = useState < number | null > ( null )
104104 const contextMenuContainerRef = useRef < HTMLDivElement > ( null )
105105 const [ isEnhancingPrompt , setIsEnhancingPrompt ] = useState ( false )
106+ const [ isFocused , setIsFocused ] = useState ( false )
106107
107108 // Fetch git commits when Git is selected or when typing a hash
108109 useEffect ( ( ) => {
@@ -379,6 +380,7 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
379380 if ( ! isMouseDownOnMenu ) {
380381 setShowContextMenu ( false )
381382 }
383+ setIsFocused ( false )
382384 } , [ isMouseDownOnMenu ] )
383385
384386 const handlePaste = useCallback (
@@ -537,6 +539,10 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
537539 backgroundColor : "var(--vscode-input-background)" ,
538540 margin : "10px 15px" ,
539541 padding : "8px" ,
542+ outline : "none" ,
543+ border : "1px solid" ,
544+ borderColor : isFocused ? "var(--vscode-focusBorder)" : "transparent" ,
545+ borderRadius : "2px" ,
540546 } }
541547 onDrop = { async ( e ) => {
542548 e . preventDefault ( )
@@ -627,7 +633,8 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
627633 fontFamily : "var(--vscode-font-family)" ,
628634 fontSize : "var(--vscode-editor-font-size)" ,
629635 lineHeight : "var(--vscode-editor-line-height)" ,
630- padding : "8px" ,
636+ padding : "2px" ,
637+ paddingRight : "8px" ,
631638 marginBottom : thumbnailsHeight > 0 ? `${ thumbnailsHeight + 16 } px` : 0 ,
632639 zIndex : 1 ,
633640 } }
@@ -647,6 +654,7 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
647654 handleInputChange ( e )
648655 updateHighlights ( )
649656 } }
657+ onFocus = { ( ) => setIsFocused ( true ) }
650658 onKeyDown = { handleKeyDown }
651659 onKeyUp = { handleKeyUp }
652660 onBlur = { handleBlur }
@@ -660,11 +668,12 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
660668 onHeightChange ?.( height )
661669 } }
662670 placeholder = { placeholderText }
663- minRows = { 2 }
664- maxRows = { 20 }
671+ minRows = { 3 }
672+ maxRows = { 15 }
665673 autoFocus = { true }
666674 style = { {
667675 width : "100%" ,
676+ outline : "none" ,
668677 boxSizing : "border-box" ,
669678 backgroundColor : "transparent" ,
670679 color : "var(--vscode-input-foreground)" ,
@@ -676,11 +685,13 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
676685 overflowX : "hidden" ,
677686 overflowY : "auto" ,
678687 border : "none" ,
679- padding : "8px" ,
688+ padding : "2px" ,
689+ paddingRight : "8px" ,
680690 marginBottom : thumbnailsHeight > 0 ? `${ thumbnailsHeight + 16 } px` : 0 ,
681691 cursor : textAreaDisabled ? "not-allowed" : undefined ,
682692 flex : "0 1 auto" ,
683693 zIndex : 2 ,
694+ scrollbarWidth : "none" ,
684695 } }
685696 onScroll = { ( ) => updateHighlights ( ) }
686697 />
@@ -696,7 +707,7 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
696707 bottom : "36px" ,
697708 left : "16px" ,
698709 zIndex : 2 ,
699- marginBottom : "8px " ,
710+ marginBottom : "4px " ,
700711 } }
701712 />
702713 ) }
@@ -707,7 +718,7 @@ const ChatTextArea = forwardRef<HTMLTextAreaElement, ChatTextAreaProps>(
707718 justifyContent : "space-between" ,
708719 alignItems : "center" ,
709720 marginTop : "auto" ,
710- paddingTop : "8px " ,
721+ paddingTop : "2px " ,
711722 } } >
712723 < div
713724 style = { {
0 commit comments