diff --git a/dom.bs b/dom.bs index 182f246d..80a7c85b 100644 --- a/dom.bs +++ b/dom.bs @@ -4502,6 +4502,8 @@ dom-Range-extractContents, dom-Range-cloneContents --> clonable is true:
    +
  1. Assert: copy is not a shadow host. +

  2. Run attach a shadow root with copy, node's shadow root's mode, true, node's shadow root's delegates focus, and node's @@ -6929,7 +6931,7 @@ are:

    To attach a shadow root, given an element element, a string mode, a boolean clonable, -a boolean delegatesFocus, and a boolean slotAssignment: +a boolean delegatesFocus, and a string slotAssignment:

    1. If element's namespace is not the HTML namespace, @@ -6958,24 +6960,30 @@ a boolean delegatesFocus, and a boolean slotAssignment:

      If element is a shadow host, then:

        -
      1. If element's shadow root's declarative - is false, then throw an "{{NotSupportedError!!exception}}" {{DOMException}}. +

      2. Let currentShadowRoot be element's shadow root. + +

      3. +

        If any of the following are true: + +

          +
        • currentShadowRoot's declarative is false; or + +

        • currentShadowRoot's mode is not mode, +

        + +

        then throw a "{{NotSupportedError!!exception}}" {{DOMException}}.

      4. Otherwise:

          -
        1. Remove all of element's shadow root's - children, in tree order. +

        2. Remove all of currentShadowRoot's children, in + tree order. -

        3. Set element's shadow root's - declarative to false. +

        4. Set currentShadowRoot's declarative to false.

        5. Return.

        - -

        This means that if multiple declarative shadow roots are contained within a single - shadow host, only the last one will remain.

    2. Let shadow be a new shadow root whose node document