-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Provide accessible error messages for AT users #959
Labels
Comments
3 tasks
7 tasks
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please leave a comment if this is still an issue for you. Thank you. |
This is important, we should do this |
heath-freenome
added a commit
to heath-freenome/react-jsonschema-form
that referenced
this issue
Jan 15, 2023
Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Updated the `CHANGELOG.md` accordingly
heath-freenome
added a commit
to heath-freenome/react-jsonschema-form
that referenced
this issue
Jan 15, 2023
Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly
heath-freenome
added a commit
to heath-freenome/react-jsonschema-form
that referenced
this issue
Jan 15, 2023
Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly
8 tasks
heath-freenome
added a commit
to heath-freenome/react-jsonschema-form
that referenced
this issue
Jan 15, 2023
Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly
heath-freenome
added a commit
to heath-freenome/react-jsonschema-form
that referenced
this issue
Jan 15, 2023
Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly
heath-freenome
added a commit
to heath-freenome/react-jsonschema-form
that referenced
this issue
Jan 16, 2023
Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly
heath-freenome
added a commit
that referenced
this issue
Jan 16, 2023
…ts (#3380) * fix: reimplement 2386 to add aria-describedby elements onto all inputs Fixes #959 by reimplementing #2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly * - Fix test snapshot * - Responded to reviewer feedback by adding and using `optionId()` and `examplesId()` - Added an optional flag to `ariaDescribedByIds()` that, if true, appends the examples id onto the string * - Minor tweak to the `5.x migration guide`
shijistar
pushed a commit
to shijistar/react-jsonschema-form
that referenced
this issue
Jun 8, 2023
… all inputs (rjsf-team#3380) * fix: reimplement 2386 to add aria-describedby elements onto all inputs Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly * - Fix test snapshot * - Responded to reviewer feedback by adding and using `optionId()` and `examplesId()` - Added an optional flag to `ariaDescribedByIds()` that, if true, appends the examples id onto the string * - Minor tweak to the `5.x migration guide`
shijistar
pushed a commit
to shijistar/react-jsonschema-form
that referenced
this issue
Jun 8, 2023
… all inputs (rjsf-team#3380) * fix: reimplement 2386 to add aria-describedby elements onto all inputs Fixes rjsf-team#959 by reimplementing rjsf-team#2386 making it consistent across all themes - In `@rjsf/utils`, added new `descriptionId()`, `errorId()`, `helpId()`, `titleId()` and `ariaDescribedByIds()` functions with unit tests - In all themes: - Updated the `FieldErrorTemplate` to use the `errorId()` function to generate its id - Updated the `FieldHelpTemplate` to use the `helpId()` function to generate its id - Updated the `ObjectFieldTemplate` to use the `titleId()` and `descriptionId()` functions to generate the ids for the `TitleFieldTemplate` and `DescriptionFieldTemplate` respectively - Updated the `BaseInputTemplate` to pass the `ariaDescribedByIds()` value to `aria-describedby` on the "input" component - For all the widgets that generated a user-accessible "input", passed in the `ariaDescribedByIds()` call into the `aria-describedby` on the "input" component - Updated all the test snapshots to update the `title` and `description` ids to the new values and to add the new `aria-describeby` properties - Updated the documentation to indicate the existance of these new functions - Updated the `5.x migration guide` to document the potential change of ids for Title, Description and `RadioWidget` and `CheckboxWidget` - Also fixed the incorrectly named `__error` to be `__errors` in the `ErrorSchema` examples - Updated the `CHANGELOG.md` accordingly * - Fix test snapshot * - Responded to reviewer feedback by adding and using `optionId()` and `examplesId()` - Added an optional flag to `ariaDescribedByIds()` that, if true, appends the examples id onto the string * - Minor tweak to the `5.x migration guide`
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Prerequisites
Description
In order to providy more accessibility to our screen reaser users, we would like to add an
aria-describedby
-attribute to input fields that reference the inline error message (e.g. "is a required property") with an id of this error meesage when validating the form. This would cause the AT to read out the error message under the input field when the user tabs through the form elements.Is there a way to configure
aria-describedby
-attributes and to enable ids to error messages?Any other ideas to solve this problem are appreciated. :)
For example, instead of this markup from the live playground
it should look like this:
Steps to Reproduce
Expected behavior
The screen reader should read out also the message that is configured here ("is a required property").
Actual behavior
The screen reader tells you that this field is required and should be filled, since it recognizes the HTML5 validation functionality of the browser. But the message is not being read out.
The text was updated successfully, but these errors were encountered: