Summary
When generating a large number of tabs with st.tabs, unmanageable tabs may occur.
I would like to know if there is any way to avoid this issue without reducing the number of characters in the tabs.
Steps to reproduce
Code snippet:
import streamlit as st
tabs = st.tabs([f"Tab of {i}" for i in range(50)])
Expected behavior:
I want to access hidden tabs, like scroll.
Actual behavior:
hidden tabs.
Debug info
Streamlit version: 1.23.1
Python version: 3.10.5
You can scroll through the tabs.
If you have horizontal scroll, that works while hovering over the tabs.
Otherwise, hold shift while using scroll and hovering over the tabs.
Otherwise you can use the arrow keys to navigate through the tabs after selecting one.
There is also a GitHub feature request to vote on if you’d like, mentioned in this other thread:
There is an open feature request for this. Be sure to vote on it as an improvement. I agree that a better visual cue and option to scroll with a mouse wheel should definitely be added!
I am playing with the CSS to see if there is any simple work around. Will post here and in the issue if I find something worth noting.
NOTE!
If you have the option on your mouse to scroll horizontally, it works. In my case, if I click my mouse wheel, I get the scroll pointer and can move my mouse left and ri…
1 Like
system
Closed
December 23, 2023, 3:20am
3
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.