Changed blocked instances to not be linked from instance page (#2121)

Co-authored-by: Beehaw Dev <dev@beehaw.dev>
Co-authored-by: SleeplessOne1917 <abias1122@gmail.com>
This commit is contained in:
Security-Chief-Odo 2023-09-12 15:56:22 -05:00 committed by GitHub
parent 5e91a4d9af
commit f9f8233d6f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -102,7 +102,9 @@ export class Instances extends Component<any, InstancesState> {
active: isSelected, active: isSelected,
})} })}
> >
{this.itemList(instances[status])} {status === "blocked"
? this.itemList(instances[status], false)
: this.itemList(instances[status])}
</div> </div>
), ),
}))} }))}
@ -128,7 +130,7 @@ export class Instances extends Component<any, InstancesState> {
); );
} }
itemList(items: Instance[]) { itemList(items: Instance[], link = true) {
return items.length > 0 ? ( return items.length > 0 ? (
<div className="table-responsive"> <div className="table-responsive">
<table id="instances_table" className="table table-sm table-hover"> <table id="instances_table" className="table table-sm table-hover">
@ -143,9 +145,13 @@ export class Instances extends Component<any, InstancesState> {
{items.map(i => ( {items.map(i => (
<tr key={i.domain}> <tr key={i.domain}>
<td> <td>
<a href={`https://${i.domain}`} rel={relTags}> {link ? (
{i.domain} <a href={`https://${i.domain}`} rel={relTags}>
</a> {i.domain}{" "}
</a>
) : (
<span>{i.domain}</span>
)}
</td> </td>
<td>{i.software}</td> <td>{i.software}</td>
<td>{i.version}</td> <td>{i.version}</td>