function setupAutodocPy(){const e=document.querySelectorAll(".py .sig-param");Array(...e).forEach(e=>{let t=document.createElement("br");e.parentNode.insertBefore(t,e)});const t=document.querySelectorAll(".py em.sig-param:last-of-type");Array(...t).forEach(e=>{let t=document.createElement("br");e.after(t)})}function setupAutodocCpp(){const e=document.querySelectorAll(".c dt.sig-object, .cpp dt.sig-object");Array(...e).forEach(e=>{e.classList.add("highlight")});const t=document.querySelectorAll("dt.sig-object.c,dt.sig-object.cpp");Array(...t).forEach(e=>{e.classList.add("highlight");var t=e.querySelectorAll(".sig-paren"),n=Array(...e.childNodes).filter(e=>e.textContent==", ");if(t.length!=2)return;if(n.forEach(e=>{if(e.compareDocumentPosition(t[0])==Node.DOCUMENT_POSITION_PRECEDING&&e.compareDocumentPosition(t[1])==Node.DOCUMENT_POSITION_FOLLOWING){let t=document.createElement("br"),n=document.createElement("span");n.className="sig-indent",e.after(t),t.after(n)}}),t[0].nextSibling!=t[1]){let e=document.createElement("br"),n=document.createElement("span");n.className="sig-indent",t[0].after(e),e.after(n);let s=document.createElement("br");t[1].parentNode.insertBefore(s,t[1])}})}function setupSidebarToggle(){const e=document.querySelector(".sphinxsidebar");document.querySelector("#toggle_sidebar a").onclick=t=>{console.log("Toggling sidebar"),t.preventDefault(),e.style.display=window.getComputedStyle(e,null).display=="none"?"block":"none"}}function setupRightSidebarToggle(){const e=document.querySelector("#right_sidebar"),t=document.querySelectorAll("a.toggle_right_sidebar");Array(...t).forEach(t=>{t.onclick=t=>{console.log("Toggling right sidebar"),t.preventDefault(),e.style.display=window.getComputedStyle(e,null).display=="none"?"block":"none"}})}document.addEventListener("DOMContentLoaded",function(){console.log("custom theme loaded"),setupAutodocPy(),setupAutodocCpp(),setupSidebarToggle(),setupRightSidebarToggle()})