Skip to content

Commit

Permalink
updated styling to userinfo page
Browse files Browse the repository at this point in the history
  • Loading branch information
Bhavesh committed Feb 10, 2023
1 parent 326dc8a commit 506293f
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 9 deletions.
6 changes: 3 additions & 3 deletions logout.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
$(document).ready(function () {
if ((localStorage.getItem("username") != null) &&(localStorage.getItem("pwd") != null) ){
let content = `<h1 id="userinfo-username">${localStorage.getItem("username")}</h1>
<h2 id="userinfo-userEmail">${localStorage.getItem("useremail")}</h2>
<h2 id="userinfo-userPoints">Total Points:${localStorage.getItem("points")}</h2>`;
let content = `<div id="user-details"><h1 id="userinfo-username">Username:${localStorage.getItem("username")}</h1>
<h2 id="userinfo-userEmail">Email:${localStorage.getItem("useremail")}</h2>
<h2 id="userinfo-userPoints">Total Points:${localStorage.getItem("points")}</h2></div> <div id="logoutpos"><button id="logout" onclick="">LogOut</button><div>`;

document.getElementById("userinfo").innerHTML += content
}
Expand Down
54 changes: 50 additions & 4 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -731,10 +731,7 @@ footer .copyright {
#account-made .alert {
font-weight: bold;
}
#userinfo {
padding: 10%;
font-size: 2000%;
}

#signup{
background-color: plum;
border: none;
Expand All @@ -759,7 +756,56 @@ footer .copyright {
#signuppos {
padding-top: 10px;
}
#logout {
background-color: plum;
border: none;
color: black;
padding: 10px 32px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 15px;
font-weight: 700;
cursor: pointer;
transition: 0.3s ease;
border-radius: 4px;
}
#logout:hover {
box-shadow: 0 8px 16px 0 rgba(0,0,0,0.2), 0 6px 20px 0 rgba(0,0,0,0.19);
transform: translateY(-3px);
background-color: black;
color: white;
transition: 0.3s ease;
}

#userinfo {
padding: 10%;
font-size: 2000%;
padding-left: 30%;
display: flex;
}
#user-details {
padding-top: 8%;

}
#userinfo-username {
padding-left: 100%;
display: flex;
font-size: 20px;
}
#userinfo-userPoints {
padding-left: 100%;
display: flex;
font-size: 20px;
}
#userinfo-userEmail {
padding-left: 100%;
display: flex;
font-size: 20px;
}
#logoutpos {
padding-right: 100px;
}

/* Media */
@media (max-width: 799px) {
Expand Down
4 changes: 2 additions & 2 deletions userinfo.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@

<div id="userinfo">
<i><i class="fa fa-user-secret user user-p"></i></i>


</div>
<button id="logout" onclick="">LogOut</button>



</body>

0 comments on commit 506293f

Please sign in to comment.