mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-03 04:52:06 +02:00
LibWeb: Re-evaluate the style block when the type attribute changes
This commit is contained in:
committed by
Andreas Kling
parent
4d17707b26
commit
bd9d489370
Notes:
github-actions[bot]
2025-04-28 23:01:58 +00:00
Author: https://github.com/h2337 🔰 Commit: https://github.com/LadybirdBrowser/ladybird/commit/bd9d4893709 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4511
@@ -59,6 +59,8 @@ void HTMLStyleElement::attribute_changed(FlyString const& name, Optional<String>
|
||||
if (name == HTML::AttributeNames::media) {
|
||||
if (auto* sheet = m_style_element_utils.sheet())
|
||||
sheet->set_media(value.value_or({}));
|
||||
} else if (name == HTML::AttributeNames::type) {
|
||||
m_style_element_utils.update_a_style_block(*this);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user