Skip to content

feat(renderer): add aria-value props - #872

Open
patrickkabwe wants to merge 1 commit into
feat/a11y-hiddenfrom
feat/a11y-value
Open

patrickkabwe wants to merge 1 commit into
feat/a11y-hiddenfrom
feat/a11y-value

Conversation

@patrickkabwe

@patrickkabwe patrickkabwe commented Dec 1, 2026 •

Copy link
Copy Markdown
Collaborator

Part of #838 (step 6). Stacked on #866.

Views take aria-valuemin, aria-valuemax, aria-valuenow and aria-valuetext, for sliders, steppers and progress.

<View
  accessible
  aria-label="Download"
  aria-valuemin={0}
  aria-valuemax={100}
  aria-valuenow={progress}
  aria-valuetext={`${progress} percent`}
>
  <View layout={{ width: `${progress}%`, height: 4 }} style={{ background: '#007aff' }} />
</View>
  • JS: each prop is a plain value, compared like any other prop. The native spec has one property per prop.
  • iOS: aria-valuetext, or else aria-valuenow as a percentage of the range (the way UISlider reads), or aria-valuenow alone, goes first in accessibilityValue, followed by the state words from step 4.
  • Android: a full range sets the node's RangeInfo, so TalkBack reads it like a native SeekBar. aria-valuetext, or aria-valuenow without a range, goes first in the state description.
  • The Animations example gets a duration stepper ("Shorter", the value, "Longer") that drives the timing animation. The value reads "0.6 seconds" with a 0.2 to 2 range. Step 7 makes it a slider.

Tested on the iOS simulator: the value reads "0.6 seconds" and follows the stepper. Removing aria-valuetext in a hot reload changed it to "33%", so removed props clear natively. On the Android emulator, a temporary delegate log showed range info 0.2..2.0 at 0.6, with and without the "0.6 seconds" state description. TalkBack itself was not run.

Re-tested after the move to ARIA names and the rebase onto main: the value reads "0.6 seconds" on iOS.

@vercel

vercel Bot commented Dec 1, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
nitro-ui-docs Ready Ready Preview Dec 2, 2026 1:34pm UTC

Request Review

@patrickkabwe patrickkabwe changed the title feat(renderer): add accessibilityValue prop feat(renderer): add aria-value props Dec 2, 2026
@patrickkabwe
patrickkabwe added this pull request to stack #951 December 2, 2026 13:39
@patrickkabwe
patrickkabwe marked this pull request as ready for review December 2, 2026 13:39
@patrickkabwe
patrickkabwe requested a review from hannojg December 2, 2026 13:40
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

Successfully merging this pull request may close these issues.

1 participant