[Userscript] Wanikani Item Inspector

Hi! I’m using WaniKani along with Chase Colburn’s Japanese Kanji App. Since Wk is periodically moving Kanji around between levels, occasionally I’d like to export the Kanji for re-import into the app. After searching the forums, I’ve come across console scripts exporting various data sets, as well as mentions of WK Item Inspector being able to do this. The latter is very overwhelming for me, though, due to the many options in its settings.
Does anyone have a short guide how to set up Item Inspector so that it exports 60 lines of Kanji sorted by level?

1 Like

I am willing to provide the requested short guide but I wonder what 60 lines of Kanji means. Do you want to export all learned kanji with several kanji per line? Please clarify.

Edit: I went on Chase Colburn site and couldn’t find the expected import format. I need this to determine the right setup for Item Inspector. Can you provide it for me?

I want to export all of WK’s Kanji, with each level on a separate line, followed by a linebreak. Chase’s app then uses this file to feed you the Kanji in the same sequence as WK does. The app tracks progress by itself, so no need to filter out what I’ve already learned.

The import format is pretty straightforward. All level 1 Kanji go onto line 1 without whitespace and separators, all level 2 kanji onto line 2 and so forth until line 60. Kind of like this:

工一二九七人入八力十三上下口大女山川
出夕玉刀土千子小丁了丸才中五六円天手文日月木水火犬王右四左本正田白目立々
今太引戸万元内分切午友少心方牛父毛止冬北半古台外市広母用矢生
平打皿他去氷礼休早糸耳貝赤足宝石世主代写号央申先名字年気百竹虫村男町花見車不仕
谷麦行毎羽図里斤同多考近音兄皮交会光回当米肉自色西何体作声弟形来社角言走学林空金雨青草
活夜首地両全向安州曲有次死羊血京国妹姉店明東歩画直知長前南室後思星海点科茶食亡私化
欠氏由札民辺付以失必未末校夏家弱時紙記通高強教理組船週雪魚鳥黄黒風
池支住助医君対局役投決究身者研馬森場朝番答絵買道間雲数楽話電所反
売事使具受和定実服泳物苦表部乗客屋度持界発相県美負送重談要勝仮予新返保試験
鉄酒転算語頭公始起速配院終習進落葉軽運開集飲業漢路農歌聞読鳴線横調親顔病最求頁
便争位別努命競良誰仲伝共好成老低初利労岸放昔波注育拾指洋神秒級追戦功特働令意味
期倍短彼待勉庭息旅根流消員島祭章第都動商悪族深球童陽階寒暑植歯温港湯登着野泉合僕
様輪問宿想感整暗橋緑練詩銀題館駅億器士料標殺然熱課賞選鏡養像情謝映疑皆俺
願例卒協参周囲固季完希念折望材束松残的約芸基性格能骨妥雰頑苺狼
紀英軍飯仏晩猫払技術毒泣浅司建昨晴列坂式変夫匹寺岩帰春昼秋計区信単福勇法築丈
園曜書遠門係取品守幸急真箱荷面典府治浴笑辞関弁政留証険危存専冒冗阪
悲喜原細薬鼻側兵堂塩席敗果栄梅無結因常識非干是渉虚官察底愛署警恋覚説幻詳劇
訓弓告種達類報等汽借焼座忘洗胸脳僧禅可許枚静句禁喫煙喉叩飴苛
加節減順容布易財若詞昆閥歴舌冊宇宙忙履団暴混乱徒得改続連善絡比笛史
困災機率飛害余難妨被裕震尻尾械確嫌個圧在夢産倒臭厚妻議犯罪防穴論経
祈敵済委挙判制務査総設資権件派岡素断評批任検審条責省増税解際認企義羨
罰誕脱過坊寝宮各案置費価勢営示統領策藤副観値吸域姿応提援状態賀諦袖
収停革職鬼規護割裁崎演律師看準則備導幹張優宅沢贅施現乳呼城俳秀棚痒
担額製違輸燃祝届狭肩腕腰触載層型庁視差管象量境環武質述供展販株
限与含影況渡響票景抜訴訟逮補候構模捕鮮効属慣豊満肥巻捜絞輩隠掛替居絶捉莫
造授印創復往較筆鉛貯故障従我激刺励討郵針徴怪獣突菓河振汗豚再接独占
招段胃腹痛退屈悩暇織貸迷惑誘就訪怒昇眠睡症締迫靴濃端極途健康郎給
逆巨庫児冷凍幼稚処博清潔録隊修券婦奇妙麗微益移程精並憲衆傘浜撃攻綺沼
監杯乾催促欧江請雄韓壊診閣僚積督臣略航寄板街宗緊娘宴怖恐添猛烈索詰勧
魅渇系婚遊旗照快版貧乏適預延翌覧懐押更枕浮漏符購越飾騒背撮盗匂濡柵
離融編華既普豪鑑除尋幾廊掃泥棒驚嘆倉孫巣帯径救散粉脈菜貨陸似均墓富徳探偵
久序迎志恩採桜永液眼祖績興衛複雑賛酸銭飼傷党卵厳捨込密汚欲暖机秘訳染
簡閉誌窓否筋垂宣尊忠拡操敬暮灰熟異皇盛砂漠糖納肺著蒸蔵装裏諸賃噂股屁
誤臓貴降丼吐奴隷芋縮純縦粋聖磁紅射幕拝薦推揮沿源勤歓承損枝爪豆刻腐痩咳
遅彫測破舎講滞紹介己厄亀互剣寿恥杉汁噌炎為熊獄酔酢鍋湖銅油醤喋戚
旧姓貿将盟遺伸債及奈幅廃甘換摘核沖縄津献療継維舞伎踏般頼依鹿諾牙超鮭
跳昭漁償刑募執塁崩患戻抗抵旬湾爆弾聴跡遣闘陣香兆臨削契恵抱掲狙葬串眉
需齢宜繰避妊娠致刊奏伴併傾却奥慮懸房扱抑択描盤称緒緩託賄賂贈逃還膝噛璧
邦鈴阜岐隆雇控壁棋渋片群仙充免圏埋埼奪御慎拒枠甲斐祉稲譲謙躍銃項鋼囚宛
顧駐駆柱唱孝俊兼剤吹堀巡戒排携敏鋭敷殿犠獲茂繁頻殖薄衝誉褒透隣雅嬉妖麺拉
遜伺徹瀬撤措拠儀樹棄虎蛍蜂酎蜜墟艦潜拳炭畑包衣仁鉱至誠郷侵偽嘘凄喧嘩
克到双哲喪堅床括弧挑掘揚握揺斎暫析枢軸柄泊滑潟焦範紛糾綱網肝芝荒袋餅
珍裂襲貢趣距籍露牧刷朗潮即垣威封筒慰懇懲摩擦撲斉旨柔沈泰滅滋炉琴
寸竜縁翼吉刃忍桃辛謎侍叱娯斗朱丘梨叫釣髪嵐笠涙缶姫粒砲雷芽塔挨拶
岳澄矛肌舟鐘凶塊狩頃魂脚也井呪嬢暦曇眺裸賭疲塾卓磨菌陰霊湿硬稼嫁溝滝狂翔
墨鳩穏鈍魔寮盆棟吾斬寧椅歳涼猿瞳鍵零碁租幽泡癖鍛錬穂帝瞬菊誇庄阻黙俵綿架孔
砕粘粧欺詐霧柳伊佐尺哀唇塀墜如婆崖帽幣恨憎憩扇扉挿掌滴炊爽畳瞭箸胴芯虹巾煎
帳蚊蛇貼辱鉢闇隙霜飢餓畜迅騎蓄尽彩憶溶耐踊賢輝脅麻灯咲培悔脇遂班塗斜殴盾穫
駒紫抽誓悟拓拘礎鶴刈剛唯壇尼概浸淡煮覆謀陶隔征陛俗桑潤珠衰奨劣勘妃慌蹴
峰巧邪駄唐廷鬱鰐蟹簿彰漫訂諮銘堰堤漂翻軌后奮亭仰伯偶淀墳壮把搬晶洞涯疫
又偉頂召挟枯沸濯燥瓶耕肯脂膚軒軟郊隅隻邸郡釈肪喚媛貞玄苗渦慈襟蓮亮聡浦塚
陥貫覇呂茨擁孤賠鎖噴祥牲秩唆膨芳恒倫陳須偏遇糧殊慢没怠遭惰猟乃綾颯隼輔
寛胞浄随稿丹壌舗騰緯艇披錦准剰繊諭惨虐据徐搭蒙鯉戴緋曙胡瓜帥啓葵駿諒莉
鯨荘栽拐冠勲酬紋卸欄逸尚顕粛愚庶践呈疎疾謡鎌酷叙且痴呆哺傲茎阿悠杏茜栞
伏鎮奉憂朴栃惜佳悼該赴髄傍累癒郭尿賓虜憾弥粗循凝脊昌旦愉抹栓之龍遼瑛那勿
拍猶宰寂縫呉凡恭錯穀陵弊舶窮悦縛轄弦窒洪摂飽紳庸靖嘉搾蝶碑尉凛匠遥智柴
賊鼓旋腸槽伐漬坪紺羅峡俸醸弔乙遍衡閲喝敢膜盲胎酵堕遮烏凸凹楓哉蒼萌
瑠硫赦窃慨扶戯濁奔肖朽殻享藩媒鶏嘱迭椎絹陪剖譜淑帆憤酌暁傑錠凌瑞菅璃
忌遷拙峠篤叔雌堪吟甚崇漆岬紡礁屯姻擬睦閑曹詠卑侮鋳蔑胆浪禍酪憧慶亜汰梓沙
款漣逝匿寡痢坑藍畔唄拷渓廉謹湧醜升殉煩劾桟婿慕罷矯某泌漸藻妄蛮倹狐冥

1 Like

This format is not supported by Item Inspector. It cannot be added without writing a new export functionality from scratch. It should not be difficult to do so but I am not willing to do this because there is already too much complexity in the current export code. Sorry about that.

Hi! I recently was trying to do something similar and figured out a workflow that might work for you. You can go to wkstats to get a list of kanji by level, copy-paste that list into a text editor, and then do some text manipulation (e.g. find-and-replace, or regex if you’re familiar) to remove commas and extraneous lines.

The list as of today

一七三上下九二人入八力十口大女山川工
々丁中丸了五六円出刀千右四土夕天子小左手才文日月木本正水火犬玉王田白目立
万今元内冬分切北午半友古台外太少市広引心戸方止母毛父牛生用矢
不世主仕他代休先写去号名央字宝平年打早村気氷申男町百皿石礼竹糸耳花虫見貝赤足車
交会体何作兄光同回図声多学弟当形斤来林毎皮社空米羽考肉自色草行西角言谷走近里金雨青音麦
両亡京全前化南向国地夜妹姉安室州店後思明星曲有東次歩死活海点画直知私科羊茶血長食首
付以夏失家弱強必教時未末札校欠氏民理由紙組船記辺通週雪風高魚鳥黄黒
住助医反君場対局役所投支数朝森楽池決番研究答絵者話買身道間雲電馬
乗予事仮使保具勝受和売定実客屋度持新服泳物界発相県美苦表要試談負返送部重験
公始最業横歌求漢病算終線習聞落葉親語読調起路転軽農速進運配酒鉄開院集頁頭顔飲鳴
争令仲伝位低便働共初別利功努労味命好岸意成戦拾指放昔波注洋特神秒競級老育良誰追
倍僕勉動合員商寒島庭彼待息悪旅族暑期根植歯泉流消深温港湯球登着短祭章童第都野陽階
俺像億問器士宿情想感整料映暗様標橋殺然熱疑皆緑練缶詩課謝賞輪選銀鏡題養館駅
例卒協参周囲固基妥季完希念性折望材束松格残狼的約能芸苺雰頑願骨
丈仏信列勇匹区単司坂変夫寺岩帰建式払技春昨昼晩晴毒法泣浅猫福秋築紀英術計軍飯
係典冒冗危取品園存守専幸府弁急政曜書治浴留真笑箱荷証辞遠門関阪険面
側兵劇原喜因堂塩官察席常干幻底恋悲愛敗是果栄梅渉無細結署薬虚覚詳説識警非鼻
借僧句叩可告喉喫報座弓忘枚汽洗焼煙禁禅種等繋胸脳苛訓許達静類飴
乱冊加史善団宇宙容履布徒得忙改昆易暴歴比混減笛節絡続舌若詞財連閥順
余個倒厚困圧在夢妨妻嫌害尻尾械機災犯率産確穴経罪臭被裕論議防難震飛
件任企判制務増委審岡批挙敵断条査検権派済省祈税素総羨義解設評認責資際
価値副勢各吸営坊域姿宮寝応態提援案状示策統置罰脱藤袖観誕諦費賀過領
乳俳停備優則割収呼城宅導崎師幹張律施棚沢準演現痒看秀職裁規護贅革鬼
供型境届展層差庁担株武燃狭環祝管肩腕腰製視触象販質載輸述違量額
与候効含居属巻影慣抜捉捕捜掛景替構模況渡満票絞絶肥莫補訟訴豊輩逮限隠響鮮
再刺創励占印往従復徴怪我振授接故汗河激独獣突筆菓討豚貯較造郵針鉛障
健就屈康怒悩惑招昇暇極段濃症痛眠睡端給締織胃腹訪誘貸迫迷退途郎靴
並修傘児冷凍処券博奇妙婦巨幼庫微憲撃攻沼浜清潔益移程稚精綺衆逆録隊麗
乾促催僚勧壊娘宗宴寄怖恐杯板欧江添烈猛略監督積索緊臣航街診詰請閣雄韓
乏匂婚延快懐押撮旗更枕柵浮渇漏濡照版盗符系翌背覧貧購越遊適預飾騒魅
似倉偵嘆均墓孫富尋巣帯幾廊径徳掃探救散既普棒泥粉編脈菜華融豪貨鑑除陸離驚
久傷党卵厳密序志恩捨採暖机染桜欲永汚液眼祖秘績興衛複訳賛込迎酸銭雑飼
否噂垂宣尊屁忠拡操敬暮漠灰熟異皇盛砂窓筋簡糖納股肺著蒸蔵装裏誌諸賃閉
丼刻勤吐咳奴射幕承拝推揮損枝歓沿源爪痩磁粋紅純縦縮聖腐臓芋薦誤豆貴降隷
亀互介剣厄喋噌寿己彫恥戚杉汁油測湖滞炎為熊獄破紹舎講遅酔酢醤銅鍋
伎伸依債及奈姓将幅廃換摘旧核沖津牙献甘療盟継維縄舞般諾貿超踏遺頼鮭鹿
串償兆刑削募執塁契崩弾恵患戻抗抱抵掲旬昭湾漁爆狙眉聴臨葬跡跳遣闘陣香
伴併傾刊却噛奏奥妊娠宜慮懸房扱抑択描璧盤称緒緩繰膝致託賂賄贈逃避還需齢
仙充免囚圏埋埼壁奪宛岐御慎拒控斐枠棋渋片甲祉稲群謙譲躍邦鈴銃鋼阜隆雇項
俊兼剤吹唱堀妖嬉孝巡戒拉排携敏敷柱殖殿犠獲繁茂薄衝褒誉透鋭隣雅頻顧駆駐麺
仁伺侵偽儀凄包喧嘘嘩墟徹拠拳措撤棄樹潜瀬炭畑至艦虎蛍蜂蜜衣誠遜郷酎鉱
克到双哲喪堅床弧括挑掘揚握揺斎暫析枢柄泊滑潟焦範糾紛綱網肝芝荒袋軸餅
刷即垣威封慰懇懲摩撲擦斉旨朗柔沈泰滅滋潮炉牧珍琴筒籍裂襲貢趣距露
丘侍刃叫叱吉塔姫娯寸嵐忍拶挨斗朱桃梨涙砲竜笠粒縁翼芽謎辛釣雷髪
也井凶卓呪塊塾嫁嬢岳暦曇湿溝滝澄狂狩疲眺矛硬磨稼翔肌脚舟菌裸賭鐘陰霊頃魂
俵吾墨孔寧寮帝幽庄斬架棟椅歳泡涼猿癖盆瞬瞳碁租穂穏綿菊誇鈍錬鍛鍵阻零魔鳩黙
伊佐哀唇塀墜如婆尺崖巾帽幣恨憎憩扇扉挿掌柳欺滴炊煎爽畳瞭砕箸粘粧胴芯虹詐霧
咲培塗尽帳彩悔憶斜殴溶灯班畜盾穫耐脅脇蓄蚊蛇貼賢踊輝辱迅遂鉢闇隙霜飢餓騎麻
俗刈剛劣勘唯壇奨妃尼征悟慌抽拓拘桑概浸淡潤煮珠礎紫衰覆誓謀蹴陛陶隔駒鶴
亭仰伯偶后唐堤堰墳壮奮峰巧廷彰把搬晶洞涯淀漂漫疫簿翻蟹訂諮軌邪銘駄鬱鰐
亮偉又召喚塚媛慈挟枯沸浦渦濯燥玄瓶耕聡肪肯脂膚苗蓮襟貞軒軟邸郊郡釈隅隻頂
乃倫偏呂唆噴孤怠恒惰慢擁殊没牲猟祥秩糧綾膨芳茨覇貫賠輔遇遭鎖陥陳隼須颯
丹准剰啓壌寛帥徐惨戴披据搭曙浄瓜稿緋緯繊胞胡舗艇莉葵蒙虐諒諭錦随駿騰鯉
且傲冠勲卸叙呆呈哺尚庶悠愚拐杏栞栽欄疎疾痴粛紋茎茜荘謡践逸酬酷鎌阿顕鯨
之伏佳傍凝勿奉尿弥循悼惜愉憂憾抹旦昌朴栃栓瑛癒粗累脊虜該賓赴遼那郭鎮髄龍
凛凡匠呉嘉宰寂尉庸弊弦恭悦拍搾摂智柴洪猶碑穀窒窮紳縛縫舶蝶轄遥錯陵靖飽
乙伐俸凸凹哉喝坪堕峡弔敢旋楓槽漬烏盲紺羅胎腸膜萌蒼衡賊遍遮酵醸閲鼓
享傑凌剖嘱奔媒帆慨憤戯扶暁朽椎殻淑濁瑞瑠璃硫窃絹肖菅藩譜赦迭酌錠陪鶏
亜侮卑叔吟堪姻屯岬峠崇忌慶憧拙擬曹梓汰沙浪漆甚睦礁禍篤紡胆蔑詠遷酪鋳閑雌
倹冥劾匿升唄坑妄婿寡廉慕拷某桟款殉泌渓湧漣漸煩狐畔痢矯罷藍藻蛮謹逝醜

2 Likes

No worries. I guess I’ll look at making WKOF script for this workflow. Thanks for checking.

1 Like

This extension seems to have disappeared for me as of yesterday (along with the Wanikani Heatmap). I’m using Chrome. It’s been working fine for a long time previously. Although the extension is enabled nothing happens when I open or refresh the browser; it’s just not there.

Can you check that value of your Position setting? I am able to reproduce your problem when I use Below Forecast. The other four settings don’t show the problem.

wkit

I will write a fix. In the mean time you can change this setting as a workaround

EDIT: Forget about this. I can’t reproduce your problem anymore…Do you have an error message in the console? Press F12 in a tab with WK dashboard open et go to the console tab.

Yes I can’t actually see the settings for the extension as it’s not loading at all.


There seem to be quite a few errors in there.

1 Like

There seems to be something wrong with the SVG for radicals files. I see nothing wrong on my end. It could be a cache corruption problem. Try clearing the Item Inspector cache. Do not clear your browser cache because that will wipe out your Heatmap data and there is no way to recover it. If you clear just the Item Inspector cache Item Inspector will reload a clean version of the data.

To clear the Item Inspector cache click on the button for this purpose in the settings.

wkitcache

I found the problem. Clearing the cache won’t work… I will write a fix.

2 Likes

Oof, I have some major local edits to the script I’ve been working on and I am not looking forward to needing to redo all of them after updating for this fix. So I guess I’ll take the time now to share what I’ve been working on and planned to eventually propose here.

One of my favorite aspects of Item Inspector is how it works with dark themes, and in particular when I first started using it, how it worked with Breeze Dark’s color changes for radicals/kanji/vocab. But with Breeze Dark kind of being unmaintained now, and me no longer wanting to constantly make local edits to it to get it to work, it was time to find something else. And conveniently that’s when Hubbit released Breeze Dark 2. It’s great! More customizable and written very well. But Item Inspector doesn’t support it.

So I sat down for a bit and took the time to edit the script to make it work. At first I did this by mirroring the rules that used .WkitBreezeColors and making my own .WkitBreeze2Colors rules + changing the function in the mutation observer to detect BD2’s different default font color and apply the class as needed. This worked really well, but eventually I realized something: with BD2 the background color and font color are customizable, so if a user makes any changes to those then Item Inspector will not detect the style as BD2 properly. And indeed, given this customizability, there isn’t any way to reliably detect the use of the style. So I concocted a plan to edit Item Inspector to work with this customizability instead of trying to detect a specific userstyle.

The mutation observer already detects whether you’re using a dark theme in general based on the brightness of the background color and if it does not detect Breeze Dark (original) or Azure Dark, then applies its own dark styling with vanilla item colors. Thus, what I have to do is make the default dark styling use the Wanikani CSS variables for item colors because BD2 overrides these to use the user defined colors. At least I thought it would be that simple, but in practice I’m running into little details that cause issues here and there, plus I will still need to make some changes to the mutation observer I think. But once it’s all working then Item Inspector should work not only with BD2 but any userstyle that overrides the Wanikani variables to set the colors. (And their corresponding *-dark variants. I was testing with Elementary Dark and turns out they forget to do this so the linear gradients get messed up being a mix of the custom color and the vanilla color).

Anyway, once I have this all sorted out I’d like to propose the changes for review. If there’s a specific way you’d like me to do that let me know (like a pull request on github, although there’s no github link in the main post of this thread).

2 Likes

I have added a Github link to the main post. Code contributions are welcomed.

Version 1.25.0 is out - Download it at the link in the top post.

Fixes the bug reported by @Ben-S and merges the pull request by @LupoMikti. This improves support for Dark Themes and miscellaneous fixes.

4 Likes

Is this how the enlarging popups are supposed to look like? This is from Breeze Dark 2. Plain old Breeze Dark is similar.

BreezeDark

I assume so since the only things I changed were background colors and text colors. Let me look at how it looks with no userstyle.

Edit: oh, there is no popup with the userstyle off. Strange. I’ll look more into it later.

1 Like

There is a setup option to enable this popup in the settings. In think the default for most tables is off.

BreezeDark

The look wo userstyle

BreezeDark

Thanks so much for your work to fix this. Can report it’s now fully functional for me again. :pray:

1 Like

Ah, then at least the style is working properly. Just changing the background color and text color that is. And the popup does indeed work for me with the style off. I must not have been hovering in the right spot for it before.

1 Like