Skip to content

Commit

Permalink
fix: 解决嵌入luckysheet时,点击外部保存,单元格编辑内容未更新保存问题
Browse files Browse the repository at this point in the history
  • Loading branch information
DemoJx committed Aug 8, 2023
1 parent 22ad24c commit 4f9f0a6
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/controllers/handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,13 @@ export default function luckysheetHandler() {
menuButton.inputMenuButtonFocus(e.target);
});

// 点击视图外部任意处,退出编辑模式
$("#luckysheet-rich-text-editor").on('blur', function(e){
if(e.relatedTarget) return
formula.updatecell(Store.luckysheetCellUpdate[0], Store.luckysheetCellUpdate[1]);
luckysheetMoveHighlightCell("down", 0, "rangeOfSelect");
})

//表格mousedown
$("#luckysheet-cell-main, #luckysheetTableContent")
.mousedown(function(event) {
Expand Down

0 comments on commit 4f9f0a6

Please sign in to comment.