css_ast 0.0.25

CSS Abstract Syntax Trees with visitable nodes and style value types.
Documentation
// AUTO-GENERATED from w3c/csswg-drafts
// Commit: https://github.com/w3c/csswg-drafts/commit/4a2d33ef63e58de3f090c0efc69a038c5c4c1527
// Do not edit this file directly.
#![allow(warnings)]
//! https://drafts.csswg.org/scroll-animations-1/

mod impls;
use super::prelude::*;
use impls::*;
/// Represents the style value for `animation-range` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#animation-range).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ <'animation-range-start'> <'animation-range-end'>? ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#animation-range
#[syntax(" [ <'animation-range-start'> <'animation-range-end'>? ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "see individual properties",
    inherits = Unknown,
    applies_to = Unknown,
    animation_type = Unknown,
    percentages = Unknown,
    longhands = AnimationRangeEnd|AnimationRangeStart,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.animation-range"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct AnimationRangeStyleValue<'a>;

/// Represents the style value for `animation-range-end` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#animation-range-end).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ normal | <length-percentage> | <timeline-range-name> <length-percentage>? ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#animation-range-end
#[syntax(" [ normal | <length-percentage> | <timeline-range-name> <length-percentage>? ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "normal",
    applies_to = Elements,
    percentages = Unknown,
    shorthand_group = AnimationRange,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.animation-range-end"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct AnimationRangeEndStyleValue<'a>;

/// Represents the style value for `animation-range-start` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#animation-range-start).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ normal | <length-percentage> | <timeline-range-name> <length-percentage>? ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#animation-range-start
#[syntax(" [ normal | <length-percentage> | <timeline-range-name> <length-percentage>? ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "normal",
    applies_to = Elements,
    percentages = Unknown,
    shorthand_group = AnimationRange,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.animation-range-start"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct AnimationRangeStartStyleValue<'a>;

/// Represents the style value for `scroll-timeline` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#scroll-timeline).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ <'scroll-timeline-name'> <'scroll-timeline-axis'>? ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#scroll-timeline
#[syntax(" [ <'scroll-timeline-name'> <'scroll-timeline-axis'>? ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "see individual properties",
    applies_to = Elements,
    percentages = Unknown,
    longhands = ScrollTimelineAxis|ScrollTimelineName,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.scroll-timeline"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ScrollTimelineStyleValue<'a>;

/// Represents the style value for `scroll-timeline-axis` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#scroll-timeline-axis).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ block | inline | x | y ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#scroll-timeline-axis
#[syntax(" [ block | inline | x | y ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "block",
    applies_to = Elements,
    shorthand_group = ScrollTimeline,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.scroll-timeline-axis"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ScrollTimelineAxisStyleValue<'a>;

/// Represents the style value for `scroll-timeline-name` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#scroll-timeline-name).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ none | <dashed-ident> ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#scroll-timeline-name
#[syntax(" [ none | <dashed-ident> ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "none",
    applies_to = Elements,
    shorthand_group = ScrollTimeline,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.scroll-timeline-name"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ScrollTimelineNameStyleValue<'a>;

/// Represents the style value for `timeline-scope` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#timeline-scope).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// none | all | <dashed-ident>#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#timeline-scope
#[syntax(" none | all | <dashed-ident># ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "none",
    applies_to = Elements,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.timeline-scope"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub enum TimelineScopeStyleValue<'a> {}

/// Represents the style value for `view-timeline` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#view-timeline).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ <'view-timeline-name'> [ <'view-timeline-axis'> || <'view-timeline-inset'> ]? ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#view-timeline
#[syntax(" [ <'view-timeline-name'> [ <'view-timeline-axis'> || <'view-timeline-inset'> ]? ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "see individual properties",
    inherits = Unknown,
    applies_to = Elements,
    animation_type = Unknown,
    percentages = Unknown,
    longhands = ViewTimelineAxis|ViewTimelineInset|ViewTimelineName,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.view-timeline"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ViewTimelineStyleValue<'a>;

/// Represents the style value for `view-timeline-axis` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#view-timeline-axis).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ block | inline | x | y ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#view-timeline-axis
#[syntax(" [ block | inline | x | y ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "block",
    applies_to = Elements,
    shorthand_group = ViewTimeline,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.view-timeline-axis"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ViewTimelineAxisStyleValue<'a>;

/// Represents the style value for `view-timeline-inset` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#view-timeline-inset).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ [ auto | <length-percentage> ]{1,2} ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#view-timeline-inset
#[syntax(" [ [ auto | <length-percentage> ]{1,2} ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "auto",
    applies_to = Elements,
    animation_type = ByComputedValue,
    percentages = Scrollport,
    shorthand_group = ViewTimeline,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.view-timeline-inset"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ViewTimelineInsetStyleValue<'a>;

/// Represents the style value for `view-timeline-name` as defined in [scroll-animations-1](https://drafts.csswg.org/scroll-animations-1/#view-timeline-name).
///
/// The animation-timeline, scroll-timeline, and view-timeline CSS properties advance animations based on the user's scroll position.
///
/// The grammar is defined as:
///
/// ```text,ignore
/// [ none | <dashed-ident> ]#
/// ```
///
/// https://drafts.csswg.org/scroll-animations-1/#view-timeline-name
#[syntax(" [ none | <dashed-ident> ]# ")]
#[derive(
	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
)]
#[declaration_metadata(
    initial = "none",
    applies_to = Elements,
    shorthand_group = ViewTimeline,
    property_group = ScrollAnimations,
    computed_value_type = Unknown,
    canonical_order = "per grammar",
)]
#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.view-timeline-name"))]
#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
#[derive(csskit_derives::NodeWithMetadata)]
pub struct ViewTimelineNameStyleValue<'a>;