Skip to content

Commit

Permalink
fix: disable automatic selection when double clicking the checkbox
Browse files Browse the repository at this point in the history
  • Loading branch information
Hufe921 committed Feb 19, 2024
1 parent 9428148 commit 72a22b5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/editor/core/event/handlers/click.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ function dblclick(host: CanvasEvent, evt: MouseEvent) {
return
}
}
// 复选框双击时是切换选择状态,禁用扩选
if (positionContext.isCheckbox && positionContext.isDirectHit) return
// 自动扩选文字
const cursorPosition = position.getCursorPosition()
if (!cursorPosition) return
Expand Down

0 comments on commit 72a22b5

Please sign in to comment.