@@ -3318,7 +3318,7 @@ RefPtr<StyleValue> Parser::parse_border_radius_shorthand_value(Vector<StyleCompo
3318
3318
return StyleValueList::create (move (border_radii), StyleValueList::Separator::Space);
3319
3319
}
3320
3320
3321
- RefPtr<StyleValue> Parser::parse_box_shadow_value (Vector<StyleComponentValueRule> const & component_values)
3321
+ RefPtr<StyleValue> Parser::parse_shadow_value (Vector<StyleComponentValueRule> const & component_values)
3322
3322
{
3323
3323
// "none"
3324
3324
if (component_values.size () == 1 && component_values.first ().is (Token::Type::Ident)) {
@@ -3328,11 +3328,11 @@ RefPtr<StyleValue> Parser::parse_box_shadow_value(Vector<StyleComponentValueRule
3328
3328
}
3329
3329
3330
3330
return parse_comma_separated_value_list (component_values, [this ](auto & tokens) {
3331
- return parse_single_box_shadow_value (tokens);
3331
+ return parse_single_shadow_value (tokens);
3332
3332
});
3333
3333
}
3334
3334
3335
- RefPtr<StyleValue> Parser::parse_single_box_shadow_value (TokenStream<StyleComponentValueRule>& tokens)
3335
+ RefPtr<StyleValue> Parser::parse_single_shadow_value (TokenStream<StyleComponentValueRule>& tokens)
3336
3336
{
3337
3337
auto start_position = tokens.position ();
3338
3338
auto error = [&]() {
@@ -3345,7 +3345,7 @@ RefPtr<StyleValue> Parser::parse_single_box_shadow_value(TokenStream<StyleCompon
3345
3345
Optional<Length> offset_y;
3346
3346
Optional<Length> blur_radius;
3347
3347
Optional<Length> spread_distance;
3348
- Optional<BoxShadowPlacement > placement;
3348
+ Optional<ShadowPlacement > placement;
3349
3349
3350
3350
while (tokens.has_next_token ()) {
3351
3351
auto & token = tokens.peek_token ();
@@ -3398,7 +3398,7 @@ RefPtr<StyleValue> Parser::parse_single_box_shadow_value(TokenStream<StyleCompon
3398
3398
if (token.is (Token::Type::Ident) && token.token ().ident ().equals_ignoring_case (" inset" sv)) {
3399
3399
if (placement.has_value ())
3400
3400
return error ();
3401
- placement = BoxShadowPlacement ::Inner;
3401
+ placement = ShadowPlacement ::Inner;
3402
3402
tokens.next_token ();
3403
3403
continue ;
3404
3404
}
@@ -3425,9 +3425,9 @@ RefPtr<StyleValue> Parser::parse_single_box_shadow_value(TokenStream<StyleCompon
3425
3425
3426
3426
// Placement is outer by default
3427
3427
if (!placement.has_value ())
3428
- placement = BoxShadowPlacement ::Outer;
3428
+ placement = ShadowPlacement ::Outer;
3429
3429
3430
- return BoxShadowStyleValue ::create (color.release_value (), offset_x.release_value (), offset_y.release_value (), blur_radius.release_value (), spread_distance.release_value (), placement.release_value ());
3430
+ return ShadowStyleValue ::create (color.release_value (), offset_x.release_value (), offset_y.release_value (), blur_radius.release_value (), spread_distance.release_value (), placement.release_value ());
3431
3431
}
3432
3432
3433
3433
RefPtr<StyleValue> Parser::parse_content_value (Vector<StyleComponentValueRule> const & component_values)
@@ -4248,7 +4248,7 @@ Result<NonnullRefPtr<StyleValue>, Parser::ParsingResult> Parser::parse_css_value
4248
4248
return parsed_value.release_nonnull ();
4249
4249
return ParsingResult::SyntaxError;
4250
4250
case PropertyID::BoxShadow:
4251
- if (auto parsed_value = parse_box_shadow_value (component_values))
4251
+ if (auto parsed_value = parse_shadow_value (component_values))
4252
4252
return parsed_value.release_nonnull ();
4253
4253
return ParsingResult::SyntaxError;
4254
4254
case PropertyID::Content:
0 commit comments