···11+export * from './Autocomplete'
22+export * from './AutocompleteItemEmoji'
33+export * from './AutocompleteItemProfile'
44+export * from './types'
55+export * from './useAutocomplete'
66+export * from './util'
+48
src/components/Autocomplete/types.ts
···11+import {type Sift} from '@bsky.app/sift'
22+import {type Emoji} from '@emoji-mart/data'
33+44+import type * as bsky from '#/types/bsky'
55+66+export type AutocompleteProfile = {
77+ key: string
88+ type: 'profile'
99+ value: string
1010+ profile: bsky.profile.AnyProfileView
1111+}
1212+1313+export type AutocompleteTag = {
1414+ key: string
1515+ type: 'tag'
1616+ value: string
1717+ tag: string
1818+}
1919+2020+export type AutocompleteEmoji = {
2121+ key: string
2222+ type: 'emoji'
2323+ value: string
2424+ emoji: Emoji
2525+}
2626+2727+export type AutocompleteSearch = {
2828+ key: string
2929+ type: 'search'
3030+ value: string
3131+}
3232+3333+export type AutocompleteItem =
3434+ | AutocompleteProfile
3535+ | AutocompleteTag
3636+ | AutocompleteEmoji
3737+ | AutocompleteSearch
3838+3939+export type AutocompleteItemType = AutocompleteItem['type']
4040+4141+export type AutocompleteItemProps = Parameters<
4242+ Parameters<typeof Sift<AutocompleteItem>>[0]['render']
4343+>[0]
4444+4545+export type AutocompleteApi = {
4646+ query: string
4747+ items: AutocompleteItem[]
4848+}
···1313 * returns a ref callback function that can be used to merge multiple refs into a single ref.
1414 */
1515export function mergeRefs<T = any>(
1616- refs: Array<React.MutableRefObject<T> | React.Ref<T>>,
1616+ refs: Array<React.MutableRefObject<T> | React.Ref<T> | undefined>,
1717): React.RefCallback<T> {
1818 return value => {
1919 refs.forEach(ref => {
+5
src/lib/useGetEmojis/getEmojis.ts
···11+import Emojis, {type EmojiMartData} from '@emoji-mart/data'
22+33+export async function getEmojis(): Promise<EmojiMartData> {
44+ return Emojis as EmojiMartData
55+}
+5
src/lib/useGetEmojis/getEmojis.web.ts
···11+import {type EmojiMartData} from '@emoji-mart/data'
22+33+export async function getEmojis(): Promise<EmojiMartData> {
44+ return (await import('@emoji-mart/data')).default as EmojiMartData
55+}