Skip to content

react-select does not scroll into view selected option #3769

@Aror

Description

@Aror

I expect that the following will result in the selected option being shown as soon as the dropdown is opened. It does not. It highlights the selected option but you have to scroll to it in order to see it.

<Select
   options={[...Array(121).keys()].map(num => {return {value: num, label: num}})}
   value={{label: 20, value: 20}}
   isOptionSelected={(option) => (option.value == 20) ? true : false}
 />

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions