16 /* This shouldn't be matched, dialog is not the parent of ::backdrop.
17 * It is given high specificity so we actually test something.
19 #dialog-parent
> #dialog
> ::backdrop,
20 #dialog-parent
> #dialog ::backdrop {
24 #dialog-parent
> ::backdrop {
30 #backdrop-ancestor ::backdrop {
38 Test ::backdrop used in descendant selectors. The test passes if there are two green boxes and no red.
40 <div id=
"dialog-parent">
41 <dialog id=
"dialog"></dialog>
43 <div id=
"backdrop-ancestor">
44 <p><span><dialog></dialog></span></p>
47 var dialogs
= document
.querySelectorAll('dialog');
48 for (var i
= 0; i
< dialogs
.length
; ++i
)
49 dialogs
[i
].showModal();