<template>
  <div class="tab">
    <mb_select class="mb_select" @handleOption="handleTab" :value="activeId" :options="list" />
  </div>
</template>

<script setup>
import { ref, onMounted, watch, defineProps, defineEmits, nextTick, provide } from "vue";
import mb_select from "@/components/mb_select";
const tab$ = ref(null);

const activeW = ref(0);


const props = defineProps({
  list: {
    type: Array,
    default: () => {
      return []
    },
  }
})

const activeId = ref(props.list[0].id);

const emit = defineEmits(['handleTab'])

const handleTab = data => {
  activeId.value = data.id
  emit('handleTab', data)
}


onMounted(() => { });
</script>

<style lang="scss" scoped>
.tab {
  font-size: 0;
  .mb_select {
    width: 100%;
  }
}
</style>
