diff --git a/src/components/CodemirrorEditor/insertForm.vue b/src/components/CodemirrorEditor/insertForm.vue index 5285393..afd4504 100644 --- a/src/components/CodemirrorEditor/insertForm.vue +++ b/src/components/CodemirrorEditor/insertForm.vue @@ -2,8 +2,8 @@ @@ -44,7 +44,7 @@ @@ -58,7 +58,7 @@ } from "vuex"; export default { props: { - dialogFormVisible: { + value: { type: Boolean, default: false } @@ -94,7 +94,7 @@ currRow = []; for (let j = 0; j < cols; ++j) { const rowIdx = i > 1 ? i - 1 : i; - i === 1 ? + i === 1 ? currRow.push("---\t") : currRow.push(this.tableData[`k_${rowIdx}_${j}`] || ""); } @@ -105,7 +105,7 @@ this.rowNum = 1; this.colNum = 1; this.editor.replaceSelection(`\n${table}\n`, "end"); - this.$emit("close"); + this.$emit('input', false); this.editorRefresh(); }, ...mapMutations(["editorRefresh"]),