Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

empty cells converted to headers (accesibility issue) #73

Open
haskinsjg opened this issue Aug 21, 2019 · 0 comments
Open

empty cells converted to headers (accesibility issue) #73

haskinsjg opened this issue Aug 21, 2019 · 0 comments

Comments

@haskinsjg
Copy link

If you have a table with empty cells, those cells can get converted to tags for the small version of the table. This can cause pages using the script to fail Section 508 compliance checks. An example table:

<table>
	<tr>
		<td>&nbsp;</td>
		<td>
			This is some table content
		</td>
	</tr>
</table>

Running Stackable.js results in this:

<table class=" stacktable small-only"><tbody><tr class="  "><th class="st-head-row st-head-row-main" colspan="2">&nbsp;</th></tr></tbody></table>
<table class="stacktable large-only">
	<tbody><tr>
		<td>&nbsp;</td>
		<td>
			This is some table content
		</td>
	</tr>
</tbody></table>

That empty <th class="st-head-row st-head-row-main" colspan="2"> causes 508 validation errors. Perhaps the <td> could only be converted to a <th> if it's not empty? Or have an option to ignore empty <td> tags to maintain 508 compliance?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant