Table of Contents

Class ScaffoldNavBarView

Namespace
Nalu
Assembly
Nalu.Maui.Scaffold.dll

The default Nalu navigation bar component, created automatically as the NavBarTemplateProperty default at the scaffold level. Slots, in order: start-drawer button, back button, title (or the page's TitleViewProperty content), end-drawer button, close button — all driven by the ScaffoldNavBarContext binding context. Style it or replace it entirely with any custom view.

public sealed class ScaffoldNavBarView : Grid, INotifyPropertyChanged, IEffectControlProvider, IToolTipElement, IContextFlyoutElement, IAnimatable, IViewController, IVisualElementController, IElementController, IGestureController, IGestureRecognizers, IPropertyMapperView, IHotReloadableView, IReplaceableView, IBindableLayout, IVisualTreeElement, IGridLayout, ILayout, IView, IElement, ITransform, IContainer, IList<IView>, ICollection<IView>, IEnumerable<IView>, IEnumerable, ISafeAreaView, IPadding, ICrossPlatformLayout
Inheritance
ScaffoldNavBarView
Implements
Inherited Members
Extension Methods

Remarks

The component spans the whole top strip and opts into the safe area itself, so its content sits below the status inset while the bar contributes its footprint to the page. The strip BACKGROUND is not the bar's concern: it belongs to the chrome and is driven by the effective the attached nav bar appearance properties (attached via Scaffold.NavBarBackground) — the same is true for any custom bar.

It owns ONLY the strip metrics (height, padding, spacing). Title and button appearance belong to the primitives — ScaffoldNavBarTitle, ScaffoldBackButton, ScaffoldCloseButton, ScaffoldFlyoutButton — which are public and styled directly, so the SAME style applies whether they sit in this bar or in a custom one:

<Style TargetType="nalu:ScaffoldNavBarTitle">
    <Setter Property="FontFamily" Value="SemiBold" />
</Style>
<Style TargetType="nalu:ScaffoldNavBarButtonBase" ApplyToDerivedTypes="True">
    <Setter Property="IconColor" Value="{StaticResource Accent}" />
</Style>

Constructors

ScaffoldNavBarView()

Initializes the default nav bar.

public ScaffoldNavBarView()

Fields

BarHeightProperty

Bindable property for BarHeight.

public static readonly BindableProperty BarHeightProperty

Field Value

BindableProperty

BarPaddingProperty

Bindable property for BarPadding.

public static readonly BindableProperty BarPaddingProperty

Field Value

BindableProperty

SpacingProperty

Bindable property for Spacing.

public static readonly BindableProperty SpacingProperty

Field Value

BindableProperty

Properties

BarHeight

Gets or sets the bar content height (excluding the status-bar inset).

public double BarHeight { get; set; }

Property Value

double

BarPadding

Gets or sets the padding around the bar content.

public Thickness BarPadding { get; set; }

Property Value

Thickness

Spacing

Gets or sets the gap around the title column. The icon buttons themselves sit flush (zero spacing): their 44dp tap targets' inner whitespace provides the optical rhythm around the 24dp glyphs.

public double Spacing { get; set; }

Property Value

double