From 339f52ee2fd728cfd18c25fda890714a20aec6f0 Mon Sep 17 00:00:00 2001 From: Blacklightdesign Date: Mon, 14 Nov 2022 08:08:48 +0100 Subject: [PATCH] fix: touch focusableElements jumps element (#6139) to first position - check if focus event triggered by touch - don't jump the slide element Co-authored-by: Andreas Henzgen --- src/modules/a11y/a11y.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/modules/a11y/a11y.js b/src/modules/a11y/a11y.js index 24f5e3803..29dd0120f 100644 --- a/src/modules/a11y/a11y.js +++ b/src/modules/a11y/a11y.js @@ -186,6 +186,7 @@ export default function A11y({ swiper, extendParams, on }) { swiper.visibleSlides && swiper.visibleSlides.includes(slideEl); if (isActive || isVisible) return; + if (e.sourceCapabilities && e.sourceCapabilities.firesTouchEvents) return; if (swiper.isHorizontal()) { swiper.el.scrollLeft = 0; } else {