minor fixes to Friendpage
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
|
||||
// this might be the part where we get rid of localstorage when the app is quit?
|
||||
// onDestroy()
|
||||
// maybe done with cookie
|
||||
|
||||
</script>
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
import Tabs from "../../pieces/Tabs.svelte";
|
||||
|
||||
let errors = {friendRequest: '',};
|
||||
let set = {friendUsername: ''}
|
||||
|
||||
let user;
|
||||
let allUsers;
|
||||
@@ -45,7 +46,6 @@
|
||||
console.log({...allUsers})
|
||||
};
|
||||
|
||||
|
||||
const fetchMyFriends = async() => {
|
||||
myFriends = await fetch('http://transcendance:8080/api/v2/network/myfriends')
|
||||
.then( x => x.json() );
|
||||
@@ -155,6 +155,7 @@
|
||||
{#each myFriends as aUser}
|
||||
<div class="sidebar-item" on:click={() => viewAUser(aUser.username)}>{aUser.username}</div>
|
||||
<div class="status sidebar-item">{aUser.status}</div>
|
||||
<br>
|
||||
{/each}
|
||||
{:else if activeTabItem === 'Friend Requests' && requestsRecieved !== undefined}
|
||||
<h3>{activeTabItem}</h3>
|
||||
@@ -162,6 +163,7 @@
|
||||
<div class="sidebar-item" on:click={() => viewAUser(aUser.senderUsername)}>{aUser.senderUsername}</div>
|
||||
<div class="status sidebar-item">{aUser.status}</div>
|
||||
<!-- yea not sure if status makes sense here, it's not the user's status it's the friendrequest status -->
|
||||
<br>
|
||||
{/each}
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user