0 ? listId : undefined}
+ aria-autocomplete="list"
+ aria-activedescendant={activeChoice?.id}
+ value={text}
+ placeholder={t('search.placeholder')}
+ autoComplete="off"
+ onChange={(e) => {
+ setText(e.target.value)
+ setOpen(true)
+ setActive(-1)
+ }}
+ onFocus={() => setOpen(true)}
+ onKeyDown={onKeyDown}
+ className="h-11 px-4"
+ />
+ {visible && enabled && (
+
+ {failed ? (
+
+ all.forEach((query) => query.refetch())} />
+
+ ) : pending ? (
+
+ {t('search.searching')}
+
+ ) : nothing ? (
+
{t('search.nothingFound', { q })}
+ ) : (
+
+ {shown.map((g) => (
+
+
+ {g.label}
+
+ {g.choices.map((c) => (
+
setActive(everyChoice.indexOf(c))} />
+ ))}
+
+ ))}
+
+ setActive(everyChoice.length - 1)}
+ />
+
+
+ )}
+