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
Table tips: Add table headers tips for mobile #526
Closed
Closed
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
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
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.
I personally think this is a bit too vague. What about:
(I am unsure how to glue together two tables using ARIA, it seems to be an awful solution. How does one ensure keyboard and screen reader compatibility? Can we link to some documentation on how to do that?)
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.
I was also confused by "If a table is rendered as multiple tables, ARIA should be used. " Is this related to the above tip about using distinct
<table>
and not separating tables within a table?I was also wondering if these tips are really edits to the text above the shareable code examples. It wasn't clear as to how they would get implemented.
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.
If we're talking about nested tables when saying "If a table is rendered as multiple tables..." then I feel like we should explicitly say that. So, perhaps a slight edit on @yatil's wording would work (if nesting tables is the issue we're describing here) such as:
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.
I hope we are not talking about nested tables because nested tables are bad, especially in the mobile context. I was thinking that the use case is ”I got a table with 6 (content) columns but only two columns fit the screen, so I break the table up in three tables with 2 columns each.”
I guess we need clarification on the use case here.
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.
Aren't there other techniques for tables on small screens than artificially creating a table out of smaller tables?
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.
There certainly are. https://www.w3.org/WAI/Policy/ reformats the table to make sense (using CSS grid layout):
(Simulated) Smaller iPhone:
A grid with 2 by 4 cells, country and date share the top row, the legislation name spans the second row. The other data is filling up the four other cells.
(Simulated) Bigger iPhone:
Reformatted to four columns with three columns combined at the top as a header section:
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.
+1 to the Responsive Design addition.
However, there seems to be a lack of agreement on the extent and clarity of the content on Table Headers that needs discussion. Perhaps add to the agenda?
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.
Agree with adding to the agenda to clarify what is meant by "If a table is rendered as multiple tables." I think if we can agree on the actual meaning then we can clarify the language in the tip sentence and maybe give some sort of example use in parenthesis.