feat(threads): up-arrow edits your last thread reply (+ fix cross-fire)
The thread composer reused RoomInput's hardcoded editableName="RoomInput", so the main timeline's global up-arrow "edit last message" handler fired while focused in a thread composer and targeted the MAIN timeline's last message (wrong), and there was no up-arrow edit for the thread itself. - Make editableName a RoomInput prop (default "RoomInput"); the thread composer passes "ThreadInput", so the two up-arrow handlers never cross-fire. - Add an up-arrow-edit handler to ThreadTimeline (parity with RoomTimeline): empty thread composer + Up -> edit the latest editable reply in that thread, using thread.liveTimeline + canEditEvent + setEditId. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -196,6 +196,7 @@ export function ThreadPanel({ room, threadId, requestClose }: ThreadPanelProps)
|
||||
roomId={room.roomId}
|
||||
threadRootId={threadId}
|
||||
editor={editor}
|
||||
editableName="ThreadInput"
|
||||
fileDropContainerRef={fileDropContainerRef}
|
||||
/>
|
||||
</Box>
|
||||
|
||||
Reference in New Issue
Block a user