mirror of
https://github.com/hay-kot/mealie.git
synced 2025-08-22 14:33:33 -07:00
fix admin sidebar
This commit is contained in:
parent
a7d48f95cf
commit
ccc2eda305
3 changed files with 17 additions and 6 deletions
|
@ -22,8 +22,15 @@
|
||||||
>
|
>
|
||||||
<template v-slot:prepend>
|
<template v-slot:prepend>
|
||||||
<v-list-item two-line>
|
<v-list-item two-line>
|
||||||
<v-list-item-avatar>
|
<v-list-item-avatar color="accent" class="white--text">
|
||||||
<img src="https://randomuser.me/api/portraits/women/81.jpg" />
|
<img
|
||||||
|
:src="userProfileImage"
|
||||||
|
v-if="!hideImage"
|
||||||
|
@error="hideImage = true"
|
||||||
|
/>
|
||||||
|
<div v-else>
|
||||||
|
{{ initials }}
|
||||||
|
</div>
|
||||||
</v-list-item-avatar>
|
</v-list-item-avatar>
|
||||||
|
|
||||||
<v-list-item-content>
|
<v-list-item-content>
|
||||||
|
@ -70,9 +77,14 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import { validators } from "@/mixins/validators";
|
||||||
|
import { initials } from "@/mixins/initials";
|
||||||
|
import { user } from "@/mixins/user";
|
||||||
export default {
|
export default {
|
||||||
|
mixins: [validators, initials, user],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
hideImage: false,
|
||||||
showSidebar: false,
|
showSidebar: false,
|
||||||
mobile: false,
|
mobile: false,
|
||||||
links: [],
|
links: [],
|
||||||
|
@ -123,8 +135,8 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
user() {
|
userProfileImage() {
|
||||||
return this.$store.getters.getUserData;
|
return `api/users/${this.user.id}/image`;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
<v-img :src="getImage(image)"> </v-img>
|
<v-img :src="getImage(image)"> </v-img>
|
||||||
</v-list-item-avatar>
|
</v-list-item-avatar>
|
||||||
<v-list-item-content>
|
<v-list-item-content>
|
||||||
<v-list-item-title >
|
<v-list-item-title>
|
||||||
{{ name }}
|
{{ name }}
|
||||||
</v-list-item-title>
|
</v-list-item-title>
|
||||||
<v-rating length="5" size="16" dense :value="rating"></v-rating>
|
<v-rating length="5" size="16" dense :value="rating"></v-rating>
|
||||||
|
|
|
@ -24,7 +24,6 @@
|
||||||
<v-avatar
|
<v-avatar
|
||||||
color="accent"
|
color="accent"
|
||||||
size="120"
|
size="120"
|
||||||
v-if="!loading"
|
|
||||||
class="white--text headline mr-2"
|
class="white--text headline mr-2"
|
||||||
>
|
>
|
||||||
<img
|
<img
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue