diff --git a/source b/source index 3bd4c337543..83db0c23c74 100644 --- a/source +++ b/source @@ -71814,10 +71814,9 @@ END:VCARD Elements that have their tabindex focus flag set, that are not actually disabled, that are not expressly inert, and that are either being - rendered or being used as relevant canvas fallback content. + data-x="concept-element-disabled">actually disabled, that are not expressly + inert, and that are either being rendered or being used as relevant + canvas fallback content. The element itself. @@ -71830,8 +71829,8 @@ END:VCARD The shapes of area elements in an image map associated with an - img element that is being rendered and is not expressly inert. + img element that is being rendered and is not expressly + inert. The img element. @@ -71851,8 +71850,8 @@ END:VCARD The user-agent provided subwidgets of elements that are being rendered and are not - actually disabled or expressly inert. + actually disabled or expressly + inert. The element for which the focusable area is a subwidget. @@ -71868,8 +71867,8 @@ END:VCARD - The scrollable regions of elements that are being rendered and are not expressly inert. @@ -71941,41 +71940,53 @@ END:VCARD object's control group.

+

Thus:

-

Thus, a viewport always belongs to the control group of the - Document for which the viewport was created, an input - control belongs to the control group of its nearest ancestor dialog or - Document, and an image map's shapes belong to the nearest ancestor - dialog or Document of the img elements (not the - area elements — this means one area element might create multiple - shapes in different control groups).

+

It is possible for a control group to be empty, i.e. for it to have no focusable areas.

-

An element is expressly inert if it is - inert but it is not a control group owner object and its nearest - ancestor control group owner object is not inert.

+
-

One focusable area in each non-empty control group is designated the - focused area of the control group. Which control is so designated changes over time, - based on algorithms in this specification. If a control group is empty, it has no focused area.

+

An element + is expressly inert if it is inert and its nearest ancestor control + group owner object is not inert.

+ +
+

In a page with no dialog elements, all elements that are inert are + expressly inert, and vice-versa.

+ +

Inside an inert dialog element, all descendant elements are not + expressly inert, even if they are inert.

+ +

A dialog element is expressly inert if it is inert and + not nested inside another inert dialog.

+
+ +

Each control group owner object can also act as the manager of a dialog group.

Each dialog element that has an open attribute specified and that is being rendered (i.e. that is a control group - owner object) and is not expressly inert + owner object) and is not expressly inert belongs to the dialog group whose manager is the dialog element's nearest ancestor control group owner object.

-

A dialog is expressly inert if it is - inert but its nearest ancestor control group owner object is not.

-

If no dialog element has a particular control group owner object as its nearest ancestor control group owner object, then that control group owner object has no dialog group.

@@ -71984,17 +71995,22 @@ END:VCARD dialog of the dialog group. Which dialog is so designated changes over time, based on algorithms in this specification.

+

Elements in dialog groups are ordered in tree + order.

+
+

One focusable area in each non-empty control group is designated the + focused area of the control group. Which control is so designated changes over time, + based on algorithms in this specification. If a control group is empty, it has no focused area.

+

Focusable areas in control groups are ordered relative to the tree order of their DOM anchors. Focusable areas with the same DOM anchor in a control group are ordered relative to their CSS box's relative positions in a pre-order, depth-first traversal of the box tree.

-

Elements in dialog groups are ordered in tree - order.

-

The currently focused area of a top-level browsing context at any particular time is @@ -72479,11 +72495,10 @@ END:VCARD

Focus fixup rule one: When the designated focused area of a control group is removed from that control group in some way (e.g. it stops being a focusable area, it is removed from the DOM, it - becomes expressly inert, etc), and the control - group is still not empty: designate the first non-inert focused area in that control group to be the new - focused area of the control group, if any; if they are all inert, then - designate the first focused area in that + becomes expressly inert, etc), and the control group is still not + empty: designate the first non-inert focusable area in that + control group to be the new focused area of the control group, if any; + if they are all inert, then designate the first focusable area in that control group to be the new focused area of the control group regardless of inertness. If such a removal instead results in the control group being empty, then there is simply no longer a focused area of the control @@ -72494,6 +72509,14 @@ END:VCARD also happen to an input element when the element gets disabled.

+

In a Document without dialog elements, whose focused area is a button element, + removing, disabling, or hiding that button would cause the page's new focused area to be the viewport of the + Document. This would, in turn, be reflected through the activeElement API as the body + element.

+

Focus fixup rule two: When a dialog group has no designated focused dialog of the dialog group, and its dialog group manager's control group changes from being non-empty to being empty, the first non-inert @@ -72502,18 +72525,18 @@ END:VCARD the focused dialog of the dialog group.

Focus fixup rule three: When the designated focused dialog of a dialog group is removed from that dialog group in - some way (e.g. it stops being rendered, it loses its open attribute, it becomes expressly inert, etc), and there is still a dialog group (because the - dialog in question was not the last dialog in that dialog group): - if the dialog group's manager's control - group is non-empty, let there be no designated focused dialog of the dialog group - any more; otherwise (in the case that the control group is empty), designate the first - non-inert dialog in the dialog group to be the focused - dialog of the dialog group, or, if they are all inert, designate the first - dialog in the dialog group to be the focused dialog of the dialog - group regardless of inertness.

+ dialog group">focused dialog of a dialog group is removed from that dialog + group in some way (e.g. it stops being rendered, it loses its open attribute, it becomes expressly inert, etc), + and there is still a dialog group (because the dialog in question was + not the last dialog in that dialog group): if the dialog + group's manager's control group is + non-empty, let there be no designated focused dialog of the dialog group any more; + otherwise (in the case that the control group is empty), designate the first + non-inert dialog in the dialog group to be the + focused dialog of the dialog group, or, if they are all inert, designate + the first dialog in the dialog group to be the focused dialog of + the dialog group regardless of inertness.

When the currently focused area of a top-level browsing context was a focusable area but stops being a focusable area, or when it was a dialog in a