Skip to content

Commit

Permalink
Editorial tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
domenic committed Dec 18, 2019
1 parent 9011d81 commit 30e0431
Showing 1 changed file with 42 additions and 34 deletions.
76 changes: 42 additions & 34 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -68155,9 +68155,10 @@ dictionary <dfn>ValidityStateFlags</dfn> {
<dd>
<p>Returns the <span data-x="ce-focus-behavior">focus behavior</span> of the
<var>internals</var>'s <span data-x="internals-target">target element</span>. Possible values
are "<code data-x="">default</code>", "<code data-x="">focusable</code>", and
"<code data-x="">simple-control</code>". If an unknown value was set, this returns
"<code data-x="">focusable</code>".</p>
are "<code data-x="ce-focusBehavior-default">default</code>", "<code
data-x="ce-focusBehavior-focusable">focusable</code>", and "<code
data-x="ce-focusBehavior-simple-control">simple-control</code>". If an unknown value was set,
this returns "<code data-x="ce-focusBehavior-focusable">focusable</code>".</p>

<p>Can be set, to change the <span data-x="ce-focus-behavior">focus behavior</span> to the new
value.</p>
Expand Down Expand Up @@ -68369,53 +68370,60 @@ dictionary <dfn>ValidityStateFlags</dfn> {
<span data-x="face-submission-value">submission value</span>.</p></li>
</ol>

<p>Each <span>autonomous custom element</span> has
<dfn data-x="ce-focus-behavior">focus behavior</dfn> string, initially
"<code data-x="">default</code>". It also can be "<code data-x="">focusable</code>" or
"<code data-x="">simple-control</code>".</p>
<hr>

<p>Each <span>autonomous custom element</span> has <dfn data-x="ce-focus-behavior">focus
behavior</dfn> string, initially "<code data-x="ce-focusBehavior-default">default</code>". It also
can be "<code data-x="ce-focusBehavior-focusable">focusable</code>" or "<code
data-x="ce-focusBehavior-simple-control">simple-control</code>". These values have the following
impacts:</p>

<dl>
<dt><code data-x="">default</code></dt>
<dt>"<dfn><code data-x="ce-focusBehavior-default">default</code></dfn>"</dt>
<dd>
<p>The element is not <span>focusable</span> by default. The element's focus-related behavior
is same as elements like <code>div</code>, which is not <span>focusable</span> by default.</p>
is same as elements like <code>div</code>, which are not <span>focusable</span> by default.</p>

<p class="note">Authors can make the element with "<code data-x="">default</code>"
<span data-x="ce-focus-behavior">focus behavior</span> <span>focusable</span> with some ways.
For example, adding <code data-x="attr-tabindex">tabindex</code> content attribute or
<code data-x="attr-contenteditable">contanteditable</code> content attribute.</p>
<p class="note">There are ways for authors to make an element with "<code
data-x="ce-focusBehavior-default">default</code>" <span data-x="ce-focus-behavior">focus
behavior</span> <span>focusable</span>, e.g., adding a <code
data-x="attr-tabindex">tabindex</code> or <code
data-x="attr-contenteditable">contenteditable</code> content attribute.</p>
</dd>

<dt><code data-x="">focusable</code></dt>
<dt>"<dfn><code data-x="ce-focusBehavior-focusable">focusable</code></dfn>"</dt>
<dd><p>The element is <span>focusable</span> by default. The element's focus-related behavior is
same as general <span>focusable</span> elements such as <span>editing host</span>.</p></dd>
same as general <span>focusable</span> elements such as <span data-x="editing host">editing
hosts</span>.</p></dd>

<dt><code data-x="">simple-control</code></dt>
<dt>"<dfn><code data-x="ce-focusBehavior-simple-control">simple-control</code></dfn>"</dt>
<dd>
<p>The element is <span>focusable</span> by default. The element's focus-related behavior is
same as simple controls like a <code>button</code> element.</p>
same as simple controls like <code>button</code> elements.</p>

<p class="note">Behavior differences between "<code data-x="">focusable</code>" and
"<code data-x="">simple-control</code>" depend on the user agent. They might affect
<span>sequentially focusable</span>, <span>click focusable</span>, and
<code data-x="focus-visible-pseudo">:focus-visible</code> <span>pseudo-class</span>.</p>
<p class="note">Behavior differences between "<code
data-x="ce-focusBehavior-focusable">focusable</code>" and "<code
data-x="ce-focusBehavior-simple-control">simple-control</code>" depend on the user agent. They
might affect <span data-x="sequentially focusable">sequential focusability</span>, <span
data-x="click focusable">click focusability</span>, or the <code
data-x="focus-visible-pseudo">:focus-visible</code> <span>pseudo-class</span>.</p>
</dd>
</dl>


<p>The <dfn><code data-x="dom-ElementInternals-focusBehavior">focusBehavior</code></dfn> IDL
attribute must return <span data-x="ce-focus-behavior">focus behavior</span> of the
<span data-x="internals-target">target element</span>. On setting, if the new string is one of
"<code data-x="">default</code>", "<code data-x="">focusable</code>", and
"<code data-x="">simple-control</code>", then the
<span data-x="ce-focus-behavior">focus behavior</span> of the
<span data-x="internals-target">target element</span> must be set to the string, and otherwise it
must be set to "<code data-x="">focusable</code>".</p>
attribute, on getting, must return the <span data-x="ce-focus-behavior">focus behavior</span> of
this <code>ElementInternals</code>'s <span data-x="internals-target">target element</span>. On
setting, if the new string is one of "<code data-x="ce-focusBehavior-default">default</code>",
"<code data-x="ce-focusBehavior-focusable">focusable</code>", or "<code
data-x="ce-focusBehavior-simple-control">simple-control</code>", then set the <span
data-x="ce-focus-behavior">focus behavior</span> of this <code>ElementInternals</code>'s <span
data-x="internals-target">target element</span> to the given value. Otherwise, set it to "<code
data-x="ce-focusBehavior-focusable">focusable</code>".</p>

<p class="note">Setting <code data-x="dom-ElementInternals-focusBehavior">focusBehavior</code> to
an unknown keyword does not throw because new keywords might be added in the future, and user
agents without the new keyword support have to work somehow with documents using the new
keyword.</p>
an unknown value does not throw because new values might be added in the future, and user agents
without support for the new value have to work somehow with documents using the new keyword.</p>
</div>

<h3 split-filename="semantics-other" id="common-idioms">Common idioms without dedicated elements</h3>
Expand Down Expand Up @@ -73976,9 +73984,9 @@ END:VCARD</pre>

<li><span data-x="browsing context container">Browsing context containers</span></li>

<li><span data-x="autonomous custom element">Autonomous custom elements</span> of which
<span data-x="ce-focus-behavior">focus behavior</span> is not
"<code data-x="">default</code>".</li>
<li><span data-x="autonomous custom element">Autonomous custom elements</span> whose <span
data-x="ce-focus-behavior">focus behavior</span> is not "<code
data-x="ce-focusBehavior-default">default</code>".</li>
</ul>

</dd>
Expand Down

0 comments on commit 30e0431

Please sign in to comment.