<template>
	<!-- 我的 -->
	<view class="mine">
		<view class="mine-top">
			<image class="header-img"
				src="https://c-ssl.dtstatic.com/uploads/blog/202201/23/20220123222213_2899a.thumb.1000_0.jpeg" alt="" />
			<view class="user-info">
				<view class="name">姓名：张三</view>
				<text class="user-id">ID:123455</text>
			</view>
			<view class="user-home">主页 <text class="home-right"></text> </view>
		</view>
		
		<MineMoney :isTeam="isTeam" />
		<MallOrderForm />
		<TeamFunction v-if="isTeam" />
		<PersonalFunction v-else />

		<kj-tabbar :value1=4></kj-tabbar>
	</view>
</template>

<script>
	import MineMoney from './component/mineMoney.vue';
	import MallOrderForm from './component/mallOrderForm.vue';
	import TeamFunction from './component/teamFunction.vue';
	import PersonalFunction from './component/personalFunction.vue';
	export default {
		components:{
			MineMoney,
			MallOrderForm,
			TeamFunction,
			PersonalFunction
		},
		data() {
			return {
				isTeam:true,
			};
		},
		created() {
			uni.setNavigationBarColor({
				frontColor: '#ffffff',
				backgroundColor: '#f4f4f4'
			})
		}
	}
</script>

<style lang="scss">
	.mine {
		padding-left: 10px;
		background-color: #f4f4f4;
		padding-right: 10px;
	}

	.mine-top {
		display: flex;
		align-items: center;
		position: relative;

		.header-img {
			height: 54px;
			width: 54px;
			border-radius: 50%;
			margin-right: 10px;
		}
		.user-info{
			.name{
				margin-bottom: 4px;
				color: #222;
				font-size: 18px;
				font-weight: 600;
			}
			.user-id{
				font-size: 12px;
				color: #333;
			}
		}
		.user-home {
			position: absolute;
			right: 0;
			width: 72px;
			height: 28px;
			background-color: #eee;
			text-align: center;
			font-size: 13px;
			font-size: #333;
			line-height: 28px;
			border-radius: 14px 0 0 14px;
			.home-right{
				display: inline-block;
				width: 10px;
				height: 10px;
				background-image: url('../../static/mine/right.png');
				background-size: 100% 100%;
				background-repeat: no-repeat;
				margin-right: 4px;
			}
		}
	}
</style>