Use Pressable for most links/embeds (#1181)

* delay press on all links

* use Pressable for all accessible links
This commit is contained in:
Eric Bailey 2023-08-24 18:28:26 -05:00 committed by GitHub
parent 4654a9a45e
commit 462022741d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 15 additions and 33 deletions

View file

@ -1,12 +1,5 @@
import React from 'react'
import {
Pressable,
StyleProp,
StyleSheet,
View,
ViewStyle,
TouchableOpacity,
} from 'react-native'
import {Pressable, StyleProp, StyleSheet, View, ViewStyle} from 'react-native'
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
import {Text} from '../util/text/Text'
import {usePalette} from 'lib/hooks/usePalette'
@ -68,7 +61,7 @@ export const CustomFeed = observer(
}, [store, item])
return (
<TouchableOpacity
<Pressable
testID={`feed-${item.displayName}`}
accessibilityRole="button"
style={[styles.container, pal.border, style]}
@ -132,7 +125,7 @@ export const CustomFeed = observer(
{pluralize(item.data.likeCount || 0, 'user')}
</Text>
) : null}
</TouchableOpacity>
</Pressable>
)
},
)