<!--  -->
<template>
  <v-tabs v-model="tab" align-tabs="start" color="primary" @update:modelValue="handleUpdate" bg-color="#f7f8fa">
    <v-tab v-for="k in tagList" :key="k.value" :value="k.value">{{ k.title }}</v-tab>
  </v-tabs>
</template>

<script setup>
defineOptions({name: 'defineOptions-buttons'})
import { ref } from 'vue'
import { useRouter } from 'vue-router'

const router = useRouter()
const props = defineProps({
  current: {
    type: Number,
    default: 0
  }
})
const tab = ref(props.current)

const tagList = [
  { title: '推荐', path:'/recruit/personal/recommend', value: 0 },
  { title: '职位', path:'/recruit/personal/position', value: 1 },
  { title: '公司', path:'/recruit/personal/company', value: 2 }
]

const handleUpdate = (e) => {
  router.push(tagList[e].path)
}
</script>

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