Skip to content

[Bug]: Combobox autosize causes unwanted scrolling when updating state #35731

@jacksonv1lle

Description

@jacksonv1lle

Component

Accordion

Package version

9.72.11

React version

^18

Environment

StackBlitz demo

Current Behavior

I am using a React state to keep track of the current option being hovered in a Combobox.
If there is a large list of options, and the listbox appears lower on the page, I am unable to select the last few items in the list as the scrollbar keeps jumping up when the state is set.

Here is an example of the bug on StackBlitz:
https://stackblitz.com/edit/q2rhzbym

Expected Behavior

The scrollbar should not jump up and I should be able to select the last item in the list

Reproduction

https://stackblitz.com/edit/q2rhzbym

Steps to reproduce

Click on the Combobox
Attempt to select the final item in the list
Observe the scrollbar jumping up

Are you reporting an Accessibility issue?

None

Suggested severity

High - No workaround

Products/sites affected

No response

Are you willing to submit a PR to fix?

no

Validations

  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • The provided reproduction is a minimal reproducible example of the bug.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions