Make Element::attach_shadow() and ShadowRoot closer to spec (#36024)

Signed-off-by: batu_hoang <longvatrong111@gmail.com>
This commit is contained in:
batu_hoang 2025-03-20 01:58:16 +08:00 committed by GitHub
parent 11d47558b3
commit db74179dc8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 117 additions and 158 deletions

View file

@ -90,10 +90,10 @@ interface Element : Node {
dictionary ShadowRootInit {
required ShadowRootMode mode;
// boolean delegatesFocus = false;
boolean delegatesFocus = false;
SlotAssignmentMode slotAssignment = "named";
boolean clonable = false;
// boolean serializable = false;
boolean serializable = false;
};
// http://dev.w3.org/csswg/cssom-view/#extensions-to-the-element-interface

View file

@ -9,10 +9,10 @@
[Exposed=Window]
interface ShadowRoot : DocumentFragment {
readonly attribute ShadowRootMode mode;
// readonly attribute boolean delegatesFocus;
readonly attribute boolean delegatesFocus;
readonly attribute SlotAssignmentMode slotAssignment;
readonly attribute boolean clonable;
// readonly attribute boolean serializable;
readonly attribute boolean serializable;
readonly attribute Element host;
attribute EventHandler onslotchange;
};