1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 14:18:12 +00:00

LibWeb: Introduce CustomElementRegistry and creating custom elements

The main missing feature here is form associated custom elements.
This commit is contained in:
Luke Wilde 2023-03-29 23:46:18 +01:00 committed by Andreas Kling
parent 083b547e97
commit 034aaf3f51
38 changed files with 1747 additions and 143 deletions

View file

@ -186,6 +186,8 @@ public:
WebIDL::ExceptionOr<JS::NonnullGCPtr<Crypto::Crypto>> crypto();
WebIDL::ExceptionOr<JS::NonnullGCPtr<CustomElementRegistry>> custom_elements();
private:
explicit Window(JS::Realm&);
@ -216,6 +218,10 @@ private:
JS::GCPtr<Navigator> m_navigator;
JS::GCPtr<Location> m_location;
// https://html.spec.whatwg.org/multipage/custom-elements.html#custom-elements-api
// Each Window object is associated with a unique instance of a CustomElementRegistry object, allocated when the Window object is created.
JS::GCPtr<CustomElementRegistry> m_custom_element_registry;
AnimationFrameCallbackDriver m_animation_frame_callback_driver;
// https://w3c.github.io/requestidlecallback/#dfn-list-of-idle-request-callbacks