Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nth child background color weirdness on dark mode old reddit #25

Open
iampueroo opened this issue Jun 16, 2021 · 5 comments
Open

nth child background color weirdness on dark mode old reddit #25

iampueroo opened this issue Jun 16, 2021 · 5 comments

Comments

@iampueroo
Copy link
Owner

Summary

To recreate, go to https://old.reddit.com/r/soccer/ with RES dark mode. After hovering on a comment, clicking "next reply" seems to trigger a swap of background color. Plus, the background color of each comment seems to be applied on the wrong element.

@iampueroo
Copy link
Owner Author

Upon more investigation, it seems that this is an :active-type behavior added by RES

@iampueroo
Copy link
Owner Author

Root cause seems to be that RES is listening to click events that bubble up to the entry class. I cannot simply stop the event propagation since there is only one event handler on rComments added directly to the parent popup, which is a parent of entry.

Possible Solutions:

  1. Move the event handler of "Next Reply" directly on the element and stop its propagation after handling
  2. Undo the stylings added by the RES class only on the popup
  3. Remove the entry class, "manually" add all the stylings from the Reddit stylesheets (this seems to be the least desired).

In general, I'd leave this as a low priority, as it only affects users on the old Reddit with RES.

@iampueroo
Copy link
Owner Author

Note: this affects both light and dark mode on RES, so it's quite annoying.

@iampueroo
Copy link
Owner Author

@azizLIGHT - Pinging you since you've been helpful and curious if you've seen this (I know you use quite a bit of extensions). Do you use rComments w/ RES on old reddit? and if so, does the "active" stylings on "Next Reply" click annoy you? I'm assuming the "active" class is important since RES allows traversing comments via keys, so I'm curious if you have an opinion.

Again, my hopeful fix is to still allow the highlighting to continue, but just not automatically highlight the comment when you click the "Next Reply".

@azizLIGHT
Copy link

azizLIGHT commented Jun 18, 2021

This is what I see on old reddit with RES dark mode:

Peek.2021-06-18.13-32.mp4

Honestly its not a bother to me, its sort of useful maybe? Though I can get it to highlight multiple comments after I click the body of a subcomment and load a new parent comment and click it's next reply link. Either way I'm not that concerned with it but maybe it bothers other people?

Peek.2021-06-18.13-39.mp4

It's upto you how you want to handle it!

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

No branches or pull requests

2 participants