Pls do these changes -
In node_modules/diagram-js/lib/core/Canvas.js
//Reset Canvas
Canvas.prototype.resetCanvas = function (){
this._changeViewbox(function() {
setCTM(this._viewport.node,{a:"1",b:"0",c:"0",d:"1",e:"0",f:"0"});
});
}
In node_modules/bpmn-js/lib/Viewer.js
Viewer.prototype.resetCanvas = function() {
var canvas = this.get('canvas');
canvas.resetCanvas();
}
In app.js
/* Reset Canvas Scroll */
function resetCanvas(){
bpmnModeler.resetCanvas();
}
//In
$(document).on('ready', function() {
//Add
$('#js-reset-canvas').click(function(e) {
e.stopPropagation();
e.preventDefault();
resetCanvas();
});
index.html
<li id="reset-canvas"><a id="js-reset-canvas" href>Reset Canvas</a></li>