bigly-chat/views/user.ejs

46 lines
1.8 KiB
Text
Raw Normal View History

2024-11-25 14:12:43 -05:00
<%- include('header.ejs') -%>
2024-11-25 14:12:43 -05:00
<form enctype='multipart/form-data' method='POST' action='/api/form/follow'>
2024-11-25 14:12:43 -05:00
<h1>User</h1>
2024-11-25 14:12:43 -05:00
<div class='form-message'></div>
<div class='user'>
2024-11-25 14:12:44 -05:00
<div class='pfp-wrapper'>
<img src='/pfp/<%= id %>.png' class='avatar'>
<div>
<p>
<b>@<%= id %></b>
</p>
<details>
<summary>
<%= following.length %> following
</summary>
<% for (let user of following) { %>
<a href='/client/user?id=<%= user.target %>'>
<%= user.target %>
</a>
<%} %>
</details>
<details>
<summary>
<%= followers.length %> followers
</summary>
<% for (let user of followers) { %>
<a href='/client/user?id=<%= user.username %>'>
<%= user.username %>
</a>
<%} %>
</details>
<input name='target' hidden value="<%= id %>">
<input type='submit' value="Follow">
</div>
</div>
2024-11-25 14:12:43 -05:00
</div>
2024-11-25 14:12:44 -05:00
<pre><%= user[0] ? user[0].bio : 'This user has not set a bio.' %></pre>
2024-11-25 14:12:43 -05:00
</form>
2024-11-25 14:12:43 -05:00
<div class='area'>
<h1>Uploaded Videos</h1>
<div class=' videos'>
<%- include('videos.ejs') -%>
</div>
</div>
2024-11-25 14:12:43 -05:00
<%- include('comments.ejs') -%>
2024-11-25 14:12:43 -05:00
<%- include('footer.ejs') -%>