mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 04:39:06 +00:00
LibWeb: Update stylesheet media value when changing link media attribute
This commit is contained in:
parent
b92abe5c26
commit
00f75648e5
Notes:
github-actions[bot]
2024-08-13 12:13:49 +00:00
Author: https://github.com/vpzomtrrfrt
Commit: 00f75648e5
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1034
5 changed files with 38 additions and 0 deletions
|
@ -187,6 +187,10 @@ void HTMLLinkElement::attribute_changed(FlyString const& name, Optional<String>
|
|||
)) {
|
||||
fetch_and_process_linked_resource();
|
||||
}
|
||||
|
||||
if (name == HTML::AttributeNames::media && m_loaded_style_sheet) {
|
||||
m_loaded_style_sheet->set_media(value.value_or(String {}));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue