- From: Mason Freed <notifications@github.com>
- Date: Wed, 25 May 2022 17:25:59 -0700
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/dom/pull/1079/review/985601177@github.com>
@mfreed7 approved this pull request. Looks good! > -<p>To <dfn export>validate</dfn> a <var>qualifiedName</var>, <a>throw</a> an -"{{InvalidCharacterError!!exception}}" {{DOMException}} if <var>qualifiedName</var> does not match -the <code><a type>QName</a></code> production. +A [=string=] |string| is a <dfn>valid basic name</dfn> if it does not contain +[=ASCII whitespace=], U+0000 NULL, U+002F (/), or U+003E (>). Somehow `<` still makes me nervous, but as you point out, it's already allowed, so ok. > -<p>To <dfn export>validate and extract</dfn> a <var>namespace</var> and <var>qualifiedName</var>, -run these steps: +<div class="note"> + <p>This concept is used to validate [=attribute=] [=Attr/local names=] and + [=Attr/qualified names=], as well as both [=Element/namespace prefix|element=] and + [=Attr/namespace prefix|attribute=] namespace prefixes, in the cases where elements and attributes + are constructed with DOM APIs. Note that the prefixes additionally cannot contain U+003A (:) by + construction since they always result from the [=validate and extract=] algorithm. + + <p>Note that this means [=attribute=] [=Attr/local names=] for attributes constructed with DOM APIs + can contain U+003D (=) in positions beyond the initial character, which is not possible when using + the HTML parser. If we didn't think there would be a compat issue, it seems simpler to just outlaw `=` entirely here, rather than have this very special behavior. But also ok as-is. -- Reply to this email directly or view it on GitHub: https://github.com/whatwg/dom/pull/1079#pullrequestreview-985601177 You are receiving this because you are subscribed to this thread. Message ID: <whatwg/dom/pull/1079/review/985601177@github.com>
Received on Thursday, 26 May 2022 00:26:11 UTC