feat: 完善内容管理通用富文本编辑器
This commit is contained in:
10
app/components/RichTextContent.vue
Normal file
10
app/components/RichTextContent.vue
Normal file
@@ -0,0 +1,10 @@
|
||||
<script setup lang="ts">
|
||||
import { toDisplayHtml } from '~/utils/rich-text'
|
||||
|
||||
const props = defineProps<{ content: string }>()
|
||||
const html = computed(() => toDisplayHtml(props.content))
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="rich-text-content" v-html="html" />
|
||||
</template>
|
||||
Reference in New Issue
Block a user