Skip to content
Snippets Groups Projects
Commit a90c4f8b authored by Yan, Andrew N.'s avatar Yan, Andrew N.
Browse files

fix regression where timeseries screen reader tables weren't showing up

parent d76a82f6
No related branches found
No related tags found
No related merge requests found
......@@ -320,12 +320,12 @@ const timeSeriesGraph = function (elem) {
elem.append('div')
.call(link(plotSROnlyTable, createStructuredSelector({
tsKey: () => 'compare',
tsKey: () => 'current',
variable: currentVariableSelector,
methods: methodsSelector,
visible: isVisibleSelector('compare'),
dataByTsID: pointsTableDataSelector('compare'),
timeSeries: currentVariableTimeSeriesSelector('compare')
visible: isVisibleSelector('current'),
dataByTsID: pointsTableDataSelector('current'),
timeSeries: currentVariableTimeSeriesSelector('current')
})));
elem.append('div')
.call(link(plotSROnlyTable, createStructuredSelector({
......
......@@ -146,12 +146,18 @@ describe('Hydrograph charting module', () => {
});
it('svg should be focusable', function() {
expect(svg.attr('tabindex')).toBe('0');
expect(svg.attr('tabindex')).toBe('0');
});
it('should have an accessibility table for each time series', function() {
expect(selectAll('table.usa-sr-only').size()).toBe(3);
expect(selectAll('table.usa-sr-only').size()).toBe(3);
});
it('should have a div for each type of time series', function() {
expect(selectAll('div#sr-only-median').size()).toBe(1);
expect(selectAll('div#sr-only-compare').size()).toBe(1);
expect(selectAll('div#sr-only-current').size()).toBe(1);
})
});
describe('SVG contains the expected elements', () => {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment