-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathYFRe970EMtFzujI9pBYZBGpdHEo.br.js
1 lines (1 loc) · 2.58 KB
/
YFRe970EMtFzujI9pBYZBGpdHEo.br.js
1
(function(){function p(r){var o=SydFSCHelper.isSydFSCEligible,e;SydFSCHelper.sydPayWallTrace("handleClickForWebScope",o);e=u!=1?_ge(f):n;o?Lib.CssClass.contains(e,t)&&(Lib.CssClass.remove(e,t),Lib.CssClass.add(i,t),SydFSCHelper.LogIntEvent("ConversationViewExit","Scope",{source:"ClickTab",target:_G[SydFSCHelper.SYD_PREV_MODE]}),sj_evt.fire("hideSydFSC")):Lib.CssClass.contains(e,t)&&(Lib.CssClass.remove(e,t),Lib.CssClass.add(i,t));sj_pd(r);sj_sp(r)}function e(r){var f,u;y&&sj_cook&&(f=sj_cook.get("SRCHHPGUSR","ADLT"),f=="STRICT"&&(_w.location.href="/chat",sj_pd(r),sj_sp(r)));u=SydFSCHelper.isSydFSCEligible;SydFSCHelper.sydPayWallTrace("handleClickForWebScope",u);u?Lib.CssClass.contains(n,t)||(Lib.CssClass.remove(i,t),Lib.CssClass.add(n,t),SydFSCHelper.triggerSydFSCQueryWithContext(),SydFSCHelper.LogIntEvent("ConversationViewEnter","Scope",{source:"ClickTab"})):(SydFSCHelper.LogIntEvent("ConvesationPayWallEnter","Scope",{source:"ClickTab",tab:"conv"}),sj_evt.fire("showSydFSC"));sj_pd(r);sj_sp(r)}function w(){var u=_d.querySelector("#b-scopeListItem-web a"),t=_d.querySelector("#b-scopeListItem-conv a"),f=_d.querySelectorAll(".b_scopebar >ul >li");if(u&&t&&i&&n){var e=f[1],o=e.querySelector(" a"),s=o.offsetLeft-i.offsetLeft,h=t.offsetWidth,r=sj_ce("style");r.textContent="\n .b_sydConvMode .b_scopebar #b-scopeListItem-web::after {\n width: ".concat(h,"px;\n transform: translateX(").concat(s,"px);\n }\n ");sj_b.appendChild(r)}}function c(){sj_ue(r?r:n,"click",e);n=_ge(f);r=n&&n.querySelector("a");sj_be(r?r:n,"click",e)}function l(){s||(s=!0,h=!1,v(!1))}function a(){h||(h=!0,s=!1,v(!0))}function v(n){var i,r,f;if(u!==1&&(i=_d.querySelectorAll(".b_scopebar >ul >li"),i&&i.length>2)){if(u===-1&&k(i),u===-1||u===1)return;r=i[1];f=i[u];Lib.CssClass.remove(f,t);n&&Lib.CssClass.remove(r,t);b(f,r)}}function b(n,t){d(n,t);var i=_d.querySelector("#b-scopeListItem-conv a");sj_be(i,"click",e)}function k(n){for(var t=0;t<n.length;t++)if(n[t].id===f){u=t;break}}function d(n,t){var i=n.innerHTML,r=n.id;n.innerHTML=t.innerHTML;n.id=t.id;t.innerHTML=i;t.id=r}var o,f="b-scopeListItem-conv",t="b_active",i=_ge("b-scopeListItem-web"),n=_ge(f),r=n&&n.querySelector("a"),y=SydFSCHelper.getConfigOrDefault((o=_w._sydConvConfig)===null||o===void 0?void 0:o.enableSydStrictRedirect,!1),u=-1,s=!1,h=!1;n&&i&&(w(),sj_be(i,"click",p),sj_be(r?r:n,"click",e),sj_evt.unbind("showSydFSC",l),sj_evt.bind("showSydFSC",l,1),sj_evt.unbind("hideSydFSC",a),sj_evt.bind("hideSydFSC",a,1),sj_evt.unbind("dynamicchatscoperelocate",c),sj_evt.bind("dynamicchatscoperelocate",c,1))})()