Repository navigation
[Help]: Carousel focus event not behaving as expected #1071
SummaryWhen I tab to focusable elements within each slide, the carousel doesn't behave as I expect. From what I understand from the docs, the default callback fires the slideFocus event and scrolls to the focused element. So does this mean Embla should automatically move to the slide with the focused element? If not, how do I began to implement this behavior? If applicable, which variants of Embla Carousel are relevant to this question?
Additional informationNo response CodeSandbox examplehttps://stackblitz.com/edit/stackblitz-starters-2xhj2u?file=app%2F_components%2FSlideshow.tsx |
Answered by
davidjerleke
Nov 25, 2024
Replies: 1 comment 1 reply
|
@hunterbecton thanks for your question. I found the following problem in your code: You've missed to set <div className="h-full" ref={emblaRef}> {/* <-- Add overflow: hidden; here */} |
1 reply
Answer selected by
hunterbecton
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@hunterbecton thanks for your question. I found the following problem in your code: You've missed to set
overflow: hidden;on your viewport element. Maybe that's why?