Skip to content

Commit 6b439ab

Browse files
kamilkisielan1ru4l
authored andcommitted
asd
1 parent 0968a15 commit 6b439ab

File tree

1 file changed

+7
-11
lines changed

1 file changed

+7
-11
lines changed

packages/web/app/src/pages/target-traces.tsx

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1315,26 +1315,24 @@ function TraceView(props: { rootSpan: SpanProps; serviceNames: string[] }) {
13151315
);
13161316
}
13171317

1318-
function TraceSheet(props: { trace: Trace | null }) {
1318+
function TraceSheet(props: { trace: DocumentType<typeof TracesList_Trace> | null }) {
13191319
const targetRef = useTargetReference();
13201320
const [activeView, setActiveView] = useState<'attributes' | 'events' | 'operation'>('attributes');
13211321
const trace = props.trace;
13221322

1323-
return null;
1324-
13251323
if (!trace) {
13261324
return null;
13271325
}
13281326

13291327
const attributes: Array<TraceAttribute> = [
13301328
{
13311329
name: 'graphql.operationKind',
1332-
value: trace.kind,
1330+
value: trace.operationType,
13331331
category: 'GraphQL',
13341332
},
13351333
{
13361334
name: 'graphql.subgraphs',
1337-
value: trace.subgraphNames.join(', '),
1335+
value: trace.subgraphs.join(', '),
13381336
category: 'GraphQL',
13391337
},
13401338
{
@@ -1359,7 +1357,7 @@ function TraceSheet(props: { trace: Trace | null }) {
13591357
},
13601358
{
13611359
name: 'http.status',
1362-
value: trace.httpStatus,
1360+
value: trace.httpStatusCode,
13631361
category: 'HTTP',
13641362
},
13651363
];
@@ -1373,7 +1371,7 @@ function TraceSheet(props: { trace: Trace | null }) {
13731371
<SheetTitle className="text-lg font-medium text-white">
13741372
{trace.operationName}
13751373
<span className="text-muted-foreground ml-2 font-mono font-normal">
1376-
{trace.operationHash.substring(0, 4)}
1374+
{trace.id.substring(0, 4)}
13771375
</span>
13781376
</SheetTitle>
13791377
</div>
@@ -1389,12 +1387,10 @@ function TraceSheet(props: { trace: Trace | null }) {
13891387
variant="outline"
13901388
className={cn(
13911389
'rounded-sm border-0 px-1 font-medium uppercase',
1392-
trace.status === 'ok'
1393-
? 'bg-green-900/30 text-green-400'
1394-
: 'bg-red-900/30 text-red-400',
1390+
trace.success ? 'bg-green-900/30 text-green-400' : 'bg-red-900/30 text-red-400',
13951391
)}
13961392
>
1397-
{trace.status}
1393+
{trace.success ? 'Ok' : 'Error'}
13981394
</Badge>
13991395
<span className="font-mono uppercase text-gray-300">
14001396
{formatDate(trace.timestamp, 'MMM dd HH:mm:ss')}

0 commit comments

Comments
 (0)