Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

the --carousel-item-auto-size is overridden in mobile #3

Closed
omarherri opened this issue Aug 21, 2023 · 2 comments
Closed

the --carousel-item-auto-size is overridden in mobile #3

omarherri opened this issue Aug 21, 2023 · 2 comments

Comments

@omarherri
Copy link

I tried to replace the default value --carousel-item-auto-size value in mobile version. But whenever the second carousel_item doesn't fit anymore in the viewport it scale the first element to 100% width and override the value set in --carousel-item-auto-size.

So if we want to have 2 elements visible, we need to juggle with the width.

@claudia-romano
Copy link
Contributor

Hi there, that's actually the expected behaviour.
The --carousel-item-auto-size variable is the minimum width value for each carousel item. If you need to have two elements visible on mobile, then you can set this variable to a small enough value (e.g., 100px) and then increase its value at different media queries. Hope that makes sense!

@omarherri
Copy link
Author

Ahhh i see thank you for this. I taught it was the default width. I'll give this a try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants