Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: widen agent orchestration chat on large displays (#40433)

Joel0f583cfe75bb
diff --git a/web/features/agent-v2/agent-detail/configure/components/preview/chat-session.tsx b/web/features/agent-v2/agent-detail/configure/components/preview/chat-session.tsx
index cf1a779acea..2ff19e62a6f 100644
--- a/web/features/agent-v2/agent-detail/configure/components/preview/chat-session.tsx
+++ b/web/features/agent-v2/agent-detail/configure/components/preview/chat-session.tsx
@@ -23,6 +23,8 @@ import { deploymentEditionAtom } from '@/features/system-features/state'
import { buildChatConfig, getAgentSoulInputs, getAgentSoulInputsForm } from './chat-config'
import { AgentPreviewChatConversation } from './chat-conversation'
+const chatMaxWidthClassName = 'max-w-150 min-[1920px]:max-w-200 min-[2560px]:max-w-240'
+
export function AgentPreviewChatSession({
conversationSessionKey,
agentId,
@@ -181,7 +183,12 @@ export function AgentPreviewChatSession({
)
return (
- <div className="relative mx-auto flex h-full min-h-0 w-full max-w-150 flex-col overflow-hidden">
+ <div
+ className={cn(
+ 'relative mx-auto flex h-full min-h-0 w-full flex-col overflow-hidden',
+ chatMaxWidthClassName,
+ )}
+ >
<div className="min-h-0 flex-1">
<AgentPreviewChatConversation
key={conversationSessionKey}
@@ -220,7 +227,7 @@ export function AgentPreviewChatSession({
<div
className={cn(
isEmptyChat
- ? 'flex w-full max-w-150 flex-col items-start text-left'
+ ? cn('flex w-full flex-col items-start text-left', chatMaxWidthClassName)
: 'pointer-events-none relative w-full',
)}
>