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

Shell.BackButtonBehavior doesn't react to swipe back #15813

Open
UkeHa opened this issue Jun 23, 2023 · 3 comments
Open

Shell.BackButtonBehavior doesn't react to swipe back #15813

UkeHa opened this issue Jun 23, 2023 · 3 comments

Comments

@UkeHa
Copy link

UkeHa commented Jun 23, 2023

Description

In iOS and Android it's possible to change the behaviour of the back button via Shell.BackButtonBehavior. That works as intended, but if you use the back swipe gesture (from the edge of the screen towards the middle) it goes back in the navigation of the stack. There is also no way to change the behaviour from the ViewModel.

I'd propose to either handle the swipe back the same way a back button is being handled, make it optional to also attach the backbutton event to the swipe gesture or make it it's own bindable behaviour.

Swipe.Back.mp4

Steps to Reproduce

  • Press Button Go to second Page
  • Swipe Back
  • No Messagebox appears

Link to public reproduction project repository

https://github.com/UkeHa/SwipeBackMaui/tree/master

Version with bug

7.0.86

Last version that worked well

Unknown/Other

Affected platforms

iOS, Android, I was not able test on other platforms

Affected platform versions

iOS 16.5.1, Android 13

Did you find any workaround?

It's possible to attach to the OnNavigating or OnNavigatingChanged event and trying to catch every possible way the navigation could be accessed or to override the INavigation, but both of these solutions are cumbersome to implement once you reuse a page in multiple instances and moves navigation into the view which isn't nice as well.

Relevant log output

No response

@UkeHa UkeHa added the t/bug Something isn't working label Jun 23, 2023
@PureWeen PureWeen added proposal/open area-controls-shell Shell Navigation, Routes, Tabs, Flyout area-navigation NavigationPage and removed t/bug Something isn't working labels Jun 23, 2023
@PureWeen PureWeen added this to the Backlog milestone Jun 23, 2023
@ghost
Copy link

ghost commented Jun 23, 2023

We've added this issue to our backlog, and we will work to address it as time and resources allow. If you have any additional information or questions about this issue, please leave a comment. For additional info about issue management, please read our Triage Process.

@UkeHa
Copy link
Author

UkeHa commented Sep 25, 2023

@PureWeen could this still be something for .net8 GA or is it too late for that?

@ElijahRomer
Copy link

Any update on this? This is causing big issues with Android UX for our .NET MAUI App. Android Backswipe wont interact with the shell.

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

No branches or pull requests

4 participants