mdn / mdn/browser-compat-data

api.ScreenOrientation.lock - not actually supported by Android WebView

Open
#21,132 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

browser:webview_android data:api p2
Dominant language
JSON
Stars
5.8k
Forks
2.6k
Avg merge
1d 21h
Merged PRs (30d)
186

Description

What type of issue is this?

Incorrect support data (example: BrowserX says "86" but support was added in "40")

What information was incorrect, unhelpful, or incomplete?

api.ScreenOrientation.lock (and unlock) are claimed to be supported by Android WebView since 38, but are not actually supported.

(also WebView 38 doesn't actually exist - the Chromium-based WebView only exists for 30, 33, 40, and 42 onward)

What browsers does this problem apply to, if applicable?

Chromium (Chrome, Edge 79+, Opera, Samsung Internet)

What did you expect to see?

No support for lock/unlock on WebView

(possibly with a note that WebView 40 exposes the API but it does not actually work; it is no longer exposed in WebView 42+)

Did you test this? If so, how?

devtools console on webview 118; screen.orientation only has angle, onchange, type properties.

(also I reviewed the chromium change that correctly hid the API in webview 42) 😄

Can you link to any release notes, bugs, pull requests, or MDN pages related to this?

https://source.chromium.org/chromium/chromium/src/+/main:android_webview/lib/aw_main_delegate.cc;l=117;drc=05700a2e26edf2610679cf578774daef53a9ea2c
https://bugs.chromium.org/p/chromium/issues/detail?id=466080
https://bugs.chromium.org/p/chromium/issues/detail?id=1497871

Do you have anything more you want to share?

No response

MDN URL

https://developer.mozilla.org/en-US/docs/Web/API/ScreenOrientation/lock

MDN metadata
MDN page report details
  • Query: api.ScreenOrientation.lock
  • Report started: 2023-10-31T18:41:05.471Z

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the compatibility-data entry for api.ScreenOrientation.lock, then compare its Android WebView data with the Chromium source link and linked Chromium bugs. Update lock and unlock so WebView support is not claimed, including the reported version details, and verify the entry matches the behavior described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
android
Domain
documentation
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.