Bug 302969

Summary: Add an event that fires for user text input
Product: WebKit Reporter: Ben Nham <nham>
Component: New BugsAssignee: Ben Nham <nham>
Status: RESOLVED FIXED    
Severity: Normal CC: webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Ben Nham
Reported 2025-11-21 11:49:50 PST
Some use cases want an event that only fires when real user typing occurs (i.e. not synthetic modifications to input or textarea via JS). Adding an event handler for the input event that checks for isTrusted events mostly accomplishes this. But it still has some overhead that we don't want to pay for (e.g. an untrusted click event on a checkbox causes a trusted input event to fire, which then spuriously invokes the code that only cares about real user typing). To help with this, add a webkitusertextinput event that only fires when real user typing occurs which modifies a text field or text area. This is analogous to the behavior of the textDidChangeInTextField and textDidChangeInTextArea APIs that we offer to the injected bundle.
Attachments
Radar WebKit Bug Importer
Comment 1 2025-11-21 11:50:10 PST
Ben Nham
Comment 2 2025-11-21 11:51:40 PST
EWS
Comment 3 2025-12-01 10:02:05 PST
Committed 303685@main (590c0256ba49): <https://commits.webkit.org/303685@main> Reviewed commits have been landed. Closing PR #54338 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.