daattali / oldschool-github-extension

Revert GitHub's UI back to its classic look (before the June 23, 2020 update that has a flat, rounded and more whitespaced design).
https://chrome.google.com/webstore/detail/old-school-github/blkkkhifjoiedclojflfcenbjigdajeb
MIT License
229 stars 11 forks source link

Apply CSS site wide, fix profile page issues, and fix visible re-paints in Firefox #12

Closed zekefarwell closed 4 years ago

zekefarwell commented 4 years ago

This PR does the following:

Injects the css on all github urls So issues can be fixed on the user page, organization page, home page, notifications page, etc.

Excludes the user profile header tabs from classic tab styling rules Turns out this page has a sticky header (unlike any other page) and the classic style tabs do not look good with it.

Moves status badge back below the user avatar on the profile page With the osgh.css applied to the profile page, the avatar changed from a circle to a square. This made the little round status badge sit fully on top of the image instead of right on the edge as it did with the circle. This did not look good, so I moved it down below the avatar, expanded it so the text is always visible (no reveal on hover), and made it a rectangle. This is not exactly how it looked before the 6/23 UI changes, but it's pretty close.

Closes #8

Injects css earlier to prevent re-paints after page load in Firefox Firefox was injecting the css after page load causing a visible flash as the restyled elements changed. Didn't seem to be a problem in Chrome. Adding "run_at": "document_start" to the manifest fixes the issue in Firefox and doesn't seem to cause an issue in Chrome. More info on this here.

daattali commented 4 years ago

Without looking at the code, from the description this looks fantastic. I'll take a look in the morning

daattali commented 4 years ago

I was going to say that the profile status looks weird on small screen, but that's just how it looks on small screens even for github's default UI :)

Thanks a lot

zekefarwell commented 4 years ago

I know! I was about to start working on fixing the status on mobile, but then saw that it was the default. They definitely pushed out this new design before it was finished.

chocolateboy commented 4 years ago

@zekefarwell Thanks for fixing the FOUC!