From 2495cb4f2732dd009c613fdc9a44289a6317a316 Mon Sep 17 00:00:00 2001 From: Krzysztof Kotowicz Date: Thu, 25 Jan 2024 15:09:01 +0100 Subject: [PATCH] Fixed copy-paste error in setAttribute() and indentation. --- dom.bs | 54 +++++++++++++++++++++++++----------------------------- 1 file changed, 25 insertions(+), 29 deletions(-) diff --git a/dom.bs b/dom.bs index 7e2db7139..5a7ed91cc 100644 --- a/dom.bs +++ b/dom.bs @@ -6413,8 +6413,8 @@ steps:

To validate and set attribute value -value for an attribute attribute, with element -element, run these steps: +{{TrustedType}} or a string value for an attribute attribute, with +element element:

  1. Let validValue be the result of calling @@ -6509,26 +6509,21 @@ or string namespace (default null): getting an attribute given namespace, localName, and element. -

  2. If attribute is null, create an attribute whose namespace is - namespace, namespace prefix is prefix, - local name is localName, value is value, and - node document is element's node document, then - append this attribute to element, and then - return. - -
      -
    1. Set attribute to a new attribute whose namespace is - namespace, namespace prefix is prefix, - local name is localName and node document is - element's node document. +

    2. +

      If attribute is null, then: +

        +
      1. Set attribute to a new attribute whose namespace is + namespace, namespace prefix is prefix, + local name is localName and node document is + element's node document. -

      2. Validate and set attribute value value for attribute with - element. +

      3. Validate and set attribute value value for attribute with + element. -

      4. Append attribute to element. +

      5. Append attribute to element. -

      6. Return. -

      +
    3. Return. +

  3. Change attribute to value.

@@ -6791,20 +6786,21 @@ method steps are: and null otherwise. -
  • If attribute is null, then: +

  • +

    If attribute is null, then: -

      -
    1. Set attribute to a new attribute whose local name is - qualifiedName and node document is this's - node document. +

        +
      1. Set attribute to a new attribute whose local name is + qualifiedName and node document is this's + node document. -

      2. Validate and set attribute value value for attribute, - with this. +

      3. Validate and set attribute value value for attribute, + with this. -

      4. Append attribute to this. +

      5. Append attribute to this. -

      6. Return. -

      +
    2. Return. +

  • Change attribute to value.