File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -601,11 +601,13 @@ function EventSignalRail({
601601 details : ResourceDetails ;
602602 detailsError : string ;
603603 detailsLoading : boolean ;
604- onOpenResource : ( id : string ) => void ;
604+ onOpenResource : ( id : string , intent ?: "logs" | null ) => void ;
605605 resource : ResourceRow ;
606606} ) {
607607 const event = details . events [ 0 ] ;
608608 const target = referencedResources ( resource . references , allResources ) [ 0 ] ;
609+ const targetIsPod = target ?. kind === "Pod" ;
610+ const TargetActionIcon = targetIsPod ? FileText : Network ;
609611 const type = detailsLoading ? "Syncing" : event ?. type || resource . image || "Event" ;
610612 const reason = detailsLoading ? "Loading" : event ?. reason || resource . diagnostic || "Event" ;
611613 const message = detailsLoading
@@ -633,9 +635,9 @@ function EventSignalRail({
633635 < ActionFact label = "Target" value = { resource . owner || "unknown" } />
634636 </ div >
635637 { target ? (
636- < button type = "button" onClick = { ( ) => onOpenResource ( target . id ) } >
637- < Network size = { 15 } />
638- Open { target . kind }
638+ < button type = "button" onClick = { ( ) => onOpenResource ( target . id , targetIsPod ? "logs" : null ) } >
639+ < TargetActionIcon size = { 15 } />
640+ { targetIsPod ? " Open pod logs" : `Open $ {target . kind } ` }
639641 </ button >
640642 ) : null }
641643 </ div >
You can’t perform that action at this time.
0 commit comments