Skip to content
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

Refresh when i swipe without being on top #74

Closed
narcisao opened this issue Jul 3, 2019 · 7 comments
Closed

Refresh when i swipe without being on top #74

narcisao opened this issue Jul 3, 2019 · 7 comments

Comments

@narcisao
Copy link

narcisao commented Jul 3, 2019

I am trying to use this pull to refresh, but im having an issue. I've looked for other issues like this, but didnt found any answer that solve my problem, so I submited this issue. I tried with 0.1.14 and 0.1.17 versions and none worked. My app is built using cordova and i tested both in mobile and browser.

Bug report

Current behavior:
When i scroll, my app refresh.

Expected behavior:
My app refresh only its on top.

** for demo with bug:**
https://jsfiddle.net/L4dypo8n/

Browsers affected:
Google chrome / android

@pateketrueke
Copy link
Collaborator

Hello @narcisao so much thanks for your input, however I was not able to run your demo.

@narcisao
Copy link
Author

narcisao commented Jul 3, 2019

https://jsfiddle.net/L4dypo8n/4/ try with this new one. changed the source code from html

@pateketrueke
Copy link
Collaborator

Did you confirmed it replicates the same issue?

@narcisao
Copy link
Author

narcisao commented Jul 3, 2019

I checked on another computer. For this app, im using cordova. I opened the console and for a reason (that i dont know why) my parameter "window.scrollY" is ALWAYS 0, so, when PTR calls the function "shouldPullToRefresh" the answer is TRUE, even if im not at the top of screen. Any sugest?
On the other computer that I tested, the plugin worked correctly.
[already checked duplicated answers and tested them all]

@pateketrueke
Copy link
Collaborator

Try providing your own shouldPullToRefresh() function in order to see why window.scrollY is always zero, there you can test other props on window (cordova-specific may be?) to see of any works for you.

@faelsoto
Copy link
Member

faelsoto commented Jul 4, 2019

I'm closing this issue, the JSFiddle is not working and therefore we aren't able to reproduce the issue. Please feel free to open another issue making sure the JSFiddle is working, as well as testing it on web and mobile browsers.

@faelsoto faelsoto closed this as completed Jul 4, 2019
@narcisao
Copy link
Author

narcisao commented Jul 4, 2019

Thanks for the help guys. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants