-
-
Notifications
You must be signed in to change notification settings - Fork 329
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
🚀 What layout style do you want? #88
Comments
give an example to show how to customize animation style #88
Thank you! I actually turned this change into a property. In case you find it interesting, I can make a commit with it. |
cool,let me a look |
You are the first one to submit |
I am happy with that! You can see what I did in this PR. It was simple changes, and a little quick, let me know if there are any side effects or problems. |
It would be great to have support for multiple items per a page. I was able to achieve this by setting the width to 50%, and adding a style of Happy to spend some time contributing to this if you could point me in the right direction. |
One other request: "Auto Height" for horizontal layouts. I know this might not be possible, as the items are currently all positioned absolutely, but it would be great to be able to size to height of the carousel based on the height of the contents. This was achievable in snap-carousel, but they may have been using a very different strategy. |
@IAmNatch were you able to figure this out, thanks for the help if you can |
hello, where can I find an example to show more than one item |
What do you mean? |
https://user-images.githubusercontent.com/15078788/156445400-0c2a7f6c-7da2-40a9-9872-2669134bf535.gif some like this, display multiple items in carousel, where can i get this example , as mentioned @IAmNatch, if I want to display 1, 2, 4, 6 elements |
I added an example. You can look at this demo in home page, and click that gif it will navigate you to code example. 🍺 |
BTW, This code will control the number of items that displaied. |
grateful for your help and your time, really thanks, I'm going to try and study the code |
@dohooo hi thanks for this amazing library, |
perfect, thank you very much for answering, I will try and commit, if I had read it but had not understood what this was for, I thought it was to move it in reference to which point could be made to slide inside the carousel on the x axis, the values of the activeoffsetx -10 10: could you tell me what they are for? since I don't have them clear from the documentation in a short summary, and should I use them in the carousel I have with activeoffsety ? since the carousel is horizontal? |
activeOffsetX should already solve your issue, it is intended for horizontal carousels (side to side) that are inside a scroll view. The "panGestureHandlerProps" property is from react-reanimated itself. From the documentation of reanimated itself: Range along X axis (in points) where fingers travels without activation of handler. Moving outside of this range implies activation of handler. Range can be given as an array or a single number. If range is set as an array, first value must be lower or equal to 0, a the second one higher or equal to 0. If only one number p is given a range of (-inf, p) will be used if p is higher or equal to 0 and (-p, inf) otherwise. |
@dohooo how can i disable bouncing? |
> Without scale. https://github.com/dohooo/react-native-reanimated-carousel/blob/main/docs/custom-animation.md |
oh man, thank you so much) guess i didnt look good enough in docs and issues |
How to center the active item? |
@dohooo - Great work on this library, thank you for all the efforts on this! I would love to know how I can implement this vertical stack animation in the Carousel ? https://www.youtube.com/shorts/-lvrU34Jt50 I was able to achieve something similar on the horizontal with |
It's very easy.. |
Would like to know how! |
RPReplay_Final1656070531.MP4 |
This is great! Exactly what I need. Could you please help me with the props you've used to achieve this ? or an example you've created ? |
I have added to examples. |
Hey @dohooo, I've been looking at your multiple example again, and I've been hitting an issue which I would call "overscrolling". When the carousel is set to "loop", everything works as expected, however when loop is disabled, you can scroll the last element all the way to "position 1" instead of it being the last item in the carousel. Current Implementation:
Ideal Implementation
I've attached a minimal reproduction in expo here: I think this would be made possible by allowing us to set maxPages on the ScrollViewGesture, where maxPages would be Curious what you think about this! Edit: I believe this is the same issue as #240. |
|
stacked card animations that look like this would be amazing: |
Has someone already found a way for this? Or is it just not possible? |
How to use parallax mode, but hide the left nad right item. so the active item will show full width screen ? |
Hi! I managed to dynamically retrieve the height of the carousel items. While it requires a bit more effort, it is possible as shown below: How It Works:
|
Writing here!
BTW, looking forward to your PR!~ 🍺
The text was updated successfully, but these errors were encountered: