MAUIverse MAUIverse

Adding a Custom Action Button to the .NET MAUI Shell TabBar

A raised button in the middle of the tab bar is a familiar pattern in mobile apps, and Vladislav’s contribution to MAUI UI July 2023 builds one by subclassing TabBar. The CustomTabBar exposes bindable properties such as the button’s command, image, text, and background color, which keeps the XAML in your Shell definition tidy. He uses the M.BindableProperty.Generator package to cut down on property boilerplate.

The visual work happens in platform code. On Android, a custom ShellRenderer supplies a ShellItemRenderer that adds a rounded button when the item uses the custom tab bar. iOS and Mac Catalyst follow a similar approach with a UIButton positioned in the middle of the bar. Registering the handlers in MauiProgram completes the setup.

If you’ve been looking for a way to go beyond the standard Shell tab styling, this is a practical blueprint, with screenshots from Android and iOS and the full sample on GitHub.

View Source →

← Back to Community Feed

}