file-age-color - Dim older files#9162
Conversation
fregante
left a comment
There was a problem hiding this comment.
The idea is good but the amount of code is most definitely not. I'd think this would be 5-10 extra lines, not 190. At that length it's not worth it.
|
Sure makes sense, admittedly I didn't pay attention to the scope compared to other features. I'll give a shot at reducing or close this! |
|
I'd start by just giving it a hard 1-year cutoff date for a single dimmed color. We don't really need the whole rainbow: focus on really new files, ignore the really old ones. |
|
I moved all logic back to the single feature file, and condensed it. I also had implemented a separate test file which i thought was needed but I realize now it's not. |
|
afda2be to
b3e3bc1
Compare
|
To maintainers: Please add labels to this PR |
|
@fregante I see, I did personally prefer the gradient just because it's cool, but you're right that it's a lot of complexity for a hardly noticeable difference. Let's compromise and have 2 fixed gray states instead of the gradient? 😄 Surface is very small now on this.
|
file-age-color - Dim older files

Keep recent file activity dates highlighted in orange, then fade older dates by reducing the opacity of GitHub's muted text color.
Adds extra context with minimal styling and without overwhelming the page with hot file color. This makes the old-age side of the gradient theme-aware, adds customization hooks for the orange threshold, fade threshold, hot color, and minimum opacity, and avoids changing the shared heat-map logic used by other features.
Defaults to 365 as the threshold for oldest file color. Fades from default gray color to our default cold file color over the 365 period.
Test URLs
https://github.com/refined-github/refined-github/
Screenshot