<template>
  <div>
    <CommonEditor v-model="content" />
    <a-button class="btn" type="primary" @click="getContent">获取内容</a-button>
  </div>
</template>

<script>
import EditorWidget from './EditorWidget.vue';

export default {
  components: { EditorWidget },
  data() {
    return {
      content:
        '<p>你好</p><p>世界</p><p><img style="width: 183px;" src="https:a.leanwo.com/Files/0/Images/com.leanwo.prodog.trace.model.TraceComment/file_1747272128000_5fb87b15795f43c69bda8e0d7b547ce4.jpg" data-filename="image name"><br></p>',
    };
  },
  methods: {
    getContent() {
      console.log('富文本内容:', this.content);
    },
  },
};
</script>

<style scoped>
.btn {
  margin-top: 8px;
}

</style>