Merge pull request #7872 from vitormateusalmeida/issue-7824

Fix cursor stuck on dragging in firefox
This commit is contained in:
Anton Georgiev 2019-08-01 12:13:42 -04:00 committed by GitHub
commit 08109e9816
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -165,9 +165,9 @@ class WebcamDraggable extends Component {
const targetClassname = e.target.className;
const { x, y } = position;
if (targetClassname.includes('Top')) {
if (targetClassname && targetClassname.includes('Top')) {
webcamDraggableDispatch({ type: 'setplacementToTop' });
} else if (targetClassname.includes('Bottom')) {
} else if (targetClassname && targetClassname.includes('Bottom')) {
webcamDraggableDispatch({ type: 'setplacementToBottom' });
} else if (singleWebcam) {
webcamDraggableDispatch(