Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -385,11 +385,12 @@ def main():
|
|
385 |
}
|
386 |
.user-bubble {
|
387 |
align-self: flex-end;
|
388 |
-
background-color: rgba(0, 0, 0, 0.
|
389 |
color: white;
|
390 |
padding: 1rem;
|
391 |
border-radius: 1rem 0.5rem 1rem 1rem;
|
392 |
max-width: 80%;
|
|
|
393 |
}
|
394 |
.rating-line {
|
395 |
font-weight: bold;
|
@@ -419,10 +420,11 @@ def main():
|
|
419 |
st.markdown('<div class="chat-container">', unsafe_allow_html=True)
|
420 |
|
421 |
for i, exchange in enumerate(st.session_state.chat_history):
|
422 |
-
# MODTRAN Bot's answer (left side)
|
423 |
-
st.markdown(f'<div class="bot-bubble"><strong>MODTRAN Bot:</strong> {exchange["bot"]}</div>', unsafe_allow_html=True)
|
424 |
# User's question (right side)
|
425 |
st.markdown(f'<div class="user-bubble"><strong>You:</strong> {exchange["user"]}</div>', unsafe_allow_html=True)
|
|
|
|
|
|
|
426 |
|
427 |
# If already rated
|
428 |
if "rating" in exchange:
|
|
|
385 |
}
|
386 |
.user-bubble {
|
387 |
align-self: flex-end;
|
388 |
+
background-color: rgba(0, 0, 0, 0.85);
|
389 |
color: white;
|
390 |
padding: 1rem;
|
391 |
border-radius: 1rem 0.5rem 1rem 1rem;
|
392 |
max-width: 80%;
|
393 |
+
text-align: right;
|
394 |
}
|
395 |
.rating-line {
|
396 |
font-weight: bold;
|
|
|
420 |
st.markdown('<div class="chat-container">', unsafe_allow_html=True)
|
421 |
|
422 |
for i, exchange in enumerate(st.session_state.chat_history):
|
|
|
|
|
423 |
# User's question (right side)
|
424 |
st.markdown(f'<div class="user-bubble"><strong>You:</strong> {exchange["user"]}</div>', unsafe_allow_html=True)
|
425 |
+
# MODTRAN Bot's answer (left side)
|
426 |
+
st.markdown(f'<div class="bot-bubble"><strong>MODTRAN Bot:</strong> {exchange["bot"]}</div>', unsafe_allow_html=True)
|
427 |
+
|
428 |
|
429 |
# If already rated
|
430 |
if "rating" in exchange:
|