mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 02:05:07 +02:00
LibWeb: Implement cloning steps for HTMLTextAreaElement
This commit is contained in:
committed by
Andreas Kling
parent
71cfa705d1
commit
d3e076f963
Notes:
github-actions[bot]
2024-08-25 10:54:22 +00:00
Author: https://github.com/tcl3 Commit: https://github.com/LadybirdBrowser/ladybird/commit/d3e076f9637 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1185
@@ -0,0 +1,20 @@
|
||||
<!DOCTYPE html>
|
||||
<script src="../include.js"></script>
|
||||
<form>
|
||||
<textarea id="testTextArea" value="FAIL"></textarea>
|
||||
</form>
|
||||
<script>
|
||||
test(() => {
|
||||
const form = document.forms[0];
|
||||
const textarea = form.querySelector("textarea");
|
||||
textarea.value = "PASS";
|
||||
|
||||
const clone = form.cloneNode(true);
|
||||
document.body.appendChild(clone);
|
||||
|
||||
println(`Cloned textarea value: ${clone.querySelector("textarea").value}`);
|
||||
|
||||
form.remove();
|
||||
clone.remove();
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user