Skip to content

React-native-photo-view-ex scaling issue #27

Description

@KamranZafar19

I am using React-native-photo-view-ex for resizing the images with a pinch for picture editing. when I resize the image the flex-box size does not change with the image size and when I added a new item for example text or image the previously resized image flex-box focused and resized the flex-box size and the position of the image will be changed. Here is my code
{imageArray &&
imageArray.map((item, index) => {
return (
<component.PinchZoomView
minScale={0.1}
maxScale={5}
scale={item.scale}
translateX={item.translateX}
translateY={item.translateY}
data={value =>
modifyValues(value, item.layer, item.key)
}
key={index}
style={[
styles.pinchImagePosition,
{
zIndex: item.key,
},
]}>
<PhotoView
source={{uri: item.editImage}}
key={index}
minimumZoomScale={0.1}
maximumZoomScale={5}
onScale={e =>
modifyScaling(e.nativeEvent, item.layer)
}
resizeMode="contain"
style={[styles.resizeImageWrapper]}
/>
</component.PinchZoomView>
);
})}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions