wallet-connect-web-examples/dapps/vue-dapp-auth/components/AvatarImage.vue
Pavel Yankovski 7e850d66c4
feat(vue-dapp-auth): Add example dapp on Vue 3 (#76)
Co-authored-by: Ben Kremer <contact@bkrem.dev>
2022-11-14 18:13:55 +01:00

19 lines
425 B
Vue

<template>
<div class="tw-border tw-border-muted tw-bg-placeholder tw-circle-24 tw-flex tw-items-center tw-justify-center">
<loading-spinner v-if="loading" class="tw-text-2xl" />
<img v-else-if="src" :src="src" :alt="alt">
</div>
</template>
<script setup lang="ts">
interface Props {
src?: string | null
loading?: boolean
alt?: string
}
withDefaults(defineProps<Props>(), {
alt: 'Avatar',
})
</script>