github-vscode-theme icon indicating copy to clipboard operation
github-vscode-theme copied to clipboard

Strings are too light

Open simurai opened this issue 4 years ago • 22 comments

Feedback from a DM:

The contrast of the string is a bit light

Screenshot 2020-05-08 at 10 20 47

compared to the default

Screenshot 2020-05-08 at 10 20 08

simurai avatar May 08 '20 08:05 simurai

tbh, inversely the string color is a bit dark in Light mode too. I cannot see any contrast between normal text and strings either. (albeit that's the case with the GitHub UI in general; but more notable when using it as a primary IDE theme)

minimaxir avatar May 08 '20 14:05 minimaxir

This is my first reaction to using this theme as well. Beautiful theme but the light strings makes HTML and CSS harder to read.

mattaningram avatar May 08 '20 16:05 mattaningram

I've been experimenting and it's trickier to make them darker if you want to stick to Primer (as other scopes are using darker hues of blue). An alternative would be #ffab70 which doesn't seem to clash with other colors. However, it introduces a new color to the theme palette, which might be undesired...

posthardcode avatar May 08 '20 17:05 posthardcode

Agree. That it the first thing I noticed. Hurts the eyes... I think that if needed we should deviate from Primers colours in this case. Maybe use a darker shade of the current color?

samuelgozi avatar May 11 '20 10:05 samuelgozi

I am not a designer, but #fff5b1 $yellow-200 looks good to me:

image

Reference image (without patch) image

/// really nice theme btw :clap:

balazs4 avatar May 11 '20 13:05 balazs4

It gets even worse with template literals, as the variables look almost the same as the surrounding string.

GitHub Dark github-dark

Dracula dracula-dark

estevanmaito avatar May 11 '20 16:05 estevanmaito

tbh, inversely the string color is a bit dark in Light mode too.

Yeah, it's a tricky question. How much should this "GitHub theme" try to mimic the syntax highlighting on github.com? Below an example and a screenshot from VS Code. It doesn't have to be 100% the same, but would still be nice to stay somewhat close. Not that github.com's syntax highlighting is perfect, but people should feel familiar. :grimacing:

https://github.com/primer/github-vscode-theme/blob/71691fbdde883083ad95b60d454b689e35a43f47/src/index.js#L10-L13

CleanShot 2020-05-12 at 18 53 00@2x

As for the dark version.. we might can be less strict since that doesn't exist for github.com.

I've been experimenting and it's trickier to make them darker if you want to stick to Primer (as other scopes are using darker hues of blue).

Yeah, blue[7] is still pretty light and blue[6] already gets used a lot elsewhere. Here a mix in between:

CleanShot 2020-05-12 at 18 51 50@2x

Maybe as quick fix before considering a bigger change.

simurai avatar May 12 '20 09:05 simurai

I feel a lighter blue is too close to $blue-300 #79b8ff and can be hard to read in the same line:

image

I'm using $yellow-200 #fff5b1 as @balazs4 suggested as a temporary fix:

image

loreina avatar May 12 '20 23:05 loreina

As a user, I come to use this theme because I want to feel at home when switching between GitHub web and VSCode. I think we should honour this expectation and try to stay close to the GitHub web theme.

paramaggarwal avatar May 13 '20 05:05 paramaggarwal

I'm using $yellow-200 #fff5b1 as @balazs4 suggested as a temporary fix:

👍 If anyone else wants to test it out, here the config you can add to your settings.json:

  "editor.tokenColorCustomizations": {
    "[GitHub Dark]": {
      "strings": "#fff5b1"
    }
  },

image

simurai avatar May 13 '20 09:05 simurai

The corresponding TextMate rule will have to be added too:

"[GitHub Dark]": {
      "strings": "#fff5b1",
      "textMateRules": [
        {
          "scope": "punctuation.definition.string",
          "settings": {
            "foreground": "#fff5b1"
          }
        }
      ]
    }

I've been testing that out and it works fine.

minimaxir avatar May 15 '20 04:05 minimaxir

As a user, I come to use this theme because I want to feel at home when switching between GitHub web and VSCode. I think we should honour this expectation and try to stay close to the GitHub web theme.

Not at the expense of readability

MrSunshyne avatar May 18 '20 10:05 MrSunshyne

@MrSunshyne Your claim is that readability is lacking on GitHub website? Because my point was about sticking to the GitHub website design as much as possible.

paramaggarwal avatar May 18 '20 15:05 paramaggarwal

@MrSunshyne Your claim is that readability is lacking on GitHub website? Because my point was about sticking to the GitHub website design as much as possible.

I think you're missing the point of this issue. GitHub uses a light theme, and as pointed earlier (https://github.com/primer/github-vscode-theme/issues/19#issuecomment-627240537) there is no intent on changing it.

We're trying to find a way to improve readability for the Dark Theme, and with this particular theme, there is more room for changes, as GitHub doesn't have a dark mode, so there is no standard for it.

estevanmaito avatar May 18 '20 16:05 estevanmaito

We're trying to find a way to improve readability for the Dark Theme, and with this particular theme, there is more room for changes, as GitHub doesn't have a dark mode, so there is no standard for it.

And how about the Github Mobile (iOS) dark mode?

image

Same color palette (?), but they are slightly different assigned to the tokens.

I personally find the mobile version somehow cleaner. 🙄

What do you think?

balazs4 avatar May 18 '20 21:05 balazs4

You're right, mobile apps (Android uses the same theme as iOS) already have a dark theme, and the color palette seems the same, but better applied.

estevanmaito avatar May 18 '20 22:05 estevanmaito

And how about the Github Mobile (iOS) dark mode?

Yeah, that's a great idea. Let's see if we can :flashlight: :mag: spy on their dark theme and steal a few hex values.

simurai avatar May 19 '20 06:05 simurai

There's also a dark theme available for the GitHub Desktop app

this-fifo avatar May 19 '20 22:05 this-fifo

  • VS Code v1.45.1
  • GitHub Theme v1.1.2 dark

Is there any reason why the color of the const variable is similar to the color of the text? image

CatsMiaow avatar May 21 '20 07:05 CatsMiaow

@MrSunshyne Your claim is that readability is lacking on GitHub website? Because my point was about sticking to the GitHub website design as much as possible.

@paramaggarwal Yep that is my claim. I would 100% prefer loading a project in vscode/webstorm darkmode before doing any serious code review. I didn't even know I was doing that until I thought about it after reading your question. I can glance at the code on github.com, but not for long. Also, to be clear, this is my opinion and I understand thousands of people do code review on github since years and it's working perfectly fine for them.

@estevanmaito since there is no standard for it, it's probably makes inserting new variations(removing while text) more acceptable?

MrSunshyne avatar May 23 '20 15:05 MrSunshyne

@MrSunshyne actually we found that there is already a Dark Mode for GitHub, mainly used on mobile, and it actually looks good https://github.com/primer/github-vscode-theme/issues/19#issuecomment-630435353

It would make sense using it.

estevanmaito avatar May 23 '20 15:05 estevanmaito

This might be irrelevant to this issue but I feel using #fff as white in general is too bright in a dark theme and kind of hurts my eyes. I am not sure if the iOS app uses #fff as white but we can test that out.

icebeam030 avatar May 29 '20 00:05 icebeam030