Skip to content

Commit

Permalink
Merge pull request #1711 from NK-Works/remove-profile-bugs
Browse files Browse the repository at this point in the history
Removed Profile Bugs
  • Loading branch information
ANSHIKA-26 authored Nov 8, 2024
2 parents 7969265 + e76fe0f commit 229e493
Show file tree
Hide file tree
Showing 3 changed files with 429 additions and 191 deletions.
17 changes: 17 additions & 0 deletions SignIn_SignUp.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,20 @@ function closeForm(formType) {
document.getElementById("signupForm").style.display = "none";
}
}

function checkLogin() {
const isLoggedIn = localStorage.getItem('authToken'); // Example: Check for token
const profileLink = document.getElementById('profileLink');

// Show "My Profile" if the user is logged in
if (isLoggedIn) {
profileLink.style.display = 'block';
}
}

// Toggle menu display
function toggleProfileMenu() {
const profileMenu = document.getElementById('profileMenu');
profileMenu.style.display = profileMenu.style.display === 'block' ? 'none' : 'block';
}

Loading

1 comment on commit 229e493

@vercel
Copy link

@vercel vercel bot commented on 229e493 Nov 8, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.