Make message list bottom-first with append-only timeline

This commit is contained in:
Shantur Rathore
2025-12-12 12:00:19 +00:00
parent ce5eaa1841
commit 766be00ded
4 changed files with 189 additions and 88 deletions

View File

@@ -204,7 +204,7 @@ interface MessageBlockProps {
instanceId: string
sessionId: string
store: () => InstanceMessageStore
messageIndexMap: () => Map<string, number>
messageIndex: number
lastAssistantIndex: () => number
showThinking: () => boolean
thinkingDefaultExpanded: () => boolean
@@ -223,7 +223,7 @@ export default function MessageBlock(props: MessageBlockProps) {
const current = record()
if (!current) return null
const index = props.messageIndexMap().get(current.id) ?? 0
const index = props.messageIndex
const lastAssistantIdx = props.lastAssistantIndex()
const isQueued = current.role === "user" && (lastAssistantIdx === -1 || index > lastAssistantIdx)
const info = messageInfo()