[Feature request] Mark posts as read when clicking the expando on new new reddit
Reddit enhancement suite added a feature to mark a link as visited when you clicked the inline expando. It doesn't work for new reddit, so I was hoping you could replace it in your extension.
I believe this is the line in reddit enhancement suite that actually marks the url as visited. But I have no idea how to detect when the expando is clicked, hopefully that is easy as well.
Sorry for the late reply, and thanks a lot for referencing the feature in RES! I’ll need some time to test this further, but theoretically we can use the same approach as RES’s to mark a post as read and attach the event to the expando. We’ve been already using MutationObservers to detect when posts are rendered, for features like Show Post Numbers.
RE also uses :visited to mark a post as visited, and Reddit stores your post view history locally in the browser, so this shouldn’t cause any issues.
I’ll keep you updated once #157 is done.
On 9 Apr 2025, at 09:35, Watchful1 @.***> wrote:
Reddit enhancement suite added a feature to mark a link as visited when you clicked the inline expando. It doesn't work for new reddit, so I was hoping you could replace it in your extension. I believe this is the line in reddit enhancement suite that actually marks the url as visited. But I have no idea how to detect when the expando is clicked, hopefully that is easy as well. — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.Message ID: @.> Watchful1 created an issue (joelacus/RedditEnhancer#160) Reddit enhancement suite added a feature to mark a link as visited when you clicked the inline expando. It doesn't work for new reddit, so I was hoping you could replace it in your extension. I believe this is the line in reddit enhancement suite that actually marks the url as visited. But I have no idea how to detect when the expando is clicked, hopefully that is easy as well. — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.Message ID: @.>
Thanks!
@Joelacus I’ll need a new extension permission to access the browser history API for this. What do you think?
On 29 Apr 2025, at 09:09, Watchful1 @.***> wrote:
Watchful1 left a comment (joelacus/RedditEnhancer#160) Thanks! — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>
This works, but I think it's causing page crashes. If I open reddit, then click the expando on an image/video, it always causes the page to refresh. Once it has refreshed, then clicking the expando again works fine and correctly marks it as read. But the first time after page load it always crashes the page and causes it to refresh.
This gets annoying if the first time I click one is after scrolling a while because it makes me lose my place.
I'll follow up in #163.