import React from 'react'; import {Image, Text, TouchableOpacity, View} from 'react-native'; import {navigateToMediaPicker} from '../../utils/camera'; import {ImageOrVideo} from 'react-native-image-crop-picker'; import {styles} from './styles'; interface GalleryIconProps { mostRecentPhotoUri: string; callback: (media: ImageOrVideo) => void; } /* * Displays the most recent photo in the user's gallery * On click, navigates to the image picker */ export const GalleryIcon: React.FC = ({ mostRecentPhotoUri, callback, }) => { return ( navigateToMediaPicker(callback)} style={styles.saveButton}> {mostRecentPhotoUri !== '' ? ( ) : ( )} Gallery ); }; export default GalleryIcon;