-
Notifications
You must be signed in to change notification settings - Fork 787
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
[WIP] Opening the profile avatar in full size by click. Closes #7 #139
Conversation
@@ -135,6 +135,7 @@ android { | |||
} | |||
|
|||
dependencies { | |||
compile project(':react-native-photo-view') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does this need a native dependency? I feel like it'd probably be best to avoid extraneous native dependencies if possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrewda In this dependence there is the "pinch to zoom" feature, it's convenient. This may come in handy in the future (to display other images with zoom). Although I agree with you, as long as this is not necessary, why can use the usual component Image
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah okay yea pinch to zoom is nice, and that makes sense! Either way works for me :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andrewda great 😄
If not against @housseindjirdeh, then I would leave this dependency, it does not seem heavy and does not interfere with the application.
BTW, I now thought, how much the application will increase in size after connection of any dependency (or it becomes more slow to work for example)? What are thoughts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i was thinking the same thing these past few weeks. It's React Native - so it's inevitable that more and more dependencies are going to be added from here on out - that's one of the reasons why I love RN so much.
But just like you said, we all usually try limiting dependencies in our applications generally to reduce bloat. I really don't know how much application load times/performance is effected in a native application to be honest. However I of course would probably agree with most people and limit dependencies to only those we particulary need, even if a native application isn't as affected as much.
This looks soo nice 👍🏾 I'll test it on my iPhone today and let you know it renders. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is soo great @lex111. I love the look and feel of it on iOS. I also really like tapping anywhere on the screen closes the modal view. Great work mate 🎉
@@ -135,6 +135,7 @@ android { | |||
} | |||
|
|||
dependencies { | |||
compile project(':react-native-photo-view') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i was thinking the same thing these past few weeks. It's React Native - so it's inevitable that more and more dependencies are going to be added from here on out - that's one of the reasons why I love RN so much.
But just like you said, we all usually try limiting dependencies in our applications generally to reduce bloat. I really don't know how much application load times/performance is effected in a native application to be honest. However I of course would probably agree with most people and limit dependencies to only those we particulary need, even if a native application isn't as affected as much.
When clicking on the avatar, the full size of the picture opens in the modal window (closes #7).
Important note: I tested the work only on Android, please see how it works on iOS.
Also considered the use of the library:
react-native-lightbox - slows opening on Android
react-native-zoom-image - works fine, but does not apply to miniature styles (
borderRadius
in particular)Therefore, I had to make my own component, using the built-in component
Modal
and PhotoView.