Skip to content

Commit

Permalink
RunList: Make table much more compact
Browse files Browse the repository at this point in the history
  • Loading branch information
zmc committed May 16, 2023
1 parent 6f20b22 commit 3670e5c
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions src/components/RunList/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,45 +54,47 @@ const _columns = [
return Math.round((start - end) / 1000);
},
valueFormatter: (row) => formatDuration(row.value),
width: 70,
},
{
field: "suite",
},
{
field: "branch",
width: 350,
},
{
field: "machine_type",
width: 90,
},
{
field: "sha1",
headerName: "hash",
width: 75,
},
{
field: "queued",
valueGetter: resultsGetter,
width: 85,
width: 60,
},
{
field: "pass",
valueGetter: resultsGetter,
width: 85,
width: 60,
},
{
field: "fail",
valueGetter: resultsGetter,
width: 85,
width: 60,
},
{
field: "dead",
valueGetter: resultsGetter,
width: 85,
width: 60,
},
{
field: "running",
valueGetter: resultsGetter,
width: 85,
width: 60,
},
];

Expand All @@ -116,6 +118,7 @@ export default function RunList(props) {
};
const paginationMode = typeof dispatch === "function" ? "server" : "client";
const columns = [..._columns];
/* If we want to automatically size the branch column:
if (query.isSuccess) {
const branchLength = Math.max(
...query.data.map((item) => item.branch.length)
Expand All @@ -126,6 +129,7 @@ export default function RunList(props) {
}
});
}
*/
return (
<DataGrid
columns={columns}
Expand Down

0 comments on commit 3670e5c

Please sign in to comment.