Error summary
The error summary appears at the top of a page to summarise any errors a user has made. It lists all the error messages on the page and offers a link to each error.
Example
How to use the error summary
The error summary should be used on any page that contains a form.
Show an error summary when there is a validation error, even if there's only one. This allows users to recover from the error quickly.
The error messages in the summary should match the ones on the form fields. Don’t use different text in each place, as this could be confusing for the user.
Adding an error summary in the CMS
An error summary can’t be added directly via the CMS to any page. It will automatically appear on any page that features a form. You can update the text that introduces the error summary – for example, ‘There was a problem submitting your enquiry. Please review the following errors:’.
If you need to update the error messages associated with any of the fields in the form, speak to Louise Spence.
Accessibility
Users can easily navigate through the links in the error summary using the keyboard. Once the user decides which error they want to fix, they can click on it, and the focus will be set on the specific form component allowing them recovering from an error.
Clearly written error messages will help the user easily correct their mistake.
We use an aria label to help screen readers understand what this section is for.