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

Popup displayed behind modal #144

Open
NguyenThang1996 opened this issue Nov 29, 2024 · 3 comments
Open

Popup displayed behind modal #144

NguyenThang1996 opened this issue Nov 29, 2024 · 3 comments

Comments

@NguyenThang1996
Copy link

Issue : Mopups displayed behind Shell Modals
How to reproduce :

Steps that work :

Open a Shell Page.
In this page, open a Mopup dialog.
The Mopup is visible in front of the Page.
Steps with problems :

Open a Shell Modal.
In this modal, open a dialog Mopup.
It opens behind the modal. Go back and you'll see the Mopup.
.Net version : 9.0
Tested platform : Android emulator

@afk013
Copy link

afk013 commented Dec 2, 2024

Duplicate of #82

@NguyenThang1996
Copy link
Author

Duplicate of #82

but the problem is still not solved :(

@arahmancsd
Copy link

You can use a quick workaround. Instead of calling this on the ViewModel, you can call on Click or Tap event in the popup page itself.

So instead of using
await Shell.Current.DisplayPromptAsync(...)
call this on the popup page itself.

private async void TapGestureRecognizer_Tapped(System.Object sender, Microsoft.Maui.Controls.TappedEventArgs e)
    {
        var result = await DisplayPromptAsync("Add Category", "Please enter unique category name.");
    }

Simulator Screenshot - iPhone 16 - 2024-12-30 at 18 28 10

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