# Empuzzler: A user script for hiding comments and answers until you want to see them

I've created a user script that hides comments and answers on Puzzling.SE's main site by default, and reveals them only when you want them revealed.

I've done this because I'm the sort of person who dislikes having potential spoilers or answers in view or at risk of being in view whilst I'm mulling over a puzzle. They're too tempting to glance at! I have to put mental effort into not scrolling, or averting my eyes from certain sections of the screen, and so on. There's so much more peace of mind for me in those answers simply not being there until I'm ready to look at them.

I'm also the sort of person who happens to be able to do something about it, because I can create user scripts. So I made a solution for this problem for myself, and thought some of you might want to use it too.

It's called the Puzzling.SE Empuzzler. You can get it here on Greasy Fork.

• Chrome users ought to be able to add it straight away.
• Firefox users will need Greasemonkey.

It runs exclusively on Puzzling main site questions, so it won't do its thing on any other SE site, nor on Puzzling Meta.

The result currently looks like this on this question:

see this bit right at the end. ↑ No comments or answers in sight until I want them there.

There may be places to improve it still. If there's anything it should do differently, or anything it doesn't do that it should, please let me know.

# Todo

2. Logged-out users get a login prompt when they expand the comments section. Need to make sure this doesn't happen.
3. Add a way to turn all spoilers in answers into regular un-spoilery quotes, since peoples' practice of spoiler-protecting their answers is redundant if you're using Empuzzler. Possibly also the same for questions, but separate.
• Nice script! If you want prettier buttons, you could use a <input type="submit"> instead, but looks great otherwise! – Doorknob Oct 8 '14 at 11:43
• @Doorknob Thanks! I've added a Show Everything! button, and tried out that style along the way - all three bright orange buttons together is glaring though, so I've decided to stick with the classic styling for now. When the site leaves beta, if its new skin has less vivid buttons, I'll see about switching over to the pretty ones again. – doppelgreener Oct 8 '14 at 13:53
• Ah, right, I meant <input type="button">. That should be a bit less... excessive. – Doorknob Oct 9 '14 at 0:00
• @Doorknob Don't both have the same style? That's the one I used actually ;) in the name of semantics I couldn't bring myself to use the submit type. – doppelgreener Oct 9 '14 at 0:02
• @Doorknob input[type=submit] has the same orange styling as input[type=button]. Only button is grey :-) – Joe Oct 9 '14 at 0:04
• @Doorknob if you already installed this; I've updated it and added (or, really, fixed) the auto-update. You might want to update to this version to get that auto-update going. (This message will self-destruct when acknowledged.) – doppelgreener Oct 9 '14 at 1:07
• Nice script! You know where it would fit great? Code Review :-) – Schism Oct 17 '14 at 23:02
• This would be awesome on codegolf.stackexchange.com too – Chrismas007 Dec 12 '14 at 15:27
• This is simply awesome :D – ABcDexter Jul 20 '16 at 7:46

Chrome:

2. Rename it .user.js
3. Go to this URL: http://chrome://extensions/
4. Drag the .js onto the list of extensions
5. Allow any requested permissions
6. Riddle In Peace

Not sure if you're too fussed, but I took the liberty to tidy it up a little bit - moved all the vars to the top, rewrote some parts, etc.

Feel free to ignore it :P

http://pastebin.com/9QNzrRnX

Update for 0.4 - see the changelog :-)

http://pastebin.com/j64sWkXb