6
0
Эх сурвалжийг харах

Merge branch '92-white-bounding-boxes-can-be-dragged' into 'master'

Resolve "white bounding boxes can be dragged"

Closes #92

See merge request troebs/pycs!86
Eric Tröbs 4 жил өмнө
parent
commit
9a063e8390

+ 6 - 1
webui/src/components/media/annotation-box.vue

@@ -1,5 +1,8 @@
 <template>
-  <div class="annotation-box" :style="style" @mousedown.stop.prevent="moveSelf" @touchstart.stop.prevent="moveSelf">
+  <div class="annotation-box"
+       :class="{draggable: type}"
+       :style="style"
+       @mousedown.stop.prevent="moveSelf" @touchstart.stop.prevent="moveSelf">
     <div class="nw" @mousedown.stop.prevent="resizeSelf('nw')" @touchstart.stop.prevent="resizeSelf('nw')"></div>
     <div class="nn" @mousedown.stop.prevent="resizeSelf('nn')" @touchstart.stop.prevent="resizeSelf('nn')"></div>
     <div class="ne" @mousedown.stop.prevent="resizeSelf('ne')" @touchstart.stop.prevent="resizeSelf('ne')"></div>
@@ -139,7 +142,9 @@ export default {
 <style scoped>
 .annotation-box {
   position: absolute;
+}
 
+.annotation-box.draggable {
   display: grid;
   grid-template-rows: 10px auto 10px;
   grid-template-columns: 10px auto 10px;