2016-07-07 23:23:18 +02:00
|
|
|
import React, { Component, PropTypes } from "react";
|
2016-08-01 00:26:52 +02:00
|
|
|
import Immutable from "immutable";
|
2016-07-07 23:23:18 +02:00
|
|
|
|
|
|
|
import FilterablePaginatedGrid from "./elements/Grid";
|
|
|
|
|
2016-08-01 00:26:52 +02:00
|
|
|
class Artists extends Component {
|
2016-07-07 23:23:18 +02:00
|
|
|
render () {
|
2016-08-01 00:26:52 +02:00
|
|
|
const grid = {
|
|
|
|
isFetching: this.props.isFetching,
|
|
|
|
items: this.props.artists,
|
2016-08-02 13:07:12 +02:00
|
|
|
itemsType: "artist",
|
2016-08-01 00:26:52 +02:00
|
|
|
itemsLabel: "app.common.artist",
|
|
|
|
subItemsType: "albums",
|
|
|
|
subItemsLabel: "app.common.album"
|
|
|
|
};
|
2016-07-07 23:23:18 +02:00
|
|
|
return (
|
2016-08-01 00:26:52 +02:00
|
|
|
<FilterablePaginatedGrid grid={grid} pagination={this.props.pagination} />
|
2016-07-07 23:23:18 +02:00
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
Artists.propTypes = {
|
2016-08-01 00:26:52 +02:00
|
|
|
isFetching: PropTypes.bool.isRequired,
|
|
|
|
artists: PropTypes.instanceOf(Immutable.List).isRequired,
|
|
|
|
pagination: PropTypes.object.isRequired,
|
2016-07-07 23:23:18 +02:00
|
|
|
};
|
2016-08-01 00:26:52 +02:00
|
|
|
|
|
|
|
export default Artists;
|