mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibWeb: Resolve accent-color property
This commit is contained in:
parent
0374b42f20
commit
6a51ef9c9b
Notes:
sideshowbarker
2024-07-17 07:20:49 +09:00
Author: https://github.com/AtkinsSJ
Commit: 6a51ef9c9b
Pull-request: https://github.com/SerenityOS/serenity/pull/19092
1 changed files with 6 additions and 0 deletions
|
@ -229,6 +229,12 @@ static ErrorOr<NonnullRefPtr<StyleValue const>> style_value_for_size(Size const&
|
|||
ErrorOr<RefPtr<StyleValue const>> ResolvedCSSStyleDeclaration::style_value_for_property(Layout::NodeWithStyle const& layout_node, PropertyID property_id) const
|
||||
{
|
||||
switch (property_id) {
|
||||
case PropertyID::AccentColor: {
|
||||
auto accent_color = layout_node.computed_values().accent_color();
|
||||
if (accent_color.has_value())
|
||||
return TRY(ColorStyleValue::create(accent_color.value()));
|
||||
return TRY(IdentifierStyleValue::create(ValueID::Auto));
|
||||
}
|
||||
case PropertyID::Background: {
|
||||
auto maybe_background_color = property(PropertyID::BackgroundColor);
|
||||
auto maybe_background_image = property(PropertyID::BackgroundImage);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue