mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-29 19:10:26 +00:00
LibWeb: Turn <td width> into a CSS width property
This commit is contained in:
parent
38d6cc8598
commit
b8dc1fc195
Notes:
sideshowbarker
2024-07-19 05:20:32 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/b8dc1fc1953
1 changed files with 6 additions and 0 deletions
|
@ -25,6 +25,7 @@
|
|||
*/
|
||||
|
||||
#include <LibWeb/DOM/HTMLTableCellElement.h>
|
||||
#include <LibWeb/Parser/CSSParser.h>
|
||||
|
||||
namespace Web {
|
||||
|
||||
|
@ -53,6 +54,11 @@ void HTMLTableCellElement::apply_presentational_hints(StyleProperties& style) co
|
|||
style.set_property(CSS::PropertyID::TextAlign, value.view());
|
||||
return;
|
||||
}
|
||||
if (name == HTML::AttributeNames::width) {
|
||||
if (auto parsed_value = parse_css_value(CSS::ParsingContext(document()), value))
|
||||
style.set_property(CSS::PropertyID::Width, parsed_value.release_nonnull());
|
||||
return;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue