Skip to content

fix keyboard interaction when combobox and popover have different shadow roots - #10631

Open
chirokas wants to merge 1 commit into
adobe:mainfrom
chirokas:combobox-shadow-portal
Open

chirokas wants to merge 1 commit into
adobe:mainfrom
chirokas:combobox-shadow-portal

Conversation

@chirokas

@chirokas chirokas commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Closes

When ComboBoxInput and Popover are rendered in separate shadow DOM trees,
opening the popover via keyboard fails because the relatedTarget of the
virtualBlur event gets retargeted to the nearest shadow-including ancestor,
causing the popover to close unexpectedly.

This fix ensures keyboard interaction works correctly even when the components
don't share the same shadow root.

New.project.mp4

✅ 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
  • I understand every change in this PR and can explain why it's there.
  • If AI-assisted, I followed our AI contribution guidance and pointed my assistant at CLAUDE.md.

📝 Test Instructions:

🧢 Your Project:

@chirokas
chirokas marked this pull request as ready for review September 24, 2026 10:07
@chirokas
chirokas force-pushed the combobox-shadow-portal branch 2 times, most recently from 39ce6c9 to ed4713a Compare September 27, 2026 09:17
@chirokas
chirokas force-pushed the combobox-shadow-portal branch from ed4713a to ccb9f50 Compare October 21, 2026 14:52
@chirokas chirokas changed the title fix: fix keyboard interaction in ComboBox with shadow portal fix keyboard interaction when combobox and popover have different shadow roots Oct 21, 2026
@nwidynski

Copy link
Copy Markdown
Contributor

@snowystinger LGTM

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.

3 participants