added spans to exclusion list

This commit is contained in:
Lauchmelder 2022-03-20 01:28:20 +01:00
parent 03ea59286b
commit 648387d256
No known key found for this signature in database
GPG key ID: C2403C69D78F011D

View file

@ -21,7 +21,8 @@ chrome.storage.local.get(["vocabulary", "kanji", "validUserLevel"], (data) => {
// Remove all tags (except for <rb>)
while(ruby.lastElementChild)
{
if(ruby.lastElementChild.tagName.toLowerCase() === "rb")
if(ruby.lastElementChild.tagName.toLowerCase() === "rb" ||
ruby.lastElementChild.tagName.toLowerCase() === "span")
{
ruby.innerHTML = ruby.lastElementChild.innerHTML
break