Wanikani Phonetic-Semantic Composition 1.0.5 [No longer supported]

Ok, I figured it out. Sorry for making you try to reproduce it, it’s actually the fault of the “Transform on’yomi readings into katakana” userscript
When I disable it your script works fine.