css_ast/values/scroll_anchoring/
mod.rs

1#![allow(warnings)]
2//! https://drafts.csswg.org/css-scroll-anchoring-1/
3
4mod impls;
5use super::prelude::*;
6use impls::*;
7/// Represents the style value for `overflow-anchor` as defined in [css-scroll-anchoring-1](https://drafts.csswg.org/css-scroll-anchoring-1/#overflow-anchor).
8///
9/// The overflow-anchor CSS property sets an element as a possible scroll anchor, reducing unintended scrolling when document changes occur above the current scrollport. This is enabled by default where supported.
10///
11/// The grammar is defined as:
12///
13/// ```text,ignore
14/// auto | none
15/// ```
16///
17/// https://drafts.csswg.org/css-scroll-anchoring-1/#overflow-anchor
18#[syntax(" auto | none ")]
19#[derive(
20	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
21)]
22#[declaration_metadata(
23    initial = "auto",
24    applies_to = Elements,
25    animation_type = Discrete,
26    property_group = ScrollAnchoring,
27    computed_value_type = Unknown,
28    canonical_order = "per grammar",
29)]
30#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
31#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.overflow-anchor"))]
32#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
33pub enum OverflowAnchorStyleValue {}