Skip to content
This repository has been archived by the owner on May 21, 2020. It is now read-only.

Click event bubbles through overlay #24

Open
Redmega opened this issue Feb 27, 2017 · 9 comments
Open

Click event bubbles through overlay #24

Redmega opened this issue Feb 27, 2017 · 9 comments

Comments

@Redmega
Copy link
Collaborator

Redmega commented Feb 27, 2017

If there is a button or component with onClick under the overlay, tapping on it with the drawer open will both close the drawer & fire the click event. This causes unexpected behavior, especially if the click event involves a link or a window.location change.

Updates: This happens only on mobile chrome (default for most android phones) and in the chrome browser when emulating a device using the developer tools.

@Redmega Redmega added the bug label Feb 27, 2017
@Redmega Redmega self-assigned this Feb 27, 2017
@Redmega
Copy link
Collaborator Author

Redmega commented Feb 28, 2017

I'm not able to replicate in the example project. I need to do more testing in my RL project.

@Redmega
Copy link
Collaborator Author

Redmega commented Feb 28, 2017

No longer able to replicate in my work project. I'll close it for now.

@Redmega Redmega closed this as completed Feb 28, 2017
@Redmega
Copy link
Collaborator Author

Redmega commented Feb 28, 2017

Unexpected behavior occurs in the "device emulator" view of the chrome dev tools. Probably doesn't exist elsewhere. I need to do testing on an actual mobile device to make sure it doesn't happen in the wild.

@Redmega Redmega reopened this Feb 28, 2017
@Redmega
Copy link
Collaborator Author

Redmega commented Feb 28, 2017

I can confirm this happens on mobile Chrome as well.

@Redmega Redmega removed their assignment Feb 28, 2017
@Redmega
Copy link
Collaborator Author

Redmega commented Mar 1, 2017

This does not happen on mobile safari.

@krishnaff
Copy link

Any pointers on how to fix this please?
Mobile Safari works fine. Issue is seen in Chrome and Android browsers.

@FDiskas
Copy link

FDiskas commented Apr 10, 2018

works
if i directly remove thous styles then it works

@Redmega
Copy link
Collaborator Author

Redmega commented Jul 3, 2018

Tentatively fixed by #51, but that PR introduces some hard coded styling to the body, which might interfere with the users' styling. I'm not satisfied by that approach. I'm not sure if a better alternative exists, though, so I may merge it regardless. Interested in hearing peoples thoughts on this.

@breeny
Copy link

breeny commented Jul 19, 2018

I think adding blocking on body scroll when the drawer is open is a good solution - in my implementation I had to manually add this as I had a list of dynamic content in both the drawer and the body in the background, so had cases where both would respond to scroll events depending on the length of lists etc.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants