import { Send } from 'lucide-react'; /** * Chat Input component with send button * * @param {string} value - Input value * @param {function} onChange - Change handler for input * @param {function} onSubmit - Submit handler for form * @param {boolean} disabled - Whether input is disabled (e.g., when not connected) * @param {string} placeholder - Placeholder text (default: "Write a message...") * @param {string} className - Additional classes for the form * @param {boolean} autoFocus - Whether to autofocus the input */ const ChatInput = ({ value, onChange, onSubmit, disabled = false, placeholder = 'Write a message...', className = '', autoFocus = false }) => { const handleSubmit = (e) => { e.preventDefault(); if (!value.trim() || disabled) return; onSubmit(e); }; return (
); }; export default ChatInput;