Merge remote-tracking branch 'upstream/dev' into feat/unified-model-connections

This commit is contained in:
Anish Sarkar 2026-06-12 03:20:46 +05:30
commit 72a7fe04b5
5 changed files with 118 additions and 58 deletions

View file

@ -27,8 +27,8 @@ export interface ChatViewportProps {
export const ChatViewport: FC<ChatViewportProps> = ({ children, footer }) => (
<ThreadPrimitive.Viewport
turnAnchor="top"
autoScroll
scrollToBottomOnRunStart
autoScroll={false}
scrollToBottomOnRunStart={false}
scrollToBottomOnInitialize
scrollToBottomOnThreadSwitch
className="aui-thread-viewport relative flex flex-1 min-h-0 flex-col overflow-y-auto px-4 scroll-smooth"

View file

@ -144,11 +144,15 @@ function getComposerSuggestionAnchorPoint(
};
}
export const Thread: FC = () => {
return <ThreadContent />;
interface ThreadProps {
hasActiveThread?: boolean;
}
export const Thread: FC<ThreadProps> = ({ hasActiveThread = false }) => {
return <ThreadContent hasActiveThread={hasActiveThread} />;
};
const ThreadContent: FC = () => {
const ThreadContent: FC<ThreadProps> = ({ hasActiveThread = false }) => {
return (
<ThreadPrimitive.Root
className="aui-root aui-thread-root @container flex h-full min-h-0 flex-col bg-main-panel"
@ -158,13 +162,13 @@ const ThreadContent: FC = () => {
>
<ChatViewport
footer={
<AuiIf condition={({ thread }) => !thread.isEmpty}>
<AuiIf condition={({ thread }) => hasActiveThread || !thread.isEmpty}>
<PremiumQuotaPinnedAlert />
<Composer />
</AuiIf>
}
>
<AuiIf condition={({ thread }) => thread.isEmpty}>
<AuiIf condition={({ thread }) => !hasActiveThread && thread.isEmpty}>
<ThreadWelcome />
</AuiIf>