Skip to content

fix(issues): Prevent focus trap conflict in assignee selector ownership modal - #123109

Draft
sentry[bot] wants to merge 1 commit into
masterfrom
seer/fix/issues-focus-trap-conflict
Draft

fix(issues): Prevent focus trap conflict in assignee selector ownership modal#123109
sentry[bot] wants to merge 1 commit into
masterfrom
seer/fix/issues-focus-trap-conflict

Conversation

@sentry

@sentry sentry Bot commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

This PR resolves a "RangeError: Maximum call stack size exceeded" that occurred when attempting to open the ownership rule modal from the assignee selector's footer on the issue details page.

The root cause was a conflict between two focus containment libraries: react-aria (used by the CompactSelect overlay in the assignee selector) and focus-trap (used by the ownership rule modal). When the ownership modal was opened, the CompactSelect overlay remained active, leading to both components attempting to control focus simultaneously, resulting in an infinite loop of focus events.

The fix involves modifying the additionalMenuFooterItems prop in AssigneeSelectorDropdown to accept a render prop that provides a closeOverlay function. The "Ownership" button in views/issueDetails/header/assigneeSelector.tsx now utilizes this closeOverlay function to explicitly dismiss the CompactSelect overlay before opening the ownership rule modal. This ensures only one focus trap is active at a time, preventing the conflict and the resulting stack overflow.

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

Fixes JAVASCRIPT-391T

@sentry <feedback>: Autofix iterates on these changes
@sentry stop iterating: Autofix stops iterating on this run

This PR was automatically generated by Sentry. You can adjust this setting at any time.

@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Aug 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants