diff --git a/dom.bs b/dom.bs index 20de2363..1e9c5e9a 100644 --- a/dom.bs +++ b/dom.bs @@ -10449,72 +10449,89 @@ interface DOMTokenList { token set (a set), which is initially empty. -
A {{DOMTokenList}} object also has an associated element and an attribute's -local name. +
A {{DOMTokenList}} object also has an associated element +(an element) and an attribute name (an attribute's +local name). Specifications may define supported tokens for a {{DOMTokenList}}'s -associated attribute's local name. +element and attribute name. -
A {{DOMTokenList}} object's +
A {{DOMTokenList}} object set's validation steps for a given token are:
If the associated attribute's local name does not define
- supported tokens, throw a TypeError.
+
If set's element and
+ attribute name does not define supported tokens, then
+ throw a TypeError.
-
Let lowercase token be a copy of token, in ASCII lowercase. +
Let lowercaseToken be token, in ASCII lowercase. -
If lowercase token is present in supported tokens, return true. +
If lowercaseToken is present in the supported tokens of + set's element and attribute name, then + return true.
Return false.
A {{DOMTokenList}} object's update steps are: +
A {{DOMTokenList}} object set's +update steps are:
If the associated element does not have an associated attribute and - token set is empty, then return. +
If get an attribute by namespace and local name given null, set's + attribute name, and set's element + returns null and set's token set is empty, then return. -
Set an attribute value for the associated element using associated - attribute's local name and the result of running the ordered set - serializer for token set. +
Set an attribute value given set's element, + set's attribute name, and the result of running the + ordered set serializer for set's token set.
A {{DOMTokenList}} object's serialize steps -are to return the result of running get an attribute value given the associated -element and the associated attribute's local name.
+A {{DOMTokenList}} object set's +serialize steps are to return the result of +running get an attribute value given set's element and +set's attribute name. +
A {{DOMTokenList}} object has these attribute change steps for its associated -element: +
A {{DOMTokenList}} object set has these attribute change steps for +set's element:
If localName is associated attribute's local name, +
If localName is set's attribute name, namespace is null, and value is null, then empty token set. -
Otherwise, if localName is associated attribute's local name, - namespace is null, then set token set to value, - parsed. +
Otherwise, if localName is set's + attribute name and namespace is null, then set set's + token set to value, parsed.
When a {{DOMTokenList}} object is created, then: +
When a {{DOMTokenList}} object set is created:
Let element be associated element. +
Let element be set's element. -
Let localName be associated attribute's local name. +
Let attributeName be set's attribute name.
Let value be the result of getting an attribute value given element and - localName. + attributeName. -
Run the attribute change steps for element, localName, +
Run the attribute change steps for element, attributeName, value, value, and null.
tokenlist . {{DOMTokenList/length}}
@@ -10575,13 +10592,16 @@ are to return the result of running get an attribute value given the asso
Can be set, to change the associated attribute.
The length attribute' getter must return
+
The object's supported property indices are the numbers in the range zero to object's token set's size − 1, unless token set is empty, in which case there are no supported property indices. +
The item(index) method steps are:
The contains(token) method steps are
to return true if this's token set[token] exists; otherwise
false.
+
The
add(tokens…)
method steps are:
@@ -10616,7 +10640,9 @@ method steps are:
Run the update steps. +
The
remove(tokens…)
method steps are:
@@ -10638,7 +10664,9 @@ method steps are:
Run the update steps. +
The toggle(token, force)
method steps are:
@@ -10665,10 +10693,12 @@ method steps are:
Return false. +
The update steps are not always run for {{DOMTokenList/toggle()}} for web compatibility. +
The
replace(token, newToken)
method steps are:
@@ -10691,10 +10721,12 @@ method steps are:
Return true. +
The update steps are not always run for {{DOMTokenList/replace()}} for web compatibility. +
The
supports(token)
method steps are:
@@ -10705,13 +10737,18 @@ method steps are:
Return result. +
The value attribute must return the
+
The value getter steps are to return the
result of running this's serialize steps.
+
Setting the {{DOMTokenList/value}} attribute must set an attribute value for the -associated element using associated attribute's local name and -the given value. +
The value setter steps are to
+set an attribute value for this's element using this's
+attribute name and the given value.
+