<script setup lang="ts">

import { ChevronDownIcon } from 'tdesign-icons-vue-next'
import type { DropdownOption } from 'tdesign-vue-next'
import { useAppStore } from '@/stores/app'
const appStore = useAppStore()
const options: DropdownOption[] = [
  {
    content: '退出登录',
    onClick() {
      appStore.logout()
    }
  }
]
</script>

<template>
  <div>
    <TDropdown :options="options" :minColumnWidth="100">
      <TButton variant="text">
        <div class="flex gap-2 items-center">
          <TAvatar size="24px" image="https://tdesign.gtimg.com/site/avatar.jpg"></TAvatar>
          依力
          <ChevronDownIcon />
        </div>
      </TButton>
    </TDropdown>
  </div>
</template>

<style scoped>

</style>
