Autocomplete updates (react-query refactor) (#1911)
* Unify the autocomplete code; drop fuse * Persist autocomplete results while they're in progress * Commit lockfile * Use ReturnType helper --------- Co-authored-by: Eric Bailey <git@esb.lol>
This commit is contained in:
parent
839e8e8d0a
commit
d5ea31920c
7 changed files with 73 additions and 152 deletions
|
@ -26,7 +26,7 @@ import {MagnifyingGlassIcon2} from 'lib/icons'
|
|||
import {NavigationProp} from 'lib/routes/types'
|
||||
import {Text} from 'view/com/util/text/Text'
|
||||
import {UserAvatar} from '#/view/com/util/UserAvatar'
|
||||
import {useActorSearch} from '#/state/queries/actor-autocomplete'
|
||||
import {useActorAutocompleteFn} from '#/state/queries/actor-autocomplete'
|
||||
import {useModerationOpts} from '#/state/queries/preferences'
|
||||
|
||||
export function SearchResultCard({
|
||||
|
@ -98,7 +98,7 @@ export const DesktopSearch = observer(function DesktopSearch() {
|
|||
>([])
|
||||
|
||||
const moderationOpts = useModerationOpts()
|
||||
const search = useActorSearch()
|
||||
const search = useActorAutocompleteFn()
|
||||
|
||||
const onChangeText = React.useCallback(
|
||||
async (text: string) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue