Capgemini / dcx-react-library

React Library UI/UX agnostic
https://main--6069a6f47f4b9f002171f8e1.chromatic.com
MIT License
107 stars 7 forks source link

FormInput: An aria attribute has been given an invalid value #631

Closed Ibabalola closed 2 months ago

Ibabalola commented 2 months ago

Describe the bug Component: FormInput

An invalid aria attribute value was found through running an accessibility test. This instance can be found with a <div> element being provided with a ‘role’ attribute and an ‘error’ value.

Expected behavior Ensure that the appropriate roles are used to allow all information to be adequately conveyed and announced to users of screen reading assistive technologies. The role should not be set to ‘error’. Consider changing these to have a role of ‘alert’ if the intention is to have them announce to screen reader users.

Please conditionally add the element when an error message is to be displayed

Screenshots

Screenshot 2024-04-16 at 11 28 58

Desktop (please complete the following information):

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.

daniele-zurico commented 2 months ago

closed by https://github.com/Capgemini/dcx-react-library/pull/632