forem / DEV-ios

DEV Community iOS App
GNU General Public License v3.0
357 stars 97 forks source link

Add refresh button (replacing the forward navigation) #164

Closed benhalpern closed 4 years ago

benhalpern commented 5 years ago

Is your feature request related to a problem? Please describe. Currently the only way to refresh the current page is by pulling down. This leads to awkward situations when the browser is not reachable and a user gets stuck in a bad state.

Describe the solution you'd like A native refresh button in the navigation.

This can replace the forward navigation button, as that is not an entirely useful button. Refresh serves more purpose in that context and I don't think we need all three.

The icon file should have a similar weight as the other nav buttons. We use pretty generic icons, but if you can't find the right one, we can fix it after the PR.

benhalpern commented 5 years ago

@vuinguyen has indicated that she'll work on this.

vuinguyen commented 5 years ago

@benhalpern :

1) I was able to add a native refresh button in the navigation (an option when adding a bar button item), and to get the forward button to be highlighted. But not a good way to show both the back and forward buttons highlighted at the same time (indicating that going either forward or backward is an option at that point). I don't mind keeping both the forward and back buttons on the navigation, my feeling is that users will complain if we remove the forward button.

2) Also, we don't want to remove the ability to refresh by pulling down, just add another way to get to that function via a native refresh button. Is that correct?

What are your thoughts on 1 and 2? Simulator Screen Shot - iPhone 8 Plus - 2019-08-21 at 16 46 46

benhalpern commented 5 years ago

@vuinguyen Yes, this is all correct. And as I'm looking at it I think it makes sense to keep them. I was probably overthinking it with regard to possible future buttons in the bottom bar, but this looks good.

Yes, users will still be able to refresh. This is primarily an alternative because the pull-to-refresh is implemented in the web view so sometimes becomes unreliable due to network connectivity issues that prevent JavaScript from downloading.

So I think you're taking the right approach and picking up the good parts of what I suggested.