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

Add Treegrid Example #762

Merged
merged 45 commits into from
Jul 12, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
3a85c1c
Stub out treegrid pattern and example page for issue #91 and issue 132.
mcking65 Apr 17, 2017
bd1beba
Initial treegrid commit for a treegrid that is mostly a tree aka tree…
aleventhal Apr 19, 2017
132b2a1
Markup tweaks, remove unused css
aleventhal Apr 19, 2017
c42f759
Support enter key behaviors on row (open message) and on first cell (…
aleventhal Apr 19, 2017
4e0a32f
Note bugs filed, we can remove as we clear these
aleventhal Apr 19, 2017
31cf6d8
Treegrid Example: Initial Implementation (pull #360)
aleventhal Apr 19, 2017
63b6080
Fix jscs error
aleventhal Apr 19, 2017
0aff398
Merge
aleventhal Apr 19, 2017
55fc698
Treegrid Example: Fix jscs error (pull #361)
aleventhal Apr 20, 2017
572a68b
Allow different options for cell focus, via ?cell=allow, ?cell=start …
aleventhal Apr 20, 2017
b9faeec
Links to the different versions which are really the same file with a…
aleventhal Apr 20, 2017
88baa21
Merge pull request #368 from aleventhal/treegrid
mcking65 Apr 20, 2017
148933d
Move aria-expanded to first cell in each row if only cells can receiv…
aleventhal Apr 21, 2017
7e1793c
Support click and double click, cursor css
aleventhal Apr 21, 2017
238b600
Treegrid Example: Put aria-expanded on 1st cell in each row if only c…
mcking65 Apr 21, 2017
9ead91e
Enter on first cell to toggle expansion was not working
aleventhal Apr 24, 2017
124f3da
Expando button not showing in ?cell=force mode
aleventhal Apr 24, 2017
d434a25
Treegrid (#378)
aleventhal Apr 24, 2017
d27025b
Show which is current
aleventhal Apr 24, 2017
2c2d77c
Fix bug where if you try to arrow out of the treegrid, you can't tab …
aleventhal Apr 24, 2017
f954cb3
Merge pull request #379 from aleventhal/treegrid for issue #132
mcking65 Apr 25, 2017
6cdd026
More positive email thread about treegrids
aleventhal Apr 25, 2017
fcba4d0
No need to specify aria-readonly
aleventhal Apr 25, 2017
c7c0b6a
Merge pull request #381 from aleventhal/treegrid
mcking65 Apr 26, 2017
fb7e1ba
Rename from convoluted name to treegrid-1
aleventhal Apr 27, 2017
638e1cf
Merge pull request #388 from aleventhal/treegrid
mcking65 Apr 27, 2017
8d56a9a
Treegrid example: Update to use APG Example template for documentatio…
jongund Jun 18, 2018
e54850c
Merge branch 'master' into treegrid
mcking65 Jun 18, 2018
ce0beb1
Merge branch 'master' into treegrid
mcking65 Jul 11, 2018
b883b4a
Fix eslint errors
mcking65 Jul 11, 2018
f7f3335
Fix broken doctype declaration
mcking65 Jul 11, 2018
1cf58e9
Added some missing closing tags.
mcking65 Jul 11, 2018
a0b1b62
Remove redundant treegrid pattern stub section
mcking65 Jul 11, 2018
f0f8bc1
Remove redundant row role, rowheader, and fix label
mcking65 Jul 12, 2018
2ad980a
Editorial revision to introduction
mcking65 Jul 12, 2018
98d45af
Add similar examples and move useage options
mcking65 Jul 12, 2018
ee12eca
Remove accessibility features section
mcking65 Jul 12, 2018
386555a
Remove space from kb table b/c not implemented
mcking65 Jul 12, 2018
57356b3
Editorial clean up of rps table
mcking65 Jul 12, 2018
0d70534
Add validation error note
mcking65 Jul 12, 2018
f001b4a
fix html errors
mcking65 Jul 12, 2018
3b79fd4
Remove gridcell role from td elements
mcking65 Jul 12, 2018
d14bd77
Revert "Remove gridcell role from td elements"
mcking65 Jul 12, 2018
5b0faba
Add role row back on the tr elements and document it.
mcking65 Jul 12, 2018
514f612
Add 2 missing symbols.
mcking65 Jul 12, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
298 changes: 151 additions & 147 deletions aria-practices.html

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions examples/treegrid/css/expand-icon-highlighted.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions examples/treegrid/css/expand-icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
103 changes: 103 additions & 0 deletions examples/treegrid/css/treegrid-1.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
#treegrid {
width: 100%;
white-space: nowrap;
border-collapse: collapse;
table-layout: fixed;
}

#treegrid tr {
display: table-row;
cursor: default;
}

#treegrid tbody td {
cursor: default;
}

#treegrid-col1, #treegrid-col3 {
width: 30%;
}

#treegrid th {
text-align: left;
background-color: #eee;
}

/* Extra space between columns for readability */
#treegrid th, #treegrid td {
padding-bottom: 3px;
overflow-x: hidden;
text-overflow: ellipsis;
}

#treegrid tr > td:not(:first-child),
#treegrid tr > th:not(:first-child) {
padding-left: 3ch;
}

#treegrid a {
padding-left: .25ch;
padding-right: .25ch;
}

#treegrid tr:focus,
#treegrid td:focus,
#treegrid a:focus {
outline: 2px solid hsl(216, 94%, 70%);
background-color: hsl(216, 80%, 97%);
}

#treegrid a:focus {
border-bottom: none;
}

/* Hide collapsed rows */
#treegrid tr.hidden {
display: none;
}

/* Indents */
#treegrid tr[aria-level="2"] > td:first-child {
padding-left: 2.5ch;
}
#treegrid tr[aria-level="3"] > td:first-child {
padding-left: 5ch;
}
#treegrid tr[aria-level="4"] > td:first-child {
padding-left: 7.5ch;
}
#treegrid tr[aria-level="5"] > td:first-child {
padding-left: 10ch;
}


/* Collapse/expand icons */
#treegrid tr > td:first-child::before {
font-family: monospace;
content: " ";
display: inline-block;
width: 2ch;
height: 11px;
transition: transform .3s;
transform-origin: 5px 5px;
}

#treegrid tr[aria-expanded] > td:first-child::before,
#treegrid td[aria-expanded]:first-child::before {
cursor: pointer;
/* Load both right away so there is no lag when we need the other */
background-image: url("expand-icon.svg"), url("expand-icon-highlighted.svg");
background-repeat: no-repeat;
}

#treegrid tr[aria-expanded]:focus > td:first-child::before,
#treegrid tr[aria-expanded] > td:focus:first-child::before,
#treegrid tr:focus > td[aria-expanded]:first-child::before,
#treegrid tr > td[aria-expanded]:focus:first-child::before {
background-image: url("expand-icon-highlighted.svg");
}

#treegrid tr[aria-expanded="true"] > td:first-child::before,
#treegrid td[aria-expanded="true"]:first-child::before {
transform: rotate(90deg);
}
Loading