[Userscript] Wanikani Lesson Spoiler Removal

I’ll agree with shikaji on this one. I, too cycle through lessons with the arrow keys. This script is definitely something I’ve been wanting for a while, but it would be super 便利 to not have to reach for my mouse to see the meaning.

As usual, thanks for all you guys do writing awesome scripts to improve the user experience.

v3.0 has shortcut/arrow key/clicking support

Known problems: short blinking of meaning when navigating to kanji examples and after the reading.

Don’t ask me to fix it because I physically can’t. This update already contains some really weird stuff I can’t really explain (but apparently works). Consider it a funny quirk until my IQ jumps up a few points and I suddenly see the error in my ways.

wow, fast! awesome, thanks! gotta wait for the next lessons to try it out though ^.^

Thanks, looks good. I greatly appreciate all the time you guys put into these scripts.

found something! such a m/Mean litte detail.

putting this @line 37

if($("#supplement-nav ul li.active").text()===“meaning” || $("#supplement-nav ul li.active").text()===“Meaning” ){
makes the whole //ARROWS AND OTHER SHORTCUTS dispensable.  with kanji&vocab now the answer shows up when clicking on or browsing through the tabs to “meaning”.
shikaji said... found something! such a m/Mean litte detail.

putting this @line 37
if($("#supplement-nav ul li.active").text()==="meaning" || $("#supplement-nav ul li.active").text()==="Meaning" ){
makes the whole //ARROWS AND OTHER SHORTCUTS dispensable.  with kanji&vocab now the answer shows up when clicking on or browsing through the tabs to "meaning".
 Damn, indeed. Gratz for finding that!

thanks for the fast update and the credits :smiley: now i can add “programming experience” to my CV xD

also i never want to be without this extension anymore. not seeing the translation right away makes me look much more closely at the actual kanji and i feel memorizing has gotten a bit easier that way. for me it’s even doubly good, cause i reset my account from lvl11->0 and so now i can actually see which items i had completely forgotten over the last couple of months.

I added this a couple months ago and I love it. Sorry, I forgot to tell you! It is very helpful and works great.

~frankiebluej

Bumping this topic for @Radish8 to post a modified version of the script that only hides vocab meanings. Sorry for the late response!

// ==UserScript==
// @name        Wanikani Lesson Spoiler Removal
// @namespace   Mempo
// @description Hides the meaning below kanji and vocab on lesson pages
// @include     https://www.wanikani.com/lesson/session
// @version     4
// @run-at      document-end
// @grant       none
// ==/UserScript==

(function() {
    'use strict';

    //HOVER EFFECT

    var css = '#main-info #meaning {visibility:visible;} #main-info.vocabulary #meaning {visibility:hidden;} #main-info.vocabulary:hover #meaning {visibility:visible !important;}';
    $('head').append('<style type="text/css">' + css + '</style>');

    //CLICKING

    $('body').click(function(e) {
        $('#main-info #meaning').css('visibility', '');

        if ($('#supplement-nav ul li.active').text() === 'meaning' || $('#supplement-nav ul li.active').text() === 'Meaning') {
            $('#main-info.vocabulary #meaning').css('visibility', 'visible');
        } else {
            $('#main-info.vocabulary #meaning').css('visibility', 'hidden');
        }

    });
})();
1 Like

Aaah, thank you so much!

Thanks for writing this script! I wanted to let you know of a usefulness not advertised: trying to guess meanings before they’re displayed. Especially for vocab, I really wanted to practice trying to guess/deduce meanings of new words, and was constantly being thwarted by meanings being displayed so prominently during lessons. So thank you!

1 Like

I’ve been using a notepad and an “always on top” app to keep the meanings hidden, but it’s annoying when I want to switch windows, then come back and forget to unminimize the notepad and I’ve seen the meaning. This is the perfect solution.

@madtapa right? It feels pretty awesome when you can guess what the word means. To me that simulates seeing it in a native environment, when you don’t exactly know the word but you can deduce the meaning.