Skip to content

Commit

Permalink
refactor: input tag to textarea
Browse files Browse the repository at this point in the history
  • Loading branch information
swgvenghy committed Oct 7, 2024
1 parent 7f57d6d commit d132d74
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/ui/components/atom/text-input/text-input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ export interface TextInputProps extends React.InputHTMLAttributes<HTMLInputEleme
disabled?: boolean;
}

const TextInput = React.forwardRef<HTMLInputElement, TextInputProps>(function TextArea(
const TextInput = React.forwardRef<HTMLTextAreaElement, TextInputProps>(function TextArea(
{ disabled = false, placeholder, onValueChange, value },
ref,
) {
return (
<input
<textarea
ref={ref}
type="text"
rows={2}
className={cn(
`w-full rounded-2xl bg-transparent px-4 py-2 text-base`,
`w-full resize-none rounded-2xl bg-transparent px-4 py-2 text-base`,
`placeholder:text-[#72777A] focus:outline-none`,
`disabled:cursor-wait`,
)}
Expand Down
2 changes: 1 addition & 1 deletion src/ui/components/molecule/chat-section/chat-section.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ const ChatSection: React.FC = () => {
<ChatCard key={index} content={msg.content} role={msg.role} />
))}
{category && <QuestionPresetButtons />}
<div ref={messageEndRef}></div>
<div className="h-6" ref={messageEndRef}></div>
</div>
);
};
Expand Down

0 comments on commit d132d74

Please sign in to comment.