Comment: (github.styl) Issue label text color

Black provides poor contrast with some dark label colors, so using
white seems like the best choice for maximum contrast with arbitrary
label colors.  But since the default label color is light gray, that
would make for very poor contrast on new labels.  So we use a CSS drop
shadow to compensate for that.  Hopefully it's a reasonable
compromise, because there's only so much that can be done.

But none of this works because Stylus can't handle :not(), or
something like that.  See comment in file.  So this is really just a
note for the future, because I don't feel like hacking up all the
generated CSS for the sake of GitHub labels.  *sigh*
master
Adam Porter 4 years ago
parent e6321158c4
commit bea989070b

@ -7,6 +7,23 @@
// ** HTML elements
*
border-color()
// HACK: Don't apply A color to GitHub issue labels. This should not
// be done here, but to do otherwise would require removing the A rule
// from this file and adding it to all other sites manually. The
// issue is that GitHub assigns label colors in <SPAN STYLE=...> tags
// depending on the label's background color, so we don't want to
// override label A colors, but there is no way in CSS to negate
// !important for certain selectors.
// But apparently Stylus (or the version I have, at least, who knows)
// doesn't support :not(), and it removes it from the CSS files it
// compiles. So while this hack might work in the future, it appears
// that, for now, the GitHub CSS must be edited manually after
// generation. What an awful idea...
// a:not(.IssueLabel)
a
a()
a:visited

Loading…
Cancel
Save