1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 import * as React from "react";
6 import { Table, TableHead, TableCell, TableRow, TableBody, StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core';
7 import { navigateTo } from "~/store/navigation/navigation-action";
9 type CssRules = 'cell';
11 const styles: StyleRulesCallback<CssRules> = theme => ({
13 paddingRight: theme.spacing.unit * 2
17 interface MetadataTable {
26 interface MetadataProps {
27 items: MetadataTable[];
30 export const MetadataTab = withStyles(styles)((props: MetadataProps & WithStyles<CssRules>) =>
34 <TableCell>uuid</TableCell>
35 <TableCell>link_class</TableCell>
36 <TableCell>name</TableCell>
37 <TableCell>tail</TableCell>
38 <TableCell>head</TableCell>
39 <TableCell>properties</TableCell>
43 {props.items.map((it, index) => {
45 <TableRow key={index}>
46 <TableCell className={props.classes.cell}>{it.uuid}</TableCell>
47 <TableCell className={props.classes.cell}>{it.linkClass}</TableCell>
48 <TableCell className={props.classes.cell}>{it.name}</TableCell>
49 <TableCell className={props.classes.cell}>{it.tailUuid}</TableCell>
50 <TableCell className={props.classes.cell}>{it.headUuid}</TableCell>
51 <TableCell className={props.classes.cell}>{JSON.stringify(it.properties, null, 2)}</TableCell>