2021-01-05 05:25:08 +00:00
|
|
|
import React from 'react';
|
2021-01-05 07:17:17 +00:00
|
|
|
import { Button, Card, Col, Container, Modal, Row } from 'react-bootstrap';
|
2021-01-05 05:25:08 +00:00
|
|
|
|
2021-01-05 07:17:17 +00:00
|
|
|
function CollectionSelector({ modalView, closeModal, showModal, collections }) {
|
2021-01-05 07:23:28 +00:00
|
|
|
const CollectionIcons = collections.map((item) => (
|
2021-01-05 07:17:17 +00:00
|
|
|
<Card style={{ width: '30%' }}>
|
2021-01-05 07:23:28 +00:00
|
|
|
<Card.Body>{item.name}</Card.Body>{' '}
|
2021-01-05 07:17:17 +00:00
|
|
|
</Card>
|
|
|
|
));
|
|
|
|
console.log(CollectionIcons);
|
2021-01-05 05:25:08 +00:00
|
|
|
return (
|
2021-01-05 07:17:17 +00:00
|
|
|
<Modal
|
|
|
|
show={modalView}
|
|
|
|
aria-labelledby='contained-modal-title-vcenter'
|
|
|
|
centered
|
|
|
|
onHide={closeModal}
|
|
|
|
>
|
|
|
|
<Modal.Header closeButton>
|
|
|
|
<Modal.Title id='contained-modal-title-vcenter'>
|
|
|
|
Modal heading
|
|
|
|
</Modal.Title>
|
|
|
|
</Modal.Header>
|
|
|
|
<Modal.Body>
|
|
|
|
<Container>
|
|
|
|
<Row>{CollectionIcons}</Row>
|
|
|
|
</Container>
|
|
|
|
</Modal.Body>
|
|
|
|
<Modal.Footer>
|
|
|
|
<Button onClick={closeModal}>Close</Button>
|
|
|
|
</Modal.Footer>
|
|
|
|
</Modal>
|
2021-01-05 05:25:08 +00:00
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
export default CollectionSelector;
|