@@ -120,6 +120,9 @@ const typeMetaMap: Record<FilterType, TypeMeta> = {
120120 } ,
121121} ;
122122
123+ const clamp = ( value : number , min : number , max : number ) =>
124+ Math . min ( Math . max ( value , min ) , max ) ;
125+
123126export const HarWaterfall : React . FC < HarWaterfallProps > = ( {
124127 entries,
125128 activeFilter,
@@ -259,9 +262,6 @@ export const HarWaterfall: React.FC<HarWaterfallProps> = ({
259262 return `${ parts . join ( ", " ) } . Total ${ formatDuration ( timing . totalTime ) } .` ;
260263 } ;
261264
262- const clamp = ( value : number , min : number , max : number ) =>
263- Math . min ( Math . max ( value , min ) , max ) ;
264-
265265 const scheduleHoverUpdate = useCallback (
266266 (
267267 listX : number ,
@@ -489,24 +489,22 @@ export const HarWaterfall: React.FC<HarWaterfallProps> = ({
489489 "hover:bg-muted/40 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-foreground/20"
490490 ) }
491491 >
492- < div className = "grid grid-cols-[110px,56px,90px,minmax(0,1.6fr),minmax(260px,2.4fr),80px] items-center gap-2 px-4 py-2" >
493- < div className = "flex flex-col gap-1" >
494- < div className = "flex items-center gap-2" >
495- < span
496- className = { cn (
497- "h-2 w-2 rounded-full" ,
498- isError ? "bg-red-500" : "bg-emerald-500"
499- ) }
500- />
501- < span
502- className = { cn (
503- "text-[13px] font-semibold tabular-nums" ,
504- isError ? "text-red-500" : "text-emerald-500"
505- ) }
506- >
507- { entry . response . status }
508- </ span >
509- </ div >
492+ < div className = "grid grid-cols-[110px,56px,90px,minmax(0,1.6fr),minmax(260px,2.4fr),80px] items-center gap-2 px-4 py-1" >
493+ < div className = "flex items-center gap-2" >
494+ < span
495+ className = { cn (
496+ "h-2 w-2 rounded-full" ,
497+ isError ? "bg-red-500" : "bg-emerald-500"
498+ ) }
499+ />
500+ < span
501+ className = { cn (
502+ "text-[13px] font-semibold tabular-nums" ,
503+ isError ? "text-red-500" : "text-emerald-500"
504+ ) }
505+ >
506+ { entry . response . status }
507+ </ span >
510508 < span className = "text-[10px] uppercase tracking-wider text-muted-foreground" >
511509 { entry . request . method }
512510 </ span >
@@ -526,17 +524,17 @@ export const HarWaterfall: React.FC<HarWaterfallProps> = ({
526524 < TooltipTrigger asChild >
527525 < span
528526 className = { cn (
529- "inline-flex h-7 w-7 items-center justify-center rounded-full ring-1" ,
527+ "inline-flex h-6 w-6 items-center justify-center rounded-full ring-1" ,
530528 typeMeta . className
531529 ) }
532530 aria-label = { ariaLabel }
533531 >
534- < TypeIcon className = "h-3.5 w-3.5 " />
532+ < TypeIcon className = "h-3 w-3" />
535533 </ span >
536534 </ TooltipTrigger >
537535 < TooltipContent
538536 side = "top"
539- className = "text-xs"
537+ className = "text-xs text-center "
540538 >
541539 { typeMeta . label }
542540 </ TooltipContent >
@@ -558,34 +556,36 @@ export const HarWaterfall: React.FC<HarWaterfallProps> = ({
558556 </ div >
559557
560558 < div className = "min-w-0" title = { entry . request . url } >
561- < div className = "text-[11px] text-muted-foreground" >
562- { searchQuery ? (
563- < SearchHighlightText
564- text = { url . hostname }
565- searchQuery = { searchQuery }
566- />
567- ) : (
568- url . hostname
569- ) }
570- </ div >
571- < div className = "flex min-w-0 items-center gap-2" >
572- < span className = "truncate text-[13px] font-medium text-foreground" >
559+ < >
560+ < div className = "text-[10px] tracking-wide text-muted-foreground" >
573561 { searchQuery ? (
574562 < SearchHighlightText
575- text = { displayPath }
563+ text = { url . hostname }
576564 searchQuery = { searchQuery }
577565 />
578566 ) : (
579- displayPath
567+ url . hostname
580568 ) }
581- </ span >
582- { searchQuery && matchInfo . hasMatch && (
583- < MatchIndicators
584- categories = { matchInfo . categories }
585- className = "flex-shrink-0"
586- />
587- ) }
588- </ div >
569+ </ div >
570+ < div className = "flex min-w-0 items-center gap-2" >
571+ < span className = "truncate text-[12px] font-medium text-foreground" >
572+ { searchQuery ? (
573+ < SearchHighlightText
574+ text = { displayPath }
575+ searchQuery = { searchQuery }
576+ />
577+ ) : (
578+ displayPath
579+ ) }
580+ </ span >
581+ { searchQuery && matchInfo . hasMatch && (
582+ < MatchIndicators
583+ categories = { matchInfo . categories }
584+ className = "flex-shrink-0"
585+ />
586+ ) }
587+ </ div >
588+ </ >
589589 </ div >
590590
591591 < div className = "relative" >
@@ -599,9 +599,9 @@ export const HarWaterfall: React.FC<HarWaterfallProps> = ({
599599 key = { `${ segment . key } -${ index } ` }
600600 className = { cn (
601601 "absolute h-full" ,
602- segmentIndex === 0 && "rounded-l-full " ,
602+ segmentIndex === 0 && "rounded-l-[3px] " ,
603603 segmentIndex === lastSegmentIndex &&
604- "rounded-r-full "
604+ "rounded-r-[3px] "
605605 ) }
606606 style = { {
607607 left : `${ segment . left } %` ,
0 commit comments