diff options
author | Paul Frazee <pfrazee@gmail.com> | 2022-09-02 11:52:33 -0500 |
---|---|---|
committer | Paul Frazee <pfrazee@gmail.com> | 2022-09-02 11:52:33 -0500 |
commit | 2f0939a1c298a9b7db17005677fc2819b5cb4095 (patch) | |
tree | 6458cba2905a0299bd1c6ba6201e49ed2490d26b /src/view/com/post-thread/PostLikedBy.tsx | |
parent | 6835caa7609259a64ba0aa2c9ddb34b7d5eb7793 (diff) | |
download | voidsky-2f0939a1c298a9b7db17005677fc2819b5cb4095.tar.zst |
Implement consistent Link component
Diffstat (limited to 'src/view/com/post-thread/PostLikedBy.tsx')
-rw-r--r-- | src/view/com/post-thread/PostLikedBy.tsx | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/view/com/post-thread/PostLikedBy.tsx b/src/view/com/post-thread/PostLikedBy.tsx index 77224640c..e928f3591 100644 --- a/src/view/com/post-thread/PostLikedBy.tsx +++ b/src/view/com/post-thread/PostLikedBy.tsx @@ -13,6 +13,7 @@ import { LikedByViewModel, LikedByViewItemModel, } from '../../../state/models/liked-by-view' +import {Link} from '../util/Link' import {useStores} from '../../../state' import {s, colors} from '../../lib/styles' import {AVIS} from '../../lib/assets' @@ -73,12 +74,8 @@ export const PostLikedBy = observer(function PostLikedBy({uri}: {uri: string}) { }) const LikedByItem = ({item}: {item: LikedByViewItemModel}) => { - const store = useStores() - const onPressOuter = () => { - store.nav.navigate(`/profile/${item.name}`) - } return ( - <TouchableOpacity style={styles.outer} onPress={onPressOuter}> + <Link style={styles.outer} href={`/profile/${item.name}`} title={item.name}> <View style={styles.layout}> <View style={styles.layoutAvi}> <Image @@ -91,7 +88,7 @@ const LikedByItem = ({item}: {item: LikedByViewItemModel}) => { <Text style={[s.f14, s.gray5]}>@{item.name}</Text> </View> </View> - </TouchableOpacity> + </Link> ) } |