Skip to content

bug(ContextMenu): positioning fails in release configuration on Android in a dotnet MAUI app #7450

@peereflits

Description

@peereflits

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

I'm using BootstrapBlazor in a dotnet MAUI app (net10) with a BlazorWebView.
In the app a ContextMenu is being used.

When I test the app in debug mode on an Android device the context menu behaves as expected.
But when I test the app in release mode on an Android device the context menu is always rendered in the bottom-left corner of the screen.

Debug mode

Image

Release mode

Image

I created an example app to demonstrate the issues. See the attachment.

BBContextMenu.zip

I tested this on:

  • Nokia Phone 7.2 (Android version 11)
  • Nokia Tablet T21 (Android version 14)

It works well on a Windows device.
I'm not yet able to test this on an Apple device.

Expected Behavior

The context menu should be rendered near the touched location in release mode, instead of the bottom left corner.

Interactive render mode

Interactive WebAssembly (Client-side rendering (CSR) using Blazor WebAssembly)

Steps To Reproduce

  1. Connect an Android device to your Dev machine
  2. Open this project in Visual Studio (2026)
  3. Set the configuration to "Debug"
  4. Run the app on your local connected device
Image
  1. Confirm that the context menu behaves normal
  2. Switch the configuration to "Release"
  3. Run the app on your local connected device
  4. Click in the text. The context menu appears on the screen in the bottom-left corner. If you don't see a context menu swipe to the bottom of the screen.

.NET Version

NET10.0

Anything else?

IDE: Visual Studio 2026
.NET Version: 10
BootstrapBlazor Version: 10.2.0
App type: .NET MAUI Hybrid Blazor

I haven't searched the existing issues as I can't read Chinese.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions