clamp area box

This commit is contained in:
Pete Matsyburka
2026-05-15 17:20:29 +03:00
parent 5bddce8969
commit 41604008d1
2 changed files with 19 additions and 20 deletions
@@ -2512,6 +2512,11 @@ export default {
this.selectedAreasRef.value = [area]
area.x = Math.min(Math.max(area.x, 0), 1)
area.y = Math.min(Math.max(area.y, 0), 1)
area.w = Math.min(Math.max(area.w, 0), 1)
area.h = Math.min(Math.max(area.h, 0), 1)
this.save()
} else {
const documentRef = this.documentRefs.find((e) => e.document.uuid === area.attachment_uuid)