swc_css_codegen/
list.rs

1#![allow(non_upper_case_globals)]
2use bitflags::bitflags;
3
4bitflags! {
5    #[derive(PartialEq, Eq, Copy, Clone)]
6    pub struct ListFormat: u16 {
7        const None = 0;
8
9        // Line separators
10        /// Prints the list on a single line (default).
11        const SingleLine = 0;
12        /// Prints the list on multiple lines.
13        const MultiLine = 1 << 0;
14        /// Prints the list using line preservation if possible.
15        const PreserveLines = 1 << 1;
16        const LinesMask = Self::MultiLine.bits() | Self::PreserveLines.bits();
17
18        // Delimiters
19        const NotDelimited = 0;
20        const SpaceDelimited = 1 << 2;
21        /// There is no delimiter between list items (default).
22        const SemiDelimited = 1 << 3;
23        const CommaDelimited = 1 << 4;
24        const DotDelimited = 1 << 5;
25        const DelimitersMask = Self::SpaceDelimited.bits()
26            | Self::SemiDelimited.bits()
27            | Self::CommaDelimited.bits()
28            | Self::DotDelimited.bits();
29    }
30}