DennisSnijder / MakeGithubGreatAgain

Extension for making GitHub great again
https://chrome.google.com/webstore/detail/makegithubgreatagain/gpejlkhibgecggplgogpbgbdpnhogmhk
1.05k stars 49 forks source link

Save the colors!!! #49

Closed voronianski closed 7 years ago

voronianski commented 7 years ago

I think you need to save us from new github colors! Especially links!

sedders123 commented 7 years ago

Found the old link colour from a stale tab #4078c0

sedders123 commented 7 years ago

And the css for the private label

.label-private {
    font-weight: normal;
    color: #4c4a42;
    background-color: #ffefc6;
}
maximilianhurl commented 7 years ago

The new green buttons are particularly upsetting on my monitor. Here's the old CSS for reference:

/* Green primary button */
.btn-primary {
    color: #fff;
    text-shadow: 0 -1px 0 rgba(0,0,0,0.15);
    background-color: #6cc644;
    background-image: -webkit-linear-gradient(#91dd70, #55ae2e);
    background-image: linear-gradient(#91dd70, #55ae2e);
    border: 1px solid #5aad35;
}
rightfold commented 7 years ago

Because the current software only applies to the header color, there should be a preferences page so that you can select which changes to apply. I like the old header with the new colors, for example.

thieman commented 7 years ago

@rightfold this half-effort appeasing attitude is completely against the stated goal of the project to make github GREAT again, just like it was in the 1950s

DennisSnijder commented 7 years ago

We need to make the colors great again! Feel free to shoot in a PR 👍

miyaoka commented 7 years ago

http://web.archive.org/web/*/github.com

2008 2013 2014

We should support github GREAT 2008 again, GREAT 2009 again, GREAT 2010 again...

joeytwiddle commented 7 years ago

Just found this extension: github-old-colors

It changes links back to the old blue, and removes some shadows and background images from buttons. But it doesn't restore the old header bar, and it doesn't restore all of the earlier colors.

It uses a nice whitelist for links, which might be less problematic than the blacklist in my PR. This is an option worth considering...

ghost commented 7 years ago

@joeytwiddle i dont get why your pull has both save-the-colors.css and links.css

joeytwiddle commented 7 years ago

@svnpenn In my Chrome, our custom styles are injected before the page styles load. As a result, the page's a rule overrides the a rule in save-the-colors.css

That's why I took tombola's script for styling the links (and for the toggling behaviour). It uses .great-again a which is more specific, so it overrided the page's rule. For sure, the two scripts could be combined into one.

What I am wondering now is the best way to override their CSS without accidentally styling elements we want to leave alone. This is especially problematic for the a links. (Another reason why I am keeping link styling in its own file for now).

Some options are:

  1. Initially in my branch I was building up a blacklist. But I kept finding more links that we were accidentally styling, and needed adding to the blacklist. This wasn't sustainable.
  2. Build up some custom overrides like the ones in the github-old-colors extension. A whitelist. I have now moved over to this approach, and the code is a bit cleaner as a result.
  3. Inject the original styles or similar simple styles (without !important or .great-again) after the page's styles, and entirely abandon toggling between new/old colors. This is a simple solution, but I quite enjoy the toggling behaviour, and would prefer to keep it.
  4. Perform a dynamic search-replace on the CSSDOM after the page's styles have loaded. This is potentially a fun hack. It would have the advantage of "correcting" the colors of any new CSS rules which get added in future. But it would need patching if they change their new colors to an even newer scheme.
joeytwiddle commented 7 years ago

On Firefox, I'm giving these a try:

They don't restore the old greens and purples. But they do restore the old white header and many of the blue links.

There are others: 1

DennisSnijder commented 7 years ago

Fixed by #51