Skip to content

fix(cohorts): keep wizard dropdowns inside the modal - #3311

Open
jerome-ng wants to merge 2 commits into
developfrom
jerome-ng/69-wizard-dropdown-overflow
Open

fix(cohorts): keep wizard dropdowns inside the modal#3311
jerome-ng wants to merge 2 commits into
developfrom
jerome-ng/69-wizard-dropdown-overflow

Conversation

@jerome-ng

@jerome-ng jerome-ng commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

Fix wizard dropdowns overflowing the Cohort Builder modal during scrolling. Position menus within the modal’s bounding box, hide them when their input scrolls out of view, and refresh their position when reopened by keyboard.

Before After
Before After

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The boundary ignores the outer scrolling modal body, allowing overflow on shorter viewports.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

Constrains the required-filter typeahead dropdown within the modal’s visible area.

Changes:

  • Hides dropdowns when inputs are clipped.
  • Sizes and flips dropdowns against the form boundary.
File summaries
File Description
ConceptSetTypeaheadField.vue Updates teleported dropdown positioning and visibility.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +212 to +216
const boundary = input.closest('.required-filters-modal')?.getBoundingClientRect()
const top = Math.max(0, boundary?.top ?? 0)
const bottom = Math.min(window.innerHeight, boundary?.bottom ?? window.innerHeight)
const left = Math.max(0, boundary?.left ?? 0)
const right = Math.min(window.innerWidth, boundary?.right ?? window.innerWidth)
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.

3 participants