mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-03 16:16:43 +00:00
LibWeb: Make clone_node capable of cloning document fragments
Used by Web Components Polyfills.
This commit is contained in:
parent
f7ad8c0f94
commit
5430bc8963
Notes:
sideshowbarker
2024-07-18 10:24:33 +09:00
Author: https://github.com/Lubrsi
Commit: 5430bc8963
Pull-request: https://github.com/SerenityOS/serenity/pull/8449
1 changed files with 3 additions and 0 deletions
|
@ -446,6 +446,9 @@ NonnullRefPtr<Node> Node::clone_node(Document* document, bool clone_children) co
|
|||
auto processing_instruction = verify_cast<ProcessingInstruction>(this);
|
||||
auto processing_instruction_copy = adopt_ref(*new ProcessingInstruction(*document, processing_instruction->data(), processing_instruction->target()));
|
||||
copy = move(processing_instruction_copy);
|
||||
} else if (is<DocumentFragment>(this)) {
|
||||
auto document_fragment_copy = adopt_ref(*new DocumentFragment(*document));
|
||||
copy = move(document_fragment_copy);
|
||||
} else {
|
||||
dbgln("clone_node() not implemented for NodeType {}", (u16)m_type);
|
||||
TODO();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue