-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: fix dropdown menu position with scroll #1199
fix: fix dropdown menu position with scroll #1199
Conversation
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 511453e:
|
ea218d7
to
6d738de
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, left some questions for discussion
packages/ui/src/molecules/Dropdown/hooks/useDropdownPosition.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add tests for this fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well done :)
5f03a15
to
8f4729a
Compare
Signed-off-by: Arthur Andrade <arthurfelandrade@gmail.com>
Signed-off-by: Arthur Andrade <arthurfelandrade@gmail.com>
Signed-off-by: Arthur Andrade <arthurfelandrade@gmail.com>
8f4729a
to
511453e
Compare
Signed-off-by: Arthur Andrade arthurfelandrade@gmail.com
What's the purpose of this pull request?
This PR fix bugs with scroll on Dropdown component. It adds the properties
scrollLeft
andscrollTop
to calculate of position, and addsevent.preventDefault()
inKeyDown
press event, avoiding page scroll when pressed.References
https://stackoverflow.com/a/18673641