Permalink
Browse files

Add grid role to contentBox, presentation to table

Odd setup for a static table, but the assumption is
that no matter how the table is rendered, it should
always be considered a single table to screen readers.
  • Loading branch information...
1 parent 932d7eb commit 1be6a724c21fb8f874d13d43bd5b2c73cb3e1924 @lsmith committed Jan 24, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 src/datatable/js/core.js
View
@@ -287,7 +287,7 @@ Y.mix(Table.prototype, {
@type {HTML}
@default '<table class="{className}"/>'
**/
- TABLE_TEMPLATE : '<table class="{className}"/>',
+ TABLE_TEMPLATE : '<table role="presentation" class="{className}"/>',
/**
HTML template used to create table's `<tbody>` if configured with a
@@ -1138,6 +1138,8 @@ Y.mix(Table.prototype, {
this._viewConfig.columns = this.get('columns');
this._viewConfig.modelList = this.data;
+ contentBox.addAttribute('role', 'grid');
+
this.fire('renderTable', {
headerView : this.get('headerView'),
headerConfig: this._headerConfig,

0 comments on commit 1be6a72

Please sign in to comment.