web-platform-tests / interop

web-platform-tests Interop project
https://wpt.fyi/interop
301 stars 28 forks source link

User Activation #782

Open hvanops opened 1 week ago

hvanops commented 1 week ago

Description

User activation is the mechanism to maintain active-user-interaction state that limits use of "abusable" APIs (e.g. opening popups or vibrating). Behaviour of 30+ web features are affected by how the user activation model is implemented in the browser. We have now defined in the HTML specification a simple-to-implement user activation model along with a test-friendly JS Interface. The major browsers have been gradually switching their internal model to the standard one, but some important differences remain, which ultimately affect the Interop of 30+ other web features mentioned above.

An external developer proposed this as an Interop goal in the past: 2022 and 2023. From the 2023 proposal: “It appears that some web APIs use the modern user activation system, but some older web APIs use the old synchronous model (or some other restrictions). This makes the platform inconsistent, for example meaning developers can use async code with certain APIs but not others, and unnecessarily restricts the ability to use some older APIs.” - AshleyScirra

Specification

https://html.spec.whatwg.org/multipage/interaction.html#tracking-user-activation

Additional Signals

Standards Positions

Tests

Additional Signals

AshleyScirra commented 2 days ago

Thanks for resubmitting this for 2025!