Commit e442ce39 authored by 张俊's avatar 张俊

编辑页面

parent 271f6bff
...@@ -31,10 +31,6 @@ export default { ...@@ -31,10 +31,6 @@ export default {
type: Boolean, type: Boolean,
default: false default: false
}, },
menu:{
type: Array,
default: []
}
}, },
watch: { watch: {
isClear(val) { isClear(val) {
...@@ -105,9 +101,6 @@ export default { ...@@ -105,9 +101,6 @@ export default {
// } // }
} }
}; };
if(this.menu.length){
this.editor.config.menus = this.menu
}
this.editor.config.onchange = html => { this.editor.config.onchange = html => {
this.info_ = html; // 绑定当前逐渐地值 this.info_ = html; // 绑定当前逐渐地值
this.$emit("change", this.info_); // 将内容同步到父组件中 this.$emit("change", this.info_); // 将内容同步到父组件中
......
...@@ -2,23 +2,38 @@ ...@@ -2,23 +2,38 @@
<div class="detail_box"> <div class="detail_box">
<p class="now_page_title"> <p class="now_page_title">
技术支持 / 问答中心 / 问答列表 / 技术支持 / 问答中心 / 问答列表 /
<span>详情</span> <span>编辑</span>
</p> </p>
<div class="detail_content"> <div class="detail_content">
<div class="detail_title">
<el-input v-model="title" placeholder="请输入问题标题"></el-input>
</div>
<div class="detail_edit">
<wang-e-bd class="editbox" v-model="editstr" :menu="menu" :full="false"></wang-e-bd>
</div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import wangEBd from '@/components/wangEBd'
export default { export default {
props: [], props: [],
components: { components: {
wangEBd
}, },
data() { data() {
return { return {
title:'',
menu:[
'bold',
'foreColor',
'code',
'link',
'image',
'video'
],
editstr:'',
}; };
}, },
watch: { watch: {
...@@ -41,7 +56,7 @@ export default { ...@@ -41,7 +56,7 @@ export default {
<style scoped> <style scoped>
.detail_box { .detail_box {
height: calc(100% - 15px);
} }
.now_page_title { .now_page_title {
margin: 13px 0; margin: 13px 0;
...@@ -52,6 +67,33 @@ export default { ...@@ -52,6 +67,33 @@ export default {
} }
.detail_content { .detail_content {
width: 100%; width: 100%;
height: calc(100% - 35px);
}
.detail_title{
height: 96px;
background-color: #ffffff;
box-shadow: 0px 3px 6px 0px
rgba(15, 19, 65, 0.04);
border-radius: 12px;
padding: 24px;
margin-bottom: 15px;
}
.editbox{
height: calc(100% - 65px);
}
.detail_edit{
height: 672px;
background-color: #ffffff;
box-shadow: 0px 3px 6px 0px
rgba(15, 19, 65, 0.04);
border-radius: 12px;
padding: 24px;
}
</style>
<style>
.detail_title .el-input__inner{
height: 48px;
line-height: 48px;
background-color: #fbfbfc;
} }
</style> </style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment