Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(46)

Unified Diff: third_party/WebKit/LayoutTests/fast/html/tabindex-nonfocusable.html

Issue 2298133004: Changed the default value of tabIndex of <fieldset> and <output> to be -1 as they are non-focusable… (Closed)
Patch Set: Code review update Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLFieldSetElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/fast/html/tabindex-nonfocusable.html
diff --git a/third_party/WebKit/LayoutTests/fast/html/tabindex-nonfocusable.html b/third_party/WebKit/LayoutTests/fast/html/tabindex-nonfocusable.html
new file mode 100644
index 0000000000000000000000000000000000000000..2d7215ad633bc6cca8250e2749ba9b5da45fe014
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/html/tabindex-nonfocusable.html
@@ -0,0 +1,42 @@
+<!DOCTYPE html>
+<script src="../../resources/testharness.js"></script>
+<script src="../../resources/testharnessreport.js"></script>
+<body>
+ <a id="a"></a>
+ <input type="hidden" id="input-hidden"></input>
+ <input disabled id="input-disabled"></input>
+ <select disabled id="select-disabled"></select>
+ <textarea disabled id="textarea-disabled"></textarea>
+ <button disabled id="button-disabled"></button>
+ <fieldset id="fieldset"><output id="output"></output></fieldset>
+ <script>
+ var idTagList = [
+ {id:"a", tag:"HYPERLINK <a> without href"},
+ {id:"input-hidden", tag:"INPUT[type=hidden]"},
+ {id:"input-disabled", tag:"INPUT[disabled]"},
+ {id:"select-disabled", tag:"SELECT[disabled]"},
+ {id:"textarea-disabled", tag:"TEXTAREA[disabled]"},
+ {id:"button-disabled", tag:"BUTTON[disabled]"},
+ ];
+
+ for (var idTag of idTagList) {
+ var id = idTag.id;
+ var tag = idTag.tag;
+ test(function() {
+ var elm = document.getElementById(id);
+ assert_equals(elm.tabIndex, 0);
+ }, 'Default tabIndex value of tag' + tag + ' should be 0');
+ }
+
+ test(function() {
+ var elm = document.getElementById("output");
+ assert_equals(elm.tabIndex, -1);
+ }, 'Default tabIndex value of tag OUTPUT should be -1');
+
+ test(function() {
+ var elm = document.getElementById("fieldset");
+ assert_equals(elm.tabIndex, -1);
+ }, 'Default tabIndex value of tag FIELDSET should be -1');
+ </script>
+</body>
+
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLFieldSetElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698