From afc02b98736d5ca6f0e3c86c1bba91f7bb2aa63b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ebubekir=20Y=C4=B1lmaz?= Date: Wed, 24 Jul 2024 11:03:57 +0300 Subject: [PATCH 1/3] Remove isMobile from ChatWidget --- src/widgets/Chat/ChatWidget.jsx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/widgets/Chat/ChatWidget.jsx b/src/widgets/Chat/ChatWidget.jsx index a5abe374..53e76663 100644 --- a/src/widgets/Chat/ChatWidget.jsx +++ b/src/widgets/Chat/ChatWidget.jsx @@ -11,15 +11,13 @@ import useChat from "./useChat"; import { useEvent } from "@nucleoidai/react-event"; import { useParams } from "react-router-dom"; -import { Box, useMediaQuery, useTheme } from "@mui/material"; +import { Box, useTheme } from "@mui/material"; import React, { useEffect, useRef, useState } from "react"; const ChatWidget = () => { const theme = useTheme(); const { chatId } = useParams("chatId"); - const isMobile = useMediaQuery((theme) => theme.breakpoints.down("sm")); - const [codeResponse, setCodeResponse] = useState(false); const [isItFirstVisit, setIsItFirstVisit] = useState(); const [loading, setLoading] = useState(false); @@ -122,7 +120,7 @@ const ChatWidget = () => { height: "100%", width: "100%", backgroundColor: theme.palette.background.paper, - paddingBottom: isMobile ? "25px" : "10px", + paddingBottom: "10px", }} > Date: Wed, 24 Jul 2024 11:04:12 +0300 Subject: [PATCH 2/3] Change position to relative --- src/widgets/Chat/SuggestionsOverlay.jsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/widgets/Chat/SuggestionsOverlay.jsx b/src/widgets/Chat/SuggestionsOverlay.jsx index ce7059d7..cf3e852d 100644 --- a/src/widgets/Chat/SuggestionsOverlay.jsx +++ b/src/widgets/Chat/SuggestionsOverlay.jsx @@ -201,8 +201,7 @@ const SuggestionsOverlay = ({ onSuggestionClick, loading, chat, error }) => { display: "flex", flexWrap: "wrap", justifyContent: "center", - position: "absolute", - bottom: { xs: "15%", sm: "15%" }, + position: "relative", width: "100%", padding: "10px", }} From 887fcf665481ddf467b48cafdc33ed56ca872f15 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ebubekir=20Y=C4=B1lmaz?= Date: Wed, 24 Jul 2024 11:04:34 +0300 Subject: [PATCH 3/3] Change paddingBottom in xs --- src/widgets/Chat/ChatDisplay.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/widgets/Chat/ChatDisplay.jsx b/src/widgets/Chat/ChatDisplay.jsx index 7c667edc..6bcf8d33 100644 --- a/src/widgets/Chat/ChatDisplay.jsx +++ b/src/widgets/Chat/ChatDisplay.jsx @@ -96,7 +96,7 @@ const ChatDisplay = ({ paddingX: { xs: "8px", sm: "16px", md: "20px" }, paddingTop: "20px", paddingBottom: { - xs: suggestionsOverlay.active ? 19 : 1, + xs: suggestionsOverlay.active ? 8 : 1, sm: suggestionsOverlay.active ? 12.5 : 2.5, }, }}