feat(prejoin/native): ui updates (#12368)

* feat(prejoin/native): ui updates
This commit is contained in:
Calinteodor 2022-10-12 15:43:11 +03:00 committed by GitHub
parent 53e4f584f9
commit 935f95a3d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 38 additions and 38 deletions

View File

@ -199,7 +199,9 @@ export const preJoinScreenOptions = {
headerStyle: { headerStyle: {
backgroundColor: BaseTheme.palette.screen02Header backgroundColor: BaseTheme.palette.screen02Header
}, },
headerTitle: '' headerTitleStyle: {
color: BaseTheme.palette.text01
}
}; };
/** /**

View File

@ -121,7 +121,8 @@ const Prejoin: React.FC<PrejoinProps> = ({ navigation }: PrejoinProps) => {
useLayoutEffect(() => { useLayoutEffect(() => {
navigation.setOptions({ navigation.setOptions({
headerLeft headerLeft,
headerTitle: t('prejoin.joinMeeting')
}); });
}, [ navigation ]); }, [ navigation ]);
@ -152,18 +153,17 @@ const Prejoin: React.FC<PrejoinProps> = ({ navigation }: PrejoinProps) => {
isFocused isFocused
&& <View style = { largeVideoContainerStyles }> && <View style = { largeVideoContainerStyles }>
<LargeVideo /> <LargeVideo />
<View style = { styles.displayRoomNameBackdrop }>
<Text
numberOfLines = { 1 }
style = { styles.preJoinRoomName as StyleProp<TextStyle> }>
{ roomName }
</Text>
</View>
</View> </View>
} }
<View style = { contentContainerStyles }> <View style = { contentContainerStyles }>
<View style = { styles.formWrapper as StyleProp<ViewStyle> }> <View style = { styles.formWrapper as StyleProp<ViewStyle> }>
<Text style = { styles.preJoinTitle as StyleProp<TextStyle> }>
{ t('prejoin.joinMeeting') }
</Text>
<Text
numberOfLines = { 1 }
style = { styles.preJoinRoomName as StyleProp<TextStyle> }>
{ roomName }
</Text>
<TextInput <TextInput
onChangeText = { onChangeDisplayName } onChangeText = { onChangeDisplayName }
placeholder = { t('dialog.enterDisplayName') } placeholder = { t('dialog.enterDisplayName') }
@ -175,14 +175,13 @@ const Prejoin: React.FC<PrejoinProps> = ({ navigation }: PrejoinProps) => {
disabled = { joinButtonDisabled } disabled = { joinButtonDisabled }
labelKey = 'prejoin.joinMeeting' labelKey = 'prejoin.joinMeeting'
onClick = { onJoin } onClick = { onJoin }
style = { styles.prejoinButton } style = { styles.joinButton }
type = { PRIMARY } /> type = { PRIMARY } />
<Button <Button
accessibilityLabel = 'prejoin.joinMeetingInLowBandwidthMode' accessibilityLabel = 'prejoin.joinMeetingInLowBandwidthMode'
disabled = { joinButtonDisabled } disabled = { joinButtonDisabled }
labelKey = 'prejoin.joinMeetingInLowBandwidthMode' labelKey = 'prejoin.joinMeetingInLowBandwidthMode'
onClick = { onJoinLowBandwidth } onClick = { onJoinLowBandwidth }
style = { styles.prejoinButton }
type = { SECONDARY } /> type = { SECONDARY } />
</View> </View>
<View style = { toolboxContainerStyles }> <View style = { toolboxContainerStyles }>

View File

@ -2,15 +2,9 @@ import BaseTheme from '../../base/ui/components/BaseTheme.native';
const SECONDARY_COLOR = BaseTheme.palette.border04; const SECONDARY_COLOR = BaseTheme.palette.border04;
const preJoinText = {
...BaseTheme.typography.heading5,
color: BaseTheme.palette.text01,
textAlign: 'center'
};
export default { export default {
prejoinButton: { joinButton: {
marginTop: BaseTheme.spacing[3] marginVertical: BaseTheme.spacing[3]
}, },
buttonStylesBorderless: { buttonStylesBorderless: {
@ -21,7 +15,7 @@ export default {
style: { style: {
flexDirection: 'row', flexDirection: 'row',
justifyContent: 'center', justifyContent: 'center',
marginHorizontal: BaseTheme.spacing[3], margin: BaseTheme.spacing[3],
height: 24, height: 24,
width: 24 width: 24
}, },
@ -38,47 +32,45 @@ export default {
}, },
largeVideoContainer: { largeVideoContainer: {
minHeight: '50%' minHeight: '60%'
}, },
largeVideoContainerWide: { largeVideoContainerWide: {
height: '100%', height: '100%',
marginRight: 'auto', marginRight: 'auto',
position: 'absolute', position: 'absolute',
width: '50%' width: '60%'
}, },
contentContainer: { contentContainer: {
alignSelf: 'center', alignSelf: 'center',
display: 'flex', display: 'flex',
justifyContent: 'center', justifyContent: 'center',
minHeight: '50%', minHeight: '40%',
paddingHorizontal: BaseTheme.spacing[3], padding: BaseTheme.spacing[3],
width: 400 width: 400
}, },
contentContainerWide: { contentContainerWide: {
alignItems: 'center', alignSelf: 'center',
height: '100%', height: '100%',
justifyContent: 'center', justifyContent: 'center',
left: '50%', left: '60%',
paddingHorizontal: BaseTheme.spacing[3], padding: BaseTheme.spacing[3],
position: 'absolute', position: 'absolute',
width: '50%' width: '40%'
}, },
toolboxContainer: { toolboxContainer: {
alignSelf: 'center', alignSelf: 'center',
display: 'flex', display: 'flex',
flexDirection: 'row', flexDirection: 'row',
justifyContent: 'center', justifyContent: 'center'
marginTop: BaseTheme.spacing[3]
}, },
toolboxContainerWide: { toolboxContainerWide: {
flexDirection: 'row', flexDirection: 'row',
justifyContent: 'center', justifyContent: 'center'
marginTop: BaseTheme.spacing[3]
}, },
formWrapper: { formWrapper: {
@ -94,15 +86,22 @@ export default {
borderWidth: 2, borderWidth: 2,
color: BaseTheme.palette.text06, color: BaseTheme.palette.text06,
height: BaseTheme.spacing[7], height: BaseTheme.spacing[7],
marginTop: BaseTheme.spacing[3],
textAlign: 'center' textAlign: 'center'
}, },
preJoinTitle: { preJoinRoomName: {
...preJoinText ...BaseTheme.typography.heading5,
color: BaseTheme.palette.text01,
textAlign: 'center'
}, },
preJoinRoomName: { displayRoomNameBackdrop: {
...preJoinText alignSelf: 'center',
backgroundColor: BaseTheme.palette.ui16,
bottom: BaseTheme.spacing[3],
borderRadius: 4,
paddingHorizontal: BaseTheme.spacing[3],
paddingVertical: BaseTheme.spacing[1],
position: 'absolute'
} }
}; };