Skip to content

Commit

Permalink
Update profile.html
Browse files Browse the repository at this point in the history
  • Loading branch information
lgor360 authored Jan 9, 2025
1 parent cd0e818 commit ff43baa
Showing 1 changed file with 25 additions and 2 deletions.
27 changes: 25 additions & 2 deletions profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,24 @@
.load-more button {
padding: 10px 20px;
}
.profile {
border: 1px solid #ccc;
border-radius: 0px;
padding: 15px;
margin: 20px auto;
max-width: 600px;
background-color: #454545;
}
.profile-header {
display: flex;
align-items: center;
margin-bottom: 10px;
}
.profile-header img {
height: 50px;
width: 50px;
margin-right: 10px;
}
</style>
</head>
<body>
Expand All @@ -146,6 +164,11 @@
<!-- <button class="login" onclick="login()">login</button> -->
</div>

<div id="profile">
<div id="profile-header">
</div>
</div>

<div id="posts">
<!-- сюда будут добавляться посты через js -->
</div>
Expand Down Expand Up @@ -272,9 +295,9 @@

// функция для рендеринга профиля
function renderUser(person_view) {
const profile_header = document.getElementById("profile-header");
const profile_header = document.querySelector("#profile #profile-header");
profile_header.innerHTML = `
${server}
<img src="${post.creator.avatar || 'https://lgor360.github.io/oldemmi/user.png'}" alt="avatar">
`;
}

Expand Down

0 comments on commit ff43baa

Please sign in to comment.