scrollIntoView
See original GitHub issueThis really needs a solution for having scrollIntoView. I can set a ref and try to do it all manually but then i have no way to know when the international dropdown is open or not so I can’t really use that at all.
So I would think taht:
- Need either an
onClick
handler on the international dropdown icon - Need either a automaticallyScrollIntoView prop for the dropdown or need a way to easily get ahold of the dropdown ref so we can call
ref.scrollIntoView()
on it manually if needed.
Right now the dropdown opens in my window and its cut off and there is no solution other than maybe putting a fixed div on top of it to capture the click event manually which is pretty darn hacky
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:12 (6 by maintainers)
Top Results From Across the Web
Element.scrollIntoView() - Web APIs | MDN
The Element interface's scrollIntoView() method scrolls the element's ancestor containers such that the element on which scrollIntoView() is ...
Read more >HTML DOM Element scrollIntoView() Method - W3Schools
The scrollIntoView() method scrolls an element into the visible area of the browser window. Syntax. element.scrollIntoView(align). Parameters. Parameter ...
Read more >JavaScript scrollIntoView() Explained By Examples
In this tutorial, you'll learn how to scroll an element into the view using the JavaScript scrollIntoView() method.
Read more >scrollIntoView | Can I use... Support tables for HTML5, CSS3, etc
The Element.scrollIntoView() method scrolls the current element into the visible area of the browser window. Parameters can be provided to set the position ......
Read more >Element.scrollIntoView() - Web APIs
The Element interface's scrollIntoView() method scrolls the element's parent container such that the element on which scrollIntoView() is called is visible ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I added both
onDropdown
andautomaticallyScrollIntoView
in https://github.com/halt-hammerzeit/react-phone-number-input/pull/48I also removed es6 from the gitignore so you are welcome to install it and try it out
Yeah, because this line was added 3 months before now https://github.com/halt-hammerzeit/react-phone-number-input/blame/master/source/input.js#L791
Anyway, your feedback was positive.