Skip to content

[Bug] Touch-related bug interrupts drawing #87

Open
@piperone

Description

@piperone

Hi. I've been using this library for the last few years on my PWA used primarily on iPads here. There is a bug that makes writing with a pen (like the Apple Pencil) on touch-devices using Perfect freehand a poor user experience.

To reproduce, do the following:

  1. Go to your example at https://biwyi.csb.app/
  2. With a stylus-device, tap once then quickly draw a line. The inputs should be [touchStart-touchStop] [touchStart-touchMove].
  3. If done correctly, the second touch-action is ignored and the browser tries to focus on the closes element (not sure about the logic here). In the case of the example above, a "Share"-tooltip is displayed when using Safari, interrupting the drawing.

If you don't have a stylus, you can get similar results by tapping with your finger and holding. Keeping your finger still, the browser shows the text-magnifier, thinking you're trying to highlight text. We have touch-action: none on the SVG, so we know that ain't it.

Now, I realize that this a renderer-issue, but your example app here does not suffer from this bug and it uses the renderer from tldraw.com. I would like to see an example renderer implementation that doesn't have this issue but without being dependent on tldraw.com. Any chance of that?

Thanks for your hard work!

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions