import * as React from 'react'; import { Link } from 'react-router-dom'; import GitRepoLink from '~/components/GitLink/GitRepoLink'; import SnapshotComponentImage from '~/components/SnapshotDetails/tabs/SnapshotComponentImage'; import { COMMIT_DETAILS_PATH, COMPONENT_DETAILS_PATH } from '~/routes/paths'; import { RowFunctionArgs, TableData } from '~/shared/components/table'; import { useNamespace } from '~/shared/providers/Namespace'; import { commitsTableColumnClasses } from './SnapshotComponentsListHeader'; export type SnapshotComponentTableData = { metadata: { uid: string; name: string }; name: string; containerImage: string; application: string; source?: { git?: { url: string; revision: string } }; }; const SnapshotComponentsListRow: React.FC< React.PropsWithChildren> > = ({ obj }) => { const namespace = useNamespace(); return ( <> {obj.name} {obj.source?.git && ( )} {obj.source?.git?.revision ? ( {obj.source?.git?.revision} ) : ( '-' )} ); }; export default SnapshotComponentsListRow;