diff options
Diffstat (limited to 'components/style/dom.rs')
-rw-r--r-- | components/style/dom.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/components/style/dom.rs b/components/style/dom.rs index ea438b66dd9..85f4f49c4b7 100644 --- a/components/style/dom.rs +++ b/components/style/dom.rs @@ -416,6 +416,20 @@ pub trait TElement F: FnMut(Self), {} + /// Return whether this element is an element in the HTML namespace. + fn is_html_element(&self) -> bool; + + /// Returns whether this element is a <html:slot> element. + fn is_html_slot_element(&self) -> bool { + self.get_local_name() == &*local_name!("slot") && + self.is_html_element() + } + + /// Return the list of slotted nodes of this node. + fn slotted_nodes(&self) -> &[Self::ConcreteNode] { + &[] + } + /// For a given NAC element, return the closest non-NAC ancestor, which is /// guaranteed to exist. fn closest_non_native_anonymous_ancestor(&self) -> Option<Self> { |