2018-07-06 11:45:36 +00:00
|
|
|
import React from 'react';
|
|
|
|
import { PropTypes } from 'prop-types';
|
|
|
|
import './style.scss';
|
|
|
|
|
|
|
|
const RelatedInterviewsList = props => (
|
|
|
|
<div className="related-interviews-list">
|
|
|
|
<h4>Related <br />Interviews</h4>
|
|
|
|
<ul>
|
2018-07-06 12:36:22 +00:00
|
|
|
{ props.data.map(interview => (
|
|
|
|
// eslint-disable-next-line
|
|
|
|
<li
|
|
|
|
id={interview.id}
|
|
|
|
key={interview.id}
|
|
|
|
onClick={props.toggleSingleInterview}
|
|
|
|
>
|
|
|
|
{ interview.name }
|
|
|
|
</li>
|
|
|
|
))
|
2018-07-06 11:45:36 +00:00
|
|
|
}
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
);
|
|
|
|
|
|
|
|
RelatedInterviewsList.propTypes = {
|
2018-07-09 14:29:38 +00:00
|
|
|
data: PropTypes.arrayOf(PropTypes.shape({})).isRequired,
|
2018-07-06 11:45:36 +00:00
|
|
|
toggleSingleInterview: PropTypes.func.isRequired,
|
2018-07-06 12:36:22 +00:00
|
|
|
};
|
2018-07-06 11:45:36 +00:00
|
|
|
|
|
|
|
export default RelatedInterviewsList;
|