Table of Contents

Enum ButtonVariant

Namespace
TwBlazor.Enums
Assembly
TwBlazor.dll

Defines the button variants.

public enum ButtonVariant

Fields

Elevated = 0

Elevated button with shadow elevation (Medium emphasis).

Uses elevation Level 1 (shadow-sm) at rest, Level 2 (shadow-md) on hover. Best for actions that need separation from the background.

Filled = 1

Filled button with solid background color (High emphasis) - Default.

The most prominent button style. Uses no shadow at rest, subtle shadow on hover. Use for primary actions like "Save", "Submit", "Continue".

Outlined = 2

Outlined button with border (Medium emphasis).

Uses transparent background with colored border and text. Best for secondary actions or paired with filled buttons.

Text = 3

Text button with no background or border (Low emphasis).

Most subtle button style with only text and state layer effects. Best for tertiary actions or inline with content.

Remarks

  • Elevated: Medium emphasis with shadow elevation
  • Filled: High emphasis with filled background (default)
  • Tonal: Medium emphasis with tonal background
  • Outlined: Medium emphasis with outline border
  • Text: Low emphasis with no background or border