<template>
	<view class="login-status" @click.stop="getUserInfo()">
		<view class="head-icon">
			<image src="../../static/images/logo.png" mode="aspectFit"></image>
		</view>
		<view v-if="!userInfo" class="no-login">
			登录/注册
		</view>
	</view>
</template>

<script>
	export default {
		name: 'loginComponents',
		data() {
			return {
				userInfo: true
			};
		},
		methods: {
			getUserInfo() {
				if (this.userInfo) {
					uni.navigateTo({
						url: '/pages/content/mine'
					});
				} else {
					uni.navigateTo({
						url: '/pages/login/index'
					});
				}



			}
		}
	}
</script>

<style lang="scss" scoped>
	.login-status {
		display: flex;
		align-items: center;

		.no-login {
			padding-left: 3px;
			font-size: 28rpx;
			font-family: PingFang SC, PingFang SC-Bold;
			font-weight: 700;
			color: #1a1a1a;
		}



	}
</style>