提交 56d56c43 编写于 作者: 璃白.'s avatar 璃白. 🌻

🐛 修复@用户时插入位置错误的问题

上级 2c0850be
流水线 #5499 已通过 ,包含阶段
in 1 分5 秒
{
"name": "awesome-markdown-editor",
"description": " A open source markdown editor of csdn codechina team contributed",
"version": "1.0.0",
"version": "1.1.0",
"publisher": "guoweijia",
"license": "MIT",
"scripts": {
......
......@@ -234,7 +234,9 @@ export default {
showSelectUser: {
handler: function(val) {
if (!val) {
this.resetQueryInfo();
setTimeout(() => {
this.resetQueryInfo();
}, 50);
}
}
}
......
......@@ -3,7 +3,6 @@ export default {
methods: {
handleSelectLinkType(index) {
const originalText = this.textContent;
const queryInfo = this.queryInfo;
const cursorPosition = getPosition(this.id);
let typeStr = "";
switch (index) {
......
......@@ -24,6 +24,9 @@ export default {
const originalText = this.textContent;
const queryInfo = this.queryInfo;
const cursorPosition = getPosition(this.id);
console.log('p',cursorPosition,this.queryInfo);
const username = user.nickname + " ";
const newText =
originalText.slice(0, queryInfo.startPosition) +
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册