Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Something Awful Last Read (SALR) Redux
Old SALR Chrome thread

Requirements
Latest version of Chrome or Firefox

In order to use the highlighting features you must have the appropriate thread tracking options turned on in your User Control Panel on the forums. Since the forums now track threads for you, SALR only enhances the functionality rather than implement it.

Download Links
Chrome
SALR Redux: https://chrome.google.com/webstore/detail/something-awful-last-read/bogegdelcjhoaakaepmoglademmhiboo

Firefox
SALR Redux: https://addons.mozilla.org/en-US/firefox/addon/salr-redux/

Development
And for those of you who want to contribute: https://github.com/MasterOdin/salr-redux

Patches are accepted, so if you're a web developer and want to help out, send over a pull request!

Follow the link above to install.

Once installed, basic highlighting features are enabled. To configure options, click on the SA logo in the location bar (omnibar). You will only see the SA logo when you are viewing the forums.

Page navigator is not enabled by default. To enable it, turn it on under "Page Display" in the options panel.

Have an idea you'd like to see in the extension?

Post it in this thread or in an issue on Github.

Features/Screenshots

THREAD HIGHLIGHTING!



HIGHLIGHT WHEN PEOPLE QUOTE YOU



PAGE NAVIGATOR



QUICK REPLY



Other features:
- Mouse gestures
- Keyboard shortcuts
- Various highlighting options
- User notes
- Convert Youtube links to inline
- A bunch of settings

Special thanks to Ferg as the original developer of SALR Chrome!

https://gfycat.com/ifr/AccomplishedAptHammerheadbird

Adbot
ADBOT LOVES YOU

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Gorilla Salad posted:

I see there's highlighting for when people quote you - does this me the "Add Coloring/Note" function is still there for weirdos like me to use?
You can add notes that are colored, but you cannot color a user's post based off that note currently.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Samizdata posted:

Oh, no worries at all. Was just trying to contribute what little I could to help. Just so happy to have a proper tool back.

Say, I haven't noticed, but is there a way to set Show live preview as the default? The existing option doesn't seem to do anything.
It's the last option under the "Show Quick Reply" list of options under "Control Options" section. All of the checkboxes on the Quick Reply window can be toggled on/off by default.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

astral posted:

Before I finish/push that out to the legacy Firefox SALR users, though, I want to look into how easy it'd be to add custom poster backgrounds & avatar hiding to Redux because then we could import all of those in one go. Once everything's available and the version with migration is in place, I'll recommend anyone still hanging onto ESR just for legacy SALR make the jump.
While it's probably not too hard to add backgrounds (add a new key 'background' that points to a color in the existing notes structure, then just add additional color picker on notes modal), I want to sit down and rewrite a large portion of how this stuff is handled (especially with regards to the other highlighting stuff). Namely, right now we basically iterate through table.post a bunch of times for all the different highlighting/notes options which is a bit inefficient when we realistically should just loop through all posts on the page once, checking if the post is by friend/OP/self, does the post contain a quote by self, do I have a user note for this person, etc. I also want to combine friendListID into the user notes structure so that the final structure would be:
code:
{
  <user_id>: {
    "is_friend": null|boolean,
    "note": null|string,
    "color": null|string,
    "background": null|string
  }
}

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Welp, looks like Mozilla found issue with the extension and have disabled on versions for now. That's an unfortunate setback.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

astral posted:

That's intentional. The upload doesn't block text entry and there's no guarantee how fast it'll complete, so it gets thrown at the end rather than in the middle of whatever you're typing at that moment.
Perhaps we make it so that if you upload an image and don't type, it'll place it at the cursor, else it'll do it at the end.

I'd like to make that the functionality for quoting posts with the quick reply window open.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Uncle at Nintendo posted:

I apologize if this was asked before, but there is a bug in Firefox and am wondering if there's a way I can fix it by messing with SALR for Firefox?

When I click on a link to a post, or click on a thread to bring me to the last unread post, I notice Firefox always brings me back way too far. It has something to do with the way Firefox is loading images or maybe twitter embeds or something. It can be very frustrating when someone links to a direct post (or I click a quoted post from a different page) and it brings me to the wrong post. I always have to scroll down to the correct one, and sometimes I am not even aware what the correct one is.

I tried SALR and it still does that, though. I know this is not SALR's fault but is there something I can change in SALR so "go to last unread post" or direct post links actually "dump" me to the correct post?

Sorry if this is a stupid question. As a sidenote, SALR is fantastic.
SALR attempts to fix that with the "Adjust window position after threads load" setting underneath "Thread Options", but it was always a janky solution and there's now way better methods for detecting when this happens that would be ideal to rewrite it to use.

But yeah, it's because of twitter embeds and the like which load after the fact on SALR.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

tithin posted:

Just got this message when trying to post via SALR - since when has dear richard given a gently caress about the SALR extension enough to code a way to deny it?
Generally, this just means the CSRF token (which SA calls "form cookie") you were using had expired, which I'd guess is just if you have the reply open for long enough it might expire. You may just need to refresh your browser and try again.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

withak posted:

edit: I feel that I am entitled to a full refund.
You'll get the vast SALR fortunes over my cold dead hands.

Will spend some time seeing if I can't fix this, not sure immediately what would be causing it as it's not something that's been affecting me so I did not know it was a thing.

Testing editing on google canary.

Master_Odin fucked around with this message at 18:28 on Nov 9, 2019

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Testing quick reply from chrome canary...

editing the post now...

Master_Odin fucked around with this message at 18:58 on Nov 9, 2019

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
New version submitted for review for Chrome. Going to spend some proper time this week trying to automate releases to both Chrome and Firefox channels to make it easier to keep things in-sync with each other.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Kild posted:

Thanks, any eta for the chrome release?
It should be available. The chrome release should hopefully be coming out at a same/similar time as the Firefox release in general going forward.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
New version of salr-redux has been submitted that has an improved quick reply styling when dark mode is running. I will try and get to adding a post highlighting / thread highlighting default colors for dark mode soon, as well as an ability to view the settings page under dark mode to make that work easier. Note, as part of this, I'm not going to have a separate dark mode toggle in SALR, but just auto-detect from SA itself for it.

If anyone has any particular suggestions for colors though, I'm all ears.

e: firefox and chrome extensions have been published and people should be able to update to 2.3.0.

shortspecialbus posted:

Is this extension taking a policy of saying "no" to any feature request that could be done with user stylesheets, by the way? It seems to be the default response to a lot of things as of late.

If that's the plan for going forward, then that's fine and all, but the OP should probably have a note saying as such. I still feel like stuff such as font size and other things that can be done in CSS would be good additions for people who don't want to screw around with another extension and/or learn CSS but I'm not developing this so I can't really complain :shrug:
For me, it depends on how "niche" the request is. SALR already does a fair amount of style mucking about so I'm open to adding more stuff. However, some of this is that my current time is very thin and I'm stretched over too many fun projects these days.

Master_Odin fucked around with this message at 19:19 on May 17, 2021

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
I've landed a fix for it, as well as made that bit of code a bit more resilient so it won't crash the extension in the future if something changes again.

Submitted the new version to Chrome and Firefox, make take a bit before it's up.

e: Firefox users can grab the new version.

Master_Odin fucked around with this message at 01:14 on Dec 3, 2021

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
This new version also has WIP I've got for a dark mode toggle in the settings pane so that people that use dark mode can now more easily see how their color scheme will look in settings. It's still rough around the edges and some things aren't quite there, but well, it's something.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Stare-Out posted:

Am I nuts or did the font in the quick reply box change?

E: It looks like Console now.
A fix for this will come out shortly so that it uses the same font-family as SA's regular rely textarea.

LastInLine posted:

I just discovered something that's not really a problem but I think is really weird. I use the quick controls and you know how the Alt key disables that so you can use the right click menu? Did you know you have to use the same Alt button to toggle it back? Like you can't toggle them off with the left key then toggle it on with the right.

I've always wondered why sometimes I couldn't get it to turn back on.

Edit: Should mention this is Chrome
This is surprising behavior, and definitely not expected, as the code uses a single keyCode value (18 which should cover both alt keys) to turn it on/off. My only assumption would be that your keyboard is somehow toggling the value to something else?

Could you go to https://codepen.io/chriscoyier/pen/mPgoYJ and press the left and right alt keys into the text area and let me know what the returned values are?

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Hm, maybe makes sense to insert as a new button to the page switcher, though not sure where exactly it makes sense to put it, or what the icon could be. Any suggestions or thoughts?

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Saukkis posted:

Oh yeah, that does work. Maybe "U" as keyboard shortcut for the function. Description does need work. How about "Reload thread and jump to first unread post".

"Last post button reloads the thread and goes to first unread post instead of scrolling to unread post on current thread page"? I'd like to keep the "instead of..." section just to give difference of behavior.

Adding a new keyboard shortcut to do this as well probably makes sense as well.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Yeah, qsvui has it right. If you are using synced user notes, then they're saved to the account logged into your browser (either firefox or chrome) using the storage.sync API and will show up on any device that's using that same logged in browser profile.

Notes stored locally are stored in window.localStorage and only available to you on that device + browser, and will not show up if you go to another device.

The difference was added because there were some people back in 2014 that wanted to have user notes per device. The average user will probably want to leave the user notes synced, and also not worry about those buttons.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
What's the resolution / size of your laptop screen?

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

Nalin posted:

I'll submit a PR to fix this one too. We are also still waiting for my previous bugfix to actually be pushed live.
New version of salr-redux has been published that contains both these fixes. Thanks for submitting the PRs!

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies

qsvui posted:

looks like this has been finally fixed, thanks!
All credit goes to Nalin for fixing it and all shame to me for not releasing a new version with the fix for months.

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Ideally there'd be something (an error) that shows up in the developer console that would indicate what went wrong.

There was a bug for a while with firefox where if you had a page open long enough the "runtime port" would end up disconnected which would account for things not working, but that should have been fixed in the latest release (2.4.3).

Adbot
ADBOT LOVES YOU

Master_Odin
Apr 15, 2010

My spear never misses its mark...

ladies
Put salr-redux v2.5.0 that fixes the feature to use localStorage instead of WebSQL. Given that WebSQL was fully removed from Chrome like a month ago, there's no way to transition the old data to new setup, so have to use this opportunity to post in all your favorite threads again to get them marked.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply