Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

How to close a popup instead of navigating back when swiping or pressing back?

$
0
0

I’m building a .NET MAUI Blazor Hybrid app, and I want to handle back navigation (both swipe gestures and the hardware/software back button).

Here’s what I need:

If the user swipes back (like iOS gesture) or presses the back button,→ and I have a popup (Blazor component) open,→ I want to close only the popup, not navigate away from the current page.

If there’s no popup open, the normal navigation back should happen.

So basically:Swipe-back or back button → if popup is open → close it and stay on the same page.


Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>