Commit 65f79912 authored by christianrhansen's avatar christianrhansen

cells aren't resizable outside the grid anymore

parent f3530fe4
Pipeline #16659 passed with stage
in 5 minutes and 55 seconds
......@@ -424,12 +424,22 @@
}
}])
},
async mobileCellResize (annotation, width, height) {
async mobileCellResize (annotation, _w, _h) {
let
parsed = annotation.target.selector.parse(),
[x, y, w, h] = parsed.xywh
w += width
h += height
// ----- w
if (_w === -1) if (w > 1) w += _w
if (_w === 1 && x < this.grid.config.columns - w + 1) w += _w
// ----- h
if (_h === -1) if (h > 1) h += _h
if (_h === 1 && y < this.grid.config.rows - h + 1) h += _h
// w += _w
// h += _h
const value = { xywh: [x, y, w, h] }
annotation.target.selector.value = value
......
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