|
@@ -36,6 +36,7 @@
|
|
|
class="ql-container"
|
|
|
placeholder="开始输入..."
|
|
|
show-img-size show-img-toolbar show-img-resize
|
|
|
+ :auto-focus="autoFocus"
|
|
|
@statuschange="onStatusChange"
|
|
|
@ready="onEditorReady"
|
|
|
@input="onInputChange"
|
|
@@ -64,6 +65,10 @@
|
|
|
default: 0,
|
|
|
validator: value => value >= 0
|
|
|
},
|
|
|
+ autoFocus: {
|
|
|
+ type: Boolean,
|
|
|
+ default: false
|
|
|
+ },
|
|
|
richValue: {
|
|
|
type: String,
|
|
|
default: ''
|
|
@@ -152,7 +157,6 @@
|
|
|
// #ifdef APP-PLUS || MP-WEIXIN || H5
|
|
|
this.createSelectorQuery().select('#editor').context((res) => {
|
|
|
this.editorCtx = res.context
|
|
|
-
|
|
|
this.setEditorContent(this.richValue)
|
|
|
}).exec()
|
|
|
// #endif
|