Skip to content
Snippets Groups Projects
Verified Commit 65a0b72c authored by Sivert Kronen Hatteberg's avatar Sivert Kronen Hatteberg
Browse files

Move the error box to the top of the form

parent 7268f58a
No related branches found
No related tags found
1 merge request!339Fix problems with submit button not being disabled and some UX improvements
Pipeline #145038 passed
...@@ -237,6 +237,16 @@ export default function GuestInfo({ ...@@ -237,6 +237,16 @@ export default function GuestInfo({
<Typography sx={{ marginBottom: '1rem' }} variant="body1"> <Typography sx={{ marginBottom: '1rem' }} variant="body1">
{t('guestInfo.contactInfoBody')} {t('guestInfo.contactInfoBody')}
</Typography> </Typography>
{emailUpdateError !== undefined && (
<Box sx={{ marginTop: '1rem', marginBottom: '1rem' }}>
<ServerErrorReport
errorHeading={emailUpdateError?.errorHeading}
statusCode={emailUpdateError?.statusCode}
statusText={emailUpdateError?.statusText}
errorBodyText={emailUpdateError?.errorBodyText}
/>
</Box>
)}
{updateOKMsg !== '' && ( {updateOKMsg !== '' && (
<Alert <Alert
severity="success" severity="success"
...@@ -347,16 +357,6 @@ export default function GuestInfo({ ...@@ -347,16 +357,6 @@ export default function GuestInfo({
> >
{t('button.save')} {t('button.save')}
</Button> </Button>
{emailUpdateError !== undefined && (
<Box sx={{ marginTop: '1rem' }}>
<ServerErrorReport
errorHeading={emailUpdateError?.errorHeading}
statusCode={emailUpdateError?.statusCode}
statusText={emailUpdateError?.statusText}
errorBodyText={emailUpdateError?.errorBodyText}
/>
</Box>
)}
</Box> </Box>
</form> </form>
<Typography sx={{ marginBottom: '1rem' }} variant="h2"> <Typography sx={{ marginBottom: '1rem' }} variant="h2">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment