1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 01:47:35 +00:00

LibWeb: Fix various spec comment inconsistencies

- Don't add multiple numbers to nested steps, just the innermost one
  (as rendered in the HTML document)
- "Otherwise" comments go before the else, not after it
- "FIXME:" goes before step number, not between it and the comment text
- Always add a period between number and comment text

The majority of these were introduced in #13756, but some unrelated ones
have been updated as well.
This commit is contained in:
Linus Groh 2022-04-20 19:48:48 +02:00
parent bf16061142
commit 95541d7064
7 changed files with 133 additions and 131 deletions

View file

@ -1354,11 +1354,11 @@ void Document::evaluate_media_queries_and_report_changes()
// 1. For each MediaQueryList object target that has doc as its document,
// in the order they were created, oldest first, run these substeps:
for (auto& media_query_list_ptr : m_media_query_lists) {
// 1.1. If targets matches state has changed since the last time these steps
// were run, fire an event at target using the MediaQueryListEvent constructor,
// with its type attribute initialized to change, its isTrusted attribute
// initialized to true, its media attribute initialized to targets media,
// and its matches attribute initialized to targets matches state.
// 1. If targets matches state has changed since the last time these steps
// were run, fire an event at target using the MediaQueryListEvent constructor,
// with its type attribute initialized to change, its isTrusted attribute
// initialized to true, its media attribute initialized to targets media,
// and its matches attribute initialized to targets matches state.
if (media_query_list_ptr.is_null())
continue;
auto media_query_list = media_query_list_ptr.strong_ref();