Feedback
TwProgress
TwProgress is a Blazor progress bar component. Set Value, Max, Color and Size, or use Indeterminate mode when the duration is unknown.
Last updated
Basic Usage
A styled wrapper around the native
<progress> element - it keeps the built-in progressbar role and automatic aria-valuenow/aria-valuemin/aria-valuemax semantics for free.Razor
<TwProgress T="int" Id="download-progress" Label="Download Progress" Value="40" Max="100" />Colors
Use
Color to give a progress bar meaning at a glance - here it signals status rather than just decoration.Sizes
Use
Size to control the bar's thickness.Razor
<div class="space-y-6">
<TwProgress T="int" Id="small-progress" Label="Small" Value="30" Max="100" Size="ProgressSize.Small" Color="Color.Warning" />
<TwProgress T="int" Id="medium-progress" Label="Medium" Value="55" Max="100" Size="ProgressSize.Medium" Color="Color.Warning" />
<TwProgress T="int" Id="large-progress" Label="Large" Value="80" Max="100" Size="ProgressSize.Large" Color="Color.Warning" />
</div>Indeterminate
Set
Indeterminate when the completion amount isn't known yet - the value attribute is omitted so it renders (and is announced) as busy rather than "0% done".Razor
<TwProgress T="int" Id="sync-progress" Label="Syncing..." Max="100" Indeterminate />Interactive
Drive
Value from your own component state - there's no built-in user interaction, so the bar only moves when your code updates it.20% complete
Disabled
Use
Disabled to dim a progress bar that's paused or inactive.Razor
<TwProgress T="int" Id="disabled-progress" Label="Paused" Value="45" Max="100" Disabled />Theme Configuration
Styling is controlled by
TwBlazorTheme.Components (a TwProgressTheme), configured via the
AddTwBlazor() options callback described on the Get Started page.
Every property is a set of Tailwind classes, so changes are picked up by your own Tailwind build.
Global Theme Configuration
These reuse shared design tokens configured once on TwBlazorTheme, rather than being unique to this component.
| Property | Type | Controls |
|---|---|---|
Colors |
TwBlazorPalette |
Full reference: TwProgressTheme on the API docs.