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

Navbar start items are not properly aligned #617

Closed
OriolAbril opened this issue Apr 2, 2022 · 4 comments · Fixed by #697
Closed

Navbar start items are not properly aligned #617

OriolAbril opened this issue Apr 2, 2022 · 4 comments · Fixed by #697

Comments

@OriolAbril
Copy link
Contributor

I noticed that #526 modified the alignment of the navbar brand so it looks nicer with texts, but since then I have been unable to align the logo and version number in the same row. It used to look like: https://arviz.readthedocs.io/en/v0.11.3/. Now it looks like https://arviz.readthedocs.io/en/latest/, I saw scipy is also having the same issue: https://scipy.github.io/devdocs/. The navbar becomes too wide and even eats up part of the content (see the search bar in the sidebar of the scipy docs).

imatge

I noticed that opening the dev tools with mozilla and unchecking the display of the .navbar-brand element fixes this:

imatge

is it possible to add this display: flex only when text is used? Should I overwrite that in a custom.css file instead?

@damianavila
Copy link
Collaborator

@choldgraf, since you introduced the display: flex change in #526, I would be interested to know your thoughts on this one.

@choldgraf
Copy link
Collaborator

choldgraf commented Apr 21, 2022

Hmm, I cannot figure out what looks wrong. The logo looks aligned with the text to me in the two links that were provided, did they change?

@OriolAbril
Copy link
Contributor Author

I fixed the ArviZ one, and it looks like scipy removed it. In ArviZ we are overriding the css, you can compare the behaviour between latest and https://python.arviz.org/en/v0.12.0. For scipy you can compare between the screenshots above though it is not as convenient as you can't inspect their source

@choldgraf
Copy link
Collaborator

ah ok - I think that if we added a CSS rule to make the navbar-start section be flex-displayed and centered, this should work as expected:

Something like:

div#navbar-start {
    display: flex;
    align-items: center;
}

I think we'd want this behavior by default for all of the major navbar sections

@choldgraf choldgraf changed the title navbar start items Navbar start items are not properly aligned Apr 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants