Skip to content

DropdownList used in combination with Combobox closes when adding elements to the list (infinite scroll impossible) #3089

Open
@philippe-bujeau

Description

@philippe-bujeau

Detailed description

We are implementing a Combobox with infinite scroll where we fetch the first 100 items then fetch the next ones when reaching the bottom of the DropdownList. After fetching the next 100 items we regenerate the ListItems which triggers a DropdownList.updateList(). The problem is that this function triggers a doEmitSelect() (see this line) which triggers a dropdown close. This breaks the user flow since the user has to re-open the dropdown to keep scrolling.

Is this a feature request (new component, new icon), a bug, or a general issue?

Not sure: this could be a bug or done on purpose

Is this issue related to a specific component?

DropdownList + Combobox

What did you expect to happen? What happened instead? What would you like to see changed?

I would expect the dropdown to not close when we update the list items.
If done on purpose, could we add an emitSelectedValuesOnListUpdate input to the DropdownList component so we can disable this behavior in order to implement infinite scroll?

What browser are you working in?

Chrome, Edge

What version of the Carbon Design System are you using?

5.56.3

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