A basic button that inherits from Base, and provides colourization based upon background color configuration.
type: string
defaultValue: 'info'
stretch the button width *
type: bool
defaultValue: false
disables the button, and reduces its opacity *
type: bool
defaultValue: false
the text string for the button. alternatively, pass a Text as a child *
type: string
type: func
defaultValue: 2
style text colour when using label prop *
type: string
defaultValue: 'white'
type: string
defaultValue: 'darken'
import { Button } from 'panza'
<Button onPress={() => console.log('hello world')}>
Default Button
</Button>
import { Button } from 'panza'
<Button
block
onPress={() => console.log('hello world')}>
Button with Block
</Button>
import { Button, SecondaryText } from 'panza'
<Button
onPress={() => console.log('hello world')}
p={1}>
<SecondaryText color='white'>
Button with custom text style & padding
</SecondaryText>
</Button>
import { SuccessButton, PlusIcon, SecondaryText } from 'panza'
<SuccessButton
p={0}
px={1}
onPress={() => console.log('onPress')}>
<PlusIcon color='white' mr={1}/>
<SecondaryText color='white'>Add Another</SecondaryText>
</SuccessButton>