mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-25 17:15:44 +00:00
LibWeb: Turn <td width> into a CSS width property
This commit is contained in:
@@ -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;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user