From 75a84391efd63619c4825349bd459af7f77cbaac Mon Sep 17 00:00:00 2001 From: Raphael Kubo da Costa Date: Tue, 24 Oct 2023 17:23:32 +0200 Subject: [PATCH] Clean up Model section, export permission and policy-controlled feature name * Move the permissions-policy text to a separate section for clarity. * Stop saying "Gyroscope a policy-controlled feature" because it does not make much sense. The most common way to list features is by saying something like "this spec defines a feature identifed by the string 'foo'". In our case, that string is "gyroscope". * Define and export the feature identifier above, as it is used in e.g. the Orientation Sensor specification. * Explicitly list all data associated with the spec's sensor type using a definition list instead of a very long paragraph. * Similarly to w3c/accelerometer#67, define and export the "gyroscope" permission so that we can eventually link to the permission name from https://w3c.github.io/permissions-registry/ --- index.bs | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/index.bs b/index.bs index 33cd59c..00b01f6 100644 --- a/index.bs +++ b/index.bs @@ -120,20 +120,26 @@ inertial sensors are in use and/or require explicit user consent to access [=sen These mitigation strategies complement the [=generic mitigations=] defined in the Generic Sensor API [[!GENERIC-SENSOR]]. -Model {#model} -===== - -The Gyroscope sensor type's associated {{Sensor}} subclass is the {{Gyroscope}} class. +Permissions Policy integration {#permissions-policy-integration} +============================== -The Gyroscope has a default sensor, which is the device's main gyroscope sensor. +This specification defines a [=policy-controlled feature=] identified by the string "gyroscope". Its [=default allowlist=] is "`self`". -The Gyroscope is a [=powerful feature=] that is identified by the -[=powerful feature/name=] "gyroscope", which is also its associated -[=sensor permission name=]. Its [=powerful feature/permission revocation algorithm=] is the -result of calling the [=generic sensor permission revocation algorithm=] with -"gyroscope". +Model {#model} +===== -The Gyroscope is a [=policy-controlled feature=] identified by the string "gyroscope". Its [=default allowlist=] is `'self'`. +The Gyroscope sensor type has the following associated data: + + : [=Extension sensor interface=] + :: {{Gyroscope}} + : [=Sensor permission names=] + :: "gyroscope" + : [=Sensor feature names=] + :: "[=gyroscope-feature|gyroscope=]" + : [=powerful feature/Permission revocation algorithm=] + :: Invoke the [=generic sensor permission revocation algorithm=] with "gyroscope". + : [=Default sensor=] + :: The device's main gyroscope sensor. A [=latest reading=] of a {{Sensor}} of Gyroscope sensor type includes three [=map/entries=] whose [=map/keys=] are "x", "y", "z" and whose [=map/values=] contain current angular