They've changed their default settings, this changes a lot of stuff in our code base.
38 lines
1008 B
JavaScript
38 lines
1008 B
JavaScript
import React from "react";
|
|
import PropTypes from "prop-types";
|
|
import { Map } from "immutable";
|
|
|
|
import { Season } from "./season";
|
|
|
|
export const SeasonsList = (props) => (
|
|
<div className="col col-12 col-md-10 offset-md-1">
|
|
{props.data
|
|
.get("seasons")
|
|
.entrySeq()
|
|
.map(function ([season, data]) {
|
|
if (season === 0) {
|
|
return null;
|
|
}
|
|
return (
|
|
<Season
|
|
key={`season-list-key-${season}`}
|
|
data={data}
|
|
season={season}
|
|
showName={props.data.get("title")}
|
|
addTorrent={props.addTorrent}
|
|
addToWishlist={props.addToWishlist}
|
|
getEpisodeDetails={props.getEpisodeDetails}
|
|
refreshSubtitles={props.refreshSubtitles}
|
|
/>
|
|
);
|
|
})}
|
|
</div>
|
|
);
|
|
SeasonsList.propTypes = {
|
|
data: PropTypes.instanceOf(Map),
|
|
addToWishlist: PropTypes.func,
|
|
addTorrent: PropTypes.func,
|
|
refreshSubtitles: PropTypes.func,
|
|
getEpisodeDetails: PropTypes.func,
|
|
};
|