motss / app-datepicker

Datepicker element built with Google's lit and Material Design 2021
https://npm.im/app-datepicker
MIT License
180 stars 51 forks source link

when going crazy with the mouse #174

Closed cintaccs closed 4 years ago

cintaccs commented 4 years ago

Description

my users do that ... then you can end up with a dragged element on a page that is dragged away. It is a little hard to reproduce but I have done it a few times now. Basically drag + drop / swip quickly at the edge of the calendar I guess. The end result is that you will be in drag state even after having released the mouse (i.e. you can move the mouse back and forward without mousedown any longer and the pages swipe). Somehow the drag operation should never be able to end in that state.

cintaccs commented 4 years ago

It goes back to normal when clicking on a day again.

cintaccs commented 4 years ago
Screenshot 2020-02-16 at 17 35 10

I was able to do it again - here is an example of how it could look. when hovering outside the dialog nothing happens - but as soon as I hover inside the container - the pages swipe back and forward - the dragstart must still be set somehow.

cintaccs commented 4 years ago

and it is a good example of where the buttons on top of the month name looks like a UI error. MDC components doesn't do that.

cintaccs commented 4 years ago

ok - I can consistently reproduce. When dragging on a page and you drag over the border to the outside container - then release the mouse - you end up with a state "dragging" inside the container that will move as soon as you hover the mouse over the container again. I think the fix should be that if the mouse pointer is outside the container - then it should release. Maybe it will work onblur of the container too....