Comments (27)
Looking at it currently. Will let you know if there is any progress @davidpaulsson
from react-native-image-gallery.
It is implemented, are you having troubles with it ?
from react-native-image-gallery.
Yup. Keeps me on first page. Still, I'll continue with my fork. Tried to check if switching to 2.0.0 and reapplying my changes will be an option for me. Not the case. Won't be able to provide more info. If you are sure it is implemented and working in v2, I will close the issue as I didn't spend much time setting it up.
from react-native-image-gallery.
It works for me on the demo with version 2.0.0
.
Are you doing something specific to set your initialPage ? Could you try using a fixed number, just to see if it works ?
By the way, what are you missing on this plugin that makes you keep using your fork ?
from react-native-image-gallery.
Can't give it a try currently. What I have additional to what was already there is the ability to show low res images while high res images are still loading and then with a small animation switch from low to high.
from react-native-image-gallery.
i had also this problem. I set initialPage to 3, but it still displayed fist element in the array
After swiped to the next or previous image, it displayed the image at 4 or 2. Hope you to fix it!
from react-native-image-gallery.
Can you send me some of your code ? I'm having troubles reproducing this issue.
from react-native-image-gallery.
Just switched my fork of v1 to use your ViewPager from v2 and I can reproduce it. It's something in the ViewPager.
So I have 3 images. If I try to go to page 2 (0-based), image 0 is shown to me. Swipe back to the first image (where it is shown again), then again to image 2 and all is fine.
from react-native-image-gallery.
I can confirm, didn't have time to check if it's on my side and didn't get earlier with this issue.
from react-native-image-gallery.
<Gallery
style={{ flex: 1, backgroundColor: 'black' }}
images={this.state.imageList}
initialPage={this.state.initialImage}
/>
@Exilz this is a snippet of my code
from react-native-image-gallery.
Could u explain this prop to me in more details?
onPageSelected | Fired with the index of page that has been selected
from react-native-image-gallery.
You pass a function that receives as its argument the index of the page that you've scrolled to.
I have no time to take a look at this initialPage
bug for the moment, I'll look into it ASAP.
from react-native-image-gallery.
Ok bro @Exilz. Thanks for your support. Have a good day
from react-native-image-gallery.
If u just swipe a few pixels and correct image appears it can be something with FlatList refreshing after scrolling to item without animation:
facebook/react-native#15634
from react-native-image-gallery.
from react-native-image-gallery.
i thought it will make app slow
from react-native-image-gallery.
Can confirm this. Any progress or suggestions on how to fix it? Just nudging the image will re-render to show the correct index (btw this is only on Android, on iOS it works as expected).
from react-native-image-gallery.
I think I have the solution. Will need someone to test it with iOS so great @davidpaulsson joined here :-) I'll write again once I'm done with commiting.
from react-native-image-gallery.
@davidpaulsson @chrusart @vanhiepdam @Exilz here's a PR
from react-native-image-gallery.
@vbuch I'm happy to see you've dug deep into this problem. I didn't know this was specific to android, this explains why I couldn't reproduce it on the simulator.
I'll try to review this ASAP, it looks like you've changed quite a few things and cleaned up some bulk, great ! We should test for regressions and not just this issue since so much code changed.
from react-native-image-gallery.
Once you get to read it, you'll see the changes are not that much. Still, hope @davidpaulsson can test it on both Android and iPhone.
from react-native-image-gallery.
from react-native-image-gallery.
@Exilz initialPage is not working with imageComponent. can you please show any example.
i am using xcode simulator.
Thanks
from react-native-image-gallery.
@Haideralee you maybe missed the fact that imageComponent
needs to be a rendering function. (props, dimensions) => {}
from react-native-image-gallery.
from react-native-image-gallery.
@vbuch i added a render function of imageComponent
but the issue is it's also show first image for the first time.
example i have 5 images and i select 3th image so it's should show 3 index image on the cover but it's always show 0 index image on the cover.
from react-native-image-gallery.
@Haideralee I can't help much for iOS. Sorry. This is also a closed issue. You should probably create a new one.
from react-native-image-gallery.
Related Issues (20)
- Laggy when using setParams react navigation on page selected HOT 1
- how to stop photo from swiping vertically when scrolling horizontally
- Warning: componentWillMount/ componentWillReceiveProps deprecated HOT 1
- Example using image in storage
- Feature Request
- infinite scrolling feature
- This library is not MAINTAINED! HOT 7
- keyExtractor HOT 1
- detect when swiped at the last image
- Animated 'useNativeDriver' was not specified HOT 6
- Exit button is not defined by default? HOT 1
- page Scroll not working
- How can i get zoom scale
- zoom to area??
- initialPage doesn't work above index value of 9
- The Gallery seems to break after removing the last image HOT 1
- How to enlarge a picture without shrinking it?Could anyone do me a favor?
- Android header space
- How to zoom image via double tap.
- css part
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-native-image-gallery.