-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Union const colors #43558
Union const colors #43558
Conversation
Some changes occurred in HTML/CSS. |
r? @arielb1 (rust_highfive has picked a reviewer for you, use r? to override) |
8173524
to
302e51f
Compare
cc @rust-lang/docs |
The "Union" could stand to be a bit darker, but it also feels about as light as the primitive color, so i'll let it fly. @TedDriggs - you wanted to check out the new colors, this is the PR that adds them. |
Red/green colorblindness is the most common kind, so structs and enums might not be distinguishable from each other. I have a friend who has some colorblindness, would you like me to run this by him? |
@carols10cents: It'd be very helpful! Maybe he can suggests better colors as well? :) |
It's quite likely! Asking! |
Ok! I sent my friend the screenshot and this is what he has to say:
|
r? @QuietMisdreavus (or someone else on the docs team) |
Hello! I'm the friend @carols10cents referenced above. I have (relatively mild) colorblindness, primarily in distinguishing warm tones. I put together a Code Pen with some contrast comparisons and an alternate palette. I don't have any context for how these colors are used (my guess is syntax highlighting for docs), so please forgive any misuse. Anyway, thank you Carol for asking. Yinz keep being this awesome and considerate and I may just have to learn some Rust. ^_^ |
I'll take a look and try to make it easier for colorblind people to see the difference. |
The complete list of colors, as the Code Pen only listed five. CR=4.5-ing done via http://accessible-colors.com/. Just raising the contrast should not be enough, if the CR of every color is 4.5 they would all become the same shade of gray when the hue is washed out.
|
As long as the contrast is high enough, I'm 👍 |
Looks good to me! I'd like to hear from the others in this thread first, though. |
I defer entirely to @jnf (who has a non-Rust real job in PST so will likely comment in a few hours at the earliest, thank you again for your time on this Jeremy!!!) |
@GuillaumeGomez Could we keep functions brown and assign the blue to constants or unions? Existing colors should better be kept "stable". |
What about statics? There are also For all of these the background highlight color on the search page will also need to be updated to match: rust/src/librustdoc/html/static/styles/main.css Lines 73 to 80 in b0424b5
|
@ollie27: Forgot about them. I update as soon as I can! |
Anything else to do in here? |
Any reason not to add colors for statics? After this they'll be the only item type that gets a full page but no colors. The background highlight colors for |
@ollie27: Fixed as well! Anything else? |
Looks good to me 👍 |
Since you were the last one having issues, I suppose we can r+? |
It sounds like any interested party is okay with what's left, or was willing to defer to someone else. Let's get this out the door. If anyone finds any more issues with contrast, open another issue and we can work it out! @bors r+ rollup |
📌 Commit 00b362e has been approved by |
…reavus Union const colors Fixes #43523 What do you think of these colors: <img width="1440" alt="screen shot 2017-07-30 at 15 10 57" src="https://user-images.githubusercontent.com/3050060/28753752-6b175a22-7539-11e7-978e-949f3a947d18.png"> ?
☀️ Test successful - status-appveyor, status-travis |
Fixes #43523
What do you think of these colors:
?