Type Alias AnchorFunction

Source
pub type AnchorFunction = GenericAnchorFunction<Percentage, Inset>;
Expand description

A specified value for anchor() function.

Aliased Type§

#[repr(C)]
pub struct AnchorFunction { pub target_element: DashedIdent, pub side: GenericAnchorSide<Percentage>, pub fallback: Optional<GenericInset<Percentage, LengthPercentage>>, }

Fields§

§target_element: DashedIdent

Anchor name of the element to anchor to. If omitted, selects the implicit anchor element.

§side: GenericAnchorSide<Percentage>

Where relative to the target anchor element to position the anchored element to.

§fallback: Optional<GenericInset<Percentage, LengthPercentage>>

Value to use in case the anchor function is invalid.

Trait Implementations§

Source§

impl Parse for AnchorFunction

Source§

fn parse<'i, 't>( context: &ParserContext<'_>, input: &mut Parser<'i, 't>, ) -> Result<Self, ParseError<'i>>

Parse a value of this type. Read more