Fix chat width issues (#1813)

This commit is contained in:
Matthew Diamant
2025-03-22 10:55:12 -07:00
committed by GitHub
parent 20a35c7bad
commit f82983c6fa
2 changed files with 5 additions and 2 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ export default function UserMessage({ message }: UserMessageProps) {
<div className="flex-col max-w-[85%]"> <div className="flex-col max-w-[85%]">
<div className="flex flex-col group"> <div className="flex flex-col group">
<div className="flex bg-slate text-white rounded-xl rounded-br-none py-2 px-3"> <div className="flex bg-slate text-white rounded-xl rounded-br-none py-2 px-3">
<div ref={contentRef}> <div className="break-all" ref={contentRef}>
<MarkdownContent content={textContent} className="text-white" /> <MarkdownContent content={textContent} className="text-white" />
</div> </div>
</div> </div>
+4 -1
View File
@@ -73,7 +73,10 @@ const ScrollArea = React.forwardRef<ScrollAreaHandle, ScrollAreaProps>(
className={cn('relative overflow-hidden', className)} className={cn('relative overflow-hidden', className)}
{...props} {...props}
> >
<ScrollAreaPrimitive.Viewport ref={viewportRef} className="h-full w-full rounded-[inherit]"> <ScrollAreaPrimitive.Viewport
ref={viewportRef}
className="h-full w-full rounded-[inherit] [&>div]:!block"
>
{children} {children}
{autoScroll && <div ref={viewportEndRef} style={{ height: '1px' }} />} {autoScroll && <div ref={viewportEndRef} style={{ height: '1px' }} />}
</ScrollAreaPrimitive.Viewport> </ScrollAreaPrimitive.Viewport>