diff options
Diffstat (limited to 'src/components/camera/buttons.tsx')
-rw-r--r-- | src/components/camera/buttons.tsx | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/components/camera/buttons.tsx b/src/components/camera/buttons.tsx index 321be958..936a663d 100644 --- a/src/components/camera/buttons.tsx +++ b/src/components/camera/buttons.tsx @@ -25,15 +25,16 @@ export const GalleryIcon: React.FC<GalleryIconProps> = ({ title, mostRecentPhoto, }) => { + const navigation = useNavigation(); return ( <TouchableOpacity - onPress={() => navigateToImagePicker(screenType, title)} + onPress={() => navigateToImagePicker(navigation, screenType, title)} style={styles.saveButton}> <Image source={{uri: mostRecentPhoto}} width={40} height={40} - style={{borderWidth: 2, borderColor: 'white', borderRadius: 5}} + style={styles.galleryIcon} /> <Text style={styles.saveButtonLabel}>Gallery</Text> </TouchableOpacity> @@ -82,14 +83,14 @@ export const FlashButton: React.FC<FlashButtonProps> = ({ height={30} width={20} color={'white'} - style={{zIndex: 999}} + style={styles.flashIcon} /> ) : ( <FlashOffIcon height={30} width={20} color={'white'} - style={{zIndex: 999}} + style={styles.flashIcon} /> )} <Text style={styles.saveButtonLabel}>Flash</Text> @@ -146,4 +147,6 @@ const styles = StyleSheet.create({ alignItems: 'center', borderRadius: 30, }, + galleryIcon: {borderWidth: 2, borderColor: 'white', borderRadius: 5}, + flashIcon: {zIndex: 2}, }); |