Skip to content

Conversation

@SunsetTechuila
Copy link
Contributor

fixes #8801

Test URLs

Screenshot

Comment on lines 25 to 26
/* Fallback in case `show-names` is disabled - #8726#issuecomment-3606420543 */
background: var(--bgColor-muted, var(--color-canvas-subtle, fuchsia));
Copy link
Contributor Author

@SunsetTechuila SunsetTechuila Dec 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure If I like this. I'll let @fregante decide

cc @karlhorky

#8726 (comment)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can't be more explicit than that

image

Copy link
Contributor Author

@SunsetTechuila SunsetTechuila Dec 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's I don't like for sure

msedge_O7rDNAJFSg

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm reverting that. Due to #6554, the background of comment headers that should be blue is gray when navigating from issue list to issue page. The header also turns gray after a comment is edited

I assume this makes the comment headers just use the standard (non-blue) header color, right?

Yes, that's how it worked

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can html:not([rgh-OFF-show-names]) be used here?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don’t think that attribute exists? But I suppose manually adding a class in that feature could also work. 👌

@fregante fregante added the bug label Dec 3, 2025
@refined-github refined-github deleted a comment from 96welchlin-wq Dec 8, 2025
@fregante
Copy link
Member

fregante commented Dec 15, 2025

Screenshot

?

I assume this makes the comment headers just use the standard (non-blue) header color, right?

@fregante fregante merged commit 1584e59 into refined-github:main Jan 3, 2026
13 checks passed
@karlhorky
Copy link
Contributor

@fregante @SunsetTechuila thanks for the PR and merge!

@karlhorky
Copy link
Contributor

karlhorky commented Jan 3, 2026

@SunsetTechuila Why was the fallback fixing the transparent header problem reverted?

@SunsetTechuila
Copy link
Contributor Author

@SunsetTechuila SunsetTechuila deleted the stickych-css-vars branch January 3, 2026 12:47
@karlhorky
Copy link
Contributor

karlhorky commented Jan 3, 2026

That's I don't like for sure

@SunsetTechuila what do you mean? That it starts out as black and then changes to blue on hydration? Maybe the fallback can be applied differently, to avoid the FOUC? Eg. via JS or something.

@karlhorky
Copy link
Contributor

Can html:not([rgh-OFF-show-names]) be used here?

But I suppose manually adding a class in that feature could also work. 👌

Or maybe adding a class, as fregante mentioned?

@SunsetTechuila
Copy link
Contributor Author

SunsetTechuila commented Jan 3, 2026

Or maybe adding a class, as fregante mentioned?

That's what I'm planning to do: add this class and use it to disable sticky-comment-header if show-names is disabled

@karlhorky
Copy link
Contributor

karlhorky commented Jan 3, 2026

Maybe we could do it in such a way that the feature doesn't get disabled, but instead degraded? (graceful degradation). Black/grey background is fine in that case.

Then the notice about the show-names could also probably be removed.

@SunsetTechuila
Copy link
Contributor Author

Maybe we could do it in such a way that the feature doesn't get disabled, but instead degraded? (graceful degradation).

I couldn't. Maybe you can

@fregante
Copy link
Member

fregante commented Jan 4, 2026

Ok, how about this? rgh-own-comments feature that simply adds .rgh-own-comment to your own comments. It would be a silent, non-disableable feature that can be used by others. This way we drop the inter-feature dependency (show-names) and can be used by more features in the future if helpful.

@karlhorky
Copy link
Contributor

@SunsetTechuila what do you think of this approach with the non-disableable rgh-own-comments feature? Do you think that you could do this? Or should I give it a shot?

@SunsetTechuila
Copy link
Contributor Author

Maybe there are already several helper features like this in RGH, but if not, then I'd rather stop trying to keep sticky-comment-header CSS-only. Keeping it CSS-only has caused way more hassle than ~10 lines of simple JS code ever could

@karlhorky
Copy link
Contributor

@fregante is it a requirement to keep it CSS-only? Or would a short JS feature like what @SunsetTechuila is proposing also be acceptable?

@fregante
Copy link
Member

fregante commented Jan 7, 2026

I already gave my suggestion

@karlhorky
Copy link
Contributor

karlhorky commented Jan 7, 2026

Ok, so the non-disableable rgh-own-comments feature is the path forward then.

@SunsetTechuila if you think you would do this, then great! Otherwise, I can take a shot at it.

@fregante
Copy link
Member

fregante commented Jan 7, 2026

For future reference: Note how much this "small feature" had to be discussed and tweaked and bugfixed for months. This should help understand why I'm hesitant to accept certain features and why I might drop this one.

@karlhorky
Copy link
Contributor

karlhorky commented Jan 7, 2026

I empathize with the back and forth of the discussion sapping of focus away from other work - it's unfortunate that GitHub's DOM, tech stack and framework integration makes for a less stable foundation upon which to build a browser extension (on the other hand, luckily, there has been no shifting in the relevant parts of that foundation since this feature was first implemented).

However, aside from the back and forth in discussions and the technical requirements, I'm not sure I agree that the amount of total implementation work that has gone into this feature is overly blown-up (also as I mentioned in my comment in October - most of the work was done before then): the first versions and fixes have been developed pretty quickly by @SunsetTechuila (also taking into account browser compatibility).

Maybe with looser requirements like not having the CSS-only rule and not having the dependency on other features it could have gone a bit faster - but probably also not worlds apart.

@SunsetTechuila
Copy link
Contributor Author

Ok, how about this? rgh-own-comments feature that simply adds .rgh-own-comment to your own comments. It would be a silent, non-disableable feature that can be used by others.

Maybe there are already several helper features like this in RGH, but if not, then I'd rather stop trying to keep sticky-comment-header CSS-only.

@SunsetTechuila if you think you would do this, then great! Otherwise, I can take a shot at it.

@karlhorky I didn't look thoroughly, but I couldn't find any other helper features like that. So if you want to implement it, you'll have to do it yourself.

When you do, please also change [class^='ReviewThreadComment-module'] to [class*='ReviewThreadComment'] - GitHub added a similar component with a different name, InlineReviewThread. Test url: refined-github/sandbox@7becc26#r174065194

Off-topic

For future reference: Note how much this "small feature" had to be discussed and tweaked and bugfixed for months. This should help understand why I'm hesitant to accept certain features and why I might drop this one.

The lesson I've learned is that it depends on how broad the feature's effect is. If it affects something very common that appears in different forms (like comments) - expect problems.

SunsetTechuila referenced this pull request in refined-github/sandbox Jan 7, 2026
@SunsetTechuila

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

fuchsia background with sticky-comment-header on GitHub Enterprise Server v3.12.17

3 participants