<!-- @format -->

<script lang="ts" setup>
import { useUserStore } from '@/stores/modules/user'

const userStore = useUserStore()
const { isLogin } = storeToRefs(userStore)

// 使用 useI18n 钩子
const { t } = useI18n()
</script>

<template>
  <div class="flex justify-between h-42px  w-1400px mx-auto">
    <div class="flex items-center">
      <NuxtLink to="/">
        <img
          src="~/assets/images/ejet_logo.png"
          alt="logo"
          class="w-200px h-31px cursor-pointer"
        >
      </NuxtLink>
    </div>
    <div class="flex items-center ">
      <!-- 使用 t 方法获取翻译文本 -->
      {{ t('Popular_test') }}
      <!-- <NuxtLink to="/" class="hover:underline">
        SELL ON EJET
      </NuxtLink> -->
      <div class="w-1px bg-#D8D8D8 h-20px mx-20px" />
      <select-lang />
      <!-- <div class="w-1px bg-#D8D8D8 h-20px mx-20px" v-if="isLogin"/>
      <NuxtLink v-if="isLogin" to="/cart">
        <svgo-cart class="!w-24px !h-24px ml-20px" />
      </NuxtLink> -->
      <user-avatar class="ml-30px" />
    </div>
  </div>
</template>

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