Skip to content

[SelectPanel 5/8] Isolate default-off native dialog and popover hosting - #8844

Draft
TylerJDev wants to merge 1 commit into
tylerjdev/selectpanel-stack-04-adapterfrom
tylerjdev/selectpanel-stack-05-native
Draft

TylerJDev wants to merge 1 commit into
tylerjdev/selectpanel-stack-04-adapterfrom
tylerjdev/selectpanel-stack-05-native

Conversation

@TylerJDev

@TylerJDev TylerJDev commented Nov 25, 2026 •

Copy link
Copy Markdown
Member

Add the native-host experiment from #7287 as a separate, default-off review. Modal hosting uses browser dialog behavior; anchored hosting remains non-modal. Command/invoker enhancement is intentionally deferred to the next PR.

Stack

Part 5/8 of the SelectPanel split. Review this PR against its selected base, #8843, rather than against main.

Part PR Base
1 #8840 main
2 #8841 #8840
3 #8842 #8841
4 #8843 #8842
5 #8844 #8843
6 #8845 #8844
7 #8846 #8842
8 #8847 #8842

The complete integration branch retains all slices for testing; it is not the base of any focused PR. Related independent AnchoredOverlay ID fix: #8837. This split does not close #7287.

Changelog

New

Native modal-dialog and manual-popover hosts, ownership documentation, compatibility guards, and native/configured contract tests behind primer_react_select_panel_native_dialog.

Changed

React remains authoritative for open state. Native modal variants use browser modality; anchored variants permit focus to leave. Existing positioning utilities and shared reference-counted scroll locking are reused, with conservative fallbacks for unsupported configurations and configured panels inside the legacy Dialog.

Removed

None.

Rollout strategy

  • No changes needed in github/github-ui
  • Ships with feature flag(s)

primer_react_select_panel_native_dialog defaults to false. Configured native adoption also requires the adapter flag and compatibility checks. Keep compatibility hosting available as the rollback path. Includes a minor changeset.

Testing & Reviewing

Review the native ownership matrix and test modal inertness/focus containment versus anchored Tab/outside dismissal, controlled external close reconciliation, focus return, late content, nested scroll locks, heading/ref contracts, and legacy-Dialog fallback. Non-default positioning stays on compatibility hosting; no bespoke positioning engine is introduced.

Preserve the composable and configured contracts while letting the browser own modal focus containment and inertness. Keep invoker commands out of this slice.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@changeset-bot

changeset-bot Bot commented Nov 25, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: bdc0a79

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Action required

👋 Hi, this pull request contains changes to the source code that github/github-ui depends on. If you are GitHub staff, test these changes with github/github-ui using the integration workflow. Check the integration testing docs for step-by-step instructions. Or, apply the integration-tests: skipped manually label to skip these checks.

This branch was successfully deployed

2 active deployments
storybook-preview-8844 — bdc0a798 Deployed Nov 25, 2026 by github-actions[bot]
github-pages — bdc0a798 Deployed Nov 25, 2026 by TylerJDev via deploy-preview #34546
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm staff Author is a staff member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant