Skip to content

Comments

fix(@react-aria/select): avoid empty option in hidden select markup#9677

Open
sonsu-lee wants to merge 1 commit intoadobe:mainfrom
sonsu-lee:fix/8085-hidden-select-empty-option
Open

fix(@react-aria/select): avoid empty option in hidden select markup#9677
sonsu-lee wants to merge 1 commit intoadobe:mainfrom
sonsu-lee:fix/8085-hidden-select-empty-option

Conversation

@sonsu-lee
Copy link
Contributor

@sonsu-lee sonsu-lee commented Feb 18, 2026

Closes #8085

✅ Pull Request Checklist:

  • Included link to corresponding React Spectrum GitHub Issue.
  • Added/updated unit tests and storybook for this change (for new code or code which already has tests).
  • Filled out test instructions.
  • Updated documentation (if it already exists for this component).
  • Looked at the Accessibility Practices for this feature - Aria Practices

📝 Test Instructions:

  1. Run yarn jest packages/@react-aria/select — two new tests should pass:
  • should include a non-empty placeholder option for native select markup
  • should submit an empty string when no value is selected
  1. In a Select story with no default value, inspect the hidden <select> and verify the first <option> is <option value="" label="\u00A0"> (no longer empty)

🧢 Your Project:

  • Personal

@github-actions github-actions bot added the RAC label Feb 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Select markup includes an empty option element, which fails W3C validation

1 participant