Because the dropdown's height is calculated as this.items.length * cursorOffset.lineHeight (https://github.com/yuku/textcomplete/blob/main/packages/textcomplete-core/src/Dropdown.ts#L227) when a max-height is set on the dropdown element, it's height is incorrectly calculated. This means the dropdown will be placed offscreen in certain circumstances, especially when there are a lot of items.
Could this.el.clientHeight be used instead?
This dropdown can show up to 100 items:
When I narrow the list down, it correctly displays on screen:
Because the dropdown's height is calculated as
this.items.length * cursorOffset.lineHeight
(https://github.com/yuku/textcomplete/blob/main/packages/textcomplete-core/src/Dropdown.ts#L227) when amax-height
is set on the dropdown element, it's height is incorrectly calculated. This means the dropdown will be placed offscreen in certain circumstances, especially when there are a lot of items.Could
this.el.clientHeight
be used instead?This dropdown can show up to 100 items:
When I narrow the list down, it correctly displays on screen: