diff options
Diffstat (limited to 'src/screens/moments/CameraScreen.tsx')
-rw-r--r-- | src/screens/moments/CameraScreen.tsx | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/screens/moments/CameraScreen.tsx b/src/screens/moments/CameraScreen.tsx index 0f2e3b5d..c759e5db 100644 --- a/src/screens/moments/CameraScreen.tsx +++ b/src/screens/moments/CameraScreen.tsx @@ -129,7 +129,6 @@ const CameraScreen: React.FC<CameraScreenProps> = ({route, navigation}) => { onPressOut={async () => { if (await cameraRef.current?.isRecording()) { cameraRef.current?.stopRecording(); - } else { } }} onPress={() => { @@ -155,15 +154,20 @@ const CameraScreen: React.FC<CameraScreenProps> = ({route, navigation}) => { ) : ( <GalleryIcon mostRecentPhotoUri={mostRecentPhoto} - callback={(pic) => { - const filename = pic.filename; + callback={(media) => { + const filename = media.filename; if ( filename && (filename.endsWith('gif') || filename.endsWith('GIF')) ) { - showGIFFailureAlert(() => navigateToCropper(pic.path)); + showGIFFailureAlert(() => navigateToCropper(media.path)); } else { - navigateToCropper(pic.path); + // is this a video? + if (media.duration !== null) { + navigateToCaptionScreen(true, media.path); + } else { + navigateToCropper(media.path); + } } }} /> |