likashefqet / react-native-image-zoom

A performant and customizable image zoom component built with Reanimated v2+ and TypeScript. 🌃 🚀
https://www.npmjs.com/package/@likashefqet/react-native-image-zoom
MIT License
267 stars 44 forks source link

The package supposed to work with `react-native-reanimated-carousel` ? #43

Closed IlanAMG closed 10 hours ago

IlanAMG commented 7 months ago

ImageZoom not working when used in the carousel

https://github.com/dohooo/react-native-reanimated-carousel

github-actions[bot] commented 5 months ago

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 15 days.

github-actions[bot] commented 3 months ago

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 15 days.

xiaoosnggao commented 2 months ago

mark

yashgada commented 1 month ago

Any directions on how I can use this lib with a horizontal flatlist? Basically I want to be able to zoom and all, but also be able to swipe to get to the next picture

arnabJ commented 1 week ago

@yashgada I was able to make it work with https://github.com/dohooo/react-native-reanimated-carousel but it's too laggy for me on the emulator.

See if you can figure it out to make it stable.

What I did: I wrapped the ImageZoom component with GestureHandlerRootView component in the renderItem function.

Note: Here I have shown inline function, but instead I have created a function and used React.memo()

Example:

<Carousel
    ref={ref}
    ...
    renderItem={({item, index}) => (
        <GestureHandlerRootView>
            <ImageZoom uri={item.uri} style={{width, height}} resizeMode="contain" />
        </GestureHandlerRootView>
    )}
/>
SpencerRohan commented 5 days ago

minPanPointers={1} was causing it to not swipe to the next slide for me.

likashefqet commented 10 hours ago

🎉 Version 4.2.0 of @likashefqet/react-native-image-zoom has been released with some exciting new features! 🚀

Feel free to update to the latest version to explore these additions. If you have any more suggestions or ideas for improvements, please feel free to share.

Thank you! 🙌