<template>
  <view class="setting-container" :style="{ height: `${windowHeight}px` }">
    <view class="menu-list mlr0">
      <view class="list-cell list-cell-arrow" @click="proxy.$settingStore.handleToEditInfo()">
        <view class="menu-item">
          <view class="iconfont oaIcon-user menu-item-icon"></view>
          <view>我的信息</view>
        </view>
      </view>
    </view>

    <view class="menu-list mt0 mlr0">
      <view class="list-cell list-cell-arrow" @click="proxy.$settingStore.handleAbout()">
        <view class="menu-item">
          <view class="iconfont oaIcon-aixin menu-item-icon"></view>
          <view>关于我们</view>
        </view>
      </view>
      <view class="list-cell list-cell-arrow" @click="proxy.$settingStore.handleHelp()">
        <view class="menu-item">
          <view class="iconfont oaIcon-Help menu-item-icon"></view>
          <view>常见问题</view>
        </view>
      </view>
      <view class="list-cell list-cell-arrow" @click="proxy.$settingStore.handleCleanTmp()">
        <view class="menu-item">
          <view class="iconfont oaIcon-qinglihuancun menu-item-icon"></view>
          <view>清理缓存</view>
          <view class="text-right">{{ proxy.$settingStore.currentSize }}</view>
        </view>
      </view>
      <view class="list-cell list-cell-arrow" @click="proxy.$settingStore.handleToUpgrade()">
        <view class="menu-item">
          <view class="iconfont oaIcon-jianchagengxin menu-item-icon"></view>
          <view>检查更新</view>
        </view>
      </view>
    </view>

    <!-- <view class="menu-list" @click="proxy.$settingStore.handleLogout">
      <view class="list-cell">
        <view class="menu-item">
          <view class="button">退 出 登 录</view>
        </view>
      </view>
    </view> -->
  </view>
</template>

<script setup>
/*----------------------------------依赖引入-----------------------------------*/
import { onLoad, onShow, onHide, onLaunch, onNavigationBarButtonTap } from "@dcloudio/uni-app";
import { ref, reactive, computed, getCurrentInstance, toRefs, inject } from "vue";
/*----------------------------------接口引入-----------------------------------*/
/*----------------------------------组件引入-----------------------------------*/
/*----------------------------------store引入-----------------------------------*/
import { useStores, commonStores } from "@/store/modules/index";
/*----------------------------------公共方法引入-----------------------------------*/
/*----------------------------------公共变量-----------------------------------*/
const { proxy } = getCurrentInstance();
const useStore = useStores();
/*----------------------------------变量声明-----------------------------------*/

const state = reactive({
  windowHeight: computed(() => {
    return uni.getSystemInfoSync().windowHeight - 50;
  }),
});

const { windowHeight } = toRefs(data);

onLoad((options) => {});

onShow(() => {
  //调用系统主题颜色
  proxy.$settingStore.systemThemeColor([1]);
});
</script>
