mirror of
https://github.com/argoproj/argo-cd
synced 2026-05-24 09:50:08 +00:00
parent
a123f0bd37
commit
43d2848c12
1 changed files with 2 additions and 2 deletions
|
|
@ -2,7 +2,7 @@ import * as React from 'react';
|
|||
import {repoUrl} from './urls';
|
||||
|
||||
export const Repo = ({url, children}: { url: string, children?: React.ReactNode }) => {
|
||||
url = repoUrl(url);
|
||||
const href = repoUrl(url);
|
||||
const content = children || url;
|
||||
return url !== null ? <a href={url}>{content}</a> : <span>{content}</span>;
|
||||
return href !== null ? <a href={href}>{content}</a> : <span>{content}</span>;
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue