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

Accessibility Issue in Nested Forms: Duplicate id Attributes Causing Validation Errors #6016

Open
sabato-galasso opened this issue Feb 17, 2025 · 1 comment
Assignees

Comments

@sabato-galasso
Copy link

Describe the bug
When using a nested form in Formio.js, two div elements with the same id are generated. This causes accessibility verification issues, as duplicate id values do not comply with WCAG standards and can interfere with screen readers and validation tools.

Version/Branch
Formio.js version:
"@formio/js": "^5.0.1"

To Reproduce

  1. Create a form containing a nested form.
  2. Add components inside the nested form.
  3. Inspect the generated HTML code.
  4. Notice that two div elements have the same id.

Expected behavior
The form should generate a single container with a unique id, avoiding duplication to ensure accessibility compliance.

Screenshots

Image

Additional context
This issue can cause errors in automated accessibility tests and impact the usability of the form for assistive technology users. A possible solution is to remove the duplicate id or ensure unique identifiers for each div.

@olgabann
Copy link

@sabato-galasso Thank you for reporting this issue. I can reproduce it and have logged a ticket for the backlog. We are always willing to review any contributions from the open-source community to resolve this issue.

For internal reference: FIO-9785

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

2 participants