Skip to content

Commit

Permalink
Add WPT reftests for handling of <newline> and <tab> when font-size i…
Browse files Browse the repository at this point in the history
…s zero.

Differential Revision: https://phabricator.services.mozilla.com/D59628

bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1606305
gecko-commit: a4caf68a8938dab269d1baee5291bddb71cdd3b8
gecko-integration-branch: autoland
gecko-reviewers: emilio
  • Loading branch information
jfkthame authored and moz-wptsync-bot committed Jan 14, 2020
1 parent 04020fc commit b8760ac
Show file tree
Hide file tree
Showing 4 changed files with 74 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<!DOCTYPE html>
<meta charset=utf-8>
<title>CSS Text test reference</title>
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com">
<style>
pre {
font-size: 12px;
float: left;
border: 1px solid black;
margin: 12px;
}
</style>
<pre>
foo
bar
</pre>
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<meta charset=utf-8>
<title>CSS Text test reference</title>
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com">
<style>
pre {
font-size: 12px;
float: left;
border: 1px solid black;
margin: 12px;
-moz-tab-size: 100px;
tab-size: 100px;
}
</style>
<pre>
<span>foo</span>&#x9;<span>bar</span>
</pre>
20 changes: 20 additions & 0 deletions css/css-text/white-space/white-space-zero-fontsize-001.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<!DOCTYPE html>
<meta charset=utf-8>
<title>CSS Text Test: preserved white space with zero font-size</title>
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com">
<link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-property">
<link rel="match" href="reference/white-space-zero-fontsize-001-ref.html">
<meta name="assert" content="Forced line break in preserved white space is respected even when font-size is zero">
<style>
pre {
font-size: 0;
float: left;
border: 1px solid black;
margin: 12px;
}
span { font-size: 12px; }
</style>
<pre>
<span>foo</span>
<span>bar</span>
</pre>
21 changes: 21 additions & 0 deletions css/css-text/white-space/white-space-zero-fontsize-002.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<meta charset=utf-8>
<title>CSS Text Test: preserved white space with zero font-size</title>
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com">
<link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-property">
<link rel="match" href="reference/white-space-zero-fontsize-002-ref.html">
<meta name="assert" content="Tab in preserved white space is respected even when font-size is zero">
<style>
pre {
font-size: 0;
float: left;
border: 1px solid black;
margin: 12px;
-moz-tab-size: 100px;
tab-size: 100px;
}
span { font-size: 12px; }
</style>
<pre>
<span>foo</span>&#x9;<span>bar</span>
</pre>

0 comments on commit b8760ac

Please sign in to comment.