mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibWeb: Implement CSSImportRule.supportsText
Returns the supports condition specified by the given import at-rule.
This commit is contained in:
parent
c37a47f76f
commit
5d57723ebf
Notes:
github-actions[bot]
2025-03-19 15:43:53 +00:00
Author: https://github.com/tcl3
Commit: 5d57723ebf
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4001
Reviewed-by: https://github.com/AtkinsSJ
Reviewed-by: https://github.com/gmta ✅
7 changed files with 35 additions and 3 deletions
|
@ -291,9 +291,11 @@ OwnPtr<BooleanExpression> Parser::parse_supports_feature(TokenStream<ComponentVa
|
|||
// FIXME: Parsing and then converting back to a string is weird.
|
||||
if (auto declaration = consume_a_declaration(block_tokens); declaration.has_value()) {
|
||||
transaction.commit();
|
||||
return Supports::Declaration::create(
|
||||
auto supports_declaration = Supports::Declaration::create(
|
||||
declaration->to_string(),
|
||||
convert_to_style_property(*declaration).has_value());
|
||||
|
||||
return BooleanExpressionInParens::create(supports_declaration.release_nonnull<BooleanExpression>());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue