Skip to content

Commit

Permalink
Dispatch editCancel event early before viewing new document request s…
Browse files Browse the repository at this point in the history
…tarts (#1198)
  • Loading branch information
alexgao1 authored Nov 1, 2023
1 parent 7e361c5 commit 8871b94
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
var documentTransforms = [];
var allLists = [];
var selectedList = null;
var dispatchService = null;

// **********************************************************************
var DocumentList = $n2.Class({
Expand Down Expand Up @@ -3344,6 +3345,10 @@

// -----------------------------------------------------------------
function viewDocument(docId){
dispatchService.send("select.js", {
type: "editCancel"
})

var $div = getDocumentDiv();
var $revs = getDocumentRevisionsDiv();

Expand Down Expand Up @@ -3574,6 +3579,7 @@
config = opts_.config;
atlasDb = opts_.config.atlasDb;
atlasDesign = opts_.config.atlasDesign;
dispatchService = opts_.config.directory.dispatchService;
serverDesign = opts_.config.serverDesign;
siteDesign = opts_.config.siteDesign;
schemaRepository = opts_.config.directory.schemaRepository;
Expand Down

0 comments on commit 8871b94

Please sign in to comment.