You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The bottom of the options list shows a gap below the last option when using a virtualized combobox where the second option has a sublabel and a sufficient number of options without sublabels.
Expected behavior
The bottom of the options list stops at the last option.
This occurs in both scrollable and unscrollable option lists.
It appears the gap is the result of the scrollable distance being calculated as if every option has a sublabel, accumulating all the height differences from all options without sublabels at the bottom.
Testing seems to suggest this only occurs when the second option has a sublabel.
The text was updated successfully, but these errors were encountered:
SpencerWBarnes
changed the title
Virtualized ComboBox miscalculates length of scrollable options
Virtualized ComboBox miscalculates height of options
Mar 2, 2023
Comment for developer who takes this issue:
Height calculations are done in VirtualScroll.tsx line 421. This function assumes that all middle children heights are the same.
Describe the bug (actual behavior)
The bottom of the options list shows a gap below the last option when using a virtualized combobox where the second option has a sublabel and a sufficient number of options without sublabels.
Expected behavior
The bottom of the options list stops at the last option.
Reproduction
Link to a minimal repro: https://codesandbox.io/s/gracious-pond-ur3c5g?file=/src/App.tsx
Steps to reproduce
Additional information
This occurs in both scrollable and unscrollable option lists.
It appears the gap is the result of the scrollable distance being calculated as if every option has a sublabel, accumulating all the height differences from all options without sublabels at the bottom.
Testing seems to suggest this only occurs when the second option has a sublabel.
The text was updated successfully, but these errors were encountered: