Skip to content

Commit

Permalink
Improve accessibility of swiper bootscore#78
Browse files Browse the repository at this point in the history
Added option on card swipers to control via keyboard for better accessibility.
  • Loading branch information
simon-eller authored Aug 15, 2024
1 parent c5d2cab commit b19c7bd
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion assets/src/js/swiper-init.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ for (i = 0; i < bsSwiper.length; i++) {
nextEl: '.swiper-button-next',
prevEl: '.swiper-button-prev',
},
keyboard: {
enabled: true,
},
breakpoints: {
768: {
slidesPerView: 2,
Expand Down Expand Up @@ -80,6 +83,9 @@ for (i = 0; i < bsSwiperAutoplay.length; i++) {
nextEl: '.swiper-button-next',
prevEl: '.swiper-button-prev',
},
keyboard: {
enabled: true,
},
breakpoints: {
768: {
slidesPerView: 2,
Expand Down Expand Up @@ -163,4 +169,4 @@ for (i = 0; i < bsSwiperHeroFade.length; i++) {

});

}
}

0 comments on commit b19c7bd

Please sign in to comment.