<route lang="yaml">
style:
  navigationBarTitleText: 商家设置
  navigationBarBackgroundColor: '#fff'
</route>
<script lang="ts" setup>
import { useUserStore } from '../../../store'
import { storeToRefs } from 'pinia'

import { desinTopBg, rightArrowIcon } from '@designer-hub/assets/src/svgs'
import { log } from 'console'
const collapseValue = ref<string[]>(['item1'])
const userStore = useUserStore()
const { isLogined, userInfo } = storeToRefs(userStore)
const logout = () => {
  console.log('logout')
  userStore.userInfo = {}
  uni.reLaunch({ url: '/pages/login/index' })
}
</script>

<template>
  <view class="bg-white p-[16px] flex-grow flex flex-col">
    <div class="flex-1">
      <div class="flex justify-between items-center mb-[30px]">
        <div class="text-black/40 text-sm font-normal font-['PingFang SC'] leading-none">头像</div>
        <img class="w-7 h-7 rounded-full" src="https://via.placeholder.com/28x28" />
      </div>
      <div class="flex justify-between items-center mb-[30px]">
        <div class="text-black/40 text-sm font-normal font-['PingFang SC'] leading-none">名称</div>
        <div
          class="text-right text-[#999999] text-sm font-normal font-['PingFang SC'] leading-none"
        >
          GELATO
        </div>
      </div>
      <div class="flex justify-between items-center mb-[30px]">
        <div class="text-black/40 text-sm font-normal font-['PingFang SC'] leading-none">ID</div>
        <div
          class="text-right text-[#999999] text-sm font-normal font-['PingFang SC'] leading-none"
        >
          1254022
        </div>
      </div>
      <div class="flex justify-between items-center mb-[30px]">
        <div class="text-black/40 text-sm font-normal font-['PingFang SC'] leading-none">
          登录用户
        </div>
        <div
          class="text-right text-[#999999] text-sm font-normal font-['PingFang SC'] leading-none"
        >
          李晓东
        </div>
      </div>
      <div class="flex justify-between items-center mb-[30px]">
        <div class="text-black/40 text-sm font-normal font-['PingFang SC'] leading-none">
          登录用户手机
        </div>
        <div
          class="text-right text-[#999999] text-sm font-normal font-['PingFang SC'] leading-none"
        >
          132****1452
        </div>
      </div>
      <div class="flex justify-between items-center">
        <div class="text-black/40 text-sm font-normal font-['PingFang SC'] leading-none">
          修改密码
        </div>
        <wd-img width="15px" height="15px" :src="rightArrowIcon"></wd-img>
      </div>
    </div>
    <div class="w-full mt-[50px]">
      <wd-button block :round="false" @click="logout">
        <div
          class="text-center text-white text-base font-normal font-['PingFang SC'] leading-normal"
        >
          退出登录
        </div>
      </wd-button>
    </div>
  </view>
</template>

<style lang="scss" scoped></style>
