cypress-real-events icon indicating copy to clipboard operation
cypress-real-events copied to clipboard

Option "step" documentation is ambiguous

Open katapofatico opened this issue 1 year ago • 2 comments

Hello,

In order to swipe faster, I've been playing with the options parameter. In my case, I'm using length : 110 for left|right and length : 180 for top|bottom. The option step documentation says that it means how often new touch move will be generated. My first thought was: "The fewer steps, the faster swipe" (and I've double-checked the interpretation with an AI assistant), but I've checked that it's just the opposite. If I'm right, please could you clarify the documentation? BTW: it's an opportunity to copy it from the code to the README.

Thanks in advance for your super helpful library.

katapofatico avatar Feb 22 '24 09:02 katapofatico

Fan fact: I also though it should work this way 😅

If you have this off your hand could you post maybe a video of different options swiping?

dmtrKovalenko avatar Feb 22 '24 09:02 dmtrKovalenko

Not sure if this helps, but I happen to create a canvas to test the swipe events.

https://github.com/dmtrKovalenko/cypress-real-events/assets/8733840/55e0c18d-8748-40ce-9ed8-86665a4b4a65

Swiping right over a length of 960px

Step:

  • 960
  • 480
  • 240
  • 120
  • 60
  • 30
  • 15
  • 7.5
  • 3.75

reproduce repo: https://github.com/amoshydra/repro-dmtrKovalenko-cypress-real-events-i-swipes/blob/real-swipe-steps-issue-638/src/components/input/Canvas.cy.tsx

amoshydra avatar Feb 24 '24 08:02 amoshydra

@amoshydra thanks this is a pretty clear description of how this intent to be working.

dmtrKovalenko avatar Jun 15 '24 12:06 dmtrKovalenko