From 3df9f9e66875254bb7e97d00a133fa10aef4edfa Mon Sep 17 00:00:00 2001 From: Rohini-Microsoft Date: Tue, 11 Jun 2024 11:14:15 +0530 Subject: [PATCH] Added changes in UI(Landing Screen) --- .../QuestionInput/QuestionInput.module.css | 14 ++++++++++- code/frontend/src/pages/chat/Chat.module.css | 16 +++++++++++++ code/frontend/src/pages/chat/Chat.tsx | 4 ++-- .../src/pages/layout/Layout.module.css | 23 ++++++++++++++++++- code/frontend/src/pages/layout/Layout.tsx | 15 ++++++------ 5 files changed, 61 insertions(+), 11 deletions(-) diff --git a/code/frontend/src/components/QuestionInput/QuestionInput.module.css b/code/frontend/src/components/QuestionInput/QuestionInput.module.css index 60a03735d..5125cd984 100644 --- a/code/frontend/src/components/QuestionInput/QuestionInput.module.css +++ b/code/frontend/src/components/QuestionInput/QuestionInput.module.css @@ -65,7 +65,7 @@ height: 24px; margin-bottom: 12px; } - + .microphoneAndSendContainer { display: flex; flex-direction: column; @@ -73,3 +73,15 @@ margin-right: 12px; margin-top: 25px; } + + + /* High contrast mode specific styles */ +@media screen and (-ms-high-contrast: active), (forced-colors: active) { + .questionInputContainer{ + border: 2px solid WindowText; + margin-bottom: 10px; + padding: 5px; + background-color: Window; + color: WindowText; + } +} diff --git a/code/frontend/src/pages/chat/Chat.module.css b/code/frontend/src/pages/chat/Chat.module.css index 9948c0161..19ebec61d 100644 --- a/code/frontend/src/pages/chat/Chat.module.css +++ b/code/frontend/src/pages/chat/Chat.module.css @@ -308,3 +308,19 @@ font-size: 12px; } } + + /* High contrast mode specific styles */ + @media screen and (-ms-high-contrast: active), (forced-colors: active) { + .chatContainer { + border: 2px solid WindowText; + padding: 10px; + background-color: Window; + color: WindowText; + } +} + +@media screen and (max-width: 1280px) { + .clearChatBroom { + left: -17px !important; + } +} diff --git a/code/frontend/src/pages/chat/Chat.tsx b/code/frontend/src/pages/chat/Chat.tsx index b0fb1b524..2ac94871e 100644 --- a/code/frontend/src/pages/chat/Chat.tsx +++ b/code/frontend/src/pages/chat/Chat.tsx @@ -136,7 +136,7 @@ const Chat = () => { setIsRecognizing(true); recognizerRef.current = await multiLingualSpeechRecognizer(); // Store the recognizer in the ref - + recognizerRef.current.recognized = (s, e) => { if (e.result.reason === ResultReason.RecognizedSpeech) { const recognized = e.result.text; @@ -226,7 +226,7 @@ const Chat = () => {
{!lastQuestionRef.current ? ( - +

Start chatting

This chatbot is configured to answer your questions diff --git a/code/frontend/src/pages/layout/Layout.module.css b/code/frontend/src/pages/layout/Layout.module.css index e37b61405..96bf2b109 100644 --- a/code/frontend/src/pages/layout/Layout.module.css +++ b/code/frontend/src/pages/layout/Layout.module.css @@ -1,3 +1,17 @@ +body { + font-size: 16px; /* Use relative units */ + line-height: 1.5; + margin: 0; + padding: 0; +} + +.header, .footer { + width: 100%; + max-width: 1200px; + padding: 1rem; + box-sizing: border-box; +} + .layout { display: flex; flex-direction: column; @@ -114,4 +128,11 @@ display: flex; align-items: center; color: #242424; -} \ No newline at end of file +} + +@media screen and (-ms-high-contrast: active), (forced-colors: active) { + +.shareButtonContainer{ + border: 2px solid WindowText; +} +} diff --git a/code/frontend/src/pages/layout/Layout.tsx b/code/frontend/src/pages/layout/Layout.tsx index 06d176d98..697998479 100644 --- a/code/frontend/src/pages/layout/Layout.tsx +++ b/code/frontend/src/pages/layout/Layout.tsx @@ -40,6 +40,7 @@ const Layout = () => { src={Azure} className={styles.headerIcon} aria-hidden="true" + alt="Azure AI logo" />

Azure AI

@@ -52,11 +53,11 @@ const Layout = () => {
-