Update app.py
Browse files
app.py
CHANGED
|
@@ -45,14 +45,14 @@ st.markdown("""
|
|
| 45 |
border-radius: 10px;
|
| 46 |
padding: 10px;
|
| 47 |
margin: 10px 0;
|
| 48 |
-
max-width:
|
| 49 |
}
|
| 50 |
.user-bubble {
|
| 51 |
background-color: #2B2B2B;
|
| 52 |
border-radius: 10px;
|
| 53 |
padding: 10px;
|
| 54 |
margin: 10px 0;
|
| 55 |
-
max-width:
|
| 56 |
}
|
| 57 |
.typing-cursor {
|
| 58 |
display: inline-block;
|
|
@@ -85,7 +85,7 @@ def typewriter_effect(text, speed=0.03, message_id=None):
|
|
| 85 |
current_text += char
|
| 86 |
container.markdown(
|
| 87 |
f'''
|
| 88 |
-
<div class="assistant-bubble" style="float:
|
| 89 |
{current_text}<span class="typing-cursor"></span>
|
| 90 |
</div>
|
| 91 |
''',
|
|
@@ -95,7 +95,7 @@ def typewriter_effect(text, speed=0.03, message_id=None):
|
|
| 95 |
|
| 96 |
# حفظ الرسالة النهائية
|
| 97 |
final_markup = f'''
|
| 98 |
-
<div class="assistant-bubble" style="float:
|
| 99 |
{text}
|
| 100 |
</div>
|
| 101 |
'''
|
|
|
|
| 45 |
border-radius: 10px;
|
| 46 |
padding: 10px;
|
| 47 |
margin: 10px 0;
|
| 48 |
+
max-width: 100%;
|
| 49 |
}
|
| 50 |
.user-bubble {
|
| 51 |
background-color: #2B2B2B;
|
| 52 |
border-radius: 10px;
|
| 53 |
padding: 10px;
|
| 54 |
margin: 10px 0;
|
| 55 |
+
max-width: 100%;
|
| 56 |
}
|
| 57 |
.typing-cursor {
|
| 58 |
display: inline-block;
|
|
|
|
| 85 |
current_text += char
|
| 86 |
container.markdown(
|
| 87 |
f'''
|
| 88 |
+
<div class="assistant-bubble" style="float: right; clear: both; text-align: right;">
|
| 89 |
{current_text}<span class="typing-cursor"></span>
|
| 90 |
</div>
|
| 91 |
''',
|
|
|
|
| 95 |
|
| 96 |
# حفظ الرسالة النهائية
|
| 97 |
final_markup = f'''
|
| 98 |
+
<div class="assistant-bubble" style="float: right; clear: both; text-align: right;">
|
| 99 |
{text}
|
| 100 |
</div>
|
| 101 |
'''
|