mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-09 21:04:49 +08:00
Fix: enable chat input resizing (#12998)
## Summary - add resizable support to shared textarea component - enable vertical resizing for chat inputs in chat and share surfaces - preserve autosize behavior while honoring manual resize height ## Test plan - not run (not requested) Fixes #12803 --------- Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -56,6 +56,7 @@ interface NextMessageInputProps {
|
||||
removeFile?(file: File): void;
|
||||
showReasoning?: boolean;
|
||||
showInternet?: boolean;
|
||||
resize?: 'none' | 'vertical' | 'horizontal' | 'both';
|
||||
}
|
||||
|
||||
export function NextMessageInput({
|
||||
@@ -65,6 +66,7 @@ export function NextMessageInput({
|
||||
sendLoading,
|
||||
disabled,
|
||||
showUploadIcon = true,
|
||||
resize = 'none',
|
||||
onUpload,
|
||||
onInputChange,
|
||||
stopOutputMessage,
|
||||
@@ -211,6 +213,7 @@ export function NextMessageInput({
|
||||
disabled={isUploading || disabled || sendLoading}
|
||||
onKeyDown={handleKeyDown}
|
||||
autoSize={{ minRows: 1, maxRows: 8 }}
|
||||
resize={resize}
|
||||
/>
|
||||
<div className={cn('flex items-center justify-between gap-1.5')}>
|
||||
<div className="flex items-center gap-3">
|
||||
|
||||
Reference in New Issue
Block a user