Skip to content

Commit 56008d2

Browse files
authored
Add chevron to the example app and center labels (#3108)
## Description I noticed the button labels were off-center, so I fixed them and added a chevron at the same time as it was looking kind of empty. <img width="546" alt="Screenshot 2024-09-17 at 11 27 33" src="https://github.com/user-attachments/assets/d3b65867-5630-4959-b715-82244f423ba5">
1 parent 6bacf33 commit 56008d2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

example/App.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import {
1414
StackScreenProps,
1515
} from '@react-navigation/stack';
1616
import { NavigationContainer, ParamListBase } from '@react-navigation/native';
17+
import Entypo from '@expo/vector-icons/Entypo';
1718
import {
1819
GestureHandlerRootView,
1920
RectButton,
@@ -323,6 +324,7 @@ function MainScreenItem({ name, onPressItem }: MainScreenItemProps) {
323324
return (
324325
<RectButton style={[styles.button]} onPress={() => onPressItem(name)}>
325326
<Text>{name}</Text>
327+
<Entypo name="chevron-right" size={24} color="#bbb" />
326328
</RectButton>
327329
);
328330
}
@@ -354,7 +356,10 @@ const styles = StyleSheet.create({
354356
flex: 1,
355357
height: 50,
356358
padding: 10,
359+
flexDirection: 'row',
357360
backgroundColor: '#fff',
361+
alignItems: 'center',
362+
justifyContent: 'space-between',
358363
},
359364
buttonContent: {
360365
flex: 1,

0 commit comments

Comments
 (0)