import type { FormEvent } from "react"; import { Search, X } from "lucide-react"; import { Button } from "@/components/ui/button"; import { Input } from "@/components/ui/input"; interface StockSearchFormProps { keyword: string; onKeywordChange: (value: string) => void; onSubmit: (event: FormEvent) => void; onInputFocus?: () => void; disabled?: boolean; isLoading?: boolean; } /** * @description 종목 검색 입력/제출 폼을 렌더링합니다. * @see features/trade/components/TradeContainer.tsx 검색 패널에서 키워드 입력 이벤트를 전달합니다. */ export function StockSearchForm({ keyword, onKeywordChange, onSubmit, onInputFocus, disabled, isLoading, }: StockSearchFormProps) { const handleClear = () => { onKeywordChange(""); // 포커스 로직이 필요하다면 상위에서 ref를 전달받거나 여기서 ref를 사용해야 함. // 현재는 단순 값 초기화만 수행. }; return (
); }