-
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
Add right border bar to Dark and Light theme #74504
Conversation
r? @jyn514 |
✌️ @@Cldfire can now approve this pull request |
So, I intentionally added this as a feature. The highlight color I used is very subtle (to keep contrast high on the text and make it easy to read), and I added the highlight bar to provide an "anchor" of sorts that you can quickly scan for with your eyes when scrolling through the page. Normally when the docs window is larger the highlight bar is much less tall which makes it less distracting: I've found it very handy in my own usage and I would be sad to see it go. I'm curious if other people agree that it is distracting, though 🙂. |
Personally, I don't get used to this highlight color bar yet. The first time I saw this bar, I wonder why is it highlighted? That's just my reason. If people like the highlighted bar, let's keep it. |
Hmm, interesting. My thinking here is that the bar appears alongside the highlight color which makes it clear that it's part of the highlighted function style. I can see this being the case though. Let's see what other people think! |
I like the highlight because it makes the function stand out a little more. Without the bar the yellow on black is a little hard to see. |
If people like it, I would expect we make the highlighting bar on other themes too for consistences. |
How do we continue the discussion? Maybe I ping other rustdoc devs like @GuillaumeGomez , @ollie27 . |
I have to admit that I like the right border highlighted too. So I'm curious what it would look like in the other themes as well. |
Looks good to me. :) Someone from @rust-lang/rustdoc wants to comment here maybe? |
I think adding the highlight bar to the light theme so it's consistent is a great idea :) |
49f6d79
to
df9a047
Compare
Ok, I changed the patch to include CSS rule for Dark and Light theme. |
On second thought: can you make the border color a bit less luminous in the dark theme please? |
Oh nice! Just need to have @Cldfire ok with this since it's the ayu theme. Can you do something equivalent with the dark theme too please? 😛 |
I have no opinion on the color choice, it seems fine. |
Let's go for |
Looks great! As far as my thoughts on the colors, I would say we should do the following:
Before: After: I would like to avoid using @lzutao can you try those three colors out please? 😄 |
df9a047
to
da9c77e
Compare
Updated the PR. |
Just a note: @Cldfire You have bors right in this PR, you could comment |
Looks good to me, thanks a lot! @bors: r+ rollup |
📌 Commit da9c77e62fd08cf715929e713d7ac87866206fa9 has been approved by |
Co-authored-by: Cldfire <[email protected]>
Ayu has it. Adding similar rule to other themes makes users less surprised and makes GUI more consistent.
da9c77e
to
7005ddb
Compare
Rebased and added co-author commit. |
Let's go again! @bors: r+ rollup |
📌 Commit 7005ddb has been approved by |
Rollup of 12 pull requests Successful merges: - rust-lang#74361 (Improve doc theme logo display) - rust-lang#74504 (Add right border bar to Dark and Light theme) - rust-lang#74572 (Internally unify rustc_deprecated and deprecated) - rust-lang#74601 (Clean up E0724 explanation) - rust-lang#74623 (polymorphize GlobalAlloc::Function) - rust-lang#74665 (Don't ICE on unconstrained anonymous lifetimes inside associated types.) - rust-lang#74666 (More BTreeMap test cases, some exposing undefined behaviour) - rust-lang#74669 (Fix typo) - rust-lang#74677 (Remove needless unsafety from BTreeMap::drain_filter) - rust-lang#74680 (Add missing backticks in diagnostics note) - rust-lang#74694 (Clean up E0727 explanation) - rust-lang#74703 (Fix ICE while building MIR with type errors) Failed merges: r? @ghost
Demo:
Light theme: #74504 (comment)
Dark theme: #74504 (comment)
Ayu theme: #74504 (comment)