Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Radio button background not grey on de-select #155

Closed
robmckinnon opened this issue Jan 23, 2015 · 1 comment
Closed

Radio button background not grey on de-select #155

robmckinnon opened this issue Jan 23, 2015 · 1 comment

Comments

@robmckinnon
Copy link

Radio button backgrounds are no longer being re-greyed on de-select in the radio button section of the GOV.UK elements guide:
screen shot 2015-01-23 at 11 58 23
screen shot 2015-01-23 at 11 58 35
screen shot 2015-01-23 at 11 58 43

Checkboxes are not effected by this issue. They are still being re-greyed on de-select.

The changes to selection-buttons.js in this govuk_elements commit may have introduced the radio button issue. This issue has also been reported at the govuk_elements repo here: alphagov/govuk_elements#54

@tombye
Copy link
Contributor

tombye commented Jan 23, 2015

From a quick debug, looks like this is because they're not wrapped in a form.

When the selection in a radio group shifts from one to the other in the group, the JS in selection-buttons.js searches for the group within the parent form. If there is no parent form, it won't be able to find the group.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants