Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <h1>Tables test</h1>
<p>Safari 10 and VoiceOver, January 2017.</p>
<p>
	In these tables, I've intentionally omitted to use any semantic element or attribute. There are no "th" elements, no "scope" attibutes, etc. The only difference is about the number of table columns and the presence or absence of a border.
</p>
<p>
	To test this page there's no need to use a screen reader. In the Safari 10 Web Inspector, select a table, then open the "Accessibility" panel in the "Node" tab and check what is the role reported. Not surprisingly, tables without borders get reported without a specific role. Only the ones with a border, either set in the HTML or with CSS, get a "table" role.
</p>

<p>
	As a consequence, VoiceOver reads the tables without borders ignoring the fact that the content is inside of a table. No information about the number of columns or rows gets announced at all.
</p>

<h2>Table with 3 columns</h2>

<table>
<tr>
	<td></td>
	<td>John</td>
	<td>Mary</td>
</tr>
<tr>
	<td>Coffee</td>
	<td>1</td>
	<td>3</td>
</tr>
<tr>
	<td>Sugar</td>
	<td>0</td>
	<td>1</td>
</tr>
</table>

<p>
	Safari 10: No exact ARIA role match.
</p>

<h2>Table with 3 columns and borders</h2>

<table border="1">
<tr>
	<td></td>
	<td>John</td>
	<td>Mary</td>
</tr>
<tr>
	<td>Coffee</td>
	<td>1</td>
	<td>3</td>
</tr>
<tr>
	<td>Sugar</td>
	<td>0</td>
	<td>1</td>
</tr>
</table>

<p>
	Safari 10: Role table (default).
</p>

<h2>Table with 3 columns and CSS border</h2>

<table class="bordered">
<tr>
	<td></td>
	<td>John</td>
	<td>Mary</td>
</tr>
<tr>
	<td>Coffee</td>
	<td>1</td>
	<td>3</td>
</tr>
<tr>
	<td>Sugar</td>
	<td>0</td>
	<td>1</td>
</tr>
</table>

<p>
	Safari 10: Role table (default).
</p>

<h2>Table with 5 columns</h2>

<table>
<tr>
	<td></td>
	<td>John</td>
	<td>Mary</td>
	<td>Robert</td>
	<td>Rose</td>
</tr>
<tr>
	<td>Coffee</td>
	<td>1</td>
	<td>3</td>
	<td>2</td>
	<td>2</td>
</tr>
<tr>
	<td>Sugar</td>
	<td>0</td>
	<td>1</td>
	<td>1</td>
	<td>1</td>
</tr>
</table>

<p>
	Safari 10: No exact ARIA role match.
</p>

<h2>Table with 5 columns and borders</h2>

<table border="1">
<tr>
	<td></td>
	<td>John</td>
	<td>Mary</td>
	<td>Robert</td>
	<td>Rose</td>
</tr>
<tr>
	<td>Coffee</td>
	<td>1</td>
	<td>3</td>
	<td>2</td>
	<td>2</td>
</tr>
<tr>
	<td>Sugar</td>
	<td>0</td>
	<td>1</td>
	<td>1</td>
	<td>1</td>
</tr>
</table>

<p>
	Safari 10: Role table (default).
</p>

<h2>Table with 5 columns and CSS border</h2>

<table class="bordered">
<tr>
	<td></td>
	<td>John</td>
	<td>Mary</td>
	<td>Robert</td>
	<td>Rose</td>
</tr>
<tr>
	<td>Coffee</td>
	<td>1</td>
	<td>3</td>
	<td>2</td>
	<td>2</td>
</tr>
<tr>
	<td>Sugar</td>
	<td>0</td>
	<td>1</td>
	<td>1</td>
	<td>1</td>
</tr>
</table>

<p>
	Safari 10: Role table (default).
</p>

              
            
!

CSS

              
                .bordered {
	border-collapse: collapse;
}

.bordered th,
.bordered td {
	border: 1px solid #ccc;
}
p {
	max-width: 700px;
}
              
            
!

JS

              
                
              
            
!
999px

Console