Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -227,7 +227,7 @@ def display_pet_card(pet, is_favorite=False):
|
|
| 227 |
if st.button("View Details", key=f"details_{pet['id']}"):
|
| 228 |
if st.session_state.selected_pet != pet['id']:
|
| 229 |
st.session_state.selected_pet = pet['id']
|
| 230 |
-
st.
|
| 231 |
|
| 232 |
with col2:
|
| 233 |
if not is_favorite:
|
|
@@ -296,7 +296,7 @@ def display_pet_details(pet_id):
|
|
| 296 |
if st.button("← Back to Search Results"):
|
| 297 |
if st.session_state.selected_pet is not None:
|
| 298 |
st.session_state.selected_pet = None
|
| 299 |
-
st.
|
| 300 |
# Pet name and status
|
| 301 |
st.markdown(f"<h1 class='main-header'>{pet['name']}</h1>", unsafe_allow_html=True)
|
| 302 |
|
|
|
|
| 227 |
if st.button("View Details", key=f"details_{pet['id']}"):
|
| 228 |
if st.session_state.selected_pet != pet['id']:
|
| 229 |
st.session_state.selected_pet = pet['id']
|
| 230 |
+
st.rerun() # Force immediate rerun
|
| 231 |
|
| 232 |
with col2:
|
| 233 |
if not is_favorite:
|
|
|
|
| 296 |
if st.button("← Back to Search Results"):
|
| 297 |
if st.session_state.selected_pet is not None:
|
| 298 |
st.session_state.selected_pet = None
|
| 299 |
+
st.rerun() # Force immediate rerun
|
| 300 |
# Pet name and status
|
| 301 |
st.markdown(f"<h1 class='main-header'>{pet['name']}</h1>", unsafe_allow_html=True)
|
| 302 |
|