import { useCallback, useState } from "react"; import { useTranslation } from "react-i18next"; import Sticky from "react-stickynode"; import { ThinContainer } from "@/components/layout/ThinContainer"; import { SearchBarInput } from "@/components/SearchBar"; import { Title } from "@/components/text/Title"; import { useSearchQuery } from "@/hooks/useSearchQuery"; import { useBannerSize } from "@/stores/banner"; export interface HeroPartProps { setIsSticky: (val: boolean) => void; searchParams: ReturnType; } export function HeroPart({ setIsSticky, searchParams }: HeroPartProps) { const { t } = useTranslation(); const [search, setSearch, setSearchUnFocus] = searchParams; const [, setShowBg] = useState(false); const bannerSize = useBannerSize(); const stickStateChanged = useCallback( ({ status }: Sticky.Status) => { const val = status === Sticky.STATUS_FIXED; setShowBg(val); setIsSticky(val); }, [setShowBg, setIsSticky] ); return (
{t("search.title")}
); }