reactjs-popup
reactjs-popup copied to clipboard
Do not close modal on mouse up outside the modal when mouse down is inside
I just discovered a potential regression, cause the bug reported in issue 174 still occurs in the latest version.
When selecting text in a popup and having mouse-up event occur outside of the popup, the popup is closed.
Version
2.0.4
Test Case
To reproduce:
- Open https://react-popup.elazizi.com/home/
- Open the demo popup by clicking the button "Open modal"
- Select all text inside the popup, and make sure that your mouse is outside of the popup when you let the pressed mouse button go.
- Now, the popup closes, whilst I would like it to stay open.
Expected Behavior
When selecting text in a popup and having mouse-up event occur outside of the popup, the popup should not be closed.
Actual Behavior
When selecting text in a popup and having mouse-up event occur outside of the popup, the popup is closed.
Have the same issue here. Were you able to find a fix for this @Crustan?
Any Updates ?
Have the same issue here. Were you able to find a fix for this @Crustan?
We applied the custom hook solution mentioned in issue 174 as a temporary fix.