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

Default favicon has very poor contrast against dark-themed browsers #727

Closed
sm-Fifteen opened this issue Nov 22, 2019 · 11 comments
Closed
Labels

Comments

@sm-Fifteen
Copy link
Contributor

Describe the bug
The current monochrome logo is a black circle on a transparent background, which makes it very hard to see against a dark background. Since I'm a 1337 H4X0R who uses dark themes pretty much everywhere, this happens to be all the time and especially frustrating given I tend to have the FastAPI doc and/or the API documentation open alongside a number of github tabs, whose logo also happens to be a black and transparent circle-like shape.

Screenshots
image
(Firefox's dark theme on Windows above, Chrome's incognito mode below. FastAPI is the second tab from the left in both cases.)

Expected behavior
The teal icon could be used instead of black, or the lightning bolt could be colored white so that either the circle or the bolt is going to be clearly visible regardless of the background color.

Additionnal context
This has been bugging me for months now, and somehow I never thought of reporting this as a bug until now.

@sm-Fifteen sm-Fifteen added the bug Something isn't working label Nov 22, 2019
@prostomarkeloff
Copy link
Contributor

LGTM

@skewty
Copy link

skewty commented Nov 26, 2019

Fixed color is often essential to branding. If you saw a big blue M sign would you think McDonalds? Since a white lightning bolt in a teal circle is used on the documentation website, I would suggest that is the proper approach. Since teal is a medium color, it may be beneficial to give it a small white border to help it stand out better against medium background colors. It would create additional (unnecessary) contrast on very dark backgrounds, but if the border is small enough it shouldn't be too distracting.

Seeing that two variants exist on the documentation web page, I would ask @tiangolo. FastAPI's logo may some day be an important Trademark and as such it will likely require fixed color (NOTE: I am not a legal expert and this is not legal advise.)

The teal color circle is easier to spot at a distance so it would be more recognizable in a line-up of tabs in my opinion. That said, the current notification / tray icon trend is to be monochrome (black / white).

@tiangolo
Copy link
Owner

That's an interesting point. I'll try and see how it looks like 🤷‍♂️ 🎨

@tiangolo tiangolo changed the title [BUG] Default favicon has very poor contrast against dark-themed browsers Default favicon has very poor contrast against dark-themed browsers Oct 22, 2022
@tiangolo tiangolo added feature New feature or request investigate and removed bug Something isn't working labels Oct 22, 2022
@sm-Fifteen
Copy link
Contributor Author

@tiangolo: So this issue seems to be part of the 20 or so (not counting translation tracking issues) that have been kept on the issue tracker instead of moved to discussions. This one in particular was submitted during FastAPI's first year and hasn't seen much attention since, so I personally expected to see it be closed or migrated. Does this mean anything with regards to this issue's relevance? Are there plans around this for an upcoming release?

@Lord-V15
Copy link

Lord-V15 commented Mar 6, 2023

Another issue is the lack of a better theme in the docs.
I actually dug very deep into the code some time ago and turns out the HTML CSS wrote for the swagger docs are extremely old (~10 years ago) and FastAPI uses it.
Now, I'm no expert with CSS but something modern would look much better like the CSS created here

@karolrzadczyk
Copy link

Another issue is the lack of a better theme in the docs.
I actually dug very deep into the code some time ago and turns out the HTML CSS wrote for the swagger docs are extremely old (~10 years ago) and FastAPI uses it.
Now, I'm no expert with CSS but something modern would look much better like the CSS created here

Is there a way to override the default theme with something like that? Without affecting the base code of fast api?

@hasnatsajid
Copy link
Contributor

I also use dark themes :)

@Lord-V15
Copy link

I actually dug very deep into the code some time ago and turns out the HTML CSS wrote for the swagger docs are extremely old (~10 years ago) and FastAPI uses it.
Now, I'm no expert with CSS but something modern would look much better like the CSS created here

Is there a way to override the default theme with something like that? Without affecting the base code of fast api?

The css is used via a URL so you need to change the package code which means you have to build from scratch and that's just too complicated for switching themes.
Maybe @tiangolo can suggest something better? 😅

@codespearhead
Copy link

codespearhead commented Apr 1, 2024

The favicon was updated via #11090 .

Should this issue be closed?

@tiangolo
Copy link
Owner

tiangolo commented Apr 2, 2024

Now that the icon was updated, this is finally done! 🚀

@tiangolo tiangolo closed this as completed Apr 2, 2024
@sm-Fifteen
Copy link
Contributor Author

Now that the icon was updated, this is finally done! 🚀

Only took... 4½ years, but better late than never!

I really like the new logo, BTW. Nice mix of the old lightning bolt, the general suggestion of an "F", and a shape I personally associate with Hermes' winged sandals (which makes sense, as he's a messenger god known for being fast). Pretty nifty stuff.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

8 participants