tabbar.vue 596 B

1234567891011121314151617181920212223
  1. <script setup lang="ts">
  2. import { $t } from '@vben/locales';
  3. import SwitchItem from '../switch-item.vue';
  4. defineOptions({
  5. name: 'PreferenceTabsConfig',
  6. });
  7. defineProps<{ disabled?: boolean }>();
  8. const tabbarEnable = defineModel<boolean>('tabbarEnable');
  9. const tabbarShowIcon = defineModel<boolean>('tabbarShowIcon');
  10. </script>
  11. <template>
  12. <SwitchItem v-model="tabbarEnable" :disabled="disabled">
  13. {{ $t('preferences.tabbar.enable') }}
  14. </SwitchItem>
  15. <SwitchItem v-model="tabbarShowIcon" :disabled="!tabbarEnable">
  16. {{ $t('preferences.tabbar.icon') }}
  17. </SwitchItem>
  18. </template>