mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 03:47:34 +00:00
LibWeb: Fully implement the fragment serializing algorithm
Rather than assuming the node's node document is an HTML document, handle XML documents as well.
This commit is contained in:
parent
e1ac9c83b2
commit
13b8eeff54
7 changed files with 19 additions and 13 deletions
|
@ -13,6 +13,7 @@
|
|||
#include <AK/TypeCasts.h>
|
||||
#include <AK/Vector.h>
|
||||
#include <LibWeb/DOM/EventTarget.h>
|
||||
#include <LibWeb/DOMParsing/XMLSerializer.h>
|
||||
#include <LibWeb/WebIDL/ExceptionOr.h>
|
||||
|
||||
namespace Web::DOM {
|
||||
|
@ -196,7 +197,7 @@ public:
|
|||
i32 id() const { return m_id; }
|
||||
static Node* from_id(i32 node_id);
|
||||
|
||||
String serialize_fragment() const;
|
||||
WebIDL::ExceptionOr<String> serialize_fragment(DOMParsing::RequireWellFormed) const;
|
||||
|
||||
void replace_all(JS::GCPtr<Node>);
|
||||
void string_replace_all(String const&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue