Skip to content

Commit d05beb0

Browse files
committed
Make checkboxes and check box consistent
1 parent f6ba49b commit d05beb0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/posts/finishing-touches-for-forms.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ We can use the [GOV.UK Components](https://govuk-components.netlify.app/) [title
9090
9191
## Making sure error links to checkboxes and radios work
9292
93-
The form builder comes with two ways to build lists of check boxes and radio buttons.
93+
The form builder comes with two ways to build lists of checkboxes and radio buttons.
9494
9595
The simplest is to use `#govuk_collection_check_boxes` and `#govuk_collection_radio_buttons`, which mimic the behaviour of [their Rails counterparts](https://edgeapi.rubyonrails.org/classes/ActionView/Helpers/FormBuilder.html#method-i-collection_checkboxes).
9696
@@ -121,7 +121,7 @@ f.govuk_radio_buttons_fieldset(:close_ticket)) do
121121
end
122122
```
123123
124-
This would make it impossible for the error summary to accurately link to the first check box or radio button without repeating the logic --- an approach that's going to lead to bugs when it's updated in one place but not the other.
124+
This would make it impossible for the error summary to accurately link to the first checkbox or radio button without repeating the logic --- an approach that's going to lead to bugs when it's updated in one place but not the other.
125125
126126
Instead, we have to help the error summary by 'marking' the field we want the error summary to link to with `link_errors: true`. This overrides the ID generation so the link in the error summary will match it.
127127

0 commit comments

Comments
 (0)