Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -231,29 +231,26 @@ def left_navbar_static():
|
|
231 |
], style={"padding": "1rem", "backgroundColor": "#f8f9fa", "height": "100vh", "overflowY": "auto"})
|
232 |
|
233 |
def chat_box_card():
|
234 |
-
#
|
235 |
return dbc.Card(
|
236 |
dbc.CardBody([
|
237 |
-
html.Div(
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
"borderRadius": "0.5rem"
|
249 |
-
}
|
250 |
-
)
|
251 |
]),
|
252 |
className="mt-3",
|
253 |
style={
|
254 |
"height": "62vh",
|
255 |
-
"
|
256 |
-
"
|
257 |
}
|
258 |
)
|
259 |
|
@@ -283,20 +280,13 @@ def user_input_card():
|
|
283 |
)
|
284 |
|
285 |
def right_main_static():
|
286 |
-
# The chat message area gets its own container/card with its own scrollbar
|
287 |
return html.Div([
|
288 |
-
|
289 |
-
|
290 |
-
style={"width": "100%"}
|
291 |
-
),
|
292 |
-
html.Div(
|
293 |
-
user_input_card(),
|
294 |
-
style={"width": "100%", "marginTop": "1.5rem"}
|
295 |
-
),
|
296 |
dcc.Loading(id="loading", type="default", fullscreen=False, style={"position": "absolute", "top": "5%", "left": "50%"}),
|
297 |
dcc.Interval(id="stream-interval", interval=400, n_intervals=0, disabled=True, max_intervals=1000),
|
298 |
dcc.Store(id="client-question", data="")
|
299 |
-
], style={"padding": "1rem", "backgroundColor": "#fff", "height": "100vh", "overflowY": "auto"
|
300 |
|
301 |
app.layout = html.Div([
|
302 |
dcc.Store(id="session-id", storage_type="local"),
|
|
|
231 |
], style={"padding": "1rem", "backgroundColor": "#f8f9fa", "height": "100vh", "overflowY": "auto"})
|
232 |
|
233 |
def chat_box_card():
|
234 |
+
# Explicit scrollbars and height
|
235 |
return dbc.Card(
|
236 |
dbc.CardBody([
|
237 |
+
html.Div(id="chat-window", style={
|
238 |
+
"height": "60vh",
|
239 |
+
"overflowY": "scroll",
|
240 |
+
"overflowX": "auto",
|
241 |
+
"display": "flex",
|
242 |
+
"flexDirection": "column",
|
243 |
+
"justifyContent": "flex-end",
|
244 |
+
"backgroundColor": "#fff",
|
245 |
+
"padding": "0.5rem",
|
246 |
+
"borderRadius": "0.5rem"
|
247 |
+
})
|
|
|
|
|
|
|
248 |
]),
|
249 |
className="mt-3",
|
250 |
style={
|
251 |
"height": "62vh",
|
252 |
+
"overflowY": "scroll",
|
253 |
+
"overflowX": "auto"
|
254 |
}
|
255 |
)
|
256 |
|
|
|
280 |
)
|
281 |
|
282 |
def right_main_static():
|
|
|
283 |
return html.Div([
|
284 |
+
chat_box_card(),
|
285 |
+
user_input_card(),
|
|
|
|
|
|
|
|
|
|
|
|
|
286 |
dcc.Loading(id="loading", type="default", fullscreen=False, style={"position": "absolute", "top": "5%", "left": "50%"}),
|
287 |
dcc.Interval(id="stream-interval", interval=400, n_intervals=0, disabled=True, max_intervals=1000),
|
288 |
dcc.Store(id="client-question", data="")
|
289 |
+
], style={"padding": "1rem", "backgroundColor": "#fff", "height": "100vh", "overflowY": "auto"})
|
290 |
|
291 |
app.layout = html.Div([
|
292 |
dcc.Store(id="session-id", storage_type="local"),
|