I’ve created a simple little script that adds a “Next Critical Review” time to the dashboard. This is the time that the review for the last radical/kanji that you will need to complete the level becomes available.
Another way of saying that, is that if you always complete your reviews at the suggested time, with 100% accuracy, then you will level up in the minimum period of time.
The main use for me is that it helps me not stress about reviews coming up each hour. Instead of tricking myself into staying up 20 more minutes for another batch of reviews, if I know that the next “critical” review is several hours after that, I can just go to bed
I’m guessing the include statement had an issue. I’ve changed it to match what I see in other scripts, so update and give ti a try! If that doesn’t work, can you tell me what url is in the address bar?
FWIW, this only seems to work if the URL is WaniKani — Log in… which doesn’t include wanikani.com. I know they go to the same place, but I usually visit wanikani.com, which means it doesn’t show up.
It also has this unfortunate interaction with a common dashboard script; I wonder if there’s a way to get it to just list all 5 items (next review, next critical review, etc) on a single line. As an interesting note, that dashboard script correctly expands it from 3 items to 4 items, so I wonder what the problem is here.
Looking into what it would take to get the scripts to play together. Both scripts attempt to resize the columns to fit four items, so somehow need to detect that the ither script is in play then override changes to make each box 20%.
Hey, I made the other script so we should coordinate our patches so it works regardless of which runs first. I think the best way is probably just checking how many elements there are in there already and setting the width to that. That way it would still work if there’s any other scripts doing the same thing in the future
That is simpler than what I was thinking. What do you think of adding something like this to both scripts?
function set_header_width() {
var header_count = $('.dashboard section.review-status ul li').length;
var width = (100/header_count) - .1;
$('.dashboard section.review-status ul li').css('width', width + '%');
}
Great, I’ve pushed up a new version with that patch. I also locally edited “Expected Daily Number of Reviews” to test it, and the outcome looks good to me!
Thanks. Super useful script^^
But since the include statement is *.wanikani.com it also includes the community section which leads to it asking for the open framework which is inactive on that page.
Changing both include statements to https://www.wanikani.com fixes that and should not break anything(not entirely sure though, but changing it locally didn’t introduce any bugs for me).
I tried adding the function to the “expected daily reviews” script, but it doesn’t seem to work no matter where i call it. i’m a programmer–but not a javascript one–so i might be missing some aspect of it.
Nerdy programming moment: There are two changes required to make it work. (1) call the function somewhere after the html DOM is injected, and (2) remove the css style that sets width. The !important flag in the style would override any other width change.
The updated script has both changes, so you are good to go!
I will heavily enjoy using this script for the remaining 3 levels I have. Shoutout to you and all the other scripters who make WaniKani a better experience for everyone! Would’ve loved this script in the times when I lost motivation. It seems like a great way to keep your eye on reality and keep moving forward, even if slowly.
Edit: It actually looks like it’s not working for me for some reason. Here’s the script list I’ve got for the dashboard, and what my dash looks like. I don’t think it would be (I don’t know much about coding, though), but could it be the Breeze Dark Theme somehow?