mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 10:07:15 +02:00
AK+Everywhere: Add Vector::contains(predicate) and use it
No functional changes.
This commit is contained in:
committed by
Sam Atkins
parent
d84a0d411c
commit
ae20ecf857
Notes:
github-actions[bot]
2026-01-08 15:28:34 +00:00
Author: https://github.com/gmta Commit: https://github.com/LadybirdBrowser/ladybird/commit/ae20ecf8578 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/7345 Reviewed-by: https://github.com/AtkinsSJ ✅
@@ -5130,7 +5130,7 @@ String HTMLParser::serialize_html_fragment(DOM::Node const& node, SerializableSh
|
||||
// - serializableShadowRoots is true and shadow's serializable is true; or
|
||||
// - shadowRoots contains shadow,
|
||||
if ((serializable_shadow_roots == SerializableShadowRoots::Yes && shadow->serializable())
|
||||
|| shadow_roots.find_first_index_if([&](auto& entry) { return entry == shadow; }).has_value()) {
|
||||
|| shadow_roots.contains([&](auto& entry) { return entry == shadow; })) {
|
||||
// then:
|
||||
// 1. Append "<template shadowrootmode="".
|
||||
builder.append("<template shadowrootmode=\""sv);
|
||||
|
||||
Reference in New Issue
Block a user