{
setIsFocused(false);
}}
onChange={(e) => setSearchValue(e.target.value)}
onFocus={() => {
setOpen(true);
setIsFocused(true);
}}
onKeyDown={async (e) => {
if (e.key === "Enter" && results[0] && results.length > 0) {
setNavigationEnter(true);
await router.push(`/annuncio/${results[0].trim()}`);
}
}}
type="search"
value={searchValue}
/>
{open && (
li:first-child>a]:underline [&>li:first-child>a]:underline-offset-2",
"scrollbar-default",
)}
// biome-ignore lint/a11y/noNoninteractiveElementToInteractiveRole:
role="listbox"
>
{loading ? (
-
Caricamento...
) : (
<>
{results.length === 0 && (
-
)}
{results.map((item) => (
-
{item}
))}
>
)}
)}
);
};
const backupFrase = "Inserisci il codice 👈";
const MovingText = ({ hidden }: { hidden: boolean }) => {
const { t } = useTranslation();
const [randomFrase, setRandomFrase] = useState