Files
simrsx-fe/app/components/pub/ui/avatar/Avatar.vue
T
Munawwirul Jamal 3eb9dde21d Dev cleaning (#106)
2025-10-08 00:03:36 +07:00

24 lines
535 B
Vue

<script setup lang="ts">
import type { HTMLAttributes } from 'vue'
import type { AvatarVariants } from '.'
import { AvatarRoot } from 'radix-vue'
import { cn } from '~/lib/utils'
import { avatarVariant } from '.'
const props = withDefaults(defineProps<{
class?: HTMLAttributes['class']
size?: AvatarVariants['size']
shape?: AvatarVariants['shape']
}>(), {
size: 'sm',
shape: 'circle',
})
</script>
<template>
<AvatarRoot :class="cn(avatarVariant({ size, shape }), props.class)">
<slot />
</AvatarRoot>
</template>