LibWeb: Implement Node.normalize()

This method puts the given node and all of its sub-tree into a
normalized form. A normalized sub-tree has no empty text nodes and no
adjacent text nodes.
This commit is contained in:
Tim Ledbetter 2024-07-11 21:52:03 +01:00 committed by Andreas Kling
commit 0a0651f34e
Notes: sideshowbarker 2024-07-17 02:29:45 +09:00
5 changed files with 148 additions and 0 deletions

View file

@ -156,6 +156,8 @@ public:
Optional<String> text_content() const;
void set_text_content(Optional<String> const&);
WebIDL::ExceptionOr<void> normalize();
Optional<String> node_value() const;
void set_node_value(Optional<String> const&);