conlang.phundrak.com/docs/.vuepress/components/ImgFigure.vue

21 lines
314 B
Vue
Raw Normal View History

2023-02-26 18:20:43 +00:00
<template>
<img :alt="alt" :src="src" />
<figcaption><slot></slot></figcaption>
</template>
<script setup lang="ts">
const props = defineProps<{
src: string;
alt?: string;
caption: string;
}>();
</script>
<style>
figcaption {
text-align: center;
margin-top: 1rem;
margin-bottom: 1rem;
}
</style>