Actions
Button
A focused action primitive with five levels of emphasis, semantic colors, native and link behavior, flexible content, and explicit async states.Anatomy
Every callout is measured from the live button below, so the lines point at the real elements.
- 1
Container
The button element itself: shape, elevation and the target size the user actually hits.
- 2
State layer
Hover, focus and pressed feedback painted on the container — the kit has no separate state-layer element.
- 3
Label
The action text. It carries the accessible name unless the button is icon-only.
- 4
Optional icon
A leading or trailing glyph. It is decorative: an icon-only button still needs an aria-label.
Variants
Choose a surface treatment from the action's relative importance in its current region.
Filled
The strongest standard button treatment for an important action that completes or advances a flow.
- Use when
- A region has one clear primary action such as Save, Confirm, or Continue.
- Avoid when
- Several actions have equal importance or the surrounding surface is already visually dominant.
<m-button>Continue</m-button>Elevated
Adds separation from a visually busy or layered background while keeping semantic color on the label.
- Use when
- The button needs separation from imagery, a scrim, or another prominent surface.
- Avoid when
- A filled button already provides enough contrast or elevation would add unnecessary visual noise.
<m-button variant="elevated">Open details</m-button>Tonal
A contained secondary action with more presence than an outline and less dominance than filled.
- Use when
- A supporting step still needs a clear container, for example Next in onboarding.
- Avoid when
- The action is the final primary outcome or should remain intentionally quiet.
<m-button variant="tonal">Next</m-button>Outlined
Keeps a visible boundary without a filled container and pairs naturally with a primary action.
- Use when
- The action is important but secondary, such as Save draft beside Publish.
- Avoid when
- The background is visually complex or nearby chips make the control ambiguous.
<m-button variant="outlined">Save draft</m-button>Text
The quietest action treatment, with a container becoming visible only through interaction states.
- Use when
- Presenting low-priority actions in cards, dialogs, snackbars, or dense toolbars.
- Avoid when
- The action must be discovered immediately or sits on a visually prominent background.
<m-button variant="text">Cancel</m-button>Semantic colors
Color communicates role and consequence; it is never a free-form visual override. Switch the role and variant to see how the scheme stays connected to the theme.
Primary and secondary
Primary carries the key action; secondary supports an alternative without competing for attention.
Tertiary and error
Tertiary creates purposeful contrast. Error is reserved for destructive or failure-related actions.
Labels and icons
Slots let the same component cover text, mixed content, and icon-only actions. Pick a content preset to see the matching markup.
Label first
A visible label is the clearest default and becomes the control's accessible name.
Icon-only needs a name
Omit the default slot and supply prepend content together with an explicit aria-label.
Button and link behavior
Select the root behavior from intent, then keep native platform semantics intact.
type=button
The safe default for commands that must not submit a surrounding form.
submit and reset
Use native form behavior only when the button belongs to that form workflow.
tag=link
Use a Nuxt link for navigation so routing, opening behavior, and assistive technology remain correct.
to
Provide a Nuxt route destination when tag is link; it is ignored by the native button root.
Interaction states
Every variant resolves a complete M3 state scheme from static SCSS tokens.
Hover
A subtle state layer confirms that the action is interactive.
Pressed
The active state acknowledges the current pointer or touch activation.
Focus-visible
A visible outline appears for keyboard focus without replacing native semantics.
Disabled
Prevents interaction and reduces emphasis while preserving the label for context.
Loading
Shows progress, exposes aria-busy, and blocks repeated activation.
Initial
Uses the selected variant and semantic color without an interaction overlay.
In context
Real compositions built from kit components — the button doing its job inside a believable UI.
Team plan
$12 / user · billed monthly