mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 01:35:08 +02:00
LibWeb: Implement Element.getAttributeNS
This commit is contained in:
committed by
Andreas Kling
parent
8cf783b260
commit
785fa60cca
Notes:
sideshowbarker
2024-07-17 03:14:39 +09:00
Author: https://github.com/shannonbooth Commit: https://github.com/SerenityOS/serenity/commit/785fa60cca Pull-request: https://github.com/SerenityOS/serenity/pull/22730
16
Tests/LibWeb/Text/input/DOM/Element-getAttributeNS.html
Normal file
16
Tests/LibWeb/Text/input/DOM/Element-getAttributeNS.html
Normal file
@@ -0,0 +1,16 @@
|
||||
<script src="../include.js"></script>
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<script id="with-xlink-href" xlink:href="test"></script>
|
||||
<script id="no-xlink-href" href="test"></script>
|
||||
</svg>
|
||||
<script id="svg-script-element">
|
||||
test(() => {
|
||||
const xlinkNS = document.getElementById("with-xlink-href");
|
||||
println(`xlink:ref getAttribute = '${xlinkNS.getAttribute("href")}'`);
|
||||
println(`xlink:ref getAttributeNS = '${xlinkNS.getAttributeNS("http://www.w3.org/1999/xlink", "href")}'`);
|
||||
|
||||
const noNS = document.getElementById("no-xlink-href");
|
||||
println(`href getAttribute = '${noNS.getAttribute("href")}'`);
|
||||
println(`href getAttributeNS = '${noNS.getAttributeNS("http://www.w3.org/1999/xlink", "href")}'`);
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user