Skip to content

Commit 35df72f

Browse files
authored
perf(web): render minimap highlights without extra nodes (#28270)
1 parent 96b0377 commit 35df72f

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

‎apps/web/src/components/chat/TimelineMinimap.tsx‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ export function TimelineMinimap({
217217
<span
218218
aria-hidden="true"
219219
className={cn(
220-
"group/strip pointer-events-none absolute left-0 h-0.5 w-6 origin-left -translate-y-1/2 rounded-full transition-transform duration-150",
220+
"pointer-events-none absolute left-0 h-0.5 w-6 origin-left -translate-y-1/2 rounded-full transition-transform duration-150 after:absolute after:inset-0 after:rounded-full after:bg-foreground/55 after:opacity-0 after:transition-opacity after:duration-150 data-[in-view=true]:after:opacity-100",
221221
activeDistance === 0 ? "bg-muted-foreground/60" : "bg-muted-foreground/25",
222222
activeDistance === 0
223223
? "scale-x-100"
@@ -238,9 +238,7 @@ export function TimelineMinimap({
238238
}
239239
}}
240240
style={{ top }}
241-
>
242-
<span className="absolute inset-0 rounded-full bg-foreground/55 opacity-0 transition-opacity duration-150 group-data-[in-view=true]/strip:opacity-100" />
243-
</span>
241+
/>
244242
);
245243
})}
246244
{activeItem ? (

0 commit comments

Comments
 (0)