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

LibWeb: Implement document.designMode

Setting this attribute to "on" makes the entire document editable.
This commit is contained in:
Tim Ledbetter 2024-02-10 15:23:19 +00:00 committed by Andreas Kling
parent c9fb3e07d2
commit 774119bb57
5 changed files with 73 additions and 0 deletions

View file

@ -561,6 +561,11 @@ public:
void add_form_associated_element_with_form_attribute(HTML::FormAssociatedElement&);
void remove_form_associated_element_with_form_attribute(HTML::FormAssociatedElement&);
bool design_mode_enabled_state() const { return m_design_mode_enabled; }
void set_design_mode_enabled_state(bool);
String design_mode() const;
WebIDL::ExceptionOr<void> set_design_mode(String const&);
Element const* element_from_point(double x, double y);
void set_needs_to_resolve_paint_only_properties() { m_needs_to_resolve_paint_only_properties = true; }
@ -789,6 +794,8 @@ private:
Vector<HTML::FormAssociatedElement*> m_form_associated_elements_with_form_attribute;
bool m_design_mode_enabled { false };
bool m_needs_to_resolve_paint_only_properties { true };
};