Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Altair/Vega/built-in charts don't stretch to full width in fullscreen mode #11802

@jrieke

Description

@jrieke

Checklist

  • I have searched the existing issues for similar issues.
  • I added a very descriptive title to this issue.
  • I have provided sufficient information below to help reproduce this issue.

Summary

When you click on the "fullscreen" toolbar icon on a Vega/Altair/built-in chart, the chart stretches to the full screen in height, but the width doesn't.

Image

Reproducible Code Example

Open in Streamlit Cloud

import streamlit as st
import pandas as pd
import numpy as np

chart_data = pd.DataFrame(np.random.randn(20, 3), columns=["a", "b", "c"])

st.line_chart(chart_data)

Steps To Reproduce

  1. Hover the chart to see the toolbar.
  2. Click on "Fullscreen" in the toolbar.

Expected Behavior

Chart should stretch to the entire width of the screen, just like it does for dataframes, Plotly charts, or maps.

Current Behavior

Chart only takes up ~1/3rd of the width of the screen.

Is this a regression?

  • Yes, this used to work in a previous version.

Debug info

  • Streamlit version: 1.46
  • Python version:
  • Operating System:
  • Browser:

Additional Information

No response

Metadata

Metadata

Assignees

Labels

feature:builtin-chartsRelated to built-in chart types, e.g. `st.line_chart`feature:st.altair_chartRelated to the `st.altair_chart` elementfeature:st.vega_lite_chartRelated to the `st.vega_lite_chart` elementpriority:P1High priority - fix within two weeksstatus:confirmedBug has been confirmed by the Streamlit teamtype:bugSomething isn't working as expectedtype:regressionThis bug is a regression from previous behavior

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions