mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 15:38:10 +00:00
LibWeb: Create HTMLInputElement UA shadow tree when inserted into DOM
Previously, we were creating a user-agent shadow tree when constructing a layout tree. This meant that we did DOM manipulation (and consequently style invalidation) during layout tree construction, which made things very hard to reason about in Layout::TreeBuilder. Simply everything by simply creating the UA shadow tree when the input element inserted into a parent node instead.
This commit is contained in:
parent
511d4951b0
commit
88173648e3
2 changed files with 7 additions and 1 deletions
|
@ -100,6 +100,8 @@ public:
|
|||
// https://html.spec.whatwg.org/multipage/forms.html#category-label
|
||||
virtual bool is_labelable() const override { return type_state() != TypeAttributeState::Hidden; }
|
||||
|
||||
virtual void inserted() override;
|
||||
|
||||
private:
|
||||
// ^DOM::EventTarget
|
||||
virtual void did_receive_focus() override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue