import { getClassOverride, twMerge } from "../utils"; import { SEARCH_BACKGROUND_ID, SEARCH_INPUT_CONTAINER_ID, SEARCH_INPUT_ID, SEARCH_INPUT_WRAP_ID, } from "../utils/constants"; import { useConfiguration } from "../context/ConfigurationProvider"; import StopIcon from "../icons/StopIcon"; const SearchBar = ({ innerRef, handleSubmit, isStreamActive, stopStream, value, inputClassNames = "", inputWrapClassNames = "", handleChange, }: { innerRef: React.RefObject; isStreamActive: boolean; stopStream?: (_: boolean) => void; value: string; inputClassNames?: string; inputWrapClassNames?: string; handleSubmit: (_e: React.FormEvent) => void; handleChange: (_e: React.ChangeEvent) => void; }) => { const configuration = useConfiguration(); return (
{stopStream && isStreamActive && ( )}
); }; export default SearchBar;