LIT-EIA / adapt-esdc-accessibilityfixes

Extension to load and run a .js file when a course loads
GNU General Public License v3.0
5 stars 2 forks source link

General - popups - Ensure that scrollable region has keyboard access #100

Closed GGD4V closed 3 years ago

GGD4V commented 3 years ago

Issue: When clicking on one of the pictures under "Being a Visible Minority in the Workplace", a complex modal pops up but the content can only be scrolled with a mouse.

GGD4V commented 3 years ago

Need to add tabindex value to popup + event listeners.. might want to make it generic to all notifications instead of just hotgrid.... $('.hotgrid-popup-inner').keydown(function(e) { if(e.keyCode == 40){$('.hotgrid-popup-inner').scrollTop($('.hotgrid-popup-inner').scrollTop()+10);} if(e.keyCode == 38){$('.hotgrid-popup-inner').scrollTop($('.hotgrid-popup-inner').scrollTop()-10);}

});

GGD4V commented 3 years ago

Solution found especially for hotgrid: $('.hotgrid-popup').keydown(function(e) { if(e.keyCode == 40){$('.hotgrid-popup').scrollTop($('.hotgrid-popup').scrollTop()+10);} if(e.keyCode == 38){$('.hotgrid-popup').scrollTop($('.hotgrid-popup').scrollTop()-10);} });

hotgrid-popup should have a fixed height and overflow-y:auto;

GGD4V commented 3 years ago

Fixed and tested on last iteration. Small bug in Safari where the bar disappears (but still scrolls).