Created
August 4, 2022 12:34
-
-
Save kidsil/eabfbd3341b1ee95912e9b9005f4ff7b to your computer and use it in GitHub Desktop.
PR Scripts - bookmarks for GitHub PRs
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
// Add these to your browser as bookmarks: | |
// Filter commentless files | |
javascript:document.querySelectorAll('#files%20>%20div%20>%20div').forEach((e)%20=>%20{%20if%20(e.querySelectorAll('[data-disable-with="Resolving%20conversation%E2%80%A6"]').length%20===%200)%20{%20e.style.display%20=%20'none';%20}%20%20}) | |
// Filter viewed files | |
javascript:document.querySelectorAll('#files%20input[name="viewed"][data-ga-click$="value:true"]').forEach(e=>{e.closest(".file").style.display="none"}); | |
// Fold All (a bit slow) | |
javascript:document.querySelectorAll('.file-info > button[aria-expanded="true"]:nth-child(1)').forEach((e) => { e.click() }) | |
// Expand All (a bit slow) | |
javascript:document.querySelectorAll('.file-info > :not(button[aria-expanded="true"]:nth-child(1))').forEach((e) => { e.click() }) | |
// Load all Diffs if hidden (super useful!) | |
javascript:document.querySelectorAll('#files%20.load-diff-button').forEach((e)%20=>%20e.click()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment