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

Add an option to disable Swipe Gesture to go back #1340

Open
Bingo90 opened this issue May 1, 2024 · 13 comments
Open

Add an option to disable Swipe Gesture to go back #1340

Bingo90 opened this issue May 1, 2024 · 13 comments
Assignees
Labels
enhancement New feature or request fixed in upcoming release Indicates that an issue has been fixed, and will be released in the next version
Milestone

Comments

@Bingo90
Copy link

Bingo90 commented May 1, 2024

Is Your Feature Request Related to a Problem?

Thunder's Swipe Gesture interferes with Android's system-wide back gesture, making it feel odd to go back. There currently doesn't seem to be a way to disable this.

Feature Description

Add a toggle to disable the gestures. They're not needed when using Android's gesture navigation.

Alternative Solutions

No response

Additional Context

No response

@Bingo90 Bingo90 added the enhancement New feature or request label May 1, 2024
@micahmo
Copy link
Member

micahmo commented May 1, 2024

Hey @Bingo90, thanks for the issue! Just to clarify, do you mean the ability to go back by swiping from anywhere left-to-right on the screen (as opposed to just the edge)?

If so, you're right that there isn't a way to disable that gesture specifically, although you can essentially "override" it by having a swipe gesture enabled for posts and comments. When those are enabled, swiping from left-to-right on the screen activates actions for posts/comments and does not swipe the page back.

Of course, if you don't want any of the action gestures enabled either, then we might have a case for adding a setting to completely disable the full-page swipe.

P.S. Not to discredit your experience at all, but I have never really experienced issues with the Android gesture conflicting with the full-page swipe. If I swipe from the edge, the Android gesture takes precedence. If I swipe from the middle, the app will handle the navigation. If there's something I'm missing, a video demonstrating the issue would go a long way to helping us understand!

@Bingo90
Copy link
Author

Bingo90 commented May 1, 2024

The left to right back gesture, yeah. I noticed it mostly in the settings screen, here's a video:
https://github.com/thunder-app/thunder/assets/28258958/d56142ae-0f62-4016-b479-f56a5b83e415

@micahmo
Copy link
Member

micahmo commented May 3, 2024

Hey @Bingo90, apologies but apparently this setting already exists and it totally slipped my mind. Check out Settings > Gestures > Fullscreen Swipe Gestures > disable. If that works for you, we can close this issue!

@Bingo90
Copy link
Author

Bingo90 commented May 3, 2024

Hey @Bingo90, apologies but apparently this setting already exists and it totally slipped my mind. Check out Settings > Gestures > Fullscreen Swipe Gestures > disable. If that works for you, we can close this issue!

I already had this disabled - I guess this doesn't apply to the settings pages?

@micahmo
Copy link
Member

micahmo commented May 3, 2024

I guess this doesn't apply to the settings pages?

Ah, maybe not. That could be a miss on our part. We'll keep this issue open to track that!

@hjiangsu
Copy link
Member

hjiangsu commented May 3, 2024

Just chiming in on this - I believe that setting only disables the full-screen swipe gesture, but keeps the edge swipe to go back gesture which is why it's not working.

Maybe what we can do here is extend it so that the setting completely disables edge swipe to go back as well. This should only be for Android, because iOS's system navigation uses the edge swipe to go back!

@hjiangsu hjiangsu self-assigned this May 3, 2024
@hjiangsu
Copy link
Member

hjiangsu commented May 3, 2024

I'll take this one!

@hjiangsu
Copy link
Member

hjiangsu commented May 5, 2024

@Bingo90 I've merged in a PR which might resolve this issue. It's a bit tricky because the Settings page uses slightly different logic than the Feed/Post pages (so the left swipe to go back isn't the same).

We'll see if this fix also fixes the issues you were encountering with the Settings page. If it doesn't we'll try to see if we can reproduce it on our end. This fix will land in the next nightly so I'll let you know when that's released!

@hjiangsu hjiangsu added the fixed in upcoming release Indicates that an issue has been fixed, and will be released in the next version label May 11, 2024
@hjiangsu hjiangsu added this to the 0.4.0 milestone May 11, 2024
@Bingo90
Copy link
Author

Bingo90 commented May 13, 2024

I installed v0.4.0-2, it's still happening in settings.

@hjiangsu
Copy link
Member

Thats unfortunate - this might be a harder issue to solve if this is the case. For devs:

  • We currently use go_router for the navigations within the Settings page. go_router should be respecting the OS level navigation gestures (generally iOS uses swipe to go back, and Android uses the system swipe gesture)

@Bingo90 Could you provide some more details on your device/Android version? This might help us narrow down the scope to see if it's affecting specific devices or not.

@micahmo Are you able to reproduce this issue on your end (specific to the Settings issue)

@Bingo90
Copy link
Author

Bingo90 commented May 13, 2024

Thats unfortunate - this might be a harder issue to solve if this is the case. For devs:

* We currently use `go_router` for the navigations within the Settings page. `go_router` should be respecting the OS level navigation gestures (generally iOS uses swipe to go back, and Android uses the system swipe gesture)

@Bingo90 Could you provide some more details on your device/Android version? This might help us narrow down the scope to see if it's affecting specific devices or not.

@micahmo Are you able to reproduce this issue on your end (specific to the Settings issue)

Android 14, One UI 6.1. Galaxy S23+
This honestly isn't that important of an issue, considering it's just settings, but I guess it'd still be nice to fix ^^

@micahmo
Copy link
Member

micahmo commented May 13, 2024

@micahmo Are you able to reproduce this issue on your end (specific to the Settings issue)

No I haven't been able to. 😞 I can't imagine what could be allowing the settings page to swipe back.

@Bingo90
Copy link
Author

Bingo90 commented May 13, 2024

Something I just figured out:
When using gesture navigation on Android, swiping back didn't go back every time (maybe it interfered with the system gestures?)
But with button navigation, swiping seems to work every time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request fixed in upcoming release Indicates that an issue has been fixed, and will be released in the next version
Projects
None yet
Development

No branches or pull requests

3 participants