@@ -14,6 +14,7 @@ import { assertNever } from "assert-never";
1414import { useEffect } from "react" ;
1515import { typedjson , useTypedFetcher } from "remix-typedjson" ;
1616import { ExitIcon } from "~/assets/icons/ExitIcon" ;
17+ import { FlagIcon } from "~/assets/icons/RegionIcons" ;
1718import { AdminDebugRun } from "~/components/admin/debugRun" ;
1819import { CodeBlock } from "~/components/code/CodeBlock" ;
1920import { EnvironmentCombo } from "~/components/environments/EnvironmentLabel" ;
@@ -22,6 +23,7 @@ import { MachineLabelCombo } from "~/components/MachineLabelCombo";
2223import { MachineTooltipInfo } from "~/components/MachineTooltipInfo" ;
2324import { Button , LinkButton } from "~/components/primitives/Buttons" ;
2425import { Callout } from "~/components/primitives/Callout" ;
26+ import { CopyableText } from "~/components/primitives/CopyableText" ;
2527import { DateTime , DateTimeAccurate } from "~/components/primitives/DateTime" ;
2628import { Header2 , Header3 } from "~/components/primitives/Headers" ;
2729import { Paragraph } from "~/components/primitives/Paragraph" ;
@@ -76,7 +78,6 @@ import {
7678} from "~/utils/pathBuilder" ;
7779import { createTimelineSpanEventsFromSpanEvents } from "~/utils/timelineSpanEvents" ;
7880import { CompleteWaitpointForm } from "../resources.orgs.$organizationSlug.projects.$projectParam.env.$envParam.waitpoints.$waitpointFriendlyId.complete/route" ;
79- import { FlagIcon } from "~/assets/icons/RegionIcons" ;
8081
8182export const loader = async ( { request, params } : LoaderFunctionArgs ) => {
8283 const { projectParam, organizationSlug, envParam, runParam, spanParam } =
@@ -409,6 +410,7 @@ function RunBody({
409410 < SimpleTooltip
410411 button = { < TaskRunStatusCombo status = { run . status } /> }
411412 content = { descriptionForTaskRunStatus ( run . status ) }
413+ disableHoverableContent
412414 />
413415 </ Property . Value >
414416 </ Property . Item >
@@ -422,82 +424,129 @@ function RunBody({
422424 tasks : [ run . taskIdentifier ] ,
423425 } ) }
424426 >
425- { run . taskIdentifier }
427+ < CopyableText
428+ value = { run . taskIdentifier }
429+ copyValue = { run . taskIdentifier }
430+ asChild
431+ />
426432 </ TextLink >
427433 }
428- content = { `Filter runs by ${ run . taskIdentifier } ` }
434+ content = { `View runs filtered by ${ run . taskIdentifier } ` }
435+ disableHoverableContent
429436 />
430437 </ Property . Value >
431438 </ Property . Item >
432439 { run . relationships . root ? (
433440 run . relationships . root . isParent ? (
434441 < Property . Item >
435- < Property . Label > Root & Parent </ Property . Label >
442+ < Property . Label > Root & Parent run </ Property . Label >
436443 < Property . Value >
437- < TextLink
438- to = { v3RunSpanPath (
439- organization ,
440- project ,
441- environment ,
442- {
443- friendlyId : run . relationships . root . friendlyId ,
444- } ,
445- { spanId : run . relationships . root . spanId }
446- ) }
447- className = "group flex flex-wrap items-center gap-x-1 gap-y-0"
448- >
449- { run . relationships . root . taskIdentifier }
450- < span className = "break-all text-text-dimmed transition-colors group-hover:text-text-bright/80" >
451- ({ run . relationships . root . friendlyId } )
452- </ span >
453- </ TextLink >
454- </ Property . Value >
455- </ Property . Item >
456- ) : (
457- < >
458- < Property . Item >
459- < Property . Label > Root</ Property . Label >
460- < Property . Value >
461- < TextLink
462- to = { v3RunSpanPath (
463- organization ,
464- project ,
465- environment ,
466- {
467- friendlyId : run . relationships . root . friendlyId ,
468- } ,
469- { spanId : run . relationships . root . spanId }
470- ) }
471- className = "group flex flex-wrap items-center gap-x-1 gap-y-0"
472- >
473- { run . relationships . root . taskIdentifier }
474- < span className = "break-all text-text-dimmed transition-colors group-hover:text-text-bright/80" >
475- ({ run . relationships . root . friendlyId } )
476- </ span >
477- </ TextLink >
478- </ Property . Value >
479- </ Property . Item >
480- { run . relationships . parent ? (
481- < Property . Item >
482- < Property . Label > Parent</ Property . Label >
483- < Property . Value >
444+ < SimpleTooltip
445+ button = {
484446 < TextLink
485447 to = { v3RunSpanPath (
486448 organization ,
487449 project ,
488450 environment ,
489451 {
490- friendlyId : run . relationships . parent . friendlyId ,
452+ friendlyId : run . relationships . root . friendlyId ,
491453 } ,
492- { spanId : run . relationships . parent . spanId }
454+ { spanId : run . relationships . root . spanId }
493455 ) }
494456 className = "group flex flex-wrap items-center gap-x-1 gap-y-0"
495457 >
496- { run . relationships . parent . taskIdentifier }
458+ < CopyableText
459+ value = { run . relationships . root . taskIdentifier }
460+ copyValue = { run . relationships . root . taskIdentifier }
461+ asChild
462+ />
497463 < span className = "break-all text-text-dimmed transition-colors group-hover:text-text-bright/80" >
498- ({ run . relationships . parent . friendlyId } )
464+ < CopyableText
465+ value = { run . relationships . root . friendlyId }
466+ copyValue = { run . relationships . root . friendlyId }
467+ asChild
468+ />
499469 </ span >
500470 </ TextLink >
471+ }
472+ content = { `Jump to root/parent run` }
473+ disableHoverableContent
474+ />
475+ </ Property . Value >
476+ </ Property . Item >
477+ ) : (
478+ < >
479+ < Property . Item >
480+ < Property . Label > Root run</ Property . Label >
481+ < Property . Value >
482+ < SimpleTooltip
483+ button = {
484+ < TextLink
485+ to = { v3RunSpanPath (
486+ organization ,
487+ project ,
488+ environment ,
489+ {
490+ friendlyId : run . relationships . root . friendlyId ,
491+ } ,
492+ { spanId : run . relationships . root . spanId }
493+ ) }
494+ className = "group flex flex-wrap items-center gap-x-1 gap-y-0"
495+ >
496+ < CopyableText
497+ value = { run . relationships . root . taskIdentifier }
498+ copyValue = { run . relationships . root . taskIdentifier }
499+ asChild
500+ />
501+ < span className = "break-all text-text-dimmed transition-colors group-hover:text-text-bright/80" >
502+ < CopyableText
503+ value = { run . relationships . root . friendlyId }
504+ copyValue = { run . relationships . root . friendlyId }
505+ asChild
506+ />
507+ </ span >
508+ </ TextLink >
509+ }
510+ content = { `Jump to root run` }
511+ disableHoverableContent
512+ />
513+ </ Property . Value >
514+ </ Property . Item >
515+ { run . relationships . parent ? (
516+ < Property . Item >
517+ < Property . Label > Parent run</ Property . Label >
518+ < Property . Value >
519+ < SimpleTooltip
520+ button = {
521+ < TextLink
522+ to = { v3RunSpanPath (
523+ organization ,
524+ project ,
525+ environment ,
526+ {
527+ friendlyId : run . relationships . parent . friendlyId ,
528+ } ,
529+ { spanId : run . relationships . parent . spanId }
530+ ) }
531+ className = "group flex flex-wrap items-center gap-x-1 gap-y-0"
532+ >
533+ < CopyableText
534+ value = { run . relationships . parent . taskIdentifier }
535+ copyValue = { run . relationships . parent . taskIdentifier }
536+ asChild
537+ />
538+ < span className = "break-all text-text-dimmed transition-colors group-hover:text-text-bright/80" >
539+ < CopyableText
540+ value = { run . relationships . parent . friendlyId }
541+ copyValue = { run . relationships . parent . friendlyId }
542+ asChild
543+ />
544+ </ span >
545+ </ TextLink >
546+ }
547+ content = { `Jump to parent run` }
548+ disableHoverableContent
549+ />
501550 </ Property . Value >
502551 </ Property . Item >
503552 ) : null }
@@ -511,10 +560,15 @@ function RunBody({
511560 < SimpleTooltip
512561 button = {
513562 < TextLink to = { v3BatchPath ( organization , project , environment , run . batch ) } >
514- { run . batch . friendlyId }
563+ < CopyableText
564+ value = { run . batch . friendlyId }
565+ copyValue = { run . batch . friendlyId }
566+ asChild
567+ />
515568 </ TextLink >
516569 }
517- content = { `Jump to ${ run . batch . friendlyId } ` }
570+ content = { `View batches filtered by ${ run . batch . friendlyId } ` }
571+ disableHoverableContent
518572 />
519573 </ Property . Value >
520574 </ Property . Item >
@@ -540,7 +594,7 @@ function RunBody({
540594 < Property . Value >
541595 { run . version ? (
542596 environment . type === "DEVELOPMENT" ? (
543- run . version
597+ < CopyableText value = { run . version } copyValue = { run . version } asChild />
544598 ) : (
545599 < SimpleTooltip
546600 button = {
@@ -553,7 +607,7 @@ function RunBody({
553607 ) }
554608 className = "group flex flex-wrap items-center gap-x-1 gap-y-0"
555609 >
556- { run . version }
610+ < CopyableText value = { run . version } copyValue = { run . version } asChild />
557611 </ TextLink >
558612 }
559613 content = { "Jump to deployment" }
@@ -606,13 +660,23 @@ function RunBody({
606660 < Property . Item >
607661 < Property . Label > Replayed from</ Property . Label >
608662 < Property . Value >
609- < TextLink
610- to = { v3RunRedirectPath ( organization , project , {
611- friendlyId : run . replayedFromTaskRunFriendlyId ,
612- } ) }
613- >
614- { run . replayedFromTaskRunFriendlyId }
615- </ TextLink >
663+ < SimpleTooltip
664+ button = {
665+ < TextLink
666+ to = { v3RunRedirectPath ( organization , project , {
667+ friendlyId : run . replayedFromTaskRunFriendlyId ,
668+ } ) }
669+ >
670+ < CopyableText
671+ value = { run . replayedFromTaskRunFriendlyId }
672+ copyValue = { run . replayedFromTaskRunFriendlyId }
673+ asChild
674+ />
675+ </ TextLink >
676+ }
677+ content = { `Jump to replayed run` }
678+ disableHoverableContent
679+ />
616680 </ Property . Value >
617681 </ Property . Item >
618682 ) }
@@ -747,11 +811,15 @@ function RunBody({
747811 </ Property . Item >
748812 < Property . Item >
749813 < Property . Label > Run ID</ Property . Label >
750- < Property . Value > { run . friendlyId } </ Property . Value >
814+ < Property . Value >
815+ < CopyableText value = { run . friendlyId } copyValue = { run . friendlyId } asChild />
816+ </ Property . Value >
751817 </ Property . Item >
752818 < Property . Item >
753819 < Property . Label > Internal ID</ Property . Label >
754- < Property . Value > { run . id } </ Property . Value >
820+ < Property . Value >
821+ < CopyableText value = { run . id } copyValue = { run . id } asChild />
822+ </ Property . Value >
755823 </ Property . Item >
756824 < Property . Item >
757825 < Property . Label > Run Engine</ Property . Label >
0 commit comments