Spaces:
Sleeping
Sleeping
Try fix problem with empty textbox
Browse files
app.py
CHANGED
|
@@ -43,8 +43,11 @@ st.markdown(
|
|
| 43 |
)
|
| 44 |
|
| 45 |
# Define the placeholder globally (outside columns)
|
| 46 |
-
|
| 47 |
-
placeholder
|
|
|
|
|
|
|
|
|
|
| 48 |
|
| 49 |
def handle_submit():
|
| 50 |
user_input = st.session_state.user_input
|
|
|
|
| 43 |
)
|
| 44 |
|
| 45 |
# Define the placeholder globally (outside columns)
|
| 46 |
+
if st.session_state.user_input:
|
| 47 |
+
placeholder = st.session_state.user_input
|
| 48 |
+
else:
|
| 49 |
+
placeholder = st.empty()
|
| 50 |
+
placeholder.markdown(f'<div class="scrollable-div"><p>Welcome! I am your Adrega AI assistant</p></div>', unsafe_allow_html=True)
|
| 51 |
|
| 52 |
def handle_submit():
|
| 53 |
user_input = st.session_state.user_input
|