Skip to content

Conversation

@martijnrusschen
Copy link
Member

Add support for standard HTML aria attribute names (aria-describedby, aria-invalid, aria-labelledby, aria-required) in addition to the existing camelCase prop names (ariaDescribedBy, ariaInvalid, ariaLabelledBy, ariaRequired).

The standard HTML attribute names take precedence when both are provided. This allows developers to use the familiar HTML attribute syntax when passing aria attributes to the DatePicker component, including when using custom inputs.

Fixes #5580

@codecov
Copy link

codecov bot commented Nov 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (main@43acb66). Learn more about missing BASE report.
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6056   +/-   ##
=======================================
  Coverage        ?   99.21%           
=======================================
  Files           ?       30           
  Lines           ?     3584           
  Branches        ?     1532           
=======================================
  Hits            ?     3556           
  Misses          ?       27           
  Partials        ?        1           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Add support for standard HTML aria attribute names (aria-describedby,
aria-invalid, aria-labelledby, aria-required) in addition to the
existing camelCase prop names (ariaDescribedBy, ariaInvalid,
ariaLabelledBy, ariaRequired).

The implementation only includes aria props in the cloneElement call
when they have actual values. This prevents overwriting aria attributes
that may already be defined on a custom input component when the
DatePicker doesn't explicitly set them.

Standard HTML attribute names take precedence when both are provided.

Fixes #5580

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@martijnrusschen martijnrusschen force-pushed the fix/aria-attributes-standard-names branch from 9c7e294 to b1f069e Compare November 26, 2025 11:27
@martijnrusschen martijnrusschen merged commit c261620 into main Nov 26, 2025
6 checks passed
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.

A11y Props (aria-describedby etc.) yield undefined in customInput's element

2 participants