Merge pull request #4 from Serraniel/feature/#1-requests-page-followed-requests-colored-star

#1 Change star color to primary color when a request is followed
This commit is contained in:
Daniel 2020-04-25 22:24:14 +02:00 committed by GitHub
commit df5240e17d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 0 deletions

View file

@ -0,0 +1,11 @@
const starIcon = "star";
executeAfterPreload(changeFollowedStarColor);
function changeFollowedStarColor() {
// find stars
let followedItems = Array.from(document.querySelectorAll("i")).filter(i => i.innerText == starIcon);
// change color
followedItems.forEach(item => item.style.color = aniBlue);
}

View file

@ -15,6 +15,15 @@
"utils/aniwatchCore.js"
],
"run_at": "document_start"
},
{
"matches": [
"*://aniwatch.me/requests"
],
"js": [
"enhancements/animeRequests.js"
],
"run_at": "document_end"
}
]
}