Re: [w3c/screen-orientation] Consume user activation (PR #218)

Thanks for your work here, @marcoscaceres. We should absolutely prevent abuse akin to your compelling [example](https://github.com/w3c/screen-orientation/pull/218#issuecomment-1290029378).

The most apparent risk is breaking uses of Element.requestFullscreen() and Screen.Orientation.lock() from one transient user activation. Long term, https://github.com/whatwg/fullscreen/issues/186 seems nice, but we should avoid breaking existing sites. My best naive idea is an internal slot to permit locking orientation without transient user activation shortly after a fullscreen request (akin to the slot discussed in https://github.com/whatwg/html/issues/8490).

I'm not aware of other use cases for locking orientation without consuming a transient user activation (e.g. auto-advancing media queue, games, mapping). Still, attempting to measure potential impact seems like a prerequisite to making a potentially disruptive change. Collecting new Chromium metrics beyond the basic [use counter](https://chromestatus.com/metrics/feature/timeline/popularity/559) might help.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/screen-orientation/pull/218#issuecomment-1540918745
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/screen-orientation/pull/218/c1540918745@github.com>

Received on Tuesday, 9 May 2023 21:31:20 UTC