Skip to main content

css_ast/values/
webkit.rs

1//! Webkit-prefixed CSS property value types.
2//!
3//! Non-standard aliases for standardised properties, kept for compatibility
4//! with legacy stylesheets.
5
6use super::prelude::*;
7use crate::{CalcableValue, Length, PositionOne, PositionTwo};
8use css_parse::{Cursor, Parse, Parser, Result as ParseResult};
9
10/// Represents the style value for `-webkit-filter`.
11///
12/// Legacy alias for `filter`. Accepts the same grammar.
13///
14/// The grammar is defined as:
15///
16/// ```text,ignore
17/// none | <filter-value-list>
18/// ```
19#[syntax(" none | <filter-value-list> ")]
20#[derive(
21	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
22)]
23#[declaration_metadata(
24    initial = "none",
25    applies_to = Unknown,
26    animation_type = Unknown,
27    property_group = FilterEffects,
28    computed_value_type = AsSpecified,
29    canonical_order = "per grammar",
30)]
31#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
32#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
33#[derive(csskit_derives::NodeWithMetadata)]
34pub struct WebkitFilterStyleValue<'a>;
35
36/// Represents the style value for `-webkit-flex`.
37///
38/// Legacy alias for `flex`. Accepts the same grammar.
39///
40/// The grammar is defined as:
41///
42/// ```text,ignore
43/// none | [ <'flex-grow'> <'flex-shrink'>? || <'flex-basis'> ]
44/// ```
45#[syntax(" none | [ <'flex-grow'> <'flex-shrink'>? || <'flex-basis'> ] ")]
46#[derive(
47	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
48)]
49#[declaration_metadata(
50    initial = "0 1 auto",
51    applies_to = Elements,
52    animation_type = Unknown,
53    property_group = Flexbox,
54    computed_value_type = Unknown,
55    canonical_order = "per grammar",
56)]
57#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
58#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
59#[derive(csskit_derives::NodeWithMetadata)]
60pub struct WebkitFlexStyleValue<'a>;
61
62/// Represents the style value for `-webkit-order`.
63///
64/// Legacy alias for `order`. Accepts the same grammar.
65///
66/// The grammar is defined as:
67///
68/// ```text,ignore
69/// <integer>
70/// ```
71#[syntax(" <integer> ")]
72#[derive(
73	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
74)]
75#[declaration_metadata(
76    initial = "0",
77    applies_to = Elements,
78    animation_type = ByComputedValue,
79    property_group = Flexbox,
80    computed_value_type = AsSpecified,
81    canonical_order = "per grammar",
82)]
83#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
84#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
85#[derive(csskit_derives::NodeWithMetadata)]
86pub struct WebkitOrderStyleValue<'a>;
87
88/// Represents the style value for `-webkit-transform-origin`.
89///
90/// Legacy alias for `transform-origin`. Accepts the same grammar.
91///
92/// The grammar is defined as:
93///
94/// ```text,ignore
95/// <position-one> | <position-two> <length>?
96/// ```
97#[syntax(" <position-one> | <position-two> <length>? ")]
98#[derive(
99	Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
100)]
101#[declaration_metadata(
102    initial = "none",
103    applies_to = Unknown,
104    animation_type = Unknown,
105    property_group = FilterEffects,
106    computed_value_type = AsSpecified,
107    canonical_order = "per grammar",
108)]
109#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
110#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
111#[derive(csskit_derives::NodeWithMetadata)]
112pub enum WebkitTransformOriginStyleValue<'a> {}
113
114impl<'a> Parse<'a> for WebkitTransformOriginStyleValue<'a> {
115	fn parse<I>(p: &mut Parser<'a, I>) -> ParseResult<Self>
116	where
117		I: Iterator<Item = Cursor> + Clone,
118	{
119		let first = p.parse::<PositionOne>()?;
120		if !p.peek::<PositionOne>() {
121			return Ok(Self::PositionOne(crate::Value::Literal(first)));
122		}
123		let second_c = p.peek_n(1);
124		let second = p.parse::<PositionOne>()?;
125		let two = PositionTwo::from_two(p, first, second, second_c)?;
126		Ok(Self::PositionTwo(crate::Value::Literal(two), p.parse_if_peek::<CalcableValue<Length>>()?))
127	}
128}
129
130/// Represents the style value for `-webkit-transition`.
131///
132/// Legacy alias for `transition`. Accepts the same grammar.
133///
134/// The grammar is defined as:
135///
136/// ```text,ignore
137/// <single-transition>#
138/// ```
139#[syntax(" <single-transition># ")]
140#[derive(
141	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
142)]
143#[declaration_metadata(
144    initial = "see individual properties",
145    applies_to = Elements,
146    property_group = Transitions,
147    computed_value_type = Unknown,
148    canonical_order = "per grammar",
149)]
150#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
151#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
152#[derive(csskit_derives::NodeWithMetadata)]
153pub struct WebkitTransitionStyleValue<'a>;
154
155/// Represents the style value for `-webkit-appearance`.
156///
157/// Legacy alias for `appearance`. Accepts the same grammar.
158///
159/// The grammar is defined as:
160///
161/// ```text,ignore
162/// none | auto | base | base-select | <compat-auto> | <compat-special>
163/// ```
164#[syntax(" none | auto | base | base-select | <compat-auto> | <compat-special> ")]
165#[derive(
166	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
167)]
168#[declaration_metadata(
169    initial = "none",
170    applies_to = Elements,
171    animation_type = Discrete,
172    property_group = Ui,
173    computed_value_type = Unknown,
174    canonical_order = "per grammar",
175)]
176#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
177#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
178#[derive(csskit_derives::NodeWithMetadata)]
179pub enum WebkitAppearanceStyleValue<'a> {}
180
181/// Represents the style value for `-webkit-transform`.
182///
183/// Legacy alias for `transform`. Accepts the same grammar.
184///
185/// The grammar is defined as:
186///
187/// ```text,ignore
188/// none | <transform-list>
189/// ```
190#[syntax(" none | <transform-list> ")]
191#[derive(
192	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
193)]
194#[declaration_metadata(
195    initial = "none",
196    applies_to = Unknown,
197    animation_type = Unknown,
198    property_group = Transforms,
199    computed_value_type = AsSpecified,
200    canonical_order = "per grammar",
201)]
202#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
203#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
204#[derive(csskit_derives::NodeWithMetadata)]
205pub struct WebkitTransformStyleValue<'a>;
206
207/// Represents the style value for `-webkit-font-smoothing`.
208///
209/// Non-standard WebKit property controlling font antialiasing.
210///
211/// The grammar is defined as:
212///
213/// ```text,ignore
214/// auto | none | antialiased | subpixel-antialiased
215/// ```
216#[syntax(" auto | none | antialiased | subpixel-antialiased ")]
217#[derive(
218	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
219)]
220#[declaration_metadata(
221    initial = "auto",
222    applies_to = Unknown,
223    animation_type = Unknown,
224    property_group = Fonts,
225    computed_value_type = AsSpecified,
226    canonical_order = "per grammar",
227)]
228#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
229#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
230#[derive(csskit_derives::NodeWithMetadata)]
231pub enum WebkitFontSmoothingStyleValue<'a> {}
232
233/// Represents the style value for `-webkit-text-size-adjust`.
234///
235/// Legacy alias for `text-size-adjust`.
236///
237/// The grammar is defined as:
238///
239/// ```text,ignore
240/// auto | none | <percentage [0,∞]>
241/// ```
242#[syntax(" auto | none | <percentage [0,∞]> ")]
243#[derive(
244	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
245)]
246#[declaration_metadata(
247    initial = "auto",
248    inherits,
249    applies_to = Elements,
250    animation_type = ByComputedValue,
251    percentages = Unknown,
252    property_group = SizeAdjust,
253    computed_value_type = Unknown,
254    canonical_order = "N/A",
255)]
256#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
257#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
258#[derive(csskit_derives::NodeWithMetadata)]
259pub struct WebkitTextSizeAdjustStyleValue<'a>;
260
261/// Represents the style value for `-webkit-animation-delay`.
262///
263/// Legacy alias for `animation-delay`. Accepts the same grammar.
264///
265/// The grammar is defined as:
266///
267/// ```text,ignore
268/// <time>#
269/// ```
270#[syntax(" <time># ")]
271#[derive(
272	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
273)]
274#[declaration_metadata(
275    initial = "0s",
276    applies_to = Elements,
277    shorthands = _WebkitAnimation,
278    property_group = Animations,
279    computed_value_type = Unknown,
280    canonical_order = "per grammar",
281)]
282#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
283#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
284#[derive(csskit_derives::NodeWithMetadata)]
285pub struct WebkitAnimationDelayStyleValue<'a>;
286
287/// Represents the style value for `-webkit-animation-duration`.
288///
289/// Legacy alias for `animation-duration`. Accepts the same grammar.
290///
291/// The grammar is defined as:
292///
293/// ```text,ignore
294/// [ auto | <time [0s,∞]> ]#
295/// ```
296#[syntax(" [ auto | <time [0s,∞]> ]# ")]
297#[derive(
298	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
299)]
300#[declaration_metadata(
301    initial = "auto",
302    applies_to = Elements,
303    shorthands = _WebkitAnimation,
304    property_group = Animations,
305    computed_value_type = Unknown,
306    canonical_order = "per grammar",
307)]
308#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
309#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
310#[derive(csskit_derives::NodeWithMetadata)]
311pub struct WebkitAnimationDurationStyleValue<'a>;
312
313/// Represents the style value for `-webkit-animation-fill-mode`.
314///
315/// Legacy alias for `animation-fill-mode`. Accepts the same grammar.
316///
317/// The grammar is defined as:
318///
319/// ```text,ignore
320/// <single-animation-fill-mode>#
321/// ```
322#[syntax(" <single-animation-fill-mode># ")]
323#[derive(
324	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
325)]
326#[declaration_metadata(
327    initial = "none",
328    applies_to = Elements,
329    shorthands = _WebkitAnimation,
330    property_group = Animations,
331    computed_value_type = Unknown,
332    canonical_order = "per grammar",
333)]
334#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
335#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
336#[derive(csskit_derives::NodeWithMetadata)]
337pub struct WebkitAnimationFillModeStyleValue<'a>;
338
339/// Represents the style value for `-webkit-animation-iteration-count`.
340///
341/// Legacy alias for `animation-iteration-count`. Accepts the same grammar.
342///
343/// The grammar is defined as:
344///
345/// ```text,ignore
346/// <single-animation-iteration-count>#
347/// ```
348#[syntax(" <single-animation-iteration-count># ")]
349#[derive(
350	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
351)]
352#[declaration_metadata(
353    initial = "1",
354    applies_to = Elements,
355    shorthands = _WebkitAnimation,
356    property_group = Animations,
357    computed_value_type = Unknown,
358    canonical_order = "per grammar",
359)]
360#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
361#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
362#[derive(csskit_derives::NodeWithMetadata)]
363pub struct WebkitAnimationIterationCountStyleValue<'a>;
364
365/// Represents the style value for `-webkit-animation-name`.
366///
367/// Legacy alias for `animation-name`. Accepts the same grammar.
368///
369/// The grammar is defined as:
370///
371/// ```text,ignore
372/// [ none | <keyframes-name> ]#
373/// ```
374#[syntax(" [ none | <keyframes-name> ]# ")]
375#[derive(
376	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
377)]
378#[declaration_metadata(
379    initial = "none",
380    applies_to = Elements,
381    shorthands = _WebkitAnimation,
382    property_group = Animations,
383    computed_value_type = Unknown,
384    canonical_order = "per grammar",
385)]
386#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
387#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
388#[derive(csskit_derives::NodeWithMetadata)]
389pub struct WebkitAnimationNameStyleValue<'a>;
390
391/// Represents the style value for `-webkit-animation-timing-function`.
392///
393/// Legacy alias for `animation-timing-function`. Accepts the same grammar.
394///
395/// The grammar is defined as:
396///
397/// ```text,ignore
398/// <easing-function>#
399/// ```
400#[syntax(" <easing-function># ")]
401#[derive(
402	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
403)]
404#[declaration_metadata(
405    initial = "ease",
406    applies_to = Elements,
407    shorthands = _WebkitAnimation,
408    property_group = Animations,
409    computed_value_type = Unknown,
410    canonical_order = "per grammar",
411)]
412#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
413#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
414#[derive(csskit_derives::NodeWithMetadata)]
415pub struct WebkitAnimationTimingFunctionStyleValue<'a>;
416
417/// Represents the style value for `-webkit-backface-visibility`.
418///
419/// Legacy alias for `backface-visibility`. Accepts the same grammar.
420///
421/// The grammar is defined as:
422///
423/// ```text,ignore
424/// visible | hidden
425/// ```
426#[syntax(" visible | hidden ")]
427#[derive(
428	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
429)]
430#[declaration_metadata(
431    initial = "visible",
432    applies_to = Elements,
433    property_group = Transforms,
434    computed_value_type = AsSpecified,
435    canonical_order = "per grammar",
436)]
437#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
438#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
439#[derive(csskit_derives::NodeWithMetadata)]
440pub enum WebkitBackfaceVisibilityStyleValue<'a> {}
441
442/// Represents the style value for `-webkit-tap-highlight-color`.
443///
444/// Non-standard property. Sets the highlight colour when an element is tapped.
445///
446/// The grammar is defined as:
447///
448/// ```text,ignore
449/// <color>
450/// ```
451#[syntax(" <color> ")]
452#[derive(
453	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
454)]
455#[declaration_metadata(
456    initial = "transparent",
457    applies_to = Elements,
458    property_group = Ui,
459    computed_value_type = AsSpecified,
460    canonical_order = "per grammar",
461)]
462#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
463#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
464#[derive(csskit_derives::NodeWithMetadata)]
465pub struct WebkitTapHighlightColorStyleValue<'a>;
466
467/// Represents the style value for `-webkit-transition-duration`.
468///
469/// Legacy alias for `transition-duration`. Accepts the same grammar.
470///
471/// The grammar is defined as:
472///
473/// ```text,ignore
474/// <time [0s,∞]>#
475/// ```
476#[syntax(" <time [0s,∞]># ")]
477#[derive(
478	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
479)]
480#[declaration_metadata(
481    initial = "0s",
482    applies_to = Elements,
483    property_group = Transitions,
484    computed_value_type = Unknown,
485    canonical_order = "per grammar",
486)]
487#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
488#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
489#[derive(csskit_derives::NodeWithMetadata)]
490pub struct WebkitTransitionDurationStyleValue<'a>;
491
492/// Represents the style value for `-webkit-transition-timing-function`.
493///
494/// Legacy alias for `transition-timing-function`. Accepts the same grammar.
495///
496/// The grammar is defined as:
497///
498/// ```text,ignore
499/// <easing-function>#
500/// ```
501#[syntax(" <easing-function># ")]
502#[derive(
503	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
504)]
505#[declaration_metadata(
506    initial = "ease",
507    applies_to = Elements,
508    property_group = Transitions,
509    computed_value_type = AsSpecified,
510    canonical_order = "per grammar",
511)]
512#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
513#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
514#[derive(csskit_derives::NodeWithMetadata)]
515pub struct WebkitTransitionTimingFunctionStyleValue<'a>;
516
517// ── Flexbox aliases ──────────────────────────────────────────────────────────
518
519/// `-webkit-flex-direction` — alias for `flex-direction`.
520#[syntax(" row | row-reverse | column | column-reverse ")]
521#[derive(
522	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
523)]
524#[declaration_metadata(
525    initial = "row",
526    applies_to = Elements,
527    animation_type = Discrete,
528    property_group = Flexbox,
529    computed_value_type = AsSpecified,
530    canonical_order = "per grammar",
531)]
532#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
533#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
534#[derive(csskit_derives::NodeWithMetadata)]
535pub enum WebkitFlexDirectionStyleValue<'a> {}
536
537/// `-webkit-flex-wrap` — alias for `flex-wrap`.
538#[syntax(" nowrap | wrap | wrap-reverse ")]
539#[derive(
540	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
541)]
542#[declaration_metadata(
543    initial = "nowrap",
544    applies_to = Elements,
545    animation_type = Discrete,
546    property_group = Flexbox,
547    computed_value_type = AsSpecified,
548    canonical_order = "per grammar",
549)]
550#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
551#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
552#[derive(csskit_derives::NodeWithMetadata)]
553pub enum WebkitFlexWrapStyleValue<'a> {}
554
555/// `-webkit-flex-basis` — alias for `flex-basis`.
556#[syntax(" content | <'width'> ")]
557#[derive(
558	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
559)]
560#[declaration_metadata(
561    initial = "auto",
562    applies_to = Elements,
563    animation_type = ByComputedValue,
564    property_group = Flexbox,
565    computed_value_type = Unknown,
566    canonical_order = "per grammar",
567)]
568#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
569#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
570#[derive(csskit_derives::NodeWithMetadata)]
571pub enum WebkitFlexBasisStyleValue<'a> {}
572
573/// `-webkit-flex-flow` — alias for `flex-flow`.
574#[syntax(" <'flex-direction'> || <'flex-wrap'> ")]
575#[derive(
576	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
577)]
578#[declaration_metadata(
579    initial = "see individual properties",
580    applies_to = Elements,
581    property_group = Flexbox,
582    computed_value_type = Unknown,
583    canonical_order = "per grammar",
584)]
585#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
586#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
587#[derive(csskit_derives::NodeWithMetadata)]
588pub struct WebkitFlexFlowStyleValue<'a>;
589
590/// `-webkit-flex-grow` — alias for `flex-grow`.
591#[syntax(" <number [0,∞]> ")]
592#[derive(
593	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
594)]
595#[declaration_metadata(
596    initial = "0",
597    applies_to = Elements,
598    animation_type = ByComputedValue,
599    property_group = Flexbox,
600    computed_value_type = AsSpecified,
601    canonical_order = "per grammar",
602)]
603#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
604#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
605#[derive(csskit_derives::NodeWithMetadata)]
606pub struct WebkitFlexGrowStyleValue<'a>;
607
608/// `-webkit-justify-content` — alias for `justify-content`.
609#[syntax(" normal | <content-distribution> | <overflow-position>? [ <content-position> | left | right ] ")]
610#[derive(
611	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
612)]
613#[declaration_metadata(
614    initial = "normal",
615    applies_to = Elements,
616    animation_type = Discrete,
617    property_group = Align,
618    computed_value_type = AsSpecified,
619    canonical_order = "per grammar",
620)]
621#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
622#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
623#[derive(csskit_derives::NodeWithMetadata)]
624pub enum WebkitJustifyContentStyleValue<'a> {}
625
626/// `-webkit-align-items` — alias for `align-items`.
627#[syntax(" normal | stretch | <baseline-position> | <overflow-position>? <self-position> ")]
628#[derive(
629	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
630)]
631#[declaration_metadata(
632    initial = "normal",
633    applies_to = Elements,
634    animation_type = Discrete,
635    property_group = Align,
636    computed_value_type = AsSpecified,
637    canonical_order = "per grammar",
638)]
639#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
640#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
641#[derive(csskit_derives::NodeWithMetadata)]
642pub enum WebkitAlignItemsStyleValue<'a> {}
643
644/// `-webkit-align-self` — alias for `align-self`.
645#[syntax(" auto | <overflow-position>? [ normal | <self-position> ] | stretch | <baseline-position> ")]
646#[derive(
647	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
648)]
649#[declaration_metadata(
650    initial = "auto",
651    applies_to = Elements,
652    animation_type = Discrete,
653    property_group = Align,
654    computed_value_type = AsSpecified,
655    canonical_order = "per grammar",
656)]
657#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
658#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
659#[derive(csskit_derives::NodeWithMetadata)]
660pub enum WebkitAlignSelfStyleValue<'a> {}
661
662/// `-webkit-align-content` — alias for `align-content`.
663#[syntax(" normal | <baseline-position> | <content-distribution> | <overflow-position>? <content-position> ")]
664#[derive(
665	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
666)]
667#[declaration_metadata(
668    initial = "normal",
669    applies_to = Elements,
670    animation_type = Discrete,
671    property_group = Align,
672    computed_value_type = AsSpecified,
673    canonical_order = "per grammar",
674)]
675#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
676#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
677#[derive(csskit_derives::NodeWithMetadata)]
678pub enum WebkitAlignContentStyleValue<'a> {}
679
680// ── Legacy box model ─────────────────────────────────────────────────────────
681
682/// `-webkit-box-orient` — legacy flexbox axis direction.
683#[syntax(" horizontal | vertical | inline-axis | block-axis ")]
684#[derive(
685	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
686)]
687#[declaration_metadata(
688    initial = "inline-axis",
689    applies_to = Elements,
690    animation_type = Discrete,
691    property_group = Flexbox,
692    computed_value_type = AsSpecified,
693    canonical_order = "per grammar",
694)]
695#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
696#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
697#[derive(csskit_derives::NodeWithMetadata)]
698pub enum WebkitBoxOrientStyleValue<'a> {}
699
700/// `-webkit-box-direction` — legacy flexbox item order direction.
701#[syntax(" normal | reverse ")]
702#[derive(
703	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
704)]
705#[declaration_metadata(
706    initial = "normal",
707    applies_to = Elements,
708    animation_type = Discrete,
709    property_group = Flexbox,
710    computed_value_type = AsSpecified,
711    canonical_order = "per grammar",
712)]
713#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
714#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
715#[derive(csskit_derives::NodeWithMetadata)]
716pub enum WebkitBoxDirectionStyleValue<'a> {}
717
718/// `-webkit-box-pack` — legacy flexbox main-axis alignment.
719#[syntax(" start | end | center | justify ")]
720#[derive(
721	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
722)]
723#[declaration_metadata(
724    initial = "start",
725    applies_to = Elements,
726    animation_type = Discrete,
727    property_group = Flexbox,
728    computed_value_type = AsSpecified,
729    canonical_order = "per grammar",
730)]
731#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
732#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
733#[derive(csskit_derives::NodeWithMetadata)]
734pub enum WebkitBoxPackStyleValue<'a> {}
735
736/// `-webkit-box-align` — legacy flexbox cross-axis alignment.
737#[syntax(" stretch | start | end | center | baseline ")]
738#[derive(
739	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
740)]
741#[declaration_metadata(
742    initial = "stretch",
743    applies_to = Elements,
744    animation_type = Discrete,
745    property_group = Flexbox,
746    computed_value_type = AsSpecified,
747    canonical_order = "per grammar",
748)]
749#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
750#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
751#[derive(csskit_derives::NodeWithMetadata)]
752pub enum WebkitBoxAlignStyleValue<'a> {}
753
754/// `-webkit-box-flex` — legacy flexbox grow factor.
755#[syntax(" <number> ")]
756#[derive(
757	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
758)]
759#[declaration_metadata(
760    initial = "0",
761    applies_to = Elements,
762    animation_type = ByComputedValue,
763    property_group = Flexbox,
764    computed_value_type = AsSpecified,
765    canonical_order = "per grammar",
766)]
767#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
768#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
769#[derive(csskit_derives::NodeWithMetadata)]
770pub struct WebkitBoxFlexStyleValue<'a>;
771
772/// `-webkit-box-ordinal-group` — legacy flexbox ordering.
773#[syntax(" <integer [1,∞]> ")]
774#[derive(
775	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
776)]
777#[declaration_metadata(
778    initial = "1",
779    applies_to = Elements,
780    animation_type = ByComputedValue,
781    property_group = Flexbox,
782    computed_value_type = AsSpecified,
783    canonical_order = "per grammar",
784)]
785#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
786#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
787#[derive(csskit_derives::NodeWithMetadata)]
788pub struct WebkitBoxOrdinalGroupStyleValue<'a>;
789
790/// `-webkit-box-shadow` — alias for `box-shadow`.
791#[syntax(" <spread-shadow># ")]
792#[derive(
793	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
794)]
795#[declaration_metadata(
796    initial = "none",
797    applies_to = Elements,
798    animation_type = ByComputedValue,
799    property_group = Borders,
800    computed_value_type = Unknown,
801    canonical_order = "per grammar",
802)]
803#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
804#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
805#[derive(csskit_derives::NodeWithMetadata)]
806pub struct WebkitBoxShadowStyleValue<'a>;
807
808/// `-webkit-box-sizing` — alias for `box-sizing`.
809#[syntax(" content-box | border-box ")]
810#[derive(
811	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
812)]
813#[declaration_metadata(
814    initial = "content-box",
815    applies_to = Elements,
816    animation_type = Discrete,
817    property_group = Sizing,
818    computed_value_type = AsSpecified,
819    canonical_order = "per grammar",
820)]
821#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
822#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
823#[derive(csskit_derives::NodeWithMetadata)]
824pub enum WebkitBoxSizingStyleValue<'a> {}
825
826/// `-webkit-box-decoration-break` — alias for `box-decoration-break`.
827#[syntax(" clone | slice ")]
828#[derive(
829	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
830)]
831#[declaration_metadata(
832    initial = "slice",
833    applies_to = Elements,
834    animation_type = Discrete,
835    property_group = Borders,
836    computed_value_type = AsSpecified,
837    canonical_order = "per grammar",
838)]
839#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
840#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
841#[derive(csskit_derives::NodeWithMetadata)]
842pub enum WebkitBoxDecorationBreakStyleValue<'a> {}
843
844// ── Misc aliases ─────────────────────────────────────────────────────────────
845
846/// `-webkit-user-select` — alias for `user-select`.
847#[syntax(" auto | text | none | all ")]
848#[derive(
849	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
850)]
851#[declaration_metadata(
852    initial = "auto",
853    applies_to = Elements,
854    animation_type = Discrete,
855    property_group = Ui,
856    computed_value_type = AsSpecified,
857    canonical_order = "per grammar",
858)]
859#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
860#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
861#[derive(csskit_derives::NodeWithMetadata)]
862pub enum WebkitUserSelectStyleValue<'a> {}
863
864/// `-webkit-overflow-scrolling` — non-standard momentum scrolling on iOS.
865#[syntax(" auto | touch ")]
866#[derive(
867	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
868)]
869#[declaration_metadata(
870    initial = "auto",
871    applies_to = Elements,
872    animation_type = Discrete,
873    property_group = Overflow,
874    computed_value_type = AsSpecified,
875    canonical_order = "per grammar",
876)]
877#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
878#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
879#[derive(csskit_derives::NodeWithMetadata)]
880pub enum WebkitOverflowScrollingStyleValue<'a> {}
881
882/// `-webkit-print-color-adjust` — alias for `print-color-adjust`.
883#[syntax(" economy | exact ")]
884#[derive(
885	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
886)]
887#[declaration_metadata(
888    initial = "economy",
889    inherits,
890    applies_to = Elements,
891    animation_type = Discrete,
892    property_group = ColorAdjust,
893    computed_value_type = AsSpecified,
894    canonical_order = "per grammar",
895)]
896#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
897#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
898#[derive(csskit_derives::NodeWithMetadata)]
899pub enum WebkitPrintColorAdjustStyleValue<'a> {}
900
901/// `-webkit-text-decoration` — alias for `text-decoration`.
902#[syntax(
903	" <'text-decoration-line'> || <'text-decoration-thickness'> || <'text-decoration-style'> || <'text-decoration-color'> "
904)]
905#[derive(
906	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
907)]
908#[declaration_metadata(
909    initial = "see individual properties",
910    applies_to = Elements,
911    animation_type = Unknown,
912    property_group = TextDecor,
913    computed_value_type = Unknown,
914    canonical_order = "per grammar",
915)]
916#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
917#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
918#[derive(csskit_derives::NodeWithMetadata)]
919pub struct WebkitTextDecorationStyleValue<'a>;
920
921/// `-webkit-text-decoration-color` — alias for `text-decoration-color`.
922#[syntax(" <color> ")]
923#[derive(
924	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
925)]
926#[declaration_metadata(
927    initial = "currentcolor",
928    inherits,
929    applies_to = Elements,
930    animation_type = ByComputedValue,
931    property_group = TextDecor,
932    computed_value_type = Unknown,
933    canonical_order = "per grammar",
934)]
935#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
936#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
937#[derive(csskit_derives::NodeWithMetadata)]
938pub struct WebkitTextDecorationColorStyleValue<'a>;
939
940/// `-webkit-text-decoration-skip-ink` — alias for `text-decoration-skip-ink`.
941#[syntax(" auto | none | all ")]
942#[derive(
943	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
944)]
945#[declaration_metadata(
946    initial = "auto",
947    inherits,
948    applies_to = Elements,
949    animation_type = Discrete,
950    property_group = TextDecor,
951    computed_value_type = AsSpecified,
952    canonical_order = "per grammar",
953)]
954#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
955#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
956#[derive(csskit_derives::NodeWithMetadata)]
957pub enum WebkitTextDecorationSkipInkStyleValue<'a> {}
958
959/// `-webkit-column-gap` — alias for `column-gap`.
960#[syntax(" normal | <length-percentage [0,∞]> | <line-width> ")]
961#[derive(
962	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
963)]
964#[declaration_metadata(
965    initial = "normal",
966    applies_to = Elements,
967    animation_type = ByComputedValue,
968    property_group = Gaps,
969    computed_value_type = Unknown,
970    canonical_order = "per grammar",
971)]
972#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
973#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
974#[derive(csskit_derives::NodeWithMetadata)]
975pub enum WebkitColumnGapStyleValue<'a> {}
976
977/// `-webkit-column-count` — alias for `column-count`.
978#[syntax(" auto | <integer [1,∞]> ")]
979#[derive(
980	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
981)]
982#[declaration_metadata(
983    initial = "auto",
984    applies_to = Elements,
985    animation_type = ByComputedValue,
986    property_group = Multicol,
987    computed_value_type = AsSpecified,
988    canonical_order = "per grammar",
989)]
990#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
991#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
992#[derive(csskit_derives::NodeWithMetadata)]
993pub struct WebkitColumnCountStyleValue<'a>;
994
995/// `-webkit-margin-end` — alias for `margin-inline-end`.
996#[syntax(" <'margin-top'> ")]
997#[derive(
998	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
999)]
1000#[declaration_metadata(
1001    initial = "0",
1002    applies_to = Elements,
1003    animation_type = ByComputedValue,
1004    property_group = Logical,
1005    computed_value_type = Unknown,
1006    canonical_order = "per grammar",
1007)]
1008#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1009#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1010#[derive(csskit_derives::NodeWithMetadata)]
1011pub struct WebkitMarginEndStyleValue<'a>;
1012
1013/// `-webkit-mask-position` — alias for `mask-position`.
1014#[syntax(" <position># ")]
1015#[derive(
1016	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1017)]
1018#[declaration_metadata(
1019    initial = "0% 0%",
1020    applies_to = Elements,
1021    animation_type = Unknown,
1022    property_group = Masking,
1023    computed_value_type = Unknown,
1024    canonical_order = "per grammar",
1025)]
1026#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1027#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1028#[derive(csskit_derives::NodeWithMetadata)]
1029pub struct WebkitMaskPositionStyleValue<'a>;
1030
1031/// `-webkit-mask-size` — alias for `mask-size`.
1032#[syntax(" <bg-size># ")]
1033#[derive(
1034	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1035)]
1036#[declaration_metadata(
1037    initial = "auto",
1038    applies_to = Elements,
1039    animation_type = Unknown,
1040    property_group = Masking,
1041    computed_value_type = Unknown,
1042    canonical_order = "per grammar",
1043)]
1044#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1045#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1046#[derive(csskit_derives::NodeWithMetadata)]
1047pub struct WebkitMaskSizeStyleValue<'a>;
1048
1049/// `-webkit-transition-property` — alias for `transition-property`.
1050#[syntax(" none | <single-transition-property># ")]
1051#[derive(
1052	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1053)]
1054#[declaration_metadata(
1055    initial = "all",
1056    applies_to = Elements,
1057    property_group = Transitions,
1058    computed_value_type = Unknown,
1059    canonical_order = "per grammar",
1060)]
1061#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1062#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1063#[derive(csskit_derives::NodeWithMetadata)]
1064pub struct WebkitTransitionPropertyStyleValue<'a>;
1065
1066/// `-webkit-transition-delay` — alias for `transition-delay`.
1067#[syntax(" <time># ")]
1068#[derive(
1069	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1070)]
1071#[declaration_metadata(
1072    initial = "0s",
1073    applies_to = Elements,
1074    property_group = Transitions,
1075    computed_value_type = Unknown,
1076    canonical_order = "per grammar",
1077)]
1078#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1079#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1080#[derive(csskit_derives::NodeWithMetadata)]
1081pub struct WebkitTransitionDelayStyleValue<'a>;
1082
1083/// `-webkit-user-drag` — non-standard drag behaviour.
1084#[syntax(" auto | none | element ")]
1085#[derive(
1086	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1087)]
1088#[declaration_metadata(
1089    initial = "auto",
1090    applies_to = Elements,
1091    animation_type = Discrete,
1092    property_group = Ui,
1093    computed_value_type = AsSpecified,
1094    canonical_order = "per grammar",
1095)]
1096#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1097#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1098#[derive(csskit_derives::NodeWithMetadata)]
1099pub enum WebkitUserDragStyleValue<'a> {}
1100
1101/// `-webkit-touch-callout` — non-standard iOS touch callout behaviour.
1102#[syntax(" default | none ")]
1103#[derive(
1104	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1105)]
1106#[declaration_metadata(
1107    initial = "default",
1108    inherits,
1109    applies_to = Elements,
1110    animation_type = Discrete,
1111    property_group = Ui,
1112    computed_value_type = AsSpecified,
1113    canonical_order = "per grammar",
1114)]
1115#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1116#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1117#[derive(csskit_derives::NodeWithMetadata)]
1118pub enum WebkitTouchCalloutStyleValue<'a> {}
1119
1120/// `-webkit-text-fill-color` — non-standard text fill colour.
1121#[syntax(" <color> ")]
1122#[derive(
1123	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1124)]
1125#[declaration_metadata(
1126    initial = "currentcolor",
1127    inherits,
1128    applies_to = Elements,
1129    animation_type = ByComputedValue,
1130    property_group = Fonts,
1131    computed_value_type = Unknown,
1132    canonical_order = "per grammar",
1133)]
1134#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1135#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1136#[derive(csskit_derives::NodeWithMetadata)]
1137pub struct WebkitTextFillColorStyleValue<'a>;
1138
1139/// `-webkit-text-stroke` shorthand for `-webkit-text-stroke-width` and `-webkit-text-stroke-color`.
1140#[syntax(" <'-webkit-text-stroke-width'> || <'-webkit-text-stroke-color'> ")]
1141#[derive(
1142	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1143)]
1144#[declaration_metadata(
1145    initial = "see individual properties",
1146    inherits,
1147    applies_to = Elements,
1148    animation_type = Unknown,
1149    longhands = _WebkitTextStrokeWidth|_WebkitTextStrokeColor,
1150    property_group = Fonts,
1151    computed_value_type = Unknown,
1152    canonical_order = "per grammar",
1153)]
1154#[declaration_writes(_WebkitTextStrokeWidth?, _WebkitTextStrokeColor?)]
1155#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1156#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1157#[derive(csskit_derives::NodeWithMetadata)]
1158pub struct WebkitTextStrokeStyleValue<'a>;
1159
1160/// `-webkit-text-stroke-color` — non-standard text stroke colour.
1161#[syntax(" <color> ")]
1162#[derive(
1163	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1164)]
1165#[declaration_metadata(
1166    initial = "currentcolor",
1167    inherits,
1168    applies_to = Elements,
1169    animation_type = ByComputedValue,
1170    shorthands = _WebkitTextStroke,
1171    property_group = Fonts,
1172    computed_value_type = Unknown,
1173    canonical_order = "per grammar",
1174)]
1175#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1176#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1177#[derive(csskit_derives::NodeWithMetadata)]
1178pub struct WebkitTextStrokeColorStyleValue<'a>;
1179
1180/// `-webkit-text-stroke-width` — non-standard text stroke width.
1181#[syntax(" <line-width> ")]
1182#[derive(
1183	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1184)]
1185#[declaration_metadata(
1186    initial = "0",
1187    inherits,
1188    applies_to = Elements,
1189    animation_type = Discrete,
1190    shorthands = _WebkitTextStroke,
1191    property_group = Fonts,
1192    computed_value_type = Unknown,
1193    canonical_order = "per grammar",
1194)]
1195#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1196#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1197#[derive(csskit_derives::NodeWithMetadata)]
1198pub struct WebkitTextStrokeWidthStyleValue<'a>;
1199
1200/// `-webkit-background-clip` — alias for `background-clip`.
1201#[syntax(" <bg-clip># ")]
1202#[derive(
1203	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1204)]
1205#[declaration_metadata(
1206    initial = "border-box",
1207    applies_to = Elements,
1208    animation_type = Discrete,
1209    property_group = Backgrounds,
1210    computed_value_type = AsSpecified,
1211    canonical_order = "per grammar",
1212)]
1213#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1214#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1215#[derive(csskit_derives::NodeWithMetadata)]
1216pub struct WebkitBackgroundClipStyleValue<'a>;
1217
1218/// `-webkit-background-size` — alias for `background-size`.
1219#[syntax(" <bg-size># ")]
1220#[derive(
1221	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1222)]
1223#[declaration_metadata(
1224    initial = "auto",
1225    applies_to = Elements,
1226    animation_type = ByComputedValue,
1227    property_group = Backgrounds,
1228    computed_value_type = Unknown,
1229    canonical_order = "per grammar",
1230)]
1231#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1232#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1233#[derive(csskit_derives::NodeWithMetadata)]
1234pub struct WebkitBackgroundSizeStyleValue<'a>;
1235
1236// `-webkit-animation` — alias for `animation`.
1237#[syntax(" <single-animation># ")]
1238#[derive(
1239	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1240)]
1241#[declaration_metadata(
1242    initial = "auto",
1243    applies_to = Elements,
1244    animation_type = ByComputedValue,
1245    property_group = Animations,
1246    longhands = _WebkitAnimationName|_WebkitAnimationDuration|_WebkitAnimationTimingFunction|_WebkitAnimationDelay|_WebkitAnimationIterationCount|_WebkitAnimationFillMode,
1247    computed_value_type = Unknown,
1248    canonical_order = "per grammar",
1249)]
1250#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1251#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1252#[derive(csskit_derives::NodeWithMetadata)]
1253pub struct WebkitAnimationStyleValue<'a>;
1254
1255/// `-webkit-perspective` — alias for `perspective`.
1256#[syntax(" none | <length [0,∞]> ")]
1257#[derive(
1258	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1259)]
1260#[declaration_metadata(
1261    initial = "none",
1262    applies_to = Elements,
1263    animation_type = ByComputedValue,
1264    property_group = Transforms,
1265    computed_value_type = Unknown,
1266    canonical_order = "per grammar",
1267)]
1268#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1269#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1270#[derive(csskit_derives::NodeWithMetadata)]
1271pub struct WebkitPerspectiveStyleValue<'a>;
1272
1273/// `-webkit-clip-path` — alias for `clip-path`.
1274#[syntax(" none | <clip-source> | [ <basic-shape> || <geometry-box> ] ")]
1275#[derive(
1276	Parse, Peek, ToSpan, ToCursors, DeclarationMetadata, SemanticEq, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash,
1277)]
1278#[declaration_metadata(
1279    initial = "none",
1280    applies_to = Unknown,
1281    animation_type = ByComputedValue,
1282    property_group = Masking,
1283    computed_value_type = SpecifiedWithAbsoluteUrls,
1284    canonical_order = "per grammar",
1285)]
1286#[cfg_attr(feature = "serde", derive(serde::Serialize), serde())]
1287#[cfg_attr(feature = "visitable", derive(Visitable), visit)]
1288#[derive(csskit_derives::NodeWithMetadata)]
1289pub enum WebkitClipPathStyleValue<'a> {}
1290
1291#[cfg(test)]
1292mod tests {
1293	use super::*;
1294	use crate::CssAtomSet;
1295	use css_parse::{assert_parse, assert_parse_error, assert_peek_false};
1296
1297	#[test]
1298	fn test_parses() {
1299		assert_parse!(CssAtomSet::ATOMS, WebkitFilterStyleValue, "none");
1300		assert_parse!(CssAtomSet::ATOMS, WebkitFilterStyleValue, "blur(4px)");
1301		assert_parse!(CssAtomSet::ATOMS, WebkitFilterStyleValue, "brightness(0.5) contrast(1.2)");
1302		assert_parse!(CssAtomSet::ATOMS, WebkitFilterStyleValue, "drop-shadow(2px 4px)");
1303		assert_parse!(CssAtomSet::ATOMS, WebkitFilterStyleValue, "drop-shadow(red 2px 4px)");
1304	}
1305
1306	#[test]
1307	fn test_errors() {
1308		assert_peek_false!(CssAtomSet::ATOMS, WebkitFilterStyleValue, "invalid");
1309	}
1310
1311	#[test]
1312	fn test_transition_parses() {
1313		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionStyleValue, "none");
1314		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionStyleValue, "all 0.3s ease");
1315		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionStyleValue, "opacity 1s, transform 0.5s");
1316	}
1317
1318	#[test]
1319	fn test_transition_errors() {
1320		assert_parse_error!(CssAtomSet::ATOMS, WebkitTransitionStyleValue, "invalid!!!!");
1321	}
1322
1323	#[test]
1324	fn test_flex_parses() {
1325		assert_parse!(CssAtomSet::ATOMS, WebkitFlexStyleValue, "none");
1326		assert_parse!(CssAtomSet::ATOMS, WebkitFlexStyleValue, "1");
1327		assert_parse!(CssAtomSet::ATOMS, WebkitFlexStyleValue, "1 1 auto");
1328	}
1329
1330	#[test]
1331	fn test_flex_errors() {
1332		assert_peek_false!(CssAtomSet::ATOMS, WebkitFlexStyleValue, "invalid");
1333	}
1334
1335	#[test]
1336	fn test_order_parses() {
1337		assert_parse!(CssAtomSet::ATOMS, WebkitOrderStyleValue, "0");
1338		assert_parse!(CssAtomSet::ATOMS, WebkitOrderStyleValue, "-1");
1339		assert_parse!(CssAtomSet::ATOMS, WebkitOrderStyleValue, "5");
1340	}
1341
1342	#[test]
1343	fn test_order_errors() {
1344		assert_peek_false!(CssAtomSet::ATOMS, WebkitOrderStyleValue, "none");
1345	}
1346
1347	#[test]
1348	fn test_appearance_parses() {
1349		assert_parse!(CssAtomSet::ATOMS, WebkitAppearanceStyleValue, "none");
1350		assert_parse!(CssAtomSet::ATOMS, WebkitAppearanceStyleValue, "auto");
1351		assert_parse!(CssAtomSet::ATOMS, WebkitAppearanceStyleValue, "textfield");
1352		assert_parse!(CssAtomSet::ATOMS, WebkitAppearanceStyleValue, "button");
1353	}
1354
1355	#[test]
1356	fn test_appearance_errors() {
1357		assert_peek_false!(CssAtomSet::ATOMS, WebkitAppearanceStyleValue, "invalid");
1358	}
1359
1360	#[test]
1361	fn test_transform_parses() {
1362		assert_parse!(CssAtomSet::ATOMS, WebkitTransformStyleValue, "none");
1363		assert_parse!(CssAtomSet::ATOMS, WebkitTransformStyleValue, "rotate(45deg)");
1364		assert_parse!(CssAtomSet::ATOMS, WebkitTransformStyleValue, "scale(-1, 1)");
1365	}
1366
1367	#[test]
1368	fn test_transform_errors() {
1369		assert_peek_false!(CssAtomSet::ATOMS, WebkitTransformStyleValue, "invalid");
1370	}
1371
1372	#[test]
1373	fn test_font_smoothing_parses() {
1374		assert_parse!(CssAtomSet::ATOMS, WebkitFontSmoothingStyleValue, "auto");
1375		assert_parse!(CssAtomSet::ATOMS, WebkitFontSmoothingStyleValue, "none");
1376		assert_parse!(CssAtomSet::ATOMS, WebkitFontSmoothingStyleValue, "antialiased");
1377		assert_parse!(CssAtomSet::ATOMS, WebkitFontSmoothingStyleValue, "subpixel-antialiased");
1378	}
1379
1380	#[test]
1381	fn test_font_smoothing_errors() {
1382		assert_peek_false!(CssAtomSet::ATOMS, WebkitFontSmoothingStyleValue, "invalid");
1383	}
1384
1385	#[test]
1386	fn test_text_size_adjust_parses() {
1387		assert_parse!(CssAtomSet::ATOMS, WebkitTextSizeAdjustStyleValue, "auto");
1388		assert_parse!(CssAtomSet::ATOMS, WebkitTextSizeAdjustStyleValue, "none");
1389		assert_parse!(CssAtomSet::ATOMS, WebkitTextSizeAdjustStyleValue, "100%");
1390	}
1391
1392	#[test]
1393	fn test_text_size_adjust_errors() {
1394		assert_peek_false!(CssAtomSet::ATOMS, WebkitTextSizeAdjustStyleValue, "invalid");
1395	}
1396
1397	#[test]
1398	fn test_animation_delay_parses() {
1399		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationDelayStyleValue, "0s");
1400		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationDelayStyleValue, "0.5s, 1s");
1401	}
1402
1403	#[test]
1404	fn test_animation_delay_errors() {
1405		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationDelayStyleValue, "invalid");
1406	}
1407
1408	#[test]
1409	fn test_animation_duration_parses() {
1410		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationDurationStyleValue, "auto");
1411		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationDurationStyleValue, "0.3s");
1412		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationDurationStyleValue, "1s, 2s");
1413	}
1414
1415	#[test]
1416	fn test_animation_duration_errors() {
1417		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationDurationStyleValue, "invalid");
1418	}
1419
1420	#[test]
1421	fn test_animation_fill_mode_parses() {
1422		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationFillModeStyleValue, "none");
1423		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationFillModeStyleValue, "forwards");
1424		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationFillModeStyleValue, "both");
1425	}
1426
1427	#[test]
1428	fn test_animation_fill_mode_errors() {
1429		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationFillModeStyleValue, "invalid");
1430	}
1431
1432	#[test]
1433	fn test_animation_iteration_count_parses() {
1434		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationIterationCountStyleValue, "1");
1435		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationIterationCountStyleValue, "infinite");
1436		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationIterationCountStyleValue, "3");
1437	}
1438
1439	#[test]
1440	fn test_animation_iteration_count_errors() {
1441		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationIterationCountStyleValue, "invalid");
1442	}
1443
1444	#[test]
1445	fn test_animation_name_parses() {
1446		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationNameStyleValue, "none");
1447		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationNameStyleValue, "my-animation");
1448	}
1449
1450	#[test]
1451	fn test_animation_name_errors() {
1452		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationNameStyleValue, "");
1453		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationNameStyleValue, "1px");
1454	}
1455
1456	#[test]
1457	fn test_animation_timing_function_parses() {
1458		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationTimingFunctionStyleValue, "ease");
1459		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationTimingFunctionStyleValue, "linear");
1460		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationTimingFunctionStyleValue, "ease-in-out");
1461		assert_parse!(CssAtomSet::ATOMS, WebkitAnimationTimingFunctionStyleValue, "cubic-bezier(0.4, 0, 0.2, 1)");
1462	}
1463
1464	#[test]
1465	fn test_animation_timing_function_errors() {
1466		assert_peek_false!(CssAtomSet::ATOMS, WebkitAnimationTimingFunctionStyleValue, "invalid");
1467	}
1468
1469	#[test]
1470	fn test_backface_visibility_parses() {
1471		assert_parse!(CssAtomSet::ATOMS, WebkitBackfaceVisibilityStyleValue, "visible");
1472		assert_parse!(CssAtomSet::ATOMS, WebkitBackfaceVisibilityStyleValue, "hidden");
1473	}
1474
1475	#[test]
1476	fn test_backface_visibility_errors() {
1477		assert_peek_false!(CssAtomSet::ATOMS, WebkitBackfaceVisibilityStyleValue, "invalid");
1478	}
1479
1480	#[test]
1481	fn test_tap_highlight_color_parses() {
1482		assert_parse!(CssAtomSet::ATOMS, WebkitTapHighlightColorStyleValue, "transparent");
1483		assert_parse!(CssAtomSet::ATOMS, WebkitTapHighlightColorStyleValue, "red");
1484		assert_parse!(CssAtomSet::ATOMS, WebkitTapHighlightColorStyleValue, "rgba(0, 0, 0, 0)");
1485	}
1486
1487	#[test]
1488	fn test_tap_highlight_color_errors() {
1489		assert_peek_false!(CssAtomSet::ATOMS, WebkitTapHighlightColorStyleValue, "invalid");
1490	}
1491
1492	#[test]
1493	fn test_transition_duration_parses() {
1494		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionDurationStyleValue, "0s");
1495		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionDurationStyleValue, "0.3s");
1496		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionDurationStyleValue, "1s, 200ms");
1497	}
1498
1499	#[test]
1500	fn test_transition_duration_errors() {
1501		assert_peek_false!(CssAtomSet::ATOMS, WebkitTransitionDurationStyleValue, "invalid");
1502	}
1503
1504	#[test]
1505	fn test_transition_timing_function_parses() {
1506		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionTimingFunctionStyleValue, "ease");
1507		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionTimingFunctionStyleValue, "linear");
1508		assert_parse!(CssAtomSet::ATOMS, WebkitTransitionTimingFunctionStyleValue, "cubic-bezier(0.4, 0, 0.2, 1)");
1509	}
1510
1511	#[test]
1512	fn test_transition_timing_function_errors() {
1513		assert_peek_false!(CssAtomSet::ATOMS, WebkitTransitionTimingFunctionStyleValue, "invalid");
1514	}
1515
1516	#[test]
1517	fn test_webkit_perspective_parses() {
1518		assert_parse!(CssAtomSet::ATOMS, WebkitPerspectiveStyleValue, "none");
1519		assert_parse!(CssAtomSet::ATOMS, WebkitPerspectiveStyleValue, "800px");
1520	}
1521
1522	#[test]
1523	fn test_webkit_perspective_errors() {
1524		assert_peek_false!(CssAtomSet::ATOMS, WebkitPerspectiveStyleValue, "invalid");
1525	}
1526
1527	#[test]
1528	fn test_text_stroke_parses() {
1529		assert_parse!(CssAtomSet::ATOMS, WebkitTextStrokeStyleValue, "1px");
1530		assert_parse!(CssAtomSet::ATOMS, WebkitTextStrokeStyleValue, "red");
1531		assert_parse!(CssAtomSet::ATOMS, WebkitTextStrokeStyleValue, "1px red");
1532		assert_parse!(CssAtomSet::ATOMS, WebkitTextStrokeStyleValue, "red 1px");
1533	}
1534
1535	#[test]
1536	fn test_text_stroke_errors() {
1537		assert_peek_false!(CssAtomSet::ATOMS, WebkitTextStrokeStyleValue, "");
1538	}
1539}