pub struct CompoundSelector {
pub parts: Vec<SelectorPart>,
}Expand description
A compound CSS selector — a chain of SelectorParts connected by
combinators (whitespace for descendant, > for child). The rightmost part
matches the target element; preceding parts must match ancestors according
to the combinator stored on each part.
Examples: .header h1 → [SelectorPart(class="header", None), SelectorPart(tag="h1", Descendant)],
div > .card → [SelectorPart(tag="div", None), SelectorPart(class="card", Child)]
Fields§
§parts: Vec<SelectorPart>Trait Implementations§
Source§impl Clone for CompoundSelector
impl Clone for CompoundSelector
Source§impl Debug for CompoundSelector
impl Debug for CompoundSelector
Source§impl PartialEq for CompoundSelector
impl PartialEq for CompoundSelector
impl StructuralPartialEq for CompoundSelector
Auto Trait Implementations§
impl Freeze for CompoundSelector
impl RefUnwindSafe for CompoundSelector
impl Send for CompoundSelector
impl Sync for CompoundSelector
impl Unpin for CompoundSelector
impl UnsafeUnpin for CompoundSelector
impl UnwindSafe for CompoundSelector
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more