I'm new to react so I'm trying to zoom an image in react. I use swiper js to show product images but for zooming i use react-image-magnify but it is not working. The react-image-magnify is working outside swiper js but not inside. Is there any solution for this?
<Swiper
navigation
loop={true}
thumbs={{ swiper: props.thumbsSwiper }}
>
{
productData.gallery.map((item, idx) =>
<SwiperSlide key={`image-slides-${idx}`}>
<div className="slide-item" key={`image-slides-${idx}`}>
<div className="slide-item__thumb">
<ReactImageMagnify {...{
smallImage: {
alt: 'Product Thumbnail',
isFluidWidth: true,
src: item.url,
className: "img-fluid",
},
largeImage: {
src: item.url,
width: 1200,
height: 1800,
},
enlargedImageContainerDimensions: {
width: '200%',
height: '100%'
}
}} />
{/*<img className="img-fluid" src={item.url} alt="Product Thumbnail" />*/}
</div>
</div>
</SwiperSlide>)
}
</Swiper>