You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not sure if this is still being maintained but toggle commit comments no longer works.
The html structure has changed, the the expanded section is dynamically added from an embeded react thingy: <script type="application/json" data-target="react-app.embeddedData">{"payload":{"commitGroups":[{"title":"Jun 29, 2024","commits":
I made a quick and dirty fix for myself if anyone wants it.
Only for the day expand on commits. But you can easily modify that to your needs.
I just find the buttons and call their click() method
Here's the mess:
(()=>{/* global $ $$ on */"use strict";// Commit history toggle// https://github.com/torvalds/linux/commits/masterfunctiontoggleButton(el,caller){constparentNode=el.closest(".list-view-items");if(parentNode){constcontainers=parentNode.querySelectorAll('[data-testid=commit-row-show-description-button]');[...containers].forEach(node=>{if((node!=caller)&&(node.matches('[data-testid=commit-row-show-description-button]'))){node.click();}});}}on($("body"),"click",event=>{consttarget=event.target;constmod=event.ctrlKey||event.metaKey||window.location.pathname.includes("/compare/");if(target&&event.getModifierState("Shift")){// give GitHub time to update the elementssetTimeout(()=>{// target is path inside svg inside buttonvarrealTarget=target;for(leti=0;i<5;i++){if(realTarget.nodeName!='BUTTON')realTarget=realTarget.parentElement;elsebreak;}if(realTarget.matches("[aria-pressed=false]")){//console.log("detail target")toggleButton(realTarget,target);}elseif(realTarget.matches("[aria-pressed=true]")){//console.log("detail closed")toggleButton(realTarget,target);}//console.log(realTarget)},100);}});})();
Not sure if this is still being maintained but toggle commit comments no longer works.
The html structure has changed, the the expanded section is dynamically added from an embeded react thingy:
<script type="application/json" data-target="react-app.embeddedData">{"payload":{"commitGroups":[{"title":"Jun 29, 2024","commits":I made a quick and dirty fix for myself if anyone wants it.
Only for the day expand on commits. But you can easily modify that to your needs.
I just find the buttons and call their click() method
Here's the mess: