소수점 한자릿수 올림
This commit is contained in:
parent
85182725df
commit
af3422b663
@ -46,7 +46,7 @@ export const useLine = () => {
|
||||
const dx = x2 - x1
|
||||
const dy = y2 - y1
|
||||
|
||||
return Number(Math.sqrt(dx * dx + dy * dy).toFixed(0)) * 10
|
||||
return Number(Math.sqrt(dx * dx + dy * dy).toFixed(1)) * 10
|
||||
}
|
||||
|
||||
return {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user