mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-29 19:30:37 +01:00
feat(Card): add variant prop
This commit is contained in:
@@ -1,6 +1,16 @@
|
||||
<script setup lang="ts">
|
||||
import theme from '#build/ui/card'
|
||||
|
||||
const variants = Object.keys(theme.variants.variant)
|
||||
|
||||
const variant = ref(theme.defaultVariants.variant)
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="flex flex-col gap-4">
|
||||
<UCard class="w-96">
|
||||
<USelect v-model="variant" :items="variants" />
|
||||
|
||||
<UCard :variant="variant" class="w-96">
|
||||
<template #header>
|
||||
<Placeholder class="h-8" />
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user