Skip to main content

BnActivityIndicator

Namespace: BlazorNative.Components

An indeterminate spinner. Renders as an indeterminate ProgressBar on Android and a UIActivityIndicatorView on iOS.

public sealed class BnActivityIndicator : Microsoft.AspNetCore.Components.ComponentBase, Microsoft.AspNetCore.Components.IComponent, Microsoft.AspNetCore.Components.IHandleEvent, Microsoft.AspNetCore.Components.IHandleAfterRender

Inheritance ObjectComponentBaseBnActivityIndicator
Implements IComponent, IHandleEvent, IHandleAfterRender

Remarks:

It has no parameters, including no start/stop. It animates for as long as it is mounted, so you control it with @if — render it while you are loading and unmount it when you are done. There is no hidden state to get wrong.

Its size is the platform's own: it measures itself, so you do not give it a width or a height. Put it in a BnView if you need to place or pad it.

@if (_loading)
{
<BnActivityIndicator />
}

Constructors

BnActivityIndicator()

public BnActivityIndicator()