diff --git a/native/media/camera-modal.react.js b/native/media/camera-modal.react.js --- a/native/media/camera-modal.react.js +++ b/native/media/camera-modal.react.js @@ -25,6 +25,7 @@ import Reanimated, { EasingNode as ReanimatedEasing, } from 'react-native-reanimated'; +import { SafeAreaView } from 'react-native-safe-area-context'; import { useDispatch } from 'react-redux'; import { pathFromURI, filenameFromPathOrURI } from 'lib/media/file-utils.js'; @@ -612,21 +613,21 @@ if (this.state.stagingMode) { return this.renderStagingView(); } - const topButtonStyle = { - top: Math.max(this.props.dimensions.topInset, 6), - }; + return ( - <> - {this.renderCameraContent(status)} - - × - - + + + {this.renderCameraContent(status)} + + × + + + ); }; @@ -640,30 +641,25 @@ image = ; } - const topButtonStyle = { - top: Math.max(this.props.dimensions.topInset - 3, 3), - }; - const sendButtonContainerStyle = { - bottom: this.props.dimensions.bottomInset + 22, - }; return ( <> {image} - - - - + + + + + + + + ); } @@ -709,12 +705,6 @@ ); } - const topButtonStyle = { - top: Math.max(this.props.dimensions.topInset - 3, 3), - }; - const bottomButtonsContainerStyle = { - bottom: this.props.dimensions.bottomInset + 20, - }; return ( {flashIcon} - + - - - × - - - - - + + - - Save - - {copyButton} + + × + + + + + + + Save + + {copyButton} + + - + ); return ( @@ -1211,6 +1216,13 @@ right: 0, top: 0, }, + buttonsOverlay: { + bottom: 0, + left: 0, + position: 'absolute', + right: 0, + top: 0, + }, closeButton: { color: 'white', fontSize: 36, @@ -1223,6 +1235,7 @@ closeButtonContainer: { position: 'absolute', right: 4, + top: 4, }, container: { flex: 1, @@ -1231,6 +1244,9 @@ flex: 1, overflow: 'hidden', }, + fill: { + flex: 1, + }, mediaIcon: { color: '#D7D7DC', fontSize: 36, @@ -1253,6 +1269,7 @@ textShadowRadius: 1, }, mediaIconsContainer: { + bottom: 8, left: 16, position: 'absolute', }, diff --git a/native/media/video-playback-modal.react.js b/native/media/video-playback-modal.react.js --- a/native/media/video-playback-modal.react.js +++ b/native/media/video-playback-modal.react.js @@ -8,6 +8,7 @@ import { TapGestureHandler } from 'react-native-gesture-handler'; import * as Progress from 'react-native-progress'; import Animated from 'react-native-reanimated'; +import { SafeAreaView } from 'react-native-safe-area-context'; import Video from 'react-native-video'; import { useIsAppBackgroundedOrInactive } from 'lib/shared/lifecycle-utils.js'; @@ -574,41 +575,45 @@ style={[styles.controls, { opacity: controlsOpacity }]} pointerEvents={controlsEnabled ? 'box-none' : 'none'} > - - - - - + + + + + + + + + + + + + + + + + + {timeElapsed} / {totalDuration} + + - - - - - - - - - - {timeElapsed} / {totalDuration} - - + ); @@ -739,6 +744,9 @@ flex: 1, overflow: 'hidden', }, + fill: { + flex: 1, + }, }; export default VideoPlaybackModal;