Files
site-10584/components/Content.vue
2026-01-29 10:43:43 +08:00

42 lines
668 B
Vue

<template>
<div v-html="data || '暂无'"></div>
<!-- <MdPreview v-else :id="id" :modelValue="data" />-->
</template>
<script setup lang="ts">
// import { MdPreview } from 'md-editor-v3';
// import 'md-editor-v3/lib/preview.css';
const props = withDefaults(
defineProps<{
data?: any;
editor?: number;
isMobile?: boolean;
}>(),
{}
);
const id = 'preview-only';
</script>
<style lang="scss">
.content {
overflow: hidden;
color: #333131;
}
.content p{
padding: 0;
line-height: 2.2rem;
//text-indent: 2rem;
}
.content img{
padding: 8px 0;
max-width: 100%;
height: auto;
}
.content video {
width: 100%;
height: auto;
}
</style>