IconButton
An icon button is a button which displays only an icon without a label. By default button has 150% size of the icon.
Usage
import * as React from 'react';
import { IconButton, Colors } from 'react-native-paper';
const MyComponent = () => (
<IconButton
icon="camera"
color={Colors.red500}
size={20}
onPress={() => console.log('Pressed')}
/>
);
export default MyComponent;
Props
disabled
Type:
boolean
Whether the button is disabled. A disabled button is greyed out and onPress
is not called on touch.
accessibilityLabel
Type:
string
Accessibility label for the button. This is read by the screen reader when the user taps the button.
style
Type:
StyleProp<ViewStyle>
ref
Type:
React.RefObject<TouchableWithoutFeedback>
theme
Type:
Theme