Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing api.Device[Motion/Orientation]Event.requestPermission feature #13398

Conversation

queengooborg
Copy link
Collaborator

This PR is a part of a project to add missing interfaces and interface features to BCD that are from an active spec (including WICG specs) and is supported in at least one browser. This particular PR adds the missing requestPermission member of the DeviceMotionEvent and DeviceOrientationEvent APIs, populating the results using commit history and date.

Commit: WebKit/WebKit@1978c01#diff-cc63b7286aced27c9467c2e4466e43c0ba3960ee6991e59cefc66b06d30ea2ce (WebKit 611.1.1)

…ture

This PR is a part of a project to add missing interfaces and interface features to BCD that are from an active spec (including WICG specs) and is supported in at least one browser.  This particular PR adds the missing `requestPermission` member of the DeviceMotionEvent and DeviceOrientationEvent APIs, populating the results using commit history and date.

Commit: WebKit/WebKit@1978c01#diff-cc63b7286aced27c9467c2e4466e43c0ba3960ee6991e59cefc66b06d30ea2ce ([WebKit 611.1.1](https://github.com/WebKit/WebKit/blob/1978c01a68fb5d4a8d7a0c3becb685f3364150ae/Source/WebCore/Configurations/Version.xcconfig))
@github-actions github-actions bot added the data:api Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API label Nov 9, 2021
@foolip
Copy link
Collaborator

foolip commented Nov 10, 2021

Can you confirm this with real device testing? requestPermission() was in Source/WebCore/dom/DeviceOrientationOrMotionEvent.idl before WebKit/WebKit@1978c01 and also the EnabledBySetting=DeviceOrientationPermissionAPI extended attribute makes it impossible to have confidence based on commit history alone, as the settings for Safari aren't public.

@foolip
Copy link
Collaborator

foolip commented Nov 10, 2021

settings for Safari aren't public

Actually maybe they are to a large degree, but in any case I don't know where to find them and have confidence in them :)

@queengooborg
Copy link
Collaborator Author

Running the collector's test in iOS 14 and 14.5 shows support was added in Safari 14.5!

@foolip foolip merged commit 3985585 into mdn:main Nov 12, 2021
@queengooborg queengooborg deleted the api/DeviceMotionEvent/requestPermission/additions branch November 12, 2021 11:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:api Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants