Bug 249223

Summary: preventDefault() doesn't block selection on iOS
Product: WebKit Reporter: Pierre Ossman <ossman>
Component: UI EventsAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: megan_gardner, thorton, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: Safari 16   
Hardware: Unspecified   
OS: iOS 16   
See Also: https://bugs.webkit.org/show_bug.cgi?id=197686

Description Pierre Ossman 2022-12-13 07:17:00 PST
This issue is specific to Safari on iOS. It doesn't happen in Safari on macOS, nor in other browsers.

We (noVNC) have a canvas where we grab all UI events (keyboard, mouse, touch), pass them on to the remote system, and call preventDefault() to avoid both a local and remote action.

For the most part, this works well, but not for selections on iOS. There are two primary cases we've seen:

 * Pressing Cmd+A
 * Double-clicking

In these cases, we get a local selection in Safari as well, which means we get a blue overlay annoying the user.

We're trying to work around most of it by using -webkit-user-select, but it is difficult to handle all cases.
Comment 1 Radar WebKit Bug Importer 2022-12-20 07:17:15 PST
<rdar://problem/103556502>