Skip to content

Commit

Permalink
feat(css_parser): add parsing css modules @value at rule (#2985)
Browse files Browse the repository at this point in the history
  • Loading branch information
denbezrukov committed May 27, 2024
1 parent fec262f commit e52084a
Show file tree
Hide file tree
Showing 56 changed files with 3,591 additions and 366 deletions.
4 changes: 4 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions crates/biome_configuration/src/css.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ pub struct CssParser {
/// Allow comments to appear on incorrect lines in `.css` files
#[partial(bpaf(hide))]
pub allow_wrong_line_comments: bool,

/// Enables parsing of CSS Modules specific features.
#[partial(bpaf(hide))]
pub css_modules: bool,
}

/// Options that changes how the CSS formatter behaves
Expand Down
125 changes: 125 additions & 0 deletions crates/biome_css_factory/src/generated/node_factory.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

189 changes: 188 additions & 1 deletion crates/biome_css_factory/src/generated/syntax_factory.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions crates/biome_css_formatter/src/css/any/at_rule.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ impl FormatRule<AnyCssAtRule> for FormatAnyCssAtRule {
AnyCssAtRule::CssScopeAtRule(node) => node.format().fmt(f),
AnyCssAtRule::CssStartingStyleAtRule(node) => node.format().fmt(f),
AnyCssAtRule::CssSupportsAtRule(node) => node.format().fmt(f),
AnyCssAtRule::CssValueAtRule(node) => node.format().fmt(f),
}
}
}
4 changes: 4 additions & 0 deletions crates/biome_css_formatter/src/css/any/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,7 @@ pub(crate) mod supports_or_combinable_condition;
pub(crate) mod url_modifier;
pub(crate) mod url_value;
pub(crate) mod value;
pub(crate) mod value_at_rule_clause;
pub(crate) mod value_at_rule_import_source;
pub(crate) mod value_at_rule_import_specifier;
pub(crate) mod value_at_rule_property;
Loading

0 comments on commit e52084a

Please sign in to comment.