Capgemini / dcx-react-library

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

FormCheckbox Component does not offer a capability to not add an aria-label #650

Open aismaelcap opened 1 month ago

aismaelcap commented 1 month ago

Describe the bug Form Checkbox takes name as an aria-label when one is not provided however I need the aria-label attribute to be deleted as it overrides the visible label and the already existing programmatic association between the and the negates the need for an aria-label.

Expected behavior When the aria-label property is not provided do not add it to the radio

Line 52 in the src/formCheckbox/FormCheckbox.tsx file ariaLabel={ariaLabel || name}

Please follow these steps to create your branch:

git checkout release/1.1.0
git pull
git checkout -b 'feature/checkbox-aria-label'