Skip to content
Snippets Groups Projects
Commit d7b7ae89 authored by Håkon Eilertsen Røskaft's avatar Håkon Eilertsen Røskaft
Browse files

Merge branch 'home_picture_fix' into 'main'

Home picture fix

See merge request !152
parents 26cea543 d7de8b37
No related branches found
No related tags found
1 merge request!152Home picture fix
Pipeline #182289 canceled with stages
......@@ -49,7 +49,7 @@
<script>
import axios from "axios";
import { tokenHeader, parseCurrentUser } from "@/utils/token-utils";
import { getItemPictures, } from "@/utils/apiutil";
import { getItemPictures } from "@/utils/apiutil";
export default {
props: {
......@@ -61,7 +61,7 @@ export default {
data() {
return {
image: null,
}
};
},
computed: {
userID() {
......@@ -113,8 +113,8 @@ export default {
if (images.length > 0) {
this.image = images[0].picture;
} else {
this.image = "https://images.unsplash.com/photo-1453728013993-6d66e9c9123a?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxzZWFyY2h8Mnx8dmlld3xlbnwwfHwwfHw%3D&w=1000&q=80";
this.image =
"https://images.unsplash.com/photo-1453728013993-6d66e9c9123a?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxzZWFyY2h8Mnx8dmlld3xlbnwwfHwwfHw%3D&w=1000&q=80";
}
},
},
......
<template>
<!-- A list conatining all the communities -->
<p v-if="!communities.length" class="flex place-content-center text-gray-400 mt-8">
<p
v-if="!communities.length"
class="flex place-content-center text-gray-400 mt-8"
>
Ingen grupper
</p>
<ul v-else>
......
......@@ -54,10 +54,7 @@
v-if="!community.picture"
class="h-10 w-10 flex flex-col justify-center items-center ml-2 mr-2"
>
<UserGroupIcon
alt="Bilde"
class="h-10 w-10 text-primary-dark"
/>
<UserGroupIcon alt="Bilde" class="h-10 w-10 text-primary-dark" />
</div>
<div
v-else
......@@ -66,7 +63,7 @@
<img
:src="community.picture"
alt="Bilde"
class="rounded-md"
class="rounded-md h-14 w-14 object-contain"
/>
</div>
<div class="flex-1 pl-1 overflow-hidden">
......
......@@ -40,13 +40,13 @@
:key="item"
>
<div class="w-full">
<ItemCard
id="ItemCardPage"
class="ItemCard w-full h-full"
:item="item"
/>
</div>
<TripleDotButton class="DotButton" @click="openDotMenu(item)"/>
<ItemCard
id="ItemCardPage"
class="ItemCard w-full h-full"
:item="item"
/>
</div>
<TripleDotButton class="DotButton" @click="openDotMenu(item)" />
<div
v-show="item.toggle"
......@@ -110,10 +110,13 @@
>
<div class="cardContainer" v-for="item in searchedItems" :key="item">
<div class="w-full">
<ItemCard id="ItemCardSearch" class="ItemCard w-full h-full" :item="item" />
<ItemCard
id="ItemCardSearch"
class="ItemCard w-full h-full"
:item="item"
/>
</div>
<TripleDotButton class="DotButton" @click="openDotMenu(item)"/>
<TripleDotButton class="DotButton" @click="openDotMenu(item)" />
<div
v-show="item.toggle"
......
......@@ -14,7 +14,7 @@ exports[`CommunityListItem component renders correctly 1`] = `
>
<img
alt="Bilde"
class="rounded-md"
class="rounded-md h-14 w-14 object-contain"
src="string"
/>
</div>
......
......@@ -24,7 +24,7 @@ exports[`CommunityList component renders correctly 1`] = `
>
<img
alt="Bilde"
class="rounded-md"
class="rounded-md h-14 w-14 object-contain"
src="string"
/>
</div>
......@@ -75,7 +75,7 @@ exports[`CommunityList component renders correctly 1`] = `
>
<img
alt="Bilde"
class="rounded-md"
class="rounded-md h-14 w-14 object-contain"
src="string"
/>
</div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment