mirror of
https://github.com/docusealco/docuseal
synced 2026-11-04 14:42:32 -05:00
center on click
This commit is contained in:
1 parent
98055f0762
commit
e20eacb5ee
1 file changed
+4
@@ -2287,6 +2287,8 @@ export default {
|
||||
|
||||
delete field.conditions
|
||||
|
||||
const isClick = area.w === 0 || area.h === 0
|
||||
|
||||
const firstArea = {
|
||||
x: area.x,
|
||||
y: area.y,
|
||||
@@ -2303,7 +2305,9 @@ export default {
|
||||
} else {
|
||||
this.setDefaultAreaSize(firstArea, field.type)
|
||||
}
|
||||
}
|
||||
|
||||
if (isClick) {
|
||||
firstArea.x -= firstArea.w / 2
|
||||
firstArea.y -= firstArea.h / 2
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user