If application has no URL, render text only (#25138)

Fixes #25124

Signed-off-by: Stan Silvert <ssilvert@redhat.com>
This commit is contained in:
Stan Silvert 2023-11-30 14:05:06 -05:00 committed by GitHub
parent 386e4ea8d4
commit 8a9b83d016
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -128,15 +128,22 @@ const Applications = () => {
className="pf-u-align-items-center"
dataListCells={[
<DataListCell width={2} key={`client${application.clientId}`}>
<Button
className="pf-u-pl-0 title-case"
component="a"
variant="link"
onClick={() => window.open(application.effectiveUrl)}
>
{application.clientName || application.clientId}{" "}
<ExternalLinkAltIcon />
</Button>
{application.effectiveUrl && (
<Button
className="pf-u-pl-0 title-case"
component="a"
variant="link"
onClick={() => window.open(application.effectiveUrl)}
>
{application.clientName || application.clientId}{" "}
<ExternalLinkAltIcon />
</Button>
)}
{!application.effectiveUrl && (
<span>
{application.clientName || application.clientId}
</span>
)}
</DataListCell>,
<DataListCell
width={2}