Skip to main content

css_ast/values/lists/
mod.rs

1// AUTO-GENERATED from w3c/csswg-drafts
2// Commit: https://github.com/w3c/csswg-drafts/commit/e8f0279ce0beff5d70e59fa4165a668e1527fff6
3// Do not edit this file directly.
4#![allow(warnings)]
5//! https://drafts.csswg.org/css-lists-3/
6
7mod impls;
8use super::prelude::*;
9use impls::*;
10/// Represents the style value for `counter-increment` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#counter-increment).
11///
12/// The counter-reset and counter-increment CSS properties and the counter() and counters() functions automatically number headings or ordered list items.
13///
14/// The grammar is defined as:
15///
16/// ```text,ignore
17/// [ <counter-name> <integer>? ]+ | none
18/// ```
19///
20/// https://drafts.csswg.org/css-lists-3/#counter-increment
21#[syntax(" [ <counter-name> <integer>? ]+ | none ")]
22#[derive(
23	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
24)]
25#[declaration_metadata(
26    initial = "none",
27    applies_to = Elements,
28    animation_type = ByComputedValue,
29    property_group = Lists,
30    computed_value_type = Unknown,
31    canonical_order = "per grammar",
32)]
33#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
34#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.counter-increment"))]
35#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
36#[derive(csskit_derives::NodeWithMetadata)]
37pub struct CounterIncrementStyleValue<'a>;
38
39// /// Represents the style value for `counter-reset` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#counter-reset).
40// ///
41// /// The counter-reset and counter-increment CSS properties and the counter() and counters() functions automatically number headings or ordered list items.
42// ///
43// /// The grammar is defined as:
44// ///
45// /// ```text,ignore
46// /// [ <counter-name> <integer>? | <reversed-counter-name> <integer>? ]+ | none
47// /// ```
48// ///
49// /// https://drafts.csswg.org/css-lists-3/#counter-reset
50// #[syntax(" [ <counter-name> <integer>? | <reversed-counter-name> <integer>? ]+ | none ")]
51// #[derive(
52//     Parse,
53//     Peek,
54//     ToSpan,
55//     ToCursors,
56//     DeclarationMetadata,
57//     SemanticEq,
58//     Debug,
59//     Clone,
60//     PartialEq,
61//     Eq,
62//     PartialOrd,
63//     Ord,
64//     Hash,
65// )]
66// #[declaration_metadata(
67//     initial = "none",
68//     applies_to = Elements,
69//     animation_type = ByComputedValue,
70//     property_group = Lists,
71//     computed_value_type = Unknown,
72//     canonical_order = "per grammar",
73// )]
74// #[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
75// #[cfg_attr(
76//     feature = "css_feature_data",
77//     derive(ToCSSFeature),
78//     css_feature("css.properties.counter-reset")
79// )]
80// #[cfg_attr(feature = "visitable", derive(Visitable), visit)]
81// #[derive(csskit_derives::NodeWithMetadata)]
82// pub struct CounterResetStyleValue<'a>;
83
84/// Represents the style value for `counter-set` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#counter-set).
85///
86/// The counter-set CSS property creates (and optionally sets a value for) a counter, the numbers for a series of headings or ordered list items.
87///
88/// The grammar is defined as:
89///
90/// ```text,ignore
91/// [ <counter-name> <integer>? ]+ | none
92/// ```
93///
94/// https://drafts.csswg.org/css-lists-3/#counter-set
95#[syntax(" [ <counter-name> <integer>? ]+ | none ")]
96#[derive(
97	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
98)]
99#[declaration_metadata(
100    initial = "none",
101    applies_to = Elements,
102    animation_type = ByComputedValue,
103    property_group = Lists,
104    computed_value_type = Unknown,
105    canonical_order = "per grammar",
106)]
107#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
108#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.counter-set"))]
109#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
110#[derive(csskit_derives::NodeWithMetadata)]
111pub struct CounterSetStyleValue<'a>;
112
113/// Represents the style value for `list-style` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#list-style).
114///
115/// The list-style shorthand CSS property and the list-style-image, list-style-position, and list-style-type longhand properties set the position and appearance of a list item's marker.
116///
117/// The grammar is defined as:
118///
119/// ```text,ignore
120/// <'list-style-position'> || <'list-style-image'> || <'list-style-type'>
121/// ```
122///
123/// https://drafts.csswg.org/css-lists-3/#list-style
124#[syntax(" <'list-style-position'> || <'list-style-image'> || <'list-style-type'> ")]
125#[derive(
126	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
127)]
128#[declaration_metadata(
129    initial = "see individual properties",
130    inherits = Unknown,
131    applies_to = Unknown,
132    animation_type = Unknown,
133    percentages = Unknown,
134    longhands = ListStyleImage|ListStylePosition|ListStyleType,
135    property_group = Lists,
136    computed_value_type = Unknown,
137    canonical_order = "per grammar",
138)]
139#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
140#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.list-style"))]
141#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
142#[derive(csskit_derives::NodeWithMetadata)]
143pub struct ListStyleStyleValue<'a>;
144
145/// Represents the style value for `list-style-image` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#list-style-image).
146///
147/// The list-style shorthand CSS property and the list-style-image, list-style-position, and list-style-type longhand properties set the position and appearance of a list item's marker.
148///
149/// The grammar is defined as:
150///
151/// ```text,ignore
152/// <image> | none
153/// ```
154///
155/// https://drafts.csswg.org/css-lists-3/#list-style-image
156#[syntax(" <image> | none ")]
157#[derive(
158	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
159)]
160#[declaration_metadata(
161    initial = "none",
162    inherits,
163    applies_to = Unknown,
164    animation_type = Discrete,
165    shorthand_group = ListStyle,
166    property_group = Lists,
167    computed_value_type = Unknown,
168    canonical_order = "per grammar",
169)]
170#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
171#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.list-style-image"))]
172#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
173#[derive(csskit_derives::NodeWithMetadata)]
174pub struct ListStyleImageStyleValue<'a>;
175
176/// Represents the style value for `list-style-position` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#list-style-position).
177///
178/// The list-style shorthand CSS property and the list-style-image, list-style-position, and list-style-type longhand properties set the position and appearance of a list item's marker.
179///
180/// The grammar is defined as:
181///
182/// ```text,ignore
183/// inside | outside
184/// ```
185///
186/// https://drafts.csswg.org/css-lists-3/#list-style-position
187#[syntax(" inside | outside ")]
188#[derive(
189	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
190)]
191#[declaration_metadata(
192    initial = "outside",
193    inherits,
194    applies_to = Unknown,
195    animation_type = Discrete,
196    shorthand_group = ListStyle,
197    property_group = Lists,
198    computed_value_type = Unknown,
199    canonical_order = "per grammar",
200)]
201#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
202#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.list-style-position"))]
203#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
204#[derive(csskit_derives::NodeWithMetadata)]
205pub enum ListStylePositionStyleValue {}
206
207/// Represents the style value for `list-style-type` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#list-style-type).
208///
209/// The list-style shorthand CSS property and the list-style-image, list-style-position, and list-style-type longhand properties set the position and appearance of a list item's marker.
210///
211/// The grammar is defined as:
212///
213/// ```text,ignore
214/// <counter-style> | <string> | none
215/// ```
216///
217/// https://drafts.csswg.org/css-lists-3/#list-style-type
218#[syntax(" <counter-style> | <string> | none ")]
219#[derive(
220	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
221)]
222#[declaration_metadata(
223    initial = "disc",
224    inherits,
225    applies_to = Unknown,
226    animation_type = Discrete,
227    shorthand_group = ListStyle,
228    property_group = Lists,
229    computed_value_type = AsSpecified,
230    canonical_order = "per grammar",
231)]
232#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
233#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.list-style-type"))]
234#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
235#[derive(csskit_derives::NodeWithMetadata)]
236pub enum ListStyleTypeStyleValue<'a> {}
237
238/// Represents the style value for `marker-side` as defined in [css-lists-3](https://drafts.csswg.org/css-lists-3/#marker-side).
239///
240/// The grammar is defined as:
241///
242/// ```text,ignore
243/// match-self | match-parent
244/// ```
245///
246/// https://drafts.csswg.org/css-lists-3/#marker-side
247#[syntax(" match-self | match-parent ")]
248#[derive(
249	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
250)]
251#[declaration_metadata(
252    initial = "match-self",
253    inherits,
254    applies_to = Unknown,
255    animation_type = Discrete,
256    property_group = Lists,
257    computed_value_type = Unknown,
258    canonical_order = "per grammar",
259)]
260#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
261#[cfg_attr(feature = "css_feature_data", derive(ToCSSFeature), css_feature("css.properties.marker-side"))]
262#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
263#[derive(csskit_derives::NodeWithMetadata)]
264pub enum MarkerSideStyleValue {}