WaniKani Always Show Item Info

Always show WaniKani item info during reviews without scrolling, no matter if your answer was correct or not.

  1. // ==UserScript==
  2. // @name WaniKani Always Show Item Info
  3. // @namespace polv/wanikani
  4. // @version 1.0
  5. // @description Always show WaniKani item info during reviews without scrolling, no matter if your answer was correct or not.
  6. // @author polv
  7. // @match *://www.wanikani.com/*/session*
  8. // @license MIT
  9. // @grant none
  10. // ==/UserScript==
  11.  
  12. (function () {
  13. 'use strict';
  14.  
  15. const onSubmit = () => {
  16. setTimeout(() => {
  17. const btn = document.getElementById('option-item-info');
  18. if (btn instanceof HTMLElement && !btn.classList.contains('active')) {
  19. btn.click();
  20. }
  21. }, 50);
  22. };
  23.  
  24. new MutationObserver(() => {
  25. const answerForm = document.querySelector('#answer-form fieldset');
  26. if (answerForm instanceof HTMLElement && answerForm.className) {
  27. onSubmit();
  28. }
  29. }).observe(document.body, {
  30. childList: true,
  31. subtree: true,
  32. attributes: true,
  33. });
  34. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址