diff --git a/source b/source index cf487e9120d..05d9f2a2117 100644 --- a/source +++ b/source @@ -6575,6 +6575,18 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute tree order.

+

A URL matches about:blank if its scheme is "about", its path contains a single string "blank", its + username and password are the empty string, and its host is null.

+ +

Such a URL's query and fragment can be non-null. For example, the URL + record created by parsing "about:blank?foo#bar" matches about:blank.

+
@@ -9199,7 +9211,7 @@ o.myself = o; nested browsing context's container document's origin, even though its active Document's URL is - "about:blank".

+ about:blank.

When a Document is created by a script using the createDocument() or HTMLIFrameElement : HTMLElement { -

  • Otherwise, if element has a src attribute - specified, or initialInsertion is false, then run the shared attribute - processing steps for iframe and frame elements given - element.

  • +
  • Otherwise, run the shared attribute processing steps for iframe and + frame elements given element and + initialInsertion.

  • The shared attribute processing steps for iframe and frame elements, given an element - element, are:

    + element and a boolean initialInsertion, are:

      -
    1. -

      If element has no src attribute specified, - or its value is the empty string, let url be the URL - "about:blank".

      - - -

      Otherwise, parse the value of element's src attribute, relative to element's node - document.

      +
    2. Let url be the URL record about:blank.

    3. -

      If that is not successful, then let url be the URL - "about:blank". Otherwise, let url be the resulting URL - record.

      - +
    4. If element has a src attribute specified, + and its value is not the empty string, then parse the value of + that attribute relative to element's node document. If this is + successful, then set url to the resulting URL record.

    5. If there exists an ancestor browsing context of element's nested browsing context whose active document's HTMLIFrameElement : HTMLElement { data-x="concept-url-fragment">fragments, is equal to url, then return.

    6. - + +
    7. +

      If url matches about:blank and + initialInsertion is true, then:

      + +
        +
      1. +

        Perform the URL and history update steps given element's + nested browsing context's active document and url.

        + +

        This is necessary in case url is something like about:blank?foo. If url is just plain about:blank, this will do nothing.

        +
      2. + +
      3. Run the iframe load event steps given element.

      4. + +
      5. Return.

      6. +
      +
    8. Let resource be a new request whose URL is url and whose HTMLObjectElement : HTMLElement {

      If the object element's nested browsing context is null, then create a new nested browsing context for the element.

      -

      If the URL of the given resource is not about:blank, then - navigate the element's nested browsing - context to that resource, with historyHandling set - to "replace" and the source browsing context - set to the object element's node document's If the URL of the given resource does not match about:blank, then navigate the element's nested browsing context to that resource, with historyHandling set to "replace" and the source browsing context set to the + object element's node document's browsing context. (The data attribute of the object element doesn't get updated if the browsing context gets further navigated to other locations.)

      @@ -79200,8 +79223,8 @@ popup4.close();
    origin.

  • -

    If invocationOrigin is non-null and url is about:blank, - then return invocationOrigin.

    +

    If invocationOrigin is non-null and url matches + about:blank, then return invocationOrigin.

    The result here is that two documents end up with the same underlying origin, meaning that document.domain @@ -80816,69 +80839,93 @@ dictionary WindowPostMessageOptions : PostMessageOpt tab.

  • -
  • Let new be true if windowType is either "new and - unrestricted" or "new with no opener", and false otherwise.

  • -
  • If target browsing context is null, then return null.

  • -
  • If new is true, then set up browsing context features for - target browsing context given tokenizedFeatures.

  • - -
  • Let urlRecord be the URL "about:blank".

  • -
  • -

    If url is not the empty string or new is true, then: +

    If windowType is either "new and unrestricted" or "new with no opener", then:

      +
    1. Set up browsing context features for target browsing context + given tokenizedFeatures.

    2. + +
    3. Let urlRecord be the URL record + about:blank.

    4. +
    5. If url is not the empty string, then parse url relative to the entry settings object, and set urlRecord to the resulting URL record, if any. If the parse a URL algorithm - failed, then throw a "SyntaxError" DOMException.

    6. - -
    7. Let request be a new request whose - URL is urlRecord.

    8. - -
    9. If noreferrer is true, then set request's referrer to "noreferrer".

    10. + failed, then throw a "SyntaxError" + DOMException.

      -
    11. Let window be target browsing context's active - window.

    12. +
    13. +

      If urlRecord matches about:blank, then perform the + URL and history update steps given target browsing context's + active document and urlRecord.

      -
    14. If urlRecord is "about:blank" and new is true, then - queue a global task on the networking task source given - window to fire an event named load at window, with the legacy target override - flag set.

      +

      This is necessary in case url is something like about:blank?foo. If url is just plain about:blank, this will do nothing.

      +
    15. Otherwise:

        -
      1. Let historyHandling be "replace" if - new is true; otherwise "default".

      2. +
      3. Let request be a new request whose + URL is urlRecord.

      4. + +
      5. If noreferrer is true, then set request's referrer to "no-referrer".

      6. Navigate target browsing context to request, with exceptionsEnabled set to true, historyHandling set to historyHandling, and the - source browsing context set to source browsing context.

      7. + data-x="navigation-hh">historyHandling set to "replace", and the source browsing context set to + source browsing context.

  • -
  • If noopener is true or windowType is "new with no opener", then return null.

  • -
  • -

    Otherwise, if new is false, set target browsing context's opener - browsing context to source browsing context.

    +

    Otherwise:

    + +
      +
    1. +

      If url is not the empty string, then:

      + +
        +
      1. Let urlRecord be the URL record + about:blank.

      2. -

        If new is true this is done as part of creating a new auxiliary - browsing context.

        +
      3. Parse url relative to the entry + settings object, and set urlRecord to the resulting URL + record, if any. If the parse a URL algorithm failed, then throw a + "SyntaxError" DOMException.

      4. + +
      5. Let request be a new request whose + URL is urlRecord.

      6. + +
      7. If noreferrer is true, then set request's referrer to "noreferrer".

      8. + +
      9. Navigate target browsing context to + request, with exceptionsEnabled set to true and the + source browsing context set to source browsing context.

      10. +
      +
    2. + +
    3. If noopener is false, then set target browsing context's + opener browsing context to source browsing context.

    4. +
  • +
  • If noopener is true or windowType is "new with no opener", then return null.

  • +
  • Return target browsing context's WindowProxy object.

  • @@ -88510,9 +88557,26 @@ dictionary PageTransitionEventInit : EventInit

    Set document's completely loaded time to the current time.

    -
  • Let container be document's browsing context's container.

  • +
  • +

    Let container be document's browsing context's container.

    + +
    +

    This will be null in the case where document is the initial about:blank Document in a + frame or iframe, since at the point of browsing context creation which calls this algorithm, the container + relationship has not yet been established. (That happens in a subsequent step of create + a new nested browsing context.)

    + +

    The consequence of this is that we the following steps do nothing, i.e., we do not fire an + asynchronous load event on the container element for such + cases. Instead, a synchronous load event is fired in a special + initial-insertion case in the shared attribute processing steps for iframe + and frame elements.

    +
    +
  • If container is an iframe element, then queue an element task on the DOM manipulation task source given container to run @@ -119020,7 +119084,7 @@ interface HTMLFrameSetElement : HTMLElement {

  • If element has a src attribute specified, or initialInsertion is false, then run the shared attribute processing steps for iframe and frame elements given - element.

  • + element and initialInsertion.

    The frame element potentially delays the load event.