dragKonva = async ([x, y, shiftX, shiftY]) => {
  const stage = window.Konva.stages[0];
  const delay = (timeout = 0) => new Promise((resolve) => setTimeout(resolve, timeout));

  stage.fire("mousedown", { evt: { offsetX: x, offsetY: y } });
  await delay();
  stage.fire("mousemove", { evt: { offsetX: x + (shiftX >> 1), offsetY: y + (shiftY >> 1) } });
  await delay();
  // we should move the cursor to the last point and only after that release the mouse
  stage.fire("mousemove", { evt: { offsetX: x + shiftX, offsetY: y + shiftY } });
  await delay();
  // because some events work on mousemove and not on mouseup
  stage.fire("mouseup", { evt: { offsetX: x + shiftX, offsetY: y + shiftY } });
  // looks like Konva needs some time to update image according to dpi
  await delay(32);
}
Click and hold, move the cursor (with one pause in the middle) and release the mouse
@param {number} x
@param {number} y
@param {number} shiftX
@param {number} shiftY