transitions and buttons
This commit is contained in:
23
app/components/ButtonLink.vue
Normal file
23
app/components/ButtonLink.vue
Normal file
@@ -0,0 +1,23 @@
|
||||
<script setup lang="ts">
|
||||
const { to, text, icon = undefined, color = undefined } = defineProps<{
|
||||
to: string,
|
||||
text: string,
|
||||
icon?: string
|
||||
color?: string
|
||||
}>()
|
||||
|
||||
const buttonClass = ref(`btn btn-outline ${color ? color : "btn-primary"}`)
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<button :class="buttonClass">
|
||||
<NuxtLink :to="to" class=" flex flex-row items-center justify-center gap-2">
|
||||
<Icon v-if="icon" :name="icon" class="w-6 h-6" />
|
||||
{{ text }}
|
||||
</NuxtLink>
|
||||
</button>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
Reference in New Issue
Block a user