## Summary - virtualize MessageTimeline so large session histories stop rendering the full timeline sidebar at once. - keep the existing full render path in selection mode so xray/selection behavior stays intact. - route active-segment scrolling through the virtualizer so timeline navigation still follows the selected message. ## Benefit - prompt field was very laggy in cession with big history and timeline had many bugs, this is fixed. - the session with big history now load as fast as a new session .
This commit is contained in:
@@ -66,10 +66,11 @@
|
||||
}
|
||||
|
||||
.message-timeline {
|
||||
--message-timeline-segment-gap: 0.35rem;
|
||||
flex: 1 1 auto;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.35rem;
|
||||
gap: 0;
|
||||
padding: 0.25rem;
|
||||
overflow-y: auto;
|
||||
overflow-x: visible;
|
||||
@@ -114,6 +115,17 @@
|
||||
-webkit-touch-callout: none;
|
||||
}
|
||||
|
||||
.message-timeline-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.message-timeline-item-spacer {
|
||||
flex: none;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.message-timeline-segment[data-delete-hover="true"]::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
@@ -319,18 +331,7 @@
|
||||
border-inline-start: 3px solid color-mix(in oklab, var(--accent-primary) 35%, transparent);
|
||||
}
|
||||
|
||||
/* Extra spacing before the first tool in a group to separate from the
|
||||
preceding user/assistant badge. */
|
||||
.message-timeline-group-start {
|
||||
margin-top: 0.35rem;
|
||||
}
|
||||
|
||||
/* Subtle extra spacing after the group parent (assistant) to separate
|
||||
from the next user badge below. Uses adjacent sibling targeting. */
|
||||
.message-timeline-group-parent + .message-timeline-user,
|
||||
.message-timeline-group-parent + .message-timeline-compaction {
|
||||
margin-top: 0.35rem;
|
||||
}
|
||||
/* Spacing is rendered by the measured item wrapper so virtua can account for it. */
|
||||
|
||||
.message-timeline-container {
|
||||
position: relative;
|
||||
|
||||
Reference in New Issue
Block a user