diff --git a/src-ui/src/app/components/chat/chat/chat.component.html b/src-ui/src/app/components/chat/chat/chat.component.html
index 8b3f90c1c..902f5d318 100644
--- a/src-ui/src/app/components/chat/chat/chat.component.html
+++ b/src-ui/src/app/components/chat/chat/chat.component.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src-ui/src/app/components/chat/chat/chat.component.scss b/src-ui/src/app/components/chat/chat/chat.component.scss
index 4b85363bb..1b6ff99ff 100644
--- a/src-ui/src/app/components/chat/chat/chat.component.scss
+++ b/src-ui/src/app/components/chat/chat/chat.component.scss
@@ -1,9 +1,9 @@
.dropdown-menu {
- width: var(--pngx-toast-max-width);
+ width: min(36rem, calc(100vw - 20px));
}
.chat-messages {
- max-height: 350px;
+ max-height: min(60dvh, 36rem);
overflow-y: auto;
white-space: pre-wrap;
}
@@ -16,9 +16,9 @@
white-space: initial;
}
-@media screen and (max-width: 400px) {
- :host ::ng-deep .dropdown-menu-end {
- right: -3rem;
+@media screen and (max-width: 575.98px) {
+ .chat-messages {
+ max-height: calc(100dvh - 12rem);
}
}
diff --git a/src-ui/src/app/components/chat/chat/chat.component.ts b/src-ui/src/app/components/chat/chat/chat.component.ts
index fe7613cfb..d40e2bd2e 100644
--- a/src-ui/src/app/components/chat/chat/chat.component.ts
+++ b/src-ui/src/app/components/chat/chat/chat.component.ts
@@ -17,6 +17,7 @@ import {
ChatService,
parseChatResponse,
} from 'src/app/services/chat.service'
+import { pngxPopperOptions } from 'src/app/utils/popper-options'
const SLOW_RESPONSE_DELAY_MS = 8000
@@ -39,6 +40,7 @@ export class ChatComponent implements OnInit {
readonly input = signal('')
readonly documentId = signal(undefined)
readonly slowResponse = signal(false)
+ public popperOptions = pngxPopperOptions
private chatService: ChatService = inject(ChatService)
private router: Router = inject(Router)