Skip to content

Commit

Permalink
Fix/button in scroll view (#202)
Browse files Browse the repository at this point in the history
* Ajout des boutton dans le scrollView DefaultNotification

Signed-off-by: ClaudeArs <claudears2474@gmail.com>
---------

Signed-off-by: ClaudeArs <claudears2474@gmail.com>
  • Loading branch information
ClaudeArs authored Jan 14, 2025
1 parent d059fa6 commit 098ccb6
Showing 1 changed file with 28 additions and 22 deletions.
50 changes: 28 additions & 22 deletions app/src/screens/DefaultNotification.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@ const DefaultNotification: React.FC<DefaultProps> = ({ navigation }: DefaultProp
const { t } = useTranslation()

const styles = StyleSheet.create({
safeArea: {
flex: 1,
},
container: {
height: '77%',
padding: 20,
marginBottom: 20,
padding: 16,
backgroundColor: ColorPallet.brand.primaryBackground,
},
textHeaderTitle: {
Expand All @@ -37,6 +38,9 @@ const DefaultNotification: React.FC<DefaultProps> = ({ navigation }: DefaultProp
flexShrink: 1,
color: TextTheme.bold.color,
},
buttonContainer: {
marginBottom: 30,
},
button: {
margin: 20,
marginTop: 10,
Expand Down Expand Up @@ -65,7 +69,7 @@ const DefaultNotification: React.FC<DefaultProps> = ({ navigation }: DefaultProp
})

return (
<SafeAreaView edges={['left', 'right', 'bottom']}>
<SafeAreaView style={styles.safeArea} edges={['left', 'right', 'bottom']}>
<ScrollView style={styles.container}>
<View style={styles.section}>
<HeaderText title={t('DefaultNotificationPage.Title')} />
Expand All @@ -79,25 +83,27 @@ const DefaultNotification: React.FC<DefaultProps> = ({ navigation }: DefaultProp
<Text style={styles.textSectionTitle}>{t('DefaultNotificationPage.ANIGRequest')}</Text>
<Text style={styles.sectionDescription}> {t('DefaultNotificationPage.ANIGAcceptDescription')}</Text>
</View>
<View style={styles.buttonContainer}>
<View style={styles.button}>
<Button
buttonType={ButtonType.Primary}
testID={testIdWithKey('StartProcess')}
accessibilityLabel={t('DefaultNotificationPage.ButtonTitle')}
title={t('DefaultNotificationPage.ButtonTitle')}
onPress={async () => await Linking.openURL(urlGestionDeCompteSag)}
></Button>
</View>
<View style={styles.button}>
<Button
buttonType={ButtonType.Secondary}
testID={testIdWithKey('StartProcess')}
accessibilityLabel={t('Global.GoBack')}
title={t('Global.GoBack')}
onPress={() => navigation.goBack()}
></Button>
</View>
</View>
</ScrollView>
<View style={styles.button}>
<Button
buttonType={ButtonType.Primary}
testID={testIdWithKey('StartProcess')}
accessibilityLabel={t('DefaultNotificationPage.ButtonTitle')}
title={t('DefaultNotificationPage.ButtonTitle')}
onPress={async () => await Linking.openURL(urlGestionDeCompteSag)}
></Button>
</View>
<View style={styles.button}>
<Button
buttonType={ButtonType.Secondary}
testID={testIdWithKey('StartProcess')}
accessibilityLabel={t('Global.GoBack')}
title={t('Global.GoBack')}
onPress={() => navigation.goBack()}
></Button>
</View>
</SafeAreaView>
)
}
Expand Down

0 comments on commit 098ccb6

Please sign in to comment.