mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 20:29:18 +00:00
LibWeb/SVG: Implement default_tab_index_value for a element
Another FIXME bites the dust :^)
This commit is contained in:
parent
9c13644cde
commit
9c4e80a3ec
Notes:
github-actions[bot]
2024-08-14 19:40:26 +00:00
Author: https://github.com/jamierocks
Commit: 9c4e80a3ec
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1077
Reviewed-by: https://github.com/AtkinsSJ ✅
Reviewed-by: https://github.com/tcl3 ✅
5 changed files with 61 additions and 1 deletions
41
Tests/LibWeb/Text/input/HTML/tabIndex-attribute.html
Normal file
41
Tests/LibWeb/Text/input/HTML/tabIndex-attribute.html
Normal file
|
@ -0,0 +1,41 @@
|
|||
<!DOCTYPE html>
|
||||
<script src="../include.js"></script>
|
||||
<script>
|
||||
function tabIndexTest(tagName, element) {
|
||||
println(`${tagName}.tabIndex initial value: ${element.tabIndex}`);
|
||||
}
|
||||
|
||||
test(() => {
|
||||
const controlTagNamesToTest = [
|
||||
"p",
|
||||
"h1",
|
||||
];
|
||||
const tagNamesToTest = [
|
||||
"a",
|
||||
"area",
|
||||
"button",
|
||||
"frame",
|
||||
"iframe",
|
||||
"input",
|
||||
"object",
|
||||
"select",
|
||||
"textarea",
|
||||
];
|
||||
const svgTagNamesToTest = [
|
||||
"a",
|
||||
];
|
||||
|
||||
for (const tagName of controlTagNamesToTest) {
|
||||
const element = document.createElement(tagName);
|
||||
tabIndexTest(tagName, element);
|
||||
}
|
||||
for (const tagName of tagNamesToTest) {
|
||||
const element = document.createElement(tagName);
|
||||
tabIndexTest(tagName, element);
|
||||
}
|
||||
for (const tagName of svgTagNamesToTest) {
|
||||
const element = document.createElementNS("http://www.w3.org/2000/svg", tagName);
|
||||
tabIndexTest(`svg.${tagName}`, element);
|
||||
}
|
||||
});
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue