Repository navigation
Conversation
The suggestion list element is marked with data-prompt-trigger-autocomplete. The dismiss-on-scroll check now exempts that element and popover content, using closest() so an option inside the list counts as internal. Window resize still dismisses, because its target is not an element scroll. A browser test supplies 24 wildcards, types the opening trigger, scrolls the overflowing listbox to the bottom, and asserts that the same listbox remains open with scrollTop greater than zero. Fixes invoke-ai#9971
1 task done
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The wildcard suggestion list that opens from a positive prompt cannot be scrolled once it is taller than the popup. The mouse wheel and the scrollbar both close it immediately. Arrow keys do the same once the highlight leaves the initially visible rows: the list blinks shut, opens again, and the highlight is back on the first entry. Suggestions are dismissed on scroll and resize so the anchor does not stay put after the prompt moves.
Scrolls inside popover content were already skipped, but this list is a separate surface, so a scroll on the list or on an option inside it was treated as the field leaving the viewport and the list closed. Arrow-key movement that scrolls the same container hits that path, which remounts the list with the first entry selected.
The suggestion list element is marked with data-prompt-trigger-autocomplete. The dismiss-on-scroll check now exempts that element and popover content, using closest() so an option inside the list counts as internal. Window resize still dismisses, because its target is not an element scroll. A browser test supplies 24 wildcards, types the opening trigger, scrolls the overflowing listbox to the bottom, and asserts that the same listbox remains open with scrollTop greater than zero.
Related Issues / Discussions
Closes #9971
QA Instructions
Ran
uv run --no-sync pytest -n logicallocally on macOS for the InvokeAI change; it fails the same way on the base branch, so the failure predates this change (it fails the same way on upstream/main).Tests for the InvokeAI change live in
invokeai/frontend/webv2/src/features/generation/ui/promptFields/PositivePromptField.browser.test.tsx.Review
Not applicable to this change.
Compatibility / Rollout
Not applicable to this change.
Checklist
What's Newcopy (if doing a release after this PR)Need help on this PR? Tag
@codesmith-botwith what you need.