feat: FieldInput ARIA#9744
Merged
mikeharv merged 5 commits intoRaspberryPiFoundation:v13from Apr 21, 2026
Merged
Conversation
gonfunko
approved these changes
Apr 21, 2026
Comment on lines
+471
to
+472
| "FIELD_LABEL_EMPTY": "empty", | ||
| "FIELD_LABEL_EMPTY_INPUT": "empty", |
Contributor
There was a problem hiding this comment.
What's the difference between these two?
Contributor
Author
There was a problem hiding this comment.
There isn't a difference, except that one is for the base field class. I wasn't sure if we should keep them distinct in case they diverge, for example if the new one changes to something like "empty input".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The basics
The details
Resolves
Fixes #9656
Proposed Changes
Implements foundational ARIA support for input fields, including text input and number fields.
Key changes:
FieldInput:"input field") if none is specified with the block definitionrecomputeAriaContext()helper to:role="button"aria-labelusingcomputeAriaLabelaria-hiddeninitViewdoValueUpdate_doValueInvalid_aria-hiddensince they are represented via ARIA labelsFIELD_LABEL_EMPTYFIELD_LABEL_EMPTY_INPUTARIA_TYPE_FIELD_INPUTFIELD_LABEL_EDIT_PREFIXReason for Changes
This change establishes a baseline pattern in
FieldInputso that fields have meaningful default accessibility behavior without requiring every implementation to solve the same problems independently. It ensures that ARIA labeling stays in sync with field state and that fields communicate their interactivity in a predictable way.At the same time, this approach intentionally leaves room for customization, allowing specific field types to provide more tailored or context-aware accessibility behavior where needed.
Test Coverage
Added unit tests for ARIA behavior on:
FieldTextInputFieldNumberTests cover:
button)aria-hiddenin flyouts)Manual testing was also performed in a rendered workspace to verify:
Documentation
New methods include TSDocs.
Additional Information