mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-03 06:40:05 +00:00
LibWeb: Implement ::file-selector-button
pseudo element
The button for a file input now matches `::file-selector-button`.
This commit is contained in:
parent
c817eb8d2b
commit
fdee82d203
Notes:
github-actions[bot]
2024-12-05 10:50:48 +00:00
Author: https://github.com/lukewarlow 🔰
Commit: fdee82d203
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2666
Reviewed-by: https://github.com/AtkinsSJ ✅
Reviewed-by: https://github.com/Psychpsyo
Reviewed-by: https://github.com/tcl3
8 changed files with 48 additions and 1 deletions
|
@ -986,6 +986,8 @@ void HTMLInputElement::create_file_input_shadow_tree()
|
|||
auto shadow_root = realm.create<DOM::ShadowRoot>(document(), *this, Bindings::ShadowRootMode::Closed);
|
||||
|
||||
m_file_button = DOM::create_element(document(), HTML::TagNames::button, Namespace::HTML).release_value_but_fixme_should_propagate_errors();
|
||||
m_file_button->set_use_pseudo_element(CSS::Selector::PseudoElement::Type::FileSelectorButton);
|
||||
|
||||
m_file_label = DOM::create_element(document(), HTML::TagNames::label, Namespace::HTML).release_value_but_fixme_should_propagate_errors();
|
||||
MUST(m_file_label->set_attribute(HTML::AttributeNames::style, "padding-left: 4px;"_string));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue