-
Notifications
You must be signed in to change notification settings - Fork 59
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
Make 'Conditions to expose sensor readings' must #288
Conversation
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.
Should spec open possibility to introduce new conditions for UA to implement required mitigation strategies?
@@ -648,10 +648,8 @@ environment constraints, e.g., software power consumption optimizations or the u | |||
|
|||
## Conditions to expose sensor readings ## {#concepts-can-expose-sensor-readings} | |||
|
|||
The user agent can define the list of [=conditions=] to check if it |
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.
The user agent must verify that all [=mandatory conditions=] are true to check if it
<dfn>can expose sensor readings</dfn>.
The list of <dfn>mandatory conditions</dfn> is presented below:
- [=steps to determine the visibility state|Visibility state=] for an
[=active document=] of [=platform sensor=]'s associated [=browsing context=]
is "visible".
- [=Currently focused area=] belongs to an [=active document=] of [=platform sensor=]'s associated
[=browsing context=] or to an [=active document=] of a [=nested browsing context=] whose
[=active document=]'s [=origin=] is the [=same origin-domain=] as the
[=top-level browsing context=]'s [=active document=]
The user agent may extend list of [=mandatory conditions=] to implement required [=mitigation strategies=],
only if added conditions do not contradict or negate [=mandatory conditions=].
@alexshalamov, yeah and we should also provide an entry point to the list for concrete sensor specs, I was planning to make it in a following PR , do you prefer to make it all at once? |
I think the better strategy here would be to revert the offending PR as there are other issues with it, including introducing normative text in informative sections and naming a normative DFN with an informative keyword ("can") which introduces further ambiguities. |
@pozdnyakov We must do it to complete level 1 feature set, can be separate PRs. |
@alexshalamov, that is a good suggestion. Consider adding an explicit extension point for such optional conditions extension specs can hook into similarly to e.g.: https://w3c.github.io/manifest/#dfn-steps-for-processing-a-manifest |
Quite the contrary, I feel it would be confusing to use RFC 2119 terms in a definition. For precedence, see e.g.: https://html.spec.whatwg.org/#can-share-memory-with |
I wasn't suggesting that either (i.e. the "perform a security check" name was clearer). I'm just saying that the offending PR (#280) introduces numerous issues and ambiguities which were absent from the spec prior to it, and I'm not quite sure what problem it's trying to solve. This new PR doesn't solve all of the problems introduced in #280, hence my suggestion is simply to roll back the previous PR, and move from there. |
To address this comment from @tobie, I suggest you either rename:
Into:
Or remove that line. |
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.
These changes look good to me, and seem to address the comments raised. Thanks for the fast turnaround!
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.
looks better now, thanks!
Thanks for the review folks! |
Fixes #287
Preview | Diff