Skip to content

[Help]: Is AutoHeight behavior based on slideRegistry instead of slidesInView by design? #1174

Closed Answered by davidjerleke
keatkeat87 asked this question in Help
Discussion options

You must be logged in to vote

Hi @keatkeat87,

Thank you for your questions.

the height is being obtained from the slideRegistry, which is not the same as slidesInView.

Is this behavior by design?

Yes, it is. This happens because a slide can be considered visible even if just 1 pixel is showing (when inViewThreshold: 0). Setting the carousel height based on such minimal visibility can lead to confusing behavior — the user might not notice that 1 pixel, yet the carousel height still changes unexpectedly.

This tends to happen more often when dragFree: true, since the user can drag freely without scroll snap restrictions, making partial visibility of slides more common.

if yes, how can I override the behavior, I pref…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by keatkeat87
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
resolved This issue is resolved question Question about how to achieve something plugin Issue is related to plugins
2 participants