forked from
jollywhoppers.com/witchsky.app
Bluesky app fork with some witchin' additions 馃挮
1import {SiftItem} from '@bsky.app/sift'
2
3import {atoms as a, useTheme} from '#/alf'
4import {Text} from '#/components/Typography'
5import {type AutocompleteItemProps} from './types'
6
7export function AutocompleteItemEmoji({
8 active,
9 props,
10 item,
11}: AutocompleteItemProps) {
12 const t = useTheme()
13
14 if (item.type !== 'emoji') return null
15
16 return (
17 <SiftItem
18 {...props}
19 style={s => [
20 {paddingVertical: 6, paddingHorizontal: 10},
21 a.flex_row,
22 a.align_center,
23 a.gap_sm,
24 active || s.hovered || s.pressed ? [t.atoms.bg_contrast_25] : [],
25 ]}>
26 <Text style={[a.text_xl, a.leading_tight]}>{item.value}</Text>
27 <Text style={[a.text_md, a.leading_tight]}>:{item.emoji.id}:</Text>
28 </SiftItem>
29 )
30}