Files
ASF_tools_legacy/asf-cloud-server/monitor/openproject_files/910ptS3pcIDQ7a5acMaHuQliuN0.br.js.download
2025-12-26 15:17:21 +01:00

1 line
1.9 KiB
Plaintext

(function(){function a(){r&&(r=!1,w(),SydFSCHelper.deleteNotebookFlagInURL())}function p(){if(!Lib.CssClass.contains(n,"disabled")&&!r){r=!0;var t=_ge(o),i=_ge(s),u=_ge(h);b(t,i);e||v(t,i,u)}}function w(){n&&Lib.CssClass.remove(n,i);t&&Lib.CssClass.remove(t,f);n.firstChild.ariaCurrent="false"}function b(r,u){n&&Lib.CssClass.add(n,i);t&&Lib.CssClass.add(t,f);r&&Lib.CssClass.remove(r,i);u&&Lib.CssClass.remove(u,i);u.firstChild.ariaCurrent="false";n.firstChild.ariaCurrent="page"}function v(i,r,u){var l,s,h,c;if(!e&&n){var a=n.offsetWidth,v=getComputedStyle(n),o=parseInt(v.marginLeft),f;i&&i.offsetWidth&&(l=getComputedStyle(i),o+=i.offsetWidth+parseInt(l.marginRight),f=i);r&&r.offsetWidth&&(s=getComputedStyle(r),o+=(!f?0:parseInt(s.marginLeft))+r.offsetWidth+parseInt(s.marginRight),f||(f=r));u&&u.offsetWidth&&(h=getComputedStyle(u),o+=parseInt(h.marginLeft)+u.offsetWidth+parseInt(h.marginRight));c=sj_ce("style");c.textContent="\n .b_sydConvMode.b_notebookMode .b_scopebar #".concat(f.id,"::after {\n width: ").concat(a,"px;\n transform: translateX(").concat(document.dir==="rtl"?"-":"").concat(o,"px);\n }\n ");t.appendChild(c);e=!0}}function k(n,t){if(n&&t){var i=n.offsetWidth,r=t.offsetWidth;t.style.transform="translate(".concat(document.dir==="rtl"?"":"-").concat((r-i)/2,"px, 6px)")}}var u,o="b-scopeListItem-web",s="b-scopeListItem-conv",h="b_bceBcbToggle",i="b_active",f="b_notebookMode",c=_ge(s),y=_ge(h),n=_ge("b-scopeListItem-notebook"),t=(u=window.document)===null||u===void 0?void 0:u.body,r=!1,e=!1,l;t&&c&&n&&(Lib.CssClass.contains(t,f)&&(l=_ge(o),v(l,c,y)),sj_be(n,"click",function(){Lib.CssClass.contains(n,"disabled")||sj_evt.fire("showNotebook")}),sj_evt.bind("switchToNotebook",p,!0),sj_evt.bind("switchToConversation",a,!0),sj_evt.bind("switchToWeb",a,!0),Lib.CssClass.contains(n,"disabled")&&sj_evt.bind("showSydFSC",function(){var t=n.querySelector(".notebook-tip");k(n,t)},!0))})()