@@ -168,7 +168,7 @@ const PathAndQuery = styled(Column)`
168168
169169// Match Method + Status, but shrink right margin slightly so that
170170// spinner + "WebRTC Media" fits OK.
171- const RTCEventType = styled ( Column ) `
171+ const EventTypeColumn = styled ( Column ) `
172172 transition: flex-basis 0.1s;
173173 ${ ( p : { pinned ?: boolean } ) =>
174174 p . pinned
@@ -204,6 +204,13 @@ const RTCConnectionDetails = styled(RTCEventDetails)`
204204 text-align: center;
205205` ;
206206
207+ // Host + Path + Query columns:
208+ const BuiltInApiRequestDetails = styled ( Column ) `
209+ flex-shrink: 1;
210+ flex-grow: 0;
211+ flex-basis: 1000px;
212+ ` ;
213+
207214const EventListRow = styled . div `
208215 display: flex;
209216 flex-direction: row;
@@ -313,12 +320,21 @@ const EventRow = observer((props: EventRowProps) => {
313320 failure = { event }
314321 /> ;
315322 } else if ( event . isHttp ( ) ) {
316- return < ExchangeRow
317- index = { index }
318- isSelected = { isSelected }
319- style = { style }
320- exchange = { event }
321- /> ;
323+ if ( event . api ?. isBuiltInApi ) {
324+ return < BuiltInApiRow
325+ index = { index }
326+ isSelected = { isSelected }
327+ style = { style }
328+ exchange = { event }
329+ />
330+ } else {
331+ return < ExchangeRow
332+ index = { index }
333+ isSelected = { isSelected }
334+ style = { style }
335+ exchange = { event }
336+ /> ;
337+ }
322338 } else if ( event . isRTCConnection ( ) ) {
323339 return < RTCConnectionRow
324340 index = { index }
@@ -440,9 +456,9 @@ const RTCConnectionRow = observer(({
440456 >
441457 < RowPin pinned = { pinned } />
442458 < RowMarker category = { category } title = { describeEventCategory ( category ) } />
443- < RTCEventType >
459+ < EventTypeColumn >
444460 { ! event . closeState && < RTCConnectedIcon /> } WebRTC
445- </ RTCEventType >
461+ </ EventTypeColumn >
446462 < Source title = { event . source . summary } >
447463 < Icon
448464 { ...event . source . icon }
@@ -484,14 +500,14 @@ const RTCStreamRow = observer(({
484500 >
485501 < RowPin pinned = { pinned } />
486502 < RowMarker category = { category } title = { describeEventCategory ( category ) } />
487- < RTCEventType >
503+ < EventTypeColumn >
488504 { ! event . closeState && < RTCConnectedIcon /> } WebRTC {
489505 event . isRTCDataChannel ( )
490506 ? 'Data'
491507 : // RTCMediaTrack:
492508 'Media'
493509 }
494- </ RTCEventType >
510+ </ EventTypeColumn >
495511 < Source title = { event . rtcConnection . source . summary } >
496512 < Icon
497513 { ...event . rtcConnection . source . icon }
@@ -525,6 +541,52 @@ const RTCStreamRow = observer(({
525541 </ TrafficEventListRow > ;
526542} ) ;
527543
544+ const BuiltInApiRow = observer ( ( p : {
545+ index : number ,
546+ exchange : HttpExchange ,
547+ isSelected : boolean ,
548+ style : { }
549+ } ) => {
550+ const {
551+ request,
552+ pinned,
553+ category
554+ } = p . exchange ;
555+ const api = p . exchange . api ! ; // Only shown for built-in APIs, so this must be set
556+
557+ // Quick hack, but it works for our only two current examples:
558+ const name = api . service . name . split ( ' ' ) [ 0 ] ;
559+
560+ return < TrafficEventListRow
561+ role = "row"
562+ aria-label = 'row'
563+ aria-rowindex = { p . index + 1 }
564+ data-event-id = { p . exchange . id }
565+ tabIndex = { p . isSelected ? 0 : - 1 }
566+
567+ className = { p . isSelected ? 'selected' : '' }
568+ style = { p . style }
569+ >
570+ < RowPin pinned = { pinned } />
571+ < RowMarker category = { category } title = { describeEventCategory ( category ) } />
572+ < EventTypeColumn > { name } </ EventTypeColumn >
573+ < Source title = { request . source . summary } >
574+ < Icon
575+ { ...request . source . icon }
576+ fixedWidth = { true }
577+ />
578+ </ Source >
579+ < BuiltInApiRequestDetails >
580+ { api . operation . name } ({
581+ api . request . parameters
582+ . filter ( param => param . value !== undefined )
583+ . map ( param => `${ param . name } =${ JSON . stringify ( param . value ) } ` )
584+ . join ( ', ' )
585+ } )
586+ </ BuiltInApiRequestDetails >
587+ </ TrafficEventListRow >
588+ } ) ;
589+
528590const FailedRequestRow = observer ( ( p : {
529591 index : number ,
530592 failure : FailedTLSConnection ,
0 commit comments