FloatingActionButton

Persistent action button that floats above the page. Three sizes, three variants, optional extended pill with label.

Pass position to anchor the FAB to a viewport edge (default: bottom-right). Use position="static" to place inline.

Usage

import { FloatingActionButton, FAB } from '@bwo-ui/react';

<FAB icon={<PlusIcon />} label="New item" />

<FAB icon={<PlusIcon />} variant="accent" position="bottom-right" />

Props

PropTypeDefaultDescription
iconReactNodeIcon element rendered inside the button.
labelReactNodeWhen present, the FAB renders in extended pill mode.
size'sm' | 'md' | 'lg''md'Size preset.
variant'primary' | 'accent' | 'surface''primary'Color variant.
position'bottom-right' | 'bottom-left' | 'top-right' | 'top-left' | 'bottom-center' | 'static''bottom-right'Viewport anchor. Use static to render inline.
offsetnumber24Distance (px) from the viewport edge.