1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 06:47:35 +00:00

LibWeb: Add roman numerals as a list-style for ol's

This patch adds support for the identifiers upper-roman and lower-roman
of the list-style property.
This commit is contained in:
Tobias Christiansen 2021-07-04 17:17:23 +02:00 committed by Andreas Kling
parent 87033ce7d1
commit e18e2af826
4 changed files with 17 additions and 0 deletions

View file

@ -107,6 +107,7 @@
"lowercase",
"lower-alpha",
"lower-latin",
"lower-roman",
"medium",
"move",
"ne-resize",
@ -163,6 +164,7 @@
"uppercase",
"upper-alpha",
"upper-latin",
"upper-roman",
"visible",
"vertical-text",
"wait",

View file

@ -645,6 +645,10 @@ Optional<CSS::ListStyleType> StyleProperties::list_style_type() const
return CSS::ListStyleType::UpperAlpha;
case CSS::ValueID::UpperLatin:
return CSS::ListStyleType::UpperLatin;
case CSS::ValueID::UpperRoman:
return CSS::ListStyleType::UpperRoman;
case CSS::ValueID::LowerRoman:
return CSS::ListStyleType::LowerRoman;
default:
return {};
}

View file

@ -1,5 +1,6 @@
/*
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
* Copyright (c) 2021, Tobias Christiansen <tobi@tobyase.de>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
@ -173,8 +174,10 @@ enum class ListStyleType {
DecimalLeadingZero,
LowerAlpha,
LowerLatin,
LowerRoman,
UpperAlpha,
UpperLatin,
UpperRoman,
};
enum class Overflow : u8 {