pub enum ContentValue {
Normal,
None,
Items(Box<[ContentItem]>),
}Expand description
CSS content property value for ::before / ::after pseudo-elements.
Variants§
Normal
content: normal. For ::before / ::after this behaves as None.
None
content: none. Suppresses pseudo-element box generation.
Items(Box<[ContentItem]>)
A non-empty list of generated content items.
Trait Implementations§
Source§impl Clone for ContentValue
impl Clone for ContentValue
Source§fn clone(&self) -> ContentValue
fn clone(&self) -> ContentValue
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ContentValue
impl Debug for ContentValue
Source§impl Default for ContentValue
impl Default for ContentValue
Source§fn default() -> ContentValue
fn default() -> ContentValue
Returns the “default value” for a type. Read more
Source§impl<'i> FromCss<'i> for ContentValue
impl<'i> FromCss<'i> for ContentValue
Source§const VALID_TOKENS: &'static [CssToken]
const VALID_TOKENS: &'static [CssToken]
Returns the list of valid CSS tokens for this type.
Source§fn from_css(input: &mut Parser<'i, '_>) -> ParseResult<'i, Self>
fn from_css(input: &mut Parser<'i, '_>) -> ParseResult<'i, Self>
Parses the type from a
Parser instance.Source§fn from_str(source: &'i str) -> ParseResult<'i, Self>where
Self: Sized,
fn from_str(source: &'i str) -> ParseResult<'i, Self>where
Self: Sized,
Helper function to parse the type from a string.
Source§const EXPECT_MESSAGE: CssExpectedMessage = CssExpectedMessage::OneValue
const EXPECT_MESSAGE: CssExpectedMessage = CssExpectedMessage::OneValue
Message template used when building parse errors for this type.
Source§impl PartialEq for ContentValue
impl PartialEq for ContentValue
Source§fn eq(&self, other: &ContentValue) -> bool
fn eq(&self, other: &ContentValue) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ContentValue
Auto Trait Implementations§
impl Freeze for ContentValue
impl RefUnwindSafe for ContentValue
impl Send for ContentValue
impl Sync for ContentValue
impl Unpin for ContentValue
impl UnsafeUnpin for ContentValue
impl UnwindSafe for ContentValue
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