Saturday, July 14, 2012

Reddit New Comments Highlighter Chrome Extension

So, this is a reddit gold feature which enables a user to highlight all the new comments on a link since he last visited the page.
I have also added keyboard shortcuts Shift+UpArrow & Shift+DownArrow to goto the nearest new comment.

The extension has 2 configurations:

  1. Maximum History: The total number of records to keep in the local storage.
  2. Pixels: The number of pixels to keep above the new comment when the extension scrolls using Shift + Up/Down arrow key.


The Options can of coarse be accessed via Extensions page. The code is available at: https://github.com/shadyabhi/Reddit-New-Comments-Highlighter & can be installed via Webstore at https://chrome.google.com/webstore/detail/ajdilinnnkbmpoegibgacadjlblmpjad

TODO: Trigger highlighting when user presses "load more comments" on threads with hundreds of comments.

2 comments:

  1. Thank you for creating this extension. It is basic functionality to which all Reddit users should have access without paying $30/year for Reddit Gold. It's the only way to follow a post with a lot of comments in any meaningful way after the first time you read it.

    ReplyDelete
  2. If anybody wants to change or remove the shift-up / shift-down shortcuts, go to Window › Extensions, copy the ID number under "Reddit New Comments Highlighter", it will look something like "ajdilinnnkbmpoegibgacsdfgblmpjad", then find the extensions folder named like the ID number (under Mac it's Library › Application Support › Google › Chrome › Default › Extensions › ajdilinnnkbmpoegibgacsdfgblmpjad). Find script.js file inside, open in TextEdit or other similar program, find and edit the parts containing shortcut keys on line that will look like this "shortcut.add("Shift+Down", function() {". Personally I just added some random keys to the shortcut, because I'll never use it anyway (Shift+Down+F+D+U+Z). It will probably work only until next update, but I'm guessing this app won't be updated often anyway.


    Cool little extension though.

    ReplyDelete