[Userscript]: WaniKani Ultimate Timeline

The timeline is now partially covered at the top by the new WaniKani header. Anyway I can reposition?

1 Like

I had this too, it’s not ultimate timeline. I assume you mean your search bar is also gone? For me it was the combination of Leech List and Burn Review. They pushed everything up as they tried to occupy the same space, causing all things on the dashboard to be pushed up. Turning off one of these script should do the trick. If that doesn’t work, turn everything off and add stuff one by one.

4 Likes

Thank you! I don’t have leech list, but turning off burn review did the trick. Guess I’ll just flick it on when I want to review burns.

1 Like

Hey there,

I’m pretty sure this is the script I re-downloaded in October when I got my laptop

I believe it used to work, but I’ve noticed (finally, it may have been since WK’s redesign) that the timeline no longer appears
 even though I have it activated.

I am running a few other scripts, in case any of these are interfering:


Where is it?


See how it is there
 also note the other scripts which I don’t believe interfered in the past


image

*snickers* I just find this amusing. XD

2 Likes

After reading some of the posts above me, I’m going to try updating WKOF if it didn’t update automatically on it’s own



 Although I’m pretty sure BASIC ran only on v1
 Hmmm :thinking:

EDIT: Well, I had it already (newest ver. of WKOF, I mean), and I reinstalled it. Time to clear cache and reload and see what happens


EDIT 2: Hmm
 Nope, nothing. Even tried loading /dashboard too, since I saw something about that. Weird.

Yeah, that version is only APIv1.
It can no longer fetch the APIv1 key since the location of the key changed.
But you could try entering the following in the Javascript console.

localStorage.apiKey = 'insert_apiv1_key_here';

(substituting your key, of course).

No idea if that will help.

1 Like

Thanks, I’ll give it a try! ^^

Hmm
 it looks like it did nothing. (I put it exactly where it was fetching the API before, on line 620, in this section
)

    // Fetch API key from account page.
    //-------------------------------------------------------------------
    function get_api_key() {
        return new Promise(function(resolve, reject) {
            localStorage.apiKey = 'This_is_my_APIv1';
            if (typeof api_key === 'string' && api_key.length == 32) return resolve();

            status_div.html('Fetching API key...');
            ajax_retry('/settings/account').then(function(page) {

                // --[ SUCCESS ]----------------------
                // Make sure what we got is a web page.
                if (typeof page !== 'string') {return reject();}

                // Extract the user name.
                page = $(page);

                // Extract the API key.
                api_key = page.find('#user_api_key').attr('value');
                if (typeof api_key !== 'string' || api_key.length !== 32) {
                    return reject(new Error('generate_apikey'));
                }

                localStorage.setItem('apiKey', api_key);

Did I need to change it anywhere else?
Oh, or cancel out some lines? (like the one with /settings listed?)

I’m seeing an odd, possibly related problem. Using:
WaniKani Open Framework 1.0.45
WaniKani Ultimate Timeline 7.0.22

The Ultimate Timeline works just fine under ViolentMonkey, and doesn’t run (other than flashing a popup window at highspeed) under TamperMonkey.

For purposes of debugging, the only scripts running are the above mentioned versions of Open Framework and Ultimate Timeline. The Open Framework is configured in the first script slot.

The browser is Version 75.0.3770.80 (Official Build) (64-bit) running on MacOS Mohave 10.14.2 (18C54).

Can anyone confirm what are the most recent versions of the Framework and Ultimate Timeline scripts that are known to work correctly with each other?

What browser are you using?

A bit confused.
The script worked fine. Until randomly it stopped working.
It just won’t start even if I restart my browser or refresh WK.
Even though it’s ‘activated’ on tapermonkey.

Check the Javascript console for errors.
(Press F12 and click on the Console tab)

Turns out clearing “Cookies and other site data” forever possibly fixes it.

1 Like

Sorry if this has been asked before, at least I could not find it. I think the ‘resistfingerprinting’ in Firefox is preventing getting the correct timezone. Is there anyway this could be added in the settings? I tried fixing it in the code but could not get it working


EDIT: Although I do clear all my cookies and lose all of my settings everytime I close Firefox so I have to manually set them again everytime :smiley:

1 Like

@morteasd: imho, Firefox’s built-in cookie manager is too limited.

Personally, I installed the extension called “cookies auto-delete”, and added wanikani.com to the whitelists. This means that these cookies will be preserved, while other sites’ cookies will be deleted.

if you use this extension, you want to disable Firefox’s built-in cookie remover. Else it will interfere.

3 Likes

I don’t have time to work on a setting, but you could modify the script:
image

Change it to something like:

var tz_ofs = 240;

The 240 is the number of minutes to subtract.
So, for GMT-4, you get 240.
For GMT+6, you get -360.

(Also, for the record, I agree with @omoide that Firefox’s security settings are too limited.)

1 Like

Hmm thanks, but for some reason that doesn’t anything for me. The times are still wrong.

TypeError: LOCAL_STORAGE is null

I wonder if this console message has something to do with it. Also I’m blocking all third party cookies so there’s a bunch of messages.

I tried searching some advice and dom.storage.enabled = true is enabled.

Because I lost all my scripts (and v1 BASIC I couldn’t get to work with my key) I’m trying to figure out the graph stuff again - although your fantastic settings box/button took care of most of the features! It’s really swell!

Just want to simplify the grid (again) and switch the 1.5 days+ back to hours
 But wow, the new script is harder to understand. APIv2 is not non-coder friendly.

Also, I want to try and make something really tiny myself
 and have it link to your wkstats.com as well
 I was looking for your “fetch APIv2” code in the WKOF and this script, and couldn’t see anything. \_(^。^ )_/

Would it be easier to use/intergrate WKOF? Although it’s something I want to put in the header of https://www.wanikani.com/* so it’s ever-present.

EDIT: Copy-pasting your old code (that I replied to) into your new script gave me a ton of errors
 all new definitions (hence why I can’t grasp what’s going on too much). Y’know, with the // to cancel the current code without deleting it in case of screwing up - like I did. Vertical was easy though
 delete a whole section. XD Found the slider, too. It’s just
 the math in the grid/graph stuff. @_@

EDIT 2: Before I began fiddling with the code (and only changed the settings) I noticed this strange phenomenon - the bar is pre-graph with all my old reviews
 and new reviews are floating up above it (which is super weird - the other thing I can see some logic in, they’re not “upcoming” they’re old and have been sitting there). I’m also curious what happened to the number - unless it’s covered by the placement of the bar?


Here are my settings:

tomorrow 21:00, I will be experiencing a “freak wave” (vague cĂ©lĂ©rate) of reviews :ocean:

Coming of nowhere, a wall of 111 reviews will crush on my head :cold_sweat:

wikipedia : Rogue wave - Wikipedia

@rfindley - I never figured it out, but the bars are still drawing weird (outside the graph). See screenshot two posts up.

@_@ ← *confused*