Skip to content

Instantly share code, notes, and snippets.

@sevenc-nanashi
Created May 6, 2021 21:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sevenc-nanashi/64fb66d3a29b6a6ce020a5257f21db39 to your computer and use it in GitHub Desktop.
Save sevenc-nanashi/64fb66d3a29b6a6ce020a5257f21db39 to your computer and use it in GitHub Desktop.
Array.from(document.getElementsByClassName("ui_id_block")).forEach(e=>{
e.addEventListener("mouseenter",()=>{
Array.from(document.querySelectorAll("[data-serno='"+e.childNodes[1].innerHTML+"']")).forEach(i=>{
i.style.backgroundColor="#ff8808"
i.style.color="#fff"
})
})
e.addEventListener("mouseleave",()=>{
Array.from(document.querySelectorAll("[data-serno='"+e.childNodes[1].innerHTML+"']")).forEach(i=>{
i.style.backgroundColor="#e3e3e3"
i.style.color="#888"
})
})
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment