Spaces:
Sleeping
Sleeping
Update frontend/src/index.css
Browse files- frontend/src/index.css +43 -31
frontend/src/index.css
CHANGED
|
@@ -23,14 +23,13 @@ html, body, #root, .app-wrapper {
|
|
| 23 |
height: 100%;
|
| 24 |
margin: 0;
|
| 25 |
padding: 0;
|
| 26 |
-
|
| 27 |
-
overflow: hidden;
|
| 28 |
}
|
| 29 |
body {
|
| 30 |
font-family: var(--fontFamily), -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
|
| 31 |
-webkit-font-smoothing: antialiased;
|
| 32 |
-moz-osx-font-smoothing: grayscale;
|
| 33 |
-
background-color: var(--white-color);
|
| 34 |
color: var(--text-color);
|
| 35 |
}
|
| 36 |
|
|
@@ -51,11 +50,13 @@ body {
|
|
| 51 |
height: 100%; /* Ensure app-wrapper takes full height */
|
| 52 |
}
|
| 53 |
|
| 54 |
-
|
| 55 |
-
|
| 56 |
display: flex;
|
| 57 |
-
|
| 58 |
-
|
|
|
|
|
|
|
| 59 |
}
|
| 60 |
|
| 61 |
/* --- Header --- */
|
|
@@ -69,8 +70,9 @@ main {
|
|
| 69 |
position: sticky;
|
| 70 |
top: 0;
|
| 71 |
z-index: 1000;
|
| 72 |
-
height: var(--header-height);
|
| 73 |
-
box-sizing: border-box;
|
|
|
|
| 74 |
}
|
| 75 |
.logo {
|
| 76 |
display: flex;
|
|
@@ -187,14 +189,7 @@ main {
|
|
| 187 |
.error-message { color: red; text-align: center; margin-bottom: 1rem; }
|
| 188 |
.auth-form .btn-primary { width: 100%; padding: 0.75rem; }
|
| 189 |
|
| 190 |
-
/*
|
| 191 |
-
.chat-layout {
|
| 192 |
-
display: flex;
|
| 193 |
-
width: 100%;
|
| 194 |
-
/* Use calc to account for header height, as body has overflow:hidden */
|
| 195 |
-
height: calc(100% - var(--header-height));
|
| 196 |
-
overflow: hidden; /* Important for containing sidebar and main chat content */
|
| 197 |
-
}
|
| 198 |
|
| 199 |
/* Sidebar Styling */
|
| 200 |
.sidebar {
|
|
@@ -205,10 +200,17 @@ main {
|
|
| 205 |
display: flex;
|
| 206 |
flex-direction: column;
|
| 207 |
justify-content: space-between; /* Pushes content to top and bottom */
|
| 208 |
-
flex-shrink: 0; /* Prevent sidebar from shrinking */
|
| 209 |
-
height: 100%; /* Make sidebar take full height of
|
| 210 |
box-sizing: border-box;
|
|
|
|
|
|
|
|
|
|
| 211 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 212 |
|
| 213 |
/* sidebar-top now contains only the new chat button */
|
| 214 |
.sidebar-top {
|
|
@@ -277,16 +279,25 @@ main {
|
|
| 277 |
color: var(--dark-green-text); /* Keep dark green text when active */
|
| 278 |
}
|
| 279 |
|
| 280 |
-
/*
|
| 281 |
-
.chat-
|
| 282 |
-
flex-grow: 1;
|
| 283 |
display: flex;
|
| 284 |
flex-direction: column;
|
| 285 |
-
justify-content: space-between; /* This is fine, it separates messages from input */
|
| 286 |
background-color: #f9f9f9;
|
| 287 |
-
height: 100%; /* Ensures it takes full height of
|
| 288 |
-
box-sizing: border-box;
|
| 289 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 290 |
}
|
| 291 |
|
| 292 |
/* Chat Messages Area */
|
|
@@ -383,14 +394,16 @@ main {
|
|
| 383 |
|
| 384 |
/* Specific styling for assistant bubbles */
|
| 385 |
.message-wrapper.assistant .message-bubble {
|
| 386 |
-
background-color: #DFE3E8; /*
|
| 387 |
border-bottom-left-radius: 5px; /* Pointy bottom-left for assistant */
|
| 388 |
margin-right: auto; /* Push to left, next to sidebar */
|
|
|
|
| 389 |
}
|
| 390 |
|
| 391 |
/* Specific styling for user bubbles */
|
| 392 |
.message-wrapper.user .message-bubble {
|
| 393 |
-
background-color: #
|
|
|
|
| 394 |
border-bottom-right-radius: 5px; /* Pointy bottom-right for user */
|
| 395 |
margin-left: auto; /* Push to right */
|
| 396 |
}
|
|
@@ -616,10 +629,9 @@ main {
|
|
| 616 |
width: 100%;
|
| 617 |
gap: 10px;
|
| 618 |
}
|
| 619 |
-
.
|
| 620 |
flex-direction: column;
|
| 621 |
-
|
| 622 |
-
height: calc(100% - var(--header-height)); /* No fixed sidebar height subtraction here */
|
| 623 |
}
|
| 624 |
.sidebar {
|
| 625 |
width: 100%;
|
|
|
|
| 23 |
height: 100%;
|
| 24 |
margin: 0;
|
| 25 |
padding: 0;
|
| 26 |
+
overflow: hidden; /* Critical for entire page to prevent unwanted scrolling */
|
|
|
|
| 27 |
}
|
| 28 |
body {
|
| 29 |
font-family: var(--fontFamily), -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
|
| 30 |
-webkit-font-smoothing: antialiased;
|
| 31 |
-moz-osx-font-smoothing: grayscale;
|
| 32 |
+
background-color: var(--white-color);
|
| 33 |
color: var(--text-color);
|
| 34 |
}
|
| 35 |
|
|
|
|
| 50 |
height: 100%; /* Ensure app-wrapper takes full height */
|
| 51 |
}
|
| 52 |
|
| 53 |
+
/* New: Container for Sidebar and Chat Content */
|
| 54 |
+
.content-area {
|
| 55 |
display: flex;
|
| 56 |
+
flex-grow: 1; /* Allows content-area to take up remaining vertical space */
|
| 57 |
+
/* Use calc to account for header height, as body has overflow:hidden */
|
| 58 |
+
height: calc(100% - var(--header-height));
|
| 59 |
+
overflow: hidden; /* Important to contain sidebar and chat and prevent this div from scrolling */
|
| 60 |
}
|
| 61 |
|
| 62 |
/* --- Header --- */
|
|
|
|
| 70 |
position: sticky;
|
| 71 |
top: 0;
|
| 72 |
z-index: 1000;
|
| 73 |
+
height: var(--header-height);
|
| 74 |
+
box-sizing: border-box;
|
| 75 |
+
flex-shrink: 0; /* Prevent header from shrinking */
|
| 76 |
}
|
| 77 |
.logo {
|
| 78 |
display: flex;
|
|
|
|
| 189 |
.error-message { color: red; text-align: center; margin-bottom: 1rem; }
|
| 190 |
.auth-form .btn-primary { width: 100%; padding: 0.75rem; }
|
| 191 |
|
| 192 |
+
/* REMOVED: .chat-layout as it's no longer the main flex container for sidebar and chat */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 193 |
|
| 194 |
/* Sidebar Styling */
|
| 195 |
.sidebar {
|
|
|
|
| 200 |
display: flex;
|
| 201 |
flex-direction: column;
|
| 202 |
justify-content: space-between; /* Pushes content to top and bottom */
|
| 203 |
+
flex-shrink: 0; /* Prevent sidebar from shrinking, CRITICAL for fixed sidebar */
|
| 204 |
+
height: 100%; /* Make sidebar take full height of content-area */
|
| 205 |
box-sizing: border-box;
|
| 206 |
+
overflow-y: auto; /* Allow sidebar content to scroll if it exceeds its height */
|
| 207 |
+
-ms-overflow-style: none; /* IE and Edge */
|
| 208 |
+
scrollbar-width: none; /* Firefox */
|
| 209 |
}
|
| 210 |
+
.sidebar::-webkit-scrollbar { /* Hide scrollbar for webkit browsers */
|
| 211 |
+
display: none;
|
| 212 |
+
}
|
| 213 |
+
|
| 214 |
|
| 215 |
/* sidebar-top now contains only the new chat button */
|
| 216 |
.sidebar-top {
|
|
|
|
| 279 |
color: var(--dark-green-text); /* Keep dark green text when active */
|
| 280 |
}
|
| 281 |
|
| 282 |
+
/* New: Styling for the container that holds ChatInterface */
|
| 283 |
+
.chat-content-container {
|
| 284 |
+
flex-grow: 1; /* Allows chat content to take all remaining width */
|
| 285 |
display: flex;
|
| 286 |
flex-direction: column;
|
|
|
|
| 287 |
background-color: #f9f9f9;
|
| 288 |
+
height: 100%; /* Ensures it takes full height of content-area */
|
| 289 |
+
box-sizing: border-box;
|
| 290 |
+
}
|
| 291 |
+
|
| 292 |
+
|
| 293 |
+
/* Main chat content area (now within chat-content-container) */
|
| 294 |
+
.chat-main { /* This class is still relevant for ChatInterface's internal layout */
|
| 295 |
+
flex-grow: 1;
|
| 296 |
+
display: flex;
|
| 297 |
+
flex-direction: column;
|
| 298 |
+
justify-content: space-between;
|
| 299 |
+
height: 100%; /* Ensure it takes full height of its parent (.chat-content-container) */
|
| 300 |
+
box-sizing: border-box;
|
| 301 |
}
|
| 302 |
|
| 303 |
/* Chat Messages Area */
|
|
|
|
| 394 |
|
| 395 |
/* Specific styling for assistant bubbles */
|
| 396 |
.message-wrapper.assistant .message-bubble {
|
| 397 |
+
background-color: #DFE3E8; /* Assistant background color */
|
| 398 |
border-bottom-left-radius: 5px; /* Pointy bottom-left for assistant */
|
| 399 |
margin-right: auto; /* Push to left, next to sidebar */
|
| 400 |
+
color: var(--text-color); /* Default text color for assistant */
|
| 401 |
}
|
| 402 |
|
| 403 |
/* Specific styling for user bubbles */
|
| 404 |
.message-wrapper.user .message-bubble {
|
| 405 |
+
background-color: #4CAF50; /* User background color: Green */
|
| 406 |
+
color: #ffffff; /* User text color: White */
|
| 407 |
border-bottom-right-radius: 5px; /* Pointy bottom-right for user */
|
| 408 |
margin-left: auto; /* Push to right */
|
| 409 |
}
|
|
|
|
| 629 |
width: 100%;
|
| 630 |
gap: 10px;
|
| 631 |
}
|
| 632 |
+
.content-area { /* Adjust content area for mobile */
|
| 633 |
flex-direction: column;
|
| 634 |
+
height: calc(100% - var(--header-height));
|
|
|
|
| 635 |
}
|
| 636 |
.sidebar {
|
| 637 |
width: 100%;
|