mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:47:35 +00:00
LibWeb: Add CSS property 'border'
This makes it possible to write shorter CSS. Instead of writing .foo { border-width: 3px; border-style: solid; border-color: blue; } it is now possible to write .foo { border: 3px solid blue; } while the order of values is irrelevant. Currently only the basic values are supported. More values should be added in the future. Three more value specific parse functions were added: parse_line_width, parse_color, and parse_line_style Additionally a few test cases were added to borders.html.
This commit is contained in:
parent
12e8efd74e
commit
0891f860f7
4 changed files with 205 additions and 0 deletions
|
@ -35,4 +35,8 @@ RefPtr<StyleSheet> parse_css(const StringView&);
|
|||
RefPtr<StyleDeclaration> parse_css_declaration(const StringView&);
|
||||
NonnullRefPtr<StyleValue> parse_css_value(const StringView&);
|
||||
|
||||
RefPtr<StyleValue> parse_line_width(const StringView&);
|
||||
RefPtr<StyleValue> parse_color(const StringView&);
|
||||
RefPtr<StyleValue> parse_line_style(const StringView&);
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue