Below is the canDrag method of my drag source spec:
const itemDragSource = {
canDrag(props, monitor) {
if(props.canDrag && !props.canDrag(props.itemData)) {
if(props.dragUndraggable){
debugger;
props.dragUndraggable(props.itemData, monitor.getInitialClientOffset());
}
return false;
}
return true;
}
}
The problem is that monitor.getInitialClientOffset returns null, so does getInitialSourceClientOffset and getClientOffset? Any ideas on how to get mouse position at this point?