feat: 添加头像信息封装

This commit is contained in:
橙子
2023-03-13 23:24:10 +08:00
parent 8e56667760
commit 9600e450af
7 changed files with 87 additions and 10 deletions

View File

@@ -21,11 +21,18 @@
</div>
</template>
<script setup>
import useUserStore from '@/stores/user'
import { onMounted } from 'vue';
const props = defineProps(['size', 'src','showWatching','time','id'])
//userInfo
//{icon,name,role,id},根据判断userInfo是否等于未定义来觉得是当前登录用户信息还是其他人信息
const props = defineProps(['size', 'src','showWatching','time','userInfo'])
const userStore=useUserStore();
const userInfo=reactive({
icon:"",
name:"",
role:"",
id:""
});
</script>
<style scoped>
.mt_1