diff --git a/css/css-view-transitions/dialog-in-top-layer-during-transition-new.html b/css/css-view-transitions/dialog-in-top-layer-during-transition-new.html
index e84167a24892cba..0473209fa9df786 100644
--- a/css/css-view-transitions/dialog-in-top-layer-during-transition-new.html
+++ b/css/css-view-transitions/dialog-in-top-layer-during-transition-new.html
@@ -18,6 +18,8 @@
view-transition-name: dialog;
contain: layout;
+
+ outline: none;
}
#target::backdrop {
diff --git a/css/css-view-transitions/dialog-in-top-layer-during-transition-old.html b/css/css-view-transitions/dialog-in-top-layer-during-transition-old.html
index 672295cd3bd7251..3634f65d8c99ae8 100644
--- a/css/css-view-transitions/dialog-in-top-layer-during-transition-old.html
+++ b/css/css-view-transitions/dialog-in-top-layer-during-transition-old.html
@@ -18,6 +18,8 @@
view-transition-name: dialog;
contain: layout;
+
+ outline: none;
}
#target::backdrop {
diff --git a/html/semantics/interactive-elements/the-dialog-element/backdrop-stacking-order.html b/html/semantics/interactive-elements/the-dialog-element/backdrop-stacking-order.html
index 57cc63aab4802e2..897f54a53fbaeaa 100644
--- a/html/semantics/interactive-elements/the-dialog-element/backdrop-stacking-order.html
+++ b/html/semantics/interactive-elements/the-dialog-element/backdrop-stacking-order.html
@@ -6,6 +6,7 @@
padding: 0px;
border: none;
margin: 0px;
+ outline: none;
}
#bottom::backdrop {
diff --git a/html/semantics/interactive-elements/the-dialog-element/child-sequential-focus.html b/html/semantics/interactive-elements/the-dialog-element/child-sequential-focus.html
new file mode 100644
index 000000000000000..b4b84c272d798e3
--- /dev/null
+++ b/html/semantics/interactive-elements/the-dialog-element/child-sequential-focus.html
@@ -0,0 +1,78 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/html/semantics/interactive-elements/the-dialog-element/dialog-focus-shadow.html b/html/semantics/interactive-elements/the-dialog-element/dialog-focus-shadow.html
index e9ea15516e27119..7e5768542559a89 100644
--- a/html/semantics/interactive-elements/the-dialog-element/dialog-focus-shadow.html
+++ b/html/semantics/interactive-elements/the-dialog-element/dialog-focus-shadow.html
@@ -9,21 +9,21 @@
We focus this one between each test, to ensure that for non-modal dialogs,
if there is no focus delegate, it stays focused (instead of causing focus to reset to the body).
-->
-Focus between tests
+Focus between tests
@@ -31,25 +31,25 @@
@@ -57,26 +57,26 @@
@@ -84,34 +84,34 @@
@@ -119,25 +119,25 @@
@@ -145,91 +145,91 @@
diff --git a/html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html b/html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html
index c511631f9fbb71d..5edff18614225d0 100644
--- a/html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html
+++ b/html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html
@@ -116,7 +116,7 @@
d6.showModal();
this.add_cleanup(function() { d6.close(); });
assert_true(d6.open);
- assert_equals(document.activeElement, document.body);
+ assert_equals(document.activeElement, d6);
}, "opening dialog without focusable children");
test(function(){
diff --git a/html/semantics/interactive-elements/the-dialog-element/dont-share-style-to-top-layer-ref.html b/html/semantics/interactive-elements/the-dialog-element/dont-share-style-to-top-layer-ref.html
index 535ac935607094e..7e6112b3cee0919 100644
--- a/html/semantics/interactive-elements/the-dialog-element/dont-share-style-to-top-layer-ref.html
+++ b/html/semantics/interactive-elements/the-dialog-element/dont-share-style-to-top-layer-ref.html
@@ -1,5 +1,8 @@
Test that a non-top layer element doesn't share style with a top layer
element. The test passes if you see two boxes.
diff --git a/html/semantics/interactive-elements/the-dialog-element/element-removed-from-top-layer-has-original-position.html b/html/semantics/interactive-elements/the-dialog-element/element-removed-from-top-layer-has-original-position.html
index d78051a9b3eec7a..0dead331636355d 100644
--- a/html/semantics/interactive-elements/the-dialog-element/element-removed-from-top-layer-has-original-position.html
+++ b/html/semantics/interactive-elements/the-dialog-element/element-removed-from-top-layer-has-original-position.html
@@ -14,6 +14,7 @@
border: none;
padding: 0;
margin: 0;
+ outline: none;
}
diff --git a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-contain-ancestor.html b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-contain-ancestor.html
index 98835cb795fb0e4..5ee64fc1d9e31d7 100644
--- a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-contain-ancestor.html
+++ b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-contain-ancestor.html
@@ -8,6 +8,9 @@
::backdrop {
display: none;
}
+#dialog {
+ outline: none;
+}
diff --git a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-fo-ancestor.html b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-fo-ancestor.html
index fe625f1c9bfb496..2bc294be2fae16c 100644
--- a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-fo-ancestor.html
+++ b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-fo-ancestor.html
@@ -8,6 +8,9 @@
::backdrop {
display: none;
}
+#dialog {
+ outline: none;
+}
diff --git a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-transformed-ancestor.html b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-transformed-ancestor.html
index 58627443dae1941..527d508252c15d0 100644
--- a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-transformed-ancestor.html
+++ b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-transformed-ancestor.html
@@ -8,6 +8,9 @@
::backdrop {
display: none;
}
+#dialog {
+ outline: none;
+}
diff --git a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-will-change-ancestor.html b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-will-change-ancestor.html
index 14f4391e6bfbc2a..e9db7321cd703d2 100644
--- a/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-will-change-ancestor.html
+++ b/html/semantics/interactive-elements/the-dialog-element/fixed-position-child-with-will-change-ancestor.html
@@ -8,6 +8,9 @@
::backdrop {
display: none;
}
+#dialog {
+ outline: none;
+}
diff --git a/html/semantics/interactive-elements/the-dialog-element/inert-label-focus.html b/html/semantics/interactive-elements/the-dialog-element/inert-label-focus.html
index 05f4069d78f57e5..61e3ddeaf23e691 100644
--- a/html/semantics/interactive-elements/the-dialog-element/inert-label-focus.html
+++ b/html/semantics/interactive-elements/the-dialog-element/inert-label-focus.html
@@ -39,12 +39,15 @@
document.querySelector('#text').focus();
label = document.querySelector('label');
+ submit = document.querySelector('#submit');
label.focus();
- assert_equals(document.activeElement, document.querySelector('#submit'),
+ assert_equals(document.activeElement, submit,
'label.focus() should send focus to the target.');
await clickOn(label);
- assert_equals(document.activeElement, document.body,
- 'Clicking the label should be the same as clicking the document body.');
+ assert_not_equals(document.activeElement, label,
+ 'Clicking the label should not focus the label.');
+ assert_not_equals(document.activeElement, submit,
+ 'Clicking the label should not focus the submit input.');
}, 'Tests focusing of an inert label for a non-inert target.');
diff --git a/html/semantics/interactive-elements/the-dialog-element/inert-node-is-unfocusable.html b/html/semantics/interactive-elements/the-dialog-element/inert-node-is-unfocusable.html
index 56f31f35924974f..74379f50e22c70a 100644
--- a/html/semantics/interactive-elements/the-dialog-element/inert-node-is-unfocusable.html
+++ b/html/semantics/interactive-elements/the-dialog-element/inert-node-is-unfocusable.html
@@ -7,6 +7,11 @@
+
diff --git a/html/semantics/interactive-elements/the-dialog-element/modal-dialog-backdrop.html b/html/semantics/interactive-elements/the-dialog-element/modal-dialog-backdrop.html
index a18af0d30ea45ac..55d7132f8cefa6b 100644
--- a/html/semantics/interactive-elements/the-dialog-element/modal-dialog-backdrop.html
+++ b/html/semantics/interactive-elements/the-dialog-element/modal-dialog-backdrop.html
@@ -7,6 +7,7 @@
height: 100px;
width: 100px;
background: green;
+ outline: none;
}
diff --git a/html/semantics/interactive-elements/the-dialog-element/modal-dialog-generated-content.html b/html/semantics/interactive-elements/the-dialog-element/modal-dialog-generated-content.html
index 86f43e52c2eb095..96b97f8ec3c4905 100644
--- a/html/semantics/interactive-elements/the-dialog-element/modal-dialog-generated-content.html
+++ b/html/semantics/interactive-elements/the-dialog-element/modal-dialog-generated-content.html
@@ -11,6 +11,7 @@
height: 100px;
width: 100px;
background: green;
+ outline: none;
}
dialog::before {
diff --git a/html/semantics/interactive-elements/the-dialog-element/show-modal-focusing-steps.html b/html/semantics/interactive-elements/the-dialog-element/show-modal-focusing-steps.html
index 164b41459d17605..6a2ad8c4a0a4eb6 100644
--- a/html/semantics/interactive-elements/the-dialog-element/show-modal-focusing-steps.html
+++ b/html/semantics/interactive-elements/the-dialog-element/show-modal-focusing-steps.html
@@ -10,10 +10,10 @@
outerButton = document.getElementById('outer-button');
assert_equals(document.activeElement, outerButton);
- // Test that focus goes to body if the dialog has no focusable elements, including itself
+ // Test that focus goes to the dialog if the dialog has no focusable elements
var outerDialog = document.getElementById('outer-dialog');
outerDialog.showModal();
- assert_equals(document.activeElement, document.body);
+ assert_equals(document.activeElement, outerDialog);
// Test that an autofocus element in the dialog gets focus.
var dialog = document.getElementById('dialog');
diff --git a/html/semantics/interactive-elements/the-dialog-element/top-layer-containing-block.html b/html/semantics/interactive-elements/the-dialog-element/top-layer-containing-block.html
index 10f6c69fbe188a5..0886c2cd2c2a0cf 100644
--- a/html/semantics/interactive-elements/the-dialog-element/top-layer-containing-block.html
+++ b/html/semantics/interactive-elements/the-dialog-element/top-layer-containing-block.html
@@ -14,7 +14,7 @@
This tests that a modal dialog's containing block is in the initial containing block and that it is unaffected by
ancestor elements with overflow or opacity.