mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-19 15:32:31 +00:00
LibWeb: Rename IdentifierStyleValue -> CSSKeywordValue
This matches the name in the CSS Typed OM spec. https://drafts.css-houdini.org/css-typed-om-1/#csskeywordvalue
This commit is contained in:
parent
0e3487b9ab
commit
9559f0f123
Notes:
github-actions[bot]
2024-08-15 12:59:38 +00:00
Author: https://github.com/AtkinsSJ
Commit: 9559f0f123
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1076
25 changed files with 137 additions and 136 deletions
|
@ -7,7 +7,7 @@
|
|||
#include <LibWeb/Bindings/HTMLDivElementPrototype.h>
|
||||
#include <LibWeb/Bindings/Intrinsics.h>
|
||||
#include <LibWeb/CSS/StyleProperties.h>
|
||||
#include <LibWeb/CSS/StyleValues/IdentifierStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSKeywordValue.h>
|
||||
#include <LibWeb/HTML/HTMLDivElement.h>
|
||||
|
||||
namespace Web::HTML {
|
||||
|
@ -27,13 +27,13 @@ void HTMLDivElement::apply_presentational_hints(CSS::StyleProperties& style) con
|
|||
for_each_attribute([&](auto& name, auto& value) {
|
||||
if (name.equals_ignoring_ascii_case("align"sv)) {
|
||||
if (value.equals_ignoring_ascii_case("left"sv))
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::IdentifierStyleValue::create(CSS::ValueID::LibwebLeft));
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::CSSKeywordValue::create(CSS::ValueID::LibwebLeft));
|
||||
else if (value.equals_ignoring_ascii_case("right"sv))
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::IdentifierStyleValue::create(CSS::ValueID::LibwebRight));
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::CSSKeywordValue::create(CSS::ValueID::LibwebRight));
|
||||
else if (value.equals_ignoring_ascii_case("center"sv))
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::IdentifierStyleValue::create(CSS::ValueID::LibwebCenter));
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::CSSKeywordValue::create(CSS::ValueID::LibwebCenter));
|
||||
else if (value.equals_ignoring_ascii_case("justify"sv))
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::IdentifierStyleValue::create(CSS::ValueID::Justify));
|
||||
style.set_property(CSS::PropertyID::TextAlign, CSS::CSSKeywordValue::create(CSS::ValueID::Justify));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue