길이 text 위치 수정
This commit is contained in:
parent
f194eb603c
commit
7132b4b90e
@ -61,12 +61,18 @@ export const usePolygon = () => {
|
||||
|
||||
let left, top
|
||||
|
||||
if (line.direction === 'left' || line.direction === 'right') {
|
||||
if (line.direction === 'right') {
|
||||
left = (x1 + x2) / 2
|
||||
top = (y1 + y2) / 2 + 10
|
||||
} else if (line.direction === 'top' || line.direction === 'bottom') {
|
||||
} else if (line.direction === 'top') {
|
||||
left = (x1 + x2) / 2 + 10
|
||||
top = (y1 + y2) / 2
|
||||
} else if (line.direction === 'left') {
|
||||
left = (x1 + x2) / 2
|
||||
top = (y1 + y2) / 2 - 30
|
||||
} else if (line.direction === 'bottom') {
|
||||
left = (x1 + x2) / 2 - 50
|
||||
top = (y1 + y2) / 2
|
||||
}
|
||||
|
||||
const minX = line.left
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user