TumblrFeed

Curate, connect, and discover

Witch King Ao3 - Blog Posts

1 year ago

im guilty of having those huge blanks everywhere, but I like it in other fics so i kept it that way (safer to have too much blank space than something too wall-of-text-y was the reasoning), if any of my readers are here do tell which version (small or big paragraph break) you prefer 🖤

StripAllEmpties: Remove extra blank paragraphs from AO3 works

When you're reading on AO3, you may encounter fanworks that have lots of empty space between each paragraph.

A screenshot of an AO3 work, viewed on mobile. The first few paragraphs have a regular amount of space between them, while the  others have extra spaces. The extra spaces are caused by AO3 inserting blank paragraphs in between the text, and mobile users have to scroll more when reading works with these extra spaces.

AO3's help text (select the question mark at the top of the main text field when posting or editing a work) says this:

If you have two blank lines in a row between paragraphs, we will add extra whitespace in for you (with <p>&nbsp;</p>).

The site can't tell the difference between when a creator intends to add extra spaces (some people use blank paragraphs as scene break markers, instead of the <hr /> line code or text symbols) and when they do it by accident. Which means that there are a lot of AO3 works with unintentionally large spacing that can be hard to read, especially on mobile.

AO3's Unofficial Browser Tools FAQ links to the StripEmpties bookmarklet by carene-waterman as a solution for readers who dislike these empty spaces. Unfortunately, it doesn't work on all fics. This is because StripEmpties looks for the code <p>&nbsp;</p> (a paragraph containing a single non-breaking space) – and nothing but this code. Which means if there's an empty paragraph with two spaces in it, or one that's actually made up of a bunch of line breaks, those paragraphs won't get hidden.

That's why I made my own version of the StripEmpties bookmarklet. This one looks for paragraphs that contain nothing but whitespace – regular spaces ( ), non-breaking spaces (&nbsp;), empty line breaks (<br />), etc. – and hides them from view temporarily.

This is the code for what I'm calling the StripAllEmpties bookmarklet:

javascript: void(function (){var paragraphs = document.querySelectorAll('#workskin p');for (const para of paragraphs){if (!/\S/.test(para.innerText)){para.style.display = 'none'}}})();

Bookmarklets can be used on any browser or device. To add a bookmarklet to your browser, the easiest way I've found is to create a new browser bookmark of any random page (by selecting the bookmark/star/heart/etc. icon on your browser) and then edit the bookmark to replace the URL with the bookmarklet code. (You should also change the name of the bookmarklet too.) Save your changes, and you're done!

A partial screenshot of the iOS Safari bookmark editor, with the title of the bookmark now set to "StripAllEmpties" and the bookmarklet code pasted into the URL address field. The bookmarklet location is in the Favorites bookmark folder.

You can use the bookmarklet by going to any AO3 work, opening your bookmarks folder, and selecting the StripAllEmpties bookmarklet. If there were any blank paragraphs in the work, they will now be removed.

A screenshot of the same work as before, but after the StripAllEmpties bookmarklet was used. The extra spaces between the third, fourth, and fifth paragraphs that were present in the first screenshot are now gone, all of the paragraphs have a regular amount of space between them. A newly visible sixth paragraph explains that the bookmarklet's effect can be reversed by refreshing the page.

The bookmarklet's effect is temporary. If you want to bring the spaces back, all you have to do is refresh the page.

I hope this helps! Happy reading.


Tags
1 year ago

"must first priority to be that it can't be [etc]"

- gem found in my notes for the fic


Tags
Loading...
End of content
No more pages to load
Explore Tumblr Blog
Search Through Tumblr Tags