diff --git a/source b/source index dedfde927e5..f9a30e35334 100644 --- a/source +++ b/source @@ -78338,7 +78338,6 @@ dictionary DragEventInit : MouseEventInit { boolean confirm(optional DOMString message = ""); DOMString? prompt(optional DOMString message = "", optional DOMString default = ""); void print(); - any showModalDialog(DOMString url, optional any argument); // deprecated unsigned long requestAnimationFrame(FrameRequestCallback callback); void cancelAnimationFrame(unsigned long handle); @@ -79744,9 +79743,8 @@ x === this; // true

This flag prevents content from creating new auxiliary browsing - contexts, e.g. using the target attribute, the - window.open() method, or the showModalDialog() method.

+ contexts, e.g. using the target attribute or + the window.open() method.

@@ -79905,7 +79903,6 @@ x === this; // true
  • window.confirm()
  • window.print()
  • window.prompt()
  • -
  • window.showModalDialog()
  • the beforeunload event
  • @@ -89150,291 +89147,6 @@ scheduleWork(); // queues a task to do lots of work - -

    Dialogs implemented using separate documents with showModalDialog()

    - -

    This feature is in the process of being removed from the Web platform. (This - is a long process that takes many years.) Using the showModalDialog() API at this time is highly discouraged.

    - - - -
    - -

    The showModalDialog(url, argument) method, when invoked, - must cause the user agent to run the following steps:

    - -
      - -
    1. - -

      Resolve url relative to the - API base URL specified by the entry settings object.

      - -

      If this fails, then throw a SyntaxError exception and abort these steps.

      - -
    2. - -
    3. If the event loop's termination nesting level is non-zero, - optionally abort these steps, returning the empty string.

    4. - -
    5. - -

      Release the storage mutex.

      - -
    6. - -
    7. - -

      If the user agent is configured such that this invocation of showModalDialog() is somehow disabled, then return the empty - string and abort these steps.

      - -

      User agents are expected to disable this method in certain cases to avoid user - annoyance (e.g. as part of their popup blocker feature). For instance, a user agent could - require that a site be safelisted before enabling this method, or the user agent could be - configured to only allow one modal dialog at a time.

      - -
    8. - -
    9. - -

      If the active sandboxing flag set of the active document of the - responsible browsing context specified by the incumbent settings - object has either the sandboxed auxiliary navigation browsing context flag - or sandboxed modals flag set, then return the empty string and abort these - steps.

      - -
    10. - -
    11. - -

      Let incumbent origin be the effective script origin - specified by the incumbent settings object at the time the showModalDialog() method was called.

      - -
    12. - -
    13. - -

      Let the list of background browsing contexts be a list of all the - browsing contexts that:

      - -
        - -
      • are part of the same unit of related browsing contexts as the browsing context - of the Window object on which the showModalDialog() method was called, and that
      • - -
      • have an active document whose origin is the same as incumbent origin,
      • - -
      - -

      ...as well as any browsing contexts that are nested inside any of the browsing contexts - matching those conditions.

      - -
    14. - -
    15. - -

      Disable the user interface for all the browsing contexts in the list of - background browsing contexts. This should prevent the user from navigating those browsing - contexts, causing events to be sent to those browsing context, or editing any content in those - browsing contexts. However, it does not prevent those browsing contexts from receiving events - from sources other than the user, from running scripts, from running animations, and so - forth.

      - -
    16. - -
    17. - -

      Create a new auxiliary browsing context, with the opener browsing - context being the browsing context of the Window object on which the showModalDialog() method was called. The new auxiliary - browsing context has no name.

      - -

      This browsing context's Documents' Window - objects all implement the WindowModal interface.

      - -
    18. - -
    19. - -

      Set all the flags in the new browsing context's popup sandboxing flag set that - are set in the active sandboxing flag set of the active document of - the responsible browsing context specified by the incumbent settings - object. The responsible browsing context specified by the incumbent - settings object must be set as the new browsing context's one permitted sandboxed - navigator.

      - -
    20. - -
    21. - -

      Let the dialog arguments of the new browsing context be set to the value of argument, or the undefined value if the argument was omitted.

      - -
    22. - -
    23. - -

      Let the dialog arguments' origin be incumbent origin.

      - -
    24. - -
    25. - -

      Let the return value of the new browsing context be the undefined value.

      - -
    26. - -
    27. - -

      Let the return value origin be incumbent origin.

      - -
    28. - -
    29. - -

      Navigate the new browsing context to - the absolute URL that resulted from resolving - url earlier, with replacement enabled, and with the - responsible browsing context specified by the incumbent settings - object as the source browsing context.

      - - - -
    30. - -
    31. - -

      Spin the event loop until the new browsing context is closed. The user agent must allow the user to indicate - that the browsing context is to be closed.

      - -
    32. - -
    33. - -

      Reenable the user interface for all the browsing contexts in the list of - background browsing contexts.

      - -
    34. - -
    35. - -

      If the auxiliary browsing context's return value origin at the time - the browsing context was closed was the same as incumbent origin, then let return value be the auxiliary browsing context's return - value as it stood when the browsing context was closed.

      - -

      Otherwise, let return value be undefined.

      - -
    36. - -
    37. - -

      Return return value.

      - -
    38. - -
    - -

    The Window objects of Documents hosted by browsing contexts created by the above algorithm must also implement the - WindowModal interface.

    - -

    When this happens, the members of the WindowModal interface, in - JavaScript environments, appear to actually be part of the Window interface (e.g. - they are on the same prototype chain as the window.alert() - method).

    - -
    - -
    [NoInterfaceObject]
    -interface WindowModal {
    -  readonly attribute any dialogArguments;
    -  attribute any returnValue;
    -};
    - -
    - -
    window . dialogArguments
    - -
    - -

    Returns the argument argument that was passed to the showModalDialog() method.

    - -
    - -
    window . returnValue [ = value ]
    - -
    - -

    Returns the current return value for the window.

    - -

    Can be set, to change the value that will be returned by the showModalDialog() method.

    - -
    - -
    - -
    - -

    Such browsing contexts have associated dialog arguments, which are stored along with - the dialog arguments' origin. These values are set by the showModalDialog() method in the algorithm above, when the - browsing context is created, based on the arguments provided to the method.

    - -

    The dialogArguments IDL - attribute, on getting, must check whether its browsing context's active document's - effective script origin is the same as the dialog arguments' - origin. If it is, then the browsing context's dialog arguments must be - returned unchanged. Otherwise, the IDL attribute must return undefined.

    - -

    These browsing contexts also have an associated return value and return value - origin. As with the previous two values, these values are set by the showModalDialog() method in the algorithm above, when the - browsing context is created.

    - -

    The returnValue IDL attribute, on - getting, must check whether its browsing context's active document's effective - script origin is the same as the current return - value origin. If it is, then the browsing context's return value must be - returned unchanged. Otherwise, the IDL attribute must return undefined. On setting, the - attribute must set the return value to the given new value, and the return - value origin to the browsing context's active document's effective - script origin.

    - -
    - -

    The window.close() method can be used to - close the browsing context.

    - -

    System state and capabilities

    The Navigator object