Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix: thread scrolling behavior (#1293)

teo77603ed9d94f
diff --git a/js/app/packages/block-channel/component/Message/MessageContainer.tsx b/js/app/packages/block-channel/component/Message/MessageContainer.tsx
index d0c681fcfb..d89d614c47 100644
--- a/js/app/packages/block-channel/component/Message/MessageContainer.tsx
+++ b/js/app/packages/block-channel/component/Message/MessageContainer.tsx
@@ -329,7 +329,7 @@ export function MessageContainer(props: MessageProps) {
const onCreateReply = () => {
listContext.createReply(message.id, true);
listContext.scrollToIndex(props.index(), {
- align: 'end',
+ align: 'nearest',
});
};
diff --git a/js/app/packages/block-channel/component/MessageList/MessageList.tsx b/js/app/packages/block-channel/component/MessageList/MessageList.tsx
index 7f9e7c693b..43b8366507 100644
--- a/js/app/packages/block-channel/component/MessageList/MessageList.tsx
+++ b/js/app/packages/block-channel/component/MessageList/MessageList.tsx
@@ -482,7 +482,7 @@ function MessageListImpl(props: MessageListProps) {
forceBottom ||
((!target || delta > TARGET_MESSAGE_ACTIVE_TIME) && isNearBottom())
) {
- virtualHandle()?.scrollToIndex(0, { align: 'end' });
+ virtualHandle()?.scrollTo(0);
return;
}