Last active
December 4, 2019 14:36
-
-
Save JakeCoxon/88936dd0789c50439e6be13408be6948 to your computer and use it in GitHub Desktop.
Github PRs Highlight name
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let username = document.querySelector('meta[name="user-login"]').getAttribute('content'); | |
document.querySelectorAll('.js-issue-row').forEach(row => { | |
let userLink = row.querySelector('a[data-hovercard-url="/users/' + username + '/hovercard"]') | |
if (!userLink) return; | |
Object.assign(userLink.style, { | |
background: '#3940c3', | |
borderRadius: '5px', | |
padding: '4px', | |
}) | |
userLink.style.setProperty("color", "white", "important"); | |
row.parentElement.insertBefore(row, row.parentElement.firstChild); | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can use this extension to run it https://chrome.google.com/webstore/detail/user-javascript-and-css/nbhcbdghjpllgmfilhnhkllmkecfmpld that runs on the URL
github.com/*/*/pulls
or one of many other extensions that let you run JS on a page