This repository was archived by the owner on Dec 18, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 322
Reference tests for display:contents #1129
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,19 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: Generated ::before and ::after on display:contents</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-pass-ref.html"> | ||
<style> | ||
div { display: contents } | ||
.p::before { content: "P" } | ||
.a::before { content: "A" } | ||
.s::after { content: "S" } | ||
</style> | ||
<p>You should see the word PASS below.</p> | ||
<div><!-- | ||
--><div><div class="p"></div></div><!-- | ||
--><div></div><!-- | ||
--><div class="a"></div><!-- | ||
--><div>S<div class="s"></div></div> | ||
</div> |
This file contains hidden or 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,18 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: Generated ::before and ::after with display:contents</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-pass-ref.html"> | ||
<style> | ||
div::before { | ||
display: contents; | ||
content: "P" | ||
} | ||
div::after { | ||
display: contents; | ||
content: "S" | ||
} | ||
</style> | ||
<p>You should see the word PASS below.</p> | ||
<div>AS</div> |
This file contains hidden or 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,18 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: display:contents in block layout</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-pass-no-red-ref.html"> | ||
<style> | ||
#contents { | ||
display: contents; | ||
border: 10px solid red | ||
} | ||
</style> | ||
<p>You should see the word PASS and no red below.</p> | ||
<div> | ||
<div id="contents"> | ||
<div id="inner">PASS</div> | ||
</div> | ||
</div> |
This file contains hidden or 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,6 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Reftest Reference</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<p>You should see the word PASS with a 300px top margin below.</p> | ||
<div style="margin-top: 300px">PASS</div> |
This file contains hidden or 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,20 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: margin collapsing through display:contents</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-block-002-ref.html"> | ||
<style> | ||
#outer { margin-top: 100px } | ||
#inner { margin-top: 300px } | ||
#contents { | ||
display: contents; | ||
margin-top: 2000px | ||
} | ||
</style> | ||
<p>You should see the word PASS with a 300px top margin below.</p> | ||
<div id="outer"> | ||
<div id="contents"> | ||
<div id="inner">PASS</div> | ||
</div> | ||
</div> |
This file contains hidden or 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,17 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: display:contents and ::first-letter</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="help" href="https://drafts.csswg.org/css-pseudo-4/#first-letter-pseudo"> | ||
<link rel="match" href="display-contents-pass-green-no-red-ref.html"> | ||
<style> | ||
#contents { display: contents } | ||
#contents::first-letter { background-color: red } | ||
#container::first-letter { color: green } | ||
span { color: green } | ||
</style> | ||
<p>You should see the word PASS in green and no red below.</p> | ||
<div id="container"> | ||
<div id="contents">P<span>ASS</span></div> | ||
</div> |
This file contains hidden or 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,16 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: display:contents and ::first-line</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="help" href="https://drafts.csswg.org/css-pseudo-4/#first-line-pseudo"> | ||
<link rel="match" href="display-contents-pass-green-no-red-ref.html"> | ||
<style> | ||
#contents { display: contents } | ||
#contents::first-line { background-color: red } | ||
#container::first-line { color: green } | ||
</style> | ||
<p>You should see the word PASS in green and no red below.</p> | ||
<div id="container"> | ||
<div id="contents">PASS</div> | ||
</div> |
This file contains hidden or 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,16 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: display:contents in inline layout</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-pass-no-red-ref.html"> | ||
<style> | ||
#contents { | ||
display: contents; | ||
border: 10px solid red | ||
} | ||
</style> | ||
<p>You should see the word PASS and no red below.</p> | ||
<span> | ||
P<div id="contents">AS</div>S | ||
</span> |
This file contains hidden or 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,6 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Reftest Reference</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<p>You should see the word PASS in green and no red below.</p> | ||
<div style="color:green">PASS</div> |
This file contains hidden or 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,6 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Reftest Reference</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<p>You should see the word PASS and no red below.</p> | ||
<div>PASS</div> |
This file contains hidden or 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,6 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Reftest Reference</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<p>You should see the word PASS below.</p> | ||
PASS |
This file contains hidden or 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,17 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Reftest Reference</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<style> | ||
button, img, input, textarea { | ||
display: contents; | ||
border: 10px solid green | ||
} | ||
</style> | ||
<p>You should see five form inputs, and an orange image, with green border below.</p> | ||
<button>Button</button> | ||
<input type="text" value="text"></input> | ||
<input type="file"></input> | ||
<input type="password" value="password"></input> | ||
<textarea>textarea</textarea> | ||
<img src="support/swatch-orange.png"> |
This file contains hidden or 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,19 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: display:contents and replaced elements</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-replaced-001-ref.html"> | ||
<style> | ||
button, img, input, textarea { | ||
display: contents; | ||
border: 10px solid green | ||
} | ||
</style> | ||
<p>You should see five form inputs, and an orange image, with green border below.</p> | ||
<button>Button</button> | ||
<input type="text" value="text"></input> | ||
<input type="file"></input> | ||
<input type="password" value="password"></input> | ||
<textarea>textarea</textarea> | ||
<img src="support/swatch-orange.png"> |
This file contains hidden or 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,18 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: Children of multiple td elements with display:contents wrapped in single anonymous table cell</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-pass-ref.html"> | ||
<style> | ||
td { | ||
display: contents; | ||
padding-right: 3em | ||
} | ||
</style> | ||
<p>You should see the word PASS below.</p> | ||
<table cellpadding="0" cellspacing="0"> | ||
<tr> | ||
<td>P</td><td>A</td><td>S</td><td>S</td> | ||
</tr> | ||
</table> |
This file contains hidden or 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,18 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8"> | ||
<title>CSS Display: td elements wrapped in single anonymous table-row with display:contents tr</title> | ||
<link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> | ||
<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents"> | ||
<link rel="match" href="display-contents-pass-ref.html"> | ||
<style> | ||
tr { display: contents } | ||
</style> | ||
<p>You should see the word PASS below.</p> | ||
<table cellpadding="0" cellspacing="0"> | ||
<tr> | ||
<td>PA</td> | ||
</tr> | ||
<tr> | ||
<td>SS</td> | ||
</tr> | ||
</table> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(This test seems to fail in Gecko, though that seems like a bug in Gecko. Filed https://bugzilla.mozilla.org/show_bug.cgi?id=1305951 )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ack