vikunja-frontend/src/components/misc/dropdown-item.vue
Dominik Pschenitschni ac630ac775 feat: convert simple components to script setup and use typescript (#1120)
Co-authored-by: Dominik Pschenitschni <mail@celement.de>
Reviewed-on: https://kolaente.dev/vikunja/frontend/pulls/1120
Reviewed-by: konrad <k@knt.li>
Co-authored-by: Dominik Pschenitschni <dpschen@noreply.kolaente.de>
Co-committed-by: Dominik Pschenitschni <dpschen@noreply.kolaente.de>
2021-12-04 14:47:32 +00:00

25 lines
345 B
Vue

<template>
<router-link
:to="to"
class="dropdown-item">
<span class="icon" v-if="icon !== ''">
<icon :icon="icon"/>
</span>
<span>
<slot></slot>
</span>
</router-link>
</template>
<script lang="ts" setup>
defineProps({
to: {
required: true,
},
icon: {
type: String,
required: false,
default: '',
},
})
</script>