AO3 Regraph

Draw the statistics bar chart on your AO3 stats page without using google and with more user options.

Author
Ardil the Traveller
Daily installs
0
Total installs
4
Ratings
0 0 0
Version
1.2
Created
2024-05-10
Updated
2024-05-22
License
MIT
Applies to

Escape Google!

This script replaces the google-generated bar chart on your AO3 stats page, so that you can still view your stats graphically without needing to enable google scripts. Block google, and still see your stats compared in an intuitive fashion!

Enjoy New Features!

Like to be able to see more / fewer stories compared? Want your bar chart in lurid green? This script has you covered!

Prefer a different font or font size to make it easier on your eyes? No problem! You can even change the relative height of the bar chart so it’s not quite so squashed.

Easy to Configure (Hopefully)

Configuration options can be found at the top of the script, clearly marked with /* Settings */. Your options are:

  • The fill colour for the bars, as a single hex value. You can find the hex value of a colour you like by looking at the colour picker in most image editing programs.
  • The text colour for the numeric values inside the bars, also as a single hex value. (I prefer this to the mouseover numbers, and also I don’t know how to do mouseover.)
  • How many bars to show on the bar chart. It will accept any number, and if you have fewer stories than the number you input, will automatically cut it down to the number of stories you actually have.
  • The ratio of chart width to chart height. A value of 10 means it will be 10 times as wide as it is tall; a value of 5 means it will be 5 times as wide as it is tall. The width of the chart is always determined by the width available to your AO3 stats page, so it shouldn’t overflow the screen. If you want your bar chart to be taller than it is wide, use fractional values, e.g. 1/4 (four times as tall as it is wide).
  • The font size for the Y-axis title, if the default size is hard on your eyes. Measured in px (pixels).
  • The font for the Y-axis title, if you find another font prettier / easier to read.
  • The font size for all the other parts of the chart (fic names, statistics, etc.). Measured in px.
  • The font for all parts of the chart except the Y-axis.
  • The sorting type to display when AO3 is sorting works by date.

Note that it can only work with stories that appear on the page. If you ask it to display more stories than are visible on your stats page, it won’t be able to see them.

Probably Maintained

I will probably be updating this script as long as I am posting fanfic. So, if there’s some feature that isn’t working or that you’d really, really like to see, drop me a message. I’ll notice it at some point and see what I can do.

Or, if you know what you’re doing better than I did when I wrote this, just go ahead and edit it yourself. If you show me a code update that will make things work, or look, better, I’ll be happy to include it.

Tested on Firefox with Violentmonkey on Linux. I can’t troubleshoot other browsers directly, but I’ll at least search the internet to see if there are any known bugs that match your error report.
Confirmed tested on Firefox with Violentmonkey on Windows 10.

Feature Requests / To Do

  • High Priority
    • none
  • Medium Priority
    • Intended Upgrade: Improve the y-axis numbering scheme.
  • Low Priority
    • Intended Upgrade: Thousands separator for large numbers, for readability.
    • Requested 2024-05-18: Support for CSS colours for rainbow bar charts. Will require me to learn how to do that in CSS, so probably not happening very soon. I’ve added it to the list, though; it does sound neat.
  • Completed
    • Intended Upgrade + Requested 2024-05-18: Word wrap support for long titles. Completed in v1.2, bar any errors being discovered.
    • Bugfix: Graph does not appear when sorting by date! Fix date sorting! (Mostly) Fixed in v1.1.