E583 Fix some Bikeshed link errors · w3c/motion-sensors@9f88664 · GitHub
[go: up one dir, main page]

Skip to content

Commit 9f88664

Browse files
author
Raphael Kubo da Costa
committed
Fix some Bikeshed link errors
LINK ERROR: No 'dfn' refs found for 'gravitysensor'. [=GravitySensor=] LINK ERROR: No 'dfn' refs found for 'linearaccelerationsensor'. [=LinearAccelerationSensor=] Refer to the GravitySensor IDL definition and to the Linear Acceleration Sensor dfn in this spec, respectively. While here, remove some link-defaults entries that are not necessary or used anywhere, and use the right LinearAccelerationSensor name in the example.
1 parent 7cf3695 commit 9f88664

File tree

2 files changed

+10
-17
lines changed

2 files changed

+10
-17
lines changed

index.bs

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -56,15 +56,6 @@ urlPrefix: https://w3c.github.io/orientation-sensor; spec: ORIENTATION-SENSOR
5656
text: absoluteorientationsensor interface
5757
</pre>
5858

59-
<pre class="link-defaults">
60-
spec:infra;
61-
type:dfn;
62-
text:list
63-
spec:generic-sensor-1;
64-
type:enum-value;
65-
text:"activated"
66-
</pre>
67-
6859
<pre class=biblio>
6960
{
7061
"QUATERNIONS": {
@@ -644,15 +635,15 @@ The [=LinearAccelerationSensor interface=] and [=GravitySensor interface=] are d
644635
[[ACCELEROMETER]] specification.
645636

646637
<div class="example">
647-
The following example implements a [=GravitySensor=] polyfill. It shows the complexity of extracting the [=gravity=] value from
638+
The following example implements a {{GravitySensor}} polyfill. It shows the complexity of extracting the [=gravity=] value from
648639
the [=Accelerometer interface=] and [=LinearAccelerationSensor interface=], in case both sensors are hardware-based sensors.
649-
In case there is no hardware-based [=LinearAccelerationSensor=], the user agent needs to implement some fusion logic based on
640+
In case there is no hardware-based [=Linear Acceleration Sensor=], the user agent needs to implement some fusion logic based on
650641
the [=Accelerometer=] value and provide a less accurate value. In the example, a simplification shortcut has been made
651642
to only listen to [=accelerometer=] events and not to both sensors' events.
652643
<pre highlight="js">
653644
class GravitySensor extends EventTarget {
654645
#accelerometer = new Accelerometer();
655-
#linearAccelerationSensor = new LinearAcceleration();
646+
#linearAccelerationSensor = new LinearAccelerationSensor();
656647
x = 0;
657648
y = 0;
658649
z = 0;

index.html

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1079,15 +1079,15 @@ <h3 class="heading settled" data-level="4.6" id="gravity-and-linear-acceleration
10791079
<p><a data-link-type="dfn" href="https://w3c.github.io/accelerometer#gravity" id="ref-for-gravity②⑦">Gravity</a> can also be removed from a <a data-link-type="dfn" href="#linear-acceleration-sensor" id="ref-for-linear-acceleration-sensor②">linear acceleration sensor</a> using a <a data-link-type="dfn" href="#magnetometer-magnetometers" id="ref-for-magnetometer-magnetometers⑨">magnetometer</a>,
10801080
as the <a data-link-type="dfn" href="https://w3c.github.io/magnetometer#magnetic-field" id="ref-for-magnetic-field⑧">magnetic field</a> vector is more or less stable.</p>
10811081
<p>The <a data-link-type="dfn" href="https://w3c.github.io/accelerometer#linearaccelerationsensor-interface" id="ref-for-linearaccelerationsensor-interface">LinearAccelerationSensor interface</a> and <a data-link-type="dfn" href="https://w3c.github.io/accelerometer#gravitysensor-interface" id="ref-for-gravitysensor-interface">GravitySensor interface</a> are defined in <a data-link-type="biblio" href="#biblio-accelerometer" title="Accelerometer">[ACCELEROMETER]</a> specification.</p>
1082-
<div class="example" id="example-bd1f66c4">
1083-
<a class="self-link" href="#example-bd1f66c4"></a> The following example implements a <a data-link-type="dfn">GravitySensor</a> polyfill. It shows the complexity of extracting the <a data-link-type="dfn" href="https://w3c.github.io/accelerometer#gravity" id="ref-for-gravity②⑧">gravity</a> value from
1082+
<div class="example" id="example-c308d41e">
1083+
<a class="self-link" href="#example-c308d41e"></a> The following example implements a <code class="idl"><a data-link-type="idl" href="https://w3c.github.io/accelerometer/#gravitysensor" id="ref-for-gravitysensor">GravitySensor</a></code> polyfill. It shows the complexity of extracting the <a data-link-type="dfn" href="https://w3c.github.io/accelerometer#gravity" id="ref-for-gravity②⑧">gravity</a> value from
10841084
the <a data-link-type="dfn" href="https://w3c.github.io/accelerometer#accelerometer-interface" id="ref-for-accelerometer-interface①">Accelerometer interface</a> and <a data-link-type="dfn" href="https://w3c.github.io/accelerometer#linearaccelerationsensor-interface" id="ref-for-linearaccelerationsensor-interface①">LinearAccelerationSensor interface</a>, in case both sensors are hardware-based sensors.
1085-
In case there is no hardware-based <a data-link-type="dfn">LinearAccelerationSensor</a>, the user agent needs to implement some fusion logic based on
1085+
In case there is no hardware-based <a data-link-type="dfn" href="#linear-acceleration-sensor" id="ref-for-linear-acceleration-sensor③">Linear Acceleration Sensor</a>, the user agent needs to implement some fusion logic based on
10861086
the <a data-link-type="dfn" href="#accelerometer" id="ref-for-accelerometer②③">Accelerometer</a> value and provide a less accurate value. In the example, a simplification shortcut has been made
10871087
to only listen to <a data-link-type="dfn" href="#accelerometer" id="ref-for-accelerometer②④">accelerometer</a> events and not to both sensors' events.
10881088
<pre class="highlight"> <c- a>class</c-> GravitySensor <c- k>extends</c-> EventTarget <c- p>{</c->
10891089
#accelerometer <c- o>=</c-> <c- ow>new</c-> Accelerometer<c- p>();</c->
1090-
#linearAccelerationSensor <c- o>=</c-> <c- ow>new</c-> LinearAcceleration<c- p>();</c->
1090+
#linearAccelerationSensor <c- o>=</c-> <c- ow>new</c-> LinearAccelerationSensor<c- p>();</c->
10911091
x <c- o>=</c-> <c- mf>0</c-><c- p>;</c->
10921092
y <c- o>=</c-> <c- mf>0</c-><c- p>;</c->
10931093
z <c- o>=</c-> <c- mf>0</c-><c- p>;</c->
@@ -1187,6 +1187,7 @@ <h3 class="no-num no-ref heading settled" id="index-defined-elsewhere"><span cla
11871187
<li>
11881188
<a data-link-type="biblio">[ACCELEROMETER]</a> defines the following terms:
11891189
<ul>
1190+
<li><span class="dfn-paneled" id="831f85b2">GravitySensor</span>
11901191
<li><span class="dfn-paneled" id="95f495ac">acceleration</span>
11911192
<li><span class="dfn-paneled" id="0f6f1720">accelerometer interface</span>
11921193
<li><span class="dfn-paneled" id="71940125">gravity</span>
@@ -1558,6 +1559,7 @@ <h3 class="no-num no-ref heading settled" id="informative"><span class="content"
15581559
</script>
15591560
<script>/* Boilerplate: script-dfn-panel-json */
15601561
window.dfnpanelData = {};
1562+
window.dfnpanelData['831f85b2'] = {"dfnID": "831f85b2", "url": "https://w3c.github.io/accelerometer/#gravitysensor", "dfnText": "GravitySensor", "refSections": [{"refs": [{"id": "ref-for-gravitysensor"}], "title": "4.6. Gravity and Linear Acceleration Sensor"}], "external": true};
15611563
window.dfnpanelData['95f495ac'] = {"dfnID": "95f495ac", "url": "https://w3c.github.io/accelerometer#acceleration", "dfnText": "acceleration", "refSections": [{"refs": [{"id": "ref-for-acceleration"}], "title": "4.3. Absolute Orientation Sensor"}], "external": true};
15621564
window.dfnpanelData['0f6f1720'] = {"dfnID": "0f6f1720", "url": "https://w3c.github.io/accelerometer#accelerometer-interface", "dfnText": "accelerometer interface", "refSections": [{"refs": [{ B5F2 "id": "ref-for-accelerometer-interface"}], "title": "3.1. Accelerometer"}, {"refs": [{"id": "ref-for-accelerometer-interface\u2460"}], "title": "4.6. Gravity and Linear Acceleration Sensor"}], "external": true};
15631565
window.dfnpanelData['71940125'] = {"dfnID": "71940125", "url": "https://w3c.github.io/accelerometer#gravity", "dfnText": "gravity", "refSections": [{"refs": [{"id": "ref-for-gravity"}, {"id": "ref-for-gravity\u2460"}, {"id": "ref-for-gravity\u2461"}, {"id": "ref-for-gravity\u2462"}, {"id": "ref-for-gravity\u2463"}, {"id": "ref-for-gravity\u2464"}, {"id": "ref-for-gravity\u2465"}, {"id": "ref-for-gravity\u2466"}], "title": "3.1. Accelerometer"}, {"refs": [{"id": "ref-for-gravity\u2467"}, {"id": "ref-for-gravity\u2468"}], "title": "3.3. Magnetometer"}, {"refs": [{"id": "ref-for-gravity\u2460\u24ea"}, {"id": "ref-for-gravity\u2460\u2460"}, {"id": "ref-for-gravity\u2460\u2461"}, {"id": "ref-for-gravity\u2460\u2462"}, {"id": "ref-for-gravity\u2460\u2463"}, {"id": "ref-for-gravity\u2460\u2464"}, {"id": "ref-for-gravity\u2460\u2465"}], "title": "4.3. Absolute Orientation Sensor"}, {"refs": [{"id": "ref-for-gravity\u2460\u2466"}, {"id": "ref-for-gravity\u2460\u2467"}], "title": "4.4. Geomagnetic Orientation Sensor"}, {"refs": [{"id": "ref-for-gravity\u2460\u2468"}, {"id": "ref-for-gravity\u2461\u24ea"}], "title": "4.5. Relative Orientation Sensor"}, {"refs": [{"id": "ref-for-gravity\u2461\u2460"}, {"id": "ref-for-gravity\u2461\u2461"}, {"id": "ref-for-gravity\u2461\u2462"}], "title": "4.5.1. Complementary filter"}, {"refs": [{"id": "ref-for-gravity\u2461\u2463"}, {"id": "ref-for-gravity\u2461\u2464"}, {"id": "ref-for-gravity\u2461\u2465"}, {"id": "ref-for-gravity\u2461\u2466"}, {"id": "ref-for-gravity\u2461\u2467"}, {"id": "ref-for-gravity\u2461\u2468"}], "title": "4.6. Gravity and Linear Acceleration Sensor"}], "external": true};
@@ -1580,7 +1582,7 @@ <h3 class="no-num no-ref heading settled" id="informative"><span class="content"
15801582
window.dfnpanelData['geomagnetic-orientation-sensor'] = {"dfnID": "geomagnetic-orientation-sensor", "url": "#geomagnetic-orientation-sensor", "dfnText": "Geomagnetic Orientation Sensor", "refSections": [{"refs": [{"id": "ref-for-geomagnetic-orientation-sensor"}], "title": "4.1. Common fusion sensors"}, {"refs": [{"id": "ref-for-geomagnetic-orientation-sensor\u2460"}], "title": "4.4. Geomagnetic Orientation Sensor"}], "external": false};
15811583
window.dfnpanelData['relative-orientation-sensor'] = {"dfnID": "relative-orientation-sensor", "url": "#relative-orientation-sensor", "dfnText": "Relative Orientation Sensor", "refSections": [{"refs": [{"id": "ref-for-relative-orientation-sensor"}], "title": "4.1. Common fusion sensors"}, {"refs": [{"id": "ref-for-relative-orientation-sensor\u2460"}], "title": "4.3. Absolute Orientation Sensor"}], "external": false};
15821584
window.dfnpanelData['complementary-filter'] = {"dfnID": "complementary-filter", "url": "#complementary-filter", "dfnText": "complementary filter", "refSections": [{"refs": [{"id": "ref-for-complementary-filter"}, {"id": "ref-for-complementary-filter\u2460"}], "title": "4.5. Relative Orientation Sensor"}, {"refs": [{"id": "ref-for-complementary-filter\u2461"}], "title": "4.5.1. Complementary filter"}, {"refs": [{"id": "ref-for-complementary-filter\u2462"}], "title": "4.6. Gravity and Linear Acceleration Sensor"}], "external": false};
1583-
window.dfnpanelData['linear-acceleration-sensor'] = {"dfnID": "linear-acceleration-sensor", "url": "#linear-acceleration-sensor", "dfnText": "Linear Acceleration Sensor", "refSections": [{"refs": [{"id": "ref-for-linear-acceleration-sensor"}], "title": "3.1. Accelerometer"}, {"refs": [{"id": "ref-for-linear-acceleration-sensor\u2460"}], "title": "4.1. Common fusion sensors"}, {"refs": [{"id": "ref-for-linear-acceleration-sensor\u2461"}], "title": "4.6. Gravity and Linear Acceleration Sensor"}], "external": false};
1585+
window.dfnpanelData['linear-acceleration-sensor'] = {"dfnID": "linear-acceleration-sensor", "url": "#linear-acceleration-sensor", "dfnText": "Linear Acceleration Sensor", "refSections": [{"refs": [{"id": "ref-for-linear-acceleration-sensor"}], "title": "3.1. Accelerometer"}, {"refs": [{"id": "ref-for-linear-acceleration-sensor\u2460"}], "title": "4.1. Common fusion sensors"}, {"refs": [{"id": "ref-for-linear-acceleration-sensor\u2461"}, {"id": "ref-for-linear-acceleration-sensor\u2462"}], "title": "4.6. Gravity and Linear Acceleration Sensor"}], "external": false};
15841586
window.dfnpanelData['gravity-sensor'] = {"dfnID": "gravity-sensor", "url": "#gravity-sensor", "dfnText": "Gravity Sensor", "refSections": [{"refs": [{"id": "ref-for-gravity-sensor"}], "title": "3.1. Accelerometer"}, {"refs": [{"id": "ref-for-gravity-sensor\u2460"}], "title": "4.1. Common fusion sensors"}, {"refs": [{"id": "ref-for-gravity-sensor\u2461"}, {"id": "ref-for-gravity-sensor\u2462"}], "title": "4.3. Absolute Orientation Sensor"}], "external": false};
15851587
</script>
15861588
<script>/* Boilerplate: script-dom-helper */

0 commit comments

Comments
 (0)
0