diff --git a/components/UsersView.vue b/components/UsersView.vue index d4c45ed..ae1965c 100644 --- a/components/UsersView.vue +++ b/components/UsersView.vue @@ -17,17 +17,16 @@ const props = defineProps({ // Computed Classes const containerClasses = computed(() => { - const baseClasses = 'w-full bg-gray-200 p-3 mt-auto rounded-3xl my-3'; - if (props.viewType === UserViewType.USERTURN) return `${baseClasses} h-full overflow-y-auto flex-grow-0`; - if (props.viewType === UserViewType.OPPONENTTURN) return `${baseClasses}`; - if (props.viewType === UserViewType.FRIENDS) return `${baseClasses}`; + const baseClasses = 'w-full bg-gray-200 px-3 pb-1 mt-auto rounded-3xl mb-3'; + if (props.viewType === UserViewType.USERTURN) return `${baseClasses} h-full overflow-y-hidden overflow-x-auto flex-grow-0`; + if (props.viewType === UserViewType.OPPONENTTURN || props.viewType === UserViewType.FRIENDS) return `${baseClasses} overflow-y-hidden`; return ''; }); const userBoxContainerClasses = computed(() => props.viewType === UserViewType.USERTURN - ? 'flex flex-col space-y-3' - : 'flex gap-3 overflow-x-auto' + ? 'flex flex-col space-y-1 md:space-y-3 h-full overflow-y-auto' + : 'flex gap-1 md:gap-3 mt-6 md:mt-9' ); @@ -42,11 +41,10 @@ function isUserInformation(user: any): user is UserInformation { // Map users conditionally depending on their type const mappedUsers = computed(() => { return props.users.map(user => { - console.log() if (isGetFriendsResponse(user)) { return { userId: user.friend_id, - userName: user.friend_username, + username: user.friend_username, userAvatar: user.friend_avatar, spotifyId: user.friend_spotify_id, status: user.status, @@ -57,7 +55,7 @@ const mappedUsers = computed(() => { } else if (isUserInformation(user)) { return { userId: user.user_id, - userName: user.username, + username: user.username, userAvatar: user.user_avatar, }; } @@ -67,27 +65,56 @@ const mappedUsers = computed(() => { \ No newline at end of file + + + diff --git a/components/home/Users/UserBox.vue b/components/home/Users/UserBox.vue index 638f738..e6e8a63 100644 --- a/components/home/Users/UserBox.vue +++ b/components/home/Users/UserBox.vue @@ -19,25 +19,25 @@