napari / napari-sphinx-theme

https://napari.org/napari-sphinx-theme
BSD 3-Clause "New" or "Revised" License
4 stars 10 forks source link

When making the window more narrow, header bar doesn't expand #162

Closed psobolewskiPhD closed 5 months ago

psobolewskiPhD commented 5 months ago

The items in the header go multiline, but the header area (blue bar) doesn't expand.

image

Compare to parent pydata-sphinx-theme: image

The header bar widens to accommodate the double-line. I don't love the aesthetic, but it is objectively better than ours 🤣

melissawm commented 5 months ago

ooh interesting! Probably an upstream bug - would you mind opening an issue there?

psobolewskiPhD commented 5 months ago

I don't think it's upstream bug, I think I just wasn't clear: Upstream wide look like this:

image

And if you narrow it you can see the header space expands vertically--it between the shadow at the bottom and the purple banner: image

In our case, here is the wide view:

image

Looks much like upstream. But when I narrow it: image

The blue header doesn't expand in the vertical direction (GitHub is auto sizing to fit width here, but I think you can see what's happening)

psobolewskiPhD commented 5 months ago

Apropos, upstream has a PR to improve the default look: https://github.com/pydata/pydata-sphinx-theme/pull/1784 (but our issue is still something different, with the blue bar graphic not expanding)

gabalafou commented 5 months ago

Hi, I landed here from the cross-reference to the PyData Theme issue (1784). I think you can fix this issue by removing the height: 64px on the header. I'm not familiar enough with Napari docs to know if that's a viable solution, maybe you have an animation or some other reason you need to set the height explicitly, but if you don't need to set an explicit, fixed height, that should fix this issue, which is what I did in PR #163

melissawm commented 5 months ago

No we dont have any customization beyond the color, I will try that, thanks! ☺️