const getMousePosition = (e,bor,dom) => {
	e.stopPropagation()
	e.preventDefault();
	if(bor){
		const touch = e.changedTouches[0];
		event = {
			offsetX:touch.clientX - e.target.getBoundingClientRect().left,
			offsetY: touch.clientY - e.target.getBoundingClientRect().top,
			clientX:touch.clientX,
			clientY:touch.clientY,
			screenX:touch.screenX,
			screenY:touch.screenY,
			target:e.target,
		}
		if(dom){
			event.offsetX = touch.clientX - dom.getBoundingClientRect().left
			event.offsetY = touch.clientY - dom.getBoundingClientRect().top
		}
	}else{
		event = {
			offsetX:e.offsetX,
			offsetY:e.offsetY,
			clientX:e.clientX,
			clientY:e.clientY,
			screenX:e.screenX,
			screenY:e.screenY,
			target:e.target,
		}
	}
	return event
}

export {
	getMousePosition,
}