react-tags icon indicating copy to clipboard operation
react-tags copied to clipboard

Scroll active suggestion into view

Open willsmanley opened this issue 5 years ago • 2 comments

I am overriding the maxSuggestionsLength prop to 1000 and my suggestions are in a scrollable div.

When I use the arrow keys to navigate between the suggestions, I would like to be able to keep the active suggestion in view.

Since the package doesn't expose a ref for the suggestionComponent, is there any way to handle scrolling in this way?

willsmanley avatar Feb 09 '20 14:02 willsmanley

I am not sure about the use case though. will something like #214 fix your problem, You should be able to render the best matched suggestion(s) to be near the component so you don't need scroll?

sibiraj-s avatar Aug 01 '20 09:08 sibiraj-s

The highlighted suggestion is automatically scrolled into view in the next major version of the component.

i-like-robots avatar Apr 13 '22 14:04 i-like-robots

This behaviour is available in v7+

i-like-robots avatar Oct 23 '23 08:10 i-like-robots