#[non_exhaustive]pub enum Flex {
Auto,
Content,
FitContent,
MaxContent,
MinContent,
None,
Length(Length),
Percentage(Percentage),
Number(f64),
Raw(Raw),
}Expand description
A value of flex.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Auto
auto.
Content
content.
FitContent
fit-content.
MaxContent
max-content.
MinContent
min-content.
None
none.
Length(Length)
A length.
Percentage(Percentage)
A percentage.
Number(f64)
A number.
Raw(Raw)
Any other value, passed through unchecked.
Trait Implementations§
Source§impl From<Percentage> for Flex
impl From<Percentage> for Flex
Source§fn from(v: Percentage) -> Self
fn from(v: Percentage) -> Self
Converts to this type from the input type.
impl StructuralPartialEq for Flex
Auto Trait Implementations§
impl Freeze for Flex
impl RefUnwindSafe for Flex
impl Send for Flex
impl Sync for Flex
impl Unpin for Flex
impl UnsafeUnpin for Flex
impl UnwindSafe for Flex
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