StackedRouter: use touch radius to check
All checks were successful
/ depoly (push) Successful in 1m18s
All checks were successful
/ depoly (push) Successful in 1m18s
This commit is contained in:
parent
840ad2cf00
commit
9b446aa846
1 changed files with 4 additions and 1 deletions
|
@ -306,7 +306,10 @@ const StackedRouter: Component<StackedRouterProps> = (oprops) => {
|
|||
}
|
||||
const [fig0] = event.touches;
|
||||
const { x, width } = event.currentTarget.getBoundingClientRect();
|
||||
if (fig0.clientX < (x - 44) || fig0.clientX > (x + 44)) {
|
||||
if (
|
||||
fig0.clientX - fig0.radiusX < x - 22 ||
|
||||
fig0.clientX + fig0.radiusX > x + 22
|
||||
) {
|
||||
return;
|
||||
}
|
||||
origX = x;
|
||||
|
|
Loading…
Reference in a new issue