Adds keyboard navigation support. The next panel can be opened by pressing the right arrow key and the previous panel can be opened by pressing the left arrow key. Also, the Enter key will open the link attached to the background or opened background images.
By default, the accordion will respond to keyboard input all the time, not only when the accordion has focus. If you would like it to respond only when the accordion is in focus, you need to add the
tabindex=0 attribute to the main accordion
<div id="my-accordion" class="accordion-slider" tabindex="0"> ... </div>
Also, you can add the
tabindex=-1 attribute to all anchor elements that are inside the accordion, in order to not allow these elements to get focus.