You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you use the Add another component to add an additional item, the legend on the form is identical to the original one: in the MOJDS docs example there would be two or more legends called "Person".
This makes it hard for users with screen readers to navigate the form, because the screen reader cannot distinguish between each fieldset.
To make this clearer, we should automatically enumerate the legends by appending an index number with JavaScript. i.e. when you "add another", the original legend will become "Person 1" and the new one will be "Person 2".
In order to support services which don't want this distinction, if the form has the attribute data-moj-add-another-enumerate="false" then the auto-enumeration should not occur. This opt-out mechanism will need to be documented.
The text was updated successfully, but these errors were encountered:
NB: This is a breaking change
When you use the Add another component to add an additional item, the legend on the form is identical to the original one: in the MOJDS docs example there would be two or more legends called "Person".
This makes it hard for users with screen readers to navigate the form, because the screen reader cannot distinguish between each fieldset.
To make this clearer, we should automatically enumerate the legends by appending an index number with JavaScript. i.e. when you "add another", the original legend will become "Person 1" and the new one will be "Person 2".
In order to support services which don't want this distinction, if the form has the attribute
data-moj-add-another-enumerate="false"
then the auto-enumeration should not occur. This opt-out mechanism will need to be documented.The text was updated successfully, but these errors were encountered: