Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extra-small column width in dataframes #10019

Open
2 tasks done
LasseDamtoft opened this issue Dec 13, 2024 · 1 comment
Open
2 tasks done

Extra-small column width in dataframes #10019

LasseDamtoft opened this issue Dec 13, 2024 · 1 comment
Labels
feature:st.column_config Related to column config functionalities feature:st.dataframe type:enhancement Requests for feature enhancements or new features

Comments

@LasseDamtoft
Copy link

Checklist

  • I have searched the existing issues for similar feature requests.
  • I added a descriptive title and summary to this issue.

Summary

I have a dataframe for a sports league and with a games (and other) column called "G" and numerical values of 1-2 digits.

On a desktop the dataframe looks fine, because there is usually enough space to view the entire dataframe, but on mobile screens, you have to scroll left-right to see all columns. This could be mitigated by columns being more narrow.

For now the minimum width a column can have is wide enough to contain four numerical digits, which would be nice if this could be lowered. If I use the width="small" value in the column_config the columns become even wider, so a solution could be an "even-smaller" width option or even a numerical one or simply that the minimum width is lowered.

This is as small/narrow as it will go, but as can be seen the contents would still be visible at half the width.
st_df_col_width

Why?

It would allow to fit more simple columns into a screen without scrolling and as such improve user experience.

How?

A solution could be an "even-smaller" width option or even a numerical one or simply that the minimum width is lowered to allow for columns containing only a single digit/character.

Additional Context

No response

@LasseDamtoft LasseDamtoft added the type:enhancement Requests for feature enhancements or new features label Dec 13, 2024
Copy link

To help Streamlit prioritize this feature, react with a 👍 (thumbs up emoji) to the initial post.

Your vote helps us identify which enhancements matter most to our users.

Visits

@jrieke jrieke changed the title Dataframe column width minimum value Extra-small column width in dataframes Dec 16, 2024
@jrieke jrieke added the feature:st.column_config Related to column config functionalities label Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature:st.column_config Related to column config functionalities feature:st.dataframe type:enhancement Requests for feature enhancements or new features
Projects
None yet
Development

No branches or pull requests

3 participants