1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 18:55:09 +00:00

LibWeb: Make event dispatching spec-compliant

Specification: https://dom.spec.whatwg.org/#concept-event-dispatch

This also introduces shadow roots due to it being a requirement of
the event dispatcher.

However, it does not introduce the full shadow DOM, that can be
left for future work.

This changes some event dispatches which require certain attributes
to be initialised to a value.
This commit is contained in:
Luke 2020-11-21 18:32:39 +00:00 committed by Andreas Kling
parent 819f099a8e
commit e8b3a65581
32 changed files with 858 additions and 54 deletions

View file

@ -44,6 +44,7 @@ const NonnullRefPtr<Document> DOMImplementation::create_htmldocument(const Strin
auto html_document = Document::create();
html_document->set_content_type("text/html");
html_document->set_ready_for_post_load_tasks(true);
auto doctype = adopt(*new DocumentType(html_document));
doctype->set_name("html");