-
Notifications
You must be signed in to change notification settings - Fork 22.5k
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
Update Feature-Policy to Permissions-Policy #22439
Update Feature-Policy to Permissions-Policy #22439
Conversation
4bfa476
to
58ac7be
Compare
This pull request has merge conflicts that must be resolved before it can be merged. |
files/en-us/web/api/absoluteorientationsensor/absoluteorientationsensor/index.md
Show resolved
Hide resolved
@@ -22,7 +22,7 @@ The **`AbsoluteOrientationSensor`** interface of the [Sensor APIs](/en-US/docs/W | |||
|
|||
To use this sensor, the user must grant permission to the `'accelerometer'`, `'gyroscope'`, and `'magnetometer'` device sensors through the [Permissions API](/en-US/docs/Web/API/Permissions_API). | |||
|
|||
If a feature policy blocks use of a feature it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. The {{httpheader('Feature-Policy')}} HTTP header article contains implementation instructions. | |||
If a Permissions Policy blocks use of a feature it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. Our [Permissions Policy](/en-US/docs/Web/HTTP/Permissions_Policy) article contains implementation instructions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, FWIW, I do not like this note, because I don't know what ". This is not something that would ever be shown to a user." means/the intent.
It is worth saying that this might be blocked though and rolling out everywhere. Something like:
This feature may be blocked by a server Permissions Policy.
... unless there is a nuance I am missing that needs to be captured?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, this note is pretty crappy. I've updated all such instances with
This feature may be blocked by a Permissions Policy set on your server.
Or some slight variation of it.
@@ -22,7 +22,7 @@ The **`Accelerometer`** interface of the [Sensor APIs](/en-US/docs/Web/API/Senso | |||
|
|||
To use this sensor, the user must grant permission to the `'accelerometer'`, device sensor through the [Permissions API](/en-US/docs/Web/API/Permissions_API). | |||
|
|||
If a feature policy blocks the use of a feature, it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. The {{httpheader('Feature-Policy')}} HTTP header article contains implementation instructions. | |||
If a Permissions Policy blocks the use of a feature, it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. Our [Permissions Policy](/en-US/docs/Web/HTTP/Permissions_Policy) article contains implementation instructions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated as per comment above.
@chrisdavidmills I have fixed the merge issues, and re-reviewed.
Once you've had a chance to look I'd be happy to merge. It's a mammoth PR so I can imagine I have missed things, but I am also sure it is way better than what preceded it. |
This pull request has merge conflicts that must be resolved before it can be merged. |
@yin1999 Would you have a chance to look into this error? 🙏 |
I'll have a look on it |
Hi @caugner, I found the problem: When we pass I've created #22898 to fix this. |
…cy-to-permissions-policy
No worries, thanks for the quick fix! 🎉 |
Let us all bow before @chrisdavidmills ! |
@hamishwillee awesome, just awesome! |
Description
This PR aims to do the work of migrating the existing
Feature-Policy
docs over toPermissions-Policy
, as described in #22347See my research document at https://docs.google.com/document/d/14xHANU3n43PfJR_dCpEwVCiVYv12BAfGqOICNvd79R4/edit#heading=h.mahbkxhoku5t for a list of the
Permissions-Policy
directives I am intending to implement on MDN as part of this work. This gives us parity with what was previously documented underFeature-Policy
, but it adds a few more that are known to be supported, and it removes mention of some that were obviously being worked on at some point, but never seem to have gotten any traction.Also see the equivalent BCD changes at mdn/browser-compat-data#18250
Notes:
Motivation
Additional details
Related issues and pull requests