Commit 7a3c88f1 authored by GitLab Bot's avatar GitLab Bot

Automatic merge of gitlab-org/gitlab-ce master

parents a82cec1f bc696947
...@@ -102,7 +102,7 @@ export default { ...@@ -102,7 +102,7 @@ export default {
:style="{ :style="{
width: onionMaxPixelWidth, width: onionMaxPixelWidth,
height: onionMaxPixelHeight, height: onionMaxPixelHeight,
'user-select': dragging === true ? 'none' : '', 'user-select': dragging ? 'none' : null,
}" }"
class="onion-skin-frame" class="onion-skin-frame"
> >
......
...@@ -68,12 +68,10 @@ export default { ...@@ -68,12 +68,10 @@ export default {
}, },
startDrag() { startDrag() {
this.dragging = true; this.dragging = true;
document.body.style.userSelect = 'none';
document.body.addEventListener('mousemove', this.dragMove); document.body.addEventListener('mousemove', this.dragMove);
}, },
stopDrag() { stopDrag() {
this.dragging = false; this.dragging = false;
document.body.style.userSelect = '';
document.body.removeEventListener('mousemove', this.dragMove); document.body.removeEventListener('mousemove', this.dragMove);
}, },
prepareSwipe() { prepareSwipe() {
...@@ -104,7 +102,13 @@ export default { ...@@ -104,7 +102,13 @@ export default {
<template> <template>
<div class="swipe view"> <div class="swipe view">
<div ref="swipeFrame" class="swipe-frame"> <div
ref="swipeFrame"
:style="{
'user-select': dragging ? 'none' : null,
}"
class="swipe-frame"
>
<image-viewer <image-viewer
key="swipeOldImg" key="swipeOldImg"
ref="swipeOldImg" ref="swipeOldImg"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment