Skip to content

Commit d5e6171

Browse files
Move elements of pointerId informative note to normative text (#411)
* Move elements of `pointerId` informative note to normative text x-ref #405 https://www.w3.org/2021/09/01-pointerevents-minutes.html#t02 * Completely rejig pointerId explanation while more verbose, this is an attempt to just explain a bit more what we're trying to do here (prevent tracking/fingerprinting, while also trying to allow some kind of "persistent" pointerId for collaborative scenarios with multiple users, for the lifetime of the page) * Be more explicit about value for primary mouse pointer
1 parent a5a66dc commit d5e6171

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -228,10 +228,10 @@ <h2><code>PointerEvent</code> interface</h2>
228228
<dl data-dfn-for="PointerEvent" data-link-for="PointerEvent">
229229
<dt><dfn>pointerId</dfn></dt>
230230
<dd>
231-
<p>A unique identifier for the pointer causing the event. This identifier MUST be unique from all other <a data-lt="active pointer">active pointers</a> in the <a>top-level browsing context</a> (as defined by [[HTML]]) at the time. The <code>pointerId</code> value of <code>-1</code> is reserved to indicate events that were generated by something other than a pointing device. The user agent MAY recycle previously retired values for <code>pointerId</code> from previous active pointers, if necessary.</p>
231+
<p>A unique identifier for the pointer causing the event. User agents MAY reserve a generic <code>pointerId</code> value of <code>0</code> or <code>1</code> for the primary mouse pointer. The <code>pointerId</code> value of <code>-1</code> MUST be reserved and used to indicate events that were generated by something other than a pointing device. For any other pointers, user agents are free to implement different strategies and approaches in how they assign a <code>pointerId</code> value. However, all <a data-lt="active pointer">active pointers</a> in the <a>top-level browsing context</a> (as defined by [[HTML]]) must be unique, and the identifier MUST NOT be influenced by any other top-level browsing context (i.e. one top-level browsing context cannot assume that the <code>pointerId</code> of a pointer will be the same when the pointer moves outside of the browsing context and into another top-level browsing context). The user agent MAY recycle previously retired values for <code>pointerId</code> from previous active pointers, or it MAY always reuse the same <code>pointerId</code> for a particular pointing device (for instance, to uniquely identify particular pen/stylus inputs from a specific user in a multi-user collaborative application). However, in the latter case, to minimize the chance of fingerprinting and tracking across different pages or domains, the <code>pointerId</code> MUST only be associated explicitly with that particular pointing device for the lifetime of the page / session, and a new randomized <code>pointerId</code> MUST be chosen the next time that particular pointing device is used again in a new session.</p>
232232

233233
<div class="note">
234-
<p>The <code>pointerId</code> selection algorithm is implementation specific. Therefore authors cannot assume values convey any particular meaning other than an identifier for the pointer that is unique from all other active pointers. As an example, user agents may simply assign a number, starting from <code>1</code>, to any active pointers, in the order that they become active — but these values are not guaranteed to be monotonically increasing. Other user agents may opt to assign a completely randomized and unique number to each active pointer. However, in the latter scenarios user agents MUST ensure that the <code>pointerId</code> that is assigned remains the same only for the lifetime of the current page, and that any new <code>pointerId</code> values are not predictable (e.g. generated randomly with cryptographically strong randomness), to minimize the possibility of users being uniquely fingerprinted and tracked across different pages.</p>
234+
<p>The <code>pointerId</code> selection algorithm is implementation specific. Therefore authors cannot assume values convey any particular meaning other than an identifier for the pointer that is unique from all other active pointers. As an example, user agents may simply assign a number, starting from <code>0</code>, to any active pointers, in the order that they become active — but these values are not guaranteed to be monotonically increasing.</p>
235235
</div>
236236
</dd>
237237
<dt><dfn>width</dfn></dt>

0 commit comments

Comments
 (0)