Floating Action Button

Fab Props

Name
Type
Default
Description

colors

object

Object with Tailwind CSS colors classes

colors.activeBgIos

string

'active:bg-ios-primary-shade'

colors.activeBgMaterial

string

''

colors.bgIos

string

'bg-primary'

colors.bgMaterial

string

'bg-md-light-primary-container dark:bg-md-dark-primary-container'

colors.textIos

string

'text-white'

colors.textMaterial

string

'text-md-light-on-primary-container dark:text-md-dark-on-primary-container'

colors.touchRipple

string

'touch-ripple-primary dark:touch-ripple-white'

component

string

'a'

Component's HTML Element

href

string

Fab's link href attribute

text

string

Button text (content)

textPosition

'after' | 'before'

'after'

Text position, can be after icon or before icon

touchRipple

boolean

true

Enables touch ripple effect in Material theme

Fab Slots

Name
Description

icon

Fab's icon

text

Button text (content)

Examples

Last updated