fix(ui): reconcile trajectory ledger with current client contracts

This commit is contained in:
_Kerman
2026-07-28 10:23:44 +08:00
parent fb3e4effba
commit 92081094ae
12 changed files with 66 additions and 69 deletions

View File

@@ -1147,7 +1147,7 @@ function RequestTiming({
}: {
assistant: TableRecord | undefined
anchor: TableRecord | undefined
request?: TrajectoryRequestNumber
request: TrajectoryRequestNumber | undefined
}) {
if (assistant !== undefined) return <RecordTiming record={assistant} />
if (request?.startedAt !== undefined) {
@@ -1746,8 +1746,9 @@ export function TrajectoryTable({
onPointerDown={(event) => {
if (event.button !== 0) return
const details = event.currentTarget.parentElement
const split = details?.parentElement
if (details === null || split === null) return
if (details === null) return
const split = details.parentElement
if (split === null) return
const splitWidth = split.getBoundingClientRect().width
detailsResizeDrag.current = {
pointerId: event.pointerId,
@@ -1785,8 +1786,9 @@ export function TrajectoryTable({
onKeyDown={(event) => {
if (event.key !== 'ArrowLeft' && event.key !== 'ArrowRight') return
const details = event.currentTarget.parentElement
const split = details?.parentElement
if (details === null || split === null) return
if (details === null) return
const split = details.parentElement
if (split === null) return
const direction = event.key === 'ArrowLeft' ? 1 : -1
const currentDetailsWidth = details.getBoundingClientRect().width
const splitWidth = split.getBoundingClientRect().width

View File

@@ -331,7 +331,6 @@ export function deriveTrajectoryLayout(input: TrajectoryLayoutInput): readonly T
text: summarizeContent(node.content),
sourceSeq: node.seq,
messageSource: node.source,
...(node.meta === undefined ? {} : { messageMeta: node.meta }),
inputDetail: detailContent(node.content),
sourceBlocks: node.content.map(block => sourceBlock(block)),
timeSeconds: 0,