mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Implement compact/type attributes for HTMLUListElement (#33303)
Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
This commit is contained in:
parent
93cd8d1ba4
commit
e43e477842
4 changed files with 20 additions and 238 deletions
|
@ -6,7 +6,9 @@ use dom_struct::dom_struct;
|
|||
use html5ever::{LocalName, Prefix};
|
||||
use js::rust::HandleObject;
|
||||
|
||||
use crate::dom::bindings::codegen::Bindings::HTMLUListElementBinding::HTMLUListElementMethods;
|
||||
use crate::dom::bindings::root::DomRoot;
|
||||
use crate::dom::bindings::str::DOMString;
|
||||
use crate::dom::document::Document;
|
||||
use crate::dom::htmlelement::HTMLElement;
|
||||
use crate::dom::node::Node;
|
||||
|
@ -43,3 +45,17 @@ impl HTMLUListElement {
|
|||
)
|
||||
}
|
||||
}
|
||||
|
||||
impl HTMLUListElementMethods for HTMLUListElement {
|
||||
// https://html.spec.whatwg.org/multipage/#dom-ul-compact
|
||||
make_bool_getter!(Compact, "compact");
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-ul-compact
|
||||
make_bool_setter!(SetCompact, "compact");
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-ul-type
|
||||
make_getter!(Type, "type");
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-ul-type
|
||||
make_setter!(SetType, "type");
|
||||
}
|
||||
|
|
|
@ -12,8 +12,8 @@ interface HTMLUListElement : HTMLElement {
|
|||
|
||||
// https://html.spec.whatwg.org/multipage/#HTMLUListElement-partial
|
||||
partial interface HTMLUListElement {
|
||||
// [CEReactions]
|
||||
// attribute boolean compact;
|
||||
// [CEReactions]
|
||||
// attribute DOMString type;
|
||||
[CEReactions]
|
||||
attribute boolean compact;
|
||||
[CEReactions]
|
||||
attribute DOMString type;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue