1
0
mirror of https://github.com/ascribe/onion.git synced 2024-06-30 21:52:08 +02:00
onion/js/components/ascribe_accordion_list/accordion_list_item.js

37 lines
1.3 KiB
JavaScript
Raw Normal View History

'use strict';
import React from 'react';
import { getLangText } from '../../utils/lang_utils';
let AccordionListItem = React.createClass({
propTypes: {
className: React.PropTypes.string,
content: React.PropTypes.object,
children: React.PropTypes.object
},
render() {
return (
<div className="row">
<div className={this.props.className}>
<div className="wrapper">
2015-07-01 10:53:40 +02:00
<div className="col-xs-5 col-sm-5 col-md-4 col-lg-4 thumbnail-wrapper">
<img src={this.props.content.thumbnail} />
</div>
2015-07-01 12:17:50 +02:00
<div className="col-xs-7 col-sm-7 col-md-7 col-lg-7 col-md-offset-1 col-lg-offset-1 accordion-list-item-header">
<h1>{this.props.content.title}</h1>
<h3>{getLangText('by %s', this.props.content.artist_name)}</h3>
2015-06-03 16:34:32 +02:00
<h3>{this.props.content.date_created.split('-')[0]}</h3>
</div>
<span style={{'clear': 'both'}}></span>
</div>
</div>
{this.props.children}
</div>
);
}
});
export default AccordionListItem;