mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
parent
292054fd5d
commit
df59c58ffc
@ -13,10 +13,8 @@ const [createComponent, bem] = createNamespace('image-preview');
|
||||
|
||||
function getDistance(touches) {
|
||||
return Math.sqrt(
|
||||
Math.abs(
|
||||
(touches[0].clientX - touches[1].clientX) *
|
||||
(touches[0].clientY - touches[1].clientY)
|
||||
)
|
||||
((touches[0].clientX - touches[1].clientX) ** 2) +
|
||||
((touches[0].clientY - touches[1].clientY) ** 2)
|
||||
);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user