Support type selector for camel-cased SVG elements in HTML.

In HTML documents, type selectors are case-insensitive for HTML elements,
but case sensitive for SVG elements [1]. We store the lower case version
of the type selector. For SVG elements, the tag name is normalized to
the camel-case version during parsing. That means we would never match
SVG tag names containing upper-case letters in HTML documents.

This CL matches SVG tag names case-insensitively in HTML documents. That
is not correct according to spec, but at least makes it possible to use
type selectors for SVG elements in HTML documents.

Since the tag name for SVG elements are still stored camelCased, we need
to lower the localName() before using it collecting tag rules from rule
sets or collecting tag name hashes for the the bloom filter.

[1] https://html.spec.whatwg.org/multipage/scripting.html#selectors

BUG=237435

Review URL: https://codereview.chromium.org/1099963003

git-svn-id: svn://svn.chromium.org/blink/trunk@195038 bbb929c8-8fbe-4397-9dbb-9b2b20218538
11 files changed
tree: 9ec3d73b2a3cc7fc08cf3476f4ce6002a93694cc
  1. third_party/