8000 BUG | `onLongPress` | does not honor the `distanceThreshold` paramter for touch devices · Issue #4585 · vueuse/vueuse · GitHub
[go: up one dir, main page]

Skip to content
BUG | onLongPress | does not honor the distanceThreshold paramter for touch devices #4585
Open
@ssxv

Description

@ssxv

Describe the bug

When using onLongPress
onLongPress( elementRef, () => { console.log("Long pressed"); }, { delay: 1000, distanceThreshold: 100 } // distanceThreshold: number | boolean | undefined );
Passing distanceThreshold as 100 or false does not give the room to wiggle around after long press has started on touch devices.

Reproduction

https://stackblitz.com/edit/vitejs-vite-pqjp5zzp?file=src%2FApp.vue

System Info

System:
    OS: Windows 11 10.0.26100
    CPU: (22) x64 Intel(R) Core(TM) Ultra 7 155H
    Memory: 2.10 GB / 15.46 GB
  Binaries:
    Node: 20.16.0 - ~\AppData\Local\Volta\tools\image\node\20.16.0\node.EXE
    Yarn: 4.2.2 - C:\Program Files\Volta\yarn.EXE
    npm: 10.8.1 - ~\AppData\Local\Volta\tools\image\node\20.16.0\npm.CMD
  Browsers:
    Edge: Chromium (132.0.2957.127)
    Internet Explorer: 11.0.26100.1882

Used Package Manager

yarn

Validations

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghas pr

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0