diff --git a/source b/source index 84638b6d657..73cb032dedd 100644 --- a/source +++ b/source @@ -62186,35 +62186,6 @@ interface HTMLDetailsElement : HTMLElement { -

The ancestor details revealing algorithm is to run the following steps on - currentNode:

- -
    -
  1. -

    While currentNode has a parent node within the flat tree:

    - -
      -
    1. -

      If currentNode is slotted into the second slot of a details - element:

      - -
        -
      1. Set currentNode to the details element which - currentNode is slotted into.

      2. - -
      3. If the open attribute is not set on - currentNode, then set - the open attribute on currentNode to the - empty string.

      4. -
      -
    2. - -
    3. Otherwise, set currentNode to the parent node of - currentNode within the flat tree.

    4. -
    -
  2. -
-

The following example shows the details element being used to hide technical @@ -80398,8 +80369,7 @@ END:VCARD data-x="navigate-fragid">fragment navigation. When these features attempt to scroll to a target which is in the element's subtree, the user agent will remove the hidden attribute in order to reveal the content before scrolling to - it by running the ancestor hidden-until-found revealing algorithm on the target - node.

+ it by running the ancestor revealing algorithm on the target node.

@@ -80554,30 +80524,80 @@ END:VCARD string.

-

The ancestor hidden-until-found revealing algorithm is to run the following steps on - currentNode:

+

An ancestor reveal pair is a tuple consisting of a node and a string.

+ +

The ancestor revealing algorithm given a node target is:

    +
  1. Let ancestorsToReveal be « ».

  2. + +
  3. Let ancestor be target.

  4. + +
  5. +

    While ancestor has a parent node within the flat tree:

    + +
      +
    1. If ancestor has a hidden attribute in the + Hidden Until Found state, then append (ancestor, "until-found") + to ancestorsToReveal.

    2. + +
    3. If ancestor is slotted into the second slot of a details + element which does not have an open attribute, then + append (ancestor's parent node, "details") to ancestorsToReveal.

    4. + +
    5. Set ancestor to the parent node of ancestor within the + flat tree.

    6. +
    +
  6. +
  7. -

    While currentNode has a parent node within the flat tree:

    +

    For each (ancestorToReveal, revealType) of + ancestorsToReveal:

      +
    1. If ancestorToReveal is not connected, then return.

    2. +
    3. -

      If currentNode has the hidden attribute in the - Hidden Until Found state, then:

      +

      If revealType is "until-found":

        +
      1. If ancestorToReveal's hidden attribute is + not in the Hidden Until Found state, then + return.

      2. +
      3. Fire an event named beforematch at currentNode with the beforematch at ancestorToReveal with the bubbles attribute initialized to true.

      4. +
      5. If ancestorToReveal is not connected, then return.

      6. + +
      7. If ancestorToReveal's hidden attribute is + not in the Hidden Until Found state, then + return.

      8. +
      9. Remove the hidden attribute from - currentNode.

      10. + ancestorToReveal.

      -
    4. +
    5. -
    6. Set currentNode to the parent node of currentNode within the - flat tree.

    7. +
    8. +

      Otherwise:

      + +
        +
      1. Assert: revealType is "details".

      2. + +
      3. If ancestorToReveal has an open + attribute, then return.

      4. + +
      5. Set ancestorToReveal's open + attribute to the empty string.

      6. +
      +
@@ -84451,15 +84471,8 @@ body { display:none } match.

  • Queue a global task on the user interaction task source given - node's relevant global object to run the following steps:

    - -
      -
    1. Run the ancestor details revealing algorithm on node.

    2. - -
    3. Run the ancestor hidden-until-found revealing algorithm on - node.

    4. -
    -
  • + node's relevant global object to run the ancestor revealing + algorithm on node.

    @@ -106727,10 +106740,7 @@ location.href = '#foo';

  • Set document's target element to target.

  • -
  • Run the ancestor details revealing algorithm on target.

  • - -
  • Run the ancestor hidden-until-found revealing algorithm on - target.

  • +
  • Run the ancestor revealing algorithm on target.

  • Scroll target into view, with behavior set to "auto", block set to "start", and inline