Skip to content

Commit fec9ae5

Browse files
committed
Fix the species search
1 parent ef53c87 commit fec9ae5

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

src/validation_handlers.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -93,23 +93,20 @@ def render_local_validation_form(result, selections):
9393
st.markdown(label)
9494

9595
# GBIF species search with autocomplete dropdown
96-
with st.expander("🐦 Other species not listed above", expanded=False, key=f"exp_other_{form_key}"):
96+
with st.container(border=True):
97+
st.markdown("🐦 **Other species not listed above**")
9798
st.caption("Search any species by common or scientific name (powered by GBIF)")
9899
selected = st_searchbox(
99100
search_species_for_searchbox,
100101
placeholder="e.g. Great Tit, Parus major, Red Fox...",
101102
clear_on_submit=True,
102-
rerun_scope="fragment",
103103
key=f"local_gbif_searchbox_{form_key}",
104104
)
105105
if selected and selected not in st.session_state.gbif_selected_species:
106-
# selected is the scientific_name (second tuple element)
107-
# Re-fetch display name
108106
st.session_state.gbif_selected_species[selected] = selected
109107
st.rerun()
110108

111109
if st.session_state.gbif_selected_species:
112-
st.markdown("**Selected species:**")
113110
to_remove = []
114111
for sci_name in list(st.session_state.gbif_selected_species):
115112
col1, col2 = st.columns([5, 1])

0 commit comments

Comments
 (0)