bitovi / bitovi/syn

.drag() on an element outside the viewport does not work

Open
#164 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
441
Forks
254
PR merge metrics
No merged PRs in 30d

Description

If you do `.drag()` on an element outside the viewport, it does not work. This is because https://developer.mozilla.org/en-US/docs/Web/API/DocumentOrShadowRoot/elementFromPoint does not work outside the viewport.

I think we should detect this and throw an error (or warning) letting people know.

It's possible we could scroll to to make this work for locations that are not negative.

Contributor guide

Open the contributing guide

Research direction

Start at the .drag() implementation and reproduce the behavior with an element outside the viewport, checking the documented elementFromPoint limitation. Decide whether the accepted outcome is an error, warning, or scrolling behavior, then verify that the chosen behavior is covered by the relevant drag tests; no repository file or test path is named in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.