Skip to content

Basically impossible to use in a scrolling div on mobile #157

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

Open
callumacrae opened this issue Sep 27, 2016 · 1 comment
Open

Basically impossible to use in a scrolling div on mobile #157

callumacrae opened this issue Sep 27, 2016 · 1 comment

Comments

@callumacrae
Copy link

Same design (in theory) as in my previous issue:

screen shot 2016-09-23 at 11 48 18

Every green box has a tether-drop instance, and they're horizontally scrollable.

If openOn is hover, then it's impossible to close without clicking on something else with a mouse event listener. If openOn is click, then it's impossible to scroll, as the drop just opens straight away.

hover doesn't work because of the way mouseout is fired on mobile: it is only fired when something like an anchor or a button is clicked. Clicking the background of the document does not cause any event to be fired.

click doesn't work because touchstart is being added to the listened click events, which also affects swiping—it makes it impossible to scroll horizontally, for a start.

@callumacrae
Copy link
Author

The problem actually seems to be when the parent element is position: relative or position: absolute.

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

No branches or pull requests

1 participant