IconButton
IconButton
Compact tappable icon with ripple + state layer feedback.
Usage
Place inline actions inside Appbar, lists, or cards.
Highlights
- Size tokens (sm, md, lg)
- Supports toggle/disabled states
When to use it
- Actions are purely iconographic.
- You need secondary actions adjacent to content.
Examples
Default
Preview (Web)
import { IconButton } from 'react-native-molecules/components/IconButton'; export default function Example() { return <IconButton name="home-outline" onPress={() => console.log('Pressed')} />; }
| Prop | Type | Default | Description |
|---|---|---|---|
accessibilityLabel | string | undefined | — | — |
onPress | (((event: GestureResponderEvent) => void) & ((e: GestureResponderEvent) => void) & ((e: GestureResponderEvent) => void)) | undefined | — | — |
disabled | boolean | undefined | — | — |
nameRequired | string | — | — |
variant | IconButtonVariant | undefined | — | — |
selected | boolean | undefined | — | — |
size | number | "sm" | "md" | "lg" | "xs" | undefined | — | — |
type | "material-community" | "feather" | undefined | — | — |
animated | boolean | undefined | — | — |
style | StyleProp<TextStyle> | — | — |
iconStyle | StyleProp<TextStyle> | — | — |
color | string | undefined | — | — |
innerContainerStyle | ViewStyle | undefined | — | — |
stateLayerProps | ViewProps | undefined | — | — |