summaryrefslogtreecommitdiff
path: root/Libraries/LibHTML/Parser
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-11-28 07:45:58 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-11-28 15:01:32 +0100
commit0c4f29f71f43e6eb6689f55aaba69688bce3d643 (patch)
tree10d4a1ae8e4209c55bec5da16facf690e6e22e3d /Libraries/LibHTML/Parser
parentf0c94758f48598a6f3055ae48988397310d45a1d (diff)
downloadserenity-0c4f29f71f43e6eb6689f55aaba69688bce3d643.zip
LibHTML: Just swallow :not selectors for now
Diffstat (limited to 'Libraries/LibHTML/Parser')
-rw-r--r--Libraries/LibHTML/Parser/CSSParser.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/Libraries/LibHTML/Parser/CSSParser.cpp b/Libraries/LibHTML/Parser/CSSParser.cpp
index de20713ca7..ad865ecfbc 100644
--- a/Libraries/LibHTML/Parser/CSSParser.cpp
+++ b/Libraries/LibHTML/Parser/CSSParser.cpp
@@ -301,8 +301,18 @@ public:
is_pseudo_element = true;
consume_one();
}
- while (is_valid_selector_char(peek()))
+ if (next_is("not")) {
+ buffer.append(consume_one());
buffer.append(consume_one());
+ buffer.append(consume_one());
+ buffer.append(consume_specific('('));
+ while (peek() != ')')
+ buffer.append(consume_one());
+ buffer.append(consume_specific(')'));
+ } else {
+ while (is_valid_selector_char(peek()))
+ buffer.append(consume_one());
+ }
auto pseudo_name = String::copy(buffer);
buffer.clear();