frc-docs icon indicating copy to clipboard operation
frc-docs copied to clipboard

Switch Theme To Furo

Open GrahamSH-LLK opened this issue 1 year ago • 25 comments

Furo

  • Is a noticeably better looking theme than RTD
  • Waaaay easier to navigate sidebar
  • Table of contents on the side (currently unused space on rtd-theme)
    • Makes viewing and finding content on long pages WAY easier
  • Is significantly more responsive on small screens
  • Has a built in and good looking dark mode
  • Is more maintained than RTD-theme (often taking months to release new version that are compatible with sphinx)
  • More modern looking admonitions
  • Better colors and font
  • Used by CTRE :)

image image image

GrahamSH-LLK avatar Apr 02 '24 00:04 GrahamSH-LLK

I think @Daltz333 might be the best judge if and how this change could be made. As is there are multiple things I don't like about the current implementation:

  • The upper left logo looks bad and is far too elongated. I think a lot of effort has gone into the previous one and it should be very similar to that: image
  • Is there any way we can keep the font sizing more similar. It seems to have made many things bigger which throws some things off. For example the "FIRST Robotics Competition Control System" on the home page now is taking two line as opposed to 1.
  • On my screen it seems like it has semi centered the page. More gap on the right than left. I think I prefer left justified but not a hill I would die on maybe I am just resistant to change.
  • The rounded search box looked better to me.
  • The scroll on the left hand side only moves the topics and not the logo above. I don't think we need to see the logo the whole time.
  • It seems like the spacing and size of the items on the left is larger and you now need to scroll forever to reach the bottom.
  • Do all the links have to be underlined? That seems like it sets them even further apart from the text where as the old theme blended better.

Overall I like many of the features this brings I think we just need to have a deeper discussion on many of the "fine" points.

jasondaming avatar Apr 04 '24 14:04 jasondaming

I think @Daltz333 might be the best judge if and how this change could be made. As is there are multiple things I don't like about the current implementation:

  • The upper left logo looks bad and is far too elongated. I think a lot of effort has gone into the previous one and it should be very similar to that: image
  • Is there any way we can keep the font sizing more similar. It seems to have made many things bigger which throws some things off. For example the "FIRST Robotics Competition Control System" on the home page now is taking two line as opposed to 1.
  • On my screen it seems like it has semi centered the page. More gap on the right than left. I think I prefer left justified but not a hill I would die on maybe I am just resistant to change.
  • The rounded search box looked better to me.
  • The scroll on the left hand side only moves the topics and not the logo above. I don't think we need to see the logo the whole time.
  • It seems like the spacing and size of the items on the left is larger and you now need to scroll forever to reach the bottom.
  • Do all the links have to be underlined? That seems like it sets them even further apart from the text where as the old theme blended better.

Overall I like many of the features this brings I think we just need to have a deeper discussion on many of the "fine" points.

Check out the sidebar changes I just pushed. It looks way better to me. The rest I'd like to get some more opinions before changing, as I've heard very different takes on them from different people.

GrahamSH-LLK avatar Apr 06 '24 16:04 GrahamSH-LLK

On the topic of looks, the people who's opinion matters most are @Kevin-OConnor (FiRST) and @arbessette (WPI). I suspect they're both busy until after championships.

sciencewhiz avatar Apr 06 '24 17:04 sciencewhiz

Yep, pretty swamped through Champs and recovering the week after. Just set myself a calendar notification for the 29th to look at this. Sorry for the delay!

Kevin-OConnor avatar Apr 08 '24 18:04 Kevin-OConnor

Overall I think this looks much better than when I first looked at it. Couple comments:

  • On my laptop screen the sidebar looks a little odd. I think it's a result of the overall content being centered, but the padding on the left that's the dark blue sidebar color stands out much more than the white/black padding on the right. I've included an image below. I'm not sure what exactly to do different though.
  • In dark mode the green/teal headers on the homepage look a little ugly to me. I don't think this should be a blocker to merging, this is always something that could be changed later.

I like the "On this page" mini table of contents that's part of this. I like the larger text size for the title, I think it helps convey the hierarchy a little better, the text sizes are pretty close between titles and various heading levels in the current theme. image

Kevin-OConnor avatar May 01 '24 14:05 Kevin-OConnor

Overall I think this looks much better than when I first looked at it. Couple comments:

  • On my laptop screen the sidebar looks a little odd. I think it's a result of the overall content being centered, but the padding on the left that's the dark blue sidebar color stands out much more than the white/black padding on the right. I've included an image below. I'm not sure what exactly to do different though.

It doesn't look particularly weird to me on my laptop, but I can see how it would to others/on different resolutions. I'm not entirely sure how to fix this either- we could reduce the padding, but I feel like that might look worse.

  • In dark mode the green/teal headers on the homepage look a little ugly to me. I don't think this should be a blocker to merging, this is always something that could be changed later.

I can definitely change colors. Which color specifically?

I like the "On this page" mini table of contents that's part of this. I like the larger text size for the title, I think it helps convey the hierarchy a little better, the text sizes are pretty close between titles and various heading levels in the current theme.

image

GrahamSH-LLK avatar May 02 '24 11:05 GrahamSH-LLK

@Kevin-OConnor I changed the sidebar so that it takes up less space. Does that look better? I'm still unsure which teal color you mean exactly. (re:

In dark mode the green/teal headers on the homepage look a little ugly to me. I don't think this should be a blocker to merging, this is always something that could be changed later. )

GrahamSH-LLK avatar Jun 08 '24 18:06 GrahamSH-LLK

@Kevin-OConnor I changed the sidebar so that it takes up less space. Does that look better? I'm still unsure which teal color you mean exactly.

LGTM. The colors of all the header blocks on the home page are the ones that don't seem to match the color scheme to me but I'm good with merging this and worrying about that later.

Kevin-OConnor avatar Jun 10 '24 15:06 Kevin-OConnor

Lets wait to merge until we split stable and main (so we can fix any issues that emerge without back-porting).

sciencewhiz avatar Jun 10 '24 15:06 sciencewhiz

Before merging I would like to get somebody who understands one of the RTL language(s?) to make sure I didn't break anything in the change. I tried to keep everything looking like it did on the old version, but it is very possible that I missed something.

GrahamSH-LLK avatar Jun 12 '24 12:06 GrahamSH-LLK

Before merging I would like to get somebody who understands one of the RTL language(s?) to make sure I didn't break anything in the change.

@AustinShalit @Starlight220

sciencewhiz avatar Jun 12 '24 16:06 sciencewhiz

Is there a way to build the Hebrew translation with the changes here? I can see if it's broken, but I'm not familiar enough with RTD/CSS/etc to know in advance.

Starlight220 avatar Jun 12 '24 17:06 Starlight220

Is there a way to build the Hebrew translation with the changes here? I can see if it's broken, but I'm not familiar enough with RTD/CSS/etc to know in advance.

here you go: https://he.grahamsh.com/

GrahamSH-LLK avatar Jun 12 '24 19:06 GrahamSH-LLK

@GrahamSH-LLK thanks for the build!

Some panel buttons on the homepage lost the framed link: Screenshot_20240613-065956.png It seems to be that way with all the Hebrew buttons on that page; I'm starting to suspect that a lot got broken.

The headings sidebar opens properly, but the TOC sidebar doesn't open.

Another note (not only RTL), I'm not sure I'm a fan of the blockquoting here: Screenshot_20240613-070746.png

This might be a problem in the source itself (note the difference in capitalization of the language labels): Screenshot_20240613-071134.png

Screenshot_20240613-071118.png

Starlight220 avatar Jun 13 '24 04:06 Starlight220

@GrahamSH-LLK thanks for the build!

Some panel buttons on the homepage lost the framed link: Screenshot_20240613-065956.png It seems to be that way with all the Hebrew buttons on that page; I'm starting to suspect that a lot got broken.

Believe it or not, those buttons seem to be missing on stable Hebrew too. I'm not sure if this is intentional, but it's not a regression in this PR.

The headings sidebar opens properly, but the TOC sidebar doesn't open.

That was just fixed (see https://he.grahamsh.com)

Another note (not only RTL), I'm not sure I'm a fan of the blockquoting here: Screenshot_20240613-070746.png

What do you dislike exactly?

This might be a problem in the source itself (note the difference in capitalization of the language labels): Screenshot_20240613-071134.png

Screenshot_20240613-071118.png

That must be a mistake from an earlier PR of mine where sphinx tabs were migrated. I'll send a PR to make it consistent soon.

GrahamSH-LLK avatar Jun 13 '24 12:06 GrahamSH-LLK

Believe it or not, those buttons seem to be missing on stable Hebrew too. I'm not sure if this is intentional, but it's not a regression in this PR.

https://github.com/wpilibsuite/frc-docs-translations/issues/38

sciencewhiz avatar Jun 13 '24 12:06 sciencewhiz

Buttons: bummer it's an upstream limitation, but oh well.

TOC sidebar: fixed; thanks!

Changelog blockquote: I'm not entirely a fan of the seemingly-arbitrary blockquoting of nested lists. Why not keep it without blockquotes? Just seems a bit weird imo that part of the changelog is quoted and some isn't, but it's probably a matter of taste so I won't object.

Tab labels: sounds good.

Overall, LGTM!

Starlight220 avatar Jun 14 '24 08:06 Starlight220

sphinx-rtd-theme should be able to be removed from pyproject.toml

removed.

GrahamSH-LLK avatar Jun 16 '24 20:06 GrahamSH-LLK

Changelog blockquote: I'm not entirely a fan of the seemingly-arbitrary blockquoting of nested lists. Why not keep it without blockquotes? Just seems a bit weird imo that part of the changelog is quoted and some isn't, but it's probably a matter of taste so I won't object.

I agree, that looks weird. That doesn't happen here with nested lists: https://sphinx-themes.org/sample-sites/furo/kitchen-sink/lists/

sciencewhiz avatar Jun 18 '24 03:06 sciencewhiz

This is why: https://github.com/pradyunsg/furo/discussions/190

Should probably find places with 4 space indents and fix, seems like it could show up many places.

sciencewhiz avatar Jun 18 '24 03:06 sciencewhiz

There's conflicts to resolve

sciencewhiz avatar Aug 02 '24 01:08 sciencewhiz

https://frc-docs--2626.org.readthedocs.build/en/2626/docs/software/advanced-controls/introduction/tuning-flywheel.html

The interactive pid tuning is broken

TheTripleV avatar Aug 02 '24 04:08 TheTripleV

The js files are being added to the html past the content, so they're not available at the js entrypoint in the article. Wrapping the entrypoint in a load event listener fixes it e.g.

<script>
   addEventListener("load", (event) => {
      flywheel_pid = new FlywheelPIDF("flywheel_feedforward", "feedforward");
   });
</script>

rzblue avatar Aug 23 '24 02:08 rzblue

Depends on https://github.com/pradyunsg/furo/issues/795

sciencewhiz avatar Sep 03 '24 02:09 sciencewhiz

Depends on #2729

sciencewhiz avatar Sep 06 '24 14:09 sciencewhiz