adding some dropdown components

This commit is contained in:
Brian 2022-09-27 11:12:13 -06:00
parent 5f87596b2f
commit a2a747c489
Signed by: brian
GPG Key ID: DE1A5390A3B84CD8
3 changed files with 38 additions and 0 deletions

View File

@ -0,0 +1,22 @@
<script setup>
import { Link } from '@inertiajs/inertia-vue3'
defineProps({
href: String,
as: String,
});
</script>
<template>
<button v-if="as == 'button'" type="submit" class="block w-full px-4 py-2 text-sm leading-5 text-gray-700 text-left hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition">
<slot></slot>
</button>
<a v-else-if="as =='a'" :href="href" class="block px-4 py-2 text-sm leading-5 text-gray-700 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition">
<slot></slot>
</a>
<Link v-else :href="href" class="block px-4 py-2 text-sm leading-5 text-gray-700 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition">
<slot></slot>
</Link>
</template>

View File

@ -0,0 +1,7 @@
<script setup>
//
</script>
<template>
<div class="border-t border-gray-100"></div>
</template>

View File

@ -0,0 +1,9 @@
<script setup>
//
</script>
<template>
<div class="block px-4 py-2 text-xs text-gray-400">
<slot></slot>
</div>
</template>