use super::prelude::*;
#[syntax(" auto | none | scrollbar ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "auto",
inherits,
applies_to = Elements,
animation_type = Discrete,
property_group = Scrollbars,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsOverflowStyleStyleValue {}
#[syntax(
" auto | none | [ [ pan-x | pan-left | pan-right ] || [ pan-y | pan-up | pan-down ] || pinch-zoom ] | manipulation "
)]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "auto",
applies_to = Elements,
animation_type = Discrete,
property_group = PointerAnimations,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsTouchActionStyleValue {}
#[syntax(" auto | text | none | all ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "auto",
applies_to = Elements,
animation_type = Discrete,
property_group = Ui,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsUserSelectStyleValue {}
#[syntax(" auto | none | <percentage [0,∞]> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "auto",
inherits,
applies_to = Elements,
animation_type = ByComputedValue,
percentages = Unknown,
property_group = SizeAdjust,
computed_value_type = Unknown,
canonical_order = "N/A",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsTextSizeAdjustStyleValue;
#[syntax(" none | [ <'flex-grow'> <'flex-shrink'>? || <'flex-basis'> ] ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "0 1 auto",
applies_to = Elements,
animation_type = Unknown,
property_group = Flexbox,
computed_value_type = Unknown,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsFlexStyleValue;
#[syntax(" <integer> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "0",
applies_to = Elements,
animation_type = ByComputedValue,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsFlexOrderStyleValue;
#[syntax(" row | row-reverse | column | column-reverse ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "row",
applies_to = Elements,
animation_type = Discrete,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexDirectionStyleValue {}
#[syntax(" nowrap | wrap | wrap-reverse ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "nowrap",
applies_to = Elements,
animation_type = Discrete,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexWrapStyleValue {}
#[syntax(" <'flex-direction'> || <'flex-wrap'> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "see individual properties",
applies_to = Elements,
property_group = Flexbox,
computed_value_type = Unknown,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsFlexFlowStyleValue;
#[syntax(" <number [0,∞]> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "0",
applies_to = Elements,
animation_type = ByComputedValue,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsFlexPositiveStyleValue;
#[syntax(" <number [0,∞]> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "1",
applies_to = Elements,
animation_type = ByComputedValue,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsFlexNegativeStyleValue;
#[syntax(" content | <'width'> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "auto",
applies_to = Elements,
animation_type = ByComputedValue,
property_group = Flexbox,
computed_value_type = Unknown,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexPreferredSizeStyleValue {}
#[syntax(" start | end | center | justify | distribute ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "start",
applies_to = Elements,
animation_type = Discrete,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexPackStyleValue {}
#[syntax(" start | end | center | stretch | baseline ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "stretch",
applies_to = Elements,
animation_type = Discrete,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexAlignStyleValue {}
#[syntax(" auto | start | end | center | stretch | baseline ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "auto",
applies_to = Elements,
animation_type = Discrete,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexItemAlignStyleValue {}
#[syntax(" start | end | center | justify | distribute | stretch ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "stretch",
applies_to = Elements,
animation_type = Discrete,
property_group = Flexbox,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum MsFlexLinePackStyleValue {}
#[syntax(" none | <transform-list> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "none",
applies_to = Elements,
animation_type = Unknown,
property_group = Transforms,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsTransformStyleValue<'a>;
#[syntax(" none | <filter-value-list> ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "none",
applies_to = Elements,
animation_type = Unknown,
property_group = FilterEffects,
computed_value_type = AsSpecified,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsFilterStyleValue<'a>;
#[syntax(" <single-transition># ")]
#[derive(
Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
initial = "see individual properties",
applies_to = Elements,
property_group = Transitions,
computed_value_type = Unknown,
canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct MsTransitionStyleValue<'a>;
#[cfg(test)]
mod tests {
use super::*;
use crate::CssAtomSet;
use css_parse::{assert_parse, assert_parse_error};
#[test]
fn test_ms_overflow_style_parses() {
assert_parse!(CssAtomSet::ATOMS, MsOverflowStyleStyleValue, "auto");
assert_parse!(CssAtomSet::ATOMS, MsOverflowStyleStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsOverflowStyleStyleValue, "scrollbar");
}
#[test]
fn test_ms_overflow_style_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsOverflowStyleStyleValue, "invalid");
}
#[test]
fn test_ms_touch_action_parses() {
assert_parse!(CssAtomSet::ATOMS, MsTouchActionStyleValue, "auto");
assert_parse!(CssAtomSet::ATOMS, MsTouchActionStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsTouchActionStyleValue, "manipulation");
assert_parse!(CssAtomSet::ATOMS, MsTouchActionStyleValue, "pan-y");
assert_parse!(CssAtomSet::ATOMS, MsTouchActionStyleValue, "pan-x pan-y");
}
#[test]
fn test_ms_touch_action_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsTouchActionStyleValue, "invalid");
}
#[test]
fn test_ms_user_select_parses() {
assert_parse!(CssAtomSet::ATOMS, MsUserSelectStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsUserSelectStyleValue, "auto");
assert_parse!(CssAtomSet::ATOMS, MsUserSelectStyleValue, "all");
}
#[test]
fn test_ms_user_select_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsUserSelectStyleValue, "invalid");
}
#[test]
fn test_ms_text_size_adjust_parses() {
assert_parse!(CssAtomSet::ATOMS, MsTextSizeAdjustStyleValue, "auto");
assert_parse!(CssAtomSet::ATOMS, MsTextSizeAdjustStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsTextSizeAdjustStyleValue, "100%");
}
#[test]
fn test_ms_text_size_adjust_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsTextSizeAdjustStyleValue, "invalid");
}
#[test]
fn test_ms_flex_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsFlexStyleValue, "1");
assert_parse!(CssAtomSet::ATOMS, MsFlexStyleValue, "0 0 auto");
assert_parse!(CssAtomSet::ATOMS, MsFlexStyleValue, "0 0 100%");
}
#[test]
fn test_ms_flex_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexStyleValue, "invalid");
}
#[test]
fn test_ms_flex_order_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexOrderStyleValue, "0");
assert_parse!(CssAtomSet::ATOMS, MsFlexOrderStyleValue, "-1");
assert_parse!(CssAtomSet::ATOMS, MsFlexOrderStyleValue, "8");
}
#[test]
fn test_ms_flex_direction_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexDirectionStyleValue, "row");
assert_parse!(CssAtomSet::ATOMS, MsFlexDirectionStyleValue, "column");
assert_parse!(CssAtomSet::ATOMS, MsFlexDirectionStyleValue, "row-reverse");
assert_parse!(CssAtomSet::ATOMS, MsFlexDirectionStyleValue, "column-reverse");
}
#[test]
fn test_ms_flex_direction_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexDirectionStyleValue, "invalid");
}
#[test]
fn test_ms_flex_wrap_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexWrapStyleValue, "nowrap");
assert_parse!(CssAtomSet::ATOMS, MsFlexWrapStyleValue, "wrap");
assert_parse!(CssAtomSet::ATOMS, MsFlexWrapStyleValue, "wrap-reverse");
}
#[test]
fn test_ms_flex_wrap_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexWrapStyleValue, "invalid");
}
#[test]
fn test_ms_flex_pack_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexPackStyleValue, "start");
assert_parse!(CssAtomSet::ATOMS, MsFlexPackStyleValue, "end");
assert_parse!(CssAtomSet::ATOMS, MsFlexPackStyleValue, "center");
assert_parse!(CssAtomSet::ATOMS, MsFlexPackStyleValue, "justify");
assert_parse!(CssAtomSet::ATOMS, MsFlexPackStyleValue, "distribute");
}
#[test]
fn test_ms_flex_pack_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexPackStyleValue, "invalid");
}
#[test]
fn test_ms_flex_align_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexAlignStyleValue, "start");
assert_parse!(CssAtomSet::ATOMS, MsFlexAlignStyleValue, "end");
assert_parse!(CssAtomSet::ATOMS, MsFlexAlignStyleValue, "center");
assert_parse!(CssAtomSet::ATOMS, MsFlexAlignStyleValue, "stretch");
assert_parse!(CssAtomSet::ATOMS, MsFlexAlignStyleValue, "baseline");
}
#[test]
fn test_ms_flex_align_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexAlignStyleValue, "invalid");
}
#[test]
fn test_ms_flex_item_align_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "auto");
assert_parse!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "start");
assert_parse!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "end");
assert_parse!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "center");
assert_parse!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "stretch");
assert_parse!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "baseline");
}
#[test]
fn test_ms_flex_item_align_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexItemAlignStyleValue, "invalid");
}
#[test]
fn test_ms_flex_line_pack_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "start");
assert_parse!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "end");
assert_parse!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "center");
assert_parse!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "justify");
assert_parse!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "distribute");
assert_parse!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "stretch");
}
#[test]
fn test_ms_flex_line_pack_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFlexLinePackStyleValue, "invalid");
}
#[test]
fn test_ms_transform_parses() {
assert_parse!(CssAtomSet::ATOMS, MsTransformStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsTransformStyleValue, "rotate(45deg)");
assert_parse!(CssAtomSet::ATOMS, MsTransformStyleValue, "scale(-1, 1)");
}
#[test]
fn test_ms_transform_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsTransformStyleValue, "invalid");
}
#[test]
fn test_ms_filter_parses() {
assert_parse!(CssAtomSet::ATOMS, MsFilterStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsFilterStyleValue, "blur(4px)");
}
#[test]
fn test_ms_filter_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsFilterStyleValue, "invalid");
}
#[test]
fn test_ms_transition_parses() {
assert_parse!(CssAtomSet::ATOMS, MsTransitionStyleValue, "none");
assert_parse!(CssAtomSet::ATOMS, MsTransitionStyleValue, "all 0.3s ease");
}
#[test]
fn test_ms_transition_errors() {
assert_parse_error!(CssAtomSet::ATOMS, MsTransitionStyleValue, "invalid!!!!");
}
}