mirror of
https://gitee.com/was666/as-editor.git
synced 2026-04-21 00:00:01 +08:00
feat: v1.0.0
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
<template>
|
||||
<div class="richtext" :style="{ background: datas.backColor }">
|
||||
<img
|
||||
draggable="false"
|
||||
src="../../../assets/images/fwb.png"
|
||||
alt=""
|
||||
v-if="!datas.myValue.length"
|
||||
/>
|
||||
<section v-else v-html="datas.myValue" />
|
||||
|
||||
<!-- 删除组件 -->
|
||||
<slot name="deles" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'richtext',
|
||||
props: {
|
||||
datas: Object,
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
.richtext {
|
||||
position: relative;
|
||||
}
|
||||
/deep/img {
|
||||
max-width: 100% !important;
|
||||
display: block;
|
||||
}
|
||||
.richtext {
|
||||
position: relative;
|
||||
/deep/pre {
|
||||
white-space: break-spaces;
|
||||
}
|
||||
/deep/p {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user