1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 import React from "react";
6 import { compose } from 'redux';
7 import { withStyles, Dialog, DialogTitle, DialogContent, DialogActions, Button, StyleRulesCallback, WithStyles, Grid } from '@material-ui/core';
8 import { WithDialogProps, withDialog } from "store/dialog/with-dialog";
9 import { LINK_ATTRIBUTES_DIALOG } from 'store/link-panel/link-panel-actions';
10 import { ArvadosTheme } from 'common/custom-theme';
11 import { LinkResource } from 'models/link';
13 type CssRules = 'root';
15 const styles: StyleRulesCallback<CssRules> = (theme: ArvadosTheme) => ({
18 '& div:nth-child(odd)': {
20 color: theme.palette.grey["500"]
25 interface AttributesLinkDialogDataProps {
29 export const AttributesLinkDialog = compose(
30 withDialog(LINK_ATTRIBUTES_DIALOG),
32 ({ open, closeDialog, data, classes }: WithDialogProps<AttributesLinkDialogDataProps> & WithStyles<CssRules>) =>
37 <DialogTitle>Attributes</DialogTitle>
39 {data.link && <Grid container direction="row" spacing={16} className={classes.root}>
40 <Grid item xs={5}>Uuid</Grid>
41 <Grid item xs={7}>{data.link.uuid}</Grid>
42 <Grid item xs={5}>Name</Grid>
43 <Grid item xs={7}>{data.link.name}</Grid>
44 <Grid item xs={5}>Head uuid</Grid>
45 <Grid item xs={7}>{data.link.headUuid}</Grid>
46 <Grid item xs={5}>Head kind</Grid>
47 <Grid item xs={7}>{data.link.headKind}</Grid>
48 <Grid item xs={5}>Tail uuid</Grid>
49 <Grid item xs={7}>{data.link.tailUuid}</Grid>
50 <Grid item xs={5}>Link class</Grid>
51 <Grid item xs={7}>{data.link.linkClass}</Grid>
52 <Grid item xs={5}>Owner uuid</Grid>
53 <Grid item xs={7}>{data.link.ownerUuid}</Grid>
54 <Grid item xs={5}>Created at</Grid>
55 <Grid item xs={7}>{data.link.createdAt}</Grid>
56 <Grid item xs={5}>Modified at</Grid>
57 <Grid item xs={7}>{data.link.modifiedAt}</Grid>
58 <Grid item xs={5}>Modified by user uuid</Grid>
59 <Grid item xs={7}>{data.link.modifiedByUserUuid}</Grid>
60 <Grid item xs={5}>Modified by client uuid</Grid>
61 <Grid item xs={7}>{data.link.modifiedByClientUuid}</Grid>
68 onClick={closeDialog}>