Blame view
imports/ui/components/documents-list.js
467 Bytes
d1f05315d
|
1 |
import React from 'react'; |
76dd62c7b
|
2 |
import { ListGroup, Alert } from 'react-bootstrap'; |
f0c912bf1
|
3 |
import { Document } from './document.js'; |
d1f05315d
|
4 |
|
f0c912bf1
|
5 6 7 8 9 10 11 12 |
export const DocumentsList = ({ documents }) => ( documents.length > 0 ? <ListGroup className="documents-list"> {documents.map((doc) => ( <Document key={ doc._id } document={ doc } /> ))} </ListGroup> : <Alert bsStyle="warning">No documents yet.</Alert> ); |
76dd62c7b
|
13 14 15 16 |
DocumentsList.propTypes = { documents: React.PropTypes.array, }; |