Skip to content

st.logo can push minimise button outside sidebar #12326

@kevinvayro

Description

@kevinvayro

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

If a wide logo is shown in the sidebar, there is potential for the minimise button to be pushed outside of the visible area.

v1.48

Image

v1.47

Image

max-width of logo used to be calculated but is now always 100%. Looks to have been raised previously in issue #8707

Reproducible Code Example

Open in Streamlit Cloud

import streamlit as st

st.logo("https://upload.wikimedia.org/wikipedia/commons/2/20/Artist_Growth_Wide_Logo.png")

with st.sidebar:
    st.write("Hello")

Steps To Reproduce

Use above code in v1.48.

Expected Behavior

Same behaviour as v1.47 where logo will scale down and minimise button will show.

Current Behavior

No response

Is this a regression?

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

Debug info

  • Streamlit version: 1.48
  • Python version: 3.13.7
  • Operating System: Windows 11
  • Browser: Chrome

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature:st.logoRelated to `st.logo` commandpriority:P2Medium-high priority - fix within one monthstatus: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