import React from 'react' import { Card, Divider, Typography } from '@material-ui/core' import StatusIcon from 'components/StatusIcon' import { theme } from 'theme' import { PipelineJobRun } from '../../sharedTypes' import { augmentOcrTasksList } from '../augmentOcrTasksList' export const PipelineJobRunOverview = ({ jobRun, }: { jobRun: PipelineJobRun }) => ( {augmentOcrTasksList({ jobRun }).map((node, index) => { const { error, status, type, output, ...customAttributes } = node.attributes return ( {index > 0 && }
{status} {node.id}{' '} {type} {['completed', 'errored'].includes(status) && ( {status === 'completed' ? output : error} )} {status !== 'not_run' && Object.entries(customAttributes).map(([key, value]) => ( {key} : {value} ))}
) })}
)