1use std::fmt;
4
5use super::{Angle, Color, Length, Percentage, Quoted, Raw, Time, Url};
6
7#[derive(Debug, Clone, PartialEq)]
9#[non_exhaustive]
10pub enum AccentColor {
11 Auto,
13 Color(Color),
15}
16
17impl fmt::Display for AccentColor {
18 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
19 match self {
20 Self::Auto => f.write_str("auto"),
21 Self::Color(v) => v.fmt(f),
22 }
23 }
24}
25
26impl From<Color> for AccentColor {
27 fn from(v: Color) -> Self {
28 Self::Color(v)
29 }
30}
31
32#[derive(Debug, Clone, PartialEq)]
34#[non_exhaustive]
35pub enum AlignContent {
36 Baseline,
38 Center,
40 End,
42 FlexEnd,
44 FlexStart,
46 Normal,
48 SpaceAround,
50 SpaceBetween,
52 SpaceEvenly,
54 Start,
56 Stretch,
58 Raw(Raw),
60}
61
62impl fmt::Display for AlignContent {
63 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
64 match self {
65 Self::Baseline => f.write_str("baseline"),
66 Self::Center => f.write_str("center"),
67 Self::End => f.write_str("end"),
68 Self::FlexEnd => f.write_str("flex-end"),
69 Self::FlexStart => f.write_str("flex-start"),
70 Self::Normal => f.write_str("normal"),
71 Self::SpaceAround => f.write_str("space-around"),
72 Self::SpaceBetween => f.write_str("space-between"),
73 Self::SpaceEvenly => f.write_str("space-evenly"),
74 Self::Start => f.write_str("start"),
75 Self::Stretch => f.write_str("stretch"),
76 Self::Raw(v) => v.fmt(f),
77 }
78 }
79}
80
81impl From<Raw> for AlignContent {
82 fn from(v: Raw) -> Self {
83 Self::Raw(v)
84 }
85}
86
87#[derive(Debug, Clone, PartialEq)]
89#[non_exhaustive]
90pub enum AlignItems {
91 AnchorCenter,
93 Baseline,
95 Center,
97 End,
99 FlexEnd,
101 FlexStart,
103 Normal,
105 SelfEnd,
107 SelfStart,
109 Start,
111 Stretch,
113 Raw(Raw),
115}
116
117impl fmt::Display for AlignItems {
118 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
119 match self {
120 Self::AnchorCenter => f.write_str("anchor-center"),
121 Self::Baseline => f.write_str("baseline"),
122 Self::Center => f.write_str("center"),
123 Self::End => f.write_str("end"),
124 Self::FlexEnd => f.write_str("flex-end"),
125 Self::FlexStart => f.write_str("flex-start"),
126 Self::Normal => f.write_str("normal"),
127 Self::SelfEnd => f.write_str("self-end"),
128 Self::SelfStart => f.write_str("self-start"),
129 Self::Start => f.write_str("start"),
130 Self::Stretch => f.write_str("stretch"),
131 Self::Raw(v) => v.fmt(f),
132 }
133 }
134}
135
136impl From<Raw> for AlignItems {
137 fn from(v: Raw) -> Self {
138 Self::Raw(v)
139 }
140}
141
142#[derive(Debug, Clone, PartialEq)]
144#[non_exhaustive]
145pub enum AlignSelf {
146 AnchorCenter,
148 Auto,
150 Baseline,
152 Center,
154 End,
156 FlexEnd,
158 FlexStart,
160 Normal,
162 SelfEnd,
164 SelfStart,
166 Start,
168 Stretch,
170 Raw(Raw),
172}
173
174impl fmt::Display for AlignSelf {
175 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
176 match self {
177 Self::AnchorCenter => f.write_str("anchor-center"),
178 Self::Auto => f.write_str("auto"),
179 Self::Baseline => f.write_str("baseline"),
180 Self::Center => f.write_str("center"),
181 Self::End => f.write_str("end"),
182 Self::FlexEnd => f.write_str("flex-end"),
183 Self::FlexStart => f.write_str("flex-start"),
184 Self::Normal => f.write_str("normal"),
185 Self::SelfEnd => f.write_str("self-end"),
186 Self::SelfStart => f.write_str("self-start"),
187 Self::Start => f.write_str("start"),
188 Self::Stretch => f.write_str("stretch"),
189 Self::Raw(v) => v.fmt(f),
190 }
191 }
192}
193
194impl From<Raw> for AlignSelf {
195 fn from(v: Raw) -> Self {
196 Self::Raw(v)
197 }
198}
199
200#[derive(Debug, Clone, PartialEq)]
202#[non_exhaustive]
203pub enum AlignmentBaseline {
204 Alphabetic,
206 Baseline,
208 Central,
210 Ideographic,
212 Mathematical,
214 Middle,
216 TextAfterEdge,
218 TextBeforeEdge,
220}
221
222impl fmt::Display for AlignmentBaseline {
223 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
224 match self {
225 Self::Alphabetic => f.write_str("alphabetic"),
226 Self::Baseline => f.write_str("baseline"),
227 Self::Central => f.write_str("central"),
228 Self::Ideographic => f.write_str("ideographic"),
229 Self::Mathematical => f.write_str("mathematical"),
230 Self::Middle => f.write_str("middle"),
231 Self::TextAfterEdge => f.write_str("text-after-edge"),
232 Self::TextBeforeEdge => f.write_str("text-before-edge"),
233 }
234 }
235}
236
237#[derive(Debug, Clone, PartialEq)]
239#[non_exhaustive]
240pub enum All {
241 Inherit,
243 Initial,
245 Revert,
247 RevertLayer,
249 Unset,
251}
252
253impl fmt::Display for All {
254 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
255 match self {
256 Self::Inherit => f.write_str("inherit"),
257 Self::Initial => f.write_str("initial"),
258 Self::Revert => f.write_str("revert"),
259 Self::RevertLayer => f.write_str("revert-layer"),
260 Self::Unset => f.write_str("unset"),
261 }
262 }
263}
264
265#[derive(Debug, Clone, PartialEq)]
267#[non_exhaustive]
268pub enum AnchorName {
269 None,
271 Raw(Raw),
273}
274
275impl fmt::Display for AnchorName {
276 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
277 match self {
278 Self::None => f.write_str("none"),
279 Self::Raw(v) => v.fmt(f),
280 }
281 }
282}
283
284impl From<Raw> for AnchorName {
285 fn from(v: Raw) -> Self {
286 Self::Raw(v)
287 }
288}
289
290#[derive(Debug, Clone, PartialEq)]
292#[non_exhaustive]
293pub enum Animation {
294 Alternate,
296 AlternateReverse,
298 Auto,
300 Backwards,
302 Both,
304 Ease,
306 EaseIn,
308 EaseInOut,
310 EaseOut,
312 Forwards,
314 Infinite,
316 Linear,
318 None,
320 Normal,
322 Paused,
324 Reverse,
326 Running,
328 StepEnd,
330 StepStart,
332 Number(f64),
334 Time(Time),
336 Quoted(Quoted),
338 Raw(Raw),
340}
341
342impl fmt::Display for Animation {
343 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
344 match self {
345 Self::Alternate => f.write_str("alternate"),
346 Self::AlternateReverse => f.write_str("alternate-reverse"),
347 Self::Auto => f.write_str("auto"),
348 Self::Backwards => f.write_str("backwards"),
349 Self::Both => f.write_str("both"),
350 Self::Ease => f.write_str("ease"),
351 Self::EaseIn => f.write_str("ease-in"),
352 Self::EaseInOut => f.write_str("ease-in-out"),
353 Self::EaseOut => f.write_str("ease-out"),
354 Self::Forwards => f.write_str("forwards"),
355 Self::Infinite => f.write_str("infinite"),
356 Self::Linear => f.write_str("linear"),
357 Self::None => f.write_str("none"),
358 Self::Normal => f.write_str("normal"),
359 Self::Paused => f.write_str("paused"),
360 Self::Reverse => f.write_str("reverse"),
361 Self::Running => f.write_str("running"),
362 Self::StepEnd => f.write_str("step-end"),
363 Self::StepStart => f.write_str("step-start"),
364 Self::Number(v) => v.fmt(f),
365 Self::Time(v) => v.fmt(f),
366 Self::Quoted(v) => v.fmt(f),
367 Self::Raw(v) => v.fmt(f),
368 }
369 }
370}
371
372impl From<f64> for Animation {
373 fn from(v: f64) -> Self {
374 Self::Number(v)
375 }
376}
377
378impl From<i32> for Animation {
379 fn from(v: i32) -> Self {
380 Self::Number(f64::from(v))
381 }
382}
383
384impl From<Time> for Animation {
385 fn from(v: Time) -> Self {
386 Self::Time(v)
387 }
388}
389
390impl From<Quoted> for Animation {
391 fn from(v: Quoted) -> Self {
392 Self::Quoted(v)
393 }
394}
395
396impl From<Raw> for Animation {
397 fn from(v: Raw) -> Self {
398 Self::Raw(v)
399 }
400}
401
402#[derive(Debug, Clone, PartialEq)]
404#[non_exhaustive]
405pub enum AnimationComposition {
406 Accumulate,
408 Add,
410 Replace,
412 Raw(Raw),
414}
415
416impl fmt::Display for AnimationComposition {
417 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
418 match self {
419 Self::Accumulate => f.write_str("accumulate"),
420 Self::Add => f.write_str("add"),
421 Self::Replace => f.write_str("replace"),
422 Self::Raw(v) => v.fmt(f),
423 }
424 }
425}
426
427impl From<Raw> for AnimationComposition {
428 fn from(v: Raw) -> Self {
429 Self::Raw(v)
430 }
431}
432
433#[derive(Debug, Clone, PartialEq)]
435#[non_exhaustive]
436pub enum AnimationDelay {
437 Time(Time),
439 Raw(Raw),
441}
442
443impl fmt::Display for AnimationDelay {
444 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
445 match self {
446 Self::Time(v) => v.fmt(f),
447 Self::Raw(v) => v.fmt(f),
448 }
449 }
450}
451
452impl From<Time> for AnimationDelay {
453 fn from(v: Time) -> Self {
454 Self::Time(v)
455 }
456}
457
458impl From<Raw> for AnimationDelay {
459 fn from(v: Raw) -> Self {
460 Self::Raw(v)
461 }
462}
463
464#[derive(Debug, Clone, PartialEq)]
466#[non_exhaustive]
467pub enum AnimationDirection {
468 Alternate,
470 AlternateReverse,
472 Normal,
474 Reverse,
476 Raw(Raw),
478}
479
480impl fmt::Display for AnimationDirection {
481 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
482 match self {
483 Self::Alternate => f.write_str("alternate"),
484 Self::AlternateReverse => f.write_str("alternate-reverse"),
485 Self::Normal => f.write_str("normal"),
486 Self::Reverse => f.write_str("reverse"),
487 Self::Raw(v) => v.fmt(f),
488 }
489 }
490}
491
492impl From<Raw> for AnimationDirection {
493 fn from(v: Raw) -> Self {
494 Self::Raw(v)
495 }
496}
497
498#[derive(Debug, Clone, PartialEq)]
500#[non_exhaustive]
501pub enum AnimationDuration {
502 Auto,
504 Time(Time),
506 Raw(Raw),
508}
509
510impl fmt::Display for AnimationDuration {
511 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
512 match self {
513 Self::Auto => f.write_str("auto"),
514 Self::Time(v) => v.fmt(f),
515 Self::Raw(v) => v.fmt(f),
516 }
517 }
518}
519
520impl From<Time> for AnimationDuration {
521 fn from(v: Time) -> Self {
522 Self::Time(v)
523 }
524}
525
526impl From<Raw> for AnimationDuration {
527 fn from(v: Raw) -> Self {
528 Self::Raw(v)
529 }
530}
531
532#[derive(Debug, Clone, PartialEq)]
534#[non_exhaustive]
535pub enum AnimationFillMode {
536 Backwards,
538 Both,
540 Forwards,
542 None,
544 Raw(Raw),
546}
547
548impl fmt::Display for AnimationFillMode {
549 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
550 match self {
551 Self::Backwards => f.write_str("backwards"),
552 Self::Both => f.write_str("both"),
553 Self::Forwards => f.write_str("forwards"),
554 Self::None => f.write_str("none"),
555 Self::Raw(v) => v.fmt(f),
556 }
557 }
558}
559
560impl From<Raw> for AnimationFillMode {
561 fn from(v: Raw) -> Self {
562 Self::Raw(v)
563 }
564}
565
566#[derive(Debug, Clone, PartialEq)]
568#[non_exhaustive]
569pub enum AnimationIterationCount {
570 Infinite,
572 Number(f64),
574 Raw(Raw),
576}
577
578impl fmt::Display for AnimationIterationCount {
579 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
580 match self {
581 Self::Infinite => f.write_str("infinite"),
582 Self::Number(v) => v.fmt(f),
583 Self::Raw(v) => v.fmt(f),
584 }
585 }
586}
587
588impl From<f64> for AnimationIterationCount {
589 fn from(v: f64) -> Self {
590 Self::Number(v)
591 }
592}
593
594impl From<i32> for AnimationIterationCount {
595 fn from(v: i32) -> Self {
596 Self::Number(f64::from(v))
597 }
598}
599
600impl From<Raw> for AnimationIterationCount {
601 fn from(v: Raw) -> Self {
602 Self::Raw(v)
603 }
604}
605
606#[derive(Debug, Clone, PartialEq)]
608#[non_exhaustive]
609pub enum AnimationName {
610 None,
612 Quoted(Quoted),
614 Raw(Raw),
616}
617
618impl fmt::Display for AnimationName {
619 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
620 match self {
621 Self::None => f.write_str("none"),
622 Self::Quoted(v) => v.fmt(f),
623 Self::Raw(v) => v.fmt(f),
624 }
625 }
626}
627
628impl From<Quoted> for AnimationName {
629 fn from(v: Quoted) -> Self {
630 Self::Quoted(v)
631 }
632}
633
634impl From<Raw> for AnimationName {
635 fn from(v: Raw) -> Self {
636 Self::Raw(v)
637 }
638}
639
640#[derive(Debug, Clone, PartialEq)]
642#[non_exhaustive]
643pub enum AnimationPlayState {
644 Paused,
646 Running,
648 Raw(Raw),
650}
651
652impl fmt::Display for AnimationPlayState {
653 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
654 match self {
655 Self::Paused => f.write_str("paused"),
656 Self::Running => f.write_str("running"),
657 Self::Raw(v) => v.fmt(f),
658 }
659 }
660}
661
662impl From<Raw> for AnimationPlayState {
663 fn from(v: Raw) -> Self {
664 Self::Raw(v)
665 }
666}
667
668#[derive(Debug, Clone, PartialEq)]
670#[non_exhaustive]
671pub enum AnimationTimingFunction {
672 Ease,
674 EaseIn,
676 EaseInOut,
678 EaseOut,
680 Linear,
682 StepEnd,
684 StepStart,
686 Raw(Raw),
688}
689
690impl fmt::Display for AnimationTimingFunction {
691 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
692 match self {
693 Self::Ease => f.write_str("ease"),
694 Self::EaseIn => f.write_str("ease-in"),
695 Self::EaseInOut => f.write_str("ease-in-out"),
696 Self::EaseOut => f.write_str("ease-out"),
697 Self::Linear => f.write_str("linear"),
698 Self::StepEnd => f.write_str("step-end"),
699 Self::StepStart => f.write_str("step-start"),
700 Self::Raw(v) => v.fmt(f),
701 }
702 }
703}
704
705impl From<Raw> for AnimationTimingFunction {
706 fn from(v: Raw) -> Self {
707 Self::Raw(v)
708 }
709}
710
711#[derive(Debug, Clone, PartialEq)]
713#[non_exhaustive]
714pub enum AnimationTrigger {
715 None,
717 Raw(Raw),
719}
720
721impl fmt::Display for AnimationTrigger {
722 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
723 match self {
724 Self::None => f.write_str("none"),
725 Self::Raw(v) => v.fmt(f),
726 }
727 }
728}
729
730impl From<Raw> for AnimationTrigger {
731 fn from(v: Raw) -> Self {
732 Self::Raw(v)
733 }
734}
735
736#[derive(Debug, Clone, PartialEq)]
738#[non_exhaustive]
739pub enum Appearance {
740 Auto,
742 BaseSelect,
744 Button,
746 Checkbox,
748 Listbox,
750 Menulist,
752 MenulistButton,
754 Meter,
756 None,
758 ProgressBar,
760 Radio,
762 Searchfield,
764 Textarea,
766 Textfield,
768}
769
770impl fmt::Display for Appearance {
771 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
772 match self {
773 Self::Auto => f.write_str("auto"),
774 Self::BaseSelect => f.write_str("base-select"),
775 Self::Button => f.write_str("button"),
776 Self::Checkbox => f.write_str("checkbox"),
777 Self::Listbox => f.write_str("listbox"),
778 Self::Menulist => f.write_str("menulist"),
779 Self::MenulistButton => f.write_str("menulist-button"),
780 Self::Meter => f.write_str("meter"),
781 Self::None => f.write_str("none"),
782 Self::ProgressBar => f.write_str("progress-bar"),
783 Self::Radio => f.write_str("radio"),
784 Self::Searchfield => f.write_str("searchfield"),
785 Self::Textarea => f.write_str("textarea"),
786 Self::Textfield => f.write_str("textfield"),
787 }
788 }
789}
790
791#[derive(Debug, Clone, PartialEq)]
793#[non_exhaustive]
794pub enum AspectRatio {
795 Auto,
797 Number(f64),
799 Raw(Raw),
801}
802
803impl fmt::Display for AspectRatio {
804 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
805 match self {
806 Self::Auto => f.write_str("auto"),
807 Self::Number(v) => v.fmt(f),
808 Self::Raw(v) => v.fmt(f),
809 }
810 }
811}
812
813impl From<f64> for AspectRatio {
814 fn from(v: f64) -> Self {
815 Self::Number(v)
816 }
817}
818
819impl From<i32> for AspectRatio {
820 fn from(v: i32) -> Self {
821 Self::Number(f64::from(v))
822 }
823}
824
825impl From<Raw> for AspectRatio {
826 fn from(v: Raw) -> Self {
827 Self::Raw(v)
828 }
829}
830
831#[derive(Debug, Clone, PartialEq)]
833#[non_exhaustive]
834pub enum BackdropFilter {
835 None,
837 Url(Url),
839 Raw(Raw),
841}
842
843impl fmt::Display for BackdropFilter {
844 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
845 match self {
846 Self::None => f.write_str("none"),
847 Self::Url(v) => v.fmt(f),
848 Self::Raw(v) => v.fmt(f),
849 }
850 }
851}
852
853impl From<Url> for BackdropFilter {
854 fn from(v: Url) -> Self {
855 Self::Url(v)
856 }
857}
858
859impl From<Raw> for BackdropFilter {
860 fn from(v: Raw) -> Self {
861 Self::Raw(v)
862 }
863}
864
865#[derive(Debug, Clone, PartialEq)]
867#[non_exhaustive]
868pub enum BackfaceVisibility {
869 Hidden,
871 Visible,
873}
874
875impl fmt::Display for BackfaceVisibility {
876 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
877 match self {
878 Self::Hidden => f.write_str("hidden"),
879 Self::Visible => f.write_str("visible"),
880 }
881 }
882}
883
884#[derive(Debug, Clone, PartialEq)]
886#[non_exhaustive]
887pub enum Background {
888 Raw(Raw),
890}
891
892impl fmt::Display for Background {
893 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
894 match self {
895 Self::Raw(v) => v.fmt(f),
896 }
897 }
898}
899
900impl From<Raw> for Background {
901 fn from(v: Raw) -> Self {
902 Self::Raw(v)
903 }
904}
905
906#[derive(Debug, Clone, PartialEq)]
908#[non_exhaustive]
909pub enum BackgroundAttachment {
910 Fixed,
912 Local,
914 Scroll,
916 Raw(Raw),
918}
919
920impl fmt::Display for BackgroundAttachment {
921 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
922 match self {
923 Self::Fixed => f.write_str("fixed"),
924 Self::Local => f.write_str("local"),
925 Self::Scroll => f.write_str("scroll"),
926 Self::Raw(v) => v.fmt(f),
927 }
928 }
929}
930
931impl From<Raw> for BackgroundAttachment {
932 fn from(v: Raw) -> Self {
933 Self::Raw(v)
934 }
935}
936
937#[derive(Debug, Clone, PartialEq)]
939#[non_exhaustive]
940pub enum BackgroundBlendMode {
941 Color,
943 ColorBurn,
945 ColorDodge,
947 Darken,
949 Difference,
951 Exclusion,
953 HardLight,
955 Hue,
957 Lighten,
959 Luminosity,
961 Multiply,
963 Normal,
965 Overlay,
967 Saturation,
969 Screen,
971 SoftLight,
973 Raw(Raw),
975}
976
977impl fmt::Display for BackgroundBlendMode {
978 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
979 match self {
980 Self::Color => f.write_str("color"),
981 Self::ColorBurn => f.write_str("color-burn"),
982 Self::ColorDodge => f.write_str("color-dodge"),
983 Self::Darken => f.write_str("darken"),
984 Self::Difference => f.write_str("difference"),
985 Self::Exclusion => f.write_str("exclusion"),
986 Self::HardLight => f.write_str("hard-light"),
987 Self::Hue => f.write_str("hue"),
988 Self::Lighten => f.write_str("lighten"),
989 Self::Luminosity => f.write_str("luminosity"),
990 Self::Multiply => f.write_str("multiply"),
991 Self::Normal => f.write_str("normal"),
992 Self::Overlay => f.write_str("overlay"),
993 Self::Saturation => f.write_str("saturation"),
994 Self::Screen => f.write_str("screen"),
995 Self::SoftLight => f.write_str("soft-light"),
996 Self::Raw(v) => v.fmt(f),
997 }
998 }
999}
1000
1001impl From<Raw> for BackgroundBlendMode {
1002 fn from(v: Raw) -> Self {
1003 Self::Raw(v)
1004 }
1005}
1006
1007#[derive(Debug, Clone, PartialEq)]
1009#[non_exhaustive]
1010pub enum BackgroundClip {
1011 BorderArea,
1013 BorderBox,
1015 ContentBox,
1017 PaddingBox,
1019 Text,
1021 Raw(Raw),
1023}
1024
1025impl fmt::Display for BackgroundClip {
1026 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1027 match self {
1028 Self::BorderArea => f.write_str("border-area"),
1029 Self::BorderBox => f.write_str("border-box"),
1030 Self::ContentBox => f.write_str("content-box"),
1031 Self::PaddingBox => f.write_str("padding-box"),
1032 Self::Text => f.write_str("text"),
1033 Self::Raw(v) => v.fmt(f),
1034 }
1035 }
1036}
1037
1038impl From<Raw> for BackgroundClip {
1039 fn from(v: Raw) -> Self {
1040 Self::Raw(v)
1041 }
1042}
1043
1044#[derive(Debug, Clone, PartialEq)]
1046#[non_exhaustive]
1047pub enum BackgroundImage {
1048 None,
1050 Url(Url),
1052 Raw(Raw),
1054}
1055
1056impl fmt::Display for BackgroundImage {
1057 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1058 match self {
1059 Self::None => f.write_str("none"),
1060 Self::Url(v) => v.fmt(f),
1061 Self::Raw(v) => v.fmt(f),
1062 }
1063 }
1064}
1065
1066impl From<Url> for BackgroundImage {
1067 fn from(v: Url) -> Self {
1068 Self::Url(v)
1069 }
1070}
1071
1072impl From<Raw> for BackgroundImage {
1073 fn from(v: Raw) -> Self {
1074 Self::Raw(v)
1075 }
1076}
1077
1078#[derive(Debug, Clone, PartialEq)]
1080#[non_exhaustive]
1081pub enum BackgroundOrigin {
1082 BorderBox,
1084 ContentBox,
1086 PaddingBox,
1088 Raw(Raw),
1090}
1091
1092impl fmt::Display for BackgroundOrigin {
1093 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1094 match self {
1095 Self::BorderBox => f.write_str("border-box"),
1096 Self::ContentBox => f.write_str("content-box"),
1097 Self::PaddingBox => f.write_str("padding-box"),
1098 Self::Raw(v) => v.fmt(f),
1099 }
1100 }
1101}
1102
1103impl From<Raw> for BackgroundOrigin {
1104 fn from(v: Raw) -> Self {
1105 Self::Raw(v)
1106 }
1107}
1108
1109#[derive(Debug, Clone, PartialEq)]
1111#[non_exhaustive]
1112pub enum BackgroundPosition {
1113 Bottom,
1115 Center,
1117 Left,
1119 Right,
1121 Top,
1123 Length(Length),
1125 Percentage(Percentage),
1127 Raw(Raw),
1129}
1130
1131impl fmt::Display for BackgroundPosition {
1132 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1133 match self {
1134 Self::Bottom => f.write_str("bottom"),
1135 Self::Center => f.write_str("center"),
1136 Self::Left => f.write_str("left"),
1137 Self::Right => f.write_str("right"),
1138 Self::Top => f.write_str("top"),
1139 Self::Length(v) => v.fmt(f),
1140 Self::Percentage(v) => v.fmt(f),
1141 Self::Raw(v) => v.fmt(f),
1142 }
1143 }
1144}
1145
1146impl From<Length> for BackgroundPosition {
1147 fn from(v: Length) -> Self {
1148 Self::Length(v)
1149 }
1150}
1151
1152impl From<Percentage> for BackgroundPosition {
1153 fn from(v: Percentage) -> Self {
1154 Self::Percentage(v)
1155 }
1156}
1157
1158impl From<Raw> for BackgroundPosition {
1159 fn from(v: Raw) -> Self {
1160 Self::Raw(v)
1161 }
1162}
1163
1164#[derive(Debug, Clone, PartialEq)]
1166#[non_exhaustive]
1167pub enum BackgroundPositionX {
1168 Center,
1170 Left,
1172 Right,
1174 XEnd,
1176 XStart,
1178 Length(Length),
1180 Percentage(Percentage),
1182 Raw(Raw),
1184}
1185
1186impl fmt::Display for BackgroundPositionX {
1187 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1188 match self {
1189 Self::Center => f.write_str("center"),
1190 Self::Left => f.write_str("left"),
1191 Self::Right => f.write_str("right"),
1192 Self::XEnd => f.write_str("x-end"),
1193 Self::XStart => f.write_str("x-start"),
1194 Self::Length(v) => v.fmt(f),
1195 Self::Percentage(v) => v.fmt(f),
1196 Self::Raw(v) => v.fmt(f),
1197 }
1198 }
1199}
1200
1201impl From<Length> for BackgroundPositionX {
1202 fn from(v: Length) -> Self {
1203 Self::Length(v)
1204 }
1205}
1206
1207impl From<Percentage> for BackgroundPositionX {
1208 fn from(v: Percentage) -> Self {
1209 Self::Percentage(v)
1210 }
1211}
1212
1213impl From<Raw> for BackgroundPositionX {
1214 fn from(v: Raw) -> Self {
1215 Self::Raw(v)
1216 }
1217}
1218
1219#[derive(Debug, Clone, PartialEq)]
1221#[non_exhaustive]
1222pub enum BackgroundPositionY {
1223 Bottom,
1225 Center,
1227 Top,
1229 YEnd,
1231 YStart,
1233 Length(Length),
1235 Percentage(Percentage),
1237 Raw(Raw),
1239}
1240
1241impl fmt::Display for BackgroundPositionY {
1242 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1243 match self {
1244 Self::Bottom => f.write_str("bottom"),
1245 Self::Center => f.write_str("center"),
1246 Self::Top => f.write_str("top"),
1247 Self::YEnd => f.write_str("y-end"),
1248 Self::YStart => f.write_str("y-start"),
1249 Self::Length(v) => v.fmt(f),
1250 Self::Percentage(v) => v.fmt(f),
1251 Self::Raw(v) => v.fmt(f),
1252 }
1253 }
1254}
1255
1256impl From<Length> for BackgroundPositionY {
1257 fn from(v: Length) -> Self {
1258 Self::Length(v)
1259 }
1260}
1261
1262impl From<Percentage> for BackgroundPositionY {
1263 fn from(v: Percentage) -> Self {
1264 Self::Percentage(v)
1265 }
1266}
1267
1268impl From<Raw> for BackgroundPositionY {
1269 fn from(v: Raw) -> Self {
1270 Self::Raw(v)
1271 }
1272}
1273
1274#[derive(Debug, Clone, PartialEq)]
1276#[non_exhaustive]
1277pub enum BackgroundRepeat {
1278 NoRepeat,
1280 Repeat,
1282 RepeatX,
1284 RepeatY,
1286 Round,
1288 Space,
1290 Raw(Raw),
1292}
1293
1294impl fmt::Display for BackgroundRepeat {
1295 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1296 match self {
1297 Self::NoRepeat => f.write_str("no-repeat"),
1298 Self::Repeat => f.write_str("repeat"),
1299 Self::RepeatX => f.write_str("repeat-x"),
1300 Self::RepeatY => f.write_str("repeat-y"),
1301 Self::Round => f.write_str("round"),
1302 Self::Space => f.write_str("space"),
1303 Self::Raw(v) => v.fmt(f),
1304 }
1305 }
1306}
1307
1308impl From<Raw> for BackgroundRepeat {
1309 fn from(v: Raw) -> Self {
1310 Self::Raw(v)
1311 }
1312}
1313
1314#[derive(Debug, Clone, PartialEq)]
1316#[non_exhaustive]
1317pub enum BackgroundSize {
1318 Auto,
1320 Contain,
1322 Cover,
1324 Length(Length),
1326 Percentage(Percentage),
1328 Raw(Raw),
1330}
1331
1332impl fmt::Display for BackgroundSize {
1333 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1334 match self {
1335 Self::Auto => f.write_str("auto"),
1336 Self::Contain => f.write_str("contain"),
1337 Self::Cover => f.write_str("cover"),
1338 Self::Length(v) => v.fmt(f),
1339 Self::Percentage(v) => v.fmt(f),
1340 Self::Raw(v) => v.fmt(f),
1341 }
1342 }
1343}
1344
1345impl From<Length> for BackgroundSize {
1346 fn from(v: Length) -> Self {
1347 Self::Length(v)
1348 }
1349}
1350
1351impl From<Percentage> for BackgroundSize {
1352 fn from(v: Percentage) -> Self {
1353 Self::Percentage(v)
1354 }
1355}
1356
1357impl From<Raw> for BackgroundSize {
1358 fn from(v: Raw) -> Self {
1359 Self::Raw(v)
1360 }
1361}
1362
1363#[derive(Debug, Clone, PartialEq)]
1365#[non_exhaustive]
1366pub enum BaselineShift {
1367 Baseline,
1369 Sub,
1371 Super,
1373 Length(Length),
1375 Percentage(Percentage),
1377}
1378
1379impl fmt::Display for BaselineShift {
1380 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1381 match self {
1382 Self::Baseline => f.write_str("baseline"),
1383 Self::Sub => f.write_str("sub"),
1384 Self::Super => f.write_str("super"),
1385 Self::Length(v) => v.fmt(f),
1386 Self::Percentage(v) => v.fmt(f),
1387 }
1388 }
1389}
1390
1391impl From<Length> for BaselineShift {
1392 fn from(v: Length) -> Self {
1393 Self::Length(v)
1394 }
1395}
1396
1397impl From<Percentage> for BaselineShift {
1398 fn from(v: Percentage) -> Self {
1399 Self::Percentage(v)
1400 }
1401}
1402
1403#[derive(Debug, Clone, PartialEq)]
1405#[non_exhaustive]
1406pub enum BaselineSource {
1407 Auto,
1409 First,
1411 Last,
1413}
1414
1415impl fmt::Display for BaselineSource {
1416 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1417 match self {
1418 Self::Auto => f.write_str("auto"),
1419 Self::First => f.write_str("first"),
1420 Self::Last => f.write_str("last"),
1421 }
1422 }
1423}
1424
1425#[derive(Debug, Clone, PartialEq)]
1427#[non_exhaustive]
1428pub enum BlockSize {
1429 Auto,
1431 FitContent,
1433 MaxContent,
1435 MinContent,
1437 Length(Length),
1439 Percentage(Percentage),
1441 Raw(Raw),
1443}
1444
1445impl fmt::Display for BlockSize {
1446 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1447 match self {
1448 Self::Auto => f.write_str("auto"),
1449 Self::FitContent => f.write_str("fit-content"),
1450 Self::MaxContent => f.write_str("max-content"),
1451 Self::MinContent => f.write_str("min-content"),
1452 Self::Length(v) => v.fmt(f),
1453 Self::Percentage(v) => v.fmt(f),
1454 Self::Raw(v) => v.fmt(f),
1455 }
1456 }
1457}
1458
1459impl From<Length> for BlockSize {
1460 fn from(v: Length) -> Self {
1461 Self::Length(v)
1462 }
1463}
1464
1465impl From<Percentage> for BlockSize {
1466 fn from(v: Percentage) -> Self {
1467 Self::Percentage(v)
1468 }
1469}
1470
1471impl From<Raw> for BlockSize {
1472 fn from(v: Raw) -> Self {
1473 Self::Raw(v)
1474 }
1475}
1476
1477#[derive(Debug, Clone, PartialEq)]
1479#[non_exhaustive]
1480pub enum Border {
1481 Dashed,
1483 Dotted,
1485 Double,
1487 Groove,
1489 Hidden,
1491 Inset,
1493 Medium,
1495 None,
1497 Outset,
1499 Ridge,
1501 Solid,
1503 Thick,
1505 Thin,
1507 Length(Length),
1509 Color(Color),
1511 Raw(Raw),
1513}
1514
1515impl fmt::Display for Border {
1516 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1517 match self {
1518 Self::Dashed => f.write_str("dashed"),
1519 Self::Dotted => f.write_str("dotted"),
1520 Self::Double => f.write_str("double"),
1521 Self::Groove => f.write_str("groove"),
1522 Self::Hidden => f.write_str("hidden"),
1523 Self::Inset => f.write_str("inset"),
1524 Self::Medium => f.write_str("medium"),
1525 Self::None => f.write_str("none"),
1526 Self::Outset => f.write_str("outset"),
1527 Self::Ridge => f.write_str("ridge"),
1528 Self::Solid => f.write_str("solid"),
1529 Self::Thick => f.write_str("thick"),
1530 Self::Thin => f.write_str("thin"),
1531 Self::Length(v) => v.fmt(f),
1532 Self::Color(v) => v.fmt(f),
1533 Self::Raw(v) => v.fmt(f),
1534 }
1535 }
1536}
1537
1538impl From<Length> for Border {
1539 fn from(v: Length) -> Self {
1540 Self::Length(v)
1541 }
1542}
1543
1544impl From<Color> for Border {
1545 fn from(v: Color) -> Self {
1546 Self::Color(v)
1547 }
1548}
1549
1550impl From<Raw> for Border {
1551 fn from(v: Raw) -> Self {
1552 Self::Raw(v)
1553 }
1554}
1555
1556#[derive(Debug, Clone, PartialEq)]
1558#[non_exhaustive]
1559pub enum BorderBlock {
1560 Dashed,
1562 Dotted,
1564 Double,
1566 Groove,
1568 Hidden,
1570 Inset,
1572 Medium,
1574 None,
1576 Outset,
1578 Ridge,
1580 Solid,
1582 Thick,
1584 Thin,
1586 Length(Length),
1588 Color(Color),
1590 Raw(Raw),
1592}
1593
1594impl fmt::Display for BorderBlock {
1595 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1596 match self {
1597 Self::Dashed => f.write_str("dashed"),
1598 Self::Dotted => f.write_str("dotted"),
1599 Self::Double => f.write_str("double"),
1600 Self::Groove => f.write_str("groove"),
1601 Self::Hidden => f.write_str("hidden"),
1602 Self::Inset => f.write_str("inset"),
1603 Self::Medium => f.write_str("medium"),
1604 Self::None => f.write_str("none"),
1605 Self::Outset => f.write_str("outset"),
1606 Self::Ridge => f.write_str("ridge"),
1607 Self::Solid => f.write_str("solid"),
1608 Self::Thick => f.write_str("thick"),
1609 Self::Thin => f.write_str("thin"),
1610 Self::Length(v) => v.fmt(f),
1611 Self::Color(v) => v.fmt(f),
1612 Self::Raw(v) => v.fmt(f),
1613 }
1614 }
1615}
1616
1617impl From<Length> for BorderBlock {
1618 fn from(v: Length) -> Self {
1619 Self::Length(v)
1620 }
1621}
1622
1623impl From<Color> for BorderBlock {
1624 fn from(v: Color) -> Self {
1625 Self::Color(v)
1626 }
1627}
1628
1629impl From<Raw> for BorderBlock {
1630 fn from(v: Raw) -> Self {
1631 Self::Raw(v)
1632 }
1633}
1634
1635#[derive(Debug, Clone, PartialEq)]
1637#[non_exhaustive]
1638pub enum BorderBlockColor {
1639 Color(Color),
1641 Raw(Raw),
1643}
1644
1645impl fmt::Display for BorderBlockColor {
1646 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1647 match self {
1648 Self::Color(v) => v.fmt(f),
1649 Self::Raw(v) => v.fmt(f),
1650 }
1651 }
1652}
1653
1654impl From<Color> for BorderBlockColor {
1655 fn from(v: Color) -> Self {
1656 Self::Color(v)
1657 }
1658}
1659
1660impl From<Raw> for BorderBlockColor {
1661 fn from(v: Raw) -> Self {
1662 Self::Raw(v)
1663 }
1664}
1665
1666#[derive(Debug, Clone, PartialEq)]
1668#[non_exhaustive]
1669pub enum BorderBlockEnd {
1670 Dashed,
1672 Dotted,
1674 Double,
1676 Groove,
1678 Hidden,
1680 Inset,
1682 Medium,
1684 None,
1686 Outset,
1688 Ridge,
1690 Solid,
1692 Thick,
1694 Thin,
1696 Length(Length),
1698 Color(Color),
1700 Raw(Raw),
1702}
1703
1704impl fmt::Display for BorderBlockEnd {
1705 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1706 match self {
1707 Self::Dashed => f.write_str("dashed"),
1708 Self::Dotted => f.write_str("dotted"),
1709 Self::Double => f.write_str("double"),
1710 Self::Groove => f.write_str("groove"),
1711 Self::Hidden => f.write_str("hidden"),
1712 Self::Inset => f.write_str("inset"),
1713 Self::Medium => f.write_str("medium"),
1714 Self::None => f.write_str("none"),
1715 Self::Outset => f.write_str("outset"),
1716 Self::Ridge => f.write_str("ridge"),
1717 Self::Solid => f.write_str("solid"),
1718 Self::Thick => f.write_str("thick"),
1719 Self::Thin => f.write_str("thin"),
1720 Self::Length(v) => v.fmt(f),
1721 Self::Color(v) => v.fmt(f),
1722 Self::Raw(v) => v.fmt(f),
1723 }
1724 }
1725}
1726
1727impl From<Length> for BorderBlockEnd {
1728 fn from(v: Length) -> Self {
1729 Self::Length(v)
1730 }
1731}
1732
1733impl From<Color> for BorderBlockEnd {
1734 fn from(v: Color) -> Self {
1735 Self::Color(v)
1736 }
1737}
1738
1739impl From<Raw> for BorderBlockEnd {
1740 fn from(v: Raw) -> Self {
1741 Self::Raw(v)
1742 }
1743}
1744
1745#[derive(Debug, Clone, PartialEq)]
1747#[non_exhaustive]
1748pub enum BorderBlockEndStyle {
1749 Dashed,
1751 Dotted,
1753 Double,
1755 Groove,
1757 Hidden,
1759 Inset,
1761 None,
1763 Outset,
1765 Ridge,
1767 Solid,
1769}
1770
1771impl fmt::Display for BorderBlockEndStyle {
1772 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1773 match self {
1774 Self::Dashed => f.write_str("dashed"),
1775 Self::Dotted => f.write_str("dotted"),
1776 Self::Double => f.write_str("double"),
1777 Self::Groove => f.write_str("groove"),
1778 Self::Hidden => f.write_str("hidden"),
1779 Self::Inset => f.write_str("inset"),
1780 Self::None => f.write_str("none"),
1781 Self::Outset => f.write_str("outset"),
1782 Self::Ridge => f.write_str("ridge"),
1783 Self::Solid => f.write_str("solid"),
1784 }
1785 }
1786}
1787
1788#[derive(Debug, Clone, PartialEq)]
1790#[non_exhaustive]
1791pub enum BorderBlockEndWidth {
1792 Medium,
1794 Thick,
1796 Thin,
1798 Length(Length),
1800}
1801
1802impl fmt::Display for BorderBlockEndWidth {
1803 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1804 match self {
1805 Self::Medium => f.write_str("medium"),
1806 Self::Thick => f.write_str("thick"),
1807 Self::Thin => f.write_str("thin"),
1808 Self::Length(v) => v.fmt(f),
1809 }
1810 }
1811}
1812
1813impl From<Length> for BorderBlockEndWidth {
1814 fn from(v: Length) -> Self {
1815 Self::Length(v)
1816 }
1817}
1818
1819#[derive(Debug, Clone, PartialEq)]
1821#[non_exhaustive]
1822pub enum BorderBlockStart {
1823 Dashed,
1825 Dotted,
1827 Double,
1829 Groove,
1831 Hidden,
1833 Inset,
1835 Medium,
1837 None,
1839 Outset,
1841 Ridge,
1843 Solid,
1845 Thick,
1847 Thin,
1849 Length(Length),
1851 Color(Color),
1853 Raw(Raw),
1855}
1856
1857impl fmt::Display for BorderBlockStart {
1858 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1859 match self {
1860 Self::Dashed => f.write_str("dashed"),
1861 Self::Dotted => f.write_str("dotted"),
1862 Self::Double => f.write_str("double"),
1863 Self::Groove => f.write_str("groove"),
1864 Self::Hidden => f.write_str("hidden"),
1865 Self::Inset => f.write_str("inset"),
1866 Self::Medium => f.write_str("medium"),
1867 Self::None => f.write_str("none"),
1868 Self::Outset => f.write_str("outset"),
1869 Self::Ridge => f.write_str("ridge"),
1870 Self::Solid => f.write_str("solid"),
1871 Self::Thick => f.write_str("thick"),
1872 Self::Thin => f.write_str("thin"),
1873 Self::Length(v) => v.fmt(f),
1874 Self::Color(v) => v.fmt(f),
1875 Self::Raw(v) => v.fmt(f),
1876 }
1877 }
1878}
1879
1880impl From<Length> for BorderBlockStart {
1881 fn from(v: Length) -> Self {
1882 Self::Length(v)
1883 }
1884}
1885
1886impl From<Color> for BorderBlockStart {
1887 fn from(v: Color) -> Self {
1888 Self::Color(v)
1889 }
1890}
1891
1892impl From<Raw> for BorderBlockStart {
1893 fn from(v: Raw) -> Self {
1894 Self::Raw(v)
1895 }
1896}
1897
1898#[derive(Debug, Clone, PartialEq)]
1900#[non_exhaustive]
1901pub enum BorderBlockStartStyle {
1902 Dashed,
1904 Dotted,
1906 Double,
1908 Groove,
1910 Hidden,
1912 Inset,
1914 None,
1916 Outset,
1918 Ridge,
1920 Solid,
1922}
1923
1924impl fmt::Display for BorderBlockStartStyle {
1925 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1926 match self {
1927 Self::Dashed => f.write_str("dashed"),
1928 Self::Dotted => f.write_str("dotted"),
1929 Self::Double => f.write_str("double"),
1930 Self::Groove => f.write_str("groove"),
1931 Self::Hidden => f.write_str("hidden"),
1932 Self::Inset => f.write_str("inset"),
1933 Self::None => f.write_str("none"),
1934 Self::Outset => f.write_str("outset"),
1935 Self::Ridge => f.write_str("ridge"),
1936 Self::Solid => f.write_str("solid"),
1937 }
1938 }
1939}
1940
1941#[derive(Debug, Clone, PartialEq)]
1943#[non_exhaustive]
1944pub enum BorderBlockStartWidth {
1945 Medium,
1947 Thick,
1949 Thin,
1951 Length(Length),
1953}
1954
1955impl fmt::Display for BorderBlockStartWidth {
1956 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1957 match self {
1958 Self::Medium => f.write_str("medium"),
1959 Self::Thick => f.write_str("thick"),
1960 Self::Thin => f.write_str("thin"),
1961 Self::Length(v) => v.fmt(f),
1962 }
1963 }
1964}
1965
1966impl From<Length> for BorderBlockStartWidth {
1967 fn from(v: Length) -> Self {
1968 Self::Length(v)
1969 }
1970}
1971
1972#[derive(Debug, Clone, PartialEq)]
1974#[non_exhaustive]
1975pub enum BorderBlockStyle {
1976 Dashed,
1978 Dotted,
1980 Double,
1982 Groove,
1984 Hidden,
1986 Inset,
1988 None,
1990 Outset,
1992 Ridge,
1994 Solid,
1996 Raw(Raw),
1998}
1999
2000impl fmt::Display for BorderBlockStyle {
2001 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2002 match self {
2003 Self::Dashed => f.write_str("dashed"),
2004 Self::Dotted => f.write_str("dotted"),
2005 Self::Double => f.write_str("double"),
2006 Self::Groove => f.write_str("groove"),
2007 Self::Hidden => f.write_str("hidden"),
2008 Self::Inset => f.write_str("inset"),
2009 Self::None => f.write_str("none"),
2010 Self::Outset => f.write_str("outset"),
2011 Self::Ridge => f.write_str("ridge"),
2012 Self::Solid => f.write_str("solid"),
2013 Self::Raw(v) => v.fmt(f),
2014 }
2015 }
2016}
2017
2018impl From<Raw> for BorderBlockStyle {
2019 fn from(v: Raw) -> Self {
2020 Self::Raw(v)
2021 }
2022}
2023
2024#[derive(Debug, Clone, PartialEq)]
2026#[non_exhaustive]
2027pub enum BorderBlockWidth {
2028 Medium,
2030 Thick,
2032 Thin,
2034 Length(Length),
2036 Raw(Raw),
2038}
2039
2040impl fmt::Display for BorderBlockWidth {
2041 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2042 match self {
2043 Self::Medium => f.write_str("medium"),
2044 Self::Thick => f.write_str("thick"),
2045 Self::Thin => f.write_str("thin"),
2046 Self::Length(v) => v.fmt(f),
2047 Self::Raw(v) => v.fmt(f),
2048 }
2049 }
2050}
2051
2052impl From<Length> for BorderBlockWidth {
2053 fn from(v: Length) -> Self {
2054 Self::Length(v)
2055 }
2056}
2057
2058impl From<Raw> for BorderBlockWidth {
2059 fn from(v: Raw) -> Self {
2060 Self::Raw(v)
2061 }
2062}
2063
2064#[derive(Debug, Clone, PartialEq)]
2066#[non_exhaustive]
2067pub enum BorderBottom {
2068 Dashed,
2070 Dotted,
2072 Double,
2074 Groove,
2076 Hidden,
2078 Inset,
2080 Medium,
2082 None,
2084 Outset,
2086 Ridge,
2088 Solid,
2090 Thick,
2092 Thin,
2094 Length(Length),
2096 Color(Color),
2098 Raw(Raw),
2100}
2101
2102impl fmt::Display for BorderBottom {
2103 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2104 match self {
2105 Self::Dashed => f.write_str("dashed"),
2106 Self::Dotted => f.write_str("dotted"),
2107 Self::Double => f.write_str("double"),
2108 Self::Groove => f.write_str("groove"),
2109 Self::Hidden => f.write_str("hidden"),
2110 Self::Inset => f.write_str("inset"),
2111 Self::Medium => f.write_str("medium"),
2112 Self::None => f.write_str("none"),
2113 Self::Outset => f.write_str("outset"),
2114 Self::Ridge => f.write_str("ridge"),
2115 Self::Solid => f.write_str("solid"),
2116 Self::Thick => f.write_str("thick"),
2117 Self::Thin => f.write_str("thin"),
2118 Self::Length(v) => v.fmt(f),
2119 Self::Color(v) => v.fmt(f),
2120 Self::Raw(v) => v.fmt(f),
2121 }
2122 }
2123}
2124
2125impl From<Length> for BorderBottom {
2126 fn from(v: Length) -> Self {
2127 Self::Length(v)
2128 }
2129}
2130
2131impl From<Color> for BorderBottom {
2132 fn from(v: Color) -> Self {
2133 Self::Color(v)
2134 }
2135}
2136
2137impl From<Raw> for BorderBottom {
2138 fn from(v: Raw) -> Self {
2139 Self::Raw(v)
2140 }
2141}
2142
2143#[derive(Debug, Clone, PartialEq)]
2145#[non_exhaustive]
2146pub enum BorderBottomLeftRadius {
2147 Length(Length),
2149 Percentage(Percentage),
2151 Raw(Raw),
2153}
2154
2155impl fmt::Display for BorderBottomLeftRadius {
2156 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2157 match self {
2158 Self::Length(v) => v.fmt(f),
2159 Self::Percentage(v) => v.fmt(f),
2160 Self::Raw(v) => v.fmt(f),
2161 }
2162 }
2163}
2164
2165impl From<Length> for BorderBottomLeftRadius {
2166 fn from(v: Length) -> Self {
2167 Self::Length(v)
2168 }
2169}
2170
2171impl From<Percentage> for BorderBottomLeftRadius {
2172 fn from(v: Percentage) -> Self {
2173 Self::Percentage(v)
2174 }
2175}
2176
2177impl From<Raw> for BorderBottomLeftRadius {
2178 fn from(v: Raw) -> Self {
2179 Self::Raw(v)
2180 }
2181}
2182
2183#[derive(Debug, Clone, PartialEq)]
2185#[non_exhaustive]
2186pub enum BorderBottomRightRadius {
2187 Length(Length),
2189 Percentage(Percentage),
2191 Raw(Raw),
2193}
2194
2195impl fmt::Display for BorderBottomRightRadius {
2196 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2197 match self {
2198 Self::Length(v) => v.fmt(f),
2199 Self::Percentage(v) => v.fmt(f),
2200 Self::Raw(v) => v.fmt(f),
2201 }
2202 }
2203}
2204
2205impl From<Length> for BorderBottomRightRadius {
2206 fn from(v: Length) -> Self {
2207 Self::Length(v)
2208 }
2209}
2210
2211impl From<Percentage> for BorderBottomRightRadius {
2212 fn from(v: Percentage) -> Self {
2213 Self::Percentage(v)
2214 }
2215}
2216
2217impl From<Raw> for BorderBottomRightRadius {
2218 fn from(v: Raw) -> Self {
2219 Self::Raw(v)
2220 }
2221}
2222
2223#[derive(Debug, Clone, PartialEq)]
2225#[non_exhaustive]
2226pub enum BorderBottomStyle {
2227 Dashed,
2229 Dotted,
2231 Double,
2233 Groove,
2235 Hidden,
2237 Inset,
2239 None,
2241 Outset,
2243 Ridge,
2245 Solid,
2247}
2248
2249impl fmt::Display for BorderBottomStyle {
2250 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2251 match self {
2252 Self::Dashed => f.write_str("dashed"),
2253 Self::Dotted => f.write_str("dotted"),
2254 Self::Double => f.write_str("double"),
2255 Self::Groove => f.write_str("groove"),
2256 Self::Hidden => f.write_str("hidden"),
2257 Self::Inset => f.write_str("inset"),
2258 Self::None => f.write_str("none"),
2259 Self::Outset => f.write_str("outset"),
2260 Self::Ridge => f.write_str("ridge"),
2261 Self::Solid => f.write_str("solid"),
2262 }
2263 }
2264}
2265
2266#[derive(Debug, Clone, PartialEq)]
2268#[non_exhaustive]
2269pub enum BorderBottomWidth {
2270 Medium,
2272 Thick,
2274 Thin,
2276 Length(Length),
2278}
2279
2280impl fmt::Display for BorderBottomWidth {
2281 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2282 match self {
2283 Self::Medium => f.write_str("medium"),
2284 Self::Thick => f.write_str("thick"),
2285 Self::Thin => f.write_str("thin"),
2286 Self::Length(v) => v.fmt(f),
2287 }
2288 }
2289}
2290
2291impl From<Length> for BorderBottomWidth {
2292 fn from(v: Length) -> Self {
2293 Self::Length(v)
2294 }
2295}
2296
2297#[derive(Debug, Clone, PartialEq)]
2299#[non_exhaustive]
2300pub enum BorderCollapse {
2301 Collapse,
2303 Separate,
2305}
2306
2307impl fmt::Display for BorderCollapse {
2308 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2309 match self {
2310 Self::Collapse => f.write_str("collapse"),
2311 Self::Separate => f.write_str("separate"),
2312 }
2313 }
2314}
2315
2316#[derive(Debug, Clone, PartialEq)]
2318#[non_exhaustive]
2319pub enum BorderColor {
2320 Color(Color),
2322 Raw(Raw),
2324}
2325
2326impl fmt::Display for BorderColor {
2327 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2328 match self {
2329 Self::Color(v) => v.fmt(f),
2330 Self::Raw(v) => v.fmt(f),
2331 }
2332 }
2333}
2334
2335impl From<Color> for BorderColor {
2336 fn from(v: Color) -> Self {
2337 Self::Color(v)
2338 }
2339}
2340
2341impl From<Raw> for BorderColor {
2342 fn from(v: Raw) -> Self {
2343 Self::Raw(v)
2344 }
2345}
2346
2347#[derive(Debug, Clone, PartialEq)]
2349#[non_exhaustive]
2350pub enum BorderEndEndRadius {
2351 Length(Length),
2353 Percentage(Percentage),
2355 Raw(Raw),
2357}
2358
2359impl fmt::Display for BorderEndEndRadius {
2360 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2361 match self {
2362 Self::Length(v) => v.fmt(f),
2363 Self::Percentage(v) => v.fmt(f),
2364 Self::Raw(v) => v.fmt(f),
2365 }
2366 }
2367}
2368
2369impl From<Length> for BorderEndEndRadius {
2370 fn from(v: Length) -> Self {
2371 Self::Length(v)
2372 }
2373}
2374
2375impl From<Percentage> for BorderEndEndRadius {
2376 fn from(v: Percentage) -> Self {
2377 Self::Percentage(v)
2378 }
2379}
2380
2381impl From<Raw> for BorderEndEndRadius {
2382 fn from(v: Raw) -> Self {
2383 Self::Raw(v)
2384 }
2385}
2386
2387#[derive(Debug, Clone, PartialEq)]
2389#[non_exhaustive]
2390pub enum BorderEndStartRadius {
2391 Length(Length),
2393 Percentage(Percentage),
2395 Raw(Raw),
2397}
2398
2399impl fmt::Display for BorderEndStartRadius {
2400 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2401 match self {
2402 Self::Length(v) => v.fmt(f),
2403 Self::Percentage(v) => v.fmt(f),
2404 Self::Raw(v) => v.fmt(f),
2405 }
2406 }
2407}
2408
2409impl From<Length> for BorderEndStartRadius {
2410 fn from(v: Length) -> Self {
2411 Self::Length(v)
2412 }
2413}
2414
2415impl From<Percentage> for BorderEndStartRadius {
2416 fn from(v: Percentage) -> Self {
2417 Self::Percentage(v)
2418 }
2419}
2420
2421impl From<Raw> for BorderEndStartRadius {
2422 fn from(v: Raw) -> Self {
2423 Self::Raw(v)
2424 }
2425}
2426
2427#[derive(Debug, Clone, PartialEq)]
2429#[non_exhaustive]
2430pub enum BorderImage {
2431 None,
2433 Repeat,
2435 Round,
2437 Space,
2439 Stretch,
2441 Url(Url),
2443 Raw(Raw),
2445}
2446
2447impl fmt::Display for BorderImage {
2448 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2449 match self {
2450 Self::None => f.write_str("none"),
2451 Self::Repeat => f.write_str("repeat"),
2452 Self::Round => f.write_str("round"),
2453 Self::Space => f.write_str("space"),
2454 Self::Stretch => f.write_str("stretch"),
2455 Self::Url(v) => v.fmt(f),
2456 Self::Raw(v) => v.fmt(f),
2457 }
2458 }
2459}
2460
2461impl From<Url> for BorderImage {
2462 fn from(v: Url) -> Self {
2463 Self::Url(v)
2464 }
2465}
2466
2467impl From<Raw> for BorderImage {
2468 fn from(v: Raw) -> Self {
2469 Self::Raw(v)
2470 }
2471}
2472
2473#[derive(Debug, Clone, PartialEq)]
2475#[non_exhaustive]
2476pub enum BorderImageOutset {
2477 Length(Length),
2479 Number(f64),
2481 Raw(Raw),
2483}
2484
2485impl fmt::Display for BorderImageOutset {
2486 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2487 match self {
2488 Self::Length(v) => v.fmt(f),
2489 Self::Number(v) => v.fmt(f),
2490 Self::Raw(v) => v.fmt(f),
2491 }
2492 }
2493}
2494
2495impl From<Length> for BorderImageOutset {
2496 fn from(v: Length) -> Self {
2497 Self::Length(v)
2498 }
2499}
2500
2501impl From<f64> for BorderImageOutset {
2502 fn from(v: f64) -> Self {
2503 Self::Number(v)
2504 }
2505}
2506
2507impl From<i32> for BorderImageOutset {
2508 fn from(v: i32) -> Self {
2509 Self::Number(f64::from(v))
2510 }
2511}
2512
2513impl From<Raw> for BorderImageOutset {
2514 fn from(v: Raw) -> Self {
2515 Self::Raw(v)
2516 }
2517}
2518
2519#[derive(Debug, Clone, PartialEq)]
2521#[non_exhaustive]
2522pub enum BorderImageRepeat {
2523 Repeat,
2525 Round,
2527 Space,
2529 Stretch,
2531 Raw(Raw),
2533}
2534
2535impl fmt::Display for BorderImageRepeat {
2536 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2537 match self {
2538 Self::Repeat => f.write_str("repeat"),
2539 Self::Round => f.write_str("round"),
2540 Self::Space => f.write_str("space"),
2541 Self::Stretch => f.write_str("stretch"),
2542 Self::Raw(v) => v.fmt(f),
2543 }
2544 }
2545}
2546
2547impl From<Raw> for BorderImageRepeat {
2548 fn from(v: Raw) -> Self {
2549 Self::Raw(v)
2550 }
2551}
2552
2553#[derive(Debug, Clone, PartialEq)]
2555#[non_exhaustive]
2556pub enum BorderImageSlice {
2557 Raw(Raw),
2559}
2560
2561impl fmt::Display for BorderImageSlice {
2562 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2563 match self {
2564 Self::Raw(v) => v.fmt(f),
2565 }
2566 }
2567}
2568
2569impl From<Raw> for BorderImageSlice {
2570 fn from(v: Raw) -> Self {
2571 Self::Raw(v)
2572 }
2573}
2574
2575#[derive(Debug, Clone, PartialEq)]
2577#[non_exhaustive]
2578pub enum BorderImageSource {
2579 None,
2581 Url(Url),
2583 Raw(Raw),
2585}
2586
2587impl fmt::Display for BorderImageSource {
2588 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2589 match self {
2590 Self::None => f.write_str("none"),
2591 Self::Url(v) => v.fmt(f),
2592 Self::Raw(v) => v.fmt(f),
2593 }
2594 }
2595}
2596
2597impl From<Url> for BorderImageSource {
2598 fn from(v: Url) -> Self {
2599 Self::Url(v)
2600 }
2601}
2602
2603impl From<Raw> for BorderImageSource {
2604 fn from(v: Raw) -> Self {
2605 Self::Raw(v)
2606 }
2607}
2608
2609#[derive(Debug, Clone, PartialEq)]
2611#[non_exhaustive]
2612pub enum BorderImageWidth {
2613 Auto,
2615 Length(Length),
2617 Percentage(Percentage),
2619 Number(f64),
2621 Raw(Raw),
2623}
2624
2625impl fmt::Display for BorderImageWidth {
2626 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2627 match self {
2628 Self::Auto => f.write_str("auto"),
2629 Self::Length(v) => v.fmt(f),
2630 Self::Percentage(v) => v.fmt(f),
2631 Self::Number(v) => v.fmt(f),
2632 Self::Raw(v) => v.fmt(f),
2633 }
2634 }
2635}
2636
2637impl From<Length> for BorderImageWidth {
2638 fn from(v: Length) -> Self {
2639 Self::Length(v)
2640 }
2641}
2642
2643impl From<Percentage> for BorderImageWidth {
2644 fn from(v: Percentage) -> Self {
2645 Self::Percentage(v)
2646 }
2647}
2648
2649impl From<f64> for BorderImageWidth {
2650 fn from(v: f64) -> Self {
2651 Self::Number(v)
2652 }
2653}
2654
2655impl From<i32> for BorderImageWidth {
2656 fn from(v: i32) -> Self {
2657 Self::Number(f64::from(v))
2658 }
2659}
2660
2661impl From<Raw> for BorderImageWidth {
2662 fn from(v: Raw) -> Self {
2663 Self::Raw(v)
2664 }
2665}
2666
2667#[derive(Debug, Clone, PartialEq)]
2669#[non_exhaustive]
2670pub enum BorderInline {
2671 Dashed,
2673 Dotted,
2675 Double,
2677 Groove,
2679 Hidden,
2681 Inset,
2683 Medium,
2685 None,
2687 Outset,
2689 Ridge,
2691 Solid,
2693 Thick,
2695 Thin,
2697 Length(Length),
2699 Color(Color),
2701 Raw(Raw),
2703}
2704
2705impl fmt::Display for BorderInline {
2706 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2707 match self {
2708 Self::Dashed => f.write_str("dashed"),
2709 Self::Dotted => f.write_str("dotted"),
2710 Self::Double => f.write_str("double"),
2711 Self::Groove => f.write_str("groove"),
2712 Self::Hidden => f.write_str("hidden"),
2713 Self::Inset => f.write_str("inset"),
2714 Self::Medium => f.write_str("medium"),
2715 Self::None => f.write_str("none"),
2716 Self::Outset => f.write_str("outset"),
2717 Self::Ridge => f.write_str("ridge"),
2718 Self::Solid => f.write_str("solid"),
2719 Self::Thick => f.write_str("thick"),
2720 Self::Thin => f.write_str("thin"),
2721 Self::Length(v) => v.fmt(f),
2722 Self::Color(v) => v.fmt(f),
2723 Self::Raw(v) => v.fmt(f),
2724 }
2725 }
2726}
2727
2728impl From<Length> for BorderInline {
2729 fn from(v: Length) -> Self {
2730 Self::Length(v)
2731 }
2732}
2733
2734impl From<Color> for BorderInline {
2735 fn from(v: Color) -> Self {
2736 Self::Color(v)
2737 }
2738}
2739
2740impl From<Raw> for BorderInline {
2741 fn from(v: Raw) -> Self {
2742 Self::Raw(v)
2743 }
2744}
2745
2746#[derive(Debug, Clone, PartialEq)]
2748#[non_exhaustive]
2749pub enum BorderInlineColor {
2750 Color(Color),
2752 Raw(Raw),
2754}
2755
2756impl fmt::Display for BorderInlineColor {
2757 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2758 match self {
2759 Self::Color(v) => v.fmt(f),
2760 Self::Raw(v) => v.fmt(f),
2761 }
2762 }
2763}
2764
2765impl From<Color> for BorderInlineColor {
2766 fn from(v: Color) -> Self {
2767 Self::Color(v)
2768 }
2769}
2770
2771impl From<Raw> for BorderInlineColor {
2772 fn from(v: Raw) -> Self {
2773 Self::Raw(v)
2774 }
2775}
2776
2777#[derive(Debug, Clone, PartialEq)]
2779#[non_exhaustive]
2780pub enum BorderInlineEnd {
2781 Dashed,
2783 Dotted,
2785 Double,
2787 Groove,
2789 Hidden,
2791 Inset,
2793 Medium,
2795 None,
2797 Outset,
2799 Ridge,
2801 Solid,
2803 Thick,
2805 Thin,
2807 Length(Length),
2809 Color(Color),
2811 Raw(Raw),
2813}
2814
2815impl fmt::Display for BorderInlineEnd {
2816 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2817 match self {
2818 Self::Dashed => f.write_str("dashed"),
2819 Self::Dotted => f.write_str("dotted"),
2820 Self::Double => f.write_str("double"),
2821 Self::Groove => f.write_str("groove"),
2822 Self::Hidden => f.write_str("hidden"),
2823 Self::Inset => f.write_str("inset"),
2824 Self::Medium => f.write_str("medium"),
2825 Self::None => f.write_str("none"),
2826 Self::Outset => f.write_str("outset"),
2827 Self::Ridge => f.write_str("ridge"),
2828 Self::Solid => f.write_str("solid"),
2829 Self::Thick => f.write_str("thick"),
2830 Self::Thin => f.write_str("thin"),
2831 Self::Length(v) => v.fmt(f),
2832 Self::Color(v) => v.fmt(f),
2833 Self::Raw(v) => v.fmt(f),
2834 }
2835 }
2836}
2837
2838impl From<Length> for BorderInlineEnd {
2839 fn from(v: Length) -> Self {
2840 Self::Length(v)
2841 }
2842}
2843
2844impl From<Color> for BorderInlineEnd {
2845 fn from(v: Color) -> Self {
2846 Self::Color(v)
2847 }
2848}
2849
2850impl From<Raw> for BorderInlineEnd {
2851 fn from(v: Raw) -> Self {
2852 Self::Raw(v)
2853 }
2854}
2855
2856#[derive(Debug, Clone, PartialEq)]
2858#[non_exhaustive]
2859pub enum BorderInlineEndStyle {
2860 Dashed,
2862 Dotted,
2864 Double,
2866 Groove,
2868 Hidden,
2870 Inset,
2872 None,
2874 Outset,
2876 Ridge,
2878 Solid,
2880}
2881
2882impl fmt::Display for BorderInlineEndStyle {
2883 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2884 match self {
2885 Self::Dashed => f.write_str("dashed"),
2886 Self::Dotted => f.write_str("dotted"),
2887 Self::Double => f.write_str("double"),
2888 Self::Groove => f.write_str("groove"),
2889 Self::Hidden => f.write_str("hidden"),
2890 Self::Inset => f.write_str("inset"),
2891 Self::None => f.write_str("none"),
2892 Self::Outset => f.write_str("outset"),
2893 Self::Ridge => f.write_str("ridge"),
2894 Self::Solid => f.write_str("solid"),
2895 }
2896 }
2897}
2898
2899#[derive(Debug, Clone, PartialEq)]
2901#[non_exhaustive]
2902pub enum BorderInlineEndWidth {
2903 Medium,
2905 Thick,
2907 Thin,
2909 Length(Length),
2911}
2912
2913impl fmt::Display for BorderInlineEndWidth {
2914 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2915 match self {
2916 Self::Medium => f.write_str("medium"),
2917 Self::Thick => f.write_str("thick"),
2918 Self::Thin => f.write_str("thin"),
2919 Self::Length(v) => v.fmt(f),
2920 }
2921 }
2922}
2923
2924impl From<Length> for BorderInlineEndWidth {
2925 fn from(v: Length) -> Self {
2926 Self::Length(v)
2927 }
2928}
2929
2930#[derive(Debug, Clone, PartialEq)]
2932#[non_exhaustive]
2933pub enum BorderInlineStart {
2934 Dashed,
2936 Dotted,
2938 Double,
2940 Groove,
2942 Hidden,
2944 Inset,
2946 Medium,
2948 None,
2950 Outset,
2952 Ridge,
2954 Solid,
2956 Thick,
2958 Thin,
2960 Length(Length),
2962 Color(Color),
2964 Raw(Raw),
2966}
2967
2968impl fmt::Display for BorderInlineStart {
2969 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2970 match self {
2971 Self::Dashed => f.write_str("dashed"),
2972 Self::Dotted => f.write_str("dotted"),
2973 Self::Double => f.write_str("double"),
2974 Self::Groove => f.write_str("groove"),
2975 Self::Hidden => f.write_str("hidden"),
2976 Self::Inset => f.write_str("inset"),
2977 Self::Medium => f.write_str("medium"),
2978 Self::None => f.write_str("none"),
2979 Self::Outset => f.write_str("outset"),
2980 Self::Ridge => f.write_str("ridge"),
2981 Self::Solid => f.write_str("solid"),
2982 Self::Thick => f.write_str("thick"),
2983 Self::Thin => f.write_str("thin"),
2984 Self::Length(v) => v.fmt(f),
2985 Self::Color(v) => v.fmt(f),
2986 Self::Raw(v) => v.fmt(f),
2987 }
2988 }
2989}
2990
2991impl From<Length> for BorderInlineStart {
2992 fn from(v: Length) -> Self {
2993 Self::Length(v)
2994 }
2995}
2996
2997impl From<Color> for BorderInlineStart {
2998 fn from(v: Color) -> Self {
2999 Self::Color(v)
3000 }
3001}
3002
3003impl From<Raw> for BorderInlineStart {
3004 fn from(v: Raw) -> Self {
3005 Self::Raw(v)
3006 }
3007}
3008
3009#[derive(Debug, Clone, PartialEq)]
3011#[non_exhaustive]
3012pub enum BorderInlineStartStyle {
3013 Dashed,
3015 Dotted,
3017 Double,
3019 Groove,
3021 Hidden,
3023 Inset,
3025 None,
3027 Outset,
3029 Ridge,
3031 Solid,
3033}
3034
3035impl fmt::Display for BorderInlineStartStyle {
3036 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3037 match self {
3038 Self::Dashed => f.write_str("dashed"),
3039 Self::Dotted => f.write_str("dotted"),
3040 Self::Double => f.write_str("double"),
3041 Self::Groove => f.write_str("groove"),
3042 Self::Hidden => f.write_str("hidden"),
3043 Self::Inset => f.write_str("inset"),
3044 Self::None => f.write_str("none"),
3045 Self::Outset => f.write_str("outset"),
3046 Self::Ridge => f.write_str("ridge"),
3047 Self::Solid => f.write_str("solid"),
3048 }
3049 }
3050}
3051
3052#[derive(Debug, Clone, PartialEq)]
3054#[non_exhaustive]
3055pub enum BorderInlineStartWidth {
3056 Medium,
3058 Thick,
3060 Thin,
3062 Length(Length),
3064}
3065
3066impl fmt::Display for BorderInlineStartWidth {
3067 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3068 match self {
3069 Self::Medium => f.write_str("medium"),
3070 Self::Thick => f.write_str("thick"),
3071 Self::Thin => f.write_str("thin"),
3072 Self::Length(v) => v.fmt(f),
3073 }
3074 }
3075}
3076
3077impl From<Length> for BorderInlineStartWidth {
3078 fn from(v: Length) -> Self {
3079 Self::Length(v)
3080 }
3081}
3082
3083#[derive(Debug, Clone, PartialEq)]
3085#[non_exhaustive]
3086pub enum BorderInlineStyle {
3087 Dashed,
3089 Dotted,
3091 Double,
3093 Groove,
3095 Hidden,
3097 Inset,
3099 None,
3101 Outset,
3103 Ridge,
3105 Solid,
3107 Raw(Raw),
3109}
3110
3111impl fmt::Display for BorderInlineStyle {
3112 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3113 match self {
3114 Self::Dashed => f.write_str("dashed"),
3115 Self::Dotted => f.write_str("dotted"),
3116 Self::Double => f.write_str("double"),
3117 Self::Groove => f.write_str("groove"),
3118 Self::Hidden => f.write_str("hidden"),
3119 Self::Inset => f.write_str("inset"),
3120 Self::None => f.write_str("none"),
3121 Self::Outset => f.write_str("outset"),
3122 Self::Ridge => f.write_str("ridge"),
3123 Self::Solid => f.write_str("solid"),
3124 Self::Raw(v) => v.fmt(f),
3125 }
3126 }
3127}
3128
3129impl From<Raw> for BorderInlineStyle {
3130 fn from(v: Raw) -> Self {
3131 Self::Raw(v)
3132 }
3133}
3134
3135#[derive(Debug, Clone, PartialEq)]
3137#[non_exhaustive]
3138pub enum BorderInlineWidth {
3139 Medium,
3141 Thick,
3143 Thin,
3145 Length(Length),
3147 Raw(Raw),
3149}
3150
3151impl fmt::Display for BorderInlineWidth {
3152 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3153 match self {
3154 Self::Medium => f.write_str("medium"),
3155 Self::Thick => f.write_str("thick"),
3156 Self::Thin => f.write_str("thin"),
3157 Self::Length(v) => v.fmt(f),
3158 Self::Raw(v) => v.fmt(f),
3159 }
3160 }
3161}
3162
3163impl From<Length> for BorderInlineWidth {
3164 fn from(v: Length) -> Self {
3165 Self::Length(v)
3166 }
3167}
3168
3169impl From<Raw> for BorderInlineWidth {
3170 fn from(v: Raw) -> Self {
3171 Self::Raw(v)
3172 }
3173}
3174
3175#[derive(Debug, Clone, PartialEq)]
3177#[non_exhaustive]
3178pub enum BorderLeft {
3179 Dashed,
3181 Dotted,
3183 Double,
3185 Groove,
3187 Hidden,
3189 Inset,
3191 Medium,
3193 None,
3195 Outset,
3197 Ridge,
3199 Solid,
3201 Thick,
3203 Thin,
3205 Length(Length),
3207 Color(Color),
3209 Raw(Raw),
3211}
3212
3213impl fmt::Display for BorderLeft {
3214 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3215 match self {
3216 Self::Dashed => f.write_str("dashed"),
3217 Self::Dotted => f.write_str("dotted"),
3218 Self::Double => f.write_str("double"),
3219 Self::Groove => f.write_str("groove"),
3220 Self::Hidden => f.write_str("hidden"),
3221 Self::Inset => f.write_str("inset"),
3222 Self::Medium => f.write_str("medium"),
3223 Self::None => f.write_str("none"),
3224 Self::Outset => f.write_str("outset"),
3225 Self::Ridge => f.write_str("ridge"),
3226 Self::Solid => f.write_str("solid"),
3227 Self::Thick => f.write_str("thick"),
3228 Self::Thin => f.write_str("thin"),
3229 Self::Length(v) => v.fmt(f),
3230 Self::Color(v) => v.fmt(f),
3231 Self::Raw(v) => v.fmt(f),
3232 }
3233 }
3234}
3235
3236impl From<Length> for BorderLeft {
3237 fn from(v: Length) -> Self {
3238 Self::Length(v)
3239 }
3240}
3241
3242impl From<Color> for BorderLeft {
3243 fn from(v: Color) -> Self {
3244 Self::Color(v)
3245 }
3246}
3247
3248impl From<Raw> for BorderLeft {
3249 fn from(v: Raw) -> Self {
3250 Self::Raw(v)
3251 }
3252}
3253
3254#[derive(Debug, Clone, PartialEq)]
3256#[non_exhaustive]
3257pub enum BorderLeftStyle {
3258 Dashed,
3260 Dotted,
3262 Double,
3264 Groove,
3266 Hidden,
3268 Inset,
3270 None,
3272 Outset,
3274 Ridge,
3276 Solid,
3278}
3279
3280impl fmt::Display for BorderLeftStyle {
3281 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3282 match self {
3283 Self::Dashed => f.write_str("dashed"),
3284 Self::Dotted => f.write_str("dotted"),
3285 Self::Double => f.write_str("double"),
3286 Self::Groove => f.write_str("groove"),
3287 Self::Hidden => f.write_str("hidden"),
3288 Self::Inset => f.write_str("inset"),
3289 Self::None => f.write_str("none"),
3290 Self::Outset => f.write_str("outset"),
3291 Self::Ridge => f.write_str("ridge"),
3292 Self::Solid => f.write_str("solid"),
3293 }
3294 }
3295}
3296
3297#[derive(Debug, Clone, PartialEq)]
3299#[non_exhaustive]
3300pub enum BorderLeftWidth {
3301 Medium,
3303 Thick,
3305 Thin,
3307 Length(Length),
3309}
3310
3311impl fmt::Display for BorderLeftWidth {
3312 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3313 match self {
3314 Self::Medium => f.write_str("medium"),
3315 Self::Thick => f.write_str("thick"),
3316 Self::Thin => f.write_str("thin"),
3317 Self::Length(v) => v.fmt(f),
3318 }
3319 }
3320}
3321
3322impl From<Length> for BorderLeftWidth {
3323 fn from(v: Length) -> Self {
3324 Self::Length(v)
3325 }
3326}
3327
3328#[derive(Debug, Clone, PartialEq)]
3330#[non_exhaustive]
3331pub enum BorderRadius {
3332 Length(Length),
3334 Percentage(Percentage),
3336 Raw(Raw),
3338}
3339
3340impl fmt::Display for BorderRadius {
3341 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3342 match self {
3343 Self::Length(v) => v.fmt(f),
3344 Self::Percentage(v) => v.fmt(f),
3345 Self::Raw(v) => v.fmt(f),
3346 }
3347 }
3348}
3349
3350impl From<Length> for BorderRadius {
3351 fn from(v: Length) -> Self {
3352 Self::Length(v)
3353 }
3354}
3355
3356impl From<Percentage> for BorderRadius {
3357 fn from(v: Percentage) -> Self {
3358 Self::Percentage(v)
3359 }
3360}
3361
3362impl From<Raw> for BorderRadius {
3363 fn from(v: Raw) -> Self {
3364 Self::Raw(v)
3365 }
3366}
3367
3368#[derive(Debug, Clone, PartialEq)]
3370#[non_exhaustive]
3371pub enum BorderRight {
3372 Dashed,
3374 Dotted,
3376 Double,
3378 Groove,
3380 Hidden,
3382 Inset,
3384 Medium,
3386 None,
3388 Outset,
3390 Ridge,
3392 Solid,
3394 Thick,
3396 Thin,
3398 Length(Length),
3400 Color(Color),
3402 Raw(Raw),
3404}
3405
3406impl fmt::Display for BorderRight {
3407 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3408 match self {
3409 Self::Dashed => f.write_str("dashed"),
3410 Self::Dotted => f.write_str("dotted"),
3411 Self::Double => f.write_str("double"),
3412 Self::Groove => f.write_str("groove"),
3413 Self::Hidden => f.write_str("hidden"),
3414 Self::Inset => f.write_str("inset"),
3415 Self::Medium => f.write_str("medium"),
3416 Self::None => f.write_str("none"),
3417 Self::Outset => f.write_str("outset"),
3418 Self::Ridge => f.write_str("ridge"),
3419 Self::Solid => f.write_str("solid"),
3420 Self::Thick => f.write_str("thick"),
3421 Self::Thin => f.write_str("thin"),
3422 Self::Length(v) => v.fmt(f),
3423 Self::Color(v) => v.fmt(f),
3424 Self::Raw(v) => v.fmt(f),
3425 }
3426 }
3427}
3428
3429impl From<Length> for BorderRight {
3430 fn from(v: Length) -> Self {
3431 Self::Length(v)
3432 }
3433}
3434
3435impl From<Color> for BorderRight {
3436 fn from(v: Color) -> Self {
3437 Self::Color(v)
3438 }
3439}
3440
3441impl From<Raw> for BorderRight {
3442 fn from(v: Raw) -> Self {
3443 Self::Raw(v)
3444 }
3445}
3446
3447#[derive(Debug, Clone, PartialEq)]
3449#[non_exhaustive]
3450pub enum BorderRightStyle {
3451 Dashed,
3453 Dotted,
3455 Double,
3457 Groove,
3459 Hidden,
3461 Inset,
3463 None,
3465 Outset,
3467 Ridge,
3469 Solid,
3471}
3472
3473impl fmt::Display for BorderRightStyle {
3474 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3475 match self {
3476 Self::Dashed => f.write_str("dashed"),
3477 Self::Dotted => f.write_str("dotted"),
3478 Self::Double => f.write_str("double"),
3479 Self::Groove => f.write_str("groove"),
3480 Self::Hidden => f.write_str("hidden"),
3481 Self::Inset => f.write_str("inset"),
3482 Self::None => f.write_str("none"),
3483 Self::Outset => f.write_str("outset"),
3484 Self::Ridge => f.write_str("ridge"),
3485 Self::Solid => f.write_str("solid"),
3486 }
3487 }
3488}
3489
3490#[derive(Debug, Clone, PartialEq)]
3492#[non_exhaustive]
3493pub enum BorderRightWidth {
3494 Medium,
3496 Thick,
3498 Thin,
3500 Length(Length),
3502}
3503
3504impl fmt::Display for BorderRightWidth {
3505 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3506 match self {
3507 Self::Medium => f.write_str("medium"),
3508 Self::Thick => f.write_str("thick"),
3509 Self::Thin => f.write_str("thin"),
3510 Self::Length(v) => v.fmt(f),
3511 }
3512 }
3513}
3514
3515impl From<Length> for BorderRightWidth {
3516 fn from(v: Length) -> Self {
3517 Self::Length(v)
3518 }
3519}
3520
3521#[derive(Debug, Clone, PartialEq)]
3523#[non_exhaustive]
3524pub enum BorderShape {
3525 None,
3527 Raw(Raw),
3529}
3530
3531impl fmt::Display for BorderShape {
3532 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3533 match self {
3534 Self::None => f.write_str("none"),
3535 Self::Raw(v) => v.fmt(f),
3536 }
3537 }
3538}
3539
3540impl From<Raw> for BorderShape {
3541 fn from(v: Raw) -> Self {
3542 Self::Raw(v)
3543 }
3544}
3545
3546#[derive(Debug, Clone, PartialEq)]
3548#[non_exhaustive]
3549pub enum BorderSpacing {
3550 Length(Length),
3552 Raw(Raw),
3554}
3555
3556impl fmt::Display for BorderSpacing {
3557 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3558 match self {
3559 Self::Length(v) => v.fmt(f),
3560 Self::Raw(v) => v.fmt(f),
3561 }
3562 }
3563}
3564
3565impl From<Length> for BorderSpacing {
3566 fn from(v: Length) -> Self {
3567 Self::Length(v)
3568 }
3569}
3570
3571impl From<Raw> for BorderSpacing {
3572 fn from(v: Raw) -> Self {
3573 Self::Raw(v)
3574 }
3575}
3576
3577#[derive(Debug, Clone, PartialEq)]
3579#[non_exhaustive]
3580pub enum BorderStartEndRadius {
3581 Length(Length),
3583 Percentage(Percentage),
3585 Raw(Raw),
3587}
3588
3589impl fmt::Display for BorderStartEndRadius {
3590 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3591 match self {
3592 Self::Length(v) => v.fmt(f),
3593 Self::Percentage(v) => v.fmt(f),
3594 Self::Raw(v) => v.fmt(f),
3595 }
3596 }
3597}
3598
3599impl From<Length> for BorderStartEndRadius {
3600 fn from(v: Length) -> Self {
3601 Self::Length(v)
3602 }
3603}
3604
3605impl From<Percentage> for BorderStartEndRadius {
3606 fn from(v: Percentage) -> Self {
3607 Self::Percentage(v)
3608 }
3609}
3610
3611impl From<Raw> for BorderStartEndRadius {
3612 fn from(v: Raw) -> Self {
3613 Self::Raw(v)
3614 }
3615}
3616
3617#[derive(Debug, Clone, PartialEq)]
3619#[non_exhaustive]
3620pub enum BorderStartStartRadius {
3621 Length(Length),
3623 Percentage(Percentage),
3625 Raw(Raw),
3627}
3628
3629impl fmt::Display for BorderStartStartRadius {
3630 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3631 match self {
3632 Self::Length(v) => v.fmt(f),
3633 Self::Percentage(v) => v.fmt(f),
3634 Self::Raw(v) => v.fmt(f),
3635 }
3636 }
3637}
3638
3639impl From<Length> for BorderStartStartRadius {
3640 fn from(v: Length) -> Self {
3641 Self::Length(v)
3642 }
3643}
3644
3645impl From<Percentage> for BorderStartStartRadius {
3646 fn from(v: Percentage) -> Self {
3647 Self::Percentage(v)
3648 }
3649}
3650
3651impl From<Raw> for BorderStartStartRadius {
3652 fn from(v: Raw) -> Self {
3653 Self::Raw(v)
3654 }
3655}
3656
3657#[derive(Debug, Clone, PartialEq)]
3659#[non_exhaustive]
3660pub enum BorderStyle {
3661 Dashed,
3663 Dotted,
3665 Double,
3667 Groove,
3669 Hidden,
3671 Inset,
3673 None,
3675 Outset,
3677 Ridge,
3679 Solid,
3681 Raw(Raw),
3683}
3684
3685impl fmt::Display for BorderStyle {
3686 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3687 match self {
3688 Self::Dashed => f.write_str("dashed"),
3689 Self::Dotted => f.write_str("dotted"),
3690 Self::Double => f.write_str("double"),
3691 Self::Groove => f.write_str("groove"),
3692 Self::Hidden => f.write_str("hidden"),
3693 Self::Inset => f.write_str("inset"),
3694 Self::None => f.write_str("none"),
3695 Self::Outset => f.write_str("outset"),
3696 Self::Ridge => f.write_str("ridge"),
3697 Self::Solid => f.write_str("solid"),
3698 Self::Raw(v) => v.fmt(f),
3699 }
3700 }
3701}
3702
3703impl From<Raw> for BorderStyle {
3704 fn from(v: Raw) -> Self {
3705 Self::Raw(v)
3706 }
3707}
3708
3709#[derive(Debug, Clone, PartialEq)]
3711#[non_exhaustive]
3712pub enum BorderTop {
3713 Dashed,
3715 Dotted,
3717 Double,
3719 Groove,
3721 Hidden,
3723 Inset,
3725 Medium,
3727 None,
3729 Outset,
3731 Ridge,
3733 Solid,
3735 Thick,
3737 Thin,
3739 Length(Length),
3741 Color(Color),
3743 Raw(Raw),
3745}
3746
3747impl fmt::Display for BorderTop {
3748 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3749 match self {
3750 Self::Dashed => f.write_str("dashed"),
3751 Self::Dotted => f.write_str("dotted"),
3752 Self::Double => f.write_str("double"),
3753 Self::Groove => f.write_str("groove"),
3754 Self::Hidden => f.write_str("hidden"),
3755 Self::Inset => f.write_str("inset"),
3756 Self::Medium => f.write_str("medium"),
3757 Self::None => f.write_str("none"),
3758 Self::Outset => f.write_str("outset"),
3759 Self::Ridge => f.write_str("ridge"),
3760 Self::Solid => f.write_str("solid"),
3761 Self::Thick => f.write_str("thick"),
3762 Self::Thin => f.write_str("thin"),
3763 Self::Length(v) => v.fmt(f),
3764 Self::Color(v) => v.fmt(f),
3765 Self::Raw(v) => v.fmt(f),
3766 }
3767 }
3768}
3769
3770impl From<Length> for BorderTop {
3771 fn from(v: Length) -> Self {
3772 Self::Length(v)
3773 }
3774}
3775
3776impl From<Color> for BorderTop {
3777 fn from(v: Color) -> Self {
3778 Self::Color(v)
3779 }
3780}
3781
3782impl From<Raw> for BorderTop {
3783 fn from(v: Raw) -> Self {
3784 Self::Raw(v)
3785 }
3786}
3787
3788#[derive(Debug, Clone, PartialEq)]
3790#[non_exhaustive]
3791pub enum BorderTopLeftRadius {
3792 Length(Length),
3794 Percentage(Percentage),
3796 Raw(Raw),
3798}
3799
3800impl fmt::Display for BorderTopLeftRadius {
3801 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3802 match self {
3803 Self::Length(v) => v.fmt(f),
3804 Self::Percentage(v) => v.fmt(f),
3805 Self::Raw(v) => v.fmt(f),
3806 }
3807 }
3808}
3809
3810impl From<Length> for BorderTopLeftRadius {
3811 fn from(v: Length) -> Self {
3812 Self::Length(v)
3813 }
3814}
3815
3816impl From<Percentage> for BorderTopLeftRadius {
3817 fn from(v: Percentage) -> Self {
3818 Self::Percentage(v)
3819 }
3820}
3821
3822impl From<Raw> for BorderTopLeftRadius {
3823 fn from(v: Raw) -> Self {
3824 Self::Raw(v)
3825 }
3826}
3827
3828#[derive(Debug, Clone, PartialEq)]
3830#[non_exhaustive]
3831pub enum BorderTopRightRadius {
3832 Length(Length),
3834 Percentage(Percentage),
3836 Raw(Raw),
3838}
3839
3840impl fmt::Display for BorderTopRightRadius {
3841 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3842 match self {
3843 Self::Length(v) => v.fmt(f),
3844 Self::Percentage(v) => v.fmt(f),
3845 Self::Raw(v) => v.fmt(f),
3846 }
3847 }
3848}
3849
3850impl From<Length> for BorderTopRightRadius {
3851 fn from(v: Length) -> Self {
3852 Self::Length(v)
3853 }
3854}
3855
3856impl From<Percentage> for BorderTopRightRadius {
3857 fn from(v: Percentage) -> Self {
3858 Self::Percentage(v)
3859 }
3860}
3861
3862impl From<Raw> for BorderTopRightRadius {
3863 fn from(v: Raw) -> Self {
3864 Self::Raw(v)
3865 }
3866}
3867
3868#[derive(Debug, Clone, PartialEq)]
3870#[non_exhaustive]
3871pub enum BorderTopStyle {
3872 Dashed,
3874 Dotted,
3876 Double,
3878 Groove,
3880 Hidden,
3882 Inset,
3884 None,
3886 Outset,
3888 Ridge,
3890 Solid,
3892}
3893
3894impl fmt::Display for BorderTopStyle {
3895 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3896 match self {
3897 Self::Dashed => f.write_str("dashed"),
3898 Self::Dotted => f.write_str("dotted"),
3899 Self::Double => f.write_str("double"),
3900 Self::Groove => f.write_str("groove"),
3901 Self::Hidden => f.write_str("hidden"),
3902 Self::Inset => f.write_str("inset"),
3903 Self::None => f.write_str("none"),
3904 Self::Outset => f.write_str("outset"),
3905 Self::Ridge => f.write_str("ridge"),
3906 Self::Solid => f.write_str("solid"),
3907 }
3908 }
3909}
3910
3911#[derive(Debug, Clone, PartialEq)]
3913#[non_exhaustive]
3914pub enum BorderTopWidth {
3915 Medium,
3917 Thick,
3919 Thin,
3921 Length(Length),
3923}
3924
3925impl fmt::Display for BorderTopWidth {
3926 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3927 match self {
3928 Self::Medium => f.write_str("medium"),
3929 Self::Thick => f.write_str("thick"),
3930 Self::Thin => f.write_str("thin"),
3931 Self::Length(v) => v.fmt(f),
3932 }
3933 }
3934}
3935
3936impl From<Length> for BorderTopWidth {
3937 fn from(v: Length) -> Self {
3938 Self::Length(v)
3939 }
3940}
3941
3942#[derive(Debug, Clone, PartialEq)]
3944#[non_exhaustive]
3945pub enum BorderWidth {
3946 Medium,
3948 Thick,
3950 Thin,
3952 Length(Length),
3954 Raw(Raw),
3956}
3957
3958impl fmt::Display for BorderWidth {
3959 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3960 match self {
3961 Self::Medium => f.write_str("medium"),
3962 Self::Thick => f.write_str("thick"),
3963 Self::Thin => f.write_str("thin"),
3964 Self::Length(v) => v.fmt(f),
3965 Self::Raw(v) => v.fmt(f),
3966 }
3967 }
3968}
3969
3970impl From<Length> for BorderWidth {
3971 fn from(v: Length) -> Self {
3972 Self::Length(v)
3973 }
3974}
3975
3976impl From<Raw> for BorderWidth {
3977 fn from(v: Raw) -> Self {
3978 Self::Raw(v)
3979 }
3980}
3981
3982#[derive(Debug, Clone, PartialEq)]
3984#[non_exhaustive]
3985pub enum Bottom {
3986 Auto,
3988 Length(Length),
3990 Percentage(Percentage),
3992 Raw(Raw),
3994}
3995
3996impl fmt::Display for Bottom {
3997 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3998 match self {
3999 Self::Auto => f.write_str("auto"),
4000 Self::Length(v) => v.fmt(f),
4001 Self::Percentage(v) => v.fmt(f),
4002 Self::Raw(v) => v.fmt(f),
4003 }
4004 }
4005}
4006
4007impl From<Length> for Bottom {
4008 fn from(v: Length) -> Self {
4009 Self::Length(v)
4010 }
4011}
4012
4013impl From<Percentage> for Bottom {
4014 fn from(v: Percentage) -> Self {
4015 Self::Percentage(v)
4016 }
4017}
4018
4019impl From<Raw> for Bottom {
4020 fn from(v: Raw) -> Self {
4021 Self::Raw(v)
4022 }
4023}
4024
4025#[derive(Debug, Clone, PartialEq)]
4027#[non_exhaustive]
4028pub enum BoxDecorationBreak {
4029 Clone,
4031 Slice,
4033}
4034
4035impl fmt::Display for BoxDecorationBreak {
4036 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4037 match self {
4038 Self::Clone => f.write_str("clone"),
4039 Self::Slice => f.write_str("slice"),
4040 }
4041 }
4042}
4043
4044#[derive(Debug, Clone, PartialEq)]
4046#[non_exhaustive]
4047pub enum BoxShadow {
4048 None,
4050 Raw(Raw),
4052}
4053
4054impl fmt::Display for BoxShadow {
4055 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4056 match self {
4057 Self::None => f.write_str("none"),
4058 Self::Raw(v) => v.fmt(f),
4059 }
4060 }
4061}
4062
4063impl From<Raw> for BoxShadow {
4064 fn from(v: Raw) -> Self {
4065 Self::Raw(v)
4066 }
4067}
4068
4069#[derive(Debug, Clone, PartialEq)]
4071#[non_exhaustive]
4072pub enum BoxSizing {
4073 BorderBox,
4075 ContentBox,
4077}
4078
4079impl fmt::Display for BoxSizing {
4080 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4081 match self {
4082 Self::BorderBox => f.write_str("border-box"),
4083 Self::ContentBox => f.write_str("content-box"),
4084 }
4085 }
4086}
4087
4088#[derive(Debug, Clone, PartialEq)]
4090#[non_exhaustive]
4091pub enum BreakAfter {
4092 All,
4094 Always,
4096 Auto,
4098 Avoid,
4100 AvoidColumn,
4102 AvoidPage,
4104 AvoidRegion,
4106 Column,
4108 Left,
4110 Page,
4112 Recto,
4114 Region,
4116 Right,
4118 Verso,
4120}
4121
4122impl fmt::Display for BreakAfter {
4123 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4124 match self {
4125 Self::All => f.write_str("all"),
4126 Self::Always => f.write_str("always"),
4127 Self::Auto => f.write_str("auto"),
4128 Self::Avoid => f.write_str("avoid"),
4129 Self::AvoidColumn => f.write_str("avoid-column"),
4130 Self::AvoidPage => f.write_str("avoid-page"),
4131 Self::AvoidRegion => f.write_str("avoid-region"),
4132 Self::Column => f.write_str("column"),
4133 Self::Left => f.write_str("left"),
4134 Self::Page => f.write_str("page"),
4135 Self::Recto => f.write_str("recto"),
4136 Self::Region => f.write_str("region"),
4137 Self::Right => f.write_str("right"),
4138 Self::Verso => f.write_str("verso"),
4139 }
4140 }
4141}
4142
4143#[derive(Debug, Clone, PartialEq)]
4145#[non_exhaustive]
4146pub enum BreakBefore {
4147 All,
4149 Always,
4151 Auto,
4153 Avoid,
4155 AvoidColumn,
4157 AvoidPage,
4159 AvoidRegion,
4161 Column,
4163 Left,
4165 Page,
4167 Recto,
4169 Region,
4171 Right,
4173 Verso,
4175}
4176
4177impl fmt::Display for BreakBefore {
4178 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4179 match self {
4180 Self::All => f.write_str("all"),
4181 Self::Always => f.write_str("always"),
4182 Self::Auto => f.write_str("auto"),
4183 Self::Avoid => f.write_str("avoid"),
4184 Self::AvoidColumn => f.write_str("avoid-column"),
4185 Self::AvoidPage => f.write_str("avoid-page"),
4186 Self::AvoidRegion => f.write_str("avoid-region"),
4187 Self::Column => f.write_str("column"),
4188 Self::Left => f.write_str("left"),
4189 Self::Page => f.write_str("page"),
4190 Self::Recto => f.write_str("recto"),
4191 Self::Region => f.write_str("region"),
4192 Self::Right => f.write_str("right"),
4193 Self::Verso => f.write_str("verso"),
4194 }
4195 }
4196}
4197
4198#[derive(Debug, Clone, PartialEq)]
4200#[non_exhaustive]
4201pub enum BreakInside {
4202 Auto,
4204 Avoid,
4206 AvoidColumn,
4208 AvoidPage,
4210 AvoidRegion,
4212}
4213
4214impl fmt::Display for BreakInside {
4215 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4216 match self {
4217 Self::Auto => f.write_str("auto"),
4218 Self::Avoid => f.write_str("avoid"),
4219 Self::AvoidColumn => f.write_str("avoid-column"),
4220 Self::AvoidPage => f.write_str("avoid-page"),
4221 Self::AvoidRegion => f.write_str("avoid-region"),
4222 }
4223 }
4224}
4225
4226#[derive(Debug, Clone, PartialEq)]
4228#[non_exhaustive]
4229pub enum CaptionSide {
4230 Bottom,
4232 Top,
4234}
4235
4236impl fmt::Display for CaptionSide {
4237 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4238 match self {
4239 Self::Bottom => f.write_str("bottom"),
4240 Self::Top => f.write_str("top"),
4241 }
4242 }
4243}
4244
4245#[derive(Debug, Clone, PartialEq)]
4247#[non_exhaustive]
4248pub enum Caret {
4249 Auto,
4251 Bar,
4253 Block,
4255 Manual,
4257 Underscore,
4259 Color(Color),
4261 Raw(Raw),
4263}
4264
4265impl fmt::Display for Caret {
4266 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4267 match self {
4268 Self::Auto => f.write_str("auto"),
4269 Self::Bar => f.write_str("bar"),
4270 Self::Block => f.write_str("block"),
4271 Self::Manual => f.write_str("manual"),
4272 Self::Underscore => f.write_str("underscore"),
4273 Self::Color(v) => v.fmt(f),
4274 Self::Raw(v) => v.fmt(f),
4275 }
4276 }
4277}
4278
4279impl From<Color> for Caret {
4280 fn from(v: Color) -> Self {
4281 Self::Color(v)
4282 }
4283}
4284
4285impl From<Raw> for Caret {
4286 fn from(v: Raw) -> Self {
4287 Self::Raw(v)
4288 }
4289}
4290
4291#[derive(Debug, Clone, PartialEq)]
4293#[non_exhaustive]
4294pub enum CaretAnimation {
4295 Auto,
4297 Manual,
4299}
4300
4301impl fmt::Display for CaretAnimation {
4302 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4303 match self {
4304 Self::Auto => f.write_str("auto"),
4305 Self::Manual => f.write_str("manual"),
4306 }
4307 }
4308}
4309
4310#[derive(Debug, Clone, PartialEq)]
4312#[non_exhaustive]
4313pub enum CaretColor {
4314 Auto,
4316 Color(Color),
4318}
4319
4320impl fmt::Display for CaretColor {
4321 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4322 match self {
4323 Self::Auto => f.write_str("auto"),
4324 Self::Color(v) => v.fmt(f),
4325 }
4326 }
4327}
4328
4329impl From<Color> for CaretColor {
4330 fn from(v: Color) -> Self {
4331 Self::Color(v)
4332 }
4333}
4334
4335#[derive(Debug, Clone, PartialEq)]
4337#[non_exhaustive]
4338pub enum CaretShape {
4339 Auto,
4341 Bar,
4343 Block,
4345 Underscore,
4347}
4348
4349impl fmt::Display for CaretShape {
4350 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4351 match self {
4352 Self::Auto => f.write_str("auto"),
4353 Self::Bar => f.write_str("bar"),
4354 Self::Block => f.write_str("block"),
4355 Self::Underscore => f.write_str("underscore"),
4356 }
4357 }
4358}
4359
4360#[derive(Debug, Clone, PartialEq)]
4362#[non_exhaustive]
4363pub enum Clear {
4364 Both,
4366 InlineEnd,
4368 InlineStart,
4370 Left,
4372 None,
4374 Right,
4376}
4377
4378impl fmt::Display for Clear {
4379 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4380 match self {
4381 Self::Both => f.write_str("both"),
4382 Self::InlineEnd => f.write_str("inline-end"),
4383 Self::InlineStart => f.write_str("inline-start"),
4384 Self::Left => f.write_str("left"),
4385 Self::None => f.write_str("none"),
4386 Self::Right => f.write_str("right"),
4387 }
4388 }
4389}
4390
4391#[derive(Debug, Clone, PartialEq)]
4393#[non_exhaustive]
4394pub enum ClipPath {
4395 BorderBox,
4397 ContentBox,
4399 FillBox,
4401 MarginBox,
4403 None,
4405 PaddingBox,
4407 StrokeBox,
4409 ViewBox,
4411 Url(Url),
4413 Raw(Raw),
4415}
4416
4417impl fmt::Display for ClipPath {
4418 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4419 match self {
4420 Self::BorderBox => f.write_str("border-box"),
4421 Self::ContentBox => f.write_str("content-box"),
4422 Self::FillBox => f.write_str("fill-box"),
4423 Self::MarginBox => f.write_str("margin-box"),
4424 Self::None => f.write_str("none"),
4425 Self::PaddingBox => f.write_str("padding-box"),
4426 Self::StrokeBox => f.write_str("stroke-box"),
4427 Self::ViewBox => f.write_str("view-box"),
4428 Self::Url(v) => v.fmt(f),
4429 Self::Raw(v) => v.fmt(f),
4430 }
4431 }
4432}
4433
4434impl From<Url> for ClipPath {
4435 fn from(v: Url) -> Self {
4436 Self::Url(v)
4437 }
4438}
4439
4440impl From<Raw> for ClipPath {
4441 fn from(v: Raw) -> Self {
4442 Self::Raw(v)
4443 }
4444}
4445
4446#[derive(Debug, Clone, PartialEq)]
4448#[non_exhaustive]
4449pub enum ClipRule {
4450 Evenodd,
4452 Nonzero,
4454}
4455
4456impl fmt::Display for ClipRule {
4457 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4458 match self {
4459 Self::Evenodd => f.write_str("evenodd"),
4460 Self::Nonzero => f.write_str("nonzero"),
4461 }
4462 }
4463}
4464
4465#[derive(Debug, Clone, PartialEq)]
4467#[non_exhaustive]
4468pub enum ColorInterpolationFilters {
4469 Auto,
4471 LinearRGB,
4473 SRGB,
4475}
4476
4477impl fmt::Display for ColorInterpolationFilters {
4478 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4479 match self {
4480 Self::Auto => f.write_str("auto"),
4481 Self::LinearRGB => f.write_str("linearRGB"),
4482 Self::SRGB => f.write_str("sRGB"),
4483 }
4484 }
4485}
4486
4487#[derive(Debug, Clone, PartialEq)]
4489#[non_exhaustive]
4490pub enum ColorScheme {
4491 Normal,
4493 Raw(Raw),
4495}
4496
4497impl fmt::Display for ColorScheme {
4498 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4499 match self {
4500 Self::Normal => f.write_str("normal"),
4501 Self::Raw(v) => v.fmt(f),
4502 }
4503 }
4504}
4505
4506impl From<Raw> for ColorScheme {
4507 fn from(v: Raw) -> Self {
4508 Self::Raw(v)
4509 }
4510}
4511
4512#[derive(Debug, Clone, PartialEq)]
4514#[non_exhaustive]
4515pub enum ColumnCount {
4516 Auto,
4518 Integer(i32),
4520}
4521
4522impl fmt::Display for ColumnCount {
4523 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4524 match self {
4525 Self::Auto => f.write_str("auto"),
4526 Self::Integer(v) => v.fmt(f),
4527 }
4528 }
4529}
4530
4531impl From<i32> for ColumnCount {
4532 fn from(v: i32) -> Self {
4533 Self::Integer(v)
4534 }
4535}
4536
4537#[derive(Debug, Clone, PartialEq)]
4539#[non_exhaustive]
4540pub enum ColumnFill {
4541 Auto,
4543 Balance,
4545}
4546
4547impl fmt::Display for ColumnFill {
4548 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4549 match self {
4550 Self::Auto => f.write_str("auto"),
4551 Self::Balance => f.write_str("balance"),
4552 }
4553 }
4554}
4555
4556#[derive(Debug, Clone, PartialEq)]
4558#[non_exhaustive]
4559pub enum ColumnGap {
4560 Normal,
4562 Length(Length),
4564 Percentage(Percentage),
4566}
4567
4568impl fmt::Display for ColumnGap {
4569 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4570 match self {
4571 Self::Normal => f.write_str("normal"),
4572 Self::Length(v) => v.fmt(f),
4573 Self::Percentage(v) => v.fmt(f),
4574 }
4575 }
4576}
4577
4578impl From<Length> for ColumnGap {
4579 fn from(v: Length) -> Self {
4580 Self::Length(v)
4581 }
4582}
4583
4584impl From<Percentage> for ColumnGap {
4585 fn from(v: Percentage) -> Self {
4586 Self::Percentage(v)
4587 }
4588}
4589
4590#[derive(Debug, Clone, PartialEq)]
4592#[non_exhaustive]
4593pub enum ColumnHeight {
4594 Auto,
4596 Length(Length),
4598}
4599
4600impl fmt::Display for ColumnHeight {
4601 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4602 match self {
4603 Self::Auto => f.write_str("auto"),
4604 Self::Length(v) => v.fmt(f),
4605 }
4606 }
4607}
4608
4609impl From<Length> for ColumnHeight {
4610 fn from(v: Length) -> Self {
4611 Self::Length(v)
4612 }
4613}
4614
4615#[derive(Debug, Clone, PartialEq)]
4617#[non_exhaustive]
4618pub enum ColumnRule {
4619 Dashed,
4621 Dotted,
4623 Double,
4625 Groove,
4627 Hidden,
4629 Inset,
4631 Medium,
4633 None,
4635 Outset,
4637 Ridge,
4639 Solid,
4641 Thick,
4643 Thin,
4645 Length(Length),
4647 Color(Color),
4649 Raw(Raw),
4651}
4652
4653impl fmt::Display for ColumnRule {
4654 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4655 match self {
4656 Self::Dashed => f.write_str("dashed"),
4657 Self::Dotted => f.write_str("dotted"),
4658 Self::Double => f.write_str("double"),
4659 Self::Groove => f.write_str("groove"),
4660 Self::Hidden => f.write_str("hidden"),
4661 Self::Inset => f.write_str("inset"),
4662 Self::Medium => f.write_str("medium"),
4663 Self::None => f.write_str("none"),
4664 Self::Outset => f.write_str("outset"),
4665 Self::Ridge => f.write_str("ridge"),
4666 Self::Solid => f.write_str("solid"),
4667 Self::Thick => f.write_str("thick"),
4668 Self::Thin => f.write_str("thin"),
4669 Self::Length(v) => v.fmt(f),
4670 Self::Color(v) => v.fmt(f),
4671 Self::Raw(v) => v.fmt(f),
4672 }
4673 }
4674}
4675
4676impl From<Length> for ColumnRule {
4677 fn from(v: Length) -> Self {
4678 Self::Length(v)
4679 }
4680}
4681
4682impl From<Color> for ColumnRule {
4683 fn from(v: Color) -> Self {
4684 Self::Color(v)
4685 }
4686}
4687
4688impl From<Raw> for ColumnRule {
4689 fn from(v: Raw) -> Self {
4690 Self::Raw(v)
4691 }
4692}
4693
4694#[derive(Debug, Clone, PartialEq)]
4696#[non_exhaustive]
4697pub enum ColumnRuleStyle {
4698 Dashed,
4700 Dotted,
4702 Double,
4704 Groove,
4706 Hidden,
4708 Inset,
4710 None,
4712 Outset,
4714 Ridge,
4716 Solid,
4718}
4719
4720impl fmt::Display for ColumnRuleStyle {
4721 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4722 match self {
4723 Self::Dashed => f.write_str("dashed"),
4724 Self::Dotted => f.write_str("dotted"),
4725 Self::Double => f.write_str("double"),
4726 Self::Groove => f.write_str("groove"),
4727 Self::Hidden => f.write_str("hidden"),
4728 Self::Inset => f.write_str("inset"),
4729 Self::None => f.write_str("none"),
4730 Self::Outset => f.write_str("outset"),
4731 Self::Ridge => f.write_str("ridge"),
4732 Self::Solid => f.write_str("solid"),
4733 }
4734 }
4735}
4736
4737#[derive(Debug, Clone, PartialEq)]
4739#[non_exhaustive]
4740pub enum ColumnRuleWidth {
4741 Medium,
4743 Thick,
4745 Thin,
4747 Length(Length),
4749}
4750
4751impl fmt::Display for ColumnRuleWidth {
4752 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4753 match self {
4754 Self::Medium => f.write_str("medium"),
4755 Self::Thick => f.write_str("thick"),
4756 Self::Thin => f.write_str("thin"),
4757 Self::Length(v) => v.fmt(f),
4758 }
4759 }
4760}
4761
4762impl From<Length> for ColumnRuleWidth {
4763 fn from(v: Length) -> Self {
4764 Self::Length(v)
4765 }
4766}
4767
4768#[derive(Debug, Clone, PartialEq)]
4770#[non_exhaustive]
4771pub enum ColumnSpan {
4772 All,
4774 None,
4776}
4777
4778impl fmt::Display for ColumnSpan {
4779 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4780 match self {
4781 Self::All => f.write_str("all"),
4782 Self::None => f.write_str("none"),
4783 }
4784 }
4785}
4786
4787#[derive(Debug, Clone, PartialEq)]
4789#[non_exhaustive]
4790pub enum ColumnWidth {
4791 Auto,
4793 Length(Length),
4795}
4796
4797impl fmt::Display for ColumnWidth {
4798 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4799 match self {
4800 Self::Auto => f.write_str("auto"),
4801 Self::Length(v) => v.fmt(f),
4802 }
4803 }
4804}
4805
4806impl From<Length> for ColumnWidth {
4807 fn from(v: Length) -> Self {
4808 Self::Length(v)
4809 }
4810}
4811
4812#[derive(Debug, Clone, PartialEq)]
4814#[non_exhaustive]
4815pub enum ColumnWrap {
4816 Auto,
4818 Nowrap,
4820 Wrap,
4822}
4823
4824impl fmt::Display for ColumnWrap {
4825 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4826 match self {
4827 Self::Auto => f.write_str("auto"),
4828 Self::Nowrap => f.write_str("nowrap"),
4829 Self::Wrap => f.write_str("wrap"),
4830 }
4831 }
4832}
4833
4834#[derive(Debug, Clone, PartialEq)]
4836#[non_exhaustive]
4837pub enum Columns {
4838 Auto,
4840 Length(Length),
4842 Integer(i32),
4844 Raw(Raw),
4846}
4847
4848impl fmt::Display for Columns {
4849 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4850 match self {
4851 Self::Auto => f.write_str("auto"),
4852 Self::Length(v) => v.fmt(f),
4853 Self::Integer(v) => v.fmt(f),
4854 Self::Raw(v) => v.fmt(f),
4855 }
4856 }
4857}
4858
4859impl From<Length> for Columns {
4860 fn from(v: Length) -> Self {
4861 Self::Length(v)
4862 }
4863}
4864
4865impl From<i32> for Columns {
4866 fn from(v: i32) -> Self {
4867 Self::Integer(v)
4868 }
4869}
4870
4871impl From<Raw> for Columns {
4872 fn from(v: Raw) -> Self {
4873 Self::Raw(v)
4874 }
4875}
4876
4877#[derive(Debug, Clone, PartialEq)]
4879#[non_exhaustive]
4880pub enum Contain {
4881 Content,
4883 InlineSize,
4885 Layout,
4887 None,
4889 Paint,
4891 Size,
4893 Strict,
4895 Style,
4897 Raw(Raw),
4899}
4900
4901impl fmt::Display for Contain {
4902 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4903 match self {
4904 Self::Content => f.write_str("content"),
4905 Self::InlineSize => f.write_str("inline-size"),
4906 Self::Layout => f.write_str("layout"),
4907 Self::None => f.write_str("none"),
4908 Self::Paint => f.write_str("paint"),
4909 Self::Size => f.write_str("size"),
4910 Self::Strict => f.write_str("strict"),
4911 Self::Style => f.write_str("style"),
4912 Self::Raw(v) => v.fmt(f),
4913 }
4914 }
4915}
4916
4917impl From<Raw> for Contain {
4918 fn from(v: Raw) -> Self {
4919 Self::Raw(v)
4920 }
4921}
4922
4923#[derive(Debug, Clone, PartialEq)]
4925#[non_exhaustive]
4926pub enum ContainIntrinsicBlockSize {
4927 None,
4929 Length(Length),
4931 Raw(Raw),
4933}
4934
4935impl fmt::Display for ContainIntrinsicBlockSize {
4936 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4937 match self {
4938 Self::None => f.write_str("none"),
4939 Self::Length(v) => v.fmt(f),
4940 Self::Raw(v) => v.fmt(f),
4941 }
4942 }
4943}
4944
4945impl From<Length> for ContainIntrinsicBlockSize {
4946 fn from(v: Length) -> Self {
4947 Self::Length(v)
4948 }
4949}
4950
4951impl From<Raw> for ContainIntrinsicBlockSize {
4952 fn from(v: Raw) -> Self {
4953 Self::Raw(v)
4954 }
4955}
4956
4957#[derive(Debug, Clone, PartialEq)]
4959#[non_exhaustive]
4960pub enum ContainIntrinsicHeight {
4961 None,
4963 Length(Length),
4965 Raw(Raw),
4967}
4968
4969impl fmt::Display for ContainIntrinsicHeight {
4970 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
4971 match self {
4972 Self::None => f.write_str("none"),
4973 Self::Length(v) => v.fmt(f),
4974 Self::Raw(v) => v.fmt(f),
4975 }
4976 }
4977}
4978
4979impl From<Length> for ContainIntrinsicHeight {
4980 fn from(v: Length) -> Self {
4981 Self::Length(v)
4982 }
4983}
4984
4985impl From<Raw> for ContainIntrinsicHeight {
4986 fn from(v: Raw) -> Self {
4987 Self::Raw(v)
4988 }
4989}
4990
4991#[derive(Debug, Clone, PartialEq)]
4993#[non_exhaustive]
4994pub enum ContainIntrinsicInlineSize {
4995 None,
4997 Length(Length),
4999 Raw(Raw),
5001}
5002
5003impl fmt::Display for ContainIntrinsicInlineSize {
5004 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5005 match self {
5006 Self::None => f.write_str("none"),
5007 Self::Length(v) => v.fmt(f),
5008 Self::Raw(v) => v.fmt(f),
5009 }
5010 }
5011}
5012
5013impl From<Length> for ContainIntrinsicInlineSize {
5014 fn from(v: Length) -> Self {
5015 Self::Length(v)
5016 }
5017}
5018
5019impl From<Raw> for ContainIntrinsicInlineSize {
5020 fn from(v: Raw) -> Self {
5021 Self::Raw(v)
5022 }
5023}
5024
5025#[derive(Debug, Clone, PartialEq)]
5027#[non_exhaustive]
5028pub enum ContainIntrinsicSize {
5029 None,
5031 Length(Length),
5033 Raw(Raw),
5035}
5036
5037impl fmt::Display for ContainIntrinsicSize {
5038 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5039 match self {
5040 Self::None => f.write_str("none"),
5041 Self::Length(v) => v.fmt(f),
5042 Self::Raw(v) => v.fmt(f),
5043 }
5044 }
5045}
5046
5047impl From<Length> for ContainIntrinsicSize {
5048 fn from(v: Length) -> Self {
5049 Self::Length(v)
5050 }
5051}
5052
5053impl From<Raw> for ContainIntrinsicSize {
5054 fn from(v: Raw) -> Self {
5055 Self::Raw(v)
5056 }
5057}
5058
5059#[derive(Debug, Clone, PartialEq)]
5061#[non_exhaustive]
5062pub enum ContainIntrinsicWidth {
5063 None,
5065 Length(Length),
5067 Raw(Raw),
5069}
5070
5071impl fmt::Display for ContainIntrinsicWidth {
5072 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5073 match self {
5074 Self::None => f.write_str("none"),
5075 Self::Length(v) => v.fmt(f),
5076 Self::Raw(v) => v.fmt(f),
5077 }
5078 }
5079}
5080
5081impl From<Length> for ContainIntrinsicWidth {
5082 fn from(v: Length) -> Self {
5083 Self::Length(v)
5084 }
5085}
5086
5087impl From<Raw> for ContainIntrinsicWidth {
5088 fn from(v: Raw) -> Self {
5089 Self::Raw(v)
5090 }
5091}
5092
5093#[derive(Debug, Clone, PartialEq)]
5095#[non_exhaustive]
5096pub enum Container {
5097 None,
5099 Raw(Raw),
5101}
5102
5103impl fmt::Display for Container {
5104 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5105 match self {
5106 Self::None => f.write_str("none"),
5107 Self::Raw(v) => v.fmt(f),
5108 }
5109 }
5110}
5111
5112impl From<Raw> for Container {
5113 fn from(v: Raw) -> Self {
5114 Self::Raw(v)
5115 }
5116}
5117
5118#[derive(Debug, Clone, PartialEq)]
5120#[non_exhaustive]
5121pub enum ContainerName {
5122 None,
5124 Raw(Raw),
5126}
5127
5128impl fmt::Display for ContainerName {
5129 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5130 match self {
5131 Self::None => f.write_str("none"),
5132 Self::Raw(v) => v.fmt(f),
5133 }
5134 }
5135}
5136
5137impl From<Raw> for ContainerName {
5138 fn from(v: Raw) -> Self {
5139 Self::Raw(v)
5140 }
5141}
5142
5143#[derive(Debug, Clone, PartialEq)]
5145#[non_exhaustive]
5146pub enum ContainerType {
5147 InlineSize,
5149 Normal,
5151 ScrollState,
5153 Size,
5155 Raw(Raw),
5157}
5158
5159impl fmt::Display for ContainerType {
5160 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5161 match self {
5162 Self::InlineSize => f.write_str("inline-size"),
5163 Self::Normal => f.write_str("normal"),
5164 Self::ScrollState => f.write_str("scroll-state"),
5165 Self::Size => f.write_str("size"),
5166 Self::Raw(v) => v.fmt(f),
5167 }
5168 }
5169}
5170
5171impl From<Raw> for ContainerType {
5172 fn from(v: Raw) -> Self {
5173 Self::Raw(v)
5174 }
5175}
5176
5177#[derive(Debug, Clone, PartialEq)]
5179#[non_exhaustive]
5180pub enum Content {
5181 CloseQuote,
5183 NoCloseQuote,
5185 NoOpenQuote,
5187 None,
5189 Normal,
5191 OpenQuote,
5193 Quoted(Quoted),
5195 Url(Url),
5197 Raw(Raw),
5199}
5200
5201impl fmt::Display for Content {
5202 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5203 match self {
5204 Self::CloseQuote => f.write_str("close-quote"),
5205 Self::NoCloseQuote => f.write_str("no-close-quote"),
5206 Self::NoOpenQuote => f.write_str("no-open-quote"),
5207 Self::None => f.write_str("none"),
5208 Self::Normal => f.write_str("normal"),
5209 Self::OpenQuote => f.write_str("open-quote"),
5210 Self::Quoted(v) => v.fmt(f),
5211 Self::Url(v) => v.fmt(f),
5212 Self::Raw(v) => v.fmt(f),
5213 }
5214 }
5215}
5216
5217impl From<Quoted> for Content {
5218 fn from(v: Quoted) -> Self {
5219 Self::Quoted(v)
5220 }
5221}
5222
5223impl From<Url> for Content {
5224 fn from(v: Url) -> Self {
5225 Self::Url(v)
5226 }
5227}
5228
5229impl From<Raw> for Content {
5230 fn from(v: Raw) -> Self {
5231 Self::Raw(v)
5232 }
5233}
5234
5235#[derive(Debug, Clone, PartialEq)]
5237#[non_exhaustive]
5238pub enum ContentVisibility {
5239 Auto,
5241 Hidden,
5243 Visible,
5245}
5246
5247impl fmt::Display for ContentVisibility {
5248 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5249 match self {
5250 Self::Auto => f.write_str("auto"),
5251 Self::Hidden => f.write_str("hidden"),
5252 Self::Visible => f.write_str("visible"),
5253 }
5254 }
5255}
5256
5257#[derive(Debug, Clone, PartialEq)]
5259#[non_exhaustive]
5260pub enum CornerBlockEndShape {
5261 Bevel,
5263 Notch,
5265 Round,
5267 Scoop,
5269 Square,
5271 Squircle,
5273 Raw(Raw),
5275}
5276
5277impl fmt::Display for CornerBlockEndShape {
5278 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5279 match self {
5280 Self::Bevel => f.write_str("bevel"),
5281 Self::Notch => f.write_str("notch"),
5282 Self::Round => f.write_str("round"),
5283 Self::Scoop => f.write_str("scoop"),
5284 Self::Square => f.write_str("square"),
5285 Self::Squircle => f.write_str("squircle"),
5286 Self::Raw(v) => v.fmt(f),
5287 }
5288 }
5289}
5290
5291impl From<Raw> for CornerBlockEndShape {
5292 fn from(v: Raw) -> Self {
5293 Self::Raw(v)
5294 }
5295}
5296
5297#[derive(Debug, Clone, PartialEq)]
5299#[non_exhaustive]
5300pub enum CornerBlockStartShape {
5301 Bevel,
5303 Notch,
5305 Round,
5307 Scoop,
5309 Square,
5311 Squircle,
5313 Raw(Raw),
5315}
5316
5317impl fmt::Display for CornerBlockStartShape {
5318 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5319 match self {
5320 Self::Bevel => f.write_str("bevel"),
5321 Self::Notch => f.write_str("notch"),
5322 Self::Round => f.write_str("round"),
5323 Self::Scoop => f.write_str("scoop"),
5324 Self::Square => f.write_str("square"),
5325 Self::Squircle => f.write_str("squircle"),
5326 Self::Raw(v) => v.fmt(f),
5327 }
5328 }
5329}
5330
5331impl From<Raw> for CornerBlockStartShape {
5332 fn from(v: Raw) -> Self {
5333 Self::Raw(v)
5334 }
5335}
5336
5337#[derive(Debug, Clone, PartialEq)]
5339#[non_exhaustive]
5340pub enum CornerBottomLeftShape {
5341 Bevel,
5343 Notch,
5345 Round,
5347 Scoop,
5349 Square,
5351 Squircle,
5353 Raw(Raw),
5355}
5356
5357impl fmt::Display for CornerBottomLeftShape {
5358 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5359 match self {
5360 Self::Bevel => f.write_str("bevel"),
5361 Self::Notch => f.write_str("notch"),
5362 Self::Round => f.write_str("round"),
5363 Self::Scoop => f.write_str("scoop"),
5364 Self::Square => f.write_str("square"),
5365 Self::Squircle => f.write_str("squircle"),
5366 Self::Raw(v) => v.fmt(f),
5367 }
5368 }
5369}
5370
5371impl From<Raw> for CornerBottomLeftShape {
5372 fn from(v: Raw) -> Self {
5373 Self::Raw(v)
5374 }
5375}
5376
5377#[derive(Debug, Clone, PartialEq)]
5379#[non_exhaustive]
5380pub enum CornerBottomRightShape {
5381 Bevel,
5383 Notch,
5385 Round,
5387 Scoop,
5389 Square,
5391 Squircle,
5393 Raw(Raw),
5395}
5396
5397impl fmt::Display for CornerBottomRightShape {
5398 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5399 match self {
5400 Self::Bevel => f.write_str("bevel"),
5401 Self::Notch => f.write_str("notch"),
5402 Self::Round => f.write_str("round"),
5403 Self::Scoop => f.write_str("scoop"),
5404 Self::Square => f.write_str("square"),
5405 Self::Squircle => f.write_str("squircle"),
5406 Self::Raw(v) => v.fmt(f),
5407 }
5408 }
5409}
5410
5411impl From<Raw> for CornerBottomRightShape {
5412 fn from(v: Raw) -> Self {
5413 Self::Raw(v)
5414 }
5415}
5416
5417#[derive(Debug, Clone, PartialEq)]
5419#[non_exhaustive]
5420pub enum CornerBottomShape {
5421 Bevel,
5423 Notch,
5425 Round,
5427 Scoop,
5429 Square,
5431 Squircle,
5433 Raw(Raw),
5435}
5436
5437impl fmt::Display for CornerBottomShape {
5438 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5439 match self {
5440 Self::Bevel => f.write_str("bevel"),
5441 Self::Notch => f.write_str("notch"),
5442 Self::Round => f.write_str("round"),
5443 Self::Scoop => f.write_str("scoop"),
5444 Self::Square => f.write_str("square"),
5445 Self::Squircle => f.write_str("squircle"),
5446 Self::Raw(v) => v.fmt(f),
5447 }
5448 }
5449}
5450
5451impl From<Raw> for CornerBottomShape {
5452 fn from(v: Raw) -> Self {
5453 Self::Raw(v)
5454 }
5455}
5456
5457#[derive(Debug, Clone, PartialEq)]
5459#[non_exhaustive]
5460pub enum CornerEndEndShape {
5461 Bevel,
5463 Notch,
5465 Round,
5467 Scoop,
5469 Square,
5471 Squircle,
5473 Raw(Raw),
5475}
5476
5477impl fmt::Display for CornerEndEndShape {
5478 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5479 match self {
5480 Self::Bevel => f.write_str("bevel"),
5481 Self::Notch => f.write_str("notch"),
5482 Self::Round => f.write_str("round"),
5483 Self::Scoop => f.write_str("scoop"),
5484 Self::Square => f.write_str("square"),
5485 Self::Squircle => f.write_str("squircle"),
5486 Self::Raw(v) => v.fmt(f),
5487 }
5488 }
5489}
5490
5491impl From<Raw> for CornerEndEndShape {
5492 fn from(v: Raw) -> Self {
5493 Self::Raw(v)
5494 }
5495}
5496
5497#[derive(Debug, Clone, PartialEq)]
5499#[non_exhaustive]
5500pub enum CornerEndStartShape {
5501 Bevel,
5503 Notch,
5505 Round,
5507 Scoop,
5509 Square,
5511 Squircle,
5513 Raw(Raw),
5515}
5516
5517impl fmt::Display for CornerEndStartShape {
5518 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5519 match self {
5520 Self::Bevel => f.write_str("bevel"),
5521 Self::Notch => f.write_str("notch"),
5522 Self::Round => f.write_str("round"),
5523 Self::Scoop => f.write_str("scoop"),
5524 Self::Square => f.write_str("square"),
5525 Self::Squircle => f.write_str("squircle"),
5526 Self::Raw(v) => v.fmt(f),
5527 }
5528 }
5529}
5530
5531impl From<Raw> for CornerEndStartShape {
5532 fn from(v: Raw) -> Self {
5533 Self::Raw(v)
5534 }
5535}
5536
5537#[derive(Debug, Clone, PartialEq)]
5539#[non_exhaustive]
5540pub enum CornerInlineEndShape {
5541 Bevel,
5543 Notch,
5545 Round,
5547 Scoop,
5549 Square,
5551 Squircle,
5553 Raw(Raw),
5555}
5556
5557impl fmt::Display for CornerInlineEndShape {
5558 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5559 match self {
5560 Self::Bevel => f.write_str("bevel"),
5561 Self::Notch => f.write_str("notch"),
5562 Self::Round => f.write_str("round"),
5563 Self::Scoop => f.write_str("scoop"),
5564 Self::Square => f.write_str("square"),
5565 Self::Squircle => f.write_str("squircle"),
5566 Self::Raw(v) => v.fmt(f),
5567 }
5568 }
5569}
5570
5571impl From<Raw> for CornerInlineEndShape {
5572 fn from(v: Raw) -> Self {
5573 Self::Raw(v)
5574 }
5575}
5576
5577#[derive(Debug, Clone, PartialEq)]
5579#[non_exhaustive]
5580pub enum CornerInlineStartShape {
5581 Bevel,
5583 Notch,
5585 Round,
5587 Scoop,
5589 Square,
5591 Squircle,
5593 Raw(Raw),
5595}
5596
5597impl fmt::Display for CornerInlineStartShape {
5598 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5599 match self {
5600 Self::Bevel => f.write_str("bevel"),
5601 Self::Notch => f.write_str("notch"),
5602 Self::Round => f.write_str("round"),
5603 Self::Scoop => f.write_str("scoop"),
5604 Self::Square => f.write_str("square"),
5605 Self::Squircle => f.write_str("squircle"),
5606 Self::Raw(v) => v.fmt(f),
5607 }
5608 }
5609}
5610
5611impl From<Raw> for CornerInlineStartShape {
5612 fn from(v: Raw) -> Self {
5613 Self::Raw(v)
5614 }
5615}
5616
5617#[derive(Debug, Clone, PartialEq)]
5619#[non_exhaustive]
5620pub enum CornerLeftShape {
5621 Bevel,
5623 Notch,
5625 Round,
5627 Scoop,
5629 Square,
5631 Squircle,
5633 Raw(Raw),
5635}
5636
5637impl fmt::Display for CornerLeftShape {
5638 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5639 match self {
5640 Self::Bevel => f.write_str("bevel"),
5641 Self::Notch => f.write_str("notch"),
5642 Self::Round => f.write_str("round"),
5643 Self::Scoop => f.write_str("scoop"),
5644 Self::Square => f.write_str("square"),
5645 Self::Squircle => f.write_str("squircle"),
5646 Self::Raw(v) => v.fmt(f),
5647 }
5648 }
5649}
5650
5651impl From<Raw> for CornerLeftShape {
5652 fn from(v: Raw) -> Self {
5653 Self::Raw(v)
5654 }
5655}
5656
5657#[derive(Debug, Clone, PartialEq)]
5659#[non_exhaustive]
5660pub enum CornerRightShape {
5661 Bevel,
5663 Notch,
5665 Round,
5667 Scoop,
5669 Square,
5671 Squircle,
5673 Raw(Raw),
5675}
5676
5677impl fmt::Display for CornerRightShape {
5678 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5679 match self {
5680 Self::Bevel => f.write_str("bevel"),
5681 Self::Notch => f.write_str("notch"),
5682 Self::Round => f.write_str("round"),
5683 Self::Scoop => f.write_str("scoop"),
5684 Self::Square => f.write_str("square"),
5685 Self::Squircle => f.write_str("squircle"),
5686 Self::Raw(v) => v.fmt(f),
5687 }
5688 }
5689}
5690
5691impl From<Raw> for CornerRightShape {
5692 fn from(v: Raw) -> Self {
5693 Self::Raw(v)
5694 }
5695}
5696
5697#[derive(Debug, Clone, PartialEq)]
5699#[non_exhaustive]
5700pub enum CornerShape {
5701 Bevel,
5703 Notch,
5705 Round,
5707 Scoop,
5709 Square,
5711 Squircle,
5713 Raw(Raw),
5715}
5716
5717impl fmt::Display for CornerShape {
5718 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5719 match self {
5720 Self::Bevel => f.write_str("bevel"),
5721 Self::Notch => f.write_str("notch"),
5722 Self::Round => f.write_str("round"),
5723 Self::Scoop => f.write_str("scoop"),
5724 Self::Square => f.write_str("square"),
5725 Self::Squircle => f.write_str("squircle"),
5726 Self::Raw(v) => v.fmt(f),
5727 }
5728 }
5729}
5730
5731impl From<Raw> for CornerShape {
5732 fn from(v: Raw) -> Self {
5733 Self::Raw(v)
5734 }
5735}
5736
5737#[derive(Debug, Clone, PartialEq)]
5739#[non_exhaustive]
5740pub enum CornerStartEndShape {
5741 Bevel,
5743 Notch,
5745 Round,
5747 Scoop,
5749 Square,
5751 Squircle,
5753 Raw(Raw),
5755}
5756
5757impl fmt::Display for CornerStartEndShape {
5758 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5759 match self {
5760 Self::Bevel => f.write_str("bevel"),
5761 Self::Notch => f.write_str("notch"),
5762 Self::Round => f.write_str("round"),
5763 Self::Scoop => f.write_str("scoop"),
5764 Self::Square => f.write_str("square"),
5765 Self::Squircle => f.write_str("squircle"),
5766 Self::Raw(v) => v.fmt(f),
5767 }
5768 }
5769}
5770
5771impl From<Raw> for CornerStartEndShape {
5772 fn from(v: Raw) -> Self {
5773 Self::Raw(v)
5774 }
5775}
5776
5777#[derive(Debug, Clone, PartialEq)]
5779#[non_exhaustive]
5780pub enum CornerStartStartShape {
5781 Bevel,
5783 Notch,
5785 Round,
5787 Scoop,
5789 Square,
5791 Squircle,
5793 Raw(Raw),
5795}
5796
5797impl fmt::Display for CornerStartStartShape {
5798 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5799 match self {
5800 Self::Bevel => f.write_str("bevel"),
5801 Self::Notch => f.write_str("notch"),
5802 Self::Round => f.write_str("round"),
5803 Self::Scoop => f.write_str("scoop"),
5804 Self::Square => f.write_str("square"),
5805 Self::Squircle => f.write_str("squircle"),
5806 Self::Raw(v) => v.fmt(f),
5807 }
5808 }
5809}
5810
5811impl From<Raw> for CornerStartStartShape {
5812 fn from(v: Raw) -> Self {
5813 Self::Raw(v)
5814 }
5815}
5816
5817#[derive(Debug, Clone, PartialEq)]
5819#[non_exhaustive]
5820pub enum CornerTopLeftShape {
5821 Bevel,
5823 Notch,
5825 Round,
5827 Scoop,
5829 Square,
5831 Squircle,
5833 Raw(Raw),
5835}
5836
5837impl fmt::Display for CornerTopLeftShape {
5838 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5839 match self {
5840 Self::Bevel => f.write_str("bevel"),
5841 Self::Notch => f.write_str("notch"),
5842 Self::Round => f.write_str("round"),
5843 Self::Scoop => f.write_str("scoop"),
5844 Self::Square => f.write_str("square"),
5845 Self::Squircle => f.write_str("squircle"),
5846 Self::Raw(v) => v.fmt(f),
5847 }
5848 }
5849}
5850
5851impl From<Raw> for CornerTopLeftShape {
5852 fn from(v: Raw) -> Self {
5853 Self::Raw(v)
5854 }
5855}
5856
5857#[derive(Debug, Clone, PartialEq)]
5859#[non_exhaustive]
5860pub enum CornerTopRightShape {
5861 Bevel,
5863 Notch,
5865 Round,
5867 Scoop,
5869 Square,
5871 Squircle,
5873 Raw(Raw),
5875}
5876
5877impl fmt::Display for CornerTopRightShape {
5878 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5879 match self {
5880 Self::Bevel => f.write_str("bevel"),
5881 Self::Notch => f.write_str("notch"),
5882 Self::Round => f.write_str("round"),
5883 Self::Scoop => f.write_str("scoop"),
5884 Self::Square => f.write_str("square"),
5885 Self::Squircle => f.write_str("squircle"),
5886 Self::Raw(v) => v.fmt(f),
5887 }
5888 }
5889}
5890
5891impl From<Raw> for CornerTopRightShape {
5892 fn from(v: Raw) -> Self {
5893 Self::Raw(v)
5894 }
5895}
5896
5897#[derive(Debug, Clone, PartialEq)]
5899#[non_exhaustive]
5900pub enum CornerTopShape {
5901 Bevel,
5903 Notch,
5905 Round,
5907 Scoop,
5909 Square,
5911 Squircle,
5913 Raw(Raw),
5915}
5916
5917impl fmt::Display for CornerTopShape {
5918 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5919 match self {
5920 Self::Bevel => f.write_str("bevel"),
5921 Self::Notch => f.write_str("notch"),
5922 Self::Round => f.write_str("round"),
5923 Self::Scoop => f.write_str("scoop"),
5924 Self::Square => f.write_str("square"),
5925 Self::Squircle => f.write_str("squircle"),
5926 Self::Raw(v) => v.fmt(f),
5927 }
5928 }
5929}
5930
5931impl From<Raw> for CornerTopShape {
5932 fn from(v: Raw) -> Self {
5933 Self::Raw(v)
5934 }
5935}
5936
5937#[derive(Debug, Clone, PartialEq)]
5939#[non_exhaustive]
5940pub enum CounterIncrement {
5941 None,
5943 Raw(Raw),
5945}
5946
5947impl fmt::Display for CounterIncrement {
5948 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5949 match self {
5950 Self::None => f.write_str("none"),
5951 Self::Raw(v) => v.fmt(f),
5952 }
5953 }
5954}
5955
5956impl From<Raw> for CounterIncrement {
5957 fn from(v: Raw) -> Self {
5958 Self::Raw(v)
5959 }
5960}
5961
5962#[derive(Debug, Clone, PartialEq)]
5964#[non_exhaustive]
5965pub enum CounterReset {
5966 None,
5968 Raw(Raw),
5970}
5971
5972impl fmt::Display for CounterReset {
5973 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5974 match self {
5975 Self::None => f.write_str("none"),
5976 Self::Raw(v) => v.fmt(f),
5977 }
5978 }
5979}
5980
5981impl From<Raw> for CounterReset {
5982 fn from(v: Raw) -> Self {
5983 Self::Raw(v)
5984 }
5985}
5986
5987#[derive(Debug, Clone, PartialEq)]
5989#[non_exhaustive]
5990pub enum CounterSet {
5991 None,
5993 Raw(Raw),
5995}
5996
5997impl fmt::Display for CounterSet {
5998 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
5999 match self {
6000 Self::None => f.write_str("none"),
6001 Self::Raw(v) => v.fmt(f),
6002 }
6003 }
6004}
6005
6006impl From<Raw> for CounterSet {
6007 fn from(v: Raw) -> Self {
6008 Self::Raw(v)
6009 }
6010}
6011
6012#[derive(Debug, Clone, PartialEq)]
6014#[non_exhaustive]
6015pub enum Cursor {
6016 Alias,
6018 AllScroll,
6020 Auto,
6022 Cell,
6024 ColResize,
6026 ContextMenu,
6028 Copy,
6030 Crosshair,
6032 Default,
6034 EResize,
6036 EwResize,
6038 Grab,
6040 Grabbing,
6042 Help,
6044 Move,
6046 NResize,
6048 NeResize,
6050 NeswResize,
6052 NoDrop,
6054 None,
6056 NotAllowed,
6058 NsResize,
6060 NwResize,
6062 NwseResize,
6064 Pointer,
6066 Progress,
6068 RowResize,
6070 SResize,
6072 SeResize,
6074 SwResize,
6076 Text,
6078 VerticalText,
6080 WResize,
6082 Wait,
6084 ZoomIn,
6086 ZoomOut,
6088 Raw(Raw),
6090}
6091
6092impl fmt::Display for Cursor {
6093 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6094 match self {
6095 Self::Alias => f.write_str("alias"),
6096 Self::AllScroll => f.write_str("all-scroll"),
6097 Self::Auto => f.write_str("auto"),
6098 Self::Cell => f.write_str("cell"),
6099 Self::ColResize => f.write_str("col-resize"),
6100 Self::ContextMenu => f.write_str("context-menu"),
6101 Self::Copy => f.write_str("copy"),
6102 Self::Crosshair => f.write_str("crosshair"),
6103 Self::Default => f.write_str("default"),
6104 Self::EResize => f.write_str("e-resize"),
6105 Self::EwResize => f.write_str("ew-resize"),
6106 Self::Grab => f.write_str("grab"),
6107 Self::Grabbing => f.write_str("grabbing"),
6108 Self::Help => f.write_str("help"),
6109 Self::Move => f.write_str("move"),
6110 Self::NResize => f.write_str("n-resize"),
6111 Self::NeResize => f.write_str("ne-resize"),
6112 Self::NeswResize => f.write_str("nesw-resize"),
6113 Self::NoDrop => f.write_str("no-drop"),
6114 Self::None => f.write_str("none"),
6115 Self::NotAllowed => f.write_str("not-allowed"),
6116 Self::NsResize => f.write_str("ns-resize"),
6117 Self::NwResize => f.write_str("nw-resize"),
6118 Self::NwseResize => f.write_str("nwse-resize"),
6119 Self::Pointer => f.write_str("pointer"),
6120 Self::Progress => f.write_str("progress"),
6121 Self::RowResize => f.write_str("row-resize"),
6122 Self::SResize => f.write_str("s-resize"),
6123 Self::SeResize => f.write_str("se-resize"),
6124 Self::SwResize => f.write_str("sw-resize"),
6125 Self::Text => f.write_str("text"),
6126 Self::VerticalText => f.write_str("vertical-text"),
6127 Self::WResize => f.write_str("w-resize"),
6128 Self::Wait => f.write_str("wait"),
6129 Self::ZoomIn => f.write_str("zoom-in"),
6130 Self::ZoomOut => f.write_str("zoom-out"),
6131 Self::Raw(v) => v.fmt(f),
6132 }
6133 }
6134}
6135
6136impl From<Raw> for Cursor {
6137 fn from(v: Raw) -> Self {
6138 Self::Raw(v)
6139 }
6140}
6141
6142#[derive(Debug, Clone, PartialEq)]
6144#[non_exhaustive]
6145pub enum Cx {
6146 Length(Length),
6148 Percentage(Percentage),
6150}
6151
6152impl fmt::Display for Cx {
6153 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6154 match self {
6155 Self::Length(v) => v.fmt(f),
6156 Self::Percentage(v) => v.fmt(f),
6157 }
6158 }
6159}
6160
6161impl From<Length> for Cx {
6162 fn from(v: Length) -> Self {
6163 Self::Length(v)
6164 }
6165}
6166
6167impl From<Percentage> for Cx {
6168 fn from(v: Percentage) -> Self {
6169 Self::Percentage(v)
6170 }
6171}
6172
6173#[derive(Debug, Clone, PartialEq)]
6175#[non_exhaustive]
6176pub enum Cy {
6177 Length(Length),
6179 Percentage(Percentage),
6181}
6182
6183impl fmt::Display for Cy {
6184 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6185 match self {
6186 Self::Length(v) => v.fmt(f),
6187 Self::Percentage(v) => v.fmt(f),
6188 }
6189 }
6190}
6191
6192impl From<Length> for Cy {
6193 fn from(v: Length) -> Self {
6194 Self::Length(v)
6195 }
6196}
6197
6198impl From<Percentage> for Cy {
6199 fn from(v: Percentage) -> Self {
6200 Self::Percentage(v)
6201 }
6202}
6203
6204#[derive(Debug, Clone, PartialEq)]
6206#[non_exhaustive]
6207pub enum D {
6208 None,
6210 Raw(Raw),
6212}
6213
6214impl fmt::Display for D {
6215 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6216 match self {
6217 Self::None => f.write_str("none"),
6218 Self::Raw(v) => v.fmt(f),
6219 }
6220 }
6221}
6222
6223impl From<Raw> for D {
6224 fn from(v: Raw) -> Self {
6225 Self::Raw(v)
6226 }
6227}
6228
6229#[derive(Debug, Clone, PartialEq)]
6231#[non_exhaustive]
6232pub enum Direction {
6233 Ltr,
6235 Rtl,
6237}
6238
6239impl fmt::Display for Direction {
6240 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6241 match self {
6242 Self::Ltr => f.write_str("ltr"),
6243 Self::Rtl => f.write_str("rtl"),
6244 }
6245 }
6246}
6247
6248#[derive(Debug, Clone, PartialEq)]
6250#[non_exhaustive]
6251pub enum Display {
6252 Block,
6254 Contents,
6256 Flex,
6258 Flow,
6260 FlowRoot,
6262 Grid,
6264 Inline,
6266 InlineBlock,
6268 InlineFlex,
6270 InlineGrid,
6272 InlineListItem,
6274 InlineTable,
6276 None,
6278 Ruby,
6280 RubyBase,
6282 RubyBaseContainer,
6284 RubyText,
6286 RubyTextContainer,
6288 RunIn,
6290 Table,
6292 TableCaption,
6294 TableCell,
6296 TableColumn,
6298 TableColumnGroup,
6300 TableFooterGroup,
6302 TableHeaderGroup,
6304 TableRow,
6306 TableRowGroup,
6308 Raw(Raw),
6310}
6311
6312impl fmt::Display for Display {
6313 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6314 match self {
6315 Self::Block => f.write_str("block"),
6316 Self::Contents => f.write_str("contents"),
6317 Self::Flex => f.write_str("flex"),
6318 Self::Flow => f.write_str("flow"),
6319 Self::FlowRoot => f.write_str("flow-root"),
6320 Self::Grid => f.write_str("grid"),
6321 Self::Inline => f.write_str("inline"),
6322 Self::InlineBlock => f.write_str("inline-block"),
6323 Self::InlineFlex => f.write_str("inline-flex"),
6324 Self::InlineGrid => f.write_str("inline-grid"),
6325 Self::InlineListItem => f.write_str("inline-list-item"),
6326 Self::InlineTable => f.write_str("inline-table"),
6327 Self::None => f.write_str("none"),
6328 Self::Ruby => f.write_str("ruby"),
6329 Self::RubyBase => f.write_str("ruby-base"),
6330 Self::RubyBaseContainer => f.write_str("ruby-base-container"),
6331 Self::RubyText => f.write_str("ruby-text"),
6332 Self::RubyTextContainer => f.write_str("ruby-text-container"),
6333 Self::RunIn => f.write_str("run-in"),
6334 Self::Table => f.write_str("table"),
6335 Self::TableCaption => f.write_str("table-caption"),
6336 Self::TableCell => f.write_str("table-cell"),
6337 Self::TableColumn => f.write_str("table-column"),
6338 Self::TableColumnGroup => f.write_str("table-column-group"),
6339 Self::TableFooterGroup => f.write_str("table-footer-group"),
6340 Self::TableHeaderGroup => f.write_str("table-header-group"),
6341 Self::TableRow => f.write_str("table-row"),
6342 Self::TableRowGroup => f.write_str("table-row-group"),
6343 Self::Raw(v) => v.fmt(f),
6344 }
6345 }
6346}
6347
6348impl From<Raw> for Display {
6349 fn from(v: Raw) -> Self {
6350 Self::Raw(v)
6351 }
6352}
6353
6354#[derive(Debug, Clone, PartialEq)]
6356#[non_exhaustive]
6357pub enum DominantBaseline {
6358 Alphabetic,
6360 Auto,
6362 Central,
6364 Hanging,
6366 Ideographic,
6368 Mathematical,
6370 Middle,
6372 TextBottom,
6374 TextTop,
6376}
6377
6378impl fmt::Display for DominantBaseline {
6379 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6380 match self {
6381 Self::Alphabetic => f.write_str("alphabetic"),
6382 Self::Auto => f.write_str("auto"),
6383 Self::Central => f.write_str("central"),
6384 Self::Hanging => f.write_str("hanging"),
6385 Self::Ideographic => f.write_str("ideographic"),
6386 Self::Mathematical => f.write_str("mathematical"),
6387 Self::Middle => f.write_str("middle"),
6388 Self::TextBottom => f.write_str("text-bottom"),
6389 Self::TextTop => f.write_str("text-top"),
6390 }
6391 }
6392}
6393
6394#[derive(Debug, Clone, PartialEq)]
6396#[non_exhaustive]
6397pub enum DynamicRangeLimit {
6398 Constrained,
6400 NoLimit,
6402 Standard,
6404 Raw(Raw),
6406}
6407
6408impl fmt::Display for DynamicRangeLimit {
6409 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6410 match self {
6411 Self::Constrained => f.write_str("constrained"),
6412 Self::NoLimit => f.write_str("no-limit"),
6413 Self::Standard => f.write_str("standard"),
6414 Self::Raw(v) => v.fmt(f),
6415 }
6416 }
6417}
6418
6419impl From<Raw> for DynamicRangeLimit {
6420 fn from(v: Raw) -> Self {
6421 Self::Raw(v)
6422 }
6423}
6424
6425#[derive(Debug, Clone, PartialEq)]
6427#[non_exhaustive]
6428pub enum EmptyCells {
6429 Hide,
6431 Show,
6433}
6434
6435impl fmt::Display for EmptyCells {
6436 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6437 match self {
6438 Self::Hide => f.write_str("hide"),
6439 Self::Show => f.write_str("show"),
6440 }
6441 }
6442}
6443
6444#[derive(Debug, Clone, PartialEq)]
6446#[non_exhaustive]
6447pub enum Fill {
6448 ContextFill,
6450 ContextStroke,
6452 None,
6454 Color(Color),
6456 Url(Url),
6458 Raw(Raw),
6460}
6461
6462impl fmt::Display for Fill {
6463 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6464 match self {
6465 Self::ContextFill => f.write_str("context-fill"),
6466 Self::ContextStroke => f.write_str("context-stroke"),
6467 Self::None => f.write_str("none"),
6468 Self::Color(v) => v.fmt(f),
6469 Self::Url(v) => v.fmt(f),
6470 Self::Raw(v) => v.fmt(f),
6471 }
6472 }
6473}
6474
6475impl From<Color> for Fill {
6476 fn from(v: Color) -> Self {
6477 Self::Color(v)
6478 }
6479}
6480
6481impl From<Url> for Fill {
6482 fn from(v: Url) -> Self {
6483 Self::Url(v)
6484 }
6485}
6486
6487impl From<Raw> for Fill {
6488 fn from(v: Raw) -> Self {
6489 Self::Raw(v)
6490 }
6491}
6492
6493#[derive(Debug, Clone, PartialEq)]
6495#[non_exhaustive]
6496pub enum FillOpacity {
6497 Percentage(Percentage),
6499 Number(f64),
6501}
6502
6503impl fmt::Display for FillOpacity {
6504 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6505 match self {
6506 Self::Percentage(v) => v.fmt(f),
6507 Self::Number(v) => v.fmt(f),
6508 }
6509 }
6510}
6511
6512impl From<Percentage> for FillOpacity {
6513 fn from(v: Percentage) -> Self {
6514 Self::Percentage(v)
6515 }
6516}
6517
6518impl From<f64> for FillOpacity {
6519 fn from(v: f64) -> Self {
6520 Self::Number(v)
6521 }
6522}
6523
6524impl From<i32> for FillOpacity {
6525 fn from(v: i32) -> Self {
6526 Self::Number(f64::from(v))
6527 }
6528}
6529
6530#[derive(Debug, Clone, PartialEq)]
6532#[non_exhaustive]
6533pub enum FillRule {
6534 Evenodd,
6536 Nonzero,
6538}
6539
6540impl fmt::Display for FillRule {
6541 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6542 match self {
6543 Self::Evenodd => f.write_str("evenodd"),
6544 Self::Nonzero => f.write_str("nonzero"),
6545 }
6546 }
6547}
6548
6549#[derive(Debug, Clone, PartialEq)]
6551#[non_exhaustive]
6552pub enum Filter {
6553 None,
6555 Url(Url),
6557 Raw(Raw),
6559}
6560
6561impl fmt::Display for Filter {
6562 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6563 match self {
6564 Self::None => f.write_str("none"),
6565 Self::Url(v) => v.fmt(f),
6566 Self::Raw(v) => v.fmt(f),
6567 }
6568 }
6569}
6570
6571impl From<Url> for Filter {
6572 fn from(v: Url) -> Self {
6573 Self::Url(v)
6574 }
6575}
6576
6577impl From<Raw> for Filter {
6578 fn from(v: Raw) -> Self {
6579 Self::Raw(v)
6580 }
6581}
6582
6583#[derive(Debug, Clone, PartialEq)]
6585#[non_exhaustive]
6586pub enum Flex {
6587 Auto,
6589 Content,
6591 FitContent,
6593 MaxContent,
6595 MinContent,
6597 None,
6599 Length(Length),
6601 Percentage(Percentage),
6603 Number(f64),
6605 Raw(Raw),
6607}
6608
6609impl fmt::Display for Flex {
6610 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6611 match self {
6612 Self::Auto => f.write_str("auto"),
6613 Self::Content => f.write_str("content"),
6614 Self::FitContent => f.write_str("fit-content"),
6615 Self::MaxContent => f.write_str("max-content"),
6616 Self::MinContent => f.write_str("min-content"),
6617 Self::None => f.write_str("none"),
6618 Self::Length(v) => v.fmt(f),
6619 Self::Percentage(v) => v.fmt(f),
6620 Self::Number(v) => v.fmt(f),
6621 Self::Raw(v) => v.fmt(f),
6622 }
6623 }
6624}
6625
6626impl From<Length> for Flex {
6627 fn from(v: Length) -> Self {
6628 Self::Length(v)
6629 }
6630}
6631
6632impl From<Percentage> for Flex {
6633 fn from(v: Percentage) -> Self {
6634 Self::Percentage(v)
6635 }
6636}
6637
6638impl From<f64> for Flex {
6639 fn from(v: f64) -> Self {
6640 Self::Number(v)
6641 }
6642}
6643
6644impl From<i32> for Flex {
6645 fn from(v: i32) -> Self {
6646 Self::Number(f64::from(v))
6647 }
6648}
6649
6650impl From<Raw> for Flex {
6651 fn from(v: Raw) -> Self {
6652 Self::Raw(v)
6653 }
6654}
6655
6656#[derive(Debug, Clone, PartialEq)]
6658#[non_exhaustive]
6659pub enum FlexBasis {
6660 Auto,
6662 Content,
6664 FitContent,
6666 MaxContent,
6668 MinContent,
6670 Length(Length),
6672 Percentage(Percentage),
6674 Raw(Raw),
6676}
6677
6678impl fmt::Display for FlexBasis {
6679 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6680 match self {
6681 Self::Auto => f.write_str("auto"),
6682 Self::Content => f.write_str("content"),
6683 Self::FitContent => f.write_str("fit-content"),
6684 Self::MaxContent => f.write_str("max-content"),
6685 Self::MinContent => f.write_str("min-content"),
6686 Self::Length(v) => v.fmt(f),
6687 Self::Percentage(v) => v.fmt(f),
6688 Self::Raw(v) => v.fmt(f),
6689 }
6690 }
6691}
6692
6693impl From<Length> for FlexBasis {
6694 fn from(v: Length) -> Self {
6695 Self::Length(v)
6696 }
6697}
6698
6699impl From<Percentage> for FlexBasis {
6700 fn from(v: Percentage) -> Self {
6701 Self::Percentage(v)
6702 }
6703}
6704
6705impl From<Raw> for FlexBasis {
6706 fn from(v: Raw) -> Self {
6707 Self::Raw(v)
6708 }
6709}
6710
6711#[derive(Debug, Clone, PartialEq)]
6713#[non_exhaustive]
6714pub enum FlexDirection {
6715 Column,
6717 ColumnReverse,
6719 Row,
6721 RowReverse,
6723}
6724
6725impl fmt::Display for FlexDirection {
6726 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6727 match self {
6728 Self::Column => f.write_str("column"),
6729 Self::ColumnReverse => f.write_str("column-reverse"),
6730 Self::Row => f.write_str("row"),
6731 Self::RowReverse => f.write_str("row-reverse"),
6732 }
6733 }
6734}
6735
6736#[derive(Debug, Clone, PartialEq)]
6738#[non_exhaustive]
6739pub enum FlexFlow {
6740 Balance,
6742 Column,
6744 ColumnReverse,
6746 Nowrap,
6748 Row,
6750 RowReverse,
6752 Wrap,
6754 WrapReverse,
6756 Raw(Raw),
6758}
6759
6760impl fmt::Display for FlexFlow {
6761 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6762 match self {
6763 Self::Balance => f.write_str("balance"),
6764 Self::Column => f.write_str("column"),
6765 Self::ColumnReverse => f.write_str("column-reverse"),
6766 Self::Nowrap => f.write_str("nowrap"),
6767 Self::Row => f.write_str("row"),
6768 Self::RowReverse => f.write_str("row-reverse"),
6769 Self::Wrap => f.write_str("wrap"),
6770 Self::WrapReverse => f.write_str("wrap-reverse"),
6771 Self::Raw(v) => v.fmt(f),
6772 }
6773 }
6774}
6775
6776impl From<Raw> for FlexFlow {
6777 fn from(v: Raw) -> Self {
6778 Self::Raw(v)
6779 }
6780}
6781
6782#[derive(Debug, Clone, PartialEq)]
6784#[non_exhaustive]
6785pub enum FlexWrap {
6786 Balance,
6788 Nowrap,
6790 Wrap,
6792 WrapReverse,
6794 Raw(Raw),
6796}
6797
6798impl fmt::Display for FlexWrap {
6799 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6800 match self {
6801 Self::Balance => f.write_str("balance"),
6802 Self::Nowrap => f.write_str("nowrap"),
6803 Self::Wrap => f.write_str("wrap"),
6804 Self::WrapReverse => f.write_str("wrap-reverse"),
6805 Self::Raw(v) => v.fmt(f),
6806 }
6807 }
6808}
6809
6810impl From<Raw> for FlexWrap {
6811 fn from(v: Raw) -> Self {
6812 Self::Raw(v)
6813 }
6814}
6815
6816#[derive(Debug, Clone, PartialEq)]
6818#[non_exhaustive]
6819pub enum Float {
6820 InlineEnd,
6822 InlineStart,
6824 Left,
6826 None,
6828 Right,
6830}
6831
6832impl fmt::Display for Float {
6833 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6834 match self {
6835 Self::InlineEnd => f.write_str("inline-end"),
6836 Self::InlineStart => f.write_str("inline-start"),
6837 Self::Left => f.write_str("left"),
6838 Self::None => f.write_str("none"),
6839 Self::Right => f.write_str("right"),
6840 }
6841 }
6842}
6843
6844#[derive(Debug, Clone, PartialEq)]
6846#[non_exhaustive]
6847pub enum FloodOpacity {
6848 Percentage(Percentage),
6850 Number(f64),
6852}
6853
6854impl fmt::Display for FloodOpacity {
6855 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6856 match self {
6857 Self::Percentage(v) => v.fmt(f),
6858 Self::Number(v) => v.fmt(f),
6859 }
6860 }
6861}
6862
6863impl From<Percentage> for FloodOpacity {
6864 fn from(v: Percentage) -> Self {
6865 Self::Percentage(v)
6866 }
6867}
6868
6869impl From<f64> for FloodOpacity {
6870 fn from(v: f64) -> Self {
6871 Self::Number(v)
6872 }
6873}
6874
6875impl From<i32> for FloodOpacity {
6876 fn from(v: i32) -> Self {
6877 Self::Number(f64::from(v))
6878 }
6879}
6880
6881#[derive(Debug, Clone, PartialEq)]
6883#[non_exhaustive]
6884pub enum Font {
6885 Caption,
6887 Icon,
6889 Menu,
6891 MessageBox,
6893 SmallCaption,
6895 StatusBar,
6897 Raw(Raw),
6899}
6900
6901impl fmt::Display for Font {
6902 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6903 match self {
6904 Self::Caption => f.write_str("caption"),
6905 Self::Icon => f.write_str("icon"),
6906 Self::Menu => f.write_str("menu"),
6907 Self::MessageBox => f.write_str("message-box"),
6908 Self::SmallCaption => f.write_str("small-caption"),
6909 Self::StatusBar => f.write_str("status-bar"),
6910 Self::Raw(v) => v.fmt(f),
6911 }
6912 }
6913}
6914
6915impl From<Raw> for Font {
6916 fn from(v: Raw) -> Self {
6917 Self::Raw(v)
6918 }
6919}
6920
6921#[derive(Debug, Clone, PartialEq)]
6923#[non_exhaustive]
6924pub enum FontFamily {
6925 Cursive,
6927 Emoji,
6929 Fangsong,
6931 Fantasy,
6933 Math,
6935 Monospace,
6937 SansSerif,
6939 Serif,
6941 SystemUi,
6943 UiMonospace,
6945 UiRounded,
6947 UiSansSerif,
6949 UiSerif,
6951 Quoted(Quoted),
6953 Raw(Raw),
6955}
6956
6957impl fmt::Display for FontFamily {
6958 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
6959 match self {
6960 Self::Cursive => f.write_str("cursive"),
6961 Self::Emoji => f.write_str("emoji"),
6962 Self::Fangsong => f.write_str("fangsong"),
6963 Self::Fantasy => f.write_str("fantasy"),
6964 Self::Math => f.write_str("math"),
6965 Self::Monospace => f.write_str("monospace"),
6966 Self::SansSerif => f.write_str("sans-serif"),
6967 Self::Serif => f.write_str("serif"),
6968 Self::SystemUi => f.write_str("system-ui"),
6969 Self::UiMonospace => f.write_str("ui-monospace"),
6970 Self::UiRounded => f.write_str("ui-rounded"),
6971 Self::UiSansSerif => f.write_str("ui-sans-serif"),
6972 Self::UiSerif => f.write_str("ui-serif"),
6973 Self::Quoted(v) => v.fmt(f),
6974 Self::Raw(v) => v.fmt(f),
6975 }
6976 }
6977}
6978
6979impl From<Quoted> for FontFamily {
6980 fn from(v: Quoted) -> Self {
6981 Self::Quoted(v)
6982 }
6983}
6984
6985impl From<Raw> for FontFamily {
6986 fn from(v: Raw) -> Self {
6987 Self::Raw(v)
6988 }
6989}
6990
6991#[derive(Debug, Clone, PartialEq)]
6993#[non_exhaustive]
6994pub enum FontFeatureSettings {
6995 Normal,
6997 Quoted(Quoted),
6999 Raw(Raw),
7001}
7002
7003impl fmt::Display for FontFeatureSettings {
7004 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7005 match self {
7006 Self::Normal => f.write_str("normal"),
7007 Self::Quoted(v) => v.fmt(f),
7008 Self::Raw(v) => v.fmt(f),
7009 }
7010 }
7011}
7012
7013impl From<Quoted> for FontFeatureSettings {
7014 fn from(v: Quoted) -> Self {
7015 Self::Quoted(v)
7016 }
7017}
7018
7019impl From<Raw> for FontFeatureSettings {
7020 fn from(v: Raw) -> Self {
7021 Self::Raw(v)
7022 }
7023}
7024
7025#[derive(Debug, Clone, PartialEq)]
7027#[non_exhaustive]
7028pub enum FontKerning {
7029 Auto,
7031 None,
7033 Normal,
7035}
7036
7037impl fmt::Display for FontKerning {
7038 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7039 match self {
7040 Self::Auto => f.write_str("auto"),
7041 Self::None => f.write_str("none"),
7042 Self::Normal => f.write_str("normal"),
7043 }
7044 }
7045}
7046
7047#[derive(Debug, Clone, PartialEq)]
7049#[non_exhaustive]
7050pub enum FontLanguageOverride {
7051 Normal,
7053 Quoted(Quoted),
7055}
7056
7057impl fmt::Display for FontLanguageOverride {
7058 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7059 match self {
7060 Self::Normal => f.write_str("normal"),
7061 Self::Quoted(v) => v.fmt(f),
7062 }
7063 }
7064}
7065
7066impl From<Quoted> for FontLanguageOverride {
7067 fn from(v: Quoted) -> Self {
7068 Self::Quoted(v)
7069 }
7070}
7071
7072#[derive(Debug, Clone, PartialEq)]
7074#[non_exhaustive]
7075pub enum FontOpticalSizing {
7076 Auto,
7078 None,
7080}
7081
7082impl fmt::Display for FontOpticalSizing {
7083 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7084 match self {
7085 Self::Auto => f.write_str("auto"),
7086 Self::None => f.write_str("none"),
7087 }
7088 }
7089}
7090
7091#[derive(Debug, Clone, PartialEq)]
7093#[non_exhaustive]
7094pub enum FontPalette {
7095 Dark,
7097 Light,
7099 Normal,
7101 Raw(Raw),
7103}
7104
7105impl fmt::Display for FontPalette {
7106 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7107 match self {
7108 Self::Dark => f.write_str("dark"),
7109 Self::Light => f.write_str("light"),
7110 Self::Normal => f.write_str("normal"),
7111 Self::Raw(v) => v.fmt(f),
7112 }
7113 }
7114}
7115
7116impl From<Raw> for FontPalette {
7117 fn from(v: Raw) -> Self {
7118 Self::Raw(v)
7119 }
7120}
7121
7122#[derive(Debug, Clone, PartialEq)]
7124#[non_exhaustive]
7125pub enum FontSize {
7126 Large,
7128 Larger,
7130 Math,
7132 Medium,
7134 Small,
7136 Smaller,
7138 XLarge,
7140 XSmall,
7142 XxLarge,
7144 XxSmall,
7146 XxxLarge,
7148 Length(Length),
7150 Percentage(Percentage),
7152}
7153
7154impl fmt::Display for FontSize {
7155 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7156 match self {
7157 Self::Large => f.write_str("large"),
7158 Self::Larger => f.write_str("larger"),
7159 Self::Math => f.write_str("math"),
7160 Self::Medium => f.write_str("medium"),
7161 Self::Small => f.write_str("small"),
7162 Self::Smaller => f.write_str("smaller"),
7163 Self::XLarge => f.write_str("x-large"),
7164 Self::XSmall => f.write_str("x-small"),
7165 Self::XxLarge => f.write_str("xx-large"),
7166 Self::XxSmall => f.write_str("xx-small"),
7167 Self::XxxLarge => f.write_str("xxx-large"),
7168 Self::Length(v) => v.fmt(f),
7169 Self::Percentage(v) => v.fmt(f),
7170 }
7171 }
7172}
7173
7174impl From<Length> for FontSize {
7175 fn from(v: Length) -> Self {
7176 Self::Length(v)
7177 }
7178}
7179
7180impl From<Percentage> for FontSize {
7181 fn from(v: Percentage) -> Self {
7182 Self::Percentage(v)
7183 }
7184}
7185
7186#[derive(Debug, Clone, PartialEq)]
7188#[non_exhaustive]
7189pub enum FontSizeAdjust {
7190 FromFont,
7192 None,
7194 Number(f64),
7196 Raw(Raw),
7198}
7199
7200impl fmt::Display for FontSizeAdjust {
7201 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7202 match self {
7203 Self::FromFont => f.write_str("from-font"),
7204 Self::None => f.write_str("none"),
7205 Self::Number(v) => v.fmt(f),
7206 Self::Raw(v) => v.fmt(f),
7207 }
7208 }
7209}
7210
7211impl From<f64> for FontSizeAdjust {
7212 fn from(v: f64) -> Self {
7213 Self::Number(v)
7214 }
7215}
7216
7217impl From<i32> for FontSizeAdjust {
7218 fn from(v: i32) -> Self {
7219 Self::Number(f64::from(v))
7220 }
7221}
7222
7223impl From<Raw> for FontSizeAdjust {
7224 fn from(v: Raw) -> Self {
7225 Self::Raw(v)
7226 }
7227}
7228
7229#[derive(Debug, Clone, PartialEq)]
7231#[non_exhaustive]
7232pub enum FontStyle {
7233 Italic,
7235 Normal,
7237 Oblique,
7239 Raw(Raw),
7241}
7242
7243impl fmt::Display for FontStyle {
7244 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7245 match self {
7246 Self::Italic => f.write_str("italic"),
7247 Self::Normal => f.write_str("normal"),
7248 Self::Oblique => f.write_str("oblique"),
7249 Self::Raw(v) => v.fmt(f),
7250 }
7251 }
7252}
7253
7254impl From<Raw> for FontStyle {
7255 fn from(v: Raw) -> Self {
7256 Self::Raw(v)
7257 }
7258}
7259
7260#[derive(Debug, Clone, PartialEq)]
7262#[non_exhaustive]
7263pub enum FontSynthesis {
7264 None,
7266 Position,
7268 SmallCaps,
7270 Style,
7272 Weight,
7274 Raw(Raw),
7276}
7277
7278impl fmt::Display for FontSynthesis {
7279 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7280 match self {
7281 Self::None => f.write_str("none"),
7282 Self::Position => f.write_str("position"),
7283 Self::SmallCaps => f.write_str("small-caps"),
7284 Self::Style => f.write_str("style"),
7285 Self::Weight => f.write_str("weight"),
7286 Self::Raw(v) => v.fmt(f),
7287 }
7288 }
7289}
7290
7291impl From<Raw> for FontSynthesis {
7292 fn from(v: Raw) -> Self {
7293 Self::Raw(v)
7294 }
7295}
7296
7297#[derive(Debug, Clone, PartialEq)]
7299#[non_exhaustive]
7300pub enum FontSynthesisSmallCaps {
7301 Auto,
7303 None,
7305}
7306
7307impl fmt::Display for FontSynthesisSmallCaps {
7308 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7309 match self {
7310 Self::Auto => f.write_str("auto"),
7311 Self::None => f.write_str("none"),
7312 }
7313 }
7314}
7315
7316#[derive(Debug, Clone, PartialEq)]
7318#[non_exhaustive]
7319pub enum FontSynthesisStyle {
7320 Auto,
7322 None,
7324}
7325
7326impl fmt::Display for FontSynthesisStyle {
7327 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7328 match self {
7329 Self::Auto => f.write_str("auto"),
7330 Self::None => f.write_str("none"),
7331 }
7332 }
7333}
7334
7335#[derive(Debug, Clone, PartialEq)]
7337#[non_exhaustive]
7338pub enum FontSynthesisWeight {
7339 Auto,
7341 None,
7343}
7344
7345impl fmt::Display for FontSynthesisWeight {
7346 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7347 match self {
7348 Self::Auto => f.write_str("auto"),
7349 Self::None => f.write_str("none"),
7350 }
7351 }
7352}
7353
7354#[derive(Debug, Clone, PartialEq)]
7356#[non_exhaustive]
7357pub enum FontVariant {
7358 AllPetiteCaps,
7360 AllSmallCaps,
7362 CommonLigatures,
7364 Contextual,
7366 DiagonalFractions,
7368 DiscretionaryLigatures,
7370 FullWidth,
7372 HistoricalForms,
7374 HistoricalLigatures,
7376 Jis04,
7378 Jis78,
7380 Jis83,
7382 Jis90,
7384 LiningNums,
7386 NoCommonLigatures,
7388 NoContextual,
7390 NoDiscretionaryLigatures,
7392 NoHistoricalLigatures,
7394 None,
7396 Normal,
7398 OldstyleNums,
7400 Ordinal,
7402 PetiteCaps,
7404 ProportionalNums,
7406 ProportionalWidth,
7408 Ruby,
7410 Simplified,
7412 SlashedZero,
7414 SmallCaps,
7416 StackedFractions,
7418 TabularNums,
7420 TitlingCaps,
7422 Traditional,
7424 Unicase,
7426 Raw(Raw),
7428}
7429
7430impl fmt::Display for FontVariant {
7431 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7432 match self {
7433 Self::AllPetiteCaps => f.write_str("all-petite-caps"),
7434 Self::AllSmallCaps => f.write_str("all-small-caps"),
7435 Self::CommonLigatures => f.write_str("common-ligatures"),
7436 Self::Contextual => f.write_str("contextual"),
7437 Self::DiagonalFractions => f.write_str("diagonal-fractions"),
7438 Self::DiscretionaryLigatures => f.write_str("discretionary-ligatures"),
7439 Self::FullWidth => f.write_str("full-width"),
7440 Self::HistoricalForms => f.write_str("historical-forms"),
7441 Self::HistoricalLigatures => f.write_str("historical-ligatures"),
7442 Self::Jis04 => f.write_str("jis04"),
7443 Self::Jis78 => f.write_str("jis78"),
7444 Self::Jis83 => f.write_str("jis83"),
7445 Self::Jis90 => f.write_str("jis90"),
7446 Self::LiningNums => f.write_str("lining-nums"),
7447 Self::NoCommonLigatures => f.write_str("no-common-ligatures"),
7448 Self::NoContextual => f.write_str("no-contextual"),
7449 Self::NoDiscretionaryLigatures => f.write_str("no-discretionary-ligatures"),
7450 Self::NoHistoricalLigatures => f.write_str("no-historical-ligatures"),
7451 Self::None => f.write_str("none"),
7452 Self::Normal => f.write_str("normal"),
7453 Self::OldstyleNums => f.write_str("oldstyle-nums"),
7454 Self::Ordinal => f.write_str("ordinal"),
7455 Self::PetiteCaps => f.write_str("petite-caps"),
7456 Self::ProportionalNums => f.write_str("proportional-nums"),
7457 Self::ProportionalWidth => f.write_str("proportional-width"),
7458 Self::Ruby => f.write_str("ruby"),
7459 Self::Simplified => f.write_str("simplified"),
7460 Self::SlashedZero => f.write_str("slashed-zero"),
7461 Self::SmallCaps => f.write_str("small-caps"),
7462 Self::StackedFractions => f.write_str("stacked-fractions"),
7463 Self::TabularNums => f.write_str("tabular-nums"),
7464 Self::TitlingCaps => f.write_str("titling-caps"),
7465 Self::Traditional => f.write_str("traditional"),
7466 Self::Unicase => f.write_str("unicase"),
7467 Self::Raw(v) => v.fmt(f),
7468 }
7469 }
7470}
7471
7472impl From<Raw> for FontVariant {
7473 fn from(v: Raw) -> Self {
7474 Self::Raw(v)
7475 }
7476}
7477
7478#[derive(Debug, Clone, PartialEq)]
7480#[non_exhaustive]
7481pub enum FontVariantAlternates {
7482 HistoricalForms,
7484 Normal,
7486 Raw(Raw),
7488}
7489
7490impl fmt::Display for FontVariantAlternates {
7491 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7492 match self {
7493 Self::HistoricalForms => f.write_str("historical-forms"),
7494 Self::Normal => f.write_str("normal"),
7495 Self::Raw(v) => v.fmt(f),
7496 }
7497 }
7498}
7499
7500impl From<Raw> for FontVariantAlternates {
7501 fn from(v: Raw) -> Self {
7502 Self::Raw(v)
7503 }
7504}
7505
7506#[derive(Debug, Clone, PartialEq)]
7508#[non_exhaustive]
7509pub enum FontVariantCaps {
7510 AllPetiteCaps,
7512 AllSmallCaps,
7514 Normal,
7516 PetiteCaps,
7518 SmallCaps,
7520 TitlingCaps,
7522 Unicase,
7524}
7525
7526impl fmt::Display for FontVariantCaps {
7527 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7528 match self {
7529 Self::AllPetiteCaps => f.write_str("all-petite-caps"),
7530 Self::AllSmallCaps => f.write_str("all-small-caps"),
7531 Self::Normal => f.write_str("normal"),
7532 Self::PetiteCaps => f.write_str("petite-caps"),
7533 Self::SmallCaps => f.write_str("small-caps"),
7534 Self::TitlingCaps => f.write_str("titling-caps"),
7535 Self::Unicase => f.write_str("unicase"),
7536 }
7537 }
7538}
7539
7540#[derive(Debug, Clone, PartialEq)]
7542#[non_exhaustive]
7543pub enum FontVariantEastAsian {
7544 FullWidth,
7546 Jis04,
7548 Jis78,
7550 Jis83,
7552 Jis90,
7554 Normal,
7556 ProportionalWidth,
7558 Ruby,
7560 Simplified,
7562 Traditional,
7564 Raw(Raw),
7566}
7567
7568impl fmt::Display for FontVariantEastAsian {
7569 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7570 match self {
7571 Self::FullWidth => f.write_str("full-width"),
7572 Self::Jis04 => f.write_str("jis04"),
7573 Self::Jis78 => f.write_str("jis78"),
7574 Self::Jis83 => f.write_str("jis83"),
7575 Self::Jis90 => f.write_str("jis90"),
7576 Self::Normal => f.write_str("normal"),
7577 Self::ProportionalWidth => f.write_str("proportional-width"),
7578 Self::Ruby => f.write_str("ruby"),
7579 Self::Simplified => f.write_str("simplified"),
7580 Self::Traditional => f.write_str("traditional"),
7581 Self::Raw(v) => v.fmt(f),
7582 }
7583 }
7584}
7585
7586impl From<Raw> for FontVariantEastAsian {
7587 fn from(v: Raw) -> Self {
7588 Self::Raw(v)
7589 }
7590}
7591
7592#[derive(Debug, Clone, PartialEq)]
7594#[non_exhaustive]
7595pub enum FontVariantEmoji {
7596 Emoji,
7598 Normal,
7600 Text,
7602 Unicode,
7604}
7605
7606impl fmt::Display for FontVariantEmoji {
7607 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7608 match self {
7609 Self::Emoji => f.write_str("emoji"),
7610 Self::Normal => f.write_str("normal"),
7611 Self::Text => f.write_str("text"),
7612 Self::Unicode => f.write_str("unicode"),
7613 }
7614 }
7615}
7616
7617#[derive(Debug, Clone, PartialEq)]
7619#[non_exhaustive]
7620pub enum FontVariantLigatures {
7621 CommonLigatures,
7623 Contextual,
7625 DiscretionaryLigatures,
7627 HistoricalLigatures,
7629 NoCommonLigatures,
7631 NoContextual,
7633 NoDiscretionaryLigatures,
7635 NoHistoricalLigatures,
7637 None,
7639 Normal,
7641 Raw(Raw),
7643}
7644
7645impl fmt::Display for FontVariantLigatures {
7646 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7647 match self {
7648 Self::CommonLigatures => f.write_str("common-ligatures"),
7649 Self::Contextual => f.write_str("contextual"),
7650 Self::DiscretionaryLigatures => f.write_str("discretionary-ligatures"),
7651 Self::HistoricalLigatures => f.write_str("historical-ligatures"),
7652 Self::NoCommonLigatures => f.write_str("no-common-ligatures"),
7653 Self::NoContextual => f.write_str("no-contextual"),
7654 Self::NoDiscretionaryLigatures => f.write_str("no-discretionary-ligatures"),
7655 Self::NoHistoricalLigatures => f.write_str("no-historical-ligatures"),
7656 Self::None => f.write_str("none"),
7657 Self::Normal => f.write_str("normal"),
7658 Self::Raw(v) => v.fmt(f),
7659 }
7660 }
7661}
7662
7663impl From<Raw> for FontVariantLigatures {
7664 fn from(v: Raw) -> Self {
7665 Self::Raw(v)
7666 }
7667}
7668
7669#[derive(Debug, Clone, PartialEq)]
7671#[non_exhaustive]
7672pub enum FontVariantNumeric {
7673 DiagonalFractions,
7675 LiningNums,
7677 Normal,
7679 OldstyleNums,
7681 Ordinal,
7683 ProportionalNums,
7685 SlashedZero,
7687 StackedFractions,
7689 TabularNums,
7691 Raw(Raw),
7693}
7694
7695impl fmt::Display for FontVariantNumeric {
7696 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7697 match self {
7698 Self::DiagonalFractions => f.write_str("diagonal-fractions"),
7699 Self::LiningNums => f.write_str("lining-nums"),
7700 Self::Normal => f.write_str("normal"),
7701 Self::OldstyleNums => f.write_str("oldstyle-nums"),
7702 Self::Ordinal => f.write_str("ordinal"),
7703 Self::ProportionalNums => f.write_str("proportional-nums"),
7704 Self::SlashedZero => f.write_str("slashed-zero"),
7705 Self::StackedFractions => f.write_str("stacked-fractions"),
7706 Self::TabularNums => f.write_str("tabular-nums"),
7707 Self::Raw(v) => v.fmt(f),
7708 }
7709 }
7710}
7711
7712impl From<Raw> for FontVariantNumeric {
7713 fn from(v: Raw) -> Self {
7714 Self::Raw(v)
7715 }
7716}
7717
7718#[derive(Debug, Clone, PartialEq)]
7720#[non_exhaustive]
7721pub enum FontVariantPosition {
7722 Normal,
7724 Sub,
7726 Super,
7728}
7729
7730impl fmt::Display for FontVariantPosition {
7731 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7732 match self {
7733 Self::Normal => f.write_str("normal"),
7734 Self::Sub => f.write_str("sub"),
7735 Self::Super => f.write_str("super"),
7736 }
7737 }
7738}
7739
7740#[derive(Debug, Clone, PartialEq)]
7742#[non_exhaustive]
7743pub enum FontVariationSettings {
7744 Normal,
7746 Raw(Raw),
7748}
7749
7750impl fmt::Display for FontVariationSettings {
7751 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7752 match self {
7753 Self::Normal => f.write_str("normal"),
7754 Self::Raw(v) => v.fmt(f),
7755 }
7756 }
7757}
7758
7759impl From<Raw> for FontVariationSettings {
7760 fn from(v: Raw) -> Self {
7761 Self::Raw(v)
7762 }
7763}
7764
7765#[derive(Debug, Clone, PartialEq)]
7767#[non_exhaustive]
7768pub enum FontWeight {
7769 Bold,
7771 Bolder,
7773 Lighter,
7775 Normal,
7777 Number(f64),
7779}
7780
7781impl fmt::Display for FontWeight {
7782 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7783 match self {
7784 Self::Bold => f.write_str("bold"),
7785 Self::Bolder => f.write_str("bolder"),
7786 Self::Lighter => f.write_str("lighter"),
7787 Self::Normal => f.write_str("normal"),
7788 Self::Number(v) => v.fmt(f),
7789 }
7790 }
7791}
7792
7793impl From<f64> for FontWeight {
7794 fn from(v: f64) -> Self {
7795 Self::Number(v)
7796 }
7797}
7798
7799impl From<i32> for FontWeight {
7800 fn from(v: i32) -> Self {
7801 Self::Number(f64::from(v))
7802 }
7803}
7804
7805#[derive(Debug, Clone, PartialEq)]
7807#[non_exhaustive]
7808pub enum ForcedColorAdjust {
7809 Auto,
7811 None,
7813 PreserveParentColor,
7815}
7816
7817impl fmt::Display for ForcedColorAdjust {
7818 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7819 match self {
7820 Self::Auto => f.write_str("auto"),
7821 Self::None => f.write_str("none"),
7822 Self::PreserveParentColor => f.write_str("preserve-parent-color"),
7823 }
7824 }
7825}
7826
7827#[derive(Debug, Clone, PartialEq)]
7829#[non_exhaustive]
7830pub enum FrameSizing {
7831 Auto,
7833 ContentBlockSize,
7835 ContentHeight,
7837 ContentInlineSize,
7839 ContentWidth,
7841}
7842
7843impl fmt::Display for FrameSizing {
7844 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7845 match self {
7846 Self::Auto => f.write_str("auto"),
7847 Self::ContentBlockSize => f.write_str("content-block-size"),
7848 Self::ContentHeight => f.write_str("content-height"),
7849 Self::ContentInlineSize => f.write_str("content-inline-size"),
7850 Self::ContentWidth => f.write_str("content-width"),
7851 }
7852 }
7853}
7854
7855#[derive(Debug, Clone, PartialEq)]
7857#[non_exhaustive]
7858pub enum Gap {
7859 Normal,
7861 Length(Length),
7863 Percentage(Percentage),
7865 Raw(Raw),
7867}
7868
7869impl fmt::Display for Gap {
7870 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7871 match self {
7872 Self::Normal => f.write_str("normal"),
7873 Self::Length(v) => v.fmt(f),
7874 Self::Percentage(v) => v.fmt(f),
7875 Self::Raw(v) => v.fmt(f),
7876 }
7877 }
7878}
7879
7880impl From<Length> for Gap {
7881 fn from(v: Length) -> Self {
7882 Self::Length(v)
7883 }
7884}
7885
7886impl From<Percentage> for Gap {
7887 fn from(v: Percentage) -> Self {
7888 Self::Percentage(v)
7889 }
7890}
7891
7892impl From<Raw> for Gap {
7893 fn from(v: Raw) -> Self {
7894 Self::Raw(v)
7895 }
7896}
7897
7898#[derive(Debug, Clone, PartialEq)]
7900#[non_exhaustive]
7901pub enum Grid {
7902 None,
7904 Quoted(Quoted),
7906 Raw(Raw),
7908}
7909
7910impl fmt::Display for Grid {
7911 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7912 match self {
7913 Self::None => f.write_str("none"),
7914 Self::Quoted(v) => v.fmt(f),
7915 Self::Raw(v) => v.fmt(f),
7916 }
7917 }
7918}
7919
7920impl From<Quoted> for Grid {
7921 fn from(v: Quoted) -> Self {
7922 Self::Quoted(v)
7923 }
7924}
7925
7926impl From<Raw> for Grid {
7927 fn from(v: Raw) -> Self {
7928 Self::Raw(v)
7929 }
7930}
7931
7932#[derive(Debug, Clone, PartialEq)]
7934#[non_exhaustive]
7935pub enum GridArea {
7936 Auto,
7938 Raw(Raw),
7940}
7941
7942impl fmt::Display for GridArea {
7943 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7944 match self {
7945 Self::Auto => f.write_str("auto"),
7946 Self::Raw(v) => v.fmt(f),
7947 }
7948 }
7949}
7950
7951impl From<Raw> for GridArea {
7952 fn from(v: Raw) -> Self {
7953 Self::Raw(v)
7954 }
7955}
7956
7957#[derive(Debug, Clone, PartialEq)]
7959#[non_exhaustive]
7960pub enum GridAutoColumns {
7961 Auto,
7963 MaxContent,
7965 MinContent,
7967 Length(Length),
7969 Percentage(Percentage),
7971 Raw(Raw),
7973}
7974
7975impl fmt::Display for GridAutoColumns {
7976 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7977 match self {
7978 Self::Auto => f.write_str("auto"),
7979 Self::MaxContent => f.write_str("max-content"),
7980 Self::MinContent => f.write_str("min-content"),
7981 Self::Length(v) => v.fmt(f),
7982 Self::Percentage(v) => v.fmt(f),
7983 Self::Raw(v) => v.fmt(f),
7984 }
7985 }
7986}
7987
7988impl From<Length> for GridAutoColumns {
7989 fn from(v: Length) -> Self {
7990 Self::Length(v)
7991 }
7992}
7993
7994impl From<Percentage> for GridAutoColumns {
7995 fn from(v: Percentage) -> Self {
7996 Self::Percentage(v)
7997 }
7998}
7999
8000impl From<Raw> for GridAutoColumns {
8001 fn from(v: Raw) -> Self {
8002 Self::Raw(v)
8003 }
8004}
8005
8006#[derive(Debug, Clone, PartialEq)]
8008#[non_exhaustive]
8009pub enum GridAutoFlow {
8010 Column,
8012 Dense,
8014 Row,
8016 Raw(Raw),
8018}
8019
8020impl fmt::Display for GridAutoFlow {
8021 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8022 match self {
8023 Self::Column => f.write_str("column"),
8024 Self::Dense => f.write_str("dense"),
8025 Self::Row => f.write_str("row"),
8026 Self::Raw(v) => v.fmt(f),
8027 }
8028 }
8029}
8030
8031impl From<Raw> for GridAutoFlow {
8032 fn from(v: Raw) -> Self {
8033 Self::Raw(v)
8034 }
8035}
8036
8037#[derive(Debug, Clone, PartialEq)]
8039#[non_exhaustive]
8040pub enum GridAutoRows {
8041 Auto,
8043 MaxContent,
8045 MinContent,
8047 Length(Length),
8049 Percentage(Percentage),
8051 Raw(Raw),
8053}
8054
8055impl fmt::Display for GridAutoRows {
8056 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8057 match self {
8058 Self::Auto => f.write_str("auto"),
8059 Self::MaxContent => f.write_str("max-content"),
8060 Self::MinContent => f.write_str("min-content"),
8061 Self::Length(v) => v.fmt(f),
8062 Self::Percentage(v) => v.fmt(f),
8063 Self::Raw(v) => v.fmt(f),
8064 }
8065 }
8066}
8067
8068impl From<Length> for GridAutoRows {
8069 fn from(v: Length) -> Self {
8070 Self::Length(v)
8071 }
8072}
8073
8074impl From<Percentage> for GridAutoRows {
8075 fn from(v: Percentage) -> Self {
8076 Self::Percentage(v)
8077 }
8078}
8079
8080impl From<Raw> for GridAutoRows {
8081 fn from(v: Raw) -> Self {
8082 Self::Raw(v)
8083 }
8084}
8085
8086#[derive(Debug, Clone, PartialEq)]
8088#[non_exhaustive]
8089pub enum GridColumn {
8090 Auto,
8092 Raw(Raw),
8094}
8095
8096impl fmt::Display for GridColumn {
8097 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8098 match self {
8099 Self::Auto => f.write_str("auto"),
8100 Self::Raw(v) => v.fmt(f),
8101 }
8102 }
8103}
8104
8105impl From<Raw> for GridColumn {
8106 fn from(v: Raw) -> Self {
8107 Self::Raw(v)
8108 }
8109}
8110
8111#[derive(Debug, Clone, PartialEq)]
8113#[non_exhaustive]
8114pub enum GridColumnEnd {
8115 Auto,
8117 Raw(Raw),
8119}
8120
8121impl fmt::Display for GridColumnEnd {
8122 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8123 match self {
8124 Self::Auto => f.write_str("auto"),
8125 Self::Raw(v) => v.fmt(f),
8126 }
8127 }
8128}
8129
8130impl From<Raw> for GridColumnEnd {
8131 fn from(v: Raw) -> Self {
8132 Self::Raw(v)
8133 }
8134}
8135
8136#[derive(Debug, Clone, PartialEq)]
8138#[non_exhaustive]
8139pub enum GridColumnStart {
8140 Auto,
8142 Raw(Raw),
8144}
8145
8146impl fmt::Display for GridColumnStart {
8147 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8148 match self {
8149 Self::Auto => f.write_str("auto"),
8150 Self::Raw(v) => v.fmt(f),
8151 }
8152 }
8153}
8154
8155impl From<Raw> for GridColumnStart {
8156 fn from(v: Raw) -> Self {
8157 Self::Raw(v)
8158 }
8159}
8160
8161#[derive(Debug, Clone, PartialEq)]
8163#[non_exhaustive]
8164pub enum GridRow {
8165 Auto,
8167 Raw(Raw),
8169}
8170
8171impl fmt::Display for GridRow {
8172 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8173 match self {
8174 Self::Auto => f.write_str("auto"),
8175 Self::Raw(v) => v.fmt(f),
8176 }
8177 }
8178}
8179
8180impl From<Raw> for GridRow {
8181 fn from(v: Raw) -> Self {
8182 Self::Raw(v)
8183 }
8184}
8185
8186#[derive(Debug, Clone, PartialEq)]
8188#[non_exhaustive]
8189pub enum GridRowEnd {
8190 Auto,
8192 Raw(Raw),
8194}
8195
8196impl fmt::Display for GridRowEnd {
8197 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8198 match self {
8199 Self::Auto => f.write_str("auto"),
8200 Self::Raw(v) => v.fmt(f),
8201 }
8202 }
8203}
8204
8205impl From<Raw> for GridRowEnd {
8206 fn from(v: Raw) -> Self {
8207 Self::Raw(v)
8208 }
8209}
8210
8211#[derive(Debug, Clone, PartialEq)]
8213#[non_exhaustive]
8214pub enum GridRowStart {
8215 Auto,
8217 Raw(Raw),
8219}
8220
8221impl fmt::Display for GridRowStart {
8222 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8223 match self {
8224 Self::Auto => f.write_str("auto"),
8225 Self::Raw(v) => v.fmt(f),
8226 }
8227 }
8228}
8229
8230impl From<Raw> for GridRowStart {
8231 fn from(v: Raw) -> Self {
8232 Self::Raw(v)
8233 }
8234}
8235
8236#[derive(Debug, Clone, PartialEq)]
8238#[non_exhaustive]
8239pub enum GridTemplate {
8240 None,
8242 Quoted(Quoted),
8244 Raw(Raw),
8246}
8247
8248impl fmt::Display for GridTemplate {
8249 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8250 match self {
8251 Self::None => f.write_str("none"),
8252 Self::Quoted(v) => v.fmt(f),
8253 Self::Raw(v) => v.fmt(f),
8254 }
8255 }
8256}
8257
8258impl From<Quoted> for GridTemplate {
8259 fn from(v: Quoted) -> Self {
8260 Self::Quoted(v)
8261 }
8262}
8263
8264impl From<Raw> for GridTemplate {
8265 fn from(v: Raw) -> Self {
8266 Self::Raw(v)
8267 }
8268}
8269
8270#[derive(Debug, Clone, PartialEq)]
8272#[non_exhaustive]
8273pub enum GridTemplateAreas {
8274 None,
8276 Quoted(Quoted),
8278 Raw(Raw),
8280}
8281
8282impl fmt::Display for GridTemplateAreas {
8283 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8284 match self {
8285 Self::None => f.write_str("none"),
8286 Self::Quoted(v) => v.fmt(f),
8287 Self::Raw(v) => v.fmt(f),
8288 }
8289 }
8290}
8291
8292impl From<Quoted> for GridTemplateAreas {
8293 fn from(v: Quoted) -> Self {
8294 Self::Quoted(v)
8295 }
8296}
8297
8298impl From<Raw> for GridTemplateAreas {
8299 fn from(v: Raw) -> Self {
8300 Self::Raw(v)
8301 }
8302}
8303
8304#[derive(Debug, Clone, PartialEq)]
8306#[non_exhaustive]
8307pub enum GridTemplateColumns {
8308 Auto,
8310 MaxContent,
8312 MinContent,
8314 None,
8316 Subgrid,
8318 Length(Length),
8320 Percentage(Percentage),
8322 Raw(Raw),
8324}
8325
8326impl fmt::Display for GridTemplateColumns {
8327 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8328 match self {
8329 Self::Auto => f.write_str("auto"),
8330 Self::MaxContent => f.write_str("max-content"),
8331 Self::MinContent => f.write_str("min-content"),
8332 Self::None => f.write_str("none"),
8333 Self::Subgrid => f.write_str("subgrid"),
8334 Self::Length(v) => v.fmt(f),
8335 Self::Percentage(v) => v.fmt(f),
8336 Self::Raw(v) => v.fmt(f),
8337 }
8338 }
8339}
8340
8341impl From<Length> for GridTemplateColumns {
8342 fn from(v: Length) -> Self {
8343 Self::Length(v)
8344 }
8345}
8346
8347impl From<Percentage> for GridTemplateColumns {
8348 fn from(v: Percentage) -> Self {
8349 Self::Percentage(v)
8350 }
8351}
8352
8353impl From<Raw> for GridTemplateColumns {
8354 fn from(v: Raw) -> Self {
8355 Self::Raw(v)
8356 }
8357}
8358
8359#[derive(Debug, Clone, PartialEq)]
8361#[non_exhaustive]
8362pub enum GridTemplateRows {
8363 Auto,
8365 MaxContent,
8367 MinContent,
8369 None,
8371 Subgrid,
8373 Length(Length),
8375 Percentage(Percentage),
8377 Raw(Raw),
8379}
8380
8381impl fmt::Display for GridTemplateRows {
8382 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8383 match self {
8384 Self::Auto => f.write_str("auto"),
8385 Self::MaxContent => f.write_str("max-content"),
8386 Self::MinContent => f.write_str("min-content"),
8387 Self::None => f.write_str("none"),
8388 Self::Subgrid => f.write_str("subgrid"),
8389 Self::Length(v) => v.fmt(f),
8390 Self::Percentage(v) => v.fmt(f),
8391 Self::Raw(v) => v.fmt(f),
8392 }
8393 }
8394}
8395
8396impl From<Length> for GridTemplateRows {
8397 fn from(v: Length) -> Self {
8398 Self::Length(v)
8399 }
8400}
8401
8402impl From<Percentage> for GridTemplateRows {
8403 fn from(v: Percentage) -> Self {
8404 Self::Percentage(v)
8405 }
8406}
8407
8408impl From<Raw> for GridTemplateRows {
8409 fn from(v: Raw) -> Self {
8410 Self::Raw(v)
8411 }
8412}
8413
8414#[derive(Debug, Clone, PartialEq)]
8416#[non_exhaustive]
8417pub enum HangingPunctuation {
8418 AllowEnd,
8420 First,
8422 ForceEnd,
8424 Last,
8426 None,
8428 Raw(Raw),
8430}
8431
8432impl fmt::Display for HangingPunctuation {
8433 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8434 match self {
8435 Self::AllowEnd => f.write_str("allow-end"),
8436 Self::First => f.write_str("first"),
8437 Self::ForceEnd => f.write_str("force-end"),
8438 Self::Last => f.write_str("last"),
8439 Self::None => f.write_str("none"),
8440 Self::Raw(v) => v.fmt(f),
8441 }
8442 }
8443}
8444
8445impl From<Raw> for HangingPunctuation {
8446 fn from(v: Raw) -> Self {
8447 Self::Raw(v)
8448 }
8449}
8450
8451#[derive(Debug, Clone, PartialEq)]
8453#[non_exhaustive]
8454pub enum Height {
8455 Auto,
8457 FitContent,
8459 MaxContent,
8461 MinContent,
8463 Length(Length),
8465 Percentage(Percentage),
8467 Raw(Raw),
8469}
8470
8471impl fmt::Display for Height {
8472 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8473 match self {
8474 Self::Auto => f.write_str("auto"),
8475 Self::FitContent => f.write_str("fit-content"),
8476 Self::MaxContent => f.write_str("max-content"),
8477 Self::MinContent => f.write_str("min-content"),
8478 Self::Length(v) => v.fmt(f),
8479 Self::Percentage(v) => v.fmt(f),
8480 Self::Raw(v) => v.fmt(f),
8481 }
8482 }
8483}
8484
8485impl From<Length> for Height {
8486 fn from(v: Length) -> Self {
8487 Self::Length(v)
8488 }
8489}
8490
8491impl From<Percentage> for Height {
8492 fn from(v: Percentage) -> Self {
8493 Self::Percentage(v)
8494 }
8495}
8496
8497impl From<Raw> for Height {
8498 fn from(v: Raw) -> Self {
8499 Self::Raw(v)
8500 }
8501}
8502
8503#[derive(Debug, Clone, PartialEq)]
8505#[non_exhaustive]
8506pub enum HyphenateCharacter {
8507 Auto,
8509 Quoted(Quoted),
8511}
8512
8513impl fmt::Display for HyphenateCharacter {
8514 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8515 match self {
8516 Self::Auto => f.write_str("auto"),
8517 Self::Quoted(v) => v.fmt(f),
8518 }
8519 }
8520}
8521
8522impl From<Quoted> for HyphenateCharacter {
8523 fn from(v: Quoted) -> Self {
8524 Self::Quoted(v)
8525 }
8526}
8527
8528#[derive(Debug, Clone, PartialEq)]
8530#[non_exhaustive]
8531pub enum HyphenateLimitChars {
8532 Auto,
8534 Integer(i32),
8536 Raw(Raw),
8538}
8539
8540impl fmt::Display for HyphenateLimitChars {
8541 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8542 match self {
8543 Self::Auto => f.write_str("auto"),
8544 Self::Integer(v) => v.fmt(f),
8545 Self::Raw(v) => v.fmt(f),
8546 }
8547 }
8548}
8549
8550impl From<i32> for HyphenateLimitChars {
8551 fn from(v: i32) -> Self {
8552 Self::Integer(v)
8553 }
8554}
8555
8556impl From<Raw> for HyphenateLimitChars {
8557 fn from(v: Raw) -> Self {
8558 Self::Raw(v)
8559 }
8560}
8561
8562#[derive(Debug, Clone, PartialEq)]
8564#[non_exhaustive]
8565pub enum Hyphens {
8566 Auto,
8568 Manual,
8570 None,
8572}
8573
8574impl fmt::Display for Hyphens {
8575 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8576 match self {
8577 Self::Auto => f.write_str("auto"),
8578 Self::Manual => f.write_str("manual"),
8579 Self::None => f.write_str("none"),
8580 }
8581 }
8582}
8583
8584#[derive(Debug, Clone, PartialEq)]
8586#[non_exhaustive]
8587pub enum ImageOrientation {
8588 Flip,
8590 FromImage,
8592 Angle(Angle),
8594 Raw(Raw),
8596}
8597
8598impl fmt::Display for ImageOrientation {
8599 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8600 match self {
8601 Self::Flip => f.write_str("flip"),
8602 Self::FromImage => f.write_str("from-image"),
8603 Self::Angle(v) => v.fmt(f),
8604 Self::Raw(v) => v.fmt(f),
8605 }
8606 }
8607}
8608
8609impl From<Angle> for ImageOrientation {
8610 fn from(v: Angle) -> Self {
8611 Self::Angle(v)
8612 }
8613}
8614
8615impl From<Raw> for ImageOrientation {
8616 fn from(v: Raw) -> Self {
8617 Self::Raw(v)
8618 }
8619}
8620
8621#[derive(Debug, Clone, PartialEq)]
8623#[non_exhaustive]
8624pub enum ImageRendering {
8625 Auto,
8627 CrispEdges,
8629 Pixelated,
8631 Smooth,
8633}
8634
8635impl fmt::Display for ImageRendering {
8636 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8637 match self {
8638 Self::Auto => f.write_str("auto"),
8639 Self::CrispEdges => f.write_str("crisp-edges"),
8640 Self::Pixelated => f.write_str("pixelated"),
8641 Self::Smooth => f.write_str("smooth"),
8642 }
8643 }
8644}
8645
8646#[derive(Debug, Clone, PartialEq)]
8648#[non_exhaustive]
8649pub enum InitialLetter {
8650 Normal,
8652 Number(f64),
8654 Raw(Raw),
8656}
8657
8658impl fmt::Display for InitialLetter {
8659 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8660 match self {
8661 Self::Normal => f.write_str("normal"),
8662 Self::Number(v) => v.fmt(f),
8663 Self::Raw(v) => v.fmt(f),
8664 }
8665 }
8666}
8667
8668impl From<f64> for InitialLetter {
8669 fn from(v: f64) -> Self {
8670 Self::Number(v)
8671 }
8672}
8673
8674impl From<i32> for InitialLetter {
8675 fn from(v: i32) -> Self {
8676 Self::Number(f64::from(v))
8677 }
8678}
8679
8680impl From<Raw> for InitialLetter {
8681 fn from(v: Raw) -> Self {
8682 Self::Raw(v)
8683 }
8684}
8685
8686#[derive(Debug, Clone, PartialEq)]
8688#[non_exhaustive]
8689pub enum InlineSize {
8690 Auto,
8692 FitContent,
8694 MaxContent,
8696 MinContent,
8698 Length(Length),
8700 Percentage(Percentage),
8702 Raw(Raw),
8704}
8705
8706impl fmt::Display for InlineSize {
8707 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8708 match self {
8709 Self::Auto => f.write_str("auto"),
8710 Self::FitContent => f.write_str("fit-content"),
8711 Self::MaxContent => f.write_str("max-content"),
8712 Self::MinContent => f.write_str("min-content"),
8713 Self::Length(v) => v.fmt(f),
8714 Self::Percentage(v) => v.fmt(f),
8715 Self::Raw(v) => v.fmt(f),
8716 }
8717 }
8718}
8719
8720impl From<Length> for InlineSize {
8721 fn from(v: Length) -> Self {
8722 Self::Length(v)
8723 }
8724}
8725
8726impl From<Percentage> for InlineSize {
8727 fn from(v: Percentage) -> Self {
8728 Self::Percentage(v)
8729 }
8730}
8731
8732impl From<Raw> for InlineSize {
8733 fn from(v: Raw) -> Self {
8734 Self::Raw(v)
8735 }
8736}
8737
8738#[derive(Debug, Clone, PartialEq)]
8740#[non_exhaustive]
8741pub enum Inset {
8742 Auto,
8744 Length(Length),
8746 Percentage(Percentage),
8748 Raw(Raw),
8750}
8751
8752impl fmt::Display for Inset {
8753 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8754 match self {
8755 Self::Auto => f.write_str("auto"),
8756 Self::Length(v) => v.fmt(f),
8757 Self::Percentage(v) => v.fmt(f),
8758 Self::Raw(v) => v.fmt(f),
8759 }
8760 }
8761}
8762
8763impl From<Length> for Inset {
8764 fn from(v: Length) -> Self {
8765 Self::Length(v)
8766 }
8767}
8768
8769impl From<Percentage> for Inset {
8770 fn from(v: Percentage) -> Self {
8771 Self::Percentage(v)
8772 }
8773}
8774
8775impl From<Raw> for Inset {
8776 fn from(v: Raw) -> Self {
8777 Self::Raw(v)
8778 }
8779}
8780
8781#[derive(Debug, Clone, PartialEq)]
8783#[non_exhaustive]
8784pub enum InsetBlock {
8785 Auto,
8787 Length(Length),
8789 Percentage(Percentage),
8791 Raw(Raw),
8793}
8794
8795impl fmt::Display for InsetBlock {
8796 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8797 match self {
8798 Self::Auto => f.write_str("auto"),
8799 Self::Length(v) => v.fmt(f),
8800 Self::Percentage(v) => v.fmt(f),
8801 Self::Raw(v) => v.fmt(f),
8802 }
8803 }
8804}
8805
8806impl From<Length> for InsetBlock {
8807 fn from(v: Length) -> Self {
8808 Self::Length(v)
8809 }
8810}
8811
8812impl From<Percentage> for InsetBlock {
8813 fn from(v: Percentage) -> Self {
8814 Self::Percentage(v)
8815 }
8816}
8817
8818impl From<Raw> for InsetBlock {
8819 fn from(v: Raw) -> Self {
8820 Self::Raw(v)
8821 }
8822}
8823
8824#[derive(Debug, Clone, PartialEq)]
8826#[non_exhaustive]
8827pub enum InsetBlockEnd {
8828 Auto,
8830 Length(Length),
8832 Percentage(Percentage),
8834 Raw(Raw),
8836}
8837
8838impl fmt::Display for InsetBlockEnd {
8839 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8840 match self {
8841 Self::Auto => f.write_str("auto"),
8842 Self::Length(v) => v.fmt(f),
8843 Self::Percentage(v) => v.fmt(f),
8844 Self::Raw(v) => v.fmt(f),
8845 }
8846 }
8847}
8848
8849impl From<Length> for InsetBlockEnd {
8850 fn from(v: Length) -> Self {
8851 Self::Length(v)
8852 }
8853}
8854
8855impl From<Percentage> for InsetBlockEnd {
8856 fn from(v: Percentage) -> Self {
8857 Self::Percentage(v)
8858 }
8859}
8860
8861impl From<Raw> for InsetBlockEnd {
8862 fn from(v: Raw) -> Self {
8863 Self::Raw(v)
8864 }
8865}
8866
8867#[derive(Debug, Clone, PartialEq)]
8869#[non_exhaustive]
8870pub enum InsetBlockStart {
8871 Auto,
8873 Length(Length),
8875 Percentage(Percentage),
8877 Raw(Raw),
8879}
8880
8881impl fmt::Display for InsetBlockStart {
8882 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8883 match self {
8884 Self::Auto => f.write_str("auto"),
8885 Self::Length(v) => v.fmt(f),
8886 Self::Percentage(v) => v.fmt(f),
8887 Self::Raw(v) => v.fmt(f),
8888 }
8889 }
8890}
8891
8892impl From<Length> for InsetBlockStart {
8893 fn from(v: Length) -> Self {
8894 Self::Length(v)
8895 }
8896}
8897
8898impl From<Percentage> for InsetBlockStart {
8899 fn from(v: Percentage) -> Self {
8900 Self::Percentage(v)
8901 }
8902}
8903
8904impl From<Raw> for InsetBlockStart {
8905 fn from(v: Raw) -> Self {
8906 Self::Raw(v)
8907 }
8908}
8909
8910#[derive(Debug, Clone, PartialEq)]
8912#[non_exhaustive]
8913pub enum InsetInline {
8914 Auto,
8916 Length(Length),
8918 Percentage(Percentage),
8920 Raw(Raw),
8922}
8923
8924impl fmt::Display for InsetInline {
8925 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8926 match self {
8927 Self::Auto => f.write_str("auto"),
8928 Self::Length(v) => v.fmt(f),
8929 Self::Percentage(v) => v.fmt(f),
8930 Self::Raw(v) => v.fmt(f),
8931 }
8932 }
8933}
8934
8935impl From<Length> for InsetInline {
8936 fn from(v: Length) -> Self {
8937 Self::Length(v)
8938 }
8939}
8940
8941impl From<Percentage> for InsetInline {
8942 fn from(v: Percentage) -> Self {
8943 Self::Percentage(v)
8944 }
8945}
8946
8947impl From<Raw> for InsetInline {
8948 fn from(v: Raw) -> Self {
8949 Self::Raw(v)
8950 }
8951}
8952
8953#[derive(Debug, Clone, PartialEq)]
8955#[non_exhaustive]
8956pub enum InsetInlineEnd {
8957 Auto,
8959 Length(Length),
8961 Percentage(Percentage),
8963 Raw(Raw),
8965}
8966
8967impl fmt::Display for InsetInlineEnd {
8968 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8969 match self {
8970 Self::Auto => f.write_str("auto"),
8971 Self::Length(v) => v.fmt(f),
8972 Self::Percentage(v) => v.fmt(f),
8973 Self::Raw(v) => v.fmt(f),
8974 }
8975 }
8976}
8977
8978impl From<Length> for InsetInlineEnd {
8979 fn from(v: Length) -> Self {
8980 Self::Length(v)
8981 }
8982}
8983
8984impl From<Percentage> for InsetInlineEnd {
8985 fn from(v: Percentage) -> Self {
8986 Self::Percentage(v)
8987 }
8988}
8989
8990impl From<Raw> for InsetInlineEnd {
8991 fn from(v: Raw) -> Self {
8992 Self::Raw(v)
8993 }
8994}
8995
8996#[derive(Debug, Clone, PartialEq)]
8998#[non_exhaustive]
8999pub enum InsetInlineStart {
9000 Auto,
9002 Length(Length),
9004 Percentage(Percentage),
9006 Raw(Raw),
9008}
9009
9010impl fmt::Display for InsetInlineStart {
9011 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9012 match self {
9013 Self::Auto => f.write_str("auto"),
9014 Self::Length(v) => v.fmt(f),
9015 Self::Percentage(v) => v.fmt(f),
9016 Self::Raw(v) => v.fmt(f),
9017 }
9018 }
9019}
9020
9021impl From<Length> for InsetInlineStart {
9022 fn from(v: Length) -> Self {
9023 Self::Length(v)
9024 }
9025}
9026
9027impl From<Percentage> for InsetInlineStart {
9028 fn from(v: Percentage) -> Self {
9029 Self::Percentage(v)
9030 }
9031}
9032
9033impl From<Raw> for InsetInlineStart {
9034 fn from(v: Raw) -> Self {
9035 Self::Raw(v)
9036 }
9037}
9038
9039#[derive(Debug, Clone, PartialEq)]
9041#[non_exhaustive]
9042pub enum Interactivity {
9043 Auto,
9045 Inert,
9047}
9048
9049impl fmt::Display for Interactivity {
9050 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9051 match self {
9052 Self::Auto => f.write_str("auto"),
9053 Self::Inert => f.write_str("inert"),
9054 }
9055 }
9056}
9057
9058#[derive(Debug, Clone, PartialEq)]
9060#[non_exhaustive]
9061pub enum InterestDelay {
9062 Normal,
9064 Time(Time),
9066 Raw(Raw),
9068}
9069
9070impl fmt::Display for InterestDelay {
9071 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9072 match self {
9073 Self::Normal => f.write_str("normal"),
9074 Self::Time(v) => v.fmt(f),
9075 Self::Raw(v) => v.fmt(f),
9076 }
9077 }
9078}
9079
9080impl From<Time> for InterestDelay {
9081 fn from(v: Time) -> Self {
9082 Self::Time(v)
9083 }
9084}
9085
9086impl From<Raw> for InterestDelay {
9087 fn from(v: Raw) -> Self {
9088 Self::Raw(v)
9089 }
9090}
9091
9092#[derive(Debug, Clone, PartialEq)]
9094#[non_exhaustive]
9095pub enum InterestDelayEnd {
9096 Normal,
9098 Time(Time),
9100}
9101
9102impl fmt::Display for InterestDelayEnd {
9103 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9104 match self {
9105 Self::Normal => f.write_str("normal"),
9106 Self::Time(v) => v.fmt(f),
9107 }
9108 }
9109}
9110
9111impl From<Time> for InterestDelayEnd {
9112 fn from(v: Time) -> Self {
9113 Self::Time(v)
9114 }
9115}
9116
9117#[derive(Debug, Clone, PartialEq)]
9119#[non_exhaustive]
9120pub enum InterestDelayStart {
9121 Normal,
9123 Time(Time),
9125}
9126
9127impl fmt::Display for InterestDelayStart {
9128 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9129 match self {
9130 Self::Normal => f.write_str("normal"),
9131 Self::Time(v) => v.fmt(f),
9132 }
9133 }
9134}
9135
9136impl From<Time> for InterestDelayStart {
9137 fn from(v: Time) -> Self {
9138 Self::Time(v)
9139 }
9140}
9141
9142#[derive(Debug, Clone, PartialEq)]
9144#[non_exhaustive]
9145pub enum Isolation {
9146 Auto,
9148 Isolate,
9150}
9151
9152impl fmt::Display for Isolation {
9153 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9154 match self {
9155 Self::Auto => f.write_str("auto"),
9156 Self::Isolate => f.write_str("isolate"),
9157 }
9158 }
9159}
9160
9161#[derive(Debug, Clone, PartialEq)]
9163#[non_exhaustive]
9164pub enum JustifyContent {
9165 Center,
9167 End,
9169 FlexEnd,
9171 FlexStart,
9173 Left,
9175 Normal,
9177 Right,
9179 SpaceAround,
9181 SpaceBetween,
9183 SpaceEvenly,
9185 Start,
9187 Stretch,
9189 Raw(Raw),
9191}
9192
9193impl fmt::Display for JustifyContent {
9194 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9195 match self {
9196 Self::Center => f.write_str("center"),
9197 Self::End => f.write_str("end"),
9198 Self::FlexEnd => f.write_str("flex-end"),
9199 Self::FlexStart => f.write_str("flex-start"),
9200 Self::Left => f.write_str("left"),
9201 Self::Normal => f.write_str("normal"),
9202 Self::Right => f.write_str("right"),
9203 Self::SpaceAround => f.write_str("space-around"),
9204 Self::SpaceBetween => f.write_str("space-between"),
9205 Self::SpaceEvenly => f.write_str("space-evenly"),
9206 Self::Start => f.write_str("start"),
9207 Self::Stretch => f.write_str("stretch"),
9208 Self::Raw(v) => v.fmt(f),
9209 }
9210 }
9211}
9212
9213impl From<Raw> for JustifyContent {
9214 fn from(v: Raw) -> Self {
9215 Self::Raw(v)
9216 }
9217}
9218
9219#[derive(Debug, Clone, PartialEq)]
9221#[non_exhaustive]
9222pub enum JustifyItems {
9223 AnchorCenter,
9225 Baseline,
9227 Center,
9229 End,
9231 FlexEnd,
9233 FlexStart,
9235 Left,
9237 Legacy,
9239 Normal,
9241 Right,
9243 SelfEnd,
9245 SelfStart,
9247 Start,
9249 Stretch,
9251 Raw(Raw),
9253}
9254
9255impl fmt::Display for JustifyItems {
9256 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9257 match self {
9258 Self::AnchorCenter => f.write_str("anchor-center"),
9259 Self::Baseline => f.write_str("baseline"),
9260 Self::Center => f.write_str("center"),
9261 Self::End => f.write_str("end"),
9262 Self::FlexEnd => f.write_str("flex-end"),
9263 Self::FlexStart => f.write_str("flex-start"),
9264 Self::Left => f.write_str("left"),
9265 Self::Legacy => f.write_str("legacy"),
9266 Self::Normal => f.write_str("normal"),
9267 Self::Right => f.write_str("right"),
9268 Self::SelfEnd => f.write_str("self-end"),
9269 Self::SelfStart => f.write_str("self-start"),
9270 Self::Start => f.write_str("start"),
9271 Self::Stretch => f.write_str("stretch"),
9272 Self::Raw(v) => v.fmt(f),
9273 }
9274 }
9275}
9276
9277impl From<Raw> for JustifyItems {
9278 fn from(v: Raw) -> Self {
9279 Self::Raw(v)
9280 }
9281}
9282
9283#[derive(Debug, Clone, PartialEq)]
9285#[non_exhaustive]
9286pub enum JustifySelf {
9287 AnchorCenter,
9289 Auto,
9291 Baseline,
9293 Center,
9295 End,
9297 FlexEnd,
9299 FlexStart,
9301 Left,
9303 Normal,
9305 Right,
9307 SelfEnd,
9309 SelfStart,
9311 Start,
9313 Stretch,
9315 Raw(Raw),
9317}
9318
9319impl fmt::Display for JustifySelf {
9320 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9321 match self {
9322 Self::AnchorCenter => f.write_str("anchor-center"),
9323 Self::Auto => f.write_str("auto"),
9324 Self::Baseline => f.write_str("baseline"),
9325 Self::Center => f.write_str("center"),
9326 Self::End => f.write_str("end"),
9327 Self::FlexEnd => f.write_str("flex-end"),
9328 Self::FlexStart => f.write_str("flex-start"),
9329 Self::Left => f.write_str("left"),
9330 Self::Normal => f.write_str("normal"),
9331 Self::Right => f.write_str("right"),
9332 Self::SelfEnd => f.write_str("self-end"),
9333 Self::SelfStart => f.write_str("self-start"),
9334 Self::Start => f.write_str("start"),
9335 Self::Stretch => f.write_str("stretch"),
9336 Self::Raw(v) => v.fmt(f),
9337 }
9338 }
9339}
9340
9341impl From<Raw> for JustifySelf {
9342 fn from(v: Raw) -> Self {
9343 Self::Raw(v)
9344 }
9345}
9346
9347#[derive(Debug, Clone, PartialEq)]
9349#[non_exhaustive]
9350pub enum Left {
9351 Auto,
9353 Length(Length),
9355 Percentage(Percentage),
9357 Raw(Raw),
9359}
9360
9361impl fmt::Display for Left {
9362 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9363 match self {
9364 Self::Auto => f.write_str("auto"),
9365 Self::Length(v) => v.fmt(f),
9366 Self::Percentage(v) => v.fmt(f),
9367 Self::Raw(v) => v.fmt(f),
9368 }
9369 }
9370}
9371
9372impl From<Length> for Left {
9373 fn from(v: Length) -> Self {
9374 Self::Length(v)
9375 }
9376}
9377
9378impl From<Percentage> for Left {
9379 fn from(v: Percentage) -> Self {
9380 Self::Percentage(v)
9381 }
9382}
9383
9384impl From<Raw> for Left {
9385 fn from(v: Raw) -> Self {
9386 Self::Raw(v)
9387 }
9388}
9389
9390#[derive(Debug, Clone, PartialEq)]
9392#[non_exhaustive]
9393pub enum LetterSpacing {
9394 Normal,
9396 Length(Length),
9398}
9399
9400impl fmt::Display for LetterSpacing {
9401 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9402 match self {
9403 Self::Normal => f.write_str("normal"),
9404 Self::Length(v) => v.fmt(f),
9405 }
9406 }
9407}
9408
9409impl From<Length> for LetterSpacing {
9410 fn from(v: Length) -> Self {
9411 Self::Length(v)
9412 }
9413}
9414
9415#[derive(Debug, Clone, PartialEq)]
9417#[non_exhaustive]
9418pub enum LineBreak {
9419 Anywhere,
9421 Auto,
9423 Loose,
9425 Normal,
9427 Strict,
9429}
9430
9431impl fmt::Display for LineBreak {
9432 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9433 match self {
9434 Self::Anywhere => f.write_str("anywhere"),
9435 Self::Auto => f.write_str("auto"),
9436 Self::Loose => f.write_str("loose"),
9437 Self::Normal => f.write_str("normal"),
9438 Self::Strict => f.write_str("strict"),
9439 }
9440 }
9441}
9442
9443#[derive(Debug, Clone, PartialEq)]
9445#[non_exhaustive]
9446pub enum LineClamp {
9447 None,
9449 Integer(i32),
9451}
9452
9453impl fmt::Display for LineClamp {
9454 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9455 match self {
9456 Self::None => f.write_str("none"),
9457 Self::Integer(v) => v.fmt(f),
9458 }
9459 }
9460}
9461
9462impl From<i32> for LineClamp {
9463 fn from(v: i32) -> Self {
9464 Self::Integer(v)
9465 }
9466}
9467
9468#[derive(Debug, Clone, PartialEq)]
9470#[non_exhaustive]
9471pub enum LineHeight {
9472 Normal,
9474 Length(Length),
9476 Percentage(Percentage),
9478 Number(f64),
9480}
9481
9482impl fmt::Display for LineHeight {
9483 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9484 match self {
9485 Self::Normal => f.write_str("normal"),
9486 Self::Length(v) => v.fmt(f),
9487 Self::Percentage(v) => v.fmt(f),
9488 Self::Number(v) => v.fmt(f),
9489 }
9490 }
9491}
9492
9493impl From<Length> for LineHeight {
9494 fn from(v: Length) -> Self {
9495 Self::Length(v)
9496 }
9497}
9498
9499impl From<Percentage> for LineHeight {
9500 fn from(v: Percentage) -> Self {
9501 Self::Percentage(v)
9502 }
9503}
9504
9505impl From<f64> for LineHeight {
9506 fn from(v: f64) -> Self {
9507 Self::Number(v)
9508 }
9509}
9510
9511impl From<i32> for LineHeight {
9512 fn from(v: i32) -> Self {
9513 Self::Number(f64::from(v))
9514 }
9515}
9516
9517#[derive(Debug, Clone, PartialEq)]
9519#[non_exhaustive]
9520pub enum ListStyle {
9521 Inside,
9523 None,
9525 Outside,
9527 Quoted(Quoted),
9529 Url(Url),
9531 Raw(Raw),
9533}
9534
9535impl fmt::Display for ListStyle {
9536 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9537 match self {
9538 Self::Inside => f.write_str("inside"),
9539 Self::None => f.write_str("none"),
9540 Self::Outside => f.write_str("outside"),
9541 Self::Quoted(v) => v.fmt(f),
9542 Self::Url(v) => v.fmt(f),
9543 Self::Raw(v) => v.fmt(f),
9544 }
9545 }
9546}
9547
9548impl From<Quoted> for ListStyle {
9549 fn from(v: Quoted) -> Self {
9550 Self::Quoted(v)
9551 }
9552}
9553
9554impl From<Url> for ListStyle {
9555 fn from(v: Url) -> Self {
9556 Self::Url(v)
9557 }
9558}
9559
9560impl From<Raw> for ListStyle {
9561 fn from(v: Raw) -> Self {
9562 Self::Raw(v)
9563 }
9564}
9565
9566#[derive(Debug, Clone, PartialEq)]
9568#[non_exhaustive]
9569pub enum ListStyleImage {
9570 None,
9572 Url(Url),
9574 Raw(Raw),
9576}
9577
9578impl fmt::Display for ListStyleImage {
9579 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9580 match self {
9581 Self::None => f.write_str("none"),
9582 Self::Url(v) => v.fmt(f),
9583 Self::Raw(v) => v.fmt(f),
9584 }
9585 }
9586}
9587
9588impl From<Url> for ListStyleImage {
9589 fn from(v: Url) -> Self {
9590 Self::Url(v)
9591 }
9592}
9593
9594impl From<Raw> for ListStyleImage {
9595 fn from(v: Raw) -> Self {
9596 Self::Raw(v)
9597 }
9598}
9599
9600#[derive(Debug, Clone, PartialEq)]
9602#[non_exhaustive]
9603pub enum ListStylePosition {
9604 Inside,
9606 Outside,
9608}
9609
9610impl fmt::Display for ListStylePosition {
9611 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9612 match self {
9613 Self::Inside => f.write_str("inside"),
9614 Self::Outside => f.write_str("outside"),
9615 }
9616 }
9617}
9618
9619#[derive(Debug, Clone, PartialEq)]
9621#[non_exhaustive]
9622pub enum ListStyleType {
9623 None,
9625 Quoted(Quoted),
9627 Raw(Raw),
9629}
9630
9631impl fmt::Display for ListStyleType {
9632 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9633 match self {
9634 Self::None => f.write_str("none"),
9635 Self::Quoted(v) => v.fmt(f),
9636 Self::Raw(v) => v.fmt(f),
9637 }
9638 }
9639}
9640
9641impl From<Quoted> for ListStyleType {
9642 fn from(v: Quoted) -> Self {
9643 Self::Quoted(v)
9644 }
9645}
9646
9647impl From<Raw> for ListStyleType {
9648 fn from(v: Raw) -> Self {
9649 Self::Raw(v)
9650 }
9651}
9652
9653#[derive(Debug, Clone, PartialEq)]
9655#[non_exhaustive]
9656pub enum Margin {
9657 Auto,
9659 Length(Length),
9661 Percentage(Percentage),
9663 Raw(Raw),
9665}
9666
9667impl fmt::Display for Margin {
9668 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9669 match self {
9670 Self::Auto => f.write_str("auto"),
9671 Self::Length(v) => v.fmt(f),
9672 Self::Percentage(v) => v.fmt(f),
9673 Self::Raw(v) => v.fmt(f),
9674 }
9675 }
9676}
9677
9678impl From<Length> for Margin {
9679 fn from(v: Length) -> Self {
9680 Self::Length(v)
9681 }
9682}
9683
9684impl From<Percentage> for Margin {
9685 fn from(v: Percentage) -> Self {
9686 Self::Percentage(v)
9687 }
9688}
9689
9690impl From<Raw> for Margin {
9691 fn from(v: Raw) -> Self {
9692 Self::Raw(v)
9693 }
9694}
9695
9696#[derive(Debug, Clone, PartialEq)]
9698#[non_exhaustive]
9699pub enum MarginBlock {
9700 Auto,
9702 Length(Length),
9704 Percentage(Percentage),
9706 Raw(Raw),
9708}
9709
9710impl fmt::Display for MarginBlock {
9711 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9712 match self {
9713 Self::Auto => f.write_str("auto"),
9714 Self::Length(v) => v.fmt(f),
9715 Self::Percentage(v) => v.fmt(f),
9716 Self::Raw(v) => v.fmt(f),
9717 }
9718 }
9719}
9720
9721impl From<Length> for MarginBlock {
9722 fn from(v: Length) -> Self {
9723 Self::Length(v)
9724 }
9725}
9726
9727impl From<Percentage> for MarginBlock {
9728 fn from(v: Percentage) -> Self {
9729 Self::Percentage(v)
9730 }
9731}
9732
9733impl From<Raw> for MarginBlock {
9734 fn from(v: Raw) -> Self {
9735 Self::Raw(v)
9736 }
9737}
9738
9739#[derive(Debug, Clone, PartialEq)]
9741#[non_exhaustive]
9742pub enum MarginBlockEnd {
9743 Auto,
9745 Length(Length),
9747 Percentage(Percentage),
9749 Raw(Raw),
9751}
9752
9753impl fmt::Display for MarginBlockEnd {
9754 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9755 match self {
9756 Self::Auto => f.write_str("auto"),
9757 Self::Length(v) => v.fmt(f),
9758 Self::Percentage(v) => v.fmt(f),
9759 Self::Raw(v) => v.fmt(f),
9760 }
9761 }
9762}
9763
9764impl From<Length> for MarginBlockEnd {
9765 fn from(v: Length) -> Self {
9766 Self::Length(v)
9767 }
9768}
9769
9770impl From<Percentage> for MarginBlockEnd {
9771 fn from(v: Percentage) -> Self {
9772 Self::Percentage(v)
9773 }
9774}
9775
9776impl From<Raw> for MarginBlockEnd {
9777 fn from(v: Raw) -> Self {
9778 Self::Raw(v)
9779 }
9780}
9781
9782#[derive(Debug, Clone, PartialEq)]
9784#[non_exhaustive]
9785pub enum MarginBlockStart {
9786 Auto,
9788 Length(Length),
9790 Percentage(Percentage),
9792 Raw(Raw),
9794}
9795
9796impl fmt::Display for MarginBlockStart {
9797 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9798 match self {
9799 Self::Auto => f.write_str("auto"),
9800 Self::Length(v) => v.fmt(f),
9801 Self::Percentage(v) => v.fmt(f),
9802 Self::Raw(v) => v.fmt(f),
9803 }
9804 }
9805}
9806
9807impl From<Length> for MarginBlockStart {
9808 fn from(v: Length) -> Self {
9809 Self::Length(v)
9810 }
9811}
9812
9813impl From<Percentage> for MarginBlockStart {
9814 fn from(v: Percentage) -> Self {
9815 Self::Percentage(v)
9816 }
9817}
9818
9819impl From<Raw> for MarginBlockStart {
9820 fn from(v: Raw) -> Self {
9821 Self::Raw(v)
9822 }
9823}
9824
9825#[derive(Debug, Clone, PartialEq)]
9827#[non_exhaustive]
9828pub enum MarginBottom {
9829 Auto,
9831 Length(Length),
9833 Percentage(Percentage),
9835 Raw(Raw),
9837}
9838
9839impl fmt::Display for MarginBottom {
9840 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9841 match self {
9842 Self::Auto => f.write_str("auto"),
9843 Self::Length(v) => v.fmt(f),
9844 Self::Percentage(v) => v.fmt(f),
9845 Self::Raw(v) => v.fmt(f),
9846 }
9847 }
9848}
9849
9850impl From<Length> for MarginBottom {
9851 fn from(v: Length) -> Self {
9852 Self::Length(v)
9853 }
9854}
9855
9856impl From<Percentage> for MarginBottom {
9857 fn from(v: Percentage) -> Self {
9858 Self::Percentage(v)
9859 }
9860}
9861
9862impl From<Raw> for MarginBottom {
9863 fn from(v: Raw) -> Self {
9864 Self::Raw(v)
9865 }
9866}
9867
9868#[derive(Debug, Clone, PartialEq)]
9870#[non_exhaustive]
9871pub enum MarginInline {
9872 Auto,
9874 Length(Length),
9876 Percentage(Percentage),
9878 Raw(Raw),
9880}
9881
9882impl fmt::Display for MarginInline {
9883 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9884 match self {
9885 Self::Auto => f.write_str("auto"),
9886 Self::Length(v) => v.fmt(f),
9887 Self::Percentage(v) => v.fmt(f),
9888 Self::Raw(v) => v.fmt(f),
9889 }
9890 }
9891}
9892
9893impl From<Length> for MarginInline {
9894 fn from(v: Length) -> Self {
9895 Self::Length(v)
9896 }
9897}
9898
9899impl From<Percentage> for MarginInline {
9900 fn from(v: Percentage) -> Self {
9901 Self::Percentage(v)
9902 }
9903}
9904
9905impl From<Raw> for MarginInline {
9906 fn from(v: Raw) -> Self {
9907 Self::Raw(v)
9908 }
9909}
9910
9911#[derive(Debug, Clone, PartialEq)]
9913#[non_exhaustive]
9914pub enum MarginInlineEnd {
9915 Auto,
9917 Length(Length),
9919 Percentage(Percentage),
9921 Raw(Raw),
9923}
9924
9925impl fmt::Display for MarginInlineEnd {
9926 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9927 match self {
9928 Self::Auto => f.write_str("auto"),
9929 Self::Length(v) => v.fmt(f),
9930 Self::Percentage(v) => v.fmt(f),
9931 Self::Raw(v) => v.fmt(f),
9932 }
9933 }
9934}
9935
9936impl From<Length> for MarginInlineEnd {
9937 fn from(v: Length) -> Self {
9938 Self::Length(v)
9939 }
9940}
9941
9942impl From<Percentage> for MarginInlineEnd {
9943 fn from(v: Percentage) -> Self {
9944 Self::Percentage(v)
9945 }
9946}
9947
9948impl From<Raw> for MarginInlineEnd {
9949 fn from(v: Raw) -> Self {
9950 Self::Raw(v)
9951 }
9952}
9953
9954#[derive(Debug, Clone, PartialEq)]
9956#[non_exhaustive]
9957pub enum MarginInlineStart {
9958 Auto,
9960 Length(Length),
9962 Percentage(Percentage),
9964 Raw(Raw),
9966}
9967
9968impl fmt::Display for MarginInlineStart {
9969 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9970 match self {
9971 Self::Auto => f.write_str("auto"),
9972 Self::Length(v) => v.fmt(f),
9973 Self::Percentage(v) => v.fmt(f),
9974 Self::Raw(v) => v.fmt(f),
9975 }
9976 }
9977}
9978
9979impl From<Length> for MarginInlineStart {
9980 fn from(v: Length) -> Self {
9981 Self::Length(v)
9982 }
9983}
9984
9985impl From<Percentage> for MarginInlineStart {
9986 fn from(v: Percentage) -> Self {
9987 Self::Percentage(v)
9988 }
9989}
9990
9991impl From<Raw> for MarginInlineStart {
9992 fn from(v: Raw) -> Self {
9993 Self::Raw(v)
9994 }
9995}
9996
9997#[derive(Debug, Clone, PartialEq)]
9999#[non_exhaustive]
10000pub enum MarginLeft {
10001 Auto,
10003 Length(Length),
10005 Percentage(Percentage),
10007 Raw(Raw),
10009}
10010
10011impl fmt::Display for MarginLeft {
10012 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10013 match self {
10014 Self::Auto => f.write_str("auto"),
10015 Self::Length(v) => v.fmt(f),
10016 Self::Percentage(v) => v.fmt(f),
10017 Self::Raw(v) => v.fmt(f),
10018 }
10019 }
10020}
10021
10022impl From<Length> for MarginLeft {
10023 fn from(v: Length) -> Self {
10024 Self::Length(v)
10025 }
10026}
10027
10028impl From<Percentage> for MarginLeft {
10029 fn from(v: Percentage) -> Self {
10030 Self::Percentage(v)
10031 }
10032}
10033
10034impl From<Raw> for MarginLeft {
10035 fn from(v: Raw) -> Self {
10036 Self::Raw(v)
10037 }
10038}
10039
10040#[derive(Debug, Clone, PartialEq)]
10042#[non_exhaustive]
10043pub enum MarginRight {
10044 Auto,
10046 Length(Length),
10048 Percentage(Percentage),
10050 Raw(Raw),
10052}
10053
10054impl fmt::Display for MarginRight {
10055 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10056 match self {
10057 Self::Auto => f.write_str("auto"),
10058 Self::Length(v) => v.fmt(f),
10059 Self::Percentage(v) => v.fmt(f),
10060 Self::Raw(v) => v.fmt(f),
10061 }
10062 }
10063}
10064
10065impl From<Length> for MarginRight {
10066 fn from(v: Length) -> Self {
10067 Self::Length(v)
10068 }
10069}
10070
10071impl From<Percentage> for MarginRight {
10072 fn from(v: Percentage) -> Self {
10073 Self::Percentage(v)
10074 }
10075}
10076
10077impl From<Raw> for MarginRight {
10078 fn from(v: Raw) -> Self {
10079 Self::Raw(v)
10080 }
10081}
10082
10083#[derive(Debug, Clone, PartialEq)]
10085#[non_exhaustive]
10086pub enum MarginTop {
10087 Auto,
10089 Length(Length),
10091 Percentage(Percentage),
10093 Raw(Raw),
10095}
10096
10097impl fmt::Display for MarginTop {
10098 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10099 match self {
10100 Self::Auto => f.write_str("auto"),
10101 Self::Length(v) => v.fmt(f),
10102 Self::Percentage(v) => v.fmt(f),
10103 Self::Raw(v) => v.fmt(f),
10104 }
10105 }
10106}
10107
10108impl From<Length> for MarginTop {
10109 fn from(v: Length) -> Self {
10110 Self::Length(v)
10111 }
10112}
10113
10114impl From<Percentage> for MarginTop {
10115 fn from(v: Percentage) -> Self {
10116 Self::Percentage(v)
10117 }
10118}
10119
10120impl From<Raw> for MarginTop {
10121 fn from(v: Raw) -> Self {
10122 Self::Raw(v)
10123 }
10124}
10125
10126#[derive(Debug, Clone, PartialEq)]
10128#[non_exhaustive]
10129pub enum Marker {
10130 None,
10132 Url(Url),
10134}
10135
10136impl fmt::Display for Marker {
10137 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10138 match self {
10139 Self::None => f.write_str("none"),
10140 Self::Url(v) => v.fmt(f),
10141 }
10142 }
10143}
10144
10145impl From<Url> for Marker {
10146 fn from(v: Url) -> Self {
10147 Self::Url(v)
10148 }
10149}
10150
10151#[derive(Debug, Clone, PartialEq)]
10153#[non_exhaustive]
10154pub enum MarkerEnd {
10155 None,
10157 Url(Url),
10159}
10160
10161impl fmt::Display for MarkerEnd {
10162 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10163 match self {
10164 Self::None => f.write_str("none"),
10165 Self::Url(v) => v.fmt(f),
10166 }
10167 }
10168}
10169
10170impl From<Url> for MarkerEnd {
10171 fn from(v: Url) -> Self {
10172 Self::Url(v)
10173 }
10174}
10175
10176#[derive(Debug, Clone, PartialEq)]
10178#[non_exhaustive]
10179pub enum MarkerMid {
10180 None,
10182 Url(Url),
10184}
10185
10186impl fmt::Display for MarkerMid {
10187 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10188 match self {
10189 Self::None => f.write_str("none"),
10190 Self::Url(v) => v.fmt(f),
10191 }
10192 }
10193}
10194
10195impl From<Url> for MarkerMid {
10196 fn from(v: Url) -> Self {
10197 Self::Url(v)
10198 }
10199}
10200
10201#[derive(Debug, Clone, PartialEq)]
10203#[non_exhaustive]
10204pub enum MarkerStart {
10205 None,
10207 Url(Url),
10209}
10210
10211impl fmt::Display for MarkerStart {
10212 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10213 match self {
10214 Self::None => f.write_str("none"),
10215 Self::Url(v) => v.fmt(f),
10216 }
10217 }
10218}
10219
10220impl From<Url> for MarkerStart {
10221 fn from(v: Url) -> Self {
10222 Self::Url(v)
10223 }
10224}
10225
10226#[derive(Debug, Clone, PartialEq)]
10228#[non_exhaustive]
10229pub enum Mask {
10230 Add,
10232 Alpha,
10234 BorderBox,
10236 Bottom,
10238 Center,
10240 ContentBox,
10242 Exclude,
10244 FillBox,
10246 Intersect,
10248 Left,
10250 Luminance,
10252 MarginBox,
10254 MatchSource,
10256 NoClip,
10258 NoRepeat,
10260 None,
10262 PaddingBox,
10264 Repeat,
10266 RepeatX,
10268 RepeatY,
10270 Right,
10272 Round,
10274 Space,
10276 StrokeBox,
10278 Subtract,
10280 Top,
10282 ViewBox,
10284 Length(Length),
10286 Percentage(Percentage),
10288 Url(Url),
10290 Raw(Raw),
10292}
10293
10294impl fmt::Display for Mask {
10295 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10296 match self {
10297 Self::Add => f.write_str("add"),
10298 Self::Alpha => f.write_str("alpha"),
10299 Self::BorderBox => f.write_str("border-box"),
10300 Self::Bottom => f.write_str("bottom"),
10301 Self::Center => f.write_str("center"),
10302 Self::ContentBox => f.write_str("content-box"),
10303 Self::Exclude => f.write_str("exclude"),
10304 Self::FillBox => f.write_str("fill-box"),
10305 Self::Intersect => f.write_str("intersect"),
10306 Self::Left => f.write_str("left"),
10307 Self::Luminance => f.write_str("luminance"),
10308 Self::MarginBox => f.write_str("margin-box"),
10309 Self::MatchSource => f.write_str("match-source"),
10310 Self::NoClip => f.write_str("no-clip"),
10311 Self::NoRepeat => f.write_str("no-repeat"),
10312 Self::None => f.write_str("none"),
10313 Self::PaddingBox => f.write_str("padding-box"),
10314 Self::Repeat => f.write_str("repeat"),
10315 Self::RepeatX => f.write_str("repeat-x"),
10316 Self::RepeatY => f.write_str("repeat-y"),
10317 Self::Right => f.write_str("right"),
10318 Self::Round => f.write_str("round"),
10319 Self::Space => f.write_str("space"),
10320 Self::StrokeBox => f.write_str("stroke-box"),
10321 Self::Subtract => f.write_str("subtract"),
10322 Self::Top => f.write_str("top"),
10323 Self::ViewBox => f.write_str("view-box"),
10324 Self::Length(v) => v.fmt(f),
10325 Self::Percentage(v) => v.fmt(f),
10326 Self::Url(v) => v.fmt(f),
10327 Self::Raw(v) => v.fmt(f),
10328 }
10329 }
10330}
10331
10332impl From<Length> for Mask {
10333 fn from(v: Length) -> Self {
10334 Self::Length(v)
10335 }
10336}
10337
10338impl From<Percentage> for Mask {
10339 fn from(v: Percentage) -> Self {
10340 Self::Percentage(v)
10341 }
10342}
10343
10344impl From<Url> for Mask {
10345 fn from(v: Url) -> Self {
10346 Self::Url(v)
10347 }
10348}
10349
10350impl From<Raw> for Mask {
10351 fn from(v: Raw) -> Self {
10352 Self::Raw(v)
10353 }
10354}
10355
10356#[derive(Debug, Clone, PartialEq)]
10358#[non_exhaustive]
10359pub enum MaskBorder {
10360 Alpha,
10362 Luminance,
10364 None,
10366 Repeat,
10368 Round,
10370 Space,
10372 Stretch,
10374 Percentage(Percentage),
10376 Number(f64),
10378 Url(Url),
10380 Raw(Raw),
10382}
10383
10384impl fmt::Display for MaskBorder {
10385 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10386 match self {
10387 Self::Alpha => f.write_str("alpha"),
10388 Self::Luminance => f.write_str("luminance"),
10389 Self::None => f.write_str("none"),
10390 Self::Repeat => f.write_str("repeat"),
10391 Self::Round => f.write_str("round"),
10392 Self::Space => f.write_str("space"),
10393 Self::Stretch => f.write_str("stretch"),
10394 Self::Percentage(v) => v.fmt(f),
10395 Self::Number(v) => v.fmt(f),
10396 Self::Url(v) => v.fmt(f),
10397 Self::Raw(v) => v.fmt(f),
10398 }
10399 }
10400}
10401
10402impl From<Percentage> for MaskBorder {
10403 fn from(v: Percentage) -> Self {
10404 Self::Percentage(v)
10405 }
10406}
10407
10408impl From<f64> for MaskBorder {
10409 fn from(v: f64) -> Self {
10410 Self::Number(v)
10411 }
10412}
10413
10414impl From<i32> for MaskBorder {
10415 fn from(v: i32) -> Self {
10416 Self::Number(f64::from(v))
10417 }
10418}
10419
10420impl From<Url> for MaskBorder {
10421 fn from(v: Url) -> Self {
10422 Self::Url(v)
10423 }
10424}
10425
10426impl From<Raw> for MaskBorder {
10427 fn from(v: Raw) -> Self {
10428 Self::Raw(v)
10429 }
10430}
10431
10432#[derive(Debug, Clone, PartialEq)]
10434#[non_exhaustive]
10435pub enum MaskBorderMode {
10436 Alpha,
10438 Luminance,
10440}
10441
10442impl fmt::Display for MaskBorderMode {
10443 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10444 match self {
10445 Self::Alpha => f.write_str("alpha"),
10446 Self::Luminance => f.write_str("luminance"),
10447 }
10448 }
10449}
10450
10451#[derive(Debug, Clone, PartialEq)]
10453#[non_exhaustive]
10454pub enum MaskBorderOutset {
10455 Length(Length),
10457 Number(f64),
10459 Raw(Raw),
10461}
10462
10463impl fmt::Display for MaskBorderOutset {
10464 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10465 match self {
10466 Self::Length(v) => v.fmt(f),
10467 Self::Number(v) => v.fmt(f),
10468 Self::Raw(v) => v.fmt(f),
10469 }
10470 }
10471}
10472
10473impl From<Length> for MaskBorderOutset {
10474 fn from(v: Length) -> Self {
10475 Self::Length(v)
10476 }
10477}
10478
10479impl From<f64> for MaskBorderOutset {
10480 fn from(v: f64) -> Self {
10481 Self::Number(v)
10482 }
10483}
10484
10485impl From<i32> for MaskBorderOutset {
10486 fn from(v: i32) -> Self {
10487 Self::Number(f64::from(v))
10488 }
10489}
10490
10491impl From<Raw> for MaskBorderOutset {
10492 fn from(v: Raw) -> Self {
10493 Self::Raw(v)
10494 }
10495}
10496
10497#[derive(Debug, Clone, PartialEq)]
10499#[non_exhaustive]
10500pub enum MaskBorderRepeat {
10501 Repeat,
10503 Round,
10505 Space,
10507 Stretch,
10509 Raw(Raw),
10511}
10512
10513impl fmt::Display for MaskBorderRepeat {
10514 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10515 match self {
10516 Self::Repeat => f.write_str("repeat"),
10517 Self::Round => f.write_str("round"),
10518 Self::Space => f.write_str("space"),
10519 Self::Stretch => f.write_str("stretch"),
10520 Self::Raw(v) => v.fmt(f),
10521 }
10522 }
10523}
10524
10525impl From<Raw> for MaskBorderRepeat {
10526 fn from(v: Raw) -> Self {
10527 Self::Raw(v)
10528 }
10529}
10530
10531#[derive(Debug, Clone, PartialEq)]
10533#[non_exhaustive]
10534pub enum MaskBorderSlice {
10535 Percentage(Percentage),
10537 Number(f64),
10539 Raw(Raw),
10541}
10542
10543impl fmt::Display for MaskBorderSlice {
10544 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10545 match self {
10546 Self::Percentage(v) => v.fmt(f),
10547 Self::Number(v) => v.fmt(f),
10548 Self::Raw(v) => v.fmt(f),
10549 }
10550 }
10551}
10552
10553impl From<Percentage> for MaskBorderSlice {
10554 fn from(v: Percentage) -> Self {
10555 Self::Percentage(v)
10556 }
10557}
10558
10559impl From<f64> for MaskBorderSlice {
10560 fn from(v: f64) -> Self {
10561 Self::Number(v)
10562 }
10563}
10564
10565impl From<i32> for MaskBorderSlice {
10566 fn from(v: i32) -> Self {
10567 Self::Number(f64::from(v))
10568 }
10569}
10570
10571impl From<Raw> for MaskBorderSlice {
10572 fn from(v: Raw) -> Self {
10573 Self::Raw(v)
10574 }
10575}
10576
10577#[derive(Debug, Clone, PartialEq)]
10579#[non_exhaustive]
10580pub enum MaskBorderSource {
10581 None,
10583 Url(Url),
10585 Raw(Raw),
10587}
10588
10589impl fmt::Display for MaskBorderSource {
10590 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10591 match self {
10592 Self::None => f.write_str("none"),
10593 Self::Url(v) => v.fmt(f),
10594 Self::Raw(v) => v.fmt(f),
10595 }
10596 }
10597}
10598
10599impl From<Url> for MaskBorderSource {
10600 fn from(v: Url) -> Self {
10601 Self::Url(v)
10602 }
10603}
10604
10605impl From<Raw> for MaskBorderSource {
10606 fn from(v: Raw) -> Self {
10607 Self::Raw(v)
10608 }
10609}
10610
10611#[derive(Debug, Clone, PartialEq)]
10613#[non_exhaustive]
10614pub enum MaskBorderWidth {
10615 Auto,
10617 Length(Length),
10619 Percentage(Percentage),
10621 Number(f64),
10623 Raw(Raw),
10625}
10626
10627impl fmt::Display for MaskBorderWidth {
10628 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10629 match self {
10630 Self::Auto => f.write_str("auto"),
10631 Self::Length(v) => v.fmt(f),
10632 Self::Percentage(v) => v.fmt(f),
10633 Self::Number(v) => v.fmt(f),
10634 Self::Raw(v) => v.fmt(f),
10635 }
10636 }
10637}
10638
10639impl From<Length> for MaskBorderWidth {
10640 fn from(v: Length) -> Self {
10641 Self::Length(v)
10642 }
10643}
10644
10645impl From<Percentage> for MaskBorderWidth {
10646 fn from(v: Percentage) -> Self {
10647 Self::Percentage(v)
10648 }
10649}
10650
10651impl From<f64> for MaskBorderWidth {
10652 fn from(v: f64) -> Self {
10653 Self::Number(v)
10654 }
10655}
10656
10657impl From<i32> for MaskBorderWidth {
10658 fn from(v: i32) -> Self {
10659 Self::Number(f64::from(v))
10660 }
10661}
10662
10663impl From<Raw> for MaskBorderWidth {
10664 fn from(v: Raw) -> Self {
10665 Self::Raw(v)
10666 }
10667}
10668
10669#[derive(Debug, Clone, PartialEq)]
10671#[non_exhaustive]
10672pub enum MaskClip {
10673 BorderBox,
10675 ContentBox,
10677 FillBox,
10679 NoClip,
10681 PaddingBox,
10683 StrokeBox,
10685 ViewBox,
10687 Raw(Raw),
10689}
10690
10691impl fmt::Display for MaskClip {
10692 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10693 match self {
10694 Self::BorderBox => f.write_str("border-box"),
10695 Self::ContentBox => f.write_str("content-box"),
10696 Self::FillBox => f.write_str("fill-box"),
10697 Self::NoClip => f.write_str("no-clip"),
10698 Self::PaddingBox => f.write_str("padding-box"),
10699 Self::StrokeBox => f.write_str("stroke-box"),
10700 Self::ViewBox => f.write_str("view-box"),
10701 Self::Raw(v) => v.fmt(f),
10702 }
10703 }
10704}
10705
10706impl From<Raw> for MaskClip {
10707 fn from(v: Raw) -> Self {
10708 Self::Raw(v)
10709 }
10710}
10711
10712#[derive(Debug, Clone, PartialEq)]
10714#[non_exhaustive]
10715pub enum MaskComposite {
10716 Add,
10718 Exclude,
10720 Intersect,
10722 Subtract,
10724 Raw(Raw),
10726}
10727
10728impl fmt::Display for MaskComposite {
10729 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10730 match self {
10731 Self::Add => f.write_str("add"),
10732 Self::Exclude => f.write_str("exclude"),
10733 Self::Intersect => f.write_str("intersect"),
10734 Self::Subtract => f.write_str("subtract"),
10735 Self::Raw(v) => v.fmt(f),
10736 }
10737 }
10738}
10739
10740impl From<Raw> for MaskComposite {
10741 fn from(v: Raw) -> Self {
10742 Self::Raw(v)
10743 }
10744}
10745
10746#[derive(Debug, Clone, PartialEq)]
10748#[non_exhaustive]
10749pub enum MaskImage {
10750 None,
10752 Url(Url),
10754 Raw(Raw),
10756}
10757
10758impl fmt::Display for MaskImage {
10759 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10760 match self {
10761 Self::None => f.write_str("none"),
10762 Self::Url(v) => v.fmt(f),
10763 Self::Raw(v) => v.fmt(f),
10764 }
10765 }
10766}
10767
10768impl From<Url> for MaskImage {
10769 fn from(v: Url) -> Self {
10770 Self::Url(v)
10771 }
10772}
10773
10774impl From<Raw> for MaskImage {
10775 fn from(v: Raw) -> Self {
10776 Self::Raw(v)
10777 }
10778}
10779
10780#[derive(Debug, Clone, PartialEq)]
10782#[non_exhaustive]
10783pub enum MaskMode {
10784 Alpha,
10786 Luminance,
10788 MatchSource,
10790 Raw(Raw),
10792}
10793
10794impl fmt::Display for MaskMode {
10795 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10796 match self {
10797 Self::Alpha => f.write_str("alpha"),
10798 Self::Luminance => f.write_str("luminance"),
10799 Self::MatchSource => f.write_str("match-source"),
10800 Self::Raw(v) => v.fmt(f),
10801 }
10802 }
10803}
10804
10805impl From<Raw> for MaskMode {
10806 fn from(v: Raw) -> Self {
10807 Self::Raw(v)
10808 }
10809}
10810
10811#[derive(Debug, Clone, PartialEq)]
10813#[non_exhaustive]
10814pub enum MaskOrigin {
10815 BorderBox,
10817 ContentBox,
10819 FillBox,
10821 PaddingBox,
10823 StrokeBox,
10825 ViewBox,
10827 Raw(Raw),
10829}
10830
10831impl fmt::Display for MaskOrigin {
10832 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10833 match self {
10834 Self::BorderBox => f.write_str("border-box"),
10835 Self::ContentBox => f.write_str("content-box"),
10836 Self::FillBox => f.write_str("fill-box"),
10837 Self::PaddingBox => f.write_str("padding-box"),
10838 Self::StrokeBox => f.write_str("stroke-box"),
10839 Self::ViewBox => f.write_str("view-box"),
10840 Self::Raw(v) => v.fmt(f),
10841 }
10842 }
10843}
10844
10845impl From<Raw> for MaskOrigin {
10846 fn from(v: Raw) -> Self {
10847 Self::Raw(v)
10848 }
10849}
10850
10851#[derive(Debug, Clone, PartialEq)]
10853#[non_exhaustive]
10854pub enum MaskPosition {
10855 Bottom,
10857 Center,
10859 Left,
10861 Right,
10863 Top,
10865 Length(Length),
10867 Percentage(Percentage),
10869 Raw(Raw),
10871}
10872
10873impl fmt::Display for MaskPosition {
10874 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10875 match self {
10876 Self::Bottom => f.write_str("bottom"),
10877 Self::Center => f.write_str("center"),
10878 Self::Left => f.write_str("left"),
10879 Self::Right => f.write_str("right"),
10880 Self::Top => f.write_str("top"),
10881 Self::Length(v) => v.fmt(f),
10882 Self::Percentage(v) => v.fmt(f),
10883 Self::Raw(v) => v.fmt(f),
10884 }
10885 }
10886}
10887
10888impl From<Length> for MaskPosition {
10889 fn from(v: Length) -> Self {
10890 Self::Length(v)
10891 }
10892}
10893
10894impl From<Percentage> for MaskPosition {
10895 fn from(v: Percentage) -> Self {
10896 Self::Percentage(v)
10897 }
10898}
10899
10900impl From<Raw> for MaskPosition {
10901 fn from(v: Raw) -> Self {
10902 Self::Raw(v)
10903 }
10904}
10905
10906#[derive(Debug, Clone, PartialEq)]
10908#[non_exhaustive]
10909pub enum MaskRepeat {
10910 NoRepeat,
10912 Repeat,
10914 RepeatX,
10916 RepeatY,
10918 Round,
10920 Space,
10922 Raw(Raw),
10924}
10925
10926impl fmt::Display for MaskRepeat {
10927 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10928 match self {
10929 Self::NoRepeat => f.write_str("no-repeat"),
10930 Self::Repeat => f.write_str("repeat"),
10931 Self::RepeatX => f.write_str("repeat-x"),
10932 Self::RepeatY => f.write_str("repeat-y"),
10933 Self::Round => f.write_str("round"),
10934 Self::Space => f.write_str("space"),
10935 Self::Raw(v) => v.fmt(f),
10936 }
10937 }
10938}
10939
10940impl From<Raw> for MaskRepeat {
10941 fn from(v: Raw) -> Self {
10942 Self::Raw(v)
10943 }
10944}
10945
10946#[derive(Debug, Clone, PartialEq)]
10948#[non_exhaustive]
10949pub enum MaskSize {
10950 Auto,
10952 Contain,
10954 Cover,
10956 Length(Length),
10958 Percentage(Percentage),
10960 Raw(Raw),
10962}
10963
10964impl fmt::Display for MaskSize {
10965 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10966 match self {
10967 Self::Auto => f.write_str("auto"),
10968 Self::Contain => f.write_str("contain"),
10969 Self::Cover => f.write_str("cover"),
10970 Self::Length(v) => v.fmt(f),
10971 Self::Percentage(v) => v.fmt(f),
10972 Self::Raw(v) => v.fmt(f),
10973 }
10974 }
10975}
10976
10977impl From<Length> for MaskSize {
10978 fn from(v: Length) -> Self {
10979 Self::Length(v)
10980 }
10981}
10982
10983impl From<Percentage> for MaskSize {
10984 fn from(v: Percentage) -> Self {
10985 Self::Percentage(v)
10986 }
10987}
10988
10989impl From<Raw> for MaskSize {
10990 fn from(v: Raw) -> Self {
10991 Self::Raw(v)
10992 }
10993}
10994
10995#[derive(Debug, Clone, PartialEq)]
10997#[non_exhaustive]
10998pub enum MaskType {
10999 Alpha,
11001 Luminance,
11003}
11004
11005impl fmt::Display for MaskType {
11006 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11007 match self {
11008 Self::Alpha => f.write_str("alpha"),
11009 Self::Luminance => f.write_str("luminance"),
11010 }
11011 }
11012}
11013
11014#[derive(Debug, Clone, PartialEq)]
11016#[non_exhaustive]
11017pub enum MathDepth {
11018 AutoAdd,
11020 Integer(i32),
11022 Raw(Raw),
11024}
11025
11026impl fmt::Display for MathDepth {
11027 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11028 match self {
11029 Self::AutoAdd => f.write_str("auto-add"),
11030 Self::Integer(v) => v.fmt(f),
11031 Self::Raw(v) => v.fmt(f),
11032 }
11033 }
11034}
11035
11036impl From<i32> for MathDepth {
11037 fn from(v: i32) -> Self {
11038 Self::Integer(v)
11039 }
11040}
11041
11042impl From<Raw> for MathDepth {
11043 fn from(v: Raw) -> Self {
11044 Self::Raw(v)
11045 }
11046}
11047
11048#[derive(Debug, Clone, PartialEq)]
11050#[non_exhaustive]
11051pub enum MathStyle {
11052 Compact,
11054 Normal,
11056}
11057
11058impl fmt::Display for MathStyle {
11059 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11060 match self {
11061 Self::Compact => f.write_str("compact"),
11062 Self::Normal => f.write_str("normal"),
11063 }
11064 }
11065}
11066
11067#[derive(Debug, Clone, PartialEq)]
11069#[non_exhaustive]
11070pub enum MaxBlockSize {
11071 FitContent,
11073 MaxContent,
11075 MinContent,
11077 None,
11079 Length(Length),
11081 Percentage(Percentage),
11083 Raw(Raw),
11085}
11086
11087impl fmt::Display for MaxBlockSize {
11088 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11089 match self {
11090 Self::FitContent => f.write_str("fit-content"),
11091 Self::MaxContent => f.write_str("max-content"),
11092 Self::MinContent => f.write_str("min-content"),
11093 Self::None => f.write_str("none"),
11094 Self::Length(v) => v.fmt(f),
11095 Self::Percentage(v) => v.fmt(f),
11096 Self::Raw(v) => v.fmt(f),
11097 }
11098 }
11099}
11100
11101impl From<Length> for MaxBlockSize {
11102 fn from(v: Length) -> Self {
11103 Self::Length(v)
11104 }
11105}
11106
11107impl From<Percentage> for MaxBlockSize {
11108 fn from(v: Percentage) -> Self {
11109 Self::Percentage(v)
11110 }
11111}
11112
11113impl From<Raw> for MaxBlockSize {
11114 fn from(v: Raw) -> Self {
11115 Self::Raw(v)
11116 }
11117}
11118
11119#[derive(Debug, Clone, PartialEq)]
11121#[non_exhaustive]
11122pub enum MaxHeight {
11123 FitContent,
11125 MaxContent,
11127 MinContent,
11129 None,
11131 Length(Length),
11133 Percentage(Percentage),
11135 Raw(Raw),
11137}
11138
11139impl fmt::Display for MaxHeight {
11140 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11141 match self {
11142 Self::FitContent => f.write_str("fit-content"),
11143 Self::MaxContent => f.write_str("max-content"),
11144 Self::MinContent => f.write_str("min-content"),
11145 Self::None => f.write_str("none"),
11146 Self::Length(v) => v.fmt(f),
11147 Self::Percentage(v) => v.fmt(f),
11148 Self::Raw(v) => v.fmt(f),
11149 }
11150 }
11151}
11152
11153impl From<Length> for MaxHeight {
11154 fn from(v: Length) -> Self {
11155 Self::Length(v)
11156 }
11157}
11158
11159impl From<Percentage> for MaxHeight {
11160 fn from(v: Percentage) -> Self {
11161 Self::Percentage(v)
11162 }
11163}
11164
11165impl From<Raw> for MaxHeight {
11166 fn from(v: Raw) -> Self {
11167 Self::Raw(v)
11168 }
11169}
11170
11171#[derive(Debug, Clone, PartialEq)]
11173#[non_exhaustive]
11174pub enum MaxInlineSize {
11175 FitContent,
11177 MaxContent,
11179 MinContent,
11181 None,
11183 Length(Length),
11185 Percentage(Percentage),
11187 Raw(Raw),
11189}
11190
11191impl fmt::Display for MaxInlineSize {
11192 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11193 match self {
11194 Self::FitContent => f.write_str("fit-content"),
11195 Self::MaxContent => f.write_str("max-content"),
11196 Self::MinContent => f.write_str("min-content"),
11197 Self::None => f.write_str("none"),
11198 Self::Length(v) => v.fmt(f),
11199 Self::Percentage(v) => v.fmt(f),
11200 Self::Raw(v) => v.fmt(f),
11201 }
11202 }
11203}
11204
11205impl From<Length> for MaxInlineSize {
11206 fn from(v: Length) -> Self {
11207 Self::Length(v)
11208 }
11209}
11210
11211impl From<Percentage> for MaxInlineSize {
11212 fn from(v: Percentage) -> Self {
11213 Self::Percentage(v)
11214 }
11215}
11216
11217impl From<Raw> for MaxInlineSize {
11218 fn from(v: Raw) -> Self {
11219 Self::Raw(v)
11220 }
11221}
11222
11223#[derive(Debug, Clone, PartialEq)]
11225#[non_exhaustive]
11226pub enum MaxWidth {
11227 FitContent,
11229 MaxContent,
11231 MinContent,
11233 None,
11235 Length(Length),
11237 Percentage(Percentage),
11239 Raw(Raw),
11241}
11242
11243impl fmt::Display for MaxWidth {
11244 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11245 match self {
11246 Self::FitContent => f.write_str("fit-content"),
11247 Self::MaxContent => f.write_str("max-content"),
11248 Self::MinContent => f.write_str("min-content"),
11249 Self::None => f.write_str("none"),
11250 Self::Length(v) => v.fmt(f),
11251 Self::Percentage(v) => v.fmt(f),
11252 Self::Raw(v) => v.fmt(f),
11253 }
11254 }
11255}
11256
11257impl From<Length> for MaxWidth {
11258 fn from(v: Length) -> Self {
11259 Self::Length(v)
11260 }
11261}
11262
11263impl From<Percentage> for MaxWidth {
11264 fn from(v: Percentage) -> Self {
11265 Self::Percentage(v)
11266 }
11267}
11268
11269impl From<Raw> for MaxWidth {
11270 fn from(v: Raw) -> Self {
11271 Self::Raw(v)
11272 }
11273}
11274
11275#[derive(Debug, Clone, PartialEq)]
11277#[non_exhaustive]
11278pub enum MinBlockSize {
11279 Auto,
11281 FitContent,
11283 MaxContent,
11285 MinContent,
11287 Length(Length),
11289 Percentage(Percentage),
11291 Raw(Raw),
11293}
11294
11295impl fmt::Display for MinBlockSize {
11296 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11297 match self {
11298 Self::Auto => f.write_str("auto"),
11299 Self::FitContent => f.write_str("fit-content"),
11300 Self::MaxContent => f.write_str("max-content"),
11301 Self::MinContent => f.write_str("min-content"),
11302 Self::Length(v) => v.fmt(f),
11303 Self::Percentage(v) => v.fmt(f),
11304 Self::Raw(v) => v.fmt(f),
11305 }
11306 }
11307}
11308
11309impl From<Length> for MinBlockSize {
11310 fn from(v: Length) -> Self {
11311 Self::Length(v)
11312 }
11313}
11314
11315impl From<Percentage> for MinBlockSize {
11316 fn from(v: Percentage) -> Self {
11317 Self::Percentage(v)
11318 }
11319}
11320
11321impl From<Raw> for MinBlockSize {
11322 fn from(v: Raw) -> Self {
11323 Self::Raw(v)
11324 }
11325}
11326
11327#[derive(Debug, Clone, PartialEq)]
11329#[non_exhaustive]
11330pub enum MinHeight {
11331 Auto,
11333 FitContent,
11335 MaxContent,
11337 MinContent,
11339 Length(Length),
11341 Percentage(Percentage),
11343 Raw(Raw),
11345}
11346
11347impl fmt::Display for MinHeight {
11348 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11349 match self {
11350 Self::Auto => f.write_str("auto"),
11351 Self::FitContent => f.write_str("fit-content"),
11352 Self::MaxContent => f.write_str("max-content"),
11353 Self::MinContent => f.write_str("min-content"),
11354 Self::Length(v) => v.fmt(f),
11355 Self::Percentage(v) => v.fmt(f),
11356 Self::Raw(v) => v.fmt(f),
11357 }
11358 }
11359}
11360
11361impl From<Length> for MinHeight {
11362 fn from(v: Length) -> Self {
11363 Self::Length(v)
11364 }
11365}
11366
11367impl From<Percentage> for MinHeight {
11368 fn from(v: Percentage) -> Self {
11369 Self::Percentage(v)
11370 }
11371}
11372
11373impl From<Raw> for MinHeight {
11374 fn from(v: Raw) -> Self {
11375 Self::Raw(v)
11376 }
11377}
11378
11379#[derive(Debug, Clone, PartialEq)]
11381#[non_exhaustive]
11382pub enum MinInlineSize {
11383 Auto,
11385 FitContent,
11387 MaxContent,
11389 MinContent,
11391 Length(Length),
11393 Percentage(Percentage),
11395 Raw(Raw),
11397}
11398
11399impl fmt::Display for MinInlineSize {
11400 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11401 match self {
11402 Self::Auto => f.write_str("auto"),
11403 Self::FitContent => f.write_str("fit-content"),
11404 Self::MaxContent => f.write_str("max-content"),
11405 Self::MinContent => f.write_str("min-content"),
11406 Self::Length(v) => v.fmt(f),
11407 Self::Percentage(v) => v.fmt(f),
11408 Self::Raw(v) => v.fmt(f),
11409 }
11410 }
11411}
11412
11413impl From<Length> for MinInlineSize {
11414 fn from(v: Length) -> Self {
11415 Self::Length(v)
11416 }
11417}
11418
11419impl From<Percentage> for MinInlineSize {
11420 fn from(v: Percentage) -> Self {
11421 Self::Percentage(v)
11422 }
11423}
11424
11425impl From<Raw> for MinInlineSize {
11426 fn from(v: Raw) -> Self {
11427 Self::Raw(v)
11428 }
11429}
11430
11431#[derive(Debug, Clone, PartialEq)]
11433#[non_exhaustive]
11434pub enum MinWidth {
11435 Auto,
11437 FitContent,
11439 MaxContent,
11441 MinContent,
11443 Length(Length),
11445 Percentage(Percentage),
11447 Raw(Raw),
11449}
11450
11451impl fmt::Display for MinWidth {
11452 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11453 match self {
11454 Self::Auto => f.write_str("auto"),
11455 Self::FitContent => f.write_str("fit-content"),
11456 Self::MaxContent => f.write_str("max-content"),
11457 Self::MinContent => f.write_str("min-content"),
11458 Self::Length(v) => v.fmt(f),
11459 Self::Percentage(v) => v.fmt(f),
11460 Self::Raw(v) => v.fmt(f),
11461 }
11462 }
11463}
11464
11465impl From<Length> for MinWidth {
11466 fn from(v: Length) -> Self {
11467 Self::Length(v)
11468 }
11469}
11470
11471impl From<Percentage> for MinWidth {
11472 fn from(v: Percentage) -> Self {
11473 Self::Percentage(v)
11474 }
11475}
11476
11477impl From<Raw> for MinWidth {
11478 fn from(v: Raw) -> Self {
11479 Self::Raw(v)
11480 }
11481}
11482
11483#[derive(Debug, Clone, PartialEq)]
11485#[non_exhaustive]
11486pub enum MixBlendMode {
11487 Color,
11489 ColorBurn,
11491 ColorDodge,
11493 Darken,
11495 Difference,
11497 Exclusion,
11499 HardLight,
11501 Hue,
11503 Lighten,
11505 Luminosity,
11507 Multiply,
11509 Normal,
11511 Overlay,
11513 PlusDarker,
11515 PlusLighter,
11517 Saturation,
11519 Screen,
11521 SoftLight,
11523}
11524
11525impl fmt::Display for MixBlendMode {
11526 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11527 match self {
11528 Self::Color => f.write_str("color"),
11529 Self::ColorBurn => f.write_str("color-burn"),
11530 Self::ColorDodge => f.write_str("color-dodge"),
11531 Self::Darken => f.write_str("darken"),
11532 Self::Difference => f.write_str("difference"),
11533 Self::Exclusion => f.write_str("exclusion"),
11534 Self::HardLight => f.write_str("hard-light"),
11535 Self::Hue => f.write_str("hue"),
11536 Self::Lighten => f.write_str("lighten"),
11537 Self::Luminosity => f.write_str("luminosity"),
11538 Self::Multiply => f.write_str("multiply"),
11539 Self::Normal => f.write_str("normal"),
11540 Self::Overlay => f.write_str("overlay"),
11541 Self::PlusDarker => f.write_str("plus-darker"),
11542 Self::PlusLighter => f.write_str("plus-lighter"),
11543 Self::Saturation => f.write_str("saturation"),
11544 Self::Screen => f.write_str("screen"),
11545 Self::SoftLight => f.write_str("soft-light"),
11546 }
11547 }
11548}
11549
11550#[derive(Debug, Clone, PartialEq)]
11552#[non_exhaustive]
11553pub enum ObjectFit {
11554 Contain,
11556 Cover,
11558 Fill,
11560 None,
11562 ScaleDown,
11564}
11565
11566impl fmt::Display for ObjectFit {
11567 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11568 match self {
11569 Self::Contain => f.write_str("contain"),
11570 Self::Cover => f.write_str("cover"),
11571 Self::Fill => f.write_str("fill"),
11572 Self::None => f.write_str("none"),
11573 Self::ScaleDown => f.write_str("scale-down"),
11574 }
11575 }
11576}
11577
11578#[derive(Debug, Clone, PartialEq)]
11580#[non_exhaustive]
11581pub enum ObjectPosition {
11582 Bottom,
11584 Center,
11586 Left,
11588 Right,
11590 Top,
11592 Length(Length),
11594 Percentage(Percentage),
11596 Raw(Raw),
11598}
11599
11600impl fmt::Display for ObjectPosition {
11601 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11602 match self {
11603 Self::Bottom => f.write_str("bottom"),
11604 Self::Center => f.write_str("center"),
11605 Self::Left => f.write_str("left"),
11606 Self::Right => f.write_str("right"),
11607 Self::Top => f.write_str("top"),
11608 Self::Length(v) => v.fmt(f),
11609 Self::Percentage(v) => v.fmt(f),
11610 Self::Raw(v) => v.fmt(f),
11611 }
11612 }
11613}
11614
11615impl From<Length> for ObjectPosition {
11616 fn from(v: Length) -> Self {
11617 Self::Length(v)
11618 }
11619}
11620
11621impl From<Percentage> for ObjectPosition {
11622 fn from(v: Percentage) -> Self {
11623 Self::Percentage(v)
11624 }
11625}
11626
11627impl From<Raw> for ObjectPosition {
11628 fn from(v: Raw) -> Self {
11629 Self::Raw(v)
11630 }
11631}
11632
11633#[derive(Debug, Clone, PartialEq)]
11635#[non_exhaustive]
11636pub enum Offset {
11637 Auto,
11639 BorderBox,
11641 Bottom,
11643 Center,
11645 ContentBox,
11647 FillBox,
11649 Left,
11651 None,
11653 Normal,
11655 PaddingBox,
11657 Right,
11659 StrokeBox,
11661 Top,
11663 ViewBox,
11665 Length(Length),
11667 Percentage(Percentage),
11669 Raw(Raw),
11671}
11672
11673impl fmt::Display for Offset {
11674 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11675 match self {
11676 Self::Auto => f.write_str("auto"),
11677 Self::BorderBox => f.write_str("border-box"),
11678 Self::Bottom => f.write_str("bottom"),
11679 Self::Center => f.write_str("center"),
11680 Self::ContentBox => f.write_str("content-box"),
11681 Self::FillBox => f.write_str("fill-box"),
11682 Self::Left => f.write_str("left"),
11683 Self::None => f.write_str("none"),
11684 Self::Normal => f.write_str("normal"),
11685 Self::PaddingBox => f.write_str("padding-box"),
11686 Self::Right => f.write_str("right"),
11687 Self::StrokeBox => f.write_str("stroke-box"),
11688 Self::Top => f.write_str("top"),
11689 Self::ViewBox => f.write_str("view-box"),
11690 Self::Length(v) => v.fmt(f),
11691 Self::Percentage(v) => v.fmt(f),
11692 Self::Raw(v) => v.fmt(f),
11693 }
11694 }
11695}
11696
11697impl From<Length> for Offset {
11698 fn from(v: Length) -> Self {
11699 Self::Length(v)
11700 }
11701}
11702
11703impl From<Percentage> for Offset {
11704 fn from(v: Percentage) -> Self {
11705 Self::Percentage(v)
11706 }
11707}
11708
11709impl From<Raw> for Offset {
11710 fn from(v: Raw) -> Self {
11711 Self::Raw(v)
11712 }
11713}
11714
11715#[derive(Debug, Clone, PartialEq)]
11717#[non_exhaustive]
11718pub enum OffsetAnchor {
11719 Auto,
11721 Bottom,
11723 Center,
11725 Left,
11727 Right,
11729 Top,
11731 Length(Length),
11733 Percentage(Percentage),
11735 Raw(Raw),
11737}
11738
11739impl fmt::Display for OffsetAnchor {
11740 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11741 match self {
11742 Self::Auto => f.write_str("auto"),
11743 Self::Bottom => f.write_str("bottom"),
11744 Self::Center => f.write_str("center"),
11745 Self::Left => f.write_str("left"),
11746 Self::Right => f.write_str("right"),
11747 Self::Top => f.write_str("top"),
11748 Self::Length(v) => v.fmt(f),
11749 Self::Percentage(v) => v.fmt(f),
11750 Self::Raw(v) => v.fmt(f),
11751 }
11752 }
11753}
11754
11755impl From<Length> for OffsetAnchor {
11756 fn from(v: Length) -> Self {
11757 Self::Length(v)
11758 }
11759}
11760
11761impl From<Percentage> for OffsetAnchor {
11762 fn from(v: Percentage) -> Self {
11763 Self::Percentage(v)
11764 }
11765}
11766
11767impl From<Raw> for OffsetAnchor {
11768 fn from(v: Raw) -> Self {
11769 Self::Raw(v)
11770 }
11771}
11772
11773#[derive(Debug, Clone, PartialEq)]
11775#[non_exhaustive]
11776pub enum OffsetDistance {
11777 Length(Length),
11779 Percentage(Percentage),
11781}
11782
11783impl fmt::Display for OffsetDistance {
11784 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11785 match self {
11786 Self::Length(v) => v.fmt(f),
11787 Self::Percentage(v) => v.fmt(f),
11788 }
11789 }
11790}
11791
11792impl From<Length> for OffsetDistance {
11793 fn from(v: Length) -> Self {
11794 Self::Length(v)
11795 }
11796}
11797
11798impl From<Percentage> for OffsetDistance {
11799 fn from(v: Percentage) -> Self {
11800 Self::Percentage(v)
11801 }
11802}
11803
11804#[derive(Debug, Clone, PartialEq)]
11806#[non_exhaustive]
11807pub enum OffsetPath {
11808 BorderBox,
11810 ContentBox,
11812 FillBox,
11814 None,
11816 PaddingBox,
11818 StrokeBox,
11820 ViewBox,
11822 Raw(Raw),
11824}
11825
11826impl fmt::Display for OffsetPath {
11827 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11828 match self {
11829 Self::BorderBox => f.write_str("border-box"),
11830 Self::ContentBox => f.write_str("content-box"),
11831 Self::FillBox => f.write_str("fill-box"),
11832 Self::None => f.write_str("none"),
11833 Self::PaddingBox => f.write_str("padding-box"),
11834 Self::StrokeBox => f.write_str("stroke-box"),
11835 Self::ViewBox => f.write_str("view-box"),
11836 Self::Raw(v) => v.fmt(f),
11837 }
11838 }
11839}
11840
11841impl From<Raw> for OffsetPath {
11842 fn from(v: Raw) -> Self {
11843 Self::Raw(v)
11844 }
11845}
11846
11847#[derive(Debug, Clone, PartialEq)]
11849#[non_exhaustive]
11850pub enum OffsetPosition {
11851 Auto,
11853 Bottom,
11855 Center,
11857 Left,
11859 Normal,
11861 Right,
11863 Top,
11865 Length(Length),
11867 Percentage(Percentage),
11869 Raw(Raw),
11871}
11872
11873impl fmt::Display for OffsetPosition {
11874 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11875 match self {
11876 Self::Auto => f.write_str("auto"),
11877 Self::Bottom => f.write_str("bottom"),
11878 Self::Center => f.write_str("center"),
11879 Self::Left => f.write_str("left"),
11880 Self::Normal => f.write_str("normal"),
11881 Self::Right => f.write_str("right"),
11882 Self::Top => f.write_str("top"),
11883 Self::Length(v) => v.fmt(f),
11884 Self::Percentage(v) => v.fmt(f),
11885 Self::Raw(v) => v.fmt(f),
11886 }
11887 }
11888}
11889
11890impl From<Length> for OffsetPosition {
11891 fn from(v: Length) -> Self {
11892 Self::Length(v)
11893 }
11894}
11895
11896impl From<Percentage> for OffsetPosition {
11897 fn from(v: Percentage) -> Self {
11898 Self::Percentage(v)
11899 }
11900}
11901
11902impl From<Raw> for OffsetPosition {
11903 fn from(v: Raw) -> Self {
11904 Self::Raw(v)
11905 }
11906}
11907
11908#[derive(Debug, Clone, PartialEq)]
11910#[non_exhaustive]
11911pub enum OffsetRotate {
11912 Auto,
11914 Reverse,
11916 Angle(Angle),
11918 Raw(Raw),
11920}
11921
11922impl fmt::Display for OffsetRotate {
11923 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11924 match self {
11925 Self::Auto => f.write_str("auto"),
11926 Self::Reverse => f.write_str("reverse"),
11927 Self::Angle(v) => v.fmt(f),
11928 Self::Raw(v) => v.fmt(f),
11929 }
11930 }
11931}
11932
11933impl From<Angle> for OffsetRotate {
11934 fn from(v: Angle) -> Self {
11935 Self::Angle(v)
11936 }
11937}
11938
11939impl From<Raw> for OffsetRotate {
11940 fn from(v: Raw) -> Self {
11941 Self::Raw(v)
11942 }
11943}
11944
11945#[derive(Debug, Clone, PartialEq)]
11947#[non_exhaustive]
11948pub enum Opacity {
11949 Percentage(Percentage),
11951 Number(f64),
11953}
11954
11955impl fmt::Display for Opacity {
11956 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11957 match self {
11958 Self::Percentage(v) => v.fmt(f),
11959 Self::Number(v) => v.fmt(f),
11960 }
11961 }
11962}
11963
11964impl From<Percentage> for Opacity {
11965 fn from(v: Percentage) -> Self {
11966 Self::Percentage(v)
11967 }
11968}
11969
11970impl From<f64> for Opacity {
11971 fn from(v: f64) -> Self {
11972 Self::Number(v)
11973 }
11974}
11975
11976impl From<i32> for Opacity {
11977 fn from(v: i32) -> Self {
11978 Self::Number(f64::from(v))
11979 }
11980}
11981
11982#[derive(Debug, Clone, PartialEq)]
11984#[non_exhaustive]
11985pub enum Outline {
11986 Auto,
11988 Dashed,
11990 Dotted,
11992 Double,
11994 Groove,
11996 Inset,
11998 Medium,
12000 None,
12002 Outset,
12004 Ridge,
12006 Solid,
12008 Thick,
12010 Thin,
12012 Length(Length),
12014 Color(Color),
12016 Raw(Raw),
12018}
12019
12020impl fmt::Display for Outline {
12021 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12022 match self {
12023 Self::Auto => f.write_str("auto"),
12024 Self::Dashed => f.write_str("dashed"),
12025 Self::Dotted => f.write_str("dotted"),
12026 Self::Double => f.write_str("double"),
12027 Self::Groove => f.write_str("groove"),
12028 Self::Inset => f.write_str("inset"),
12029 Self::Medium => f.write_str("medium"),
12030 Self::None => f.write_str("none"),
12031 Self::Outset => f.write_str("outset"),
12032 Self::Ridge => f.write_str("ridge"),
12033 Self::Solid => f.write_str("solid"),
12034 Self::Thick => f.write_str("thick"),
12035 Self::Thin => f.write_str("thin"),
12036 Self::Length(v) => v.fmt(f),
12037 Self::Color(v) => v.fmt(f),
12038 Self::Raw(v) => v.fmt(f),
12039 }
12040 }
12041}
12042
12043impl From<Length> for Outline {
12044 fn from(v: Length) -> Self {
12045 Self::Length(v)
12046 }
12047}
12048
12049impl From<Color> for Outline {
12050 fn from(v: Color) -> Self {
12051 Self::Color(v)
12052 }
12053}
12054
12055impl From<Raw> for Outline {
12056 fn from(v: Raw) -> Self {
12057 Self::Raw(v)
12058 }
12059}
12060
12061#[derive(Debug, Clone, PartialEq)]
12063#[non_exhaustive]
12064pub enum OutlineColor {
12065 Auto,
12067 Color(Color),
12069}
12070
12071impl fmt::Display for OutlineColor {
12072 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12073 match self {
12074 Self::Auto => f.write_str("auto"),
12075 Self::Color(v) => v.fmt(f),
12076 }
12077 }
12078}
12079
12080impl From<Color> for OutlineColor {
12081 fn from(v: Color) -> Self {
12082 Self::Color(v)
12083 }
12084}
12085
12086#[derive(Debug, Clone, PartialEq)]
12088#[non_exhaustive]
12089pub enum OutlineStyle {
12090 Auto,
12092 Dashed,
12094 Dotted,
12096 Double,
12098 Groove,
12100 Inset,
12102 None,
12104 Outset,
12106 Ridge,
12108 Solid,
12110}
12111
12112impl fmt::Display for OutlineStyle {
12113 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12114 match self {
12115 Self::Auto => f.write_str("auto"),
12116 Self::Dashed => f.write_str("dashed"),
12117 Self::Dotted => f.write_str("dotted"),
12118 Self::Double => f.write_str("double"),
12119 Self::Groove => f.write_str("groove"),
12120 Self::Inset => f.write_str("inset"),
12121 Self::None => f.write_str("none"),
12122 Self::Outset => f.write_str("outset"),
12123 Self::Ridge => f.write_str("ridge"),
12124 Self::Solid => f.write_str("solid"),
12125 }
12126 }
12127}
12128
12129#[derive(Debug, Clone, PartialEq)]
12131#[non_exhaustive]
12132pub enum OutlineWidth {
12133 Medium,
12135 Thick,
12137 Thin,
12139 Length(Length),
12141}
12142
12143impl fmt::Display for OutlineWidth {
12144 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12145 match self {
12146 Self::Medium => f.write_str("medium"),
12147 Self::Thick => f.write_str("thick"),
12148 Self::Thin => f.write_str("thin"),
12149 Self::Length(v) => v.fmt(f),
12150 }
12151 }
12152}
12153
12154impl From<Length> for OutlineWidth {
12155 fn from(v: Length) -> Self {
12156 Self::Length(v)
12157 }
12158}
12159
12160#[derive(Debug, Clone, PartialEq)]
12162#[non_exhaustive]
12163pub enum Overflow {
12164 Auto,
12166 Clip,
12168 Hidden,
12170 Scroll,
12172 Visible,
12174 Raw(Raw),
12176}
12177
12178impl fmt::Display for Overflow {
12179 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12180 match self {
12181 Self::Auto => f.write_str("auto"),
12182 Self::Clip => f.write_str("clip"),
12183 Self::Hidden => f.write_str("hidden"),
12184 Self::Scroll => f.write_str("scroll"),
12185 Self::Visible => f.write_str("visible"),
12186 Self::Raw(v) => v.fmt(f),
12187 }
12188 }
12189}
12190
12191impl From<Raw> for Overflow {
12192 fn from(v: Raw) -> Self {
12193 Self::Raw(v)
12194 }
12195}
12196
12197#[derive(Debug, Clone, PartialEq)]
12199#[non_exhaustive]
12200pub enum OverflowAnchor {
12201 Auto,
12203 None,
12205}
12206
12207impl fmt::Display for OverflowAnchor {
12208 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12209 match self {
12210 Self::Auto => f.write_str("auto"),
12211 Self::None => f.write_str("none"),
12212 }
12213 }
12214}
12215
12216#[derive(Debug, Clone, PartialEq)]
12218#[non_exhaustive]
12219pub enum OverflowBlock {
12220 Auto,
12222 Clip,
12224 Hidden,
12226 Scroll,
12228 Visible,
12230}
12231
12232impl fmt::Display for OverflowBlock {
12233 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12234 match self {
12235 Self::Auto => f.write_str("auto"),
12236 Self::Clip => f.write_str("clip"),
12237 Self::Hidden => f.write_str("hidden"),
12238 Self::Scroll => f.write_str("scroll"),
12239 Self::Visible => f.write_str("visible"),
12240 }
12241 }
12242}
12243
12244#[derive(Debug, Clone, PartialEq)]
12246#[non_exhaustive]
12247pub enum OverflowClipMargin {
12248 BorderBox,
12250 ContentBox,
12252 PaddingBox,
12254 Length(Length),
12256 Raw(Raw),
12258}
12259
12260impl fmt::Display for OverflowClipMargin {
12261 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12262 match self {
12263 Self::BorderBox => f.write_str("border-box"),
12264 Self::ContentBox => f.write_str("content-box"),
12265 Self::PaddingBox => f.write_str("padding-box"),
12266 Self::Length(v) => v.fmt(f),
12267 Self::Raw(v) => v.fmt(f),
12268 }
12269 }
12270}
12271
12272impl From<Length> for OverflowClipMargin {
12273 fn from(v: Length) -> Self {
12274 Self::Length(v)
12275 }
12276}
12277
12278impl From<Raw> for OverflowClipMargin {
12279 fn from(v: Raw) -> Self {
12280 Self::Raw(v)
12281 }
12282}
12283
12284#[derive(Debug, Clone, PartialEq)]
12286#[non_exhaustive]
12287pub enum OverflowInline {
12288 Auto,
12290 Clip,
12292 Hidden,
12294 Scroll,
12296 Visible,
12298}
12299
12300impl fmt::Display for OverflowInline {
12301 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12302 match self {
12303 Self::Auto => f.write_str("auto"),
12304 Self::Clip => f.write_str("clip"),
12305 Self::Hidden => f.write_str("hidden"),
12306 Self::Scroll => f.write_str("scroll"),
12307 Self::Visible => f.write_str("visible"),
12308 }
12309 }
12310}
12311
12312#[derive(Debug, Clone, PartialEq)]
12314#[non_exhaustive]
12315pub enum OverflowWrap {
12316 Anywhere,
12318 BreakWord,
12320 Normal,
12322}
12323
12324impl fmt::Display for OverflowWrap {
12325 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12326 match self {
12327 Self::Anywhere => f.write_str("anywhere"),
12328 Self::BreakWord => f.write_str("break-word"),
12329 Self::Normal => f.write_str("normal"),
12330 }
12331 }
12332}
12333
12334#[derive(Debug, Clone, PartialEq)]
12336#[non_exhaustive]
12337pub enum OverflowX {
12338 Auto,
12340 Clip,
12342 Hidden,
12344 Scroll,
12346 Visible,
12348}
12349
12350impl fmt::Display for OverflowX {
12351 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12352 match self {
12353 Self::Auto => f.write_str("auto"),
12354 Self::Clip => f.write_str("clip"),
12355 Self::Hidden => f.write_str("hidden"),
12356 Self::Scroll => f.write_str("scroll"),
12357 Self::Visible => f.write_str("visible"),
12358 }
12359 }
12360}
12361
12362#[derive(Debug, Clone, PartialEq)]
12364#[non_exhaustive]
12365pub enum OverflowY {
12366 Auto,
12368 Clip,
12370 Hidden,
12372 Scroll,
12374 Visible,
12376}
12377
12378impl fmt::Display for OverflowY {
12379 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12380 match self {
12381 Self::Auto => f.write_str("auto"),
12382 Self::Clip => f.write_str("clip"),
12383 Self::Hidden => f.write_str("hidden"),
12384 Self::Scroll => f.write_str("scroll"),
12385 Self::Visible => f.write_str("visible"),
12386 }
12387 }
12388}
12389
12390#[derive(Debug, Clone, PartialEq)]
12392#[non_exhaustive]
12393pub enum OverscrollBehavior {
12394 Auto,
12396 Contain,
12398 None,
12400 Raw(Raw),
12402}
12403
12404impl fmt::Display for OverscrollBehavior {
12405 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12406 match self {
12407 Self::Auto => f.write_str("auto"),
12408 Self::Contain => f.write_str("contain"),
12409 Self::None => f.write_str("none"),
12410 Self::Raw(v) => v.fmt(f),
12411 }
12412 }
12413}
12414
12415impl From<Raw> for OverscrollBehavior {
12416 fn from(v: Raw) -> Self {
12417 Self::Raw(v)
12418 }
12419}
12420
12421#[derive(Debug, Clone, PartialEq)]
12423#[non_exhaustive]
12424pub enum OverscrollBehaviorBlock {
12425 Auto,
12427 Contain,
12429 None,
12431}
12432
12433impl fmt::Display for OverscrollBehaviorBlock {
12434 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12435 match self {
12436 Self::Auto => f.write_str("auto"),
12437 Self::Contain => f.write_str("contain"),
12438 Self::None => f.write_str("none"),
12439 }
12440 }
12441}
12442
12443#[derive(Debug, Clone, PartialEq)]
12445#[non_exhaustive]
12446pub enum OverscrollBehaviorInline {
12447 Auto,
12449 Contain,
12451 None,
12453}
12454
12455impl fmt::Display for OverscrollBehaviorInline {
12456 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12457 match self {
12458 Self::Auto => f.write_str("auto"),
12459 Self::Contain => f.write_str("contain"),
12460 Self::None => f.write_str("none"),
12461 }
12462 }
12463}
12464
12465#[derive(Debug, Clone, PartialEq)]
12467#[non_exhaustive]
12468pub enum OverscrollBehaviorX {
12469 Auto,
12471 Contain,
12473 None,
12475}
12476
12477impl fmt::Display for OverscrollBehaviorX {
12478 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12479 match self {
12480 Self::Auto => f.write_str("auto"),
12481 Self::Contain => f.write_str("contain"),
12482 Self::None => f.write_str("none"),
12483 }
12484 }
12485}
12486
12487#[derive(Debug, Clone, PartialEq)]
12489#[non_exhaustive]
12490pub enum OverscrollBehaviorY {
12491 Auto,
12493 Contain,
12495 None,
12497}
12498
12499impl fmt::Display for OverscrollBehaviorY {
12500 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12501 match self {
12502 Self::Auto => f.write_str("auto"),
12503 Self::Contain => f.write_str("contain"),
12504 Self::None => f.write_str("none"),
12505 }
12506 }
12507}
12508
12509#[derive(Debug, Clone, PartialEq)]
12511#[non_exhaustive]
12512pub enum Padding {
12513 Length(Length),
12515 Percentage(Percentage),
12517 Raw(Raw),
12519}
12520
12521impl fmt::Display for Padding {
12522 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12523 match self {
12524 Self::Length(v) => v.fmt(f),
12525 Self::Percentage(v) => v.fmt(f),
12526 Self::Raw(v) => v.fmt(f),
12527 }
12528 }
12529}
12530
12531impl From<Length> for Padding {
12532 fn from(v: Length) -> Self {
12533 Self::Length(v)
12534 }
12535}
12536
12537impl From<Percentage> for Padding {
12538 fn from(v: Percentage) -> Self {
12539 Self::Percentage(v)
12540 }
12541}
12542
12543impl From<Raw> for Padding {
12544 fn from(v: Raw) -> Self {
12545 Self::Raw(v)
12546 }
12547}
12548
12549#[derive(Debug, Clone, PartialEq)]
12551#[non_exhaustive]
12552pub enum PaddingBlock {
12553 Length(Length),
12555 Percentage(Percentage),
12557 Raw(Raw),
12559}
12560
12561impl fmt::Display for PaddingBlock {
12562 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12563 match self {
12564 Self::Length(v) => v.fmt(f),
12565 Self::Percentage(v) => v.fmt(f),
12566 Self::Raw(v) => v.fmt(f),
12567 }
12568 }
12569}
12570
12571impl From<Length> for PaddingBlock {
12572 fn from(v: Length) -> Self {
12573 Self::Length(v)
12574 }
12575}
12576
12577impl From<Percentage> for PaddingBlock {
12578 fn from(v: Percentage) -> Self {
12579 Self::Percentage(v)
12580 }
12581}
12582
12583impl From<Raw> for PaddingBlock {
12584 fn from(v: Raw) -> Self {
12585 Self::Raw(v)
12586 }
12587}
12588
12589#[derive(Debug, Clone, PartialEq)]
12591#[non_exhaustive]
12592pub enum PaddingBlockEnd {
12593 Length(Length),
12595 Percentage(Percentage),
12597}
12598
12599impl fmt::Display for PaddingBlockEnd {
12600 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12601 match self {
12602 Self::Length(v) => v.fmt(f),
12603 Self::Percentage(v) => v.fmt(f),
12604 }
12605 }
12606}
12607
12608impl From<Length> for PaddingBlockEnd {
12609 fn from(v: Length) -> Self {
12610 Self::Length(v)
12611 }
12612}
12613
12614impl From<Percentage> for PaddingBlockEnd {
12615 fn from(v: Percentage) -> Self {
12616 Self::Percentage(v)
12617 }
12618}
12619
12620#[derive(Debug, Clone, PartialEq)]
12622#[non_exhaustive]
12623pub enum PaddingBlockStart {
12624 Length(Length),
12626 Percentage(Percentage),
12628}
12629
12630impl fmt::Display for PaddingBlockStart {
12631 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12632 match self {
12633 Self::Length(v) => v.fmt(f),
12634 Self::Percentage(v) => v.fmt(f),
12635 }
12636 }
12637}
12638
12639impl From<Length> for PaddingBlockStart {
12640 fn from(v: Length) -> Self {
12641 Self::Length(v)
12642 }
12643}
12644
12645impl From<Percentage> for PaddingBlockStart {
12646 fn from(v: Percentage) -> Self {
12647 Self::Percentage(v)
12648 }
12649}
12650
12651#[derive(Debug, Clone, PartialEq)]
12653#[non_exhaustive]
12654pub enum PaddingBottom {
12655 Length(Length),
12657 Percentage(Percentage),
12659}
12660
12661impl fmt::Display for PaddingBottom {
12662 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12663 match self {
12664 Self::Length(v) => v.fmt(f),
12665 Self::Percentage(v) => v.fmt(f),
12666 }
12667 }
12668}
12669
12670impl From<Length> for PaddingBottom {
12671 fn from(v: Length) -> Self {
12672 Self::Length(v)
12673 }
12674}
12675
12676impl From<Percentage> for PaddingBottom {
12677 fn from(v: Percentage) -> Self {
12678 Self::Percentage(v)
12679 }
12680}
12681
12682#[derive(Debug, Clone, PartialEq)]
12684#[non_exhaustive]
12685pub enum PaddingInline {
12686 Length(Length),
12688 Percentage(Percentage),
12690 Raw(Raw),
12692}
12693
12694impl fmt::Display for PaddingInline {
12695 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12696 match self {
12697 Self::Length(v) => v.fmt(f),
12698 Self::Percentage(v) => v.fmt(f),
12699 Self::Raw(v) => v.fmt(f),
12700 }
12701 }
12702}
12703
12704impl From<Length> for PaddingInline {
12705 fn from(v: Length) -> Self {
12706 Self::Length(v)
12707 }
12708}
12709
12710impl From<Percentage> for PaddingInline {
12711 fn from(v: Percentage) -> Self {
12712 Self::Percentage(v)
12713 }
12714}
12715
12716impl From<Raw> for PaddingInline {
12717 fn from(v: Raw) -> Self {
12718 Self::Raw(v)
12719 }
12720}
12721
12722#[derive(Debug, Clone, PartialEq)]
12724#[non_exhaustive]
12725pub enum PaddingInlineEnd {
12726 Length(Length),
12728 Percentage(Percentage),
12730}
12731
12732impl fmt::Display for PaddingInlineEnd {
12733 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12734 match self {
12735 Self::Length(v) => v.fmt(f),
12736 Self::Percentage(v) => v.fmt(f),
12737 }
12738 }
12739}
12740
12741impl From<Length> for PaddingInlineEnd {
12742 fn from(v: Length) -> Self {
12743 Self::Length(v)
12744 }
12745}
12746
12747impl From<Percentage> for PaddingInlineEnd {
12748 fn from(v: Percentage) -> Self {
12749 Self::Percentage(v)
12750 }
12751}
12752
12753#[derive(Debug, Clone, PartialEq)]
12755#[non_exhaustive]
12756pub enum PaddingInlineStart {
12757 Length(Length),
12759 Percentage(Percentage),
12761}
12762
12763impl fmt::Display for PaddingInlineStart {
12764 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12765 match self {
12766 Self::Length(v) => v.fmt(f),
12767 Self::Percentage(v) => v.fmt(f),
12768 }
12769 }
12770}
12771
12772impl From<Length> for PaddingInlineStart {
12773 fn from(v: Length) -> Self {
12774 Self::Length(v)
12775 }
12776}
12777
12778impl From<Percentage> for PaddingInlineStart {
12779 fn from(v: Percentage) -> Self {
12780 Self::Percentage(v)
12781 }
12782}
12783
12784#[derive(Debug, Clone, PartialEq)]
12786#[non_exhaustive]
12787pub enum PaddingLeft {
12788 Length(Length),
12790 Percentage(Percentage),
12792}
12793
12794impl fmt::Display for PaddingLeft {
12795 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12796 match self {
12797 Self::Length(v) => v.fmt(f),
12798 Self::Percentage(v) => v.fmt(f),
12799 }
12800 }
12801}
12802
12803impl From<Length> for PaddingLeft {
12804 fn from(v: Length) -> Self {
12805 Self::Length(v)
12806 }
12807}
12808
12809impl From<Percentage> for PaddingLeft {
12810 fn from(v: Percentage) -> Self {
12811 Self::Percentage(v)
12812 }
12813}
12814
12815#[derive(Debug, Clone, PartialEq)]
12817#[non_exhaustive]
12818pub enum PaddingRight {
12819 Length(Length),
12821 Percentage(Percentage),
12823}
12824
12825impl fmt::Display for PaddingRight {
12826 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12827 match self {
12828 Self::Length(v) => v.fmt(f),
12829 Self::Percentage(v) => v.fmt(f),
12830 }
12831 }
12832}
12833
12834impl From<Length> for PaddingRight {
12835 fn from(v: Length) -> Self {
12836 Self::Length(v)
12837 }
12838}
12839
12840impl From<Percentage> for PaddingRight {
12841 fn from(v: Percentage) -> Self {
12842 Self::Percentage(v)
12843 }
12844}
12845
12846#[derive(Debug, Clone, PartialEq)]
12848#[non_exhaustive]
12849pub enum PaddingTop {
12850 Length(Length),
12852 Percentage(Percentage),
12854}
12855
12856impl fmt::Display for PaddingTop {
12857 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12858 match self {
12859 Self::Length(v) => v.fmt(f),
12860 Self::Percentage(v) => v.fmt(f),
12861 }
12862 }
12863}
12864
12865impl From<Length> for PaddingTop {
12866 fn from(v: Length) -> Self {
12867 Self::Length(v)
12868 }
12869}
12870
12871impl From<Percentage> for PaddingTop {
12872 fn from(v: Percentage) -> Self {
12873 Self::Percentage(v)
12874 }
12875}
12876
12877#[derive(Debug, Clone, PartialEq)]
12879#[non_exhaustive]
12880pub enum Page {
12881 Auto,
12883 Raw(Raw),
12885}
12886
12887impl fmt::Display for Page {
12888 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12889 match self {
12890 Self::Auto => f.write_str("auto"),
12891 Self::Raw(v) => v.fmt(f),
12892 }
12893 }
12894}
12895
12896impl From<Raw> for Page {
12897 fn from(v: Raw) -> Self {
12898 Self::Raw(v)
12899 }
12900}
12901
12902#[derive(Debug, Clone, PartialEq)]
12904#[non_exhaustive]
12905pub enum PaintOrder {
12906 Fill,
12908 Markers,
12910 Normal,
12912 Stroke,
12914 Raw(Raw),
12916}
12917
12918impl fmt::Display for PaintOrder {
12919 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12920 match self {
12921 Self::Fill => f.write_str("fill"),
12922 Self::Markers => f.write_str("markers"),
12923 Self::Normal => f.write_str("normal"),
12924 Self::Stroke => f.write_str("stroke"),
12925 Self::Raw(v) => v.fmt(f),
12926 }
12927 }
12928}
12929
12930impl From<Raw> for PaintOrder {
12931 fn from(v: Raw) -> Self {
12932 Self::Raw(v)
12933 }
12934}
12935
12936#[derive(Debug, Clone, PartialEq)]
12938#[non_exhaustive]
12939pub enum PathLength {
12940 None,
12942 Raw(Raw),
12944}
12945
12946impl fmt::Display for PathLength {
12947 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12948 match self {
12949 Self::None => f.write_str("none"),
12950 Self::Raw(v) => v.fmt(f),
12951 }
12952 }
12953}
12954
12955impl From<Raw> for PathLength {
12956 fn from(v: Raw) -> Self {
12957 Self::Raw(v)
12958 }
12959}
12960
12961#[derive(Debug, Clone, PartialEq)]
12963#[non_exhaustive]
12964pub enum Perspective {
12965 None,
12967 Length(Length),
12969}
12970
12971impl fmt::Display for Perspective {
12972 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
12973 match self {
12974 Self::None => f.write_str("none"),
12975 Self::Length(v) => v.fmt(f),
12976 }
12977 }
12978}
12979
12980impl From<Length> for Perspective {
12981 fn from(v: Length) -> Self {
12982 Self::Length(v)
12983 }
12984}
12985
12986#[derive(Debug, Clone, PartialEq)]
12988#[non_exhaustive]
12989pub enum PerspectiveOrigin {
12990 Bottom,
12992 Center,
12994 Left,
12996 Right,
12998 Top,
13000 Length(Length),
13002 Percentage(Percentage),
13004 Raw(Raw),
13006}
13007
13008impl fmt::Display for PerspectiveOrigin {
13009 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13010 match self {
13011 Self::Bottom => f.write_str("bottom"),
13012 Self::Center => f.write_str("center"),
13013 Self::Left => f.write_str("left"),
13014 Self::Right => f.write_str("right"),
13015 Self::Top => f.write_str("top"),
13016 Self::Length(v) => v.fmt(f),
13017 Self::Percentage(v) => v.fmt(f),
13018 Self::Raw(v) => v.fmt(f),
13019 }
13020 }
13021}
13022
13023impl From<Length> for PerspectiveOrigin {
13024 fn from(v: Length) -> Self {
13025 Self::Length(v)
13026 }
13027}
13028
13029impl From<Percentage> for PerspectiveOrigin {
13030 fn from(v: Percentage) -> Self {
13031 Self::Percentage(v)
13032 }
13033}
13034
13035impl From<Raw> for PerspectiveOrigin {
13036 fn from(v: Raw) -> Self {
13037 Self::Raw(v)
13038 }
13039}
13040
13041#[derive(Debug, Clone, PartialEq)]
13043#[non_exhaustive]
13044pub enum PlaceContent {
13045 Baseline,
13047 Center,
13049 End,
13051 FlexEnd,
13053 FlexStart,
13055 Normal,
13057 SpaceAround,
13059 SpaceBetween,
13061 SpaceEvenly,
13063 Start,
13065 Stretch,
13067 Raw(Raw),
13069}
13070
13071impl fmt::Display for PlaceContent {
13072 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13073 match self {
13074 Self::Baseline => f.write_str("baseline"),
13075 Self::Center => f.write_str("center"),
13076 Self::End => f.write_str("end"),
13077 Self::FlexEnd => f.write_str("flex-end"),
13078 Self::FlexStart => f.write_str("flex-start"),
13079 Self::Normal => f.write_str("normal"),
13080 Self::SpaceAround => f.write_str("space-around"),
13081 Self::SpaceBetween => f.write_str("space-between"),
13082 Self::SpaceEvenly => f.write_str("space-evenly"),
13083 Self::Start => f.write_str("start"),
13084 Self::Stretch => f.write_str("stretch"),
13085 Self::Raw(v) => v.fmt(f),
13086 }
13087 }
13088}
13089
13090impl From<Raw> for PlaceContent {
13091 fn from(v: Raw) -> Self {
13092 Self::Raw(v)
13093 }
13094}
13095
13096#[derive(Debug, Clone, PartialEq)]
13098#[non_exhaustive]
13099pub enum PlaceItems {
13100 AnchorCenter,
13102 Baseline,
13104 Center,
13106 End,
13108 FlexEnd,
13110 FlexStart,
13112 Normal,
13114 SelfEnd,
13116 SelfStart,
13118 Start,
13120 Stretch,
13122 Raw(Raw),
13124}
13125
13126impl fmt::Display for PlaceItems {
13127 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13128 match self {
13129 Self::AnchorCenter => f.write_str("anchor-center"),
13130 Self::Baseline => f.write_str("baseline"),
13131 Self::Center => f.write_str("center"),
13132 Self::End => f.write_str("end"),
13133 Self::FlexEnd => f.write_str("flex-end"),
13134 Self::FlexStart => f.write_str("flex-start"),
13135 Self::Normal => f.write_str("normal"),
13136 Self::SelfEnd => f.write_str("self-end"),
13137 Self::SelfStart => f.write_str("self-start"),
13138 Self::Start => f.write_str("start"),
13139 Self::Stretch => f.write_str("stretch"),
13140 Self::Raw(v) => v.fmt(f),
13141 }
13142 }
13143}
13144
13145impl From<Raw> for PlaceItems {
13146 fn from(v: Raw) -> Self {
13147 Self::Raw(v)
13148 }
13149}
13150
13151#[derive(Debug, Clone, PartialEq)]
13153#[non_exhaustive]
13154pub enum PlaceSelf {
13155 AnchorCenter,
13157 Auto,
13159 Baseline,
13161 Center,
13163 End,
13165 FlexEnd,
13167 FlexStart,
13169 Normal,
13171 SelfEnd,
13173 SelfStart,
13175 Start,
13177 Stretch,
13179 Raw(Raw),
13181}
13182
13183impl fmt::Display for PlaceSelf {
13184 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13185 match self {
13186 Self::AnchorCenter => f.write_str("anchor-center"),
13187 Self::Auto => f.write_str("auto"),
13188 Self::Baseline => f.write_str("baseline"),
13189 Self::Center => f.write_str("center"),
13190 Self::End => f.write_str("end"),
13191 Self::FlexEnd => f.write_str("flex-end"),
13192 Self::FlexStart => f.write_str("flex-start"),
13193 Self::Normal => f.write_str("normal"),
13194 Self::SelfEnd => f.write_str("self-end"),
13195 Self::SelfStart => f.write_str("self-start"),
13196 Self::Start => f.write_str("start"),
13197 Self::Stretch => f.write_str("stretch"),
13198 Self::Raw(v) => v.fmt(f),
13199 }
13200 }
13201}
13202
13203impl From<Raw> for PlaceSelf {
13204 fn from(v: Raw) -> Self {
13205 Self::Raw(v)
13206 }
13207}
13208
13209#[derive(Debug, Clone, PartialEq)]
13211#[non_exhaustive]
13212pub enum PointerEvents {
13213 All,
13215 Auto,
13217 Fill,
13219 Inherit,
13221 None,
13223 Painted,
13225 Stroke,
13227 Visible,
13229 VisibleFill,
13231 VisiblePainted,
13233 VisibleStroke,
13235}
13236
13237impl fmt::Display for PointerEvents {
13238 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13239 match self {
13240 Self::All => f.write_str("all"),
13241 Self::Auto => f.write_str("auto"),
13242 Self::Fill => f.write_str("fill"),
13243 Self::Inherit => f.write_str("inherit"),
13244 Self::None => f.write_str("none"),
13245 Self::Painted => f.write_str("painted"),
13246 Self::Stroke => f.write_str("stroke"),
13247 Self::Visible => f.write_str("visible"),
13248 Self::VisibleFill => f.write_str("visibleFill"),
13249 Self::VisiblePainted => f.write_str("visiblePainted"),
13250 Self::VisibleStroke => f.write_str("visibleStroke"),
13251 }
13252 }
13253}
13254
13255#[derive(Debug, Clone, PartialEq)]
13257#[non_exhaustive]
13258pub enum Position {
13259 Absolute,
13261 Fixed,
13263 Relative,
13265 Static,
13267 Sticky,
13269}
13270
13271impl fmt::Display for Position {
13272 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13273 match self {
13274 Self::Absolute => f.write_str("absolute"),
13275 Self::Fixed => f.write_str("fixed"),
13276 Self::Relative => f.write_str("relative"),
13277 Self::Static => f.write_str("static"),
13278 Self::Sticky => f.write_str("sticky"),
13279 }
13280 }
13281}
13282
13283#[derive(Debug, Clone, PartialEq)]
13285#[non_exhaustive]
13286pub enum PositionAnchor {
13287 Auto,
13289 MatchParent,
13291 None,
13293 Normal,
13295 Raw(Raw),
13297}
13298
13299impl fmt::Display for PositionAnchor {
13300 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13301 match self {
13302 Self::Auto => f.write_str("auto"),
13303 Self::MatchParent => f.write_str("match-parent"),
13304 Self::None => f.write_str("none"),
13305 Self::Normal => f.write_str("normal"),
13306 Self::Raw(v) => v.fmt(f),
13307 }
13308 }
13309}
13310
13311impl From<Raw> for PositionAnchor {
13312 fn from(v: Raw) -> Self {
13313 Self::Raw(v)
13314 }
13315}
13316
13317#[derive(Debug, Clone, PartialEq)]
13319#[non_exhaustive]
13320pub enum PositionArea {
13321 None,
13323 Raw(Raw),
13325}
13326
13327impl fmt::Display for PositionArea {
13328 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13329 match self {
13330 Self::None => f.write_str("none"),
13331 Self::Raw(v) => v.fmt(f),
13332 }
13333 }
13334}
13335
13336impl From<Raw> for PositionArea {
13337 fn from(v: Raw) -> Self {
13338 Self::Raw(v)
13339 }
13340}
13341
13342#[derive(Debug, Clone, PartialEq)]
13344#[non_exhaustive]
13345pub enum PositionTryFallbacks {
13346 FlipBlock,
13348 FlipInline,
13350 FlipStart,
13352 None,
13354 Raw(Raw),
13356}
13357
13358impl fmt::Display for PositionTryFallbacks {
13359 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13360 match self {
13361 Self::FlipBlock => f.write_str("flip-block"),
13362 Self::FlipInline => f.write_str("flip-inline"),
13363 Self::FlipStart => f.write_str("flip-start"),
13364 Self::None => f.write_str("none"),
13365 Self::Raw(v) => v.fmt(f),
13366 }
13367 }
13368}
13369
13370impl From<Raw> for PositionTryFallbacks {
13371 fn from(v: Raw) -> Self {
13372 Self::Raw(v)
13373 }
13374}
13375
13376#[derive(Debug, Clone, PartialEq)]
13378#[non_exhaustive]
13379pub enum PrintColorAdjust {
13380 Economy,
13382 Exact,
13384}
13385
13386impl fmt::Display for PrintColorAdjust {
13387 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13388 match self {
13389 Self::Economy => f.write_str("economy"),
13390 Self::Exact => f.write_str("exact"),
13391 }
13392 }
13393}
13394
13395#[derive(Debug, Clone, PartialEq)]
13397#[non_exhaustive]
13398pub enum Quotes {
13399 Auto,
13401 None,
13403 Raw(Raw),
13405}
13406
13407impl fmt::Display for Quotes {
13408 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13409 match self {
13410 Self::Auto => f.write_str("auto"),
13411 Self::None => f.write_str("none"),
13412 Self::Raw(v) => v.fmt(f),
13413 }
13414 }
13415}
13416
13417impl From<Raw> for Quotes {
13418 fn from(v: Raw) -> Self {
13419 Self::Raw(v)
13420 }
13421}
13422
13423#[derive(Debug, Clone, PartialEq)]
13425#[non_exhaustive]
13426pub enum R {
13427 Length(Length),
13429 Percentage(Percentage),
13431}
13432
13433impl fmt::Display for R {
13434 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13435 match self {
13436 Self::Length(v) => v.fmt(f),
13437 Self::Percentage(v) => v.fmt(f),
13438 }
13439 }
13440}
13441
13442impl From<Length> for R {
13443 fn from(v: Length) -> Self {
13444 Self::Length(v)
13445 }
13446}
13447
13448impl From<Percentage> for R {
13449 fn from(v: Percentage) -> Self {
13450 Self::Percentage(v)
13451 }
13452}
13453
13454#[derive(Debug, Clone, PartialEq)]
13456#[non_exhaustive]
13457pub enum ReadingFlow {
13458 FlexFlow,
13460 FlexVisual,
13462 GridColumns,
13464 GridOrder,
13466 GridRows,
13468 Normal,
13470 SourceOrder,
13472}
13473
13474impl fmt::Display for ReadingFlow {
13475 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13476 match self {
13477 Self::FlexFlow => f.write_str("flex-flow"),
13478 Self::FlexVisual => f.write_str("flex-visual"),
13479 Self::GridColumns => f.write_str("grid-columns"),
13480 Self::GridOrder => f.write_str("grid-order"),
13481 Self::GridRows => f.write_str("grid-rows"),
13482 Self::Normal => f.write_str("normal"),
13483 Self::SourceOrder => f.write_str("source-order"),
13484 }
13485 }
13486}
13487
13488#[derive(Debug, Clone, PartialEq)]
13490#[non_exhaustive]
13491pub enum Resize {
13492 Block,
13494 Both,
13496 Horizontal,
13498 Inline,
13500 None,
13502 Vertical,
13504}
13505
13506impl fmt::Display for Resize {
13507 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13508 match self {
13509 Self::Block => f.write_str("block"),
13510 Self::Both => f.write_str("both"),
13511 Self::Horizontal => f.write_str("horizontal"),
13512 Self::Inline => f.write_str("inline"),
13513 Self::None => f.write_str("none"),
13514 Self::Vertical => f.write_str("vertical"),
13515 }
13516 }
13517}
13518
13519#[derive(Debug, Clone, PartialEq)]
13521#[non_exhaustive]
13522pub enum Right {
13523 Auto,
13525 Length(Length),
13527 Percentage(Percentage),
13529 Raw(Raw),
13531}
13532
13533impl fmt::Display for Right {
13534 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13535 match self {
13536 Self::Auto => f.write_str("auto"),
13537 Self::Length(v) => v.fmt(f),
13538 Self::Percentage(v) => v.fmt(f),
13539 Self::Raw(v) => v.fmt(f),
13540 }
13541 }
13542}
13543
13544impl From<Length> for Right {
13545 fn from(v: Length) -> Self {
13546 Self::Length(v)
13547 }
13548}
13549
13550impl From<Percentage> for Right {
13551 fn from(v: Percentage) -> Self {
13552 Self::Percentage(v)
13553 }
13554}
13555
13556impl From<Raw> for Right {
13557 fn from(v: Raw) -> Self {
13558 Self::Raw(v)
13559 }
13560}
13561
13562#[derive(Debug, Clone, PartialEq)]
13564#[non_exhaustive]
13565pub enum Rotate {
13566 None,
13568 Angle(Angle),
13570 Raw(Raw),
13572}
13573
13574impl fmt::Display for Rotate {
13575 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13576 match self {
13577 Self::None => f.write_str("none"),
13578 Self::Angle(v) => v.fmt(f),
13579 Self::Raw(v) => v.fmt(f),
13580 }
13581 }
13582}
13583
13584impl From<Angle> for Rotate {
13585 fn from(v: Angle) -> Self {
13586 Self::Angle(v)
13587 }
13588}
13589
13590impl From<Raw> for Rotate {
13591 fn from(v: Raw) -> Self {
13592 Self::Raw(v)
13593 }
13594}
13595
13596#[derive(Debug, Clone, PartialEq)]
13598#[non_exhaustive]
13599pub enum RowGap {
13600 Normal,
13602 Length(Length),
13604 Percentage(Percentage),
13606}
13607
13608impl fmt::Display for RowGap {
13609 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13610 match self {
13611 Self::Normal => f.write_str("normal"),
13612 Self::Length(v) => v.fmt(f),
13613 Self::Percentage(v) => v.fmt(f),
13614 }
13615 }
13616}
13617
13618impl From<Length> for RowGap {
13619 fn from(v: Length) -> Self {
13620 Self::Length(v)
13621 }
13622}
13623
13624impl From<Percentage> for RowGap {
13625 fn from(v: Percentage) -> Self {
13626 Self::Percentage(v)
13627 }
13628}
13629
13630#[derive(Debug, Clone, PartialEq)]
13632#[non_exhaustive]
13633pub enum RubyAlign {
13634 Center,
13636 SpaceAround,
13638 SpaceBetween,
13640 Start,
13642}
13643
13644impl fmt::Display for RubyAlign {
13645 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13646 match self {
13647 Self::Center => f.write_str("center"),
13648 Self::SpaceAround => f.write_str("space-around"),
13649 Self::SpaceBetween => f.write_str("space-between"),
13650 Self::Start => f.write_str("start"),
13651 }
13652 }
13653}
13654
13655#[derive(Debug, Clone, PartialEq)]
13657#[non_exhaustive]
13658pub enum RubyOverhang {
13659 Auto,
13661 None,
13663}
13664
13665impl fmt::Display for RubyOverhang {
13666 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13667 match self {
13668 Self::Auto => f.write_str("auto"),
13669 Self::None => f.write_str("none"),
13670 }
13671 }
13672}
13673
13674#[derive(Debug, Clone, PartialEq)]
13676#[non_exhaustive]
13677pub enum RubyPosition {
13678 Alternate,
13680 InterCharacter,
13682 Over,
13684 Under,
13686 Raw(Raw),
13688}
13689
13690impl fmt::Display for RubyPosition {
13691 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13692 match self {
13693 Self::Alternate => f.write_str("alternate"),
13694 Self::InterCharacter => f.write_str("inter-character"),
13695 Self::Over => f.write_str("over"),
13696 Self::Under => f.write_str("under"),
13697 Self::Raw(v) => v.fmt(f),
13698 }
13699 }
13700}
13701
13702impl From<Raw> for RubyPosition {
13703 fn from(v: Raw) -> Self {
13704 Self::Raw(v)
13705 }
13706}
13707
13708#[derive(Debug, Clone, PartialEq)]
13710#[non_exhaustive]
13711pub enum Rx {
13712 Auto,
13714 Length(Length),
13716 Percentage(Percentage),
13718}
13719
13720impl fmt::Display for Rx {
13721 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13722 match self {
13723 Self::Auto => f.write_str("auto"),
13724 Self::Length(v) => v.fmt(f),
13725 Self::Percentage(v) => v.fmt(f),
13726 }
13727 }
13728}
13729
13730impl From<Length> for Rx {
13731 fn from(v: Length) -> Self {
13732 Self::Length(v)
13733 }
13734}
13735
13736impl From<Percentage> for Rx {
13737 fn from(v: Percentage) -> Self {
13738 Self::Percentage(v)
13739 }
13740}
13741
13742#[derive(Debug, Clone, PartialEq)]
13744#[non_exhaustive]
13745pub enum Ry {
13746 Auto,
13748 Length(Length),
13750 Percentage(Percentage),
13752}
13753
13754impl fmt::Display for Ry {
13755 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13756 match self {
13757 Self::Auto => f.write_str("auto"),
13758 Self::Length(v) => v.fmt(f),
13759 Self::Percentage(v) => v.fmt(f),
13760 }
13761 }
13762}
13763
13764impl From<Length> for Ry {
13765 fn from(v: Length) -> Self {
13766 Self::Length(v)
13767 }
13768}
13769
13770impl From<Percentage> for Ry {
13771 fn from(v: Percentage) -> Self {
13772 Self::Percentage(v)
13773 }
13774}
13775
13776#[derive(Debug, Clone, PartialEq)]
13778#[non_exhaustive]
13779pub enum Scale {
13780 None,
13782 Percentage(Percentage),
13784 Number(f64),
13786 Raw(Raw),
13788}
13789
13790impl fmt::Display for Scale {
13791 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13792 match self {
13793 Self::None => f.write_str("none"),
13794 Self::Percentage(v) => v.fmt(f),
13795 Self::Number(v) => v.fmt(f),
13796 Self::Raw(v) => v.fmt(f),
13797 }
13798 }
13799}
13800
13801impl From<Percentage> for Scale {
13802 fn from(v: Percentage) -> Self {
13803 Self::Percentage(v)
13804 }
13805}
13806
13807impl From<f64> for Scale {
13808 fn from(v: f64) -> Self {
13809 Self::Number(v)
13810 }
13811}
13812
13813impl From<i32> for Scale {
13814 fn from(v: i32) -> Self {
13815 Self::Number(f64::from(v))
13816 }
13817}
13818
13819impl From<Raw> for Scale {
13820 fn from(v: Raw) -> Self {
13821 Self::Raw(v)
13822 }
13823}
13824
13825#[derive(Debug, Clone, PartialEq)]
13827#[non_exhaustive]
13828pub enum ScrollAxisLock {
13829 Auto,
13831 None,
13833}
13834
13835impl fmt::Display for ScrollAxisLock {
13836 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13837 match self {
13838 Self::Auto => f.write_str("auto"),
13839 Self::None => f.write_str("none"),
13840 }
13841 }
13842}
13843
13844#[derive(Debug, Clone, PartialEq)]
13846#[non_exhaustive]
13847pub enum ScrollBehavior {
13848 Auto,
13850 Smooth,
13852}
13853
13854impl fmt::Display for ScrollBehavior {
13855 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13856 match self {
13857 Self::Auto => f.write_str("auto"),
13858 Self::Smooth => f.write_str("smooth"),
13859 }
13860 }
13861}
13862
13863#[derive(Debug, Clone, PartialEq)]
13865#[non_exhaustive]
13866pub enum ScrollMargin {
13867 Length(Length),
13869 Raw(Raw),
13871}
13872
13873impl fmt::Display for ScrollMargin {
13874 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13875 match self {
13876 Self::Length(v) => v.fmt(f),
13877 Self::Raw(v) => v.fmt(f),
13878 }
13879 }
13880}
13881
13882impl From<Length> for ScrollMargin {
13883 fn from(v: Length) -> Self {
13884 Self::Length(v)
13885 }
13886}
13887
13888impl From<Raw> for ScrollMargin {
13889 fn from(v: Raw) -> Self {
13890 Self::Raw(v)
13891 }
13892}
13893
13894#[derive(Debug, Clone, PartialEq)]
13896#[non_exhaustive]
13897pub enum ScrollMarginBlock {
13898 Length(Length),
13900 Raw(Raw),
13902}
13903
13904impl fmt::Display for ScrollMarginBlock {
13905 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13906 match self {
13907 Self::Length(v) => v.fmt(f),
13908 Self::Raw(v) => v.fmt(f),
13909 }
13910 }
13911}
13912
13913impl From<Length> for ScrollMarginBlock {
13914 fn from(v: Length) -> Self {
13915 Self::Length(v)
13916 }
13917}
13918
13919impl From<Raw> for ScrollMarginBlock {
13920 fn from(v: Raw) -> Self {
13921 Self::Raw(v)
13922 }
13923}
13924
13925#[derive(Debug, Clone, PartialEq)]
13927#[non_exhaustive]
13928pub enum ScrollMarginInline {
13929 Length(Length),
13931 Raw(Raw),
13933}
13934
13935impl fmt::Display for ScrollMarginInline {
13936 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13937 match self {
13938 Self::Length(v) => v.fmt(f),
13939 Self::Raw(v) => v.fmt(f),
13940 }
13941 }
13942}
13943
13944impl From<Length> for ScrollMarginInline {
13945 fn from(v: Length) -> Self {
13946 Self::Length(v)
13947 }
13948}
13949
13950impl From<Raw> for ScrollMarginInline {
13951 fn from(v: Raw) -> Self {
13952 Self::Raw(v)
13953 }
13954}
13955
13956#[derive(Debug, Clone, PartialEq)]
13958#[non_exhaustive]
13959pub enum ScrollMarkerGroup {
13960 After,
13962 Before,
13964 None,
13966}
13967
13968impl fmt::Display for ScrollMarkerGroup {
13969 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13970 match self {
13971 Self::After => f.write_str("after"),
13972 Self::Before => f.write_str("before"),
13973 Self::None => f.write_str("none"),
13974 }
13975 }
13976}
13977
13978#[derive(Debug, Clone, PartialEq)]
13980#[non_exhaustive]
13981pub enum ScrollPadding {
13982 Auto,
13984 Length(Length),
13986 Percentage(Percentage),
13988 Raw(Raw),
13990}
13991
13992impl fmt::Display for ScrollPadding {
13993 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
13994 match self {
13995 Self::Auto => f.write_str("auto"),
13996 Self::Length(v) => v.fmt(f),
13997 Self::Percentage(v) => v.fmt(f),
13998 Self::Raw(v) => v.fmt(f),
13999 }
14000 }
14001}
14002
14003impl From<Length> for ScrollPadding {
14004 fn from(v: Length) -> Self {
14005 Self::Length(v)
14006 }
14007}
14008
14009impl From<Percentage> for ScrollPadding {
14010 fn from(v: Percentage) -> Self {
14011 Self::Percentage(v)
14012 }
14013}
14014
14015impl From<Raw> for ScrollPadding {
14016 fn from(v: Raw) -> Self {
14017 Self::Raw(v)
14018 }
14019}
14020
14021#[derive(Debug, Clone, PartialEq)]
14023#[non_exhaustive]
14024pub enum ScrollPaddingBlock {
14025 Auto,
14027 Length(Length),
14029 Percentage(Percentage),
14031 Raw(Raw),
14033}
14034
14035impl fmt::Display for ScrollPaddingBlock {
14036 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14037 match self {
14038 Self::Auto => f.write_str("auto"),
14039 Self::Length(v) => v.fmt(f),
14040 Self::Percentage(v) => v.fmt(f),
14041 Self::Raw(v) => v.fmt(f),
14042 }
14043 }
14044}
14045
14046impl From<Length> for ScrollPaddingBlock {
14047 fn from(v: Length) -> Self {
14048 Self::Length(v)
14049 }
14050}
14051
14052impl From<Percentage> for ScrollPaddingBlock {
14053 fn from(v: Percentage) -> Self {
14054 Self::Percentage(v)
14055 }
14056}
14057
14058impl From<Raw> for ScrollPaddingBlock {
14059 fn from(v: Raw) -> Self {
14060 Self::Raw(v)
14061 }
14062}
14063
14064#[derive(Debug, Clone, PartialEq)]
14066#[non_exhaustive]
14067pub enum ScrollPaddingBlockEnd {
14068 Auto,
14070 Length(Length),
14072 Percentage(Percentage),
14074}
14075
14076impl fmt::Display for ScrollPaddingBlockEnd {
14077 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14078 match self {
14079 Self::Auto => f.write_str("auto"),
14080 Self::Length(v) => v.fmt(f),
14081 Self::Percentage(v) => v.fmt(f),
14082 }
14083 }
14084}
14085
14086impl From<Length> for ScrollPaddingBlockEnd {
14087 fn from(v: Length) -> Self {
14088 Self::Length(v)
14089 }
14090}
14091
14092impl From<Percentage> for ScrollPaddingBlockEnd {
14093 fn from(v: Percentage) -> Self {
14094 Self::Percentage(v)
14095 }
14096}
14097
14098#[derive(Debug, Clone, PartialEq)]
14100#[non_exhaustive]
14101pub enum ScrollPaddingBlockStart {
14102 Auto,
14104 Length(Length),
14106 Percentage(Percentage),
14108}
14109
14110impl fmt::Display for ScrollPaddingBlockStart {
14111 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14112 match self {
14113 Self::Auto => f.write_str("auto"),
14114 Self::Length(v) => v.fmt(f),
14115 Self::Percentage(v) => v.fmt(f),
14116 }
14117 }
14118}
14119
14120impl From<Length> for ScrollPaddingBlockStart {
14121 fn from(v: Length) -> Self {
14122 Self::Length(v)
14123 }
14124}
14125
14126impl From<Percentage> for ScrollPaddingBlockStart {
14127 fn from(v: Percentage) -> Self {
14128 Self::Percentage(v)
14129 }
14130}
14131
14132#[derive(Debug, Clone, PartialEq)]
14134#[non_exhaustive]
14135pub enum ScrollPaddingBottom {
14136 Auto,
14138 Length(Length),
14140 Percentage(Percentage),
14142}
14143
14144impl fmt::Display for ScrollPaddingBottom {
14145 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14146 match self {
14147 Self::Auto => f.write_str("auto"),
14148 Self::Length(v) => v.fmt(f),
14149 Self::Percentage(v) => v.fmt(f),
14150 }
14151 }
14152}
14153
14154impl From<Length> for ScrollPaddingBottom {
14155 fn from(v: Length) -> Self {
14156 Self::Length(v)
14157 }
14158}
14159
14160impl From<Percentage> for ScrollPaddingBottom {
14161 fn from(v: Percentage) -> Self {
14162 Self::Percentage(v)
14163 }
14164}
14165
14166#[derive(Debug, Clone, PartialEq)]
14168#[non_exhaustive]
14169pub enum ScrollPaddingInline {
14170 Auto,
14172 Length(Length),
14174 Percentage(Percentage),
14176 Raw(Raw),
14178}
14179
14180impl fmt::Display for ScrollPaddingInline {
14181 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14182 match self {
14183 Self::Auto => f.write_str("auto"),
14184 Self::Length(v) => v.fmt(f),
14185 Self::Percentage(v) => v.fmt(f),
14186 Self::Raw(v) => v.fmt(f),
14187 }
14188 }
14189}
14190
14191impl From<Length> for ScrollPaddingInline {
14192 fn from(v: Length) -> Self {
14193 Self::Length(v)
14194 }
14195}
14196
14197impl From<Percentage> for ScrollPaddingInline {
14198 fn from(v: Percentage) -> Self {
14199 Self::Percentage(v)
14200 }
14201}
14202
14203impl From<Raw> for ScrollPaddingInline {
14204 fn from(v: Raw) -> Self {
14205 Self::Raw(v)
14206 }
14207}
14208
14209#[derive(Debug, Clone, PartialEq)]
14211#[non_exhaustive]
14212pub enum ScrollPaddingInlineEnd {
14213 Auto,
14215 Length(Length),
14217 Percentage(Percentage),
14219}
14220
14221impl fmt::Display for ScrollPaddingInlineEnd {
14222 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14223 match self {
14224 Self::Auto => f.write_str("auto"),
14225 Self::Length(v) => v.fmt(f),
14226 Self::Percentage(v) => v.fmt(f),
14227 }
14228 }
14229}
14230
14231impl From<Length> for ScrollPaddingInlineEnd {
14232 fn from(v: Length) -> Self {
14233 Self::Length(v)
14234 }
14235}
14236
14237impl From<Percentage> for ScrollPaddingInlineEnd {
14238 fn from(v: Percentage) -> Self {
14239 Self::Percentage(v)
14240 }
14241}
14242
14243#[derive(Debug, Clone, PartialEq)]
14245#[non_exhaustive]
14246pub enum ScrollPaddingInlineStart {
14247 Auto,
14249 Length(Length),
14251 Percentage(Percentage),
14253}
14254
14255impl fmt::Display for ScrollPaddingInlineStart {
14256 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14257 match self {
14258 Self::Auto => f.write_str("auto"),
14259 Self::Length(v) => v.fmt(f),
14260 Self::Percentage(v) => v.fmt(f),
14261 }
14262 }
14263}
14264
14265impl From<Length> for ScrollPaddingInlineStart {
14266 fn from(v: Length) -> Self {
14267 Self::Length(v)
14268 }
14269}
14270
14271impl From<Percentage> for ScrollPaddingInlineStart {
14272 fn from(v: Percentage) -> Self {
14273 Self::Percentage(v)
14274 }
14275}
14276
14277#[derive(Debug, Clone, PartialEq)]
14279#[non_exhaustive]
14280pub enum ScrollPaddingLeft {
14281 Auto,
14283 Length(Length),
14285 Percentage(Percentage),
14287}
14288
14289impl fmt::Display for ScrollPaddingLeft {
14290 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14291 match self {
14292 Self::Auto => f.write_str("auto"),
14293 Self::Length(v) => v.fmt(f),
14294 Self::Percentage(v) => v.fmt(f),
14295 }
14296 }
14297}
14298
14299impl From<Length> for ScrollPaddingLeft {
14300 fn from(v: Length) -> Self {
14301 Self::Length(v)
14302 }
14303}
14304
14305impl From<Percentage> for ScrollPaddingLeft {
14306 fn from(v: Percentage) -> Self {
14307 Self::Percentage(v)
14308 }
14309}
14310
14311#[derive(Debug, Clone, PartialEq)]
14313#[non_exhaustive]
14314pub enum ScrollPaddingRight {
14315 Auto,
14317 Length(Length),
14319 Percentage(Percentage),
14321}
14322
14323impl fmt::Display for ScrollPaddingRight {
14324 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14325 match self {
14326 Self::Auto => f.write_str("auto"),
14327 Self::Length(v) => v.fmt(f),
14328 Self::Percentage(v) => v.fmt(f),
14329 }
14330 }
14331}
14332
14333impl From<Length> for ScrollPaddingRight {
14334 fn from(v: Length) -> Self {
14335 Self::Length(v)
14336 }
14337}
14338
14339impl From<Percentage> for ScrollPaddingRight {
14340 fn from(v: Percentage) -> Self {
14341 Self::Percentage(v)
14342 }
14343}
14344
14345#[derive(Debug, Clone, PartialEq)]
14347#[non_exhaustive]
14348pub enum ScrollPaddingTop {
14349 Auto,
14351 Length(Length),
14353 Percentage(Percentage),
14355}
14356
14357impl fmt::Display for ScrollPaddingTop {
14358 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14359 match self {
14360 Self::Auto => f.write_str("auto"),
14361 Self::Length(v) => v.fmt(f),
14362 Self::Percentage(v) => v.fmt(f),
14363 }
14364 }
14365}
14366
14367impl From<Length> for ScrollPaddingTop {
14368 fn from(v: Length) -> Self {
14369 Self::Length(v)
14370 }
14371}
14372
14373impl From<Percentage> for ScrollPaddingTop {
14374 fn from(v: Percentage) -> Self {
14375 Self::Percentage(v)
14376 }
14377}
14378
14379#[derive(Debug, Clone, PartialEq)]
14381#[non_exhaustive]
14382pub enum ScrollSnapAlign {
14383 Center,
14385 End,
14387 None,
14389 Start,
14391 Raw(Raw),
14393}
14394
14395impl fmt::Display for ScrollSnapAlign {
14396 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14397 match self {
14398 Self::Center => f.write_str("center"),
14399 Self::End => f.write_str("end"),
14400 Self::None => f.write_str("none"),
14401 Self::Start => f.write_str("start"),
14402 Self::Raw(v) => v.fmt(f),
14403 }
14404 }
14405}
14406
14407impl From<Raw> for ScrollSnapAlign {
14408 fn from(v: Raw) -> Self {
14409 Self::Raw(v)
14410 }
14411}
14412
14413#[derive(Debug, Clone, PartialEq)]
14415#[non_exhaustive]
14416pub enum ScrollSnapStop {
14417 Always,
14419 Normal,
14421}
14422
14423impl fmt::Display for ScrollSnapStop {
14424 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14425 match self {
14426 Self::Always => f.write_str("always"),
14427 Self::Normal => f.write_str("normal"),
14428 }
14429 }
14430}
14431
14432#[derive(Debug, Clone, PartialEq)]
14434#[non_exhaustive]
14435pub enum ScrollSnapType {
14436 Block,
14438 Both,
14440 Inline,
14442 None,
14444 X,
14446 Y,
14448 Raw(Raw),
14450}
14451
14452impl fmt::Display for ScrollSnapType {
14453 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14454 match self {
14455 Self::Block => f.write_str("block"),
14456 Self::Both => f.write_str("both"),
14457 Self::Inline => f.write_str("inline"),
14458 Self::None => f.write_str("none"),
14459 Self::X => f.write_str("x"),
14460 Self::Y => f.write_str("y"),
14461 Self::Raw(v) => v.fmt(f),
14462 }
14463 }
14464}
14465
14466impl From<Raw> for ScrollSnapType {
14467 fn from(v: Raw) -> Self {
14468 Self::Raw(v)
14469 }
14470}
14471
14472#[derive(Debug, Clone, PartialEq)]
14474#[non_exhaustive]
14475pub enum ScrollTargetGroup {
14476 Auto,
14478 None,
14480}
14481
14482impl fmt::Display for ScrollTargetGroup {
14483 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14484 match self {
14485 Self::Auto => f.write_str("auto"),
14486 Self::None => f.write_str("none"),
14487 }
14488 }
14489}
14490
14491#[derive(Debug, Clone, PartialEq)]
14493#[non_exhaustive]
14494pub enum ScrollbarColor {
14495 Auto,
14497 Color(Color),
14499 Raw(Raw),
14501}
14502
14503impl fmt::Display for ScrollbarColor {
14504 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14505 match self {
14506 Self::Auto => f.write_str("auto"),
14507 Self::Color(v) => v.fmt(f),
14508 Self::Raw(v) => v.fmt(f),
14509 }
14510 }
14511}
14512
14513impl From<Color> for ScrollbarColor {
14514 fn from(v: Color) -> Self {
14515 Self::Color(v)
14516 }
14517}
14518
14519impl From<Raw> for ScrollbarColor {
14520 fn from(v: Raw) -> Self {
14521 Self::Raw(v)
14522 }
14523}
14524
14525#[derive(Debug, Clone, PartialEq)]
14527#[non_exhaustive]
14528pub enum ScrollbarGutter {
14529 Auto,
14531 Raw(Raw),
14533}
14534
14535impl fmt::Display for ScrollbarGutter {
14536 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14537 match self {
14538 Self::Auto => f.write_str("auto"),
14539 Self::Raw(v) => v.fmt(f),
14540 }
14541 }
14542}
14543
14544impl From<Raw> for ScrollbarGutter {
14545 fn from(v: Raw) -> Self {
14546 Self::Raw(v)
14547 }
14548}
14549
14550#[derive(Debug, Clone, PartialEq)]
14552#[non_exhaustive]
14553pub enum ScrollbarWidth {
14554 Auto,
14556 None,
14558 Thin,
14560}
14561
14562impl fmt::Display for ScrollbarWidth {
14563 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14564 match self {
14565 Self::Auto => f.write_str("auto"),
14566 Self::None => f.write_str("none"),
14567 Self::Thin => f.write_str("thin"),
14568 }
14569 }
14570}
14571
14572#[derive(Debug, Clone, PartialEq)]
14574#[non_exhaustive]
14575pub enum ShapeImageThreshold {
14576 Percentage(Percentage),
14578 Number(f64),
14580}
14581
14582impl fmt::Display for ShapeImageThreshold {
14583 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14584 match self {
14585 Self::Percentage(v) => v.fmt(f),
14586 Self::Number(v) => v.fmt(f),
14587 }
14588 }
14589}
14590
14591impl From<Percentage> for ShapeImageThreshold {
14592 fn from(v: Percentage) -> Self {
14593 Self::Percentage(v)
14594 }
14595}
14596
14597impl From<f64> for ShapeImageThreshold {
14598 fn from(v: f64) -> Self {
14599 Self::Number(v)
14600 }
14601}
14602
14603impl From<i32> for ShapeImageThreshold {
14604 fn from(v: i32) -> Self {
14605 Self::Number(f64::from(v))
14606 }
14607}
14608
14609#[derive(Debug, Clone, PartialEq)]
14611#[non_exhaustive]
14612pub enum ShapeMargin {
14613 Length(Length),
14615 Percentage(Percentage),
14617}
14618
14619impl fmt::Display for ShapeMargin {
14620 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14621 match self {
14622 Self::Length(v) => v.fmt(f),
14623 Self::Percentage(v) => v.fmt(f),
14624 }
14625 }
14626}
14627
14628impl From<Length> for ShapeMargin {
14629 fn from(v: Length) -> Self {
14630 Self::Length(v)
14631 }
14632}
14633
14634impl From<Percentage> for ShapeMargin {
14635 fn from(v: Percentage) -> Self {
14636 Self::Percentage(v)
14637 }
14638}
14639
14640#[derive(Debug, Clone, PartialEq)]
14642#[non_exhaustive]
14643pub enum ShapeOutside {
14644 BorderBox,
14646 ContentBox,
14648 MarginBox,
14650 None,
14652 PaddingBox,
14654 Url(Url),
14656 Raw(Raw),
14658}
14659
14660impl fmt::Display for ShapeOutside {
14661 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14662 match self {
14663 Self::BorderBox => f.write_str("border-box"),
14664 Self::ContentBox => f.write_str("content-box"),
14665 Self::MarginBox => f.write_str("margin-box"),
14666 Self::None => f.write_str("none"),
14667 Self::PaddingBox => f.write_str("padding-box"),
14668 Self::Url(v) => v.fmt(f),
14669 Self::Raw(v) => v.fmt(f),
14670 }
14671 }
14672}
14673
14674impl From<Url> for ShapeOutside {
14675 fn from(v: Url) -> Self {
14676 Self::Url(v)
14677 }
14678}
14679
14680impl From<Raw> for ShapeOutside {
14681 fn from(v: Raw) -> Self {
14682 Self::Raw(v)
14683 }
14684}
14685
14686#[derive(Debug, Clone, PartialEq)]
14688#[non_exhaustive]
14689pub enum ShapeRendering {
14690 Auto,
14692 CrispEdges,
14694 GeometricPrecision,
14696 OptimizeSpeed,
14698}
14699
14700impl fmt::Display for ShapeRendering {
14701 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14702 match self {
14703 Self::Auto => f.write_str("auto"),
14704 Self::CrispEdges => f.write_str("crispEdges"),
14705 Self::GeometricPrecision => f.write_str("geometricPrecision"),
14706 Self::OptimizeSpeed => f.write_str("optimizeSpeed"),
14707 }
14708 }
14709}
14710
14711#[derive(Debug, Clone, PartialEq)]
14713#[non_exhaustive]
14714pub enum StopOpacity {
14715 Percentage(Percentage),
14717 Number(f64),
14719}
14720
14721impl fmt::Display for StopOpacity {
14722 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14723 match self {
14724 Self::Percentage(v) => v.fmt(f),
14725 Self::Number(v) => v.fmt(f),
14726 }
14727 }
14728}
14729
14730impl From<Percentage> for StopOpacity {
14731 fn from(v: Percentage) -> Self {
14732 Self::Percentage(v)
14733 }
14734}
14735
14736impl From<f64> for StopOpacity {
14737 fn from(v: f64) -> Self {
14738 Self::Number(v)
14739 }
14740}
14741
14742impl From<i32> for StopOpacity {
14743 fn from(v: i32) -> Self {
14744 Self::Number(f64::from(v))
14745 }
14746}
14747
14748#[derive(Debug, Clone, PartialEq)]
14750#[non_exhaustive]
14751pub enum Stroke {
14752 ContextFill,
14754 ContextStroke,
14756 None,
14758 Color(Color),
14760 Url(Url),
14762 Raw(Raw),
14764}
14765
14766impl fmt::Display for Stroke {
14767 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14768 match self {
14769 Self::ContextFill => f.write_str("context-fill"),
14770 Self::ContextStroke => f.write_str("context-stroke"),
14771 Self::None => f.write_str("none"),
14772 Self::Color(v) => v.fmt(f),
14773 Self::Url(v) => v.fmt(f),
14774 Self::Raw(v) => v.fmt(f),
14775 }
14776 }
14777}
14778
14779impl From<Color> for Stroke {
14780 fn from(v: Color) -> Self {
14781 Self::Color(v)
14782 }
14783}
14784
14785impl From<Url> for Stroke {
14786 fn from(v: Url) -> Self {
14787 Self::Url(v)
14788 }
14789}
14790
14791impl From<Raw> for Stroke {
14792 fn from(v: Raw) -> Self {
14793 Self::Raw(v)
14794 }
14795}
14796
14797#[derive(Debug, Clone, PartialEq)]
14799#[non_exhaustive]
14800pub enum StrokeDasharray {
14801 None,
14803 Length(Length),
14805 Percentage(Percentage),
14807 Number(f64),
14809 Raw(Raw),
14811}
14812
14813impl fmt::Display for StrokeDasharray {
14814 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14815 match self {
14816 Self::None => f.write_str("none"),
14817 Self::Length(v) => v.fmt(f),
14818 Self::Percentage(v) => v.fmt(f),
14819 Self::Number(v) => v.fmt(f),
14820 Self::Raw(v) => v.fmt(f),
14821 }
14822 }
14823}
14824
14825impl From<Length> for StrokeDasharray {
14826 fn from(v: Length) -> Self {
14827 Self::Length(v)
14828 }
14829}
14830
14831impl From<Percentage> for StrokeDasharray {
14832 fn from(v: Percentage) -> Self {
14833 Self::Percentage(v)
14834 }
14835}
14836
14837impl From<f64> for StrokeDasharray {
14838 fn from(v: f64) -> Self {
14839 Self::Number(v)
14840 }
14841}
14842
14843impl From<i32> for StrokeDasharray {
14844 fn from(v: i32) -> Self {
14845 Self::Number(f64::from(v))
14846 }
14847}
14848
14849impl From<Raw> for StrokeDasharray {
14850 fn from(v: Raw) -> Self {
14851 Self::Raw(v)
14852 }
14853}
14854
14855#[derive(Debug, Clone, PartialEq)]
14857#[non_exhaustive]
14858pub enum StrokeDashoffset {
14859 Length(Length),
14861 Percentage(Percentage),
14863 Number(f64),
14865}
14866
14867impl fmt::Display for StrokeDashoffset {
14868 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14869 match self {
14870 Self::Length(v) => v.fmt(f),
14871 Self::Percentage(v) => v.fmt(f),
14872 Self::Number(v) => v.fmt(f),
14873 }
14874 }
14875}
14876
14877impl From<Length> for StrokeDashoffset {
14878 fn from(v: Length) -> Self {
14879 Self::Length(v)
14880 }
14881}
14882
14883impl From<Percentage> for StrokeDashoffset {
14884 fn from(v: Percentage) -> Self {
14885 Self::Percentage(v)
14886 }
14887}
14888
14889impl From<f64> for StrokeDashoffset {
14890 fn from(v: f64) -> Self {
14891 Self::Number(v)
14892 }
14893}
14894
14895impl From<i32> for StrokeDashoffset {
14896 fn from(v: i32) -> Self {
14897 Self::Number(f64::from(v))
14898 }
14899}
14900
14901#[derive(Debug, Clone, PartialEq)]
14903#[non_exhaustive]
14904pub enum StrokeLinecap {
14905 Butt,
14907 Round,
14909 Square,
14911}
14912
14913impl fmt::Display for StrokeLinecap {
14914 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14915 match self {
14916 Self::Butt => f.write_str("butt"),
14917 Self::Round => f.write_str("round"),
14918 Self::Square => f.write_str("square"),
14919 }
14920 }
14921}
14922
14923#[derive(Debug, Clone, PartialEq)]
14925#[non_exhaustive]
14926pub enum StrokeLinejoin {
14927 Arcs,
14929 Bevel,
14931 Miter,
14933 MiterClip,
14935 Round,
14937}
14938
14939impl fmt::Display for StrokeLinejoin {
14940 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14941 match self {
14942 Self::Arcs => f.write_str("arcs"),
14943 Self::Bevel => f.write_str("bevel"),
14944 Self::Miter => f.write_str("miter"),
14945 Self::MiterClip => f.write_str("miter-clip"),
14946 Self::Round => f.write_str("round"),
14947 }
14948 }
14949}
14950
14951#[derive(Debug, Clone, PartialEq)]
14953#[non_exhaustive]
14954pub enum StrokeOpacity {
14955 Percentage(Percentage),
14957 Number(f64),
14959}
14960
14961impl fmt::Display for StrokeOpacity {
14962 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
14963 match self {
14964 Self::Percentage(v) => v.fmt(f),
14965 Self::Number(v) => v.fmt(f),
14966 }
14967 }
14968}
14969
14970impl From<Percentage> for StrokeOpacity {
14971 fn from(v: Percentage) -> Self {
14972 Self::Percentage(v)
14973 }
14974}
14975
14976impl From<f64> for StrokeOpacity {
14977 fn from(v: f64) -> Self {
14978 Self::Number(v)
14979 }
14980}
14981
14982impl From<i32> for StrokeOpacity {
14983 fn from(v: i32) -> Self {
14984 Self::Number(f64::from(v))
14985 }
14986}
14987
14988#[derive(Debug, Clone, PartialEq)]
14990#[non_exhaustive]
14991pub enum StrokeWidth {
14992 Length(Length),
14994 Percentage(Percentage),
14996 Number(f64),
14998}
14999
15000impl fmt::Display for StrokeWidth {
15001 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15002 match self {
15003 Self::Length(v) => v.fmt(f),
15004 Self::Percentage(v) => v.fmt(f),
15005 Self::Number(v) => v.fmt(f),
15006 }
15007 }
15008}
15009
15010impl From<Length> for StrokeWidth {
15011 fn from(v: Length) -> Self {
15012 Self::Length(v)
15013 }
15014}
15015
15016impl From<Percentage> for StrokeWidth {
15017 fn from(v: Percentage) -> Self {
15018 Self::Percentage(v)
15019 }
15020}
15021
15022impl From<f64> for StrokeWidth {
15023 fn from(v: f64) -> Self {
15024 Self::Number(v)
15025 }
15026}
15027
15028impl From<i32> for StrokeWidth {
15029 fn from(v: i32) -> Self {
15030 Self::Number(f64::from(v))
15031 }
15032}
15033
15034#[derive(Debug, Clone, PartialEq)]
15036#[non_exhaustive]
15037pub enum TabSize {
15038 Length(Length),
15040 Integer(i32),
15042}
15043
15044impl fmt::Display for TabSize {
15045 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15046 match self {
15047 Self::Length(v) => v.fmt(f),
15048 Self::Integer(v) => v.fmt(f),
15049 }
15050 }
15051}
15052
15053impl From<Length> for TabSize {
15054 fn from(v: Length) -> Self {
15055 Self::Length(v)
15056 }
15057}
15058
15059impl From<i32> for TabSize {
15060 fn from(v: i32) -> Self {
15061 Self::Integer(v)
15062 }
15063}
15064
15065#[derive(Debug, Clone, PartialEq)]
15067#[non_exhaustive]
15068pub enum TableLayout {
15069 Auto,
15071 Fixed,
15073}
15074
15075impl fmt::Display for TableLayout {
15076 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15077 match self {
15078 Self::Auto => f.write_str("auto"),
15079 Self::Fixed => f.write_str("fixed"),
15080 }
15081 }
15082}
15083
15084#[derive(Debug, Clone, PartialEq)]
15086#[non_exhaustive]
15087pub enum TextAlign {
15088 Center,
15090 End,
15092 Justify,
15094 Left,
15096 MatchParent,
15098 Right,
15100 Start,
15102}
15103
15104impl fmt::Display for TextAlign {
15105 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15106 match self {
15107 Self::Center => f.write_str("center"),
15108 Self::End => f.write_str("end"),
15109 Self::Justify => f.write_str("justify"),
15110 Self::Left => f.write_str("left"),
15111 Self::MatchParent => f.write_str("match-parent"),
15112 Self::Right => f.write_str("right"),
15113 Self::Start => f.write_str("start"),
15114 }
15115 }
15116}
15117
15118#[derive(Debug, Clone, PartialEq)]
15120#[non_exhaustive]
15121pub enum TextAlignLast {
15122 Auto,
15124 Center,
15126 End,
15128 Justify,
15130 Left,
15132 Right,
15134 Start,
15136}
15137
15138impl fmt::Display for TextAlignLast {
15139 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15140 match self {
15141 Self::Auto => f.write_str("auto"),
15142 Self::Center => f.write_str("center"),
15143 Self::End => f.write_str("end"),
15144 Self::Justify => f.write_str("justify"),
15145 Self::Left => f.write_str("left"),
15146 Self::Right => f.write_str("right"),
15147 Self::Start => f.write_str("start"),
15148 }
15149 }
15150}
15151
15152#[derive(Debug, Clone, PartialEq)]
15154#[non_exhaustive]
15155pub enum TextAnchor {
15156 End,
15158 Middle,
15160 Start,
15162}
15163
15164impl fmt::Display for TextAnchor {
15165 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15166 match self {
15167 Self::End => f.write_str("end"),
15168 Self::Middle => f.write_str("middle"),
15169 Self::Start => f.write_str("start"),
15170 }
15171 }
15172}
15173
15174#[derive(Debug, Clone, PartialEq)]
15176#[non_exhaustive]
15177pub enum TextAutospace {
15178 Auto,
15180 Normal,
15182 Raw(Raw),
15184}
15185
15186impl fmt::Display for TextAutospace {
15187 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15188 match self {
15189 Self::Auto => f.write_str("auto"),
15190 Self::Normal => f.write_str("normal"),
15191 Self::Raw(v) => v.fmt(f),
15192 }
15193 }
15194}
15195
15196impl From<Raw> for TextAutospace {
15197 fn from(v: Raw) -> Self {
15198 Self::Raw(v)
15199 }
15200}
15201
15202#[derive(Debug, Clone, PartialEq)]
15204#[non_exhaustive]
15205pub enum TextBox {
15206 Auto,
15208 Cap,
15210 Ex,
15212 Ideographic,
15214 IdeographicInk,
15216 None,
15218 Normal,
15220 Text,
15222 TrimBoth,
15224 TrimEnd,
15226 TrimStart,
15228 Raw(Raw),
15230}
15231
15232impl fmt::Display for TextBox {
15233 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15234 match self {
15235 Self::Auto => f.write_str("auto"),
15236 Self::Cap => f.write_str("cap"),
15237 Self::Ex => f.write_str("ex"),
15238 Self::Ideographic => f.write_str("ideographic"),
15239 Self::IdeographicInk => f.write_str("ideographic-ink"),
15240 Self::None => f.write_str("none"),
15241 Self::Normal => f.write_str("normal"),
15242 Self::Text => f.write_str("text"),
15243 Self::TrimBoth => f.write_str("trim-both"),
15244 Self::TrimEnd => f.write_str("trim-end"),
15245 Self::TrimStart => f.write_str("trim-start"),
15246 Self::Raw(v) => v.fmt(f),
15247 }
15248 }
15249}
15250
15251impl From<Raw> for TextBox {
15252 fn from(v: Raw) -> Self {
15253 Self::Raw(v)
15254 }
15255}
15256
15257#[derive(Debug, Clone, PartialEq)]
15259#[non_exhaustive]
15260pub enum TextBoxEdge {
15261 Auto,
15263 Cap,
15265 Ex,
15267 Ideographic,
15269 IdeographicInk,
15271 Text,
15273 Raw(Raw),
15275}
15276
15277impl fmt::Display for TextBoxEdge {
15278 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15279 match self {
15280 Self::Auto => f.write_str("auto"),
15281 Self::Cap => f.write_str("cap"),
15282 Self::Ex => f.write_str("ex"),
15283 Self::Ideographic => f.write_str("ideographic"),
15284 Self::IdeographicInk => f.write_str("ideographic-ink"),
15285 Self::Text => f.write_str("text"),
15286 Self::Raw(v) => v.fmt(f),
15287 }
15288 }
15289}
15290
15291impl From<Raw> for TextBoxEdge {
15292 fn from(v: Raw) -> Self {
15293 Self::Raw(v)
15294 }
15295}
15296
15297#[derive(Debug, Clone, PartialEq)]
15299#[non_exhaustive]
15300pub enum TextBoxTrim {
15301 None,
15303 TrimBoth,
15305 TrimEnd,
15307 TrimStart,
15309}
15310
15311impl fmt::Display for TextBoxTrim {
15312 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15313 match self {
15314 Self::None => f.write_str("none"),
15315 Self::TrimBoth => f.write_str("trim-both"),
15316 Self::TrimEnd => f.write_str("trim-end"),
15317 Self::TrimStart => f.write_str("trim-start"),
15318 }
15319 }
15320}
15321
15322#[derive(Debug, Clone, PartialEq)]
15324#[non_exhaustive]
15325pub enum TextCombineUpright {
15326 All,
15328 Digits,
15330 None,
15332 Raw(Raw),
15334}
15335
15336impl fmt::Display for TextCombineUpright {
15337 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15338 match self {
15339 Self::All => f.write_str("all"),
15340 Self::Digits => f.write_str("digits"),
15341 Self::None => f.write_str("none"),
15342 Self::Raw(v) => v.fmt(f),
15343 }
15344 }
15345}
15346
15347impl From<Raw> for TextCombineUpright {
15348 fn from(v: Raw) -> Self {
15349 Self::Raw(v)
15350 }
15351}
15352
15353#[derive(Debug, Clone, PartialEq)]
15355#[non_exhaustive]
15356pub enum TextDecoration {
15357 Auto,
15359 Blink,
15361 Dashed,
15363 Dotted,
15365 Double,
15367 FromFont,
15369 GrammarError,
15371 LineThrough,
15373 None,
15375 Overline,
15377 Solid,
15379 SpellingError,
15381 Underline,
15383 Wavy,
15385 Length(Length),
15387 Percentage(Percentage),
15389 Color(Color),
15391 Raw(Raw),
15393}
15394
15395impl fmt::Display for TextDecoration {
15396 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15397 match self {
15398 Self::Auto => f.write_str("auto"),
15399 Self::Blink => f.write_str("blink"),
15400 Self::Dashed => f.write_str("dashed"),
15401 Self::Dotted => f.write_str("dotted"),
15402 Self::Double => f.write_str("double"),
15403 Self::FromFont => f.write_str("from-font"),
15404 Self::GrammarError => f.write_str("grammar-error"),
15405 Self::LineThrough => f.write_str("line-through"),
15406 Self::None => f.write_str("none"),
15407 Self::Overline => f.write_str("overline"),
15408 Self::Solid => f.write_str("solid"),
15409 Self::SpellingError => f.write_str("spelling-error"),
15410 Self::Underline => f.write_str("underline"),
15411 Self::Wavy => f.write_str("wavy"),
15412 Self::Length(v) => v.fmt(f),
15413 Self::Percentage(v) => v.fmt(f),
15414 Self::Color(v) => v.fmt(f),
15415 Self::Raw(v) => v.fmt(f),
15416 }
15417 }
15418}
15419
15420impl From<Length> for TextDecoration {
15421 fn from(v: Length) -> Self {
15422 Self::Length(v)
15423 }
15424}
15425
15426impl From<Percentage> for TextDecoration {
15427 fn from(v: Percentage) -> Self {
15428 Self::Percentage(v)
15429 }
15430}
15431
15432impl From<Color> for TextDecoration {
15433 fn from(v: Color) -> Self {
15434 Self::Color(v)
15435 }
15436}
15437
15438impl From<Raw> for TextDecoration {
15439 fn from(v: Raw) -> Self {
15440 Self::Raw(v)
15441 }
15442}
15443
15444#[derive(Debug, Clone, PartialEq)]
15446#[non_exhaustive]
15447pub enum TextDecorationInset {
15448 Auto,
15450 Length(Length),
15452 Percentage(Percentage),
15454 Raw(Raw),
15456}
15457
15458impl fmt::Display for TextDecorationInset {
15459 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15460 match self {
15461 Self::Auto => f.write_str("auto"),
15462 Self::Length(v) => v.fmt(f),
15463 Self::Percentage(v) => v.fmt(f),
15464 Self::Raw(v) => v.fmt(f),
15465 }
15466 }
15467}
15468
15469impl From<Length> for TextDecorationInset {
15470 fn from(v: Length) -> Self {
15471 Self::Length(v)
15472 }
15473}
15474
15475impl From<Percentage> for TextDecorationInset {
15476 fn from(v: Percentage) -> Self {
15477 Self::Percentage(v)
15478 }
15479}
15480
15481impl From<Raw> for TextDecorationInset {
15482 fn from(v: Raw) -> Self {
15483 Self::Raw(v)
15484 }
15485}
15486
15487#[derive(Debug, Clone, PartialEq)]
15489#[non_exhaustive]
15490pub enum TextDecorationLine {
15491 Blink,
15493 GrammarError,
15495 LineThrough,
15497 None,
15499 Overline,
15501 SpellingError,
15503 Underline,
15505 Raw(Raw),
15507}
15508
15509impl fmt::Display for TextDecorationLine {
15510 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15511 match self {
15512 Self::Blink => f.write_str("blink"),
15513 Self::GrammarError => f.write_str("grammar-error"),
15514 Self::LineThrough => f.write_str("line-through"),
15515 Self::None => f.write_str("none"),
15516 Self::Overline => f.write_str("overline"),
15517 Self::SpellingError => f.write_str("spelling-error"),
15518 Self::Underline => f.write_str("underline"),
15519 Self::Raw(v) => v.fmt(f),
15520 }
15521 }
15522}
15523
15524impl From<Raw> for TextDecorationLine {
15525 fn from(v: Raw) -> Self {
15526 Self::Raw(v)
15527 }
15528}
15529
15530#[derive(Debug, Clone, PartialEq)]
15532#[non_exhaustive]
15533pub enum TextDecorationSkipInk {
15534 All,
15536 Auto,
15538 None,
15540}
15541
15542impl fmt::Display for TextDecorationSkipInk {
15543 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15544 match self {
15545 Self::All => f.write_str("all"),
15546 Self::Auto => f.write_str("auto"),
15547 Self::None => f.write_str("none"),
15548 }
15549 }
15550}
15551
15552#[derive(Debug, Clone, PartialEq)]
15554#[non_exhaustive]
15555pub enum TextDecorationStyle {
15556 Dashed,
15558 Dotted,
15560 Double,
15562 Solid,
15564 Wavy,
15566}
15567
15568impl fmt::Display for TextDecorationStyle {
15569 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15570 match self {
15571 Self::Dashed => f.write_str("dashed"),
15572 Self::Dotted => f.write_str("dotted"),
15573 Self::Double => f.write_str("double"),
15574 Self::Solid => f.write_str("solid"),
15575 Self::Wavy => f.write_str("wavy"),
15576 }
15577 }
15578}
15579
15580#[derive(Debug, Clone, PartialEq)]
15582#[non_exhaustive]
15583pub enum TextDecorationThickness {
15584 Auto,
15586 FromFont,
15588 Length(Length),
15590 Percentage(Percentage),
15592}
15593
15594impl fmt::Display for TextDecorationThickness {
15595 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15596 match self {
15597 Self::Auto => f.write_str("auto"),
15598 Self::FromFont => f.write_str("from-font"),
15599 Self::Length(v) => v.fmt(f),
15600 Self::Percentage(v) => v.fmt(f),
15601 }
15602 }
15603}
15604
15605impl From<Length> for TextDecorationThickness {
15606 fn from(v: Length) -> Self {
15607 Self::Length(v)
15608 }
15609}
15610
15611impl From<Percentage> for TextDecorationThickness {
15612 fn from(v: Percentage) -> Self {
15613 Self::Percentage(v)
15614 }
15615}
15616
15617#[derive(Debug, Clone, PartialEq)]
15619#[non_exhaustive]
15620pub enum TextEmphasis {
15621 Circle,
15623 Dot,
15625 DoubleCircle,
15627 Filled,
15629 None,
15631 Open,
15633 Sesame,
15635 Triangle,
15637 Color(Color),
15639 Quoted(Quoted),
15641 Raw(Raw),
15643}
15644
15645impl fmt::Display for TextEmphasis {
15646 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15647 match self {
15648 Self::Circle => f.write_str("circle"),
15649 Self::Dot => f.write_str("dot"),
15650 Self::DoubleCircle => f.write_str("double-circle"),
15651 Self::Filled => f.write_str("filled"),
15652 Self::None => f.write_str("none"),
15653 Self::Open => f.write_str("open"),
15654 Self::Sesame => f.write_str("sesame"),
15655 Self::Triangle => f.write_str("triangle"),
15656 Self::Color(v) => v.fmt(f),
15657 Self::Quoted(v) => v.fmt(f),
15658 Self::Raw(v) => v.fmt(f),
15659 }
15660 }
15661}
15662
15663impl From<Color> for TextEmphasis {
15664 fn from(v: Color) -> Self {
15665 Self::Color(v)
15666 }
15667}
15668
15669impl From<Quoted> for TextEmphasis {
15670 fn from(v: Quoted) -> Self {
15671 Self::Quoted(v)
15672 }
15673}
15674
15675impl From<Raw> for TextEmphasis {
15676 fn from(v: Raw) -> Self {
15677 Self::Raw(v)
15678 }
15679}
15680
15681#[derive(Debug, Clone, PartialEq)]
15683#[non_exhaustive]
15684pub enum TextEmphasisPosition {
15685 Auto,
15687 Raw(Raw),
15689}
15690
15691impl fmt::Display for TextEmphasisPosition {
15692 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15693 match self {
15694 Self::Auto => f.write_str("auto"),
15695 Self::Raw(v) => v.fmt(f),
15696 }
15697 }
15698}
15699
15700impl From<Raw> for TextEmphasisPosition {
15701 fn from(v: Raw) -> Self {
15702 Self::Raw(v)
15703 }
15704}
15705
15706#[derive(Debug, Clone, PartialEq)]
15708#[non_exhaustive]
15709pub enum TextEmphasisStyle {
15710 Circle,
15712 Dot,
15714 DoubleCircle,
15716 Filled,
15718 None,
15720 Open,
15722 Sesame,
15724 Triangle,
15726 Quoted(Quoted),
15728 Raw(Raw),
15730}
15731
15732impl fmt::Display for TextEmphasisStyle {
15733 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15734 match self {
15735 Self::Circle => f.write_str("circle"),
15736 Self::Dot => f.write_str("dot"),
15737 Self::DoubleCircle => f.write_str("double-circle"),
15738 Self::Filled => f.write_str("filled"),
15739 Self::None => f.write_str("none"),
15740 Self::Open => f.write_str("open"),
15741 Self::Sesame => f.write_str("sesame"),
15742 Self::Triangle => f.write_str("triangle"),
15743 Self::Quoted(v) => v.fmt(f),
15744 Self::Raw(v) => v.fmt(f),
15745 }
15746 }
15747}
15748
15749impl From<Quoted> for TextEmphasisStyle {
15750 fn from(v: Quoted) -> Self {
15751 Self::Quoted(v)
15752 }
15753}
15754
15755impl From<Raw> for TextEmphasisStyle {
15756 fn from(v: Raw) -> Self {
15757 Self::Raw(v)
15758 }
15759}
15760
15761#[derive(Debug, Clone, PartialEq)]
15763#[non_exhaustive]
15764pub enum TextFit {
15765 Grow,
15767 None,
15769 Shrink,
15771 Raw(Raw),
15773}
15774
15775impl fmt::Display for TextFit {
15776 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15777 match self {
15778 Self::Grow => f.write_str("grow"),
15779 Self::None => f.write_str("none"),
15780 Self::Shrink => f.write_str("shrink"),
15781 Self::Raw(v) => v.fmt(f),
15782 }
15783 }
15784}
15785
15786impl From<Raw> for TextFit {
15787 fn from(v: Raw) -> Self {
15788 Self::Raw(v)
15789 }
15790}
15791
15792#[derive(Debug, Clone, PartialEq)]
15794#[non_exhaustive]
15795pub enum TextIndent {
15796 Raw(Raw),
15798}
15799
15800impl fmt::Display for TextIndent {
15801 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15802 match self {
15803 Self::Raw(v) => v.fmt(f),
15804 }
15805 }
15806}
15807
15808impl From<Raw> for TextIndent {
15809 fn from(v: Raw) -> Self {
15810 Self::Raw(v)
15811 }
15812}
15813
15814#[derive(Debug, Clone, PartialEq)]
15816#[non_exhaustive]
15817pub enum TextJustify {
15818 Auto,
15820 InterCharacter,
15822 InterWord,
15824 None,
15826}
15827
15828impl fmt::Display for TextJustify {
15829 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15830 match self {
15831 Self::Auto => f.write_str("auto"),
15832 Self::InterCharacter => f.write_str("inter-character"),
15833 Self::InterWord => f.write_str("inter-word"),
15834 Self::None => f.write_str("none"),
15835 }
15836 }
15837}
15838
15839#[derive(Debug, Clone, PartialEq)]
15841#[non_exhaustive]
15842pub enum TextOrientation {
15843 Mixed,
15845 Sideways,
15847 Upright,
15849}
15850
15851impl fmt::Display for TextOrientation {
15852 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15853 match self {
15854 Self::Mixed => f.write_str("mixed"),
15855 Self::Sideways => f.write_str("sideways"),
15856 Self::Upright => f.write_str("upright"),
15857 }
15858 }
15859}
15860
15861#[derive(Debug, Clone, PartialEq)]
15863#[non_exhaustive]
15864pub enum TextOverflow {
15865 Clip,
15867 Ellipsis,
15869 Quoted(Quoted),
15871 Raw(Raw),
15873}
15874
15875impl fmt::Display for TextOverflow {
15876 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15877 match self {
15878 Self::Clip => f.write_str("clip"),
15879 Self::Ellipsis => f.write_str("ellipsis"),
15880 Self::Quoted(v) => v.fmt(f),
15881 Self::Raw(v) => v.fmt(f),
15882 }
15883 }
15884}
15885
15886impl From<Quoted> for TextOverflow {
15887 fn from(v: Quoted) -> Self {
15888 Self::Quoted(v)
15889 }
15890}
15891
15892impl From<Raw> for TextOverflow {
15893 fn from(v: Raw) -> Self {
15894 Self::Raw(v)
15895 }
15896}
15897
15898#[derive(Debug, Clone, PartialEq)]
15900#[non_exhaustive]
15901pub enum TextRendering {
15902 Auto,
15904 GeometricPrecision,
15906 OptimizeLegibility,
15908 OptimizeSpeed,
15910}
15911
15912impl fmt::Display for TextRendering {
15913 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15914 match self {
15915 Self::Auto => f.write_str("auto"),
15916 Self::GeometricPrecision => f.write_str("geometricPrecision"),
15917 Self::OptimizeLegibility => f.write_str("optimizeLegibility"),
15918 Self::OptimizeSpeed => f.write_str("optimizeSpeed"),
15919 }
15920 }
15921}
15922
15923#[derive(Debug, Clone, PartialEq)]
15925#[non_exhaustive]
15926pub enum TextShadow {
15927 None,
15929 Raw(Raw),
15931}
15932
15933impl fmt::Display for TextShadow {
15934 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15935 match self {
15936 Self::None => f.write_str("none"),
15937 Self::Raw(v) => v.fmt(f),
15938 }
15939 }
15940}
15941
15942impl From<Raw> for TextShadow {
15943 fn from(v: Raw) -> Self {
15944 Self::Raw(v)
15945 }
15946}
15947
15948#[derive(Debug, Clone, PartialEq)]
15950#[non_exhaustive]
15951pub enum TextTransform {
15952 Capitalize,
15954 FullSizeKana,
15956 FullWidth,
15958 Lowercase,
15960 MathAuto,
15962 None,
15964 Uppercase,
15966 Raw(Raw),
15968}
15969
15970impl fmt::Display for TextTransform {
15971 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
15972 match self {
15973 Self::Capitalize => f.write_str("capitalize"),
15974 Self::FullSizeKana => f.write_str("full-size-kana"),
15975 Self::FullWidth => f.write_str("full-width"),
15976 Self::Lowercase => f.write_str("lowercase"),
15977 Self::MathAuto => f.write_str("math-auto"),
15978 Self::None => f.write_str("none"),
15979 Self::Uppercase => f.write_str("uppercase"),
15980 Self::Raw(v) => v.fmt(f),
15981 }
15982 }
15983}
15984
15985impl From<Raw> for TextTransform {
15986 fn from(v: Raw) -> Self {
15987 Self::Raw(v)
15988 }
15989}
15990
15991#[derive(Debug, Clone, PartialEq)]
15993#[non_exhaustive]
15994pub enum TextUnderlineOffset {
15995 Auto,
15997 Length(Length),
15999 Percentage(Percentage),
16001}
16002
16003impl fmt::Display for TextUnderlineOffset {
16004 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16005 match self {
16006 Self::Auto => f.write_str("auto"),
16007 Self::Length(v) => v.fmt(f),
16008 Self::Percentage(v) => v.fmt(f),
16009 }
16010 }
16011}
16012
16013impl From<Length> for TextUnderlineOffset {
16014 fn from(v: Length) -> Self {
16015 Self::Length(v)
16016 }
16017}
16018
16019impl From<Percentage> for TextUnderlineOffset {
16020 fn from(v: Percentage) -> Self {
16021 Self::Percentage(v)
16022 }
16023}
16024
16025#[derive(Debug, Clone, PartialEq)]
16027#[non_exhaustive]
16028pub enum TextUnderlinePosition {
16029 Auto,
16031 FromFont,
16033 Left,
16035 Right,
16037 Under,
16039 Raw(Raw),
16041}
16042
16043impl fmt::Display for TextUnderlinePosition {
16044 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16045 match self {
16046 Self::Auto => f.write_str("auto"),
16047 Self::FromFont => f.write_str("from-font"),
16048 Self::Left => f.write_str("left"),
16049 Self::Right => f.write_str("right"),
16050 Self::Under => f.write_str("under"),
16051 Self::Raw(v) => v.fmt(f),
16052 }
16053 }
16054}
16055
16056impl From<Raw> for TextUnderlinePosition {
16057 fn from(v: Raw) -> Self {
16058 Self::Raw(v)
16059 }
16060}
16061
16062#[derive(Debug, Clone, PartialEq)]
16064#[non_exhaustive]
16065pub enum TextWrap {
16066 Auto,
16068 Balance,
16070 Nowrap,
16072 Pretty,
16074 Stable,
16076 Wrap,
16078 Raw(Raw),
16080}
16081
16082impl fmt::Display for TextWrap {
16083 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16084 match self {
16085 Self::Auto => f.write_str("auto"),
16086 Self::Balance => f.write_str("balance"),
16087 Self::Nowrap => f.write_str("nowrap"),
16088 Self::Pretty => f.write_str("pretty"),
16089 Self::Stable => f.write_str("stable"),
16090 Self::Wrap => f.write_str("wrap"),
16091 Self::Raw(v) => v.fmt(f),
16092 }
16093 }
16094}
16095
16096impl From<Raw> for TextWrap {
16097 fn from(v: Raw) -> Self {
16098 Self::Raw(v)
16099 }
16100}
16101
16102#[derive(Debug, Clone, PartialEq)]
16104#[non_exhaustive]
16105pub enum TextWrapMode {
16106 Nowrap,
16108 Wrap,
16110}
16111
16112impl fmt::Display for TextWrapMode {
16113 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16114 match self {
16115 Self::Nowrap => f.write_str("nowrap"),
16116 Self::Wrap => f.write_str("wrap"),
16117 }
16118 }
16119}
16120
16121#[derive(Debug, Clone, PartialEq)]
16123#[non_exhaustive]
16124pub enum TextWrapStyle {
16125 Auto,
16127 Balance,
16129 Pretty,
16131 Stable,
16133}
16134
16135impl fmt::Display for TextWrapStyle {
16136 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16137 match self {
16138 Self::Auto => f.write_str("auto"),
16139 Self::Balance => f.write_str("balance"),
16140 Self::Pretty => f.write_str("pretty"),
16141 Self::Stable => f.write_str("stable"),
16142 }
16143 }
16144}
16145
16146#[derive(Debug, Clone, PartialEq)]
16148#[non_exhaustive]
16149pub enum TimelineTrigger {
16150 None,
16152 Raw(Raw),
16154}
16155
16156impl fmt::Display for TimelineTrigger {
16157 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16158 match self {
16159 Self::None => f.write_str("none"),
16160 Self::Raw(v) => v.fmt(f),
16161 }
16162 }
16163}
16164
16165impl From<Raw> for TimelineTrigger {
16166 fn from(v: Raw) -> Self {
16167 Self::Raw(v)
16168 }
16169}
16170
16171#[derive(Debug, Clone, PartialEq)]
16173#[non_exhaustive]
16174pub enum TimelineTriggerActivationRange {
16175 Contain,
16177 Cover,
16179 Entry,
16181 EntryCrossing,
16183 Exit,
16185 ExitCrossing,
16187 Normal,
16189 Length(Length),
16191 Percentage(Percentage),
16193 Raw(Raw),
16195}
16196
16197impl fmt::Display for TimelineTriggerActivationRange {
16198 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16199 match self {
16200 Self::Contain => f.write_str("contain"),
16201 Self::Cover => f.write_str("cover"),
16202 Self::Entry => f.write_str("entry"),
16203 Self::EntryCrossing => f.write_str("entry-crossing"),
16204 Self::Exit => f.write_str("exit"),
16205 Self::ExitCrossing => f.write_str("exit-crossing"),
16206 Self::Normal => f.write_str("normal"),
16207 Self::Length(v) => v.fmt(f),
16208 Self::Percentage(v) => v.fmt(f),
16209 Self::Raw(v) => v.fmt(f),
16210 }
16211 }
16212}
16213
16214impl From<Length> for TimelineTriggerActivationRange {
16215 fn from(v: Length) -> Self {
16216 Self::Length(v)
16217 }
16218}
16219
16220impl From<Percentage> for TimelineTriggerActivationRange {
16221 fn from(v: Percentage) -> Self {
16222 Self::Percentage(v)
16223 }
16224}
16225
16226impl From<Raw> for TimelineTriggerActivationRange {
16227 fn from(v: Raw) -> Self {
16228 Self::Raw(v)
16229 }
16230}
16231
16232#[derive(Debug, Clone, PartialEq)]
16234#[non_exhaustive]
16235pub enum TimelineTriggerActivationRangeEnd {
16236 Contain,
16238 Cover,
16240 Entry,
16242 EntryCrossing,
16244 Exit,
16246 ExitCrossing,
16248 Normal,
16250 Length(Length),
16252 Percentage(Percentage),
16254 Raw(Raw),
16256}
16257
16258impl fmt::Display for TimelineTriggerActivationRangeEnd {
16259 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16260 match self {
16261 Self::Contain => f.write_str("contain"),
16262 Self::Cover => f.write_str("cover"),
16263 Self::Entry => f.write_str("entry"),
16264 Self::EntryCrossing => f.write_str("entry-crossing"),
16265 Self::Exit => f.write_str("exit"),
16266 Self::ExitCrossing => f.write_str("exit-crossing"),
16267 Self::Normal => f.write_str("normal"),
16268 Self::Length(v) => v.fmt(f),
16269 Self::Percentage(v) => v.fmt(f),
16270 Self::Raw(v) => v.fmt(f),
16271 }
16272 }
16273}
16274
16275impl From<Length> for TimelineTriggerActivationRangeEnd {
16276 fn from(v: Length) -> Self {
16277 Self::Length(v)
16278 }
16279}
16280
16281impl From<Percentage> for TimelineTriggerActivationRangeEnd {
16282 fn from(v: Percentage) -> Self {
16283 Self::Percentage(v)
16284 }
16285}
16286
16287impl From<Raw> for TimelineTriggerActivationRangeEnd {
16288 fn from(v: Raw) -> Self {
16289 Self::Raw(v)
16290 }
16291}
16292
16293#[derive(Debug, Clone, PartialEq)]
16295#[non_exhaustive]
16296pub enum TimelineTriggerActivationRangeStart {
16297 Contain,
16299 Cover,
16301 Entry,
16303 EntryCrossing,
16305 Exit,
16307 ExitCrossing,
16309 Normal,
16311 Length(Length),
16313 Percentage(Percentage),
16315 Raw(Raw),
16317}
16318
16319impl fmt::Display for TimelineTriggerActivationRangeStart {
16320 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16321 match self {
16322 Self::Contain => f.write_str("contain"),
16323 Self::Cover => f.write_str("cover"),
16324 Self::Entry => f.write_str("entry"),
16325 Self::EntryCrossing => f.write_str("entry-crossing"),
16326 Self::Exit => f.write_str("exit"),
16327 Self::ExitCrossing => f.write_str("exit-crossing"),
16328 Self::Normal => f.write_str("normal"),
16329 Self::Length(v) => v.fmt(f),
16330 Self::Percentage(v) => v.fmt(f),
16331 Self::Raw(v) => v.fmt(f),
16332 }
16333 }
16334}
16335
16336impl From<Length> for TimelineTriggerActivationRangeStart {
16337 fn from(v: Length) -> Self {
16338 Self::Length(v)
16339 }
16340}
16341
16342impl From<Percentage> for TimelineTriggerActivationRangeStart {
16343 fn from(v: Percentage) -> Self {
16344 Self::Percentage(v)
16345 }
16346}
16347
16348impl From<Raw> for TimelineTriggerActivationRangeStart {
16349 fn from(v: Raw) -> Self {
16350 Self::Raw(v)
16351 }
16352}
16353
16354#[derive(Debug, Clone, PartialEq)]
16356#[non_exhaustive]
16357pub enum TimelineTriggerActiveRange {
16358 Auto,
16360 Contain,
16362 Cover,
16364 Entry,
16366 EntryCrossing,
16368 Exit,
16370 ExitCrossing,
16372 Normal,
16374 Length(Length),
16376 Percentage(Percentage),
16378 Raw(Raw),
16380}
16381
16382impl fmt::Display for TimelineTriggerActiveRange {
16383 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16384 match self {
16385 Self::Auto => f.write_str("auto"),
16386 Self::Contain => f.write_str("contain"),
16387 Self::Cover => f.write_str("cover"),
16388 Self::Entry => f.write_str("entry"),
16389 Self::EntryCrossing => f.write_str("entry-crossing"),
16390 Self::Exit => f.write_str("exit"),
16391 Self::ExitCrossing => f.write_str("exit-crossing"),
16392 Self::Normal => f.write_str("normal"),
16393 Self::Length(v) => v.fmt(f),
16394 Self::Percentage(v) => v.fmt(f),
16395 Self::Raw(v) => v.fmt(f),
16396 }
16397 }
16398}
16399
16400impl From<Length> for TimelineTriggerActiveRange {
16401 fn from(v: Length) -> Self {
16402 Self::Length(v)
16403 }
16404}
16405
16406impl From<Percentage> for TimelineTriggerActiveRange {
16407 fn from(v: Percentage) -> Self {
16408 Self::Percentage(v)
16409 }
16410}
16411
16412impl From<Raw> for TimelineTriggerActiveRange {
16413 fn from(v: Raw) -> Self {
16414 Self::Raw(v)
16415 }
16416}
16417
16418#[derive(Debug, Clone, PartialEq)]
16420#[non_exhaustive]
16421pub enum TimelineTriggerActiveRangeEnd {
16422 Auto,
16424 Contain,
16426 Cover,
16428 Entry,
16430 EntryCrossing,
16432 Exit,
16434 ExitCrossing,
16436 Normal,
16438 Length(Length),
16440 Percentage(Percentage),
16442 Raw(Raw),
16444}
16445
16446impl fmt::Display for TimelineTriggerActiveRangeEnd {
16447 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16448 match self {
16449 Self::Auto => f.write_str("auto"),
16450 Self::Contain => f.write_str("contain"),
16451 Self::Cover => f.write_str("cover"),
16452 Self::Entry => f.write_str("entry"),
16453 Self::EntryCrossing => f.write_str("entry-crossing"),
16454 Self::Exit => f.write_str("exit"),
16455 Self::ExitCrossing => f.write_str("exit-crossing"),
16456 Self::Normal => f.write_str("normal"),
16457 Self::Length(v) => v.fmt(f),
16458 Self::Percentage(v) => v.fmt(f),
16459 Self::Raw(v) => v.fmt(f),
16460 }
16461 }
16462}
16463
16464impl From<Length> for TimelineTriggerActiveRangeEnd {
16465 fn from(v: Length) -> Self {
16466 Self::Length(v)
16467 }
16468}
16469
16470impl From<Percentage> for TimelineTriggerActiveRangeEnd {
16471 fn from(v: Percentage) -> Self {
16472 Self::Percentage(v)
16473 }
16474}
16475
16476impl From<Raw> for TimelineTriggerActiveRangeEnd {
16477 fn from(v: Raw) -> Self {
16478 Self::Raw(v)
16479 }
16480}
16481
16482#[derive(Debug, Clone, PartialEq)]
16484#[non_exhaustive]
16485pub enum TimelineTriggerActiveRangeStart {
16486 Auto,
16488 Contain,
16490 Cover,
16492 Entry,
16494 EntryCrossing,
16496 Exit,
16498 ExitCrossing,
16500 Normal,
16502 Length(Length),
16504 Percentage(Percentage),
16506 Raw(Raw),
16508}
16509
16510impl fmt::Display for TimelineTriggerActiveRangeStart {
16511 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16512 match self {
16513 Self::Auto => f.write_str("auto"),
16514 Self::Contain => f.write_str("contain"),
16515 Self::Cover => f.write_str("cover"),
16516 Self::Entry => f.write_str("entry"),
16517 Self::EntryCrossing => f.write_str("entry-crossing"),
16518 Self::Exit => f.write_str("exit"),
16519 Self::ExitCrossing => f.write_str("exit-crossing"),
16520 Self::Normal => f.write_str("normal"),
16521 Self::Length(v) => v.fmt(f),
16522 Self::Percentage(v) => v.fmt(f),
16523 Self::Raw(v) => v.fmt(f),
16524 }
16525 }
16526}
16527
16528impl From<Length> for TimelineTriggerActiveRangeStart {
16529 fn from(v: Length) -> Self {
16530 Self::Length(v)
16531 }
16532}
16533
16534impl From<Percentage> for TimelineTriggerActiveRangeStart {
16535 fn from(v: Percentage) -> Self {
16536 Self::Percentage(v)
16537 }
16538}
16539
16540impl From<Raw> for TimelineTriggerActiveRangeStart {
16541 fn from(v: Raw) -> Self {
16542 Self::Raw(v)
16543 }
16544}
16545
16546#[derive(Debug, Clone, PartialEq)]
16548#[non_exhaustive]
16549pub enum TimelineTriggerName {
16550 None,
16552 Raw(Raw),
16554}
16555
16556impl fmt::Display for TimelineTriggerName {
16557 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16558 match self {
16559 Self::None => f.write_str("none"),
16560 Self::Raw(v) => v.fmt(f),
16561 }
16562 }
16563}
16564
16565impl From<Raw> for TimelineTriggerName {
16566 fn from(v: Raw) -> Self {
16567 Self::Raw(v)
16568 }
16569}
16570
16571#[derive(Debug, Clone, PartialEq)]
16573#[non_exhaustive]
16574pub enum TimelineTriggerSource {
16575 Auto,
16577 None,
16579 Raw(Raw),
16581}
16582
16583impl fmt::Display for TimelineTriggerSource {
16584 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16585 match self {
16586 Self::Auto => f.write_str("auto"),
16587 Self::None => f.write_str("none"),
16588 Self::Raw(v) => v.fmt(f),
16589 }
16590 }
16591}
16592
16593impl From<Raw> for TimelineTriggerSource {
16594 fn from(v: Raw) -> Self {
16595 Self::Raw(v)
16596 }
16597}
16598
16599#[derive(Debug, Clone, PartialEq)]
16601#[non_exhaustive]
16602pub enum Top {
16603 Auto,
16605 Length(Length),
16607 Percentage(Percentage),
16609 Raw(Raw),
16611}
16612
16613impl fmt::Display for Top {
16614 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16615 match self {
16616 Self::Auto => f.write_str("auto"),
16617 Self::Length(v) => v.fmt(f),
16618 Self::Percentage(v) => v.fmt(f),
16619 Self::Raw(v) => v.fmt(f),
16620 }
16621 }
16622}
16623
16624impl From<Length> for Top {
16625 fn from(v: Length) -> Self {
16626 Self::Length(v)
16627 }
16628}
16629
16630impl From<Percentage> for Top {
16631 fn from(v: Percentage) -> Self {
16632 Self::Percentage(v)
16633 }
16634}
16635
16636impl From<Raw> for Top {
16637 fn from(v: Raw) -> Self {
16638 Self::Raw(v)
16639 }
16640}
16641
16642#[derive(Debug, Clone, PartialEq)]
16644#[non_exhaustive]
16645pub enum TouchAction {
16646 Auto,
16648 Manipulation,
16650 None,
16652 PanDown,
16654 PanLeft,
16656 PanRight,
16658 PanUp,
16660 PanX,
16662 PanY,
16664 PinchZoom,
16666 Raw(Raw),
16668}
16669
16670impl fmt::Display for TouchAction {
16671 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16672 match self {
16673 Self::Auto => f.write_str("auto"),
16674 Self::Manipulation => f.write_str("manipulation"),
16675 Self::None => f.write_str("none"),
16676 Self::PanDown => f.write_str("pan-down"),
16677 Self::PanLeft => f.write_str("pan-left"),
16678 Self::PanRight => f.write_str("pan-right"),
16679 Self::PanUp => f.write_str("pan-up"),
16680 Self::PanX => f.write_str("pan-x"),
16681 Self::PanY => f.write_str("pan-y"),
16682 Self::PinchZoom => f.write_str("pinch-zoom"),
16683 Self::Raw(v) => v.fmt(f),
16684 }
16685 }
16686}
16687
16688impl From<Raw> for TouchAction {
16689 fn from(v: Raw) -> Self {
16690 Self::Raw(v)
16691 }
16692}
16693
16694#[derive(Debug, Clone, PartialEq)]
16696#[non_exhaustive]
16697pub enum Transform {
16698 None,
16700 Raw(Raw),
16702}
16703
16704impl fmt::Display for Transform {
16705 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16706 match self {
16707 Self::None => f.write_str("none"),
16708 Self::Raw(v) => v.fmt(f),
16709 }
16710 }
16711}
16712
16713impl From<Raw> for Transform {
16714 fn from(v: Raw) -> Self {
16715 Self::Raw(v)
16716 }
16717}
16718
16719#[derive(Debug, Clone, PartialEq)]
16721#[non_exhaustive]
16722pub enum TransformBox {
16723 BorderBox,
16725 ContentBox,
16727 FillBox,
16729 StrokeBox,
16731 ViewBox,
16733}
16734
16735impl fmt::Display for TransformBox {
16736 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16737 match self {
16738 Self::BorderBox => f.write_str("border-box"),
16739 Self::ContentBox => f.write_str("content-box"),
16740 Self::FillBox => f.write_str("fill-box"),
16741 Self::StrokeBox => f.write_str("stroke-box"),
16742 Self::ViewBox => f.write_str("view-box"),
16743 }
16744 }
16745}
16746
16747#[derive(Debug, Clone, PartialEq)]
16749#[non_exhaustive]
16750pub enum TransformOrigin {
16751 Bottom,
16753 Center,
16755 Left,
16757 Right,
16759 Top,
16761 Length(Length),
16763 Percentage(Percentage),
16765 Raw(Raw),
16767}
16768
16769impl fmt::Display for TransformOrigin {
16770 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16771 match self {
16772 Self::Bottom => f.write_str("bottom"),
16773 Self::Center => f.write_str("center"),
16774 Self::Left => f.write_str("left"),
16775 Self::Right => f.write_str("right"),
16776 Self::Top => f.write_str("top"),
16777 Self::Length(v) => v.fmt(f),
16778 Self::Percentage(v) => v.fmt(f),
16779 Self::Raw(v) => v.fmt(f),
16780 }
16781 }
16782}
16783
16784impl From<Length> for TransformOrigin {
16785 fn from(v: Length) -> Self {
16786 Self::Length(v)
16787 }
16788}
16789
16790impl From<Percentage> for TransformOrigin {
16791 fn from(v: Percentage) -> Self {
16792 Self::Percentage(v)
16793 }
16794}
16795
16796impl From<Raw> for TransformOrigin {
16797 fn from(v: Raw) -> Self {
16798 Self::Raw(v)
16799 }
16800}
16801
16802#[derive(Debug, Clone, PartialEq)]
16804#[non_exhaustive]
16805pub enum TransformStyle {
16806 Flat,
16808 Preserve3d,
16810}
16811
16812impl fmt::Display for TransformStyle {
16813 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16814 match self {
16815 Self::Flat => f.write_str("flat"),
16816 Self::Preserve3d => f.write_str("preserve-3d"),
16817 }
16818 }
16819}
16820
16821#[derive(Debug, Clone, PartialEq)]
16823#[non_exhaustive]
16824pub enum Transition {
16825 All,
16827 AllowDiscrete,
16829 Ease,
16831 EaseIn,
16833 EaseInOut,
16835 EaseOut,
16837 Linear,
16839 None,
16841 Normal,
16843 StepEnd,
16845 StepStart,
16847 Time(Time),
16849 Raw(Raw),
16851}
16852
16853impl fmt::Display for Transition {
16854 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16855 match self {
16856 Self::All => f.write_str("all"),
16857 Self::AllowDiscrete => f.write_str("allow-discrete"),
16858 Self::Ease => f.write_str("ease"),
16859 Self::EaseIn => f.write_str("ease-in"),
16860 Self::EaseInOut => f.write_str("ease-in-out"),
16861 Self::EaseOut => f.write_str("ease-out"),
16862 Self::Linear => f.write_str("linear"),
16863 Self::None => f.write_str("none"),
16864 Self::Normal => f.write_str("normal"),
16865 Self::StepEnd => f.write_str("step-end"),
16866 Self::StepStart => f.write_str("step-start"),
16867 Self::Time(v) => v.fmt(f),
16868 Self::Raw(v) => v.fmt(f),
16869 }
16870 }
16871}
16872
16873impl From<Time> for Transition {
16874 fn from(v: Time) -> Self {
16875 Self::Time(v)
16876 }
16877}
16878
16879impl From<Raw> for Transition {
16880 fn from(v: Raw) -> Self {
16881 Self::Raw(v)
16882 }
16883}
16884
16885#[derive(Debug, Clone, PartialEq)]
16887#[non_exhaustive]
16888pub enum TransitionBehavior {
16889 AllowDiscrete,
16891 Normal,
16893 Raw(Raw),
16895}
16896
16897impl fmt::Display for TransitionBehavior {
16898 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16899 match self {
16900 Self::AllowDiscrete => f.write_str("allow-discrete"),
16901 Self::Normal => f.write_str("normal"),
16902 Self::Raw(v) => v.fmt(f),
16903 }
16904 }
16905}
16906
16907impl From<Raw> for TransitionBehavior {
16908 fn from(v: Raw) -> Self {
16909 Self::Raw(v)
16910 }
16911}
16912
16913#[derive(Debug, Clone, PartialEq)]
16915#[non_exhaustive]
16916pub enum TransitionDelay {
16917 Time(Time),
16919 Raw(Raw),
16921}
16922
16923impl fmt::Display for TransitionDelay {
16924 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16925 match self {
16926 Self::Time(v) => v.fmt(f),
16927 Self::Raw(v) => v.fmt(f),
16928 }
16929 }
16930}
16931
16932impl From<Time> for TransitionDelay {
16933 fn from(v: Time) -> Self {
16934 Self::Time(v)
16935 }
16936}
16937
16938impl From<Raw> for TransitionDelay {
16939 fn from(v: Raw) -> Self {
16940 Self::Raw(v)
16941 }
16942}
16943
16944#[derive(Debug, Clone, PartialEq)]
16946#[non_exhaustive]
16947pub enum TransitionDuration {
16948 Time(Time),
16950 Raw(Raw),
16952}
16953
16954impl fmt::Display for TransitionDuration {
16955 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16956 match self {
16957 Self::Time(v) => v.fmt(f),
16958 Self::Raw(v) => v.fmt(f),
16959 }
16960 }
16961}
16962
16963impl From<Time> for TransitionDuration {
16964 fn from(v: Time) -> Self {
16965 Self::Time(v)
16966 }
16967}
16968
16969impl From<Raw> for TransitionDuration {
16970 fn from(v: Raw) -> Self {
16971 Self::Raw(v)
16972 }
16973}
16974
16975#[derive(Debug, Clone, PartialEq)]
16977#[non_exhaustive]
16978pub enum TransitionProperty {
16979 All,
16981 None,
16983 Raw(Raw),
16985}
16986
16987impl fmt::Display for TransitionProperty {
16988 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
16989 match self {
16990 Self::All => f.write_str("all"),
16991 Self::None => f.write_str("none"),
16992 Self::Raw(v) => v.fmt(f),
16993 }
16994 }
16995}
16996
16997impl From<Raw> for TransitionProperty {
16998 fn from(v: Raw) -> Self {
16999 Self::Raw(v)
17000 }
17001}
17002
17003#[derive(Debug, Clone, PartialEq)]
17005#[non_exhaustive]
17006pub enum TransitionTimingFunction {
17007 Ease,
17009 EaseIn,
17011 EaseInOut,
17013 EaseOut,
17015 Linear,
17017 StepEnd,
17019 StepStart,
17021 Raw(Raw),
17023}
17024
17025impl fmt::Display for TransitionTimingFunction {
17026 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17027 match self {
17028 Self::Ease => f.write_str("ease"),
17029 Self::EaseIn => f.write_str("ease-in"),
17030 Self::EaseInOut => f.write_str("ease-in-out"),
17031 Self::EaseOut => f.write_str("ease-out"),
17032 Self::Linear => f.write_str("linear"),
17033 Self::StepEnd => f.write_str("step-end"),
17034 Self::StepStart => f.write_str("step-start"),
17035 Self::Raw(v) => v.fmt(f),
17036 }
17037 }
17038}
17039
17040impl From<Raw> for TransitionTimingFunction {
17041 fn from(v: Raw) -> Self {
17042 Self::Raw(v)
17043 }
17044}
17045
17046#[derive(Debug, Clone, PartialEq)]
17048#[non_exhaustive]
17049pub enum Translate {
17050 None,
17052 Length(Length),
17054 Percentage(Percentage),
17056 Raw(Raw),
17058}
17059
17060impl fmt::Display for Translate {
17061 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17062 match self {
17063 Self::None => f.write_str("none"),
17064 Self::Length(v) => v.fmt(f),
17065 Self::Percentage(v) => v.fmt(f),
17066 Self::Raw(v) => v.fmt(f),
17067 }
17068 }
17069}
17070
17071impl From<Length> for Translate {
17072 fn from(v: Length) -> Self {
17073 Self::Length(v)
17074 }
17075}
17076
17077impl From<Percentage> for Translate {
17078 fn from(v: Percentage) -> Self {
17079 Self::Percentage(v)
17080 }
17081}
17082
17083impl From<Raw> for Translate {
17084 fn from(v: Raw) -> Self {
17085 Self::Raw(v)
17086 }
17087}
17088
17089#[derive(Debug, Clone, PartialEq)]
17091#[non_exhaustive]
17092pub enum TriggerScope {
17093 All,
17095 None,
17097 Raw(Raw),
17099}
17100
17101impl fmt::Display for TriggerScope {
17102 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17103 match self {
17104 Self::All => f.write_str("all"),
17105 Self::None => f.write_str("none"),
17106 Self::Raw(v) => v.fmt(f),
17107 }
17108 }
17109}
17110
17111impl From<Raw> for TriggerScope {
17112 fn from(v: Raw) -> Self {
17113 Self::Raw(v)
17114 }
17115}
17116
17117#[derive(Debug, Clone, PartialEq)]
17119#[non_exhaustive]
17120pub enum UnicodeBidi {
17121 BidiOverride,
17123 Embed,
17125 Isolate,
17127 IsolateOverride,
17129 Normal,
17131 Plaintext,
17133}
17134
17135impl fmt::Display for UnicodeBidi {
17136 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17137 match self {
17138 Self::BidiOverride => f.write_str("bidi-override"),
17139 Self::Embed => f.write_str("embed"),
17140 Self::Isolate => f.write_str("isolate"),
17141 Self::IsolateOverride => f.write_str("isolate-override"),
17142 Self::Normal => f.write_str("normal"),
17143 Self::Plaintext => f.write_str("plaintext"),
17144 }
17145 }
17146}
17147
17148#[derive(Debug, Clone, PartialEq)]
17150#[non_exhaustive]
17151pub enum UserSelect {
17152 All,
17154 Auto,
17156 None,
17158 Text,
17160}
17161
17162impl fmt::Display for UserSelect {
17163 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17164 match self {
17165 Self::All => f.write_str("all"),
17166 Self::Auto => f.write_str("auto"),
17167 Self::None => f.write_str("none"),
17168 Self::Text => f.write_str("text"),
17169 }
17170 }
17171}
17172
17173#[derive(Debug, Clone, PartialEq)]
17175#[non_exhaustive]
17176pub enum VectorEffect {
17177 FixedPosition,
17179 NonRotation,
17181 NonScalingSize,
17183 NonScalingStroke,
17185 None,
17187}
17188
17189impl fmt::Display for VectorEffect {
17190 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17191 match self {
17192 Self::FixedPosition => f.write_str("fixed-position"),
17193 Self::NonRotation => f.write_str("non-rotation"),
17194 Self::NonScalingSize => f.write_str("non-scaling-size"),
17195 Self::NonScalingStroke => f.write_str("non-scaling-stroke"),
17196 Self::None => f.write_str("none"),
17197 }
17198 }
17199}
17200
17201#[derive(Debug, Clone, PartialEq)]
17203#[non_exhaustive]
17204pub enum VerticalAlign {
17205 Baseline,
17207 Bottom,
17209 Middle,
17211 Sub,
17213 Super,
17215 TextBottom,
17217 TextTop,
17219 Top,
17221 Length(Length),
17223 Percentage(Percentage),
17225}
17226
17227impl fmt::Display for VerticalAlign {
17228 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17229 match self {
17230 Self::Baseline => f.write_str("baseline"),
17231 Self::Bottom => f.write_str("bottom"),
17232 Self::Middle => f.write_str("middle"),
17233 Self::Sub => f.write_str("sub"),
17234 Self::Super => f.write_str("super"),
17235 Self::TextBottom => f.write_str("text-bottom"),
17236 Self::TextTop => f.write_str("text-top"),
17237 Self::Top => f.write_str("top"),
17238 Self::Length(v) => v.fmt(f),
17239 Self::Percentage(v) => v.fmt(f),
17240 }
17241 }
17242}
17243
17244impl From<Length> for VerticalAlign {
17245 fn from(v: Length) -> Self {
17246 Self::Length(v)
17247 }
17248}
17249
17250impl From<Percentage> for VerticalAlign {
17251 fn from(v: Percentage) -> Self {
17252 Self::Percentage(v)
17253 }
17254}
17255
17256#[derive(Debug, Clone, PartialEq)]
17258#[non_exhaustive]
17259pub enum ViewTransitionClass {
17260 None,
17262 Raw(Raw),
17264}
17265
17266impl fmt::Display for ViewTransitionClass {
17267 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17268 match self {
17269 Self::None => f.write_str("none"),
17270 Self::Raw(v) => v.fmt(f),
17271 }
17272 }
17273}
17274
17275impl From<Raw> for ViewTransitionClass {
17276 fn from(v: Raw) -> Self {
17277 Self::Raw(v)
17278 }
17279}
17280
17281#[derive(Debug, Clone, PartialEq)]
17283#[non_exhaustive]
17284pub enum ViewTransitionName {
17285 MatchElement,
17287 None,
17289 Raw(Raw),
17291}
17292
17293impl fmt::Display for ViewTransitionName {
17294 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17295 match self {
17296 Self::MatchElement => f.write_str("match-element"),
17297 Self::None => f.write_str("none"),
17298 Self::Raw(v) => v.fmt(f),
17299 }
17300 }
17301}
17302
17303impl From<Raw> for ViewTransitionName {
17304 fn from(v: Raw) -> Self {
17305 Self::Raw(v)
17306 }
17307}
17308
17309#[derive(Debug, Clone, PartialEq)]
17311#[non_exhaustive]
17312pub enum ViewTransitionScope {
17313 All,
17315 None,
17317}
17318
17319impl fmt::Display for ViewTransitionScope {
17320 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17321 match self {
17322 Self::All => f.write_str("all"),
17323 Self::None => f.write_str("none"),
17324 }
17325 }
17326}
17327
17328#[derive(Debug, Clone, PartialEq)]
17330#[non_exhaustive]
17331pub enum Visibility {
17332 Collapse,
17334 Hidden,
17336 Visible,
17338}
17339
17340impl fmt::Display for Visibility {
17341 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17342 match self {
17343 Self::Collapse => f.write_str("collapse"),
17344 Self::Hidden => f.write_str("hidden"),
17345 Self::Visible => f.write_str("visible"),
17346 }
17347 }
17348}
17349
17350#[derive(Debug, Clone, PartialEq)]
17352#[non_exhaustive]
17353pub enum WhiteSpace {
17354 BreakSpaces,
17356 Collapse,
17358 Normal,
17360 Nowrap,
17362 Pre,
17364 PreLine,
17366 PreWrap,
17368 Preserve,
17370 PreserveBreaks,
17372 PreserveSpaces,
17374 Wrap,
17376 Raw(Raw),
17378}
17379
17380impl fmt::Display for WhiteSpace {
17381 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17382 match self {
17383 Self::BreakSpaces => f.write_str("break-spaces"),
17384 Self::Collapse => f.write_str("collapse"),
17385 Self::Normal => f.write_str("normal"),
17386 Self::Nowrap => f.write_str("nowrap"),
17387 Self::Pre => f.write_str("pre"),
17388 Self::PreLine => f.write_str("pre-line"),
17389 Self::PreWrap => f.write_str("pre-wrap"),
17390 Self::Preserve => f.write_str("preserve"),
17391 Self::PreserveBreaks => f.write_str("preserve-breaks"),
17392 Self::PreserveSpaces => f.write_str("preserve-spaces"),
17393 Self::Wrap => f.write_str("wrap"),
17394 Self::Raw(v) => v.fmt(f),
17395 }
17396 }
17397}
17398
17399impl From<Raw> for WhiteSpace {
17400 fn from(v: Raw) -> Self {
17401 Self::Raw(v)
17402 }
17403}
17404
17405#[derive(Debug, Clone, PartialEq)]
17407#[non_exhaustive]
17408pub enum WhiteSpaceCollapse {
17409 BreakSpaces,
17411 Collapse,
17413 Preserve,
17415 PreserveBreaks,
17417 PreserveSpaces,
17419}
17420
17421impl fmt::Display for WhiteSpaceCollapse {
17422 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17423 match self {
17424 Self::BreakSpaces => f.write_str("break-spaces"),
17425 Self::Collapse => f.write_str("collapse"),
17426 Self::Preserve => f.write_str("preserve"),
17427 Self::PreserveBreaks => f.write_str("preserve-breaks"),
17428 Self::PreserveSpaces => f.write_str("preserve-spaces"),
17429 }
17430 }
17431}
17432
17433#[derive(Debug, Clone, PartialEq)]
17435#[non_exhaustive]
17436pub enum Width {
17437 Auto,
17439 FitContent,
17441 MaxContent,
17443 MinContent,
17445 Length(Length),
17447 Percentage(Percentage),
17449 Raw(Raw),
17451}
17452
17453impl fmt::Display for Width {
17454 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17455 match self {
17456 Self::Auto => f.write_str("auto"),
17457 Self::FitContent => f.write_str("fit-content"),
17458 Self::MaxContent => f.write_str("max-content"),
17459 Self::MinContent => f.write_str("min-content"),
17460 Self::Length(v) => v.fmt(f),
17461 Self::Percentage(v) => v.fmt(f),
17462 Self::Raw(v) => v.fmt(f),
17463 }
17464 }
17465}
17466
17467impl From<Length> for Width {
17468 fn from(v: Length) -> Self {
17469 Self::Length(v)
17470 }
17471}
17472
17473impl From<Percentage> for Width {
17474 fn from(v: Percentage) -> Self {
17475 Self::Percentage(v)
17476 }
17477}
17478
17479impl From<Raw> for Width {
17480 fn from(v: Raw) -> Self {
17481 Self::Raw(v)
17482 }
17483}
17484
17485#[derive(Debug, Clone, PartialEq)]
17487#[non_exhaustive]
17488pub enum WillChange {
17489 Auto,
17491 Contents,
17493 ScrollPosition,
17495 Raw(Raw),
17497}
17498
17499impl fmt::Display for WillChange {
17500 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17501 match self {
17502 Self::Auto => f.write_str("auto"),
17503 Self::Contents => f.write_str("contents"),
17504 Self::ScrollPosition => f.write_str("scroll-position"),
17505 Self::Raw(v) => v.fmt(f),
17506 }
17507 }
17508}
17509
17510impl From<Raw> for WillChange {
17511 fn from(v: Raw) -> Self {
17512 Self::Raw(v)
17513 }
17514}
17515
17516#[derive(Debug, Clone, PartialEq)]
17518#[non_exhaustive]
17519pub enum WindowDrag {
17520 Move,
17522 None,
17524}
17525
17526impl fmt::Display for WindowDrag {
17527 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17528 match self {
17529 Self::Move => f.write_str("move"),
17530 Self::None => f.write_str("none"),
17531 }
17532 }
17533}
17534
17535#[derive(Debug, Clone, PartialEq)]
17537#[non_exhaustive]
17538pub enum WordBreak {
17539 AutoPhrase,
17541 BreakAll,
17543 BreakWord,
17545 KeepAll,
17547 Normal,
17549}
17550
17551impl fmt::Display for WordBreak {
17552 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17553 match self {
17554 Self::AutoPhrase => f.write_str("auto-phrase"),
17555 Self::BreakAll => f.write_str("break-all"),
17556 Self::BreakWord => f.write_str("break-word"),
17557 Self::KeepAll => f.write_str("keep-all"),
17558 Self::Normal => f.write_str("normal"),
17559 }
17560 }
17561}
17562
17563#[derive(Debug, Clone, PartialEq)]
17565#[non_exhaustive]
17566pub enum WordSpacing {
17567 Normal,
17569 Length(Length),
17571}
17572
17573impl fmt::Display for WordSpacing {
17574 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17575 match self {
17576 Self::Normal => f.write_str("normal"),
17577 Self::Length(v) => v.fmt(f),
17578 }
17579 }
17580}
17581
17582impl From<Length> for WordSpacing {
17583 fn from(v: Length) -> Self {
17584 Self::Length(v)
17585 }
17586}
17587
17588#[derive(Debug, Clone, PartialEq)]
17590#[non_exhaustive]
17591pub enum WordWrap {
17592 BreakWord,
17594 Normal,
17596}
17597
17598impl fmt::Display for WordWrap {
17599 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17600 match self {
17601 Self::BreakWord => f.write_str("break-word"),
17602 Self::Normal => f.write_str("normal"),
17603 }
17604 }
17605}
17606
17607#[derive(Debug, Clone, PartialEq)]
17609#[non_exhaustive]
17610pub enum WritingMode {
17611 HorizontalTb,
17613 SidewaysLr,
17615 SidewaysRl,
17617 VerticalLr,
17619 VerticalRl,
17621}
17622
17623impl fmt::Display for WritingMode {
17624 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17625 match self {
17626 Self::HorizontalTb => f.write_str("horizontal-tb"),
17627 Self::SidewaysLr => f.write_str("sideways-lr"),
17628 Self::SidewaysRl => f.write_str("sideways-rl"),
17629 Self::VerticalLr => f.write_str("vertical-lr"),
17630 Self::VerticalRl => f.write_str("vertical-rl"),
17631 }
17632 }
17633}
17634
17635#[derive(Debug, Clone, PartialEq)]
17637#[non_exhaustive]
17638pub enum X {
17639 Length(Length),
17641 Percentage(Percentage),
17643}
17644
17645impl fmt::Display for X {
17646 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17647 match self {
17648 Self::Length(v) => v.fmt(f),
17649 Self::Percentage(v) => v.fmt(f),
17650 }
17651 }
17652}
17653
17654impl From<Length> for X {
17655 fn from(v: Length) -> Self {
17656 Self::Length(v)
17657 }
17658}
17659
17660impl From<Percentage> for X {
17661 fn from(v: Percentage) -> Self {
17662 Self::Percentage(v)
17663 }
17664}
17665
17666#[derive(Debug, Clone, PartialEq)]
17668#[non_exhaustive]
17669pub enum Y {
17670 Length(Length),
17672 Percentage(Percentage),
17674}
17675
17676impl fmt::Display for Y {
17677 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17678 match self {
17679 Self::Length(v) => v.fmt(f),
17680 Self::Percentage(v) => v.fmt(f),
17681 }
17682 }
17683}
17684
17685impl From<Length> for Y {
17686 fn from(v: Length) -> Self {
17687 Self::Length(v)
17688 }
17689}
17690
17691impl From<Percentage> for Y {
17692 fn from(v: Percentage) -> Self {
17693 Self::Percentage(v)
17694 }
17695}
17696
17697#[derive(Debug, Clone, PartialEq)]
17699#[non_exhaustive]
17700pub enum ZIndex {
17701 Auto,
17703 Integer(i32),
17705}
17706
17707impl fmt::Display for ZIndex {
17708 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17709 match self {
17710 Self::Auto => f.write_str("auto"),
17711 Self::Integer(v) => v.fmt(f),
17712 }
17713 }
17714}
17715
17716impl From<i32> for ZIndex {
17717 fn from(v: i32) -> Self {
17718 Self::Integer(v)
17719 }
17720}
17721
17722#[derive(Debug, Clone, PartialEq)]
17724#[non_exhaustive]
17725pub enum Zoom {
17726 Normal,
17728 Reset,
17730 Percentage(Percentage),
17732 Number(f64),
17734 Raw(Raw),
17736}
17737
17738impl fmt::Display for Zoom {
17739 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
17740 match self {
17741 Self::Normal => f.write_str("normal"),
17742 Self::Reset => f.write_str("reset"),
17743 Self::Percentage(v) => v.fmt(f),
17744 Self::Number(v) => v.fmt(f),
17745 Self::Raw(v) => v.fmt(f),
17746 }
17747 }
17748}
17749
17750impl From<Percentage> for Zoom {
17751 fn from(v: Percentage) -> Self {
17752 Self::Percentage(v)
17753 }
17754}
17755
17756impl From<f64> for Zoom {
17757 fn from(v: f64) -> Self {
17758 Self::Number(v)
17759 }
17760}
17761
17762impl From<i32> for Zoom {
17763 fn from(v: i32) -> Self {
17764 Self::Number(f64::from(v))
17765 }
17766}
17767
17768impl From<Raw> for Zoom {
17769 fn from(v: Raw) -> Self {
17770 Self::Raw(v)
17771 }
17772}
17773
17774impl Color {
17775 pub const ALICEBLUE: Self = Self::named("aliceblue");
17777 pub const ANTIQUEWHITE: Self = Self::named("antiquewhite");
17779 pub const AQUA: Self = Self::named("aqua");
17781 pub const AQUAMARINE: Self = Self::named("aquamarine");
17783 pub const AZURE: Self = Self::named("azure");
17785 pub const BEIGE: Self = Self::named("beige");
17787 pub const BISQUE: Self = Self::named("bisque");
17789 pub const BLACK: Self = Self::named("black");
17791 pub const BLANCHEDALMOND: Self = Self::named("blanchedalmond");
17793 pub const BLUE: Self = Self::named("blue");
17795 pub const BLUEVIOLET: Self = Self::named("blueviolet");
17797 pub const BROWN: Self = Self::named("brown");
17799 pub const BURLYWOOD: Self = Self::named("burlywood");
17801 pub const CADETBLUE: Self = Self::named("cadetblue");
17803 pub const CHARTREUSE: Self = Self::named("chartreuse");
17805 pub const CHOCOLATE: Self = Self::named("chocolate");
17807 pub const CORAL: Self = Self::named("coral");
17809 pub const CORNFLOWERBLUE: Self = Self::named("cornflowerblue");
17811 pub const CORNSILK: Self = Self::named("cornsilk");
17813 pub const CRIMSON: Self = Self::named("crimson");
17815 pub const CYAN: Self = Self::named("cyan");
17817 pub const DARKBLUE: Self = Self::named("darkblue");
17819 pub const DARKCYAN: Self = Self::named("darkcyan");
17821 pub const DARKGOLDENROD: Self = Self::named("darkgoldenrod");
17823 pub const DARKGRAY: Self = Self::named("darkgray");
17825 pub const DARKGREEN: Self = Self::named("darkgreen");
17827 pub const DARKGREY: Self = Self::named("darkgrey");
17829 pub const DARKKHAKI: Self = Self::named("darkkhaki");
17831 pub const DARKMAGENTA: Self = Self::named("darkmagenta");
17833 pub const DARKOLIVEGREEN: Self = Self::named("darkolivegreen");
17835 pub const DARKORANGE: Self = Self::named("darkorange");
17837 pub const DARKORCHID: Self = Self::named("darkorchid");
17839 pub const DARKRED: Self = Self::named("darkred");
17841 pub const DARKSALMON: Self = Self::named("darksalmon");
17843 pub const DARKSEAGREEN: Self = Self::named("darkseagreen");
17845 pub const DARKSLATEBLUE: Self = Self::named("darkslateblue");
17847 pub const DARKSLATEGRAY: Self = Self::named("darkslategray");
17849 pub const DARKSLATEGREY: Self = Self::named("darkslategrey");
17851 pub const DARKTURQUOISE: Self = Self::named("darkturquoise");
17853 pub const DARKVIOLET: Self = Self::named("darkviolet");
17855 pub const DEEPPINK: Self = Self::named("deeppink");
17857 pub const DEEPSKYBLUE: Self = Self::named("deepskyblue");
17859 pub const DIMGRAY: Self = Self::named("dimgray");
17861 pub const DIMGREY: Self = Self::named("dimgrey");
17863 pub const DODGERBLUE: Self = Self::named("dodgerblue");
17865 pub const FIREBRICK: Self = Self::named("firebrick");
17867 pub const FLORALWHITE: Self = Self::named("floralwhite");
17869 pub const FORESTGREEN: Self = Self::named("forestgreen");
17871 pub const FUCHSIA: Self = Self::named("fuchsia");
17873 pub const GAINSBORO: Self = Self::named("gainsboro");
17875 pub const GHOSTWHITE: Self = Self::named("ghostwhite");
17877 pub const GOLD: Self = Self::named("gold");
17879 pub const GOLDENROD: Self = Self::named("goldenrod");
17881 pub const GRAY: Self = Self::named("gray");
17883 pub const GREEN: Self = Self::named("green");
17885 pub const GREENYELLOW: Self = Self::named("greenyellow");
17887 pub const GREY: Self = Self::named("grey");
17889 pub const HONEYDEW: Self = Self::named("honeydew");
17891 pub const HOTPINK: Self = Self::named("hotpink");
17893 pub const INDIANRED: Self = Self::named("indianred");
17895 pub const INDIGO: Self = Self::named("indigo");
17897 pub const IVORY: Self = Self::named("ivory");
17899 pub const KHAKI: Self = Self::named("khaki");
17901 pub const LAVENDER: Self = Self::named("lavender");
17903 pub const LAVENDERBLUSH: Self = Self::named("lavenderblush");
17905 pub const LAWNGREEN: Self = Self::named("lawngreen");
17907 pub const LEMONCHIFFON: Self = Self::named("lemonchiffon");
17909 pub const LIGHTBLUE: Self = Self::named("lightblue");
17911 pub const LIGHTCORAL: Self = Self::named("lightcoral");
17913 pub const LIGHTCYAN: Self = Self::named("lightcyan");
17915 pub const LIGHTGOLDENRODYELLOW: Self = Self::named("lightgoldenrodyellow");
17917 pub const LIGHTGRAY: Self = Self::named("lightgray");
17919 pub const LIGHTGREEN: Self = Self::named("lightgreen");
17921 pub const LIGHTGREY: Self = Self::named("lightgrey");
17923 pub const LIGHTPINK: Self = Self::named("lightpink");
17925 pub const LIGHTSALMON: Self = Self::named("lightsalmon");
17927 pub const LIGHTSEAGREEN: Self = Self::named("lightseagreen");
17929 pub const LIGHTSKYBLUE: Self = Self::named("lightskyblue");
17931 pub const LIGHTSLATEGRAY: Self = Self::named("lightslategray");
17933 pub const LIGHTSLATEGREY: Self = Self::named("lightslategrey");
17935 pub const LIGHTSTEELBLUE: Self = Self::named("lightsteelblue");
17937 pub const LIGHTYELLOW: Self = Self::named("lightyellow");
17939 pub const LIME: Self = Self::named("lime");
17941 pub const LIMEGREEN: Self = Self::named("limegreen");
17943 pub const LINEN: Self = Self::named("linen");
17945 pub const MAGENTA: Self = Self::named("magenta");
17947 pub const MAROON: Self = Self::named("maroon");
17949 pub const MEDIUMAQUAMARINE: Self = Self::named("mediumaquamarine");
17951 pub const MEDIUMBLUE: Self = Self::named("mediumblue");
17953 pub const MEDIUMORCHID: Self = Self::named("mediumorchid");
17955 pub const MEDIUMPURPLE: Self = Self::named("mediumpurple");
17957 pub const MEDIUMSEAGREEN: Self = Self::named("mediumseagreen");
17959 pub const MEDIUMSLATEBLUE: Self = Self::named("mediumslateblue");
17961 pub const MEDIUMSPRINGGREEN: Self = Self::named("mediumspringgreen");
17963 pub const MEDIUMTURQUOISE: Self = Self::named("mediumturquoise");
17965 pub const MEDIUMVIOLETRED: Self = Self::named("mediumvioletred");
17967 pub const MIDNIGHTBLUE: Self = Self::named("midnightblue");
17969 pub const MINTCREAM: Self = Self::named("mintcream");
17971 pub const MISTYROSE: Self = Self::named("mistyrose");
17973 pub const MOCCASIN: Self = Self::named("moccasin");
17975 pub const NAVAJOWHITE: Self = Self::named("navajowhite");
17977 pub const NAVY: Self = Self::named("navy");
17979 pub const OLDLACE: Self = Self::named("oldlace");
17981 pub const OLIVE: Self = Self::named("olive");
17983 pub const OLIVEDRAB: Self = Self::named("olivedrab");
17985 pub const ORANGE: Self = Self::named("orange");
17987 pub const ORANGERED: Self = Self::named("orangered");
17989 pub const ORCHID: Self = Self::named("orchid");
17991 pub const PALEGOLDENROD: Self = Self::named("palegoldenrod");
17993 pub const PALEGREEN: Self = Self::named("palegreen");
17995 pub const PALETURQUOISE: Self = Self::named("paleturquoise");
17997 pub const PALEVIOLETRED: Self = Self::named("palevioletred");
17999 pub const PAPAYAWHIP: Self = Self::named("papayawhip");
18001 pub const PEACHPUFF: Self = Self::named("peachpuff");
18003 pub const PERU: Self = Self::named("peru");
18005 pub const PINK: Self = Self::named("pink");
18007 pub const PLUM: Self = Self::named("plum");
18009 pub const POWDERBLUE: Self = Self::named("powderblue");
18011 pub const PURPLE: Self = Self::named("purple");
18013 pub const REBECCAPURPLE: Self = Self::named("rebeccapurple");
18015 pub const RED: Self = Self::named("red");
18017 pub const ROSYBROWN: Self = Self::named("rosybrown");
18019 pub const ROYALBLUE: Self = Self::named("royalblue");
18021 pub const SADDLEBROWN: Self = Self::named("saddlebrown");
18023 pub const SALMON: Self = Self::named("salmon");
18025 pub const SANDYBROWN: Self = Self::named("sandybrown");
18027 pub const SEAGREEN: Self = Self::named("seagreen");
18029 pub const SEASHELL: Self = Self::named("seashell");
18031 pub const SIENNA: Self = Self::named("sienna");
18033 pub const SILVER: Self = Self::named("silver");
18035 pub const SKYBLUE: Self = Self::named("skyblue");
18037 pub const SLATEBLUE: Self = Self::named("slateblue");
18039 pub const SLATEGRAY: Self = Self::named("slategray");
18041 pub const SLATEGREY: Self = Self::named("slategrey");
18043 pub const SNOW: Self = Self::named("snow");
18045 pub const SPRINGGREEN: Self = Self::named("springgreen");
18047 pub const STEELBLUE: Self = Self::named("steelblue");
18049 pub const TAN: Self = Self::named("tan");
18051 pub const TEAL: Self = Self::named("teal");
18053 pub const THISTLE: Self = Self::named("thistle");
18055 pub const TOMATO: Self = Self::named("tomato");
18057 pub const TURQUOISE: Self = Self::named("turquoise");
18059 pub const VIOLET: Self = Self::named("violet");
18061 pub const WHEAT: Self = Self::named("wheat");
18063 pub const WHITE: Self = Self::named("white");
18065 pub const WHITESMOKE: Self = Self::named("whitesmoke");
18067 pub const YELLOW: Self = Self::named("yellow");
18069 pub const YELLOWGREEN: Self = Self::named("yellowgreen");
18071}