1 2 const ID_SECTION = "#section-banner-argomentiSuggeriti"; 3 const CLOSE_BUTTON = "#close-button-cardArgomentiSuggeriti"; 4 5 $(document).ready(function() { 6 $(CLOSE_BUTTON).on("click", function () { 7 $(this).parent().hide(); 8 $("#banner-argomentiSuggeriti").removeClass("col-md-8") 9 }) 10 }) 11 12 document.addEventListener("checkSession", () => { 13 14 let isShow = checkShowCondition(); 15 16 if (!isShow) { 17 $(ID_SECTION).hide(); 18 $(ID_SECTION).parent().hide(); 19 } 20 21 function checkShowCondition() { 22 let isLoggedIn = Pinia.getActivePinia()?.state?.value?.authStore?.user?.loggedIn ?? false; 23 let interessi = Pinia.getActivePinia()?.state?.value?.authStore?.user?.interessi ?? []; 24 if (isLoggedIn && interessi.length == 0) { 25 return true 26 } else if (isLoggedIn && interessi.length > 0) { 27 return false; 28 } else if (!isLoggedIn) { 29 return false; 30 } 31 } 32 33 34 }) 35 36
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.