1.0.2 • Published 9 years ago
zooid-ui-alerts v1.0.2
zooid-ui-alerts
React component for messages & alerts.
Install
npm install --save zooid-ui-alerts
Props
Prop | Type | Default | Description |
---|---|---|---|
children | node | Body of your alert. Pass in html. | |
className | string | Additional css classes for your alert | |
dismissible | boolean | Determines whether to render 'dismiss' button | |
type | string | 'info' | What kind of alert: 'info', 'warning', 'error', or 'success' |
Example
import React, { Component } from 'react'
import Alert from 'zooid-ui-alerts'
export default class App extends Component {
render() {
return <div>
<h1>App</h1>
<Alert dismissible={true} type='warning'>
<div>
This is a warning message
</div>
</Alert>
</div>
}
}