Change changeset list from table to simple divs

This commit is contained in:
René Pfeuffer
2018-09-18 16:45:22 +02:00
parent 5c376e1c00
commit 03bfb92ec7
3 changed files with 93 additions and 35 deletions

View File

@@ -1,29 +1,24 @@
// @flow
import ChangesetRow from "./ChangesetRow";
import React from "react";
import type {Changeset} from "@scm-manager/ui-types";
type Props = {
changesets: Changeset[]
}
};
class ChangesetTable extends React.Component<Props> {
render() {
const {changesets} = this.props;
return <div>
<table className="table is-hoverable is-fullwidth is-striped is-bordered">
<thead>
<tr>
<th>Changesets</th>
</tr>
</thead>
<tbody>
{changesets.map((changeset, index) => {
return <ChangesetRow key={index} changeset={changeset}/>;
})}
</tbody>
</table>
</div>
const { changesets } = this.props;
const content = changesets.map((changeset, index) => {
return <ChangesetRow key={index} changeset={changeset} />;
});
return (
<div>
<hr />
{content}
</div>
);
}
}