mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-26 06:18:59 +00:00
LibWeb: Replace ::-webkit pseudo-elements with ones from CSS Forms spec
This spec is very early on, and likely to change. However, it still feels preferable to use these rather than the prefixed -webkit ones. Plus, as we have a `::fill` on range inputs, we can use that for styling the bar instead of inserting CSS from C++.
This commit is contained in:
parent
f5a6704219
commit
3ebdb64fed
Notes:
github-actions[bot]
2025-03-19 10:11:17 +00:00
Author: https://github.com/AtkinsSJ
Commit: 3ebdb64fed
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3991
6 changed files with 85 additions and 81 deletions
|
@ -118,11 +118,11 @@ void HTMLProgressElement::create_shadow_tree_if_needed()
|
|||
set_shadow_root(shadow_root);
|
||||
|
||||
auto progress_bar_element = MUST(DOM::create_element(document(), HTML::TagNames::div, Namespace::HTML));
|
||||
progress_bar_element->set_use_pseudo_element(CSS::Selector::PseudoElement::Type::ProgressBar);
|
||||
progress_bar_element->set_use_pseudo_element(CSS::Selector::PseudoElement::Type::Track);
|
||||
MUST(shadow_root->append_child(*progress_bar_element));
|
||||
|
||||
m_progress_value_element = MUST(DOM::create_element(document(), HTML::TagNames::div, Namespace::HTML));
|
||||
m_progress_value_element->set_use_pseudo_element(CSS::Selector::PseudoElement::Type::ProgressValue);
|
||||
m_progress_value_element->set_use_pseudo_element(CSS::Selector::PseudoElement::Type::Fill);
|
||||
MUST(progress_bar_element->append_child(*m_progress_value_element));
|
||||
update_progress_value_element();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue