Summary
I’m trying to add columns to the expander, but unfortunately it doesn’t seem to take effect
Steps to reproduce
Code snippet:
expanderList.append(st.expander('💡 Generate Results %s'%lineNum, expanded=False))
MODEL_CONFIG['rank_list_len']=4
columns = expanderList[lineNum].columns([1] * MODEL_CONFIG['rank_list_len'])
for i, c in enumerate(columns):
with c:
choice = expanderList[lineNum].selectbox(f'i+1', rank_choices,key=tagNum,
index=index)
if choice != -1 and choice in rank_results:
else:
rank_results[i] = choice
texts[i] = expanderList[lineNum].text_area('answer%s:'%tagNum,texts[i],height=200)
tagNum = tagNum + 1
index = index + 1
Expected behavior:Add several columns to the expander
Actual behavior:Unable to recognize column, still changed layout to row
Debug info
- Streamlit version: 1.17.0
- Python version: 3.8.15
- Using Conda
- OS version: WIN11
- Browser version: Chrome 109.0.5414.120x64
Requirements file
No special dependency library
Links
- Link to your GitHub repo:None
- Link to your deployed app:None
Additional information
None