Skip to content

Commit 15fa53f

Browse files
chat section changes
1 parent fa68f3b commit 15fa53f

3 files changed

Lines changed: 39 additions & 8 deletions

File tree

App/frontend-app/src/components/chat/chatRoom.module.scss

Lines changed: 34 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,15 @@
2929
box-sizing: border-box !important;
3030
}
3131

32+
/* Force full width for all containers */
33+
.full-width-container {
34+
width: 100vw !important;
35+
max-width: 100vw !important;
36+
margin: 0 !important;
37+
padding: 0 !important;
38+
box-sizing: border-box !important;
39+
}
40+
3241
table {
3342
border-collapse: collapse;
3443
width: 100%;
@@ -73,8 +82,30 @@ table {
7382
.chatMessagesContainer, .questionContainer {
7483
padding-right: 0.25rem;
7584
padding-left: 0.25rem;
76-
width: 100%;
85+
width: 100% !important;
7786
box-sizing: border-box; /* Include padding in width calculation */
78-
max-width: 100%; /* Ensure it doesn't exceed container width */
79-
margin: 0;
87+
max-width: 100% !important; /* Ensure it doesn't exceed container width */
88+
margin: 0 !important;
89+
}
90+
91+
/* Force Copilot components to take full width */
92+
.chatMessagesContainer :global(fui-CopilotChat) {
93+
width: 100% !important;
94+
max-width: 100% !important;
95+
}
96+
97+
.chatMessagesContainer :global([role="log"]) {
98+
width: 100% !important;
99+
max-width: 100% !important;
100+
margin: 0 !important;
101+
padding: 0 !important;
102+
}
103+
104+
/* Ensure all chat message containers take full width */
105+
.chatMessagesContainer :global(.fui-CopilotMessage),
106+
.chatMessagesContainer :global(.fui-UserMessage) {
107+
width: 100% !important;
108+
max-width: 100% !important;
109+
margin-left: 0 !important;
110+
margin-right: 0 !important;
80111
}

App/frontend-app/src/components/chat/chatRoom.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -405,15 +405,15 @@ export function ChatRoom({ searchResultDocuments, selectedDocuments, chatWithDoc
405405
}, []);
406406

407407
return (
408-
<div className="flex w-full flex-1 flex-col items-stretch grey-background">
408+
<div className="flex w-full flex-1 flex-col items-stretch grey-background !m-0 !p-0 !max-w-none">
409409
{isDialogOpen && (
410410
<DocDialog
411411
metadata={dialogMetadata as Document}
412412
isOpen={isDialogOpen}
413413
onClose={handleDialogClose}
414414
allChunkTexts={allChunkTexts} clearChatFlag={false} />
415415
)}
416-
<div ref={chatContainerRef} className={`no-scrollbar flex w-full flex-1 flex-col overflow-auto ${styles["chat-container"]}`}>
416+
<div ref={chatContainerRef} className={`no-scrollbar flex w-full flex-1 flex-col overflow-auto !max-w-none !m-0 !p-0 ${styles["chat-container"]}`}>
417417
{!disableOptionsPanel && (
418418
<OptionsPanel
419419
className={`px-4 mx-0 my-10 flex flex-col items-center justify-center rounded-xl bg-neutral-500 bg-opacity-10 shadow-md outline outline-1 outline-transparent w-full`}
@@ -425,7 +425,7 @@ export function ChatRoom({ searchResultDocuments, selectedDocuments, chatWithDoc
425425
/>
426426
)}
427427
<div ref={optionsBottom}></div>
428-
<CopilotProvider className={`${styles.chatMessagesContainer} w-full`}>
428+
<CopilotProvider className={`${styles.chatMessagesContainer} w-full !max-w-none`}>
429429
<CopilotChat>
430430
{conversationAnswers.map(([prompt, response], index) => (
431431
<Fragment key={index}>

App/frontend-app/src/pages/chat/chatPage.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ export function ChatPage() {
3737
<HeaderBar location={NavLocation.Home} />
3838
</div>
3939
</Header>
40-
<main className="grid flex-1 grid-cols-5 gap-x-2 gap-y-8">
41-
<div className="col-span-3 col-start-2 flex flex-1 flex-col md:col-span-3 md:col-start-2">
40+
<main className="flex flex-1 flex-col w-full">
41+
<div className="flex flex-1 flex-col w-full">
4242
<HeaderMenuTabs
4343
className=""
4444
searchResultDocuments={searchResultDocuments}

0 commit comments

Comments
 (0)