pub enum ArbitraryDisambiguateSeparation {
None,
Comma,
Space,
Both,
}Expand description
When defining a [PluginArbitraryMatcher] for an Arbitrary kind, defines how values
are separated.
A lot of CSS properties allow specifying several values of a single type separated by a
character, e.g margin allows <length>
or <percentage>
values separated by spaces, to define a specific margin for each side of the CSS layout box.
This enumeration helps matching these values when using a [PluginArbitraryMatcher], e.g for
the margin example, you would use
ⓘ
Plugin::new(...)
.matchers(&[Length, Percentage], PluginArbitraryMatcherSeparation::Space)Variants§
None
No separation, a single value is matched.
Comma
Separated by commas (,).
Example: 33px, 42%, 6em.
Space
Separated by spaces ( ).
Example: left top.
Both
Separated by commas (,) then spaces ( ).
Example: left, 12% 33px, right center.
Trait Implementations§
Source§impl Clone for ArbitraryDisambiguateSeparation
impl Clone for ArbitraryDisambiguateSeparation
Source§fn clone(&self) -> ArbitraryDisambiguateSeparation
fn clone(&self) -> ArbitraryDisambiguateSeparation
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 moreimpl Copy for ArbitraryDisambiguateSeparation
Source§impl<'de> Deserialize<'de> for ArbitraryDisambiguateSeparation
impl<'de> Deserialize<'de> for ArbitraryDisambiguateSeparation
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ArbitraryDisambiguateSeparation
impl StructuralPartialEq for ArbitraryDisambiguateSeparation
Auto Trait Implementations§
impl Freeze for ArbitraryDisambiguateSeparation
impl RefUnwindSafe for ArbitraryDisambiguateSeparation
impl Send for ArbitraryDisambiguateSeparation
impl Sync for ArbitraryDisambiguateSeparation
impl Unpin for ArbitraryDisambiguateSeparation
impl UnsafeUnpin for ArbitraryDisambiguateSeparation
impl UnwindSafe for ArbitraryDisambiguateSeparation
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