forked from SerenityOS/serenity
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
LibWeb: Support CSS font shorthand with up to 4 consecutive
normal
All of the following properties in the font shorthand can be `normal`: - font-style - font-variant - font-weight - font-stretch This means that we must allow up to four consecutive `normal` at the start of a font shorthand value.
- Loading branch information
1 parent
f33baa3
commit a5b1c50
Showing
3 changed files
with
41 additions
and
1 deletion.
There are no files selected for viewing
30 changes: 30 additions & 0 deletions
30
Tests/LibWeb/Layout/expected/font-with-many-normal-values.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
Viewport <#document> at (0,0) content-size 800x600 children: not-inline | ||
BlockContainer <html> at (0,0) content-size 800x216 [BFC] children: not-inline | ||
BlockContainer <body> at (8,8) content-size 784x200 children: inline | ||
line 0 width: 424, height: 200, bottom: 200, baseline: 159.960937 | ||
frag 0 from TextNode start: 0, length: 1, rect: [8,8 79.296875x200] | ||
"1" | ||
frag 1 from TextNode start: 0, length: 1, rect: [87,154 8x17.46875] | ||
" " | ||
frag 2 from TextNode start: 0, length: 1, rect: [95,8 110.15625x200] | ||
"2" | ||
frag 3 from TextNode start: 0, length: 1, rect: [205,154 8x17.46875] | ||
" " | ||
frag 4 from TextNode start: 0, length: 1, rect: [213,8 113.671875x200] | ||
"3" | ||
frag 5 from TextNode start: 0, length: 1, rect: [327,154 8x17.46875] | ||
" " | ||
frag 6 from TextNode start: 0, length: 1, rect: [335,8 96.875x200] | ||
"4" | ||
InlineNode <span.one> | ||
TextNode <#text> | ||
TextNode <#text> | ||
InlineNode <span.two> | ||
TextNode <#text> | ||
TextNode <#text> | ||
InlineNode <span.three> | ||
TextNode <#text> | ||
TextNode <#text> | ||
InlineNode <span.four> | ||
TextNode <#text> | ||
TextNode <#text> |
10 changes: 10 additions & 0 deletions
10
Tests/LibWeb/Layout/input/font-with-many-normal-values.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<!doctype html><style> | ||
.one { font: normal 200px/1 SerenitySans; } | ||
.two { font: normal normal 200px/1 SerenitySans; } | ||
.three { font: normal normal normal 200px/1 SerenitySans; } | ||
.four { font: normal normal normal normal 200px/1 SerenitySans; } | ||
</style> | ||
<span class=one>1</span> | ||
<span class=two>2</span> | ||
<span class=three>3</span> | ||
<span class=four>4</span> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters