pub struct VariantParser { /* private fields */ }Expand description
Variant parser for handling CSS variants
Implementations§
Source§impl VariantParser
impl VariantParser
Sourcepub fn parse_variants(&self, class: &str) -> (Vec<String>, String)
pub fn parse_variants(&self, class: &str) -> (Vec<String>, String)
Parse variants from a class string
Sourcepub fn get_variant_selector(&self, variant: &str) -> String
pub fn get_variant_selector(&self, variant: &str) -> String
Get the CSS selector for a variant
Sourcepub fn get_device_media_query(&self, variant: &str) -> Option<String>
pub fn get_device_media_query(&self, variant: &str) -> Option<String>
Get the media query for device variants
Sourcepub fn get_responsive_media_query(&self, variant: &str) -> Option<String>
pub fn get_responsive_media_query(&self, variant: &str) -> Option<String>
Get the media query for a responsive variant
Sourcepub fn is_supported_variant(&self, variant: &str) -> bool
pub fn is_supported_variant(&self, variant: &str) -> bool
Check if a variant is supported
Sourcepub fn get_supported_variants(&self) -> &[String]
pub fn get_supported_variants(&self) -> &[String]
Get all supported variants
Sourcepub fn get_supported_breakpoints(&self) -> &[Breakpoint]
pub fn get_supported_breakpoints(&self) -> &[Breakpoint]
Get all supported breakpoints
Trait Implementations§
Source§impl Clone for VariantParser
impl Clone for VariantParser
Source§fn clone(&self) -> VariantParser
fn clone(&self) -> VariantParser
Returns a duplicate of the value. Read more
1.0.0 · 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 VariantParser
impl Debug for VariantParser
Auto Trait Implementations§
impl Freeze for VariantParser
impl RefUnwindSafe for VariantParser
impl Send for VariantParser
impl Sync for VariantParser
impl Unpin for VariantParser
impl UnwindSafe for VariantParser
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