0.10.7 • Published 1 year ago

@govuk-react-bjss-pttg/error-summary v0.10.7

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

ErrorSummary

Import

  import ErrorSummary from '@govuk-react-bjss-pttg/error-summary';

Use this component at the top of a page to summarise any errors a user has made.

Properties

PropRequiredDefaultTypeDescription
descriptionundefinedstringOptional description of the errors
errors[]{ targetName?: string; text?: string; }[]Array of errors with text and target element name to scroll into view when clicked
headingThere is a problemstringHeading text
onHandleErrorClickundefined(targetName: string) => voidonClick function to scroll the target element into view