2018-09-17 14:03:13 +02:00
|
|
|
// @flow
|
|
|
|
|
import ChangesetRow from "./ChangesetRow";
|
|
|
|
|
import React from "react";
|
2018-09-19 09:49:24 +02:00
|
|
|
import type { Changeset } from "@scm-manager/ui-types";
|
|
|
|
|
import classNames from "classnames";
|
2018-09-17 14:03:13 +02:00
|
|
|
|
|
|
|
|
type Props = {
|
|
|
|
|
changesets: Changeset[]
|
2018-09-18 16:45:22 +02:00
|
|
|
};
|
2018-09-17 14:03:13 +02:00
|
|
|
|
|
|
|
|
class ChangesetTable extends React.Component<Props> {
|
|
|
|
|
render() {
|
2018-09-18 16:45:22 +02:00
|
|
|
const { changesets } = this.props;
|
|
|
|
|
const content = changesets.map((changeset, index) => {
|
|
|
|
|
return <ChangesetRow key={index} changeset={changeset} />;
|
|
|
|
|
});
|
2018-09-19 09:49:24 +02:00
|
|
|
return <div className={classNames("box")}>{content}</div>;
|
2018-09-17 14:03:13 +02:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default ChangesetTable;
|