adevinta / spark

โœจ Simple, Modular & Accessible UI Components for your React Applications
https://sparkui.vercel.app
MIT License
70 stars 20 forks source link

fix(checkbox): remove the required attribute from individual checkboxes as soon as 1 checkbox is checked #2206

Closed acd02 closed 3 months ago

acd02 commented 3 months ago

TASK:#2205

Description, Motivation and Context

When a CheckboxGroup is marked as required, we should remove the required attribute from individual checkboxes as soon as one checkbox is checked.

Types of changes

codecov[bot] commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 97.63%. Comparing base (cef5c53) to head (bea7ccf). Report is 10 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #2206 +/- ## ======================================= Coverage 97.63% 97.63% ======================================= Files 749 749 Lines 5885 5888 +3 Branches 2107 2078 -29 ======================================= + Hits 5746 5749 +3 Misses 137 137 Partials 2 2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

Powerplex commented 3 months ago

Thanks. I checked and HTML required attribute is not supported. Instead everywhere it is suggested to use JS to manage it, so the fix is aligned with that.