main
vue 28 lines 605 Bytes
Raw
1 <template>
2 <n-button :size :type :secondary @click="goToGitHubAudit">
3 <template #icon>
4 <Icon :name="GitHubIcon" />
5 </template>
6 GitHub Audit
7 </n-button>
8 </template>
9
10 <script setup lang="ts">
11 import type { ButtonSize, ButtonType } from "naive-ui"
12 import { NButton } from "naive-ui"
13 import { useRouter } from "vue-router"
14 import Icon from "@/components/common/Icon.vue"
15
16 defineProps<{
17 size?: ButtonSize
18 type?: ButtonType
19 secondary?: boolean
20 }>()
21
22 const GitHubIcon = "carbon:logo-github"
23 const router = useRouter()
24
25 function goToGitHubAudit() {
26 router.push({ name: "GitHubAudit" })
27 }
28 </script>