Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/jgraph/drawio.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Benson [draw.io] <david@jgraph.com>2020-05-05 18:39:45 +0300
committerDavid Benson [draw.io] <david@jgraph.com>2020-05-05 18:39:45 +0300
commit4727adfcd3224fb80d2eabd8565448fef62d2f54 (patch)
tree1961b5eeacf484d78452619f75162da897aa5b4a
parentff0b4e7ae8adc83b106be9a2ddf0077fdc029500 (diff)
13.0.8 releasev13.0.8
-rw-r--r--ChangeLog4
-rw-r--r--VERSION2
-rw-r--r--etc/license-worker/license.js9
-rw-r--r--src/main/webapp/connect/confluence/macroEditor-1-4-8.html106
-rw-r--r--src/main/webapp/js/app.min.js20
-rw-r--r--src/main/webapp/js/mxgraph/EditorUi.js51
-rw-r--r--src/main/webapp/js/mxgraph/Graph.js3
-rw-r--r--src/main/webapp/js/viewer.min.js1202
-rw-r--r--src/main/webapp/service-worker.js2
9 files changed, 714 insertions, 685 deletions
diff --git a/ChangeLog b/ChangeLog
index 0b4180ac..29494ed3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+05-MAY-2020: 13.0.8
+
+- Adds ctrl+enter for table cells
+
05-MAY-2020: 13.0.7
- Uses mxGraph 4.1.2 beta 6
diff --git a/VERSION b/VERSION
index aac9a035..d9c8e061 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-13.0.7 \ No newline at end of file
+13.0.8 \ No newline at end of file
diff --git a/etc/license-worker/license.js b/etc/license-worker/license.js
index 452eb613..87077ae0 100644
--- a/etc/license-worker/license.js
+++ b/etc/license-worker/license.js
@@ -20,6 +20,7 @@ async function handleRequest(request)
let reqBodyTxt = new TextDecoder("utf-8").decode(reqBody.value);
let params = new URL('http://dummy.com?' + reqBodyTxt).searchParams;
let domain = params.get('domain');
+ let confLicense = params.get('confLicense');
//Try Query string parameters
if (domain == null)
@@ -38,9 +39,15 @@ async function handleRequest(request)
let url = "https://log.diagrams.net/" + msg;
fetch(url);
}
+ else if (confLicense != null && domain != null)
+ {
+ let msg = encodeURIComponent(('license:confLicense=' + confLicense + ',domain=' + domain));
+ let url = "https://log.diagrams.net/" + msg;
+ fetch(url);
+ }
else if (domain != null)
{
- let msg = encodeURIComponent(('license:atlas-cloud:' + domain));
+ let msg = encodeURIComponent(('license:domain=' + domain));
let url = "https://log.diagrams.net/" + msg;
fetch(url);
}
diff --git a/src/main/webapp/connect/confluence/macroEditor-1-4-8.html b/src/main/webapp/connect/confluence/macroEditor-1-4-8.html
index 9006176b..5c17d471 100644
--- a/src/main/webapp/connect/confluence/macroEditor-1-4-8.html
+++ b/src/main/webapp/connect/confluence/macroEditor-1-4-8.html
@@ -36,77 +36,73 @@
AC.logError(message, url, linenumber, colno, err);
};
- var xdm_e = AC.getSiteUrl();
var baseUrl = AC.getBaseUrl();
- var license = AC.getUrlParam('lic', false);
var connectUrl = baseUrl + '/atlassian-connect';
var head = document.getElementsByTagName('head')[0];
- var licenseValid = true;
+
var script = document.createElement('script');
script.setAttribute('data-options', 'resize:false;margin:false');
-
- if (license != null && xdm_e != null)
+
+ // Main
+ script.onload = function()
{
- if (license == 'none')
+ var xdm_e = AC.getSiteUrl();
+ var license = AC.getUrlParam('lic', false);
+
+ if (license != null && xdm_e != null)
{
- var hostParse = document.createElement('a');
- hostParse.href = xdm_e;
- var hostname = hostParse.hostname;
-
- if (hostname != null)
+ if (license == 'none')
{
- if (hostname.indexOf('.ngrok.io') > -1)
- {
- console.log("License status = ", license);
- }
- else
+ var hostParse = document.createElement('a');
+ hostParse.href = xdm_e;
+ var hostname = hostParse.hostname;
+
+ if (hostname != null)
{
- var xhr = new XMLHttpRequest();
-
- xhr.onreadystatechange = function()
+ if (hostname.indexOf('.ngrok.io') > -1)
{
- if (xhr.readyState == XMLHttpRequest.DONE && xhr.status >= 200 && xhr.status <= 299)
- {
- var resp = xhr.responseText;
-
- if (resp != null && resp.length > 0)
- {
- var lic = JSON.parse(resp);
+ console.log("License status = ", license);
+ }
+ else
+ {
+ AP.request({
+ type: 'GET',
+ url: '/rest/atlassian-connect/1/addons/com.mxgraph.confluence.plugins.diagramly',
+ contentType: 'application/json;charset=UTF-8',
+ success: function (resp)
+ {
+ resp = JSON.parse(resp);
+
+ var xhr = new XMLHttpRequest();
- if (lic != null && lic.atlasCloudLic != null)
+ xhr.onreadystatechange = function()
{
- licenseValid = true;
- }
- }
- }
- };
-
- xhr.open('POST', '/license?domain=' + hostname, true);
- xhr.send(null);
+ if (xhr.readyState == XMLHttpRequest.DONE && xhr.status >= 200 && xhr.status <= 299)
+ {
+ var resp = xhr.responseText;
+
+ if (resp != null && resp.length > 0)
+ {
+ var lic = JSON.parse(resp);
+
+ if (lic != null && lic.atlasCloudLic != null)
+ {
+ // decide whether valid and close if not
+ // AP.dialog.close();
+ }
+ }
+ }
+ };
+
+ xhr.open('POST', '/license?domain=' + hostname + '&confLicense=' + license + '&SEN=' + resp.license? resp.license.supportEntitlementNumber : 'Unlicensed', true);
+ xhr.send(null);
+ }
+ });
+ }
}
}
}
- else
- {
- licenseValid = true;
- }
- }
-
- // Main
- script.onload = function()
- {
- if (!licenseValid)
- {
- setTimeout(function()
- {
- if (!licenseValid)
- {
- alert("Please install a license for the draw.io app");
- AP.dialog.close();
- }
- }, 3000);
- }
AP.resize('100%', '100%');
diff --git a/src/main/webapp/js/app.min.js b/src/main/webapp/js/app.min.js
index 9ae9a2f3..8460e99c 100644
--- a/src/main/webapp/js/app.min.js
+++ b/src/main/webapp/js/app.min.js
@@ -2272,7 +2272,8 @@ mxEvent.getClientY(a));g=m();k=!1;mxEvent.consume(a)});mxEvent.addListener(a,"cl
EditorUi.prototype.handleError=function(a,c,d,b,f){a=null!=a&&null!=a.error?a.error:a;if(null!=a||null!=c){f=mxUtils.htmlEntities(mxResources.get("unknownError"));var e=mxResources.get("ok");c=null!=c?c:mxResources.get("error");null!=a&&null!=a.message&&(f=mxUtils.htmlEntities(a.message));this.showError(c,f,e,d,null,null,null,null,null,null,null,null,b?d:null)}else null!=d&&d()};
EditorUi.prototype.showError=function(a,c,d,b,f,e,h,g,k,l,m,n,p){a=new ErrorDialog(this,a,c,d||mxResources.get("ok"),b,f,e,h,n,g,k);c=Math.ceil(null!=c?c.length/50:1);this.showDialog(a.container,l||340,m||100+20*c,!0,!1,p);a.init()};EditorUi.prototype.showDialog=function(a,c,d,b,f,e,h,g,k,l){this.editor.graph.tooltipHandler.hideTooltip();null==this.dialogs&&(this.dialogs=[]);this.dialog=new Dialog(this,a,c,d,b,f,e,h,g,k,l);this.dialogs.push(this.dialog)};
EditorUi.prototype.hideDialog=function(a,c){if(null!=this.dialogs&&0<this.dialogs.length){var d=this.dialogs.pop();0==d.close(a,c)?this.dialogs.push(d):(this.dialog=0<this.dialogs.length?this.dialogs[this.dialogs.length-1]:null,this.editor.fireEvent(new mxEventObject("hideDialog")),null==this.dialog&&"hidden"!=this.editor.graph.container.style.visibility&&window.setTimeout(mxUtils.bind(this,function(){this.editor.graph.isEditing()&&null!=this.editor.graph.cellEditor.textarea?this.editor.graph.cellEditor.textarea.focus():
-(mxUtils.clearSelection(),this.editor.graph.container.focus())}),0))}};EditorUi.prototype.pickColor=function(a,c){var d=this.editor.graph,b=d.cellEditor.saveSelection(),f=226+17*(Math.ceil(ColorDialog.prototype.presetColors.length/12)+Math.ceil(ColorDialog.prototype.defaultColors.length/12)),e=new ColorDialog(this,a||"none",function(a){d.cellEditor.restoreSelection(b);c(a)},function(){d.cellEditor.restoreSelection(b)});this.showDialog(e.container,230,f,!0,!1);e.init()};
+(mxUtils.clearSelection(),this.editor.graph.container.focus())}),0))}};EditorUi.prototype.ctrlEnter=function(){var a=this.editor.graph;if(a.isEnabled())try{for(var c=a.getSelectionCells(),d=new mxDictionary,b=[],f=0;f<c.length;f++){var e=a.isTableCell(c[f])?a.model.getParent(c[f]):c[f];null==e||d.get(e)||(d.put(e,!0),b.push(e))}a.setSelectionCells(a.duplicateCells(b,!1))}catch(h){this.handleError(h)}};
+EditorUi.prototype.pickColor=function(a,c){var d=this.editor.graph,b=d.cellEditor.saveSelection(),f=226+17*(Math.ceil(ColorDialog.prototype.presetColors.length/12)+Math.ceil(ColorDialog.prototype.defaultColors.length/12)),e=new ColorDialog(this,a||"none",function(a){d.cellEditor.restoreSelection(b);c(a)},function(){d.cellEditor.restoreSelection(b)});this.showDialog(e.container,230,f,!0,!1);e.init()};
EditorUi.prototype.openFile=function(){window.openFile=new OpenFile(mxUtils.bind(this,function(a){this.hideDialog(a)}));this.showDialog((new OpenDialog(this)).container,Editor.useLocalStorage?640:320,Editor.useLocalStorage?480:220,!0,!0,function(){window.openFile=null})};
EditorUi.prototype.extractGraphModelFromHtml=function(a){var c=null;try{var d=a.indexOf("&lt;mxGraphModel ");if(0<=d){var b=a.lastIndexOf("&lt;/mxGraphModel&gt;");b>d&&(c=a.substring(d,b+21).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}}catch(f){}return c};
EditorUi.prototype.extractGraphModelFromEvent=function(a){var c=null,d=null;null!=a&&(a=null!=a.dataTransfer?a.dataTransfer:a.clipboardData,null!=a&&(10==document.documentMode||11==document.documentMode?d=a.getData("Text"):(d=0<=mxUtils.indexOf(a.types,"text/html")?a.getData("text/html"):null,mxUtils.indexOf(a.types,null==d||0==d.length)&&(d=a.getData("text/plain"))),null!=d&&(d=Graph.zapGremlins(mxUtils.trim(d)),a=this.extractGraphModelFromHtml(d),null!=a&&(d=a))));null!=d&&this.isCompatibleString(d)&&
@@ -2292,14 +2293,13 @@ mxEvent.isShiftDown(a)||90!=a.keyCode&&89!=a.keyCode&&188!=a.keyCode&&190!=a.key
null,k={37:mxConstants.DIRECTION_WEST,38:mxConstants.DIRECTION_NORTH,39:mxConstants.DIRECTION_EAST,40:mxConstants.DIRECTION_SOUTH},l=f.getFunction;mxKeyHandler.prototype.getFunction=function(a){if(b.isEnabled()){if(mxEvent.isShiftDown(a)&&mxEvent.isAltDown(a)){var e=d.actions.get(d.altShiftActions[a.keyCode]);if(null!=e)return e.funct}if(9==a.keyCode&&mxEvent.isAltDown(a))return b.cellEditor.isContentEditing()?function(){document.execCommand("outdent",!1,null)}:mxEvent.isShiftDown(a)?function(){b.selectParentCell()}:
function(){b.selectChildCell()};if(null!=k[a.keyCode]&&!b.isSelectionEmpty())if(!this.isControlDown(a)&&mxEvent.isShiftDown(a)&&mxEvent.isAltDown(a)){if(b.model.isVertex(b.getSelectionCell()))return function(){var c=b.connectVertex(b.getSelectionCell(),k[a.keyCode],b.defaultEdgeLength,a,!0);null!=c&&0<c.length&&(1==c.length&&b.model.isEdge(c[0])?b.setSelectionCell(b.model.getTerminal(c[0],!1)):b.setSelectionCell(c[c.length-1]),b.scrollCellToVisible(b.getSelectionCell()),null!=d.hoverIcons&&d.hoverIcons.update(b.view.getState(b.getSelectionCell())))}}else return this.isControlDown(a)?
function(){c(a.keyCode,mxEvent.isShiftDown(a)?b.gridSize:null,!0)}:function(){c(a.keyCode,mxEvent.isShiftDown(a)?b.gridSize:null)}}return l.apply(this,arguments)};f.bindAction=mxUtils.bind(this,function(a,b,c,d){var e=this.actions.get(c);null!=e&&(c=function(){e.isEnabled()&&e.funct()},b?d?f.bindControlShiftKey(a,c):f.bindControlKey(a,c):d?f.bindShiftKey(a,c):f.bindKey(a,c))});var m=this,n=f.escape;f.escape=function(a){n.apply(this,arguments)};f.enter=function(){};f.bindControlShiftKey(36,function(){b.exitGroup()});
-f.bindControlShiftKey(35,function(){b.enterGroup()});f.bindShiftKey(36,function(){b.home()});f.bindKey(35,function(){b.refresh()});f.bindAction(107,!0,"zoomIn");f.bindAction(109,!0,"zoomOut");f.bindAction(80,!0,"print");f.bindAction(79,!0,"outline",!0);if(!this.editor.chromeless||this.editor.editable)f.bindControlKey(36,function(){b.isEnabled()&&b.foldCells(!0)}),f.bindControlKey(35,function(){b.isEnabled()&&b.foldCells(!1)}),f.bindControlKey(13,function(){if(b.isEnabled())try{b.setSelectionCells(b.duplicateCells(b.getSelectionCells(),
-!1))}catch(p){m.handleError(p)}}),f.bindAction(8,!1,"delete"),f.bindAction(8,!0,"deleteAll"),f.bindAction(46,!1,"delete"),f.bindAction(46,!0,"deleteAll"),f.bindAction(36,!1,"resetView"),f.bindAction(72,!0,"fitWindow",!0),f.bindAction(74,!0,"fitPage"),f.bindAction(74,!0,"fitTwoPages",!0),f.bindAction(48,!0,"customZoom"),f.bindAction(82,!0,"turn"),f.bindAction(82,!0,"clearDefaultStyle",!0),f.bindAction(83,!0,"save"),f.bindAction(83,!0,"saveAs",!0),f.bindAction(65,!0,"selectAll"),f.bindAction(65,!0,
-"selectNone",!0),f.bindAction(73,!0,"selectVertices",!0),f.bindAction(69,!0,"selectEdges",!0),f.bindAction(69,!0,"editStyle"),f.bindAction(66,!0,"bold"),f.bindAction(66,!0,"toBack",!0),f.bindAction(70,!0,"toFront",!0),f.bindAction(68,!0,"duplicate"),f.bindAction(68,!0,"setAsDefaultStyle",!0),f.bindAction(90,!0,"undo"),f.bindAction(89,!0,"autosize",!0),f.bindAction(88,!0,"cut"),f.bindAction(67,!0,"copy"),f.bindAction(86,!0,"paste"),f.bindAction(71,!0,"group"),f.bindAction(77,!0,"editData"),f.bindAction(71,
-!0,"grid",!0),f.bindAction(73,!0,"italic"),f.bindAction(76,!0,"lockUnlock"),f.bindAction(76,!0,"layers",!0),f.bindAction(80,!0,"formatPanel",!0),f.bindAction(85,!0,"underline"),f.bindAction(85,!0,"ungroup",!0),f.bindAction(190,!0,"superscript"),f.bindAction(188,!0,"subscript"),f.bindAction(9,!1,"indent",!0),f.bindKey(13,function(){b.isEnabled()&&b.startEditingAtCell()}),f.bindKey(113,function(){b.isEnabled()&&b.startEditingAtCell()});mxClient.IS_WIN?f.bindAction(89,!0,"redo"):f.bindAction(90,!0,"redo",
-!0);return f};
-EditorUi.prototype.destroy=function(){null!=this.editor&&(this.editor.destroy(),this.editor=null);null!=this.menubar&&(this.menubar.destroy(),this.menubar=null);null!=this.toolbar&&(this.toolbar.destroy(),this.toolbar=null);null!=this.sidebar&&(this.sidebar.destroy(),this.sidebar=null);null!=this.keyHandler&&(this.keyHandler.destroy(),this.keyHandler=null);null!=this.keydownHandler&&(mxEvent.removeListener(document,"keydown",this.keydownHandler),this.keydownHandler=null);null!=this.keyupHandler&&(mxEvent.removeListener(document,
-"keyup",this.keyupHandler),this.keyupHandler=null);null!=this.resizeHandler&&(mxEvent.removeListener(window,"resize",this.resizeHandler),this.resizeHandler=null);null!=this.gestureHandler&&(mxEvent.removeGestureListeners(document,this.gestureHandler),this.gestureHandler=null);null!=this.orientationChangeHandler&&(mxEvent.removeListener(window,"orientationchange",this.orientationChangeHandler),this.orientationChangeHandler=null);null!=this.scrollHandler&&(mxEvent.removeListener(window,"scroll",this.scrollHandler),
-this.scrollHandler=null);if(null!=this.destroyFunctions){for(var a=0;a<this.destroyFunctions.length;a++)this.destroyFunctions[a]();this.destroyFunctions=null}for(var c=[this.menubarContainer,this.toolbarContainer,this.sidebarContainer,this.formatContainer,this.diagramContainer,this.footerContainer,this.chromelessToolbar,this.hsplit,this.sidebarFooterContainer,this.layersDialog],a=0;a<c.length;a++)null!=c[a]&&null!=c[a].parentNode&&c[a].parentNode.removeChild(c[a])};function Sidebar(a,c){this.editorUi=a;this.container=c;this.palettes={};this.taglist={};this.showTooltips=!0;this.graph=a.createTemporaryGraph(this.editorUi.editor.graph.getStylesheet());this.graph.cellRenderer.minSvgStrokeWidth=this.minThumbStrokeWidth;this.graph.cellRenderer.antiAlias=this.thumbAntiAlias;this.graph.container.style.visibility="hidden";this.graph.foldingEnabled=!1;document.body.appendChild(this.graph.container);this.pointerUpHandler=mxUtils.bind(this,function(){this.showTooltips=
+f.bindControlShiftKey(35,function(){b.enterGroup()});f.bindShiftKey(36,function(){b.home()});f.bindKey(35,function(){b.refresh()});f.bindAction(107,!0,"zoomIn");f.bindAction(109,!0,"zoomOut");f.bindAction(80,!0,"print");f.bindAction(79,!0,"outline",!0);if(!this.editor.chromeless||this.editor.editable)f.bindControlKey(36,function(){b.isEnabled()&&b.foldCells(!0)}),f.bindControlKey(35,function(){b.isEnabled()&&b.foldCells(!1)}),f.bindControlKey(13,function(){m.ctrlEnter()}),f.bindAction(8,!1,"delete"),
+f.bindAction(8,!0,"deleteAll"),f.bindAction(46,!1,"delete"),f.bindAction(46,!0,"deleteAll"),f.bindAction(36,!1,"resetView"),f.bindAction(72,!0,"fitWindow",!0),f.bindAction(74,!0,"fitPage"),f.bindAction(74,!0,"fitTwoPages",!0),f.bindAction(48,!0,"customZoom"),f.bindAction(82,!0,"turn"),f.bindAction(82,!0,"clearDefaultStyle",!0),f.bindAction(83,!0,"save"),f.bindAction(83,!0,"saveAs",!0),f.bindAction(65,!0,"selectAll"),f.bindAction(65,!0,"selectNone",!0),f.bindAction(73,!0,"selectVertices",!0),f.bindAction(69,
+!0,"selectEdges",!0),f.bindAction(69,!0,"editStyle"),f.bindAction(66,!0,"bold"),f.bindAction(66,!0,"toBack",!0),f.bindAction(70,!0,"toFront",!0),f.bindAction(68,!0,"duplicate"),f.bindAction(68,!0,"setAsDefaultStyle",!0),f.bindAction(90,!0,"undo"),f.bindAction(89,!0,"autosize",!0),f.bindAction(88,!0,"cut"),f.bindAction(67,!0,"copy"),f.bindAction(86,!0,"paste"),f.bindAction(71,!0,"group"),f.bindAction(77,!0,"editData"),f.bindAction(71,!0,"grid",!0),f.bindAction(73,!0,"italic"),f.bindAction(76,!0,"lockUnlock"),
+f.bindAction(76,!0,"layers",!0),f.bindAction(80,!0,"formatPanel",!0),f.bindAction(85,!0,"underline"),f.bindAction(85,!0,"ungroup",!0),f.bindAction(190,!0,"superscript"),f.bindAction(188,!0,"subscript"),f.bindAction(9,!1,"indent",!0),f.bindKey(13,function(){b.isEnabled()&&b.startEditingAtCell()}),f.bindKey(113,function(){b.isEnabled()&&b.startEditingAtCell()});mxClient.IS_WIN?f.bindAction(89,!0,"redo"):f.bindAction(90,!0,"redo",!0);return f};
+EditorUi.prototype.destroy=function(){null!=this.editor&&(this.editor.destroy(),this.editor=null);null!=this.menubar&&(this.menubar.destroy(),this.menubar=null);null!=this.toolbar&&(this.toolbar.destroy(),this.toolbar=null);null!=this.sidebar&&(this.sidebar.destroy(),this.sidebar=null);null!=this.keyHandler&&(this.keyHandler.destroy(),this.keyHandler=null);null!=this.keydownHandler&&(mxEvent.removeListener(document,"keydown",this.keydownHandler),this.keydownHandler=null);null!=this.keyupHandler&&
+(mxEvent.removeListener(document,"keyup",this.keyupHandler),this.keyupHandler=null);null!=this.resizeHandler&&(mxEvent.removeListener(window,"resize",this.resizeHandler),this.resizeHandler=null);null!=this.gestureHandler&&(mxEvent.removeGestureListeners(document,this.gestureHandler),this.gestureHandler=null);null!=this.orientationChangeHandler&&(mxEvent.removeListener(window,"orientationchange",this.orientationChangeHandler),this.orientationChangeHandler=null);null!=this.scrollHandler&&(mxEvent.removeListener(window,
+"scroll",this.scrollHandler),this.scrollHandler=null);if(null!=this.destroyFunctions){for(var a=0;a<this.destroyFunctions.length;a++)this.destroyFunctions[a]();this.destroyFunctions=null}for(var c=[this.menubarContainer,this.toolbarContainer,this.sidebarContainer,this.formatContainer,this.diagramContainer,this.footerContainer,this.chromelessToolbar,this.hsplit,this.sidebarFooterContainer,this.layersDialog],a=0;a<c.length;a++)null!=c[a]&&null!=c[a].parentNode&&c[a].parentNode.removeChild(c[a])};function Sidebar(a,c){this.editorUi=a;this.container=c;this.palettes={};this.taglist={};this.showTooltips=!0;this.graph=a.createTemporaryGraph(this.editorUi.editor.graph.getStylesheet());this.graph.cellRenderer.minSvgStrokeWidth=this.minThumbStrokeWidth;this.graph.cellRenderer.antiAlias=this.thumbAntiAlias;this.graph.container.style.visibility="hidden";this.graph.foldingEnabled=!1;document.body.appendChild(this.graph.container);this.pointerUpHandler=mxUtils.bind(this,function(){this.showTooltips=
!0});mxEvent.addListener(document,mxClient.IS_POINTER?"pointerup":"mouseup",this.pointerUpHandler);this.pointerDownHandler=mxUtils.bind(this,function(){this.showTooltips=!1;this.hideTooltip()});mxEvent.addListener(document,mxClient.IS_POINTER?"pointerdown":"mousedown",this.pointerDownHandler);this.pointerMoveHandler=mxUtils.bind(this,function(a){for(a=mxEvent.getSource(a);null!=a;){if(a==this.currentElt)return;a=a.parentNode}this.hideTooltip()});mxEvent.addListener(document,mxClient.IS_POINTER?"pointermove":
"mousemove",this.pointerMoveHandler);this.pointerOutHandler=mxUtils.bind(this,function(a){null==a.toElement&&null==a.relatedTarget&&this.hideTooltip()});mxEvent.addListener(document,mxClient.IS_POINTER?"pointerout":"mouseout",this.pointerOutHandler);mxEvent.addListener(c,"scroll",mxUtils.bind(this,function(){this.showTooltips=!0;this.hideTooltip()}));this.init()}
Sidebar.prototype.init=function(){var a=STENCIL_PATH;this.addSearchPalette(!0);this.addGeneralPalette(!0);this.addMiscPalette(!1);this.addAdvancedPalette(!1);this.addBasicPalette(a);this.addStencilPalette("arrows",mxResources.get("arrows"),a+"/arrows.xml",";whiteSpace=wrap;html=1;fillColor=#ffffff;strokeColor=#000000;strokeWidth=2");this.addUmlPalette(!1);this.addBpmnPalette(a,!1);this.addStencilPalette("flowchart","Flowchart",a+"/flowchart.xml",";whiteSpace=wrap;html=1;fillColor=#ffffff;strokeColor=#000000;strokeWidth=2");
@@ -9075,7 +9075,7 @@ k=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});k.classNa
"print":"ok"),function(){a.hideDialog();c(!0)});x.className="geBtn gePrimaryBtn";m.appendChild(x);a.editor.cancelFirst||m.appendChild(k);g.appendChild(m);this.container=g};var E=ChangePageSetup.prototype.execute;ChangePageSetup.prototype.execute=function(){null==this.page&&(this.page=this.ui.currentPage);this.page!=this.ui.currentPage?null!=this.page.viewState&&(this.ignoreColor||(this.page.viewState.background=this.color),this.ignoreImage||(this.page.viewState.backgroundImage=this.image),null!=this.format&&
(this.page.viewState.pageFormat=this.format),null!=this.mathEnabled&&(this.page.viewState.mathEnabled=this.mathEnabled),null!=this.shadowVisible&&(this.page.viewState.shadowVisible=this.shadowVisible)):(E.apply(this,arguments),null!=this.mathEnabled&&this.mathEnabled!=this.ui.isMathEnabled()&&(this.ui.setMathEnabled(this.mathEnabled),this.mathEnabled=!this.mathEnabled),null!=this.shadowVisible&&this.shadowVisible!=this.ui.editor.graph.shadowVisible&&(this.ui.editor.graph.setShadowVisible(this.shadowVisible),
this.shadowVisible=!this.shadowVisible))};Editor.prototype.useCanvasForExport=!1;try{var H=document.createElement("canvas"),F=new Image;F.onload=function(){try{H.getContext("2d").drawImage(F,0,0);var a=H.toDataURL("image/png");Editor.prototype.useCanvasForExport=null!=a&&6<a.length}catch(K){}};F.src="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1px" height="1px" version="1.1"><foreignObject pointer-events="all" width="1" height="1"><div xmlns="http://www.w3.org/1999/xhtml"></div></foreignObject></svg>')))}catch(J){}})();
-(function(){var a=new mxObjectCodec(new ChangePageSetup,["ui","previousColor","previousImage","previousFormat"]);a.beforeDecode=function(a,c,b){b.ui=a.ui;return c};a.afterDecode=function(a,c,b){b.previousColor=b.color;b.previousImage=b.image;b.previousFormat=b.format;null!=b.foldingEnabled&&(b.foldingEnabled=!b.foldingEnabled);null!=b.mathEnabled&&(b.mathEnabled=!b.mathEnabled);null!=b.shadowVisible&&(b.shadowVisible=!b.shadowVisible);return b};mxCodecRegistry.register(a)})();(function(){EditorUi.VERSION="13.0.7";EditorUi.compactUi="atlas"!=uiTheme;mxGraphView.prototype.defaultDarkGridColor="#6e6e6e";"dark"==uiTheme&&(mxGraphView.prototype.gridColor=mxGraphView.prototype.defaultDarkGridColor);EditorUi.enableLogging="1"!=urlParams.stealth&&(/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname))&&"support.draw.io"!=window.location.hostname;EditorUi.drawHost=window.DRAWIO_BASE_URL;EditorUi.lastErrorMessage=null;EditorUi.ignoredAnonymizedChars=
+(function(){var a=new mxObjectCodec(new ChangePageSetup,["ui","previousColor","previousImage","previousFormat"]);a.beforeDecode=function(a,c,b){b.ui=a.ui;return c};a.afterDecode=function(a,c,b){b.previousColor=b.color;b.previousImage=b.image;b.previousFormat=b.format;null!=b.foldingEnabled&&(b.foldingEnabled=!b.foldingEnabled);null!=b.mathEnabled&&(b.mathEnabled=!b.mathEnabled);null!=b.shadowVisible&&(b.shadowVisible=!b.shadowVisible);return b};mxCodecRegistry.register(a)})();(function(){EditorUi.VERSION="13.0.8";EditorUi.compactUi="atlas"!=uiTheme;mxGraphView.prototype.defaultDarkGridColor="#6e6e6e";"dark"==uiTheme&&(mxGraphView.prototype.gridColor=mxGraphView.prototype.defaultDarkGridColor);EditorUi.enableLogging="1"!=urlParams.stealth&&(/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname))&&"support.draw.io"!=window.location.hostname;EditorUi.drawHost=window.DRAWIO_BASE_URL;EditorUi.lastErrorMessage=null;EditorUi.ignoredAnonymizedChars=
"\n\t`~!@#$%^&*()_+{}|:\"<>?-=[];'./,\n\t";EditorUi.templateFile=TEMPLATE_PATH+"/index.xml";EditorUi.cacheUrl="1"==urlParams.dev?"/cache":window.REALTIME_URL;null==EditorUi.cacheUrl&&"undefined"!==typeof DrawioFile&&(DrawioFile.SYNC="none");Editor.cacheTimeout=1E4;EditorUi.enablePlantUml=EditorUi.enableLogging;EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;EditorUi.enableDrafts=!mxClient.IS_CHROMEAPP&&isLocalStorage&&
!EditorUi.isElectronApp&&"0"!=urlParams.drafts;EditorUi.scratchpadHelpLink="https://desk.draw.io/support/solutions/articles/16000042367";EditorUi.defaultMermaidConfig={theme:"neutral",arrowMarkerAbsolute:!1,flowchart:{htmlLabels:!1},sequence:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,showSequenceNumbers:!1},gantt:{titleTopMargin:25,barHeight:20,barGap:4,
topPadding:50,leftPadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:4,axisFormat:"%Y-%m-%d"}};EditorUi.logError=function(a,b,c,e,f,k,l){k=null!=k?k:0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";if(EditorUi.enableLogging&&"1"!=urlParams.dev)try{if(a!=EditorUi.lastErrorMessage&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&
diff --git a/src/main/webapp/js/mxgraph/EditorUi.js b/src/main/webapp/js/mxgraph/EditorUi.js
index 82a3c26d..8b6dd663 100644
--- a/src/main/webapp/js/mxgraph/EditorUi.js
+++ b/src/main/webapp/js/mxgraph/EditorUi.js
@@ -3737,6 +3737,42 @@ EditorUi.prototype.hideDialog = function(cancel, isEsc)
};
/**
+ * Handles ctrl+enter keystroke to clone cells.
+ */
+EditorUi.prototype.ctrlEnter = function()
+{
+ var graph = this.editor.graph;
+
+ if (graph.isEnabled())
+ {
+ try
+ {
+ var cells = graph.getSelectionCells();
+ var lookup = new mxDictionary();
+ var newCells = [];
+
+ for (var i = 0; i < cells.length; i++)
+ {
+ // Clones table rows instead of cells
+ var cell = (graph.isTableCell(cells[i])) ? graph.model.getParent(cells[i]) : cells[i];
+
+ if (cell != null && !lookup.get(cell))
+ {
+ lookup.put(cell, true);
+ newCells.push(cell);
+ }
+ }
+
+ graph.setSelectionCells(graph.duplicateCells(newCells, false));
+ }
+ catch (e)
+ {
+ this.handleError(e);
+ }
+ }
+};
+
+/**
* Display a color dialog.
*/
EditorUi.prototype.pickColor = function(color, apply)
@@ -4526,20 +4562,7 @@ EditorUi.prototype.createKeyHandler = function(editor)
{
keyHandler.bindControlKey(36, function() { if (graph.isEnabled()) { graph.foldCells(true); }}); // Ctrl+Home
keyHandler.bindControlKey(35, function() { if (graph.isEnabled()) { graph.foldCells(false); }}); // Ctrl+End
- keyHandler.bindControlKey(13, function()
- {
- if (graph.isEnabled())
- {
- try
- {
- graph.setSelectionCells(graph.duplicateCells(graph.getSelectionCells(), false));
- }
- catch (e)
- {
- ui.handleError(e);
- }
- }
- }); // Ctrl+Enter
+ keyHandler.bindControlKey(13, function() { ui.ctrlEnter(); }); // Ctrl+Enter
keyHandler.bindAction(8, false, 'delete'); // Backspace
keyHandler.bindAction(8, true, 'deleteAll'); // Shift+Backspace
keyHandler.bindAction(46, false, 'delete'); // Delete
diff --git a/src/main/webapp/js/mxgraph/Graph.js b/src/main/webapp/js/mxgraph/Graph.js
index c1f0ec4e..1af6aa6c 100644
--- a/src/main/webapp/js/mxgraph/Graph.js
+++ b/src/main/webapp/js/mxgraph/Graph.js
@@ -4347,8 +4347,7 @@ Graph.prototype.createCrossFunctionalSwimlane = function(rowCount, colCount, w,
w = (w != null) ? w : 120;
h = (h != null) ? h : 120;
- var s = 'swimlane;html=1;whiteSpace=wrap;' +
- 'collapsible=0;recursiveResize=0;expand=0;';
+ var s = 'swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;';
var table = this.createVertex(null, null, '', 0, 0,
colCount * w, rowCount * h, s + 'containerType=table;container=0;dropTarget=0;' +
diff --git a/src/main/webapp/js/viewer.min.js b/src/main/webapp/js/viewer.min.js
index 13bbb52d..bab46722 100644
--- a/src/main/webapp/js/viewer.min.js
+++ b/src/main/webapp/js/viewer.min.js
@@ -2046,11 +2046,11 @@ Editor.prototype.setFilename=function(a){this.filename=a};
Editor.prototype.createUndoManager=function(){var a=this.graph,b=new mxUndoManager;this.undoListener=function(a,e){b.undoableEditHappened(e.getProperty("edit"))};var e=mxUtils.bind(this,function(a,b){this.undoListener.apply(this,arguments)});a.getModel().addListener(mxEvent.UNDO,e);a.getView().addListener(mxEvent.UNDO,e);e=function(d,b){var e=a.getSelectionCellsForChanges(b.getProperty("edit").changes,function(a){return!(a instanceof mxChildChange)});if(0<e.length){a.getModel();for(var k=[],c=0;c<
e.length;c++)null!=a.view.getState(e[c])&&k.push(e[c]);a.setSelectionCells(k)}};b.addListener(mxEvent.UNDO,e);b.addListener(mxEvent.REDO,e);return b};Editor.prototype.initStencilRegistry=function(){};Editor.prototype.destroy=function(){null!=this.graph&&(this.graph.destroy(),this.graph=null)};OpenFile=function(a){this.consumer=this.producer=null;this.done=a;this.args=null};OpenFile.prototype.setConsumer=function(a){this.consumer=a;this.execute()};
OpenFile.prototype.setData=function(){this.args=arguments;this.execute()};OpenFile.prototype.error=function(a){this.cancel(!0);mxUtils.alert(a)};OpenFile.prototype.execute=function(){null!=this.consumer&&null!=this.args&&(this.cancel(!1),this.consumer.apply(this,this.args))};OpenFile.prototype.cancel=function(a){null!=this.done&&this.done(null!=a?a:!0)};
-function Dialog(a,b,e,d,k,m,q,c,f,g,p){var l=0;mxClient.IS_VML&&(null==document.documentMode||8>document.documentMode)&&(l=80);e+=l;d+=l;var n=e,v=d,t=mxUtils.getDocumentSize();null!=window.innerHeight&&(t.height=window.innerHeight);var u=t.height,A=Math.max(1,Math.round((t.width-e-64)/2)),B=Math.max(1,Math.round((u-d-a.footerHeight)/3));mxClient.IS_QUIRKS||(b.style.maxHeight="100%");e=null!=document.body?Math.min(e,document.body.scrollWidth-64):e;d=Math.min(d,u-64);0<a.dialogs.length&&(this.zIndex+=
+function Dialog(a,b,e,d,k,l,q,c,f,g,p){var m=0;mxClient.IS_VML&&(null==document.documentMode||8>document.documentMode)&&(m=80);e+=m;d+=m;var n=e,v=d,t=mxUtils.getDocumentSize();null!=window.innerHeight&&(t.height=window.innerHeight);var u=t.height,A=Math.max(1,Math.round((t.width-e-64)/2)),B=Math.max(1,Math.round((u-d-a.footerHeight)/3));mxClient.IS_QUIRKS||(b.style.maxHeight="100%");e=null!=document.body?Math.min(e,document.body.scrollWidth-64):e;d=Math.min(d,u-64);0<a.dialogs.length&&(this.zIndex+=
2*a.dialogs.length);null==this.bg&&(this.bg=a.createDiv("background"),this.bg.style.position="absolute",this.bg.style.background=Dialog.backdropColor,this.bg.style.height=u+"px",this.bg.style.right="0px",this.bg.style.zIndex=this.zIndex-2,mxUtils.setOpacity(this.bg,this.bgOpacity),mxClient.IS_QUIRKS&&new mxDivResizer(this.bg));t=mxUtils.getDocumentScrollOrigin(document);this.bg.style.left=t.x+"px";this.bg.style.top=t.y+"px";A+=t.x;B+=t.y;k&&document.body.appendChild(this.bg);var D=a.createDiv(f?"geTransDialog":
-"geDialog");k=this.getPosition(A,B,e,d);A=k.x;B=k.y;D.style.width=e+"px";D.style.height=d+"px";D.style.left=A+"px";D.style.top=B+"px";D.style.zIndex=this.zIndex;D.appendChild(b);document.body.appendChild(D);!c&&b.clientHeight>D.clientHeight-64&&(b.style.overflowY="auto");if(m&&(m=document.createElement("img"),m.setAttribute("src",Dialog.prototype.closeImage),m.setAttribute("title",mxResources.get("close")),m.className="geDialogClose",m.style.top=B+14+"px",m.style.left=A+e+38-l+"px",m.style.zIndex=
-this.zIndex,mxEvent.addListener(m,"click",mxUtils.bind(this,function(){a.hideDialog(!0)})),document.body.appendChild(m),this.dialogImg=m,!p)){var C=!1;mxEvent.addGestureListeners(this.bg,mxUtils.bind(this,function(a){C=!0}),null,mxUtils.bind(this,function(c){C&&(a.hideDialog(!0),C=!1)}))}this.resizeListener=mxUtils.bind(this,function(){if(null!=g){var f=g();null!=f&&(n=e=f.w,v=d=f.h)}f=mxUtils.getDocumentSize();u=f.height;this.bg.style.height=u+"px";A=Math.max(1,Math.round((f.width-e-64)/2));B=Math.max(1,
-Math.round((u-d-a.footerHeight)/3));e=null!=document.body?Math.min(n,document.body.scrollWidth-64):n;d=Math.min(v,u-64);f=this.getPosition(A,B,e,d);A=f.x;B=f.y;D.style.left=A+"px";D.style.top=B+"px";D.style.width=e+"px";D.style.height=d+"px";!c&&b.clientHeight>D.clientHeight-64&&(b.style.overflowY="auto");null!=this.dialogImg&&(this.dialogImg.style.top=B+14+"px",this.dialogImg.style.left=A+e+38-l+"px")});mxEvent.addListener(window,"resize",this.resizeListener);this.onDialogClose=q;this.container=
+"geDialog");k=this.getPosition(A,B,e,d);A=k.x;B=k.y;D.style.width=e+"px";D.style.height=d+"px";D.style.left=A+"px";D.style.top=B+"px";D.style.zIndex=this.zIndex;D.appendChild(b);document.body.appendChild(D);!c&&b.clientHeight>D.clientHeight-64&&(b.style.overflowY="auto");if(l&&(l=document.createElement("img"),l.setAttribute("src",Dialog.prototype.closeImage),l.setAttribute("title",mxResources.get("close")),l.className="geDialogClose",l.style.top=B+14+"px",l.style.left=A+e+38-m+"px",l.style.zIndex=
+this.zIndex,mxEvent.addListener(l,"click",mxUtils.bind(this,function(){a.hideDialog(!0)})),document.body.appendChild(l),this.dialogImg=l,!p)){var C=!1;mxEvent.addGestureListeners(this.bg,mxUtils.bind(this,function(a){C=!0}),null,mxUtils.bind(this,function(c){C&&(a.hideDialog(!0),C=!1)}))}this.resizeListener=mxUtils.bind(this,function(){if(null!=g){var f=g();null!=f&&(n=e=f.w,v=d=f.h)}f=mxUtils.getDocumentSize();u=f.height;this.bg.style.height=u+"px";A=Math.max(1,Math.round((f.width-e-64)/2));B=Math.max(1,
+Math.round((u-d-a.footerHeight)/3));e=null!=document.body?Math.min(n,document.body.scrollWidth-64):n;d=Math.min(v,u-64);f=this.getPosition(A,B,e,d);A=f.x;B=f.y;D.style.left=A+"px";D.style.top=B+"px";D.style.width=e+"px";D.style.height=d+"px";!c&&b.clientHeight>D.clientHeight-64&&(b.style.overflowY="auto");null!=this.dialogImg&&(this.dialogImg.style.top=B+14+"px",this.dialogImg.style.left=A+e+38-m+"px")});mxEvent.addListener(window,"resize",this.resizeListener);this.onDialogClose=q;this.container=
D;a.editor.fireEvent(new mxEventObject("showDialog"))}Dialog.backdropColor="white";Dialog.prototype.zIndex=mxPopupMenu.prototype.zIndex-1;
Dialog.prototype.noColorImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyBpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBXaW5kb3dzIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkEzRDlBMUUwODYxMTExRTFCMzA4RDdDMjJBMEMxRDM3IiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkEzRDlBMUUxODYxMTExRTFCMzA4RDdDMjJBMEMxRDM3Ij4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6QTNEOUExREU4NjExMTFFMUIzMDhEN0MyMkEwQzFEMzciIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6QTNEOUExREY4NjExMTFFMUIzMDhEN0MyMkEwQzFEMzciLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5xh3fmAAAABlBMVEX////MzMw46qqDAAAAGElEQVR42mJggAJGKGAYIIGBth8KAAIMAEUQAIElnLuQAAAAAElFTkSuQmCC":IMAGE_PATH+
"/nocolor.png";Dialog.prototype.closeImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAJAQMAAADaX5RTAAAABlBMVEV7mr3///+wksspAAAAAnRSTlP/AOW3MEoAAAAdSURBVAgdY9jXwCDDwNDRwHCwgeExmASygSL7GgB12QiqNHZZIwAAAABJRU5ErkJggg==":IMAGE_PATH+"/close.png";
@@ -2060,47 +2060,47 @@ Dialog.prototype.lockedImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoA
"/locked.png";
Dialog.prototype.unlockedImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAMAAABhq6zVAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MzdDMDZCN0QxNzIxMTFFNUI0RTk5NTg4OTcyMUUyODEiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MzdDMDZCN0UxNzIxMTFFNUI0RTk5NTg4OTcyMUUyODEiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDozN0MwNkI3QjE3MjExMUU1QjRFOTk1ODg5NzIxRTI4MSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDozN0MwNkI3QzE3MjExMUU1QjRFOTk1ODg5NzIxRTI4MSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PkKMpVwAAAAYUExURZmZmbKysr+/v6ysrOXl5czMzLGxsf///zHN5lwAAAAIdFJOU/////////8A3oO9WQAAADxJREFUeNpUzFESACAEBNBVsfe/cZJU+8Mzs8CIABCidtfGOndnYsT40HDSiCcbPdoJo10o9aI677cpwACRoAF3dFNlswAAAABJRU5ErkJggg==":IMAGE_PATH+
"/unlocked.png";Dialog.prototype.bgOpacity=80;Dialog.prototype.getPosition=function(a,b){return new mxPoint(a,b)};Dialog.prototype.close=function(a,b){if(null!=this.onDialogClose){if(0==this.onDialogClose(a,b))return!1;this.onDialogClose=null}null!=this.dialogImg&&(this.dialogImg.parentNode.removeChild(this.dialogImg),this.dialogImg=null);null!=this.bg&&null!=this.bg.parentNode&&this.bg.parentNode.removeChild(this.bg);mxEvent.removeListener(window,"resize",this.resizeListener);this.container.parentNode.removeChild(this.container)};
-var ErrorDialog=function(a,b,e,d,k,m,q,c,f,g,p){f=null!=f?f:!0;var l=document.createElement("div");l.style.textAlign="center";if(null!=b){var n=document.createElement("div");n.style.padding="0px";n.style.margin="0px";n.style.fontSize="18px";n.style.paddingBottom="16px";n.style.marginBottom="10px";n.style.borderBottom="1px solid #c0c0c0";n.style.color="gray";n.style.whiteSpace="nowrap";n.style.textOverflow="ellipsis";n.style.overflow="hidden";mxUtils.write(n,b);n.setAttribute("title",b);l.appendChild(n)}b=
-document.createElement("div");b.style.lineHeight="1.2em";b.style.padding="6px";b.innerHTML=e;l.appendChild(b);e=document.createElement("div");e.style.marginTop="12px";e.style.textAlign="center";null!=m&&(b=mxUtils.button(mxResources.get("tryAgain"),function(){a.hideDialog();m()}),b.className="geBtn",e.appendChild(b),e.style.textAlign="center");null!=g&&(g=mxUtils.button(g,function(){null!=p&&p()}),g.className="geBtn",e.appendChild(g));var v=mxUtils.button(d,function(){f&&a.hideDialog();null!=k&&k()});
-v.className="geBtn";e.appendChild(v);null!=q&&(d=mxUtils.button(q,function(){f&&a.hideDialog();null!=c&&c()}),d.className="geBtn gePrimaryBtn",e.appendChild(d));this.init=function(){v.focus()};l.appendChild(e);this.container=l},PrintDialog=function(a,b){this.create(a,b)};
-PrintDialog.prototype.create=function(a){function b(a){var f=c.checked||g.checked,d=parseInt(l.value)/100;isNaN(d)&&(d=1,l.value="100%");var d=.75*d,b=e.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT,n=1/e.pageScale;if(f){var v=c.checked?1:parseInt(p.value);isNaN(v)||(n=mxUtils.getScaleForPageCount(v,e,b))}e.getGraphBounds();var m=v=0,b=mxRectangle.fromRectangle(b);b.width=Math.ceil(b.width*d);b.height=Math.ceil(b.height*d);n*=d;!f&&e.pageVisible?(d=e.getPageLayout(),v-=d.x*b.width,m-=d.y*b.height):
-f=!0;f=PrintDialog.createPrintPreview(e,n,b,0,v,m,f);f.open();a&&PrintDialog.printPreview(f)}var e=a.editor.graph,d,k,m=document.createElement("table");m.style.width="100%";m.style.height="100%";var q=document.createElement("tbody");d=document.createElement("tr");var c=document.createElement("input");c.setAttribute("type","checkbox");k=document.createElement("td");k.setAttribute("colspan","2");k.style.fontSize="10pt";k.appendChild(c);var f=document.createElement("span");mxUtils.write(f," "+mxResources.get("fitPage"));
+var ErrorDialog=function(a,b,e,d,k,l,q,c,f,g,p){f=null!=f?f:!0;var m=document.createElement("div");m.style.textAlign="center";if(null!=b){var n=document.createElement("div");n.style.padding="0px";n.style.margin="0px";n.style.fontSize="18px";n.style.paddingBottom="16px";n.style.marginBottom="10px";n.style.borderBottom="1px solid #c0c0c0";n.style.color="gray";n.style.whiteSpace="nowrap";n.style.textOverflow="ellipsis";n.style.overflow="hidden";mxUtils.write(n,b);n.setAttribute("title",b);m.appendChild(n)}b=
+document.createElement("div");b.style.lineHeight="1.2em";b.style.padding="6px";b.innerHTML=e;m.appendChild(b);e=document.createElement("div");e.style.marginTop="12px";e.style.textAlign="center";null!=l&&(b=mxUtils.button(mxResources.get("tryAgain"),function(){a.hideDialog();l()}),b.className="geBtn",e.appendChild(b),e.style.textAlign="center");null!=g&&(g=mxUtils.button(g,function(){null!=p&&p()}),g.className="geBtn",e.appendChild(g));var v=mxUtils.button(d,function(){f&&a.hideDialog();null!=k&&k()});
+v.className="geBtn";e.appendChild(v);null!=q&&(d=mxUtils.button(q,function(){f&&a.hideDialog();null!=c&&c()}),d.className="geBtn gePrimaryBtn",e.appendChild(d));this.init=function(){v.focus()};m.appendChild(e);this.container=m},PrintDialog=function(a,b){this.create(a,b)};
+PrintDialog.prototype.create=function(a){function b(a){var f=c.checked||g.checked,d=parseInt(m.value)/100;isNaN(d)&&(d=1,m.value="100%");var d=.75*d,b=e.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT,n=1/e.pageScale;if(f){var v=c.checked?1:parseInt(p.value);isNaN(v)||(n=mxUtils.getScaleForPageCount(v,e,b))}e.getGraphBounds();var l=v=0,b=mxRectangle.fromRectangle(b);b.width=Math.ceil(b.width*d);b.height=Math.ceil(b.height*d);n*=d;!f&&e.pageVisible?(d=e.getPageLayout(),v-=d.x*b.width,l-=d.y*b.height):
+f=!0;f=PrintDialog.createPrintPreview(e,n,b,0,v,l,f);f.open();a&&PrintDialog.printPreview(f)}var e=a.editor.graph,d,k,l=document.createElement("table");l.style.width="100%";l.style.height="100%";var q=document.createElement("tbody");d=document.createElement("tr");var c=document.createElement("input");c.setAttribute("type","checkbox");k=document.createElement("td");k.setAttribute("colspan","2");k.style.fontSize="10pt";k.appendChild(c);var f=document.createElement("span");mxUtils.write(f," "+mxResources.get("fitPage"));
k.appendChild(f);mxEvent.addListener(f,"click",function(a){c.checked=!c.checked;g.checked=!c.checked;mxEvent.consume(a)});mxEvent.addListener(c,"change",function(){g.checked=!c.checked});d.appendChild(k);q.appendChild(d);d=d.cloneNode(!1);var g=document.createElement("input");g.setAttribute("type","checkbox");k=document.createElement("td");k.style.fontSize="10pt";k.appendChild(g);f=document.createElement("span");mxUtils.write(f," "+mxResources.get("posterPrint")+":");k.appendChild(f);mxEvent.addListener(f,
"click",function(a){g.checked=!g.checked;c.checked=!g.checked;mxEvent.consume(a)});d.appendChild(k);var p=document.createElement("input");p.setAttribute("value","1");p.setAttribute("type","number");p.setAttribute("min","1");p.setAttribute("size","4");p.setAttribute("disabled","disabled");p.style.width="50px";k=document.createElement("td");k.style.fontSize="10pt";k.appendChild(p);mxUtils.write(k," "+mxResources.get("pages")+" (max)");d.appendChild(k);q.appendChild(d);mxEvent.addListener(g,"change",
-function(){g.checked?p.removeAttribute("disabled"):p.setAttribute("disabled","disabled");c.checked=!g.checked});d=d.cloneNode(!1);k=document.createElement("td");mxUtils.write(k,mxResources.get("pageScale")+":");d.appendChild(k);k=document.createElement("td");var l=document.createElement("input");l.setAttribute("value","100 %");l.setAttribute("size","5");l.style.width="50px";k.appendChild(l);d.appendChild(k);q.appendChild(d);d=document.createElement("tr");k=document.createElement("td");k.colSpan=2;
+function(){g.checked?p.removeAttribute("disabled"):p.setAttribute("disabled","disabled");c.checked=!g.checked});d=d.cloneNode(!1);k=document.createElement("td");mxUtils.write(k,mxResources.get("pageScale")+":");d.appendChild(k);k=document.createElement("td");var m=document.createElement("input");m.setAttribute("value","100 %");m.setAttribute("size","5");m.style.width="50px";k.appendChild(m);d.appendChild(k);q.appendChild(d);d=document.createElement("tr");k=document.createElement("td");k.colSpan=2;
k.style.paddingTop="20px";k.setAttribute("align","right");f=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});f.className="geBtn";a.editor.cancelFirst&&k.appendChild(f);if(PrintDialog.previewEnabled){var n=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();b(!1)});n.className="geBtn";k.appendChild(n)}n=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?"print":"ok"),function(){a.hideDialog();b(!0)});n.className="geBtn gePrimaryBtn";k.appendChild(n);a.editor.cancelFirst||
-k.appendChild(f);d.appendChild(k);q.appendChild(d);m.appendChild(q);this.container=m};PrintDialog.printPreview=function(a){try{if(null!=a.wnd){var b=function(){a.wnd.focus();a.wnd.print();a.wnd.close()};mxClient.IS_GC?window.setTimeout(b,500):b()}}catch(e){}};
-PrintDialog.createPrintPreview=function(a,b,e,d,k,m,q){b=new mxPrintPreview(a,b,e,d,k,m);b.title=mxResources.get("preview");b.printBackgroundImage=!0;b.autoOrigin=q;a=a.background;if(null==a||""==a||a==mxConstants.NONE)a="#ffffff";b.backgroundColor=a;var c=b.writeHead;b.writeHead=function(a){c.apply(this,arguments);a.writeln('<style type="text/css">');a.writeln("@media screen {");a.writeln(" body > div { padding:30px;box-sizing:content-box; }");a.writeln("}");a.writeln("</style>")};return b};
+k.appendChild(f);d.appendChild(k);q.appendChild(d);l.appendChild(q);this.container=l};PrintDialog.printPreview=function(a){try{if(null!=a.wnd){var b=function(){a.wnd.focus();a.wnd.print();a.wnd.close()};mxClient.IS_GC?window.setTimeout(b,500):b()}}catch(e){}};
+PrintDialog.createPrintPreview=function(a,b,e,d,k,l,q){b=new mxPrintPreview(a,b,e,d,k,l);b.title=mxResources.get("preview");b.printBackgroundImage=!0;b.autoOrigin=q;a=a.background;if(null==a||""==a||a==mxConstants.NONE)a="#ffffff";b.backgroundColor=a;var c=b.writeHead;b.writeHead=function(a){c.apply(this,arguments);a.writeln('<style type="text/css">');a.writeln("@media screen {");a.writeln(" body > div { padding:30px;box-sizing:content-box; }");a.writeln("}");a.writeln("</style>")};return b};
PrintDialog.previewEnabled=!0;
-var PageSetupDialog=function(a){function b(){null==p||p==mxConstants.NONE?(g.style.backgroundColor="",g.style.backgroundImage="url('"+Dialog.prototype.noColorImage+"')"):(g.style.backgroundColor=p,g.style.backgroundImage="")}function e(){null==v?(n.removeAttribute("title"),n.style.fontSize="",n.innerHTML=mxResources.get("change")+"..."):(n.setAttribute("title",v.src),n.style.fontSize="11px",n.innerHTML=v.src.substring(0,42)+"...")}var d=a.editor.graph,k,m,q=document.createElement("table");q.style.width=
-"100%";q.style.height="100%";var c=document.createElement("tbody");k=document.createElement("tr");m=document.createElement("td");m.style.verticalAlign="top";m.style.fontSize="10pt";mxUtils.write(m,mxResources.get("paperSize")+":");k.appendChild(m);m=document.createElement("td");m.style.verticalAlign="top";m.style.fontSize="10pt";var f=PageSetupDialog.addPageFormatPanel(m,"pagesetupdialog",d.pageFormat);k.appendChild(m);c.appendChild(k);k=document.createElement("tr");m=document.createElement("td");
-mxUtils.write(m,mxResources.get("background")+":");k.appendChild(m);m=document.createElement("td");m.style.whiteSpace="nowrap";document.createElement("input").setAttribute("type","text");var g=document.createElement("button");g.style.width="18px";g.style.height="18px";g.style.marginRight="20px";g.style.backgroundPosition="center center";g.style.backgroundRepeat="no-repeat";var p=d.background;b();mxEvent.addListener(g,"click",function(c){a.pickColor(p||"none",function(a){p=a;b()});mxEvent.consume(c)});
-m.appendChild(g);mxUtils.write(m,mxResources.get("gridSize")+":");var l=document.createElement("input");l.setAttribute("type","number");l.setAttribute("min","0");l.style.width="40px";l.style.marginLeft="6px";l.value=d.getGridSize();m.appendChild(l);mxEvent.addListener(l,"change",function(){var a=parseInt(l.value);l.value=Math.max(1,isNaN(a)?d.getGridSize():a)});k.appendChild(m);c.appendChild(k);k=document.createElement("tr");m=document.createElement("td");mxUtils.write(m,mxResources.get("image")+
-":");k.appendChild(m);m=document.createElement("td");var n=document.createElement("a");n.style.textDecoration="underline";n.style.cursor="pointer";n.style.color="#a0a0a0";var v=d.backgroundImage;mxEvent.addListener(n,"click",function(c){a.showBackgroundImageDialog(function(a){v=a;e()});mxEvent.consume(c)});e();m.appendChild(n);k.appendChild(m);c.appendChild(k);k=document.createElement("tr");m=document.createElement("td");m.colSpan=2;m.style.paddingTop="16px";m.setAttribute("align","right");var t=
-mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});t.className="geBtn";a.editor.cancelFirst&&m.appendChild(t);var u=mxUtils.button(mxResources.get("apply"),function(){a.hideDialog();d.gridSize!==l.value&&d.setGridSize(parseInt(l.value));var c=new ChangePageSetup(a,p,v,f.get());c.ignoreColor=d.background==p;c.ignoreImage=(null!=d.backgroundImage?d.backgroundImage.src:null)===(null!=v?v.src:null);d.pageFormat.width==c.previousFormat.width&&d.pageFormat.height==c.previousFormat.height&&
-c.ignoreColor&&c.ignoreImage||d.model.execute(c)});u.className="geBtn gePrimaryBtn";m.appendChild(u);a.editor.cancelFirst||m.appendChild(t);k.appendChild(m);c.appendChild(k);q.appendChild(c);this.container=q};
-PageSetupDialog.addPageFormatPanel=function(a,b,e,d){function k(a,d,b){if(b||l!=document.activeElement&&n!=document.activeElement){a=!1;for(d=0;d<t.length;d++)b=t[d],D?"custom"==b.key&&(c.value=b.key,D=!1):null!=b.format&&("a4"==b.key?826==e.width?(e=mxRectangle.fromRectangle(e),e.width=827):826==e.height&&(e=mxRectangle.fromRectangle(e),e.height=827):"a5"==b.key&&(584==e.width?(e=mxRectangle.fromRectangle(e),e.width=583):584==e.height&&(e=mxRectangle.fromRectangle(e),e.height=583)),e.width==b.format.width&&
-e.height==b.format.height?(c.value=b.key,m.setAttribute("checked","checked"),m.defaultChecked=!0,m.checked=!0,q.removeAttribute("checked"),q.defaultChecked=!1,q.checked=!1,a=!0):e.width==b.format.height&&e.height==b.format.width&&(c.value=b.key,m.removeAttribute("checked"),m.defaultChecked=!1,m.checked=!1,q.setAttribute("checked","checked"),q.defaultChecked=!0,a=q.checked=!0));a?(f.style.display="",p.style.display="none"):(l.value=e.width/100,n.value=e.height/100,m.setAttribute("checked","checked"),
-c.value="custom",f.style.display="none",p.style.display="")}}b="format-"+b;var m=document.createElement("input");m.setAttribute("name",b);m.setAttribute("type","radio");m.setAttribute("value","portrait");var q=document.createElement("input");q.setAttribute("name",b);q.setAttribute("type","radio");q.setAttribute("value","landscape");var c=document.createElement("select");c.style.marginBottom="8px";c.style.width="202px";var f=document.createElement("div");f.style.marginLeft="4px";f.style.width="210px";
-f.style.height="24px";m.style.marginRight="6px";f.appendChild(m);b=document.createElement("span");b.style.maxWidth="100px";mxUtils.write(b,mxResources.get("portrait"));f.appendChild(b);q.style.marginLeft="10px";q.style.marginRight="6px";f.appendChild(q);var g=document.createElement("span");g.style.width="100px";mxUtils.write(g,mxResources.get("landscape"));f.appendChild(g);var p=document.createElement("div");p.style.marginLeft="4px";p.style.width="210px";p.style.height="24px";var l=document.createElement("input");
-l.setAttribute("size","7");l.style.textAlign="right";p.appendChild(l);mxUtils.write(p," in x ");var n=document.createElement("input");n.setAttribute("size","7");n.style.textAlign="right";p.appendChild(n);mxUtils.write(p," in");f.style.display="none";p.style.display="none";for(var v={},t=PageSetupDialog.getFormats(),u=0;u<t.length;u++){var A=t[u];v[A.key]=A;var B=document.createElement("option");B.setAttribute("value",A.key);mxUtils.write(B,A.title);c.appendChild(B)}var D=!1;k();a.appendChild(c);mxUtils.br(a);
-a.appendChild(f);a.appendChild(p);var C=e,x=function(a,b){var g=v[c.value];null!=g.format?(l.value=g.format.width/100,n.value=g.format.height/100,p.style.display="none",f.style.display=""):(f.style.display="none",p.style.display="");g=parseFloat(l.value);if(isNaN(g)||0>=g)l.value=e.width/100;g=parseFloat(n.value);if(isNaN(g)||0>=g)n.value=e.height/100;g=new mxRectangle(0,0,Math.floor(100*parseFloat(l.value)),Math.floor(100*parseFloat(n.value)));"custom"!=c.value&&q.checked&&(g=new mxRectangle(0,0,
-g.height,g.width));b&&D||g.width==C.width&&g.height==C.height||(C=g,null!=d&&d(C))};mxEvent.addListener(b,"click",function(a){m.checked=!0;x(a);mxEvent.consume(a)});mxEvent.addListener(g,"click",function(a){q.checked=!0;x(a);mxEvent.consume(a)});mxEvent.addListener(l,"blur",x);mxEvent.addListener(l,"click",x);mxEvent.addListener(n,"blur",x);mxEvent.addListener(n,"click",x);mxEvent.addListener(q,"change",x);mxEvent.addListener(m,"change",x);mxEvent.addListener(c,"change",function(a){D="custom"==c.value;
-x(a,!0)});x();return{set:function(a){e=a;k(null,null,!0)},get:function(){return C},widthInput:l,heightInput:n}};
+var PageSetupDialog=function(a){function b(){null==p||p==mxConstants.NONE?(g.style.backgroundColor="",g.style.backgroundImage="url('"+Dialog.prototype.noColorImage+"')"):(g.style.backgroundColor=p,g.style.backgroundImage="")}function e(){null==v?(n.removeAttribute("title"),n.style.fontSize="",n.innerHTML=mxResources.get("change")+"..."):(n.setAttribute("title",v.src),n.style.fontSize="11px",n.innerHTML=v.src.substring(0,42)+"...")}var d=a.editor.graph,k,l,q=document.createElement("table");q.style.width=
+"100%";q.style.height="100%";var c=document.createElement("tbody");k=document.createElement("tr");l=document.createElement("td");l.style.verticalAlign="top";l.style.fontSize="10pt";mxUtils.write(l,mxResources.get("paperSize")+":");k.appendChild(l);l=document.createElement("td");l.style.verticalAlign="top";l.style.fontSize="10pt";var f=PageSetupDialog.addPageFormatPanel(l,"pagesetupdialog",d.pageFormat);k.appendChild(l);c.appendChild(k);k=document.createElement("tr");l=document.createElement("td");
+mxUtils.write(l,mxResources.get("background")+":");k.appendChild(l);l=document.createElement("td");l.style.whiteSpace="nowrap";document.createElement("input").setAttribute("type","text");var g=document.createElement("button");g.style.width="18px";g.style.height="18px";g.style.marginRight="20px";g.style.backgroundPosition="center center";g.style.backgroundRepeat="no-repeat";var p=d.background;b();mxEvent.addListener(g,"click",function(c){a.pickColor(p||"none",function(a){p=a;b()});mxEvent.consume(c)});
+l.appendChild(g);mxUtils.write(l,mxResources.get("gridSize")+":");var m=document.createElement("input");m.setAttribute("type","number");m.setAttribute("min","0");m.style.width="40px";m.style.marginLeft="6px";m.value=d.getGridSize();l.appendChild(m);mxEvent.addListener(m,"change",function(){var a=parseInt(m.value);m.value=Math.max(1,isNaN(a)?d.getGridSize():a)});k.appendChild(l);c.appendChild(k);k=document.createElement("tr");l=document.createElement("td");mxUtils.write(l,mxResources.get("image")+
+":");k.appendChild(l);l=document.createElement("td");var n=document.createElement("a");n.style.textDecoration="underline";n.style.cursor="pointer";n.style.color="#a0a0a0";var v=d.backgroundImage;mxEvent.addListener(n,"click",function(c){a.showBackgroundImageDialog(function(a){v=a;e()});mxEvent.consume(c)});e();l.appendChild(n);k.appendChild(l);c.appendChild(k);k=document.createElement("tr");l=document.createElement("td");l.colSpan=2;l.style.paddingTop="16px";l.setAttribute("align","right");var t=
+mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});t.className="geBtn";a.editor.cancelFirst&&l.appendChild(t);var u=mxUtils.button(mxResources.get("apply"),function(){a.hideDialog();d.gridSize!==m.value&&d.setGridSize(parseInt(m.value));var c=new ChangePageSetup(a,p,v,f.get());c.ignoreColor=d.background==p;c.ignoreImage=(null!=d.backgroundImage?d.backgroundImage.src:null)===(null!=v?v.src:null);d.pageFormat.width==c.previousFormat.width&&d.pageFormat.height==c.previousFormat.height&&
+c.ignoreColor&&c.ignoreImage||d.model.execute(c)});u.className="geBtn gePrimaryBtn";l.appendChild(u);a.editor.cancelFirst||l.appendChild(t);k.appendChild(l);c.appendChild(k);q.appendChild(c);this.container=q};
+PageSetupDialog.addPageFormatPanel=function(a,b,e,d){function k(a,d,b){if(b||m!=document.activeElement&&n!=document.activeElement){a=!1;for(d=0;d<t.length;d++)b=t[d],D?"custom"==b.key&&(c.value=b.key,D=!1):null!=b.format&&("a4"==b.key?826==e.width?(e=mxRectangle.fromRectangle(e),e.width=827):826==e.height&&(e=mxRectangle.fromRectangle(e),e.height=827):"a5"==b.key&&(584==e.width?(e=mxRectangle.fromRectangle(e),e.width=583):584==e.height&&(e=mxRectangle.fromRectangle(e),e.height=583)),e.width==b.format.width&&
+e.height==b.format.height?(c.value=b.key,l.setAttribute("checked","checked"),l.defaultChecked=!0,l.checked=!0,q.removeAttribute("checked"),q.defaultChecked=!1,q.checked=!1,a=!0):e.width==b.format.height&&e.height==b.format.width&&(c.value=b.key,l.removeAttribute("checked"),l.defaultChecked=!1,l.checked=!1,q.setAttribute("checked","checked"),q.defaultChecked=!0,a=q.checked=!0));a?(f.style.display="",p.style.display="none"):(m.value=e.width/100,n.value=e.height/100,l.setAttribute("checked","checked"),
+c.value="custom",f.style.display="none",p.style.display="")}}b="format-"+b;var l=document.createElement("input");l.setAttribute("name",b);l.setAttribute("type","radio");l.setAttribute("value","portrait");var q=document.createElement("input");q.setAttribute("name",b);q.setAttribute("type","radio");q.setAttribute("value","landscape");var c=document.createElement("select");c.style.marginBottom="8px";c.style.width="202px";var f=document.createElement("div");f.style.marginLeft="4px";f.style.width="210px";
+f.style.height="24px";l.style.marginRight="6px";f.appendChild(l);b=document.createElement("span");b.style.maxWidth="100px";mxUtils.write(b,mxResources.get("portrait"));f.appendChild(b);q.style.marginLeft="10px";q.style.marginRight="6px";f.appendChild(q);var g=document.createElement("span");g.style.width="100px";mxUtils.write(g,mxResources.get("landscape"));f.appendChild(g);var p=document.createElement("div");p.style.marginLeft="4px";p.style.width="210px";p.style.height="24px";var m=document.createElement("input");
+m.setAttribute("size","7");m.style.textAlign="right";p.appendChild(m);mxUtils.write(p," in x ");var n=document.createElement("input");n.setAttribute("size","7");n.style.textAlign="right";p.appendChild(n);mxUtils.write(p," in");f.style.display="none";p.style.display="none";for(var v={},t=PageSetupDialog.getFormats(),u=0;u<t.length;u++){var A=t[u];v[A.key]=A;var B=document.createElement("option");B.setAttribute("value",A.key);mxUtils.write(B,A.title);c.appendChild(B)}var D=!1;k();a.appendChild(c);mxUtils.br(a);
+a.appendChild(f);a.appendChild(p);var C=e,x=function(a,b){var g=v[c.value];null!=g.format?(m.value=g.format.width/100,n.value=g.format.height/100,p.style.display="none",f.style.display=""):(f.style.display="none",p.style.display="");g=parseFloat(m.value);if(isNaN(g)||0>=g)m.value=e.width/100;g=parseFloat(n.value);if(isNaN(g)||0>=g)n.value=e.height/100;g=new mxRectangle(0,0,Math.floor(100*parseFloat(m.value)),Math.floor(100*parseFloat(n.value)));"custom"!=c.value&&q.checked&&(g=new mxRectangle(0,0,
+g.height,g.width));b&&D||g.width==C.width&&g.height==C.height||(C=g,null!=d&&d(C))};mxEvent.addListener(b,"click",function(a){l.checked=!0;x(a);mxEvent.consume(a)});mxEvent.addListener(g,"click",function(a){q.checked=!0;x(a);mxEvent.consume(a)});mxEvent.addListener(m,"blur",x);mxEvent.addListener(m,"click",x);mxEvent.addListener(n,"blur",x);mxEvent.addListener(n,"click",x);mxEvent.addListener(q,"change",x);mxEvent.addListener(l,"change",x);mxEvent.addListener(c,"change",function(a){D="custom"==c.value;
+x(a,!0)});x();return{set:function(a){e=a;k(null,null,!0)},get:function(){return C},widthInput:m,heightInput:n}};
PageSetupDialog.getFormats=function(){return[{key:"letter",title:'US-Letter (8,5" x 11")',format:mxConstants.PAGE_FORMAT_LETTER_PORTRAIT},{key:"legal",title:'US-Legal (8,5" x 14")',format:new mxRectangle(0,0,850,1400)},{key:"tabloid",title:'US-Tabloid (11" x 17")',format:new mxRectangle(0,0,1100,1700)},{key:"executive",title:'US-Executive (7" x 10")',format:new mxRectangle(0,0,700,1E3)},{key:"a0",title:"A0 (841 mm x 1189 mm)",format:new mxRectangle(0,0,3300,4681)},{key:"a1",title:"A1 (594 mm x 841 mm)",
format:new mxRectangle(0,0,2339,3300)},{key:"a2",title:"A2 (420 mm x 594 mm)",format:new mxRectangle(0,0,1654,2336)},{key:"a3",title:"A3 (297 mm x 420 mm)",format:new mxRectangle(0,0,1169,1654)},{key:"a4",title:"A4 (210 mm x 297 mm)",format:mxConstants.PAGE_FORMAT_A4_PORTRAIT},{key:"a5",title:"A5 (148 mm x 210 mm)",format:new mxRectangle(0,0,583,827)},{key:"a6",title:"A6 (105 mm x 148 mm)",format:new mxRectangle(0,0,413,583)},{key:"a7",title:"A7 (74 mm x 105 mm)",format:new mxRectangle(0,0,291,413)},
{key:"b4",title:"B4 (250 mm x 353 mm)",format:new mxRectangle(0,0,980,1390)},{key:"b5",title:"B5 (176 mm x 250 mm)",format:new mxRectangle(0,0,690,980)},{key:"16-9",title:"16:9 (1600 x 900)",format:new mxRectangle(0,0,1600,900)},{key:"16-10",title:"16:10 (1920 x 1200)",format:new mxRectangle(0,0,1920,1200)},{key:"4-3",title:"4:3 (1600 x 1200)",format:new mxRectangle(0,0,1600,1200)},{key:"custom",title:mxResources.get("custom"),format:null}]};
-var FilenameDialog=function(a,b,e,d,k,m,q,c,f,g,p,l){f=null!=f?f:!0;var n,v,t=document.createElement("table"),u=document.createElement("tbody");t.style.marginTop="8px";n=document.createElement("tr");v=document.createElement("td");v.style.whiteSpace="nowrap";v.style.fontSize="10pt";v.style.width=p?"80px":"120px";mxUtils.write(v,(k||mxResources.get("filename"))+":");n.appendChild(v);var A=document.createElement("input");A.setAttribute("value",b||"");A.style.marginLeft="4px";A.style.width=null!=l?l+
-"px":"180px";var B=mxUtils.button(e,function(){if(null==m||m(A.value))f&&a.hideDialog(),d(A.value)});B.className="geBtn gePrimaryBtn";this.init=function(){if(null!=k||null==q)if(A.focus(),mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode||mxClient.IS_QUIRKS?A.select():document.execCommand("selectAll",!1,null),Graph.fileSupport){var a=t.parentNode;if(null!=a){var c=null;mxEvent.addListener(a,"dragleave",function(a){null!=c&&(c.style.backgroundColor="",c=null);a.stopPropagation();a.preventDefault()});
+var FilenameDialog=function(a,b,e,d,k,l,q,c,f,g,p,m){f=null!=f?f:!0;var n,v,t=document.createElement("table"),u=document.createElement("tbody");t.style.marginTop="8px";n=document.createElement("tr");v=document.createElement("td");v.style.whiteSpace="nowrap";v.style.fontSize="10pt";v.style.width=p?"80px":"120px";mxUtils.write(v,(k||mxResources.get("filename"))+":");n.appendChild(v);var A=document.createElement("input");A.setAttribute("value",b||"");A.style.marginLeft="4px";A.style.width=null!=m?m+
+"px":"180px";var B=mxUtils.button(e,function(){if(null==l||l(A.value))f&&a.hideDialog(),d(A.value)});B.className="geBtn gePrimaryBtn";this.init=function(){if(null!=k||null==q)if(A.focus(),mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode||mxClient.IS_QUIRKS?A.select():document.execCommand("selectAll",!1,null),Graph.fileSupport){var a=t.parentNode;if(null!=a){var c=null;mxEvent.addListener(a,"dragleave",function(a){null!=c&&(c.style.backgroundColor="",c=null);a.stopPropagation();a.preventDefault()});
mxEvent.addListener(a,"dragover",mxUtils.bind(this,function(a){null==c&&(!mxClient.IS_IE||10<document.documentMode)&&(c=A,c.style.backgroundColor="#ebf2f9");a.stopPropagation();a.preventDefault()}));mxEvent.addListener(a,"drop",mxUtils.bind(this,function(a){null!=c&&(c.style.backgroundColor="",c=null);0<=mxUtils.indexOf(a.dataTransfer.types,"text/uri-list")&&(A.value=decodeURIComponent(a.dataTransfer.getData("text/uri-list")),B.click());a.stopPropagation();a.preventDefault()}))}}};v=document.createElement("td");
-v.style.whiteSpace="nowrap";v.appendChild(A);n.appendChild(v);if(null!=k||null==q)u.appendChild(n),null!=p&&(null!=a.editor.diagramFileTypes&&(n=FilenameDialog.createFileTypes(a,A,a.editor.diagramFileTypes),n.style.marginLeft="6px",n.style.width="74px",v.appendChild(n),A.style.width=null!=l?l-40+"px":"140px"),v.appendChild(FilenameDialog.createTypeHint(a,A,p)));null!=q&&(n=document.createElement("tr"),v=document.createElement("td"),v.colSpan=2,v.appendChild(q),n.appendChild(v),u.appendChild(n));n=
-document.createElement("tr");v=document.createElement("td");v.colSpan=2;v.style.paddingTop="20px";v.style.whiteSpace="nowrap";v.setAttribute("align","right");p=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog();null!=g&&g()});p.className="geBtn";a.editor.cancelFirst&&v.appendChild(p);null!=c&&(l=mxUtils.button(mxResources.get("help"),function(){a.editor.graph.openLink(c)}),l.className="geBtn",v.appendChild(l));mxEvent.addListener(A,"keypress",function(a){13==a.keyCode&&B.click()});
+v.style.whiteSpace="nowrap";v.appendChild(A);n.appendChild(v);if(null!=k||null==q)u.appendChild(n),null!=p&&(null!=a.editor.diagramFileTypes&&(n=FilenameDialog.createFileTypes(a,A,a.editor.diagramFileTypes),n.style.marginLeft="6px",n.style.width="74px",v.appendChild(n),A.style.width=null!=m?m-40+"px":"140px"),v.appendChild(FilenameDialog.createTypeHint(a,A,p)));null!=q&&(n=document.createElement("tr"),v=document.createElement("td"),v.colSpan=2,v.appendChild(q),n.appendChild(v),u.appendChild(n));n=
+document.createElement("tr");v=document.createElement("td");v.colSpan=2;v.style.paddingTop="20px";v.style.whiteSpace="nowrap";v.setAttribute("align","right");p=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog();null!=g&&g()});p.className="geBtn";a.editor.cancelFirst&&v.appendChild(p);null!=c&&(m=mxUtils.button(mxResources.get("help"),function(){a.editor.graph.openLink(c)}),m.className="geBtn",v.appendChild(m));mxEvent.addListener(A,"keypress",function(a){13==a.keyCode&&B.click()});
v.appendChild(B);a.editor.cancelFirst||v.appendChild(p);n.appendChild(v);u.appendChild(n);t.appendChild(u);this.container=t};FilenameDialog.filenameHelpLink=null;
FilenameDialog.createTypeHint=function(a,b,e){var d=document.createElement("img");d.style.cssText="vertical-align:top;height:16px;width:16px;margin-left:4px;background-repeat:no-repeat;background-position:center bottom;cursor:pointer;";mxUtils.setOpacity(d,70);var k=function(){d.setAttribute("src",Editor.helpImage);d.setAttribute("title",mxResources.get("help"));for(var a=0;a<e.length;a++)if(0<e[a].ext.length&&b.value.toLowerCase().substring(b.value.length-e[a].ext.length-1)=="."+e[a].ext){d.setAttribute("src",
mxClient.imageBasePath+"/warning.png");d.setAttribute("title",mxResources.get(e[a].title));break}};mxEvent.addListener(b,"keyup",k);mxEvent.addListener(b,"change",k);mxEvent.addListener(d,"click",function(b){var e=d.getAttribute("title");d.getAttribute("src")==Editor.helpImage?a.editor.graph.openLink(FilenameDialog.filenameHelpLink):""!=e&&a.showError(null,e,mxResources.get("help"),function(){a.editor.graph.openLink(FilenameDialog.filenameHelpLink)},null,mxResources.get("ok"),null,null,null,340,90);
mxEvent.consume(b)});k();return d};
-FilenameDialog.createFileTypes=function(a,b,e){var d=document.createElement("select");for(a=0;a<e.length;a++){var k=document.createElement("option");k.setAttribute("value",a);mxUtils.write(k,mxResources.get(e[a].description)+" (."+e[a].extension+")");d.appendChild(k)}mxEvent.addListener(d,"change",function(a){a=e[d.value].extension;var m=b.value.lastIndexOf(".");0<m?(a=e[d.value].extension,b.value=b.value.substring(0,m+1)+a):b.value=b.value+"."+a;"createEvent"in document?(a=document.createEvent("HTMLEvents"),
-a.initEvent("change",!1,!0),b.dispatchEvent(a)):b.fireEvent("onchange")});a=function(a){var m=b.value.lastIndexOf(".");a=0;if(0<m)for(var m=b.value.toLowerCase().substring(m+1),c=0;c<e.length;c++)if(m==e[c].extension){a=c;break}d.value=a};mxEvent.addListener(b,"change",a);mxEvent.addListener(b,"keyup",a);a();return d};
+FilenameDialog.createFileTypes=function(a,b,e){var d=document.createElement("select");for(a=0;a<e.length;a++){var k=document.createElement("option");k.setAttribute("value",a);mxUtils.write(k,mxResources.get(e[a].description)+" (."+e[a].extension+")");d.appendChild(k)}mxEvent.addListener(d,"change",function(a){a=e[d.value].extension;var l=b.value.lastIndexOf(".");0<l?(a=e[d.value].extension,b.value=b.value.substring(0,l+1)+a):b.value=b.value+"."+a;"createEvent"in document?(a=document.createEvent("HTMLEvents"),
+a.initEvent("change",!1,!0),b.dispatchEvent(a)):b.fireEvent("onchange")});a=function(a){var l=b.value.lastIndexOf(".");a=0;if(0<l)for(var l=b.value.toLowerCase().substring(l+1),c=0;c<e.length;c++)if(l==e[c].extension){a=c;break}d.value=a};mxEvent.addListener(b,"change",a);mxEvent.addListener(b,"keyup",a);a();return d};
(function(){mxGraphView.prototype.validateBackgroundPage=function(){var a=this.graph;if(null!=a.container&&!a.transparentBackground){if(a.pageVisible){var f=this.getBackgroundPageBounds();if(null==this.backgroundPageShape){for(var d=a.container.firstChild;null!=d&&d.nodeType!=mxConstants.NODETYPE_ELEMENT;)d=d.nextSibling;null!=d&&(this.backgroundPageShape=this.createBackgroundPageShape(f),this.backgroundPageShape.scale=1,this.backgroundPageShape.isShadow=!mxClient.IS_QUIRKS,this.backgroundPageShape.dialect=
mxConstants.DIALECT_STRICTHTML,this.backgroundPageShape.init(a.container),d.style.position="absolute",a.container.insertBefore(this.backgroundPageShape.node,d),this.backgroundPageShape.redraw(),this.backgroundPageShape.node.className="geBackgroundPage",mxEvent.addListener(this.backgroundPageShape.node,"dblclick",mxUtils.bind(this,function(c){a.dblClick(c)})),mxEvent.addGestureListeners(this.backgroundPageShape.node,mxUtils.bind(this,function(c){a.fireMouseEvent(mxEvent.MOUSE_DOWN,new mxMouseEvent(c))}),
mxUtils.bind(this,function(c){null!=a.tooltipHandler&&a.tooltipHandler.isHideOnHover()&&a.tooltipHandler.hide();a.isMouseDown&&!mxEvent.isConsumed(c)&&a.fireMouseEvent(mxEvent.MOUSE_MOVE,new mxMouseEvent(c))}),mxUtils.bind(this,function(c){a.fireMouseEvent(mxEvent.MOUSE_UP,new mxMouseEvent(c))})))}else this.backgroundPageShape.scale=1,this.backgroundPageShape.bounds=f,this.backgroundPageShape.redraw()}else null!=this.backgroundPageShape&&(this.backgroundPageShape.destroy(),this.backgroundPageShape=
@@ -2109,33 +2109,33 @@ b="url("+this.gridImage+")";var n=d=0;null!=a.view.backgroundPageShape&&(n=this.
f,a.container.className="geDiagramContainer geDiagramBackdrop",d.style.backgroundImage="none",d.style.backgroundColor=""):(a.container.className="geDiagramContainer",d.style.backgroundPosition=e,d.style.backgroundColor=f,d.style.backgroundImage=b)};mxGraphView.prototype.createSvgGrid=function(a){for(var c=this.graph.gridSize*this.scale;c<this.minGridSize;)c*=2;for(var d=this.gridSteps*c,b=[],e=1;e<this.gridSteps;e++){var n=e*c;b.push("M 0 "+n+" L "+d+" "+n+" M "+n+" 0 L "+n+" "+d)}return'<svg width="'+
d+'" height="'+d+'" xmlns="'+mxConstants.NS_SVG+'"><defs><pattern id="grid" width="'+d+'" height="'+d+'" patternUnits="userSpaceOnUse"><path d="'+b.join(" ")+'" fill="none" stroke="'+a+'" opacity="0.2" stroke-width="1"/><path d="M '+d+" 0 L 0 0 0 "+d+'" fill="none" stroke="'+a+'" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(#grid)"/></svg>'};var a=mxGraph.prototype.panGraph;mxGraph.prototype.panGraph=function(c,f){a.apply(this,arguments);if(null!=this.shiftPreview1){var d=
this.view.canvas;null!=d.ownerSVGElement&&(d=d.ownerSVGElement);var b=this.gridSize*this.view.scale*this.view.gridSteps,b=-Math.round(b-mxUtils.mod(this.view.translate.x*this.view.scale+c,b))+"px "+-Math.round(b-mxUtils.mod(this.view.translate.y*this.view.scale+f,b))+"px";d.style.backgroundPosition=b}};mxGraph.prototype.updatePageBreaks=function(a,f,d){var c=this.view.scale,b=this.view.translate,g=this.pageFormat,e=c*this.pageScale,t=this.view.getBackgroundPageBounds();f=t.width;d=t.height;var u=
-new mxRectangle(c*b.x,c*b.y,g.width*e,g.height*e),m=(a=a&&Math.min(u.width,u.height)>this.minPageBreakDist)?Math.ceil(d/u.height)-1:0,k=a?Math.ceil(f/u.width)-1:0,q=t.x+f,C=t.y+d;null==this.horizontalPageBreaks&&0<m&&(this.horizontalPageBreaks=[]);null==this.verticalPageBreaks&&0<k&&(this.verticalPageBreaks=[]);a=mxUtils.bind(this,function(a){if(null!=a){for(var c=a==this.horizontalPageBreaks?m:k,f=0;f<=c;f++){var d=a==this.horizontalPageBreaks?[new mxPoint(Math.round(t.x),Math.round(t.y+(f+1)*u.height)),
+new mxRectangle(c*b.x,c*b.y,g.width*e,g.height*e),l=(a=a&&Math.min(u.width,u.height)>this.minPageBreakDist)?Math.ceil(d/u.height)-1:0,k=a?Math.ceil(f/u.width)-1:0,q=t.x+f,C=t.y+d;null==this.horizontalPageBreaks&&0<l&&(this.horizontalPageBreaks=[]);null==this.verticalPageBreaks&&0<k&&(this.verticalPageBreaks=[]);a=mxUtils.bind(this,function(a){if(null!=a){for(var c=a==this.horizontalPageBreaks?l:k,f=0;f<=c;f++){var d=a==this.horizontalPageBreaks?[new mxPoint(Math.round(t.x),Math.round(t.y+(f+1)*u.height)),
new mxPoint(Math.round(q),Math.round(t.y+(f+1)*u.height))]:[new mxPoint(Math.round(t.x+(f+1)*u.width),Math.round(t.y)),new mxPoint(Math.round(t.x+(f+1)*u.width),Math.round(C))];null!=a[f]?(a[f].points=d,a[f].redraw()):(d=new mxPolyline(d,this.pageBreakColor),d.dialect=this.dialect,d.isDashed=this.pageBreakDashed,d.pointerEvents=!1,d.init(this.view.backgroundPane),d.redraw(),a[f]=d)}for(f=c;f<a.length;f++)a[f].destroy();a.splice(c,a.length-c)}});a(this.horizontalPageBreaks);a(this.verticalPageBreaks)};
var b=mxGraphHandler.prototype.shouldRemoveCellsFromParent;mxGraphHandler.prototype.shouldRemoveCellsFromParent=function(a,f,d){for(var c=0;c<f.length;c++)if(this.graph.getModel().isVertex(f[c])){var g=this.graph.getCellGeometry(f[c]);if(null!=g&&g.relative)return!1}return b.apply(this,arguments)};var e=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var a=e.apply(this,arguments);a.intersects=mxUtils.bind(this,function(c,d){return this.isConnecting()?
!0:mxCellMarker.prototype.intersects.apply(a,arguments)});return a};mxGraphView.prototype.createBackgroundPageShape=function(a){return new mxRectangleShape(a,"#ffffff",this.graph.defaultPageBorderColor)};mxGraphView.prototype.getBackgroundPageBounds=function(){var a=this.getGraphBounds(),f=0<a.width?a.x/this.scale-this.translate.x:0,d=0<a.height?a.y/this.scale-this.translate.y:0,b=this.graph.pageFormat,e=this.graph.pageScale,n=b.width*e,b=b.height*e,e=Math.floor(Math.min(0,f)/n),v=Math.floor(Math.min(0,
d)/b);return new mxRectangle(this.scale*(this.translate.x+e*n),this.scale*(this.translate.y+v*b),this.scale*(Math.ceil(Math.max(1,f+a.width/this.scale)/n)-e)*n,this.scale*(Math.ceil(Math.max(1,d+a.height/this.scale)/b)-v)*b)};var d=mxGraph.prototype.panGraph;mxGraph.prototype.panGraph=function(a,f){d.apply(this,arguments);this.dialect==mxConstants.DIALECT_SVG||null==this.view.backgroundPageShape||this.useScrollbarsForPanning&&mxUtils.hasScrollbars(this.container)||(this.view.backgroundPageShape.node.style.marginLeft=
-a+"px",this.view.backgroundPageShape.node.style.marginTop=f+"px")};var k=mxPopupMenu.prototype.addItem;mxPopupMenu.prototype.addItem=function(a,f,d,b,e,n){var c=k.apply(this,arguments);null==n||n||mxEvent.addListener(c,"mousedown",function(a){mxEvent.consume(a)});return c};var m=mxGraphHandler.prototype.getInitialCellForEvent;mxGraphHandler.prototype.getInitialCellForEvent=function(a){var c=m.apply(this,arguments),d=this.graph.getModel(),b=d.getParent(this.graph.getSelectionCell()),e=d.getParent(c);
+a+"px",this.view.backgroundPageShape.node.style.marginTop=f+"px")};var k=mxPopupMenu.prototype.addItem;mxPopupMenu.prototype.addItem=function(a,f,d,b,e,n){var c=k.apply(this,arguments);null==n||n||mxEvent.addListener(c,"mousedown",function(a){mxEvent.consume(a)});return c};var l=mxGraphHandler.prototype.getInitialCellForEvent;mxGraphHandler.prototype.getInitialCellForEvent=function(a){var c=l.apply(this,arguments),d=this.graph.getModel(),b=d.getParent(this.graph.getSelectionCell()),e=d.getParent(c);
if(null==b||b!=c&&b!=e)for(;!(this.graph.isCellSelected(c)||this.graph.isCellSelected(e)||this.graph.isContainer(e)&&!this.graph.isPart(c))&&d.isVertex(e);)c=e,e=this.graph.getModel().getParent(c);return c};var q=mxGraphHandler.prototype.isDelayedSelection;mxGraphHandler.prototype.isDelayedSelection=function(a,f){if(this.graph.cellEditor.getEditingCell()==a)return!1;var c=q.apply(this,arguments);if(!c)for(var d=this.graph.getModel(),b=d.getParent(a);null!=b;){if(this.graph.isCellSelected(b)&&d.isVertex(b)){c=
!0;break}b=d.getParent(b)}return c};mxGraphHandler.prototype.selectDelayed=function(a){if(!this.graph.popupMenuHandler.isPopupTrigger(a)){var c=a.getCell();null==c&&(c=this.cell);var d=this.graph.view.getState(c);if(!(null!=d&&a.isSource(d.control)||this.graph.isToggleEvent(a.getEvent())))for(var d=this.graph.getModel(),b=d.getParent(c);!this.graph.isCellSelected(b)&&d.isVertex(b);)c=b,b=d.getParent(c);this.graph.selectCellForEvent(c,a.getEvent())}};mxPopupMenuHandler.prototype.getCellForPopupEvent=
function(a){a=a.getCell();for(var c=this.graph.getModel(),d=c.getParent(a);c.isVertex(d)&&!this.graph.isContainer(d);)this.graph.isCellSelected(d)&&(a=d),d=c.getParent(d);return a}})();EditorUi=function(a,b,e){mxEventSource.call(this);this.destroyFunctions=[];this.editor=a||new Editor;this.container=b||document.body;var d=this.editor.graph;d.lightbox=e;d.useCssTransforms&&(this.lazyZoomDelay=0);mxClient.IS_SVG?mxPopupMenu.prototype.submenuImage="data:image/gif;base64,R0lGODlhCQAJAIAAAP///zMzMyH5BAEAAAAALAAAAAAJAAkAAAIPhI8WebHsHopSOVgb26AAADs=":(new Image).src=mxPopupMenu.prototype.submenuImage;mxClient.IS_SVG||null==mxConnectionHandler.prototype.connectImage||((new Image).src=mxConnectionHandler.prototype.connectImage.src);
this.editor.chromeless&&!this.editor.editable&&(this.footerHeight=0,d.isEnabled=function(){return!1},d.panningHandler.isForcePanningEvent=function(a){return!mxEvent.isPopupTrigger(a.getEvent())});this.actions=new Actions(this);this.menus=this.createMenus();if(!d.standalone){this.createDivs();this.createUi();this.refresh();var k=mxUtils.bind(this,function(a){null==a&&(a=window.event);return d.isEditing()||null!=a&&this.isSelectionAllowed(a)});this.container==document.body&&(this.menubarContainer.onselectstart=
k,this.menubarContainer.onmousedown=k,this.toolbarContainer.onselectstart=k,this.toolbarContainer.onmousedown=k,this.diagramContainer.onselectstart=k,this.diagramContainer.onmousedown=k,this.sidebarContainer.onselectstart=k,this.sidebarContainer.onmousedown=k,this.formatContainer.onselectstart=k,this.formatContainer.onmousedown=k,this.footerContainer.onselectstart=k,this.footerContainer.onmousedown=k,null!=this.tabContainer&&(this.tabContainer.onselectstart=k));!this.editor.chromeless||this.editor.editable?
(b=function(a){if(null!=a){var c=mxEvent.getSource(a);if("A"==c.nodeName)for(;null!=c;){if("geHint"==c.className)return!0;c=c.parentNode}}return k(a)},mxClient.IS_IE&&("undefined"===typeof document.documentMode||9>document.documentMode)?mxEvent.addListener(this.diagramContainer,"contextmenu",b):this.diagramContainer.oncontextmenu=b):d.panningHandler.usePopupTrigger=!1;d.init(this.diagramContainer);mxClient.IS_SVG&&null!=d.view.getDrawPane()&&(b=d.view.getDrawPane().ownerSVGElement,null!=b&&(b.style.position=
-"absolute"));this.hoverIcons=this.createHoverIcons();if(null!=d.graphHandler){var m=d.graphHandler.start;d.graphHandler.start=function(){null!=A.hoverIcons&&A.hoverIcons.reset();m.apply(this,arguments)}}mxEvent.addListener(this.diagramContainer,"mousemove",mxUtils.bind(this,function(a){var c=mxUtils.getOffset(this.diagramContainer);0<mxEvent.getClientX(a)-c.x-this.diagramContainer.clientWidth||0<mxEvent.getClientY(a)-c.y-this.diagramContainer.clientHeight?this.diagramContainer.setAttribute("title",
+"absolute"));this.hoverIcons=this.createHoverIcons();if(null!=d.graphHandler){var l=d.graphHandler.start;d.graphHandler.start=function(){null!=A.hoverIcons&&A.hoverIcons.reset();l.apply(this,arguments)}}mxEvent.addListener(this.diagramContainer,"mousemove",mxUtils.bind(this,function(a){var c=mxUtils.getOffset(this.diagramContainer);0<mxEvent.getClientX(a)-c.x-this.diagramContainer.clientWidth||0<mxEvent.getClientY(a)-c.y-this.diagramContainer.clientHeight?this.diagramContainer.setAttribute("title",
mxResources.get("panTooltip")):this.diagramContainer.removeAttribute("title")}));var q=!1,c=this.hoverIcons.isResetEvent;this.hoverIcons.isResetEvent=function(a,d){return q||c.apply(this,arguments)};this.keydownHandler=mxUtils.bind(this,function(a){32!=a.which||d.isEditing()?mxEvent.isConsumed(a)||27!=a.keyCode||this.hideDialog(null,!0):(q=!0,this.hoverIcons.reset(),d.container.style.cursor="move",d.isEditing()||mxEvent.getSource(a)!=d.container||mxEvent.consume(a))});mxEvent.addListener(document,
"keydown",this.keydownHandler);this.keyupHandler=mxUtils.bind(this,function(a){d.container.style.cursor="";q=!1});mxEvent.addListener(document,"keyup",this.keyupHandler);var f=d.panningHandler.isForcePanningEvent;d.panningHandler.isForcePanningEvent=function(a){return f.apply(this,arguments)||q||mxEvent.isMouseEvent(a.getEvent())&&(this.usePopupTrigger||!mxEvent.isPopupTrigger(a.getEvent()))&&(!mxEvent.isControlDown(a.getEvent())&&mxEvent.isRightMouseButton(a.getEvent())||mxEvent.isMiddleMouseButton(a.getEvent()))};
-var g=d.cellEditor.isStopEditingEvent;d.cellEditor.isStopEditingEvent=function(a){return g.apply(this,arguments)||13==a.keyCode&&(!mxClient.IS_SF&&mxEvent.isControlDown(a)||mxClient.IS_MAC&&mxEvent.isMetaDown(a)||mxClient.IS_SF&&mxEvent.isShiftDown(a))};var p=d.isZoomWheelEvent;d.isZoomWheelEvent=function(){return q||p.apply(this,arguments)};var l=!1,n=null,v=null,t=null,u=mxUtils.bind(this,function(){if(null!=this.toolbar&&l!=d.cellEditor.isContentEditing()){for(var a=this.toolbar.container.firstChild,
-c=[];null!=a;){var f=a.nextSibling;0>mxUtils.indexOf(this.toolbar.staticElements,a)&&(a.parentNode.removeChild(a),c.push(a));a=f}a=this.toolbar.fontMenu;f=this.toolbar.sizeMenu;if(null==t)this.toolbar.createTextToolbar();else{for(var b=0;b<t.length;b++)this.toolbar.container.appendChild(t[b]);this.toolbar.fontMenu=n;this.toolbar.sizeMenu=v}l=d.cellEditor.isContentEditing();n=a;v=f;t=c}}),A=this,B=d.cellEditor.startEditing;d.cellEditor.startEditing=function(){B.apply(this,arguments);u();if(d.cellEditor.isContentEditing()){var a=
+var g=d.cellEditor.isStopEditingEvent;d.cellEditor.isStopEditingEvent=function(a){return g.apply(this,arguments)||13==a.keyCode&&(!mxClient.IS_SF&&mxEvent.isControlDown(a)||mxClient.IS_MAC&&mxEvent.isMetaDown(a)||mxClient.IS_SF&&mxEvent.isShiftDown(a))};var p=d.isZoomWheelEvent;d.isZoomWheelEvent=function(){return q||p.apply(this,arguments)};var m=!1,n=null,v=null,t=null,u=mxUtils.bind(this,function(){if(null!=this.toolbar&&m!=d.cellEditor.isContentEditing()){for(var a=this.toolbar.container.firstChild,
+c=[];null!=a;){var f=a.nextSibling;0>mxUtils.indexOf(this.toolbar.staticElements,a)&&(a.parentNode.removeChild(a),c.push(a));a=f}a=this.toolbar.fontMenu;f=this.toolbar.sizeMenu;if(null==t)this.toolbar.createTextToolbar();else{for(var b=0;b<t.length;b++)this.toolbar.container.appendChild(t[b]);this.toolbar.fontMenu=n;this.toolbar.sizeMenu=v}m=d.cellEditor.isContentEditing();n=a;v=f;t=c}}),A=this,B=d.cellEditor.startEditing;d.cellEditor.startEditing=function(){B.apply(this,arguments);u();if(d.cellEditor.isContentEditing()){var a=
!1,c=function(){a||(a=!0,window.setTimeout(function(){for(var c=d.getSelectedElement();null!=c&&c.nodeType!=mxConstants.NODETYPE_ELEMENT;)c=c.parentNode;if(null!=c&&(c=mxUtils.getCurrentStyle(c),null!=c&&null!=A.toolbar)){var f=c.fontFamily;"'"==f.charAt(0)&&(f=f.substring(1));"'"==f.charAt(f.length-1)&&(f=f.substring(0,f.length-1));A.toolbar.setFontName(f);A.toolbar.setFontSize(parseInt(c.fontSize))}a=!1},0))};mxEvent.addListener(d.cellEditor.textarea,"input",c);mxEvent.addListener(d.cellEditor.textarea,
"touchend",c);mxEvent.addListener(d.cellEditor.textarea,"mouseup",c);mxEvent.addListener(d.cellEditor.textarea,"keyup",c);c()}};var D=d.cellEditor.stopEditing;d.cellEditor.stopEditing=function(a,c){try{D.apply(this,arguments),u()}catch(z){A.handleError(z)}};d.container.setAttribute("tabindex","0");d.container.style.cursor="default";if(window.self===window.top&&null!=d.container.parentNode)try{d.container.focus()}catch(y){}var C=d.fireMouseEvent;d.fireMouseEvent=function(a,c,d){a==mxEvent.MOUSE_DOWN&&
this.container.focus();C.apply(this,arguments)};d.popupMenuHandler.autoExpand=!0;null!=this.menus&&(d.popupMenuHandler.factoryMethod=mxUtils.bind(this,function(a,c,d){this.menus.createPopupMenu(a,c,d)}));mxEvent.addGestureListeners(document,mxUtils.bind(this,function(a){d.popupMenuHandler.hideMenu()}));this.keyHandler=this.createKeyHandler(a);this.getKeyHandler=function(){return keyHandler};var x="rounded shadow glass dashed dashPattern comic labelBackgroundColor".split(" "),F="shape edgeStyle curved rounded elbow comic jumpStyle jumpSize".split(" ");
-this.setDefaultStyle=function(a){try{var c=d.view.getState(a);if(null!=c){var f=a.clone();f.style="";var b=d.getCellStyle(f);a=[];var f=[],g;for(g in c.style)b[g]!=c.style[g]&&(a.push(c.style[g]),f.push(g));for(var e=d.getModel().getStyle(c.cell),l=null!=e?e.split(";"):[],e=0;e<l.length;e++){var p=l[e],n=p.indexOf("=");if(0<=n){g=p.substring(0,n);var u=p.substring(n+1);null!=b[g]&&"none"==u&&(a.push(u),f.push(g))}}d.getModel().isEdge(c.cell)?d.currentEdgeStyle={}:d.currentVertexStyle={};this.fireEvent(new mxEventObject("styleChanged",
+this.setDefaultStyle=function(a){try{var c=d.view.getState(a);if(null!=c){var f=a.clone();f.style="";var b=d.getCellStyle(f);a=[];var f=[],g;for(g in c.style)b[g]!=c.style[g]&&(a.push(c.style[g]),f.push(g));for(var e=d.getModel().getStyle(c.cell),m=null!=e?e.split(";"):[],e=0;e<m.length;e++){var p=m[e],n=p.indexOf("=");if(0<=n){g=p.substring(0,n);var u=p.substring(n+1);null!=b[g]&&"none"==u&&(a.push(u),f.push(g))}}d.getModel().isEdge(c.cell)?d.currentEdgeStyle={}:d.currentVertexStyle={};this.fireEvent(new mxEventObject("styleChanged",
"keys",f,"values",a,"cells",[c.cell]))}}catch(fa){this.handleError(fa)}};this.clearDefaultStyle=function(){d.currentEdgeStyle=mxUtils.clone(d.defaultEdgeStyle);d.currentVertexStyle=mxUtils.clone(d.defaultVertexStyle);this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[]))};var G=["fontFamily","fontSize","fontColor"],E="edgeStyle startArrow startFill startSize endArrow endFill endSize".split(" "),J=["startArrow startFill startSize sourcePerimeterSpacing endArrow endFill endSize targetPerimeterSpacing".split(" "),
-["strokeColor","strokeWidth"],["fillColor","gradientColor"],G,["opacity"],["align"],["html"]];for(a=0;a<J.length;a++)for(b=0;b<J[a].length;b++)x.push(J[a][b]);for(a=0;a<F.length;a++)0>mxUtils.indexOf(x,F[a])&&x.push(F[a]);var H=function(a,c){var f=d.getModel();f.beginUpdate();try{for(var b=0;b<a.length;b++){var g=a[b],e;if(c)e=["fontSize","fontFamily","fontColor"];else{var l=f.getStyle(g),p=null!=l?l.split(";"):[];e=x.slice();for(var n=0;n<p.length;n++){var u=p[n],t=u.indexOf("=");if(0<=t){var y=
-u.substring(0,t),K=mxUtils.indexOf(e,y);0<=K&&e.splice(K,1);for(var v=0;v<J.length;v++){var m=J[v];if(0<=mxUtils.indexOf(m,y))for(var k=0;k<m.length;k++){var B=mxUtils.indexOf(e,m[k]);0<=B&&e.splice(B,1)}}}}}for(var A=f.isEdge(g),q=A?d.currentEdgeStyle:d.currentVertexStyle,D=f.getStyle(g),n=0;n<e.length;n++){var y=e[n],C=q[y];null==C||"shape"==y&&!A||A&&!(0>mxUtils.indexOf(F,y))||(D=mxUtils.setStyle(D,y,C))}f.setStyle(g,D)}}finally{f.endUpdate()}};d.addListener("cellsInserted",function(a,c){H(c.getProperty("cells"))});
+["strokeColor","strokeWidth"],["fillColor","gradientColor"],G,["opacity"],["align"],["html"]];for(a=0;a<J.length;a++)for(b=0;b<J[a].length;b++)x.push(J[a][b]);for(a=0;a<F.length;a++)0>mxUtils.indexOf(x,F[a])&&x.push(F[a]);var H=function(a,c){var f=d.getModel();f.beginUpdate();try{for(var b=0;b<a.length;b++){var g=a[b],e;if(c)e=["fontSize","fontFamily","fontColor"];else{var m=f.getStyle(g),p=null!=m?m.split(";"):[];e=x.slice();for(var n=0;n<p.length;n++){var u=p[n],t=u.indexOf("=");if(0<=t){var y=
+u.substring(0,t),K=mxUtils.indexOf(e,y);0<=K&&e.splice(K,1);for(var v=0;v<J.length;v++){var l=J[v];if(0<=mxUtils.indexOf(l,y))for(var k=0;k<l.length;k++){var B=mxUtils.indexOf(e,l[k]);0<=B&&e.splice(B,1)}}}}}for(var A=f.isEdge(g),q=A?d.currentEdgeStyle:d.currentVertexStyle,D=f.getStyle(g),n=0;n<e.length;n++){var y=e[n],C=q[y];null==C||"shape"==y&&!A||A&&!(0>mxUtils.indexOf(F,y))||(D=mxUtils.setStyle(D,y,C))}f.setStyle(g,D)}}finally{f.endUpdate()}};d.addListener("cellsInserted",function(a,c){H(c.getProperty("cells"))});
d.addListener("textInserted",function(a,c){H(c.getProperty("cells"),!0)});d.connectionHandler.addListener(mxEvent.CONNECT,function(a,c){var d=[c.getProperty("cell")];c.getProperty("terminalInserted")&&d.push(c.getProperty("terminal"));H(d)});this.addListener("styleChanged",mxUtils.bind(this,function(a,c){var f=c.getProperty("cells"),b=!1,g=!1;if(0<f.length)for(var e=0;e<f.length&&(b=d.getModel().isVertex(f[e])||b,!(g=d.getModel().isEdge(f[e])||g)||!b);e++);else g=b=!0;for(var f=c.getProperty("keys"),
-l=c.getProperty("values"),e=0;e<f.length;e++){var p=0<=mxUtils.indexOf(G,f[e]);if("strokeColor"!=f[e]||null!=l[e]&&"none"!=l[e])if(0<=mxUtils.indexOf(F,f[e]))g||0<=mxUtils.indexOf(E,f[e])?null==l[e]?delete d.currentEdgeStyle[f[e]]:d.currentEdgeStyle[f[e]]=l[e]:b&&0<=mxUtils.indexOf(x,f[e])&&(null==l[e]?delete d.currentVertexStyle[f[e]]:d.currentVertexStyle[f[e]]=l[e]);else if(0<=mxUtils.indexOf(x,f[e])){if(b||p)null==l[e]?delete d.currentVertexStyle[f[e]]:d.currentVertexStyle[f[e]]=l[e];if(g||p||
-0<=mxUtils.indexOf(E,f[e]))null==l[e]?delete d.currentEdgeStyle[f[e]]:d.currentEdgeStyle[f[e]]=l[e]}}null!=this.toolbar&&(this.toolbar.setFontName(d.currentVertexStyle.fontFamily||Menus.prototype.defaultFont),this.toolbar.setFontSize(d.currentVertexStyle.fontSize||Menus.prototype.defaultFontSize),null!=this.toolbar.edgeStyleMenu&&(this.toolbar.edgeStyleMenu.getElementsByTagName("div")[0].className="orthogonalEdgeStyle"==d.currentEdgeStyle.edgeStyle&&"1"==d.currentEdgeStyle.curved?"geSprite geSprite-curved":
+m=c.getProperty("values"),e=0;e<f.length;e++){var p=0<=mxUtils.indexOf(G,f[e]);if("strokeColor"!=f[e]||null!=m[e]&&"none"!=m[e])if(0<=mxUtils.indexOf(F,f[e]))g||0<=mxUtils.indexOf(E,f[e])?null==m[e]?delete d.currentEdgeStyle[f[e]]:d.currentEdgeStyle[f[e]]=m[e]:b&&0<=mxUtils.indexOf(x,f[e])&&(null==m[e]?delete d.currentVertexStyle[f[e]]:d.currentVertexStyle[f[e]]=m[e]);else if(0<=mxUtils.indexOf(x,f[e])){if(b||p)null==m[e]?delete d.currentVertexStyle[f[e]]:d.currentVertexStyle[f[e]]=m[e];if(g||p||
+0<=mxUtils.indexOf(E,f[e]))null==m[e]?delete d.currentEdgeStyle[f[e]]:d.currentEdgeStyle[f[e]]=m[e]}}null!=this.toolbar&&(this.toolbar.setFontName(d.currentVertexStyle.fontFamily||Menus.prototype.defaultFont),this.toolbar.setFontSize(d.currentVertexStyle.fontSize||Menus.prototype.defaultFontSize),null!=this.toolbar.edgeStyleMenu&&(this.toolbar.edgeStyleMenu.getElementsByTagName("div")[0].className="orthogonalEdgeStyle"==d.currentEdgeStyle.edgeStyle&&"1"==d.currentEdgeStyle.curved?"geSprite geSprite-curved":
"straight"==d.currentEdgeStyle.edgeStyle||"none"==d.currentEdgeStyle.edgeStyle||null==d.currentEdgeStyle.edgeStyle?"geSprite geSprite-straight":"entityRelationEdgeStyle"==d.currentEdgeStyle.edgeStyle?"geSprite geSprite-entity":"elbowEdgeStyle"==d.currentEdgeStyle.edgeStyle?"geSprite geSprite-"+("vertical"==d.currentEdgeStyle.elbow?"verticalelbow":"horizontalelbow"):"isometricEdgeStyle"==d.currentEdgeStyle.edgeStyle?"geSprite geSprite-"+("vertical"==d.currentEdgeStyle.elbow?"verticalisometric":"horizontalisometric"):
"geSprite geSprite-orthogonal"),null!=this.toolbar.edgeShapeMenu&&(this.toolbar.edgeShapeMenu.getElementsByTagName("div")[0].className="link"==d.currentEdgeStyle.shape?"geSprite geSprite-linkedge":"flexArrow"==d.currentEdgeStyle.shape?"geSprite geSprite-arrow":"arrow"==d.currentEdgeStyle.shape?"geSprite geSprite-simplearrow":"geSprite geSprite-connection"),null!=this.toolbar.lineStartMenu&&(this.toolbar.lineStartMenu.getElementsByTagName("div")[0].className=this.getCssClassForMarker("start",d.currentEdgeStyle.shape,
d.currentEdgeStyle[mxConstants.STYLE_STARTARROW],mxUtils.getValue(d.currentEdgeStyle,"startFill","1"))),null!=this.toolbar.lineEndMenu&&(this.toolbar.lineEndMenu.getElementsByTagName("div")[0].className=this.getCssClassForMarker("end",d.currentEdgeStyle.shape,d.currentEdgeStyle[mxConstants.STYLE_ENDARROW],mxUtils.getValue(d.currentEdgeStyle,"endFill","1"))))}));null!=this.toolbar&&(a=mxUtils.bind(this,function(){var a=d.currentVertexStyle.fontFamily||"Helvetica",c=String(d.currentVertexStyle.fontSize||
@@ -2154,26 +2154,26 @@ EditorUi.prototype.getCssClassForMarker=function(a,b,e,d){return"flexArrow"==b?n
e==mxConstants.ARROW_DIAMOND_THIN?"1"==d?"geSprite geSprite-"+a+"thindiamond":"geSprite geSprite-"+a+"thindiamondtrans":"openAsync"==e?"geSprite geSprite-"+a+"openasync":"dash"==e?"geSprite geSprite-"+a+"dash":"cross"==e?"geSprite geSprite-"+a+"cross":"async"==e?"1"==d?"geSprite geSprite-"+a+"async":"geSprite geSprite-"+a+"asynctrans":"circle"==e||"circlePlus"==e?"1"==d||"circle"==e?"geSprite geSprite-"+a+"circle":"geSprite geSprite-"+a+"circleplus":"ERone"==e?"geSprite geSprite-"+a+"erone":"ERmandOne"==
e?"geSprite geSprite-"+a+"eronetoone":"ERmany"==e?"geSprite geSprite-"+a+"ermany":"ERoneToMany"==e?"geSprite geSprite-"+a+"eronetomany":"ERzeroToOne"==e?"geSprite geSprite-"+a+"eroneopt":"ERzeroToMany"==e?"geSprite geSprite-"+a+"ermanyopt":"geSprite geSprite-noarrow"};EditorUi.prototype.createMenus=function(){return null};
EditorUi.prototype.updatePasteActionStates=function(){var a=this.editor.graph,b=this.actions.get("paste"),e=this.actions.get("pasteHere");b.setEnabled(this.editor.graph.cellEditor.isContentEditing()||!mxClipboard.isEmpty()&&a.isEnabled()&&!a.isCellLocked(a.getDefaultParent()));e.setEnabled(b.isEnabled())};
-EditorUi.prototype.initClipboard=function(){var a=this,b=mxClipboard.cut;mxClipboard.cut=function(d){d.cellEditor.isContentEditing()?document.execCommand("cut",!1,null):b.apply(this,arguments);a.updatePasteActionStates()};mxClipboard.copy=function(d){var b=null;if(d.cellEditor.isContentEditing())document.execCommand("copy",!1,null);else{for(var b=b||d.getSelectionCells(),b=d.getExportableCells(d.model.getTopmostCells(b)),c={},f=d.createCellLookup(b),g=d.cloneCells(b,null,c),e=new mxGraphModel,l=e.getChildAt(e.getRoot(),
-0),n=0;n<g.length;n++)e.add(l,g[n]);d.updateCustomLinks(d.createCellMapping(c,f),g);mxClipboard.insertCount=1;mxClipboard.setCells(g)}a.updatePasteActionStates();return b};var e=mxClipboard.paste;mxClipboard.paste=function(d){var b=null;d.cellEditor.isContentEditing()?document.execCommand("paste",!1,null):b=e.apply(this,arguments);a.updatePasteActionStates();return b};var d=this.editor.graph.cellEditor.startEditing;this.editor.graph.cellEditor.startEditing=function(){d.apply(this,arguments);a.updatePasteActionStates()};
+EditorUi.prototype.initClipboard=function(){var a=this,b=mxClipboard.cut;mxClipboard.cut=function(d){d.cellEditor.isContentEditing()?document.execCommand("cut",!1,null):b.apply(this,arguments);a.updatePasteActionStates()};mxClipboard.copy=function(d){var b=null;if(d.cellEditor.isContentEditing())document.execCommand("copy",!1,null);else{for(var b=b||d.getSelectionCells(),b=d.getExportableCells(d.model.getTopmostCells(b)),c={},f=d.createCellLookup(b),g=d.cloneCells(b,null,c),e=new mxGraphModel,m=e.getChildAt(e.getRoot(),
+0),n=0;n<g.length;n++)e.add(m,g[n]);d.updateCustomLinks(d.createCellMapping(c,f),g);mxClipboard.insertCount=1;mxClipboard.setCells(g)}a.updatePasteActionStates();return b};var e=mxClipboard.paste;mxClipboard.paste=function(d){var b=null;d.cellEditor.isContentEditing()?document.execCommand("paste",!1,null):b=e.apply(this,arguments);a.updatePasteActionStates();return b};var d=this.editor.graph.cellEditor.startEditing;this.editor.graph.cellEditor.startEditing=function(){d.apply(this,arguments);a.updatePasteActionStates()};
var k=this.editor.graph.cellEditor.stopEditing;this.editor.graph.cellEditor.stopEditing=function(d,b){k.apply(this,arguments);a.updatePasteActionStates()};this.updatePasteActionStates()};EditorUi.prototype.lazyZoomDelay=20;EditorUi.prototype.wheelZoomDelay=400;EditorUi.prototype.buttonZoomDelay=600;
EditorUi.prototype.initCanvas=function(){var a=this.editor.graph;a.timerAutoScroll=!0;a.getPagePadding=function(){return new mxPoint(Math.max(0,Math.round((a.container.offsetWidth-34)/a.view.scale)),Math.max(0,Math.round((a.container.offsetHeight-34)/a.view.scale)))};a.view.getBackgroundPageBounds=function(){var a=this.graph.getPageLayout(),c=this.graph.getPageSize();return new mxRectangle(this.scale*(this.translate.x+a.x*c.width),this.scale*(this.translate.y+a.y*c.height),this.scale*a.width*c.width,
-this.scale*a.height*c.height)};a.getPreferredPageSize=function(a,c,f){a=this.getPageLayout();c=this.getPageSize();return new mxRectangle(0,0,a.width*c.width,a.height*c.height)};var b=null,e=this;if(this.editor.isChromelessView()){this.chromelessResize=b=mxUtils.bind(this,function(c,f,d,b){if(null!=a.container&&!a.isViewer()){d=null!=d?d:0;b=null!=b?b:0;var g=a.pageVisible?a.view.getBackgroundPageBounds():a.getGraphBounds(),e=mxUtils.hasScrollbars(a.container),l=a.view.translate,p=a.view.scale,n=mxRectangle.fromRectangle(g);
-n.x=n.x/p-l.x;n.y=n.y/p-l.y;n.width/=p;n.height/=p;var l=a.container.scrollTop,u=a.container.scrollLeft,t=mxClient.IS_QUIRKS||8<=document.documentMode?20:14;if(8==document.documentMode||9==document.documentMode)t+=3;var y=a.container.offsetWidth-t,t=a.container.offsetHeight-t;c=c?Math.max(.3,Math.min(f||1,y/n.width)):p;f=(y-c*n.width)/2/c;var z=0==this.lightboxVerticalDivider?0:(t-c*n.height)/this.lightboxVerticalDivider/c;e&&(f=Math.max(f,0),z=Math.max(z,0));if(e||g.width<y||g.height<t)a.view.scaleAndTranslate(c,
-Math.floor(f-n.x),Math.floor(z-n.y)),a.container.scrollTop=l*c/p,a.container.scrollLeft=u*c/p;else if(0!=d||0!=b)g=a.view.translate,a.view.setTranslate(Math.floor(g.x+d/p),Math.floor(g.y+b/p))}});this.chromelessWindowResize=mxUtils.bind(this,function(){this.chromelessResize(!1)});var d=mxUtils.bind(this,function(){this.chromelessWindowResize(!1)});mxEvent.addListener(window,"resize",d);this.destroyFunctions.push(function(){mxEvent.removeListener(window,"resize",d)});this.editor.addListener("resetGraphView",
+this.scale*a.height*c.height)};a.getPreferredPageSize=function(a,c,f){a=this.getPageLayout();c=this.getPageSize();return new mxRectangle(0,0,a.width*c.width,a.height*c.height)};var b=null,e=this;if(this.editor.isChromelessView()){this.chromelessResize=b=mxUtils.bind(this,function(c,f,d,b){if(null!=a.container&&!a.isViewer()){d=null!=d?d:0;b=null!=b?b:0;var g=a.pageVisible?a.view.getBackgroundPageBounds():a.getGraphBounds(),e=mxUtils.hasScrollbars(a.container),m=a.view.translate,p=a.view.scale,n=mxRectangle.fromRectangle(g);
+n.x=n.x/p-m.x;n.y=n.y/p-m.y;n.width/=p;n.height/=p;var m=a.container.scrollTop,u=a.container.scrollLeft,t=mxClient.IS_QUIRKS||8<=document.documentMode?20:14;if(8==document.documentMode||9==document.documentMode)t+=3;var y=a.container.offsetWidth-t,t=a.container.offsetHeight-t;c=c?Math.max(.3,Math.min(f||1,y/n.width)):p;f=(y-c*n.width)/2/c;var z=0==this.lightboxVerticalDivider?0:(t-c*n.height)/this.lightboxVerticalDivider/c;e&&(f=Math.max(f,0),z=Math.max(z,0));if(e||g.width<y||g.height<t)a.view.scaleAndTranslate(c,
+Math.floor(f-n.x),Math.floor(z-n.y)),a.container.scrollTop=m*c/p,a.container.scrollLeft=u*c/p;else if(0!=d||0!=b)g=a.view.translate,a.view.setTranslate(Math.floor(g.x+d/p),Math.floor(g.y+b/p))}});this.chromelessWindowResize=mxUtils.bind(this,function(){this.chromelessResize(!1)});var d=mxUtils.bind(this,function(){this.chromelessWindowResize(!1)});mxEvent.addListener(window,"resize",d);this.destroyFunctions.push(function(){mxEvent.removeListener(window,"resize",d)});this.editor.addListener("resetGraphView",
mxUtils.bind(this,function(){this.chromelessResize(!0)}));this.actions.get("zoomIn").funct=mxUtils.bind(this,function(c){a.zoomIn();this.chromelessResize(!1)});this.actions.get("zoomOut").funct=mxUtils.bind(this,function(c){a.zoomOut();this.chromelessResize(!1)});if("0"!=urlParams.toolbar){var k=JSON.parse(decodeURIComponent(urlParams["toolbar-config"]||"{}"));this.chromelessToolbar=document.createElement("div");this.chromelessToolbar.style.position="fixed";this.chromelessToolbar.style.overflow="hidden";
-this.chromelessToolbar.style.boxSizing="border-box";this.chromelessToolbar.style.whiteSpace="nowrap";this.chromelessToolbar.style.backgroundColor="#000000";this.chromelessToolbar.style.padding="10px 10px 8px 10px";this.chromelessToolbar.style.left=a.isViewer()?"0":"50%";mxClient.IS_VML||(mxUtils.setPrefixedStyle(this.chromelessToolbar.style,"borderRadius","20px"),mxUtils.setPrefixedStyle(this.chromelessToolbar.style,"transition","opacity 600ms ease-in-out"));var m=mxUtils.bind(this,function(){var c=
-mxUtils.getCurrentStyle(a.container);a.isViewer()?this.chromelessToolbar.style.top="0":this.chromelessToolbar.style.bottom=(null!=c?parseInt(c["margin-bottom"]||0):0)+(null!=this.tabContainer?20+parseInt(this.tabContainer.style.height):20)+"px"});this.editor.addListener("resetGraphView",m);m();var q=0,m=mxUtils.bind(this,function(a,c,f){q++;var d=document.createElement("span");d.style.paddingLeft="8px";d.style.paddingRight="8px";d.style.cursor="pointer";mxEvent.addListener(d,"click",a);null!=f&&d.setAttribute("title",
-f);a=document.createElement("img");a.setAttribute("border","0");a.setAttribute("src",c);d.appendChild(a);this.chromelessToolbar.appendChild(d);return d});null!=k.backBtn&&m(mxUtils.bind(this,function(a){window.location.href=k.backBtn.url;mxEvent.consume(a)}),Editor.backLargeImage,mxResources.get("back",null,"Back"));var c=m(mxUtils.bind(this,function(a){this.actions.get("previousPage").funct();mxEvent.consume(a)}),Editor.previousLargeImage,mxResources.get("previousPage")),f=document.createElement("div");
-f.style.display="inline-block";f.style.verticalAlign="top";f.style.fontFamily="Helvetica,Arial";f.style.marginTop="8px";f.style.fontSize="14px";f.style.color="#ffffff";this.chromelessToolbar.appendChild(f);var g=m(mxUtils.bind(this,function(a){this.actions.get("nextPage").funct();mxEvent.consume(a)}),Editor.nextLargeImage,mxResources.get("nextPage")),p=mxUtils.bind(this,function(){null!=this.pages&&1<this.pages.length&&null!=this.currentPage&&(f.innerHTML="",mxUtils.write(f,mxUtils.indexOf(this.pages,
-this.currentPage)+1+" / "+this.pages.length))});c.style.paddingLeft="0px";c.style.paddingRight="4px";g.style.paddingLeft="4px";g.style.paddingRight="0px";var l=mxUtils.bind(this,function(){null!=this.pages&&1<this.pages.length&&null!=this.currentPage?(g.style.display="",c.style.display="",f.style.display="inline-block"):(g.style.display="none",c.style.display="none",f.style.display="none");p()});this.editor.addListener("resetGraphView",l);this.editor.addListener("pageSelected",p);m(mxUtils.bind(this,
-function(a){this.actions.get("zoomOut").funct();mxEvent.consume(a)}),Editor.zoomOutLargeImage,mxResources.get("zoomOut")+" (Alt+Mousewheel)");m(mxUtils.bind(this,function(a){this.actions.get("zoomIn").funct();mxEvent.consume(a)}),Editor.zoomInLargeImage,mxResources.get("zoomIn")+" (Alt+Mousewheel)");m(mxUtils.bind(this,function(c){a.isLightboxView()?(1==a.view.scale?this.lightboxFit():a.zoomTo(1),this.chromelessResize(!1)):this.chromelessResize(!0);mxEvent.consume(c)}),Editor.actualSizeLargeImage,
+this.chromelessToolbar.style.boxSizing="border-box";this.chromelessToolbar.style.whiteSpace="nowrap";this.chromelessToolbar.style.backgroundColor="#000000";this.chromelessToolbar.style.padding="10px 10px 8px 10px";this.chromelessToolbar.style.left=a.isViewer()?"0":"50%";mxClient.IS_VML||(mxUtils.setPrefixedStyle(this.chromelessToolbar.style,"borderRadius","20px"),mxUtils.setPrefixedStyle(this.chromelessToolbar.style,"transition","opacity 600ms ease-in-out"));var l=mxUtils.bind(this,function(){var c=
+mxUtils.getCurrentStyle(a.container);a.isViewer()?this.chromelessToolbar.style.top="0":this.chromelessToolbar.style.bottom=(null!=c?parseInt(c["margin-bottom"]||0):0)+(null!=this.tabContainer?20+parseInt(this.tabContainer.style.height):20)+"px"});this.editor.addListener("resetGraphView",l);l();var q=0,l=mxUtils.bind(this,function(a,c,f){q++;var d=document.createElement("span");d.style.paddingLeft="8px";d.style.paddingRight="8px";d.style.cursor="pointer";mxEvent.addListener(d,"click",a);null!=f&&d.setAttribute("title",
+f);a=document.createElement("img");a.setAttribute("border","0");a.setAttribute("src",c);d.appendChild(a);this.chromelessToolbar.appendChild(d);return d});null!=k.backBtn&&l(mxUtils.bind(this,function(a){window.location.href=k.backBtn.url;mxEvent.consume(a)}),Editor.backLargeImage,mxResources.get("back",null,"Back"));var c=l(mxUtils.bind(this,function(a){this.actions.get("previousPage").funct();mxEvent.consume(a)}),Editor.previousLargeImage,mxResources.get("previousPage")),f=document.createElement("div");
+f.style.display="inline-block";f.style.verticalAlign="top";f.style.fontFamily="Helvetica,Arial";f.style.marginTop="8px";f.style.fontSize="14px";f.style.color="#ffffff";this.chromelessToolbar.appendChild(f);var g=l(mxUtils.bind(this,function(a){this.actions.get("nextPage").funct();mxEvent.consume(a)}),Editor.nextLargeImage,mxResources.get("nextPage")),p=mxUtils.bind(this,function(){null!=this.pages&&1<this.pages.length&&null!=this.currentPage&&(f.innerHTML="",mxUtils.write(f,mxUtils.indexOf(this.pages,
+this.currentPage)+1+" / "+this.pages.length))});c.style.paddingLeft="0px";c.style.paddingRight="4px";g.style.paddingLeft="4px";g.style.paddingRight="0px";var m=mxUtils.bind(this,function(){null!=this.pages&&1<this.pages.length&&null!=this.currentPage?(g.style.display="",c.style.display="",f.style.display="inline-block"):(g.style.display="none",c.style.display="none",f.style.display="none");p()});this.editor.addListener("resetGraphView",m);this.editor.addListener("pageSelected",p);l(mxUtils.bind(this,
+function(a){this.actions.get("zoomOut").funct();mxEvent.consume(a)}),Editor.zoomOutLargeImage,mxResources.get("zoomOut")+" (Alt+Mousewheel)");l(mxUtils.bind(this,function(a){this.actions.get("zoomIn").funct();mxEvent.consume(a)}),Editor.zoomInLargeImage,mxResources.get("zoomIn")+" (Alt+Mousewheel)");l(mxUtils.bind(this,function(c){a.isLightboxView()?(1==a.view.scale?this.lightboxFit():a.zoomTo(1),this.chromelessResize(!1)):this.chromelessResize(!0);mxEvent.consume(c)}),Editor.actualSizeLargeImage,
mxResources.get("fit"));var n=null,v=null,t=mxUtils.bind(this,function(a){null!=n&&(window.clearTimeout(n),fadeThead=null);null!=v&&(window.clearTimeout(v),fadeThead2=null);n=window.setTimeout(mxUtils.bind(this,function(){mxUtils.setOpacity(this.chromelessToolbar,0);n=null;v=window.setTimeout(mxUtils.bind(this,function(){this.chromelessToolbar.style.display="none";v=null}),600)}),a||200)}),u=mxUtils.bind(this,function(a){null!=n&&(window.clearTimeout(n),fadeThead=null);null!=v&&(window.clearTimeout(v),
-fadeThead2=null);this.chromelessToolbar.style.display="";mxUtils.setOpacity(this.chromelessToolbar,a||30)});if("1"==urlParams.layers){this.layersDialog=null;var A=m(mxUtils.bind(this,function(c){if(null!=this.layersDialog)this.layersDialog.parentNode.removeChild(this.layersDialog),this.layersDialog=null;else{this.layersDialog=a.createLayersDialog();mxEvent.addListener(this.layersDialog,"mouseleave",mxUtils.bind(this,function(){this.layersDialog.parentNode.removeChild(this.layersDialog);this.layersDialog=
+fadeThead2=null);this.chromelessToolbar.style.display="";mxUtils.setOpacity(this.chromelessToolbar,a||30)});if("1"==urlParams.layers){this.layersDialog=null;var A=l(mxUtils.bind(this,function(c){if(null!=this.layersDialog)this.layersDialog.parentNode.removeChild(this.layersDialog),this.layersDialog=null;else{this.layersDialog=a.createLayersDialog();mxEvent.addListener(this.layersDialog,"mouseleave",mxUtils.bind(this,function(){this.layersDialog.parentNode.removeChild(this.layersDialog);this.layersDialog=
null}));var f=A.getBoundingClientRect();mxUtils.setPrefixedStyle(this.layersDialog.style,"borderRadius","5px");this.layersDialog.style.position="fixed";this.layersDialog.style.fontFamily="Helvetica,Arial";this.layersDialog.style.backgroundColor="#000000";this.layersDialog.style.width="160px";this.layersDialog.style.padding="4px 2px 4px 2px";this.layersDialog.style.color="#ffffff";mxUtils.setOpacity(this.layersDialog,70);this.layersDialog.style.left=f.left+"px";this.layersDialog.style.bottom=parseInt(this.chromelessToolbar.style.bottom)+
-this.chromelessToolbar.offsetHeight+4+"px";f=mxUtils.getCurrentStyle(this.editor.graph.container);this.layersDialog.style.zIndex=f.zIndex;document.body.appendChild(this.layersDialog)}mxEvent.consume(c)}),Editor.layersLargeImage,mxResources.get("layers")),B=a.getModel();B.addListener(mxEvent.CHANGE,function(){A.style.display=1<B.getChildCount(B.root)?"":"none"})}this.addChromelessToolbarItems(m);null==this.editor.editButtonLink&&null==this.editor.editButtonFunc||m(mxUtils.bind(this,function(c){null!=
-this.editor.editButtonFunc?this.editor.editButtonFunc():"_blank"==this.editor.editButtonLink?this.editor.editAsNew(this.getEditBlankXml()):a.openLink(this.editor.editButtonLink,"editWindow");mxEvent.consume(c)}),Editor.editLargeImage,mxResources.get("edit"));if(null!=this.lightboxToolbarActions)for(l=0;l<this.lightboxToolbarActions.length;l++){var D=this.lightboxToolbarActions[l];m(D.fn,D.icon,D.tooltip)}null!=k.refreshBtn&&m(mxUtils.bind(this,function(a){k.refreshBtn.url?window.location.href=k.refreshBtn.url:
-window.location.reload();mxEvent.consume(a)}),Editor.refreshLargeImage,mxResources.get("refresh",null,"Refresh"));null!=k.fullscreenBtn&&window.self!==window.top&&m(mxUtils.bind(this,function(c){k.fullscreenBtn.url?a.openLink(k.fullscreenBtn.url):a.openLink(window.location.href);mxEvent.consume(c)}),Editor.fullscreenLargeImage,mxResources.get("openInNewWindow",null,"Open in New Window"));(k.closeBtn&&window.self===window.top||a.lightbox&&("1"==urlParams.close||this.container!=document.body))&&m(mxUtils.bind(this,
+this.chromelessToolbar.offsetHeight+4+"px";f=mxUtils.getCurrentStyle(this.editor.graph.container);this.layersDialog.style.zIndex=f.zIndex;document.body.appendChild(this.layersDialog)}mxEvent.consume(c)}),Editor.layersLargeImage,mxResources.get("layers")),B=a.getModel();B.addListener(mxEvent.CHANGE,function(){A.style.display=1<B.getChildCount(B.root)?"":"none"})}this.addChromelessToolbarItems(l);null==this.editor.editButtonLink&&null==this.editor.editButtonFunc||l(mxUtils.bind(this,function(c){null!=
+this.editor.editButtonFunc?this.editor.editButtonFunc():"_blank"==this.editor.editButtonLink?this.editor.editAsNew(this.getEditBlankXml()):a.openLink(this.editor.editButtonLink,"editWindow");mxEvent.consume(c)}),Editor.editLargeImage,mxResources.get("edit"));if(null!=this.lightboxToolbarActions)for(m=0;m<this.lightboxToolbarActions.length;m++){var D=this.lightboxToolbarActions[m];l(D.fn,D.icon,D.tooltip)}null!=k.refreshBtn&&l(mxUtils.bind(this,function(a){k.refreshBtn.url?window.location.href=k.refreshBtn.url:
+window.location.reload();mxEvent.consume(a)}),Editor.refreshLargeImage,mxResources.get("refresh",null,"Refresh"));null!=k.fullscreenBtn&&window.self!==window.top&&l(mxUtils.bind(this,function(c){k.fullscreenBtn.url?a.openLink(k.fullscreenBtn.url):a.openLink(window.location.href);mxEvent.consume(c)}),Editor.fullscreenLargeImage,mxResources.get("openInNewWindow",null,"Open in New Window"));(k.closeBtn&&window.self===window.top||a.lightbox&&("1"==urlParams.close||this.container!=document.body))&&l(mxUtils.bind(this,
function(a){"1"==urlParams.close||k.closeBtn?window.close():(this.destroy(),mxEvent.consume(a))}),Editor.closeLargeImage,mxResources.get("close")+" (Escape)");this.chromelessToolbar.style.display="none";a.isViewer()||mxUtils.setPrefixedStyle(this.chromelessToolbar.style,"transform","translate(-50%,0)");a.container.appendChild(this.chromelessToolbar);mxEvent.addListener(a.container,mxClient.IS_POINTER?"pointermove":"mousemove",mxUtils.bind(this,function(a){mxEvent.isTouchEvent(a)||(mxEvent.isShiftDown(a)||
u(30),t())}));mxEvent.addListener(this.chromelessToolbar,mxClient.IS_POINTER?"pointermove":"mousemove",function(a){mxEvent.consume(a)});mxEvent.addListener(this.chromelessToolbar,"mouseenter",mxUtils.bind(this,function(a){mxEvent.isShiftDown(a)?t():u(100)}));mxEvent.addListener(this.chromelessToolbar,"mousemove",mxUtils.bind(this,function(a){mxEvent.isShiftDown(a)?t():u(100);mxEvent.consume(a)}));mxEvent.addListener(this.chromelessToolbar,"mouseleave",mxUtils.bind(this,function(a){mxEvent.isTouchEvent(a)||
u(30)}));var C=a.getTolerance();a.addMouseListener({startX:0,startY:0,scrollLeft:0,scrollTop:0,mouseDown:function(c,f){this.startX=f.getGraphX();this.startY=f.getGraphY();this.scrollLeft=a.container.scrollLeft;this.scrollTop=a.container.scrollTop},mouseMove:function(a,c){},mouseUp:function(c,f){mxEvent.isTouchEvent(f.getEvent())&&Math.abs(this.scrollLeft-a.container.scrollLeft)<C&&Math.abs(this.scrollTop-a.container.scrollTop)<C&&Math.abs(this.startX-f.getGraphX())<C&&Math.abs(this.startY-f.getGraphY())<
@@ -2181,8 +2181,8 @@ C&&(0<parseFloat(e.chromelessToolbar.style.opacity||0)?t():u(30))}})}this.editor
function(){if(null!=this.container&&mxUtils.hasScrollbars(this.container)){var c=this.getPageLayout(),f=this.getPagePadding(),d=this.getPageSize(),b=Math.ceil(2*f.x+c.width*d.width),g=Math.ceil(2*f.y+c.height*d.height),e=a.minimumGraphSize;if(null==e||e.width!=b||e.height!=g)a.minimumGraphSize=new mxRectangle(0,0,b,g);b=f.x-c.x*d.width;f=f.y-c.y*d.height;this.autoTranslate||this.view.translate.x==b&&this.view.translate.y==f?F.apply(this,arguments):(this.autoTranslate=!0,this.view.x0=c.x,this.view.y0=
c.y,c=a.view.translate.x,d=a.view.translate.y,a.view.setTranslate(b,f),a.container.scrollLeft+=Math.round((b-c)*a.view.scale),a.container.scrollTop+=Math.round((f-d)*a.view.scale),this.autoTranslate=!1)}else this.fireEvent(new mxEventObject(mxEvent.SIZE,"bounds",this.getGraphBounds()))}}}var G=a.view.getBackgroundPane(),E=a.view.getDrawPane();a.cumulativeZoomFactor=1;var J=null,H=null,y=null,K=null,z=function(c){null!=J&&window.clearTimeout(J);window.setTimeout(function(){a.isMouseDown||(J=window.setTimeout(mxUtils.bind(this,
function(){a.isFastZoomEnabled()&&(null!=a.view.backgroundPageShape&&null!=a.view.backgroundPageShape.node&&(mxUtils.setPrefixedStyle(a.view.backgroundPageShape.node.style,"transform-origin",null),mxUtils.setPrefixedStyle(a.view.backgroundPageShape.node.style,"transform",null)),E.style.transformOrigin="",G.style.transformOrigin="",mxClient.IS_SF?(E.style.transform="scale(1)",G.style.transform="scale(1)",window.setTimeout(function(){E.style.transform="";G.style.transform=""},0)):(E.style.transform=
-"",G.style.transform=""),a.view.getDecoratorPane().style.opacity="",a.view.getOverlayPane().style.opacity="");var c=new mxPoint(a.container.scrollLeft,a.container.scrollTop),f=mxUtils.getOffset(a.container),d=a.view.scale,g=0,l=0;null!=H&&(g=a.container.offsetWidth/2-H.x+f.x,l=a.container.offsetHeight/2-H.y+f.y);a.zoom(a.cumulativeZoomFactor);a.view.scale!=d&&(null!=y&&(g+=c.x-y.x,l+=c.y-y.y),null!=b&&e.chromelessResize(!1,null,g*(a.cumulativeZoomFactor-1),l*(a.cumulativeZoomFactor-1)),!mxUtils.hasScrollbars(a.container)||
-0==g&&0==l||(a.container.scrollLeft-=g*(a.cumulativeZoomFactor-1),a.container.scrollTop-=l*(a.cumulativeZoomFactor-1)));null!=K&&E.setAttribute("filter",K);a.cumulativeZoomFactor=1;K=H=y=J=null}),null!=c?c:a.isFastZoomEnabled()?e.wheelZoomDelay:e.lazyZoomDelay))},0)};a.lazyZoom=function(c,f,d){(f=f||!a.scrollbars)&&(H=new mxPoint(a.container.offsetLeft+a.container.clientWidth/2,a.container.offsetTop+a.container.clientHeight/2));c?.15>=this.view.scale*this.cumulativeZoomFactor?this.cumulativeZoomFactor*=
+"",G.style.transform=""),a.view.getDecoratorPane().style.opacity="",a.view.getOverlayPane().style.opacity="");var c=new mxPoint(a.container.scrollLeft,a.container.scrollTop),f=mxUtils.getOffset(a.container),d=a.view.scale,g=0,m=0;null!=H&&(g=a.container.offsetWidth/2-H.x+f.x,m=a.container.offsetHeight/2-H.y+f.y);a.zoom(a.cumulativeZoomFactor);a.view.scale!=d&&(null!=y&&(g+=c.x-y.x,m+=c.y-y.y),null!=b&&e.chromelessResize(!1,null,g*(a.cumulativeZoomFactor-1),m*(a.cumulativeZoomFactor-1)),!mxUtils.hasScrollbars(a.container)||
+0==g&&0==m||(a.container.scrollLeft-=g*(a.cumulativeZoomFactor-1),a.container.scrollTop-=m*(a.cumulativeZoomFactor-1)));null!=K&&E.setAttribute("filter",K);a.cumulativeZoomFactor=1;K=H=y=J=null}),null!=c?c:a.isFastZoomEnabled()?e.wheelZoomDelay:e.lazyZoomDelay))},0)};a.lazyZoom=function(c,f,d){(f=f||!a.scrollbars)&&(H=new mxPoint(a.container.offsetLeft+a.container.clientWidth/2,a.container.offsetTop+a.container.clientHeight/2));c?.15>=this.view.scale*this.cumulativeZoomFactor?this.cumulativeZoomFactor*=
(this.view.scale+.05)/this.view.scale:(this.cumulativeZoomFactor*=this.zoomFactor,this.cumulativeZoomFactor=Math.round(this.view.scale*this.cumulativeZoomFactor*20)/20/this.view.scale):.15>=this.view.scale*this.cumulativeZoomFactor?this.cumulativeZoomFactor*=(this.view.scale-.05)/this.view.scale:(this.cumulativeZoomFactor/=this.zoomFactor,this.cumulativeZoomFactor=Math.round(this.view.scale*this.cumulativeZoomFactor*20)/20/this.view.scale);this.cumulativeZoomFactor=Math.max(.05,Math.min(this.view.scale*
this.cumulativeZoomFactor,160))/this.view.scale;if(a.isFastZoomEnabled()){null==K&&""!=E.getAttribute("filter")&&(K=E.getAttribute("filter"),E.removeAttribute("filter"));y=new mxPoint(a.container.scrollLeft,a.container.scrollTop);c=f?a.container.scrollLeft+a.container.clientWidth/2:H.x+a.container.scrollLeft-a.container.offsetLeft;var b=f?a.container.scrollTop+a.container.clientHeight/2:H.y+a.container.scrollTop-a.container.offsetTop;E.style.transformOrigin=c+"px "+b+"px";E.style.transform="scale("+
this.cumulativeZoomFactor+")";G.style.transformOrigin=c+"px "+b+"px";G.style.transform="scale("+this.cumulativeZoomFactor+")";null!=a.view.backgroundPageShape&&null!=a.view.backgroundPageShape.node&&(c=a.view.backgroundPageShape.node,mxUtils.setPrefixedStyle(c.style,"transform-origin",(f?a.container.clientWidth/2+a.container.scrollLeft-c.offsetLeft+"px":H.x+a.container.scrollLeft-c.offsetLeft-a.container.offsetLeft+"px")+" "+(f?a.container.clientHeight/2+a.container.scrollTop-c.offsetTop+"px":H.y+
@@ -2209,19 +2209,19 @@ this.previousFormat=b);null!=this.foldingEnabled&&this.foldingEnabled!=this.ui.e
(function(){var a=new mxObjectCodec(new ChangePageSetup,["ui","previousColor","previousImage","previousFormat","previousPageScale"]);a.afterDecode=function(a,e,d){d.previousColor=d.color;d.previousImage=d.image;d.previousFormat=d.format;d.previousPageScale=d.pageScale;null!=d.foldingEnabled&&(d.foldingEnabled=!d.foldingEnabled);return d};mxCodecRegistry.register(a)})();EditorUi.prototype.setBackgroundColor=function(a){this.editor.graph.background=a;this.editor.graph.view.validateBackground();this.fireEvent(new mxEventObject("backgroundColorChanged"))};
EditorUi.prototype.setFoldingEnabled=function(a){this.editor.graph.foldingEnabled=a;this.editor.graph.view.revalidate();this.fireEvent(new mxEventObject("foldingEnabledChanged"))};EditorUi.prototype.setPageFormat=function(a){this.editor.graph.pageFormat=a;this.editor.graph.pageVisible?(this.editor.graph.view.validateBackground(),this.editor.graph.sizeDidChange()):this.actions.get("pageView").funct();this.fireEvent(new mxEventObject("pageFormatChanged"))};
EditorUi.prototype.setPageScale=function(a){this.editor.graph.pageScale=a;this.editor.graph.pageVisible?(this.editor.graph.view.validateBackground(),this.editor.graph.sizeDidChange()):this.actions.get("pageView").funct();this.fireEvent(new mxEventObject("pageScaleChanged"))};EditorUi.prototype.setGridColor=function(a){this.editor.graph.view.gridColor=a;this.editor.graph.view.validateBackground();this.fireEvent(new mxEventObject("gridColorChanged"))};
-EditorUi.prototype.addUndoListener=function(){var a=this.actions.get("undo"),b=this.actions.get("redo"),e=this.editor.undoManager,d=mxUtils.bind(this,function(){a.setEnabled(this.canUndo());b.setEnabled(this.canRedo())});e.addListener(mxEvent.ADD,d);e.addListener(mxEvent.UNDO,d);e.addListener(mxEvent.REDO,d);e.addListener(mxEvent.CLEAR,d);var k=this.editor.graph.cellEditor.startEditing;this.editor.graph.cellEditor.startEditing=function(){k.apply(this,arguments);d()};var m=this.editor.graph.cellEditor.stopEditing;
-this.editor.graph.cellEditor.stopEditing=function(a,c){m.apply(this,arguments);d()};d()};
-EditorUi.prototype.updateActionStates=function(){var a=this.editor.graph,b=!a.isSelectionEmpty(),e=!1,d=!1,k=a.getSelectionCells();if(null!=k)for(var m=0;m<k.length;m++){var q=k[m];a.getModel().isEdge(q)&&(d=!0);a.getModel().isVertex(q)&&(e=!0);if(d&&e)break}k="cut copy bold italic underline delete duplicate editStyle editTooltip editLink backgroundColor borderColor edit toFront toBack lockUnlock solid dashed pasteSize dotted fillColor gradientColor shadow fontColor formattedText rounded toggleRounded sharp strokeColor".split(" ");for(m=
-0;m<k.length;m++)this.actions.get(k[m]).setEnabled(b);this.actions.get("setAsDefaultStyle").setEnabled(1==a.getSelectionCount());this.actions.get("clearWaypoints").setEnabled(!a.isSelectionEmpty());this.actions.get("copySize").setEnabled(1==a.getSelectionCount());this.actions.get("turn").setEnabled(!a.isSelectionEmpty());this.actions.get("curved").setEnabled(d);this.actions.get("rotation").setEnabled(e);this.actions.get("wordWrap").setEnabled(e);this.actions.get("autosize").setEnabled(e);d=e&&1==
+EditorUi.prototype.addUndoListener=function(){var a=this.actions.get("undo"),b=this.actions.get("redo"),e=this.editor.undoManager,d=mxUtils.bind(this,function(){a.setEnabled(this.canUndo());b.setEnabled(this.canRedo())});e.addListener(mxEvent.ADD,d);e.addListener(mxEvent.UNDO,d);e.addListener(mxEvent.REDO,d);e.addListener(mxEvent.CLEAR,d);var k=this.editor.graph.cellEditor.startEditing;this.editor.graph.cellEditor.startEditing=function(){k.apply(this,arguments);d()};var l=this.editor.graph.cellEditor.stopEditing;
+this.editor.graph.cellEditor.stopEditing=function(a,c){l.apply(this,arguments);d()};d()};
+EditorUi.prototype.updateActionStates=function(){var a=this.editor.graph,b=!a.isSelectionEmpty(),e=!1,d=!1,k=a.getSelectionCells();if(null!=k)for(var l=0;l<k.length;l++){var q=k[l];a.getModel().isEdge(q)&&(d=!0);a.getModel().isVertex(q)&&(e=!0);if(d&&e)break}k="cut copy bold italic underline delete duplicate editStyle editTooltip editLink backgroundColor borderColor edit toFront toBack lockUnlock solid dashed pasteSize dotted fillColor gradientColor shadow fontColor formattedText rounded toggleRounded sharp strokeColor".split(" ");for(l=
+0;l<k.length;l++)this.actions.get(k[l]).setEnabled(b);this.actions.get("setAsDefaultStyle").setEnabled(1==a.getSelectionCount());this.actions.get("clearWaypoints").setEnabled(!a.isSelectionEmpty());this.actions.get("copySize").setEnabled(1==a.getSelectionCount());this.actions.get("turn").setEnabled(!a.isSelectionEmpty());this.actions.get("curved").setEnabled(d);this.actions.get("rotation").setEnabled(e);this.actions.get("wordWrap").setEnabled(e);this.actions.get("autosize").setEnabled(e);d=e&&1==
a.getSelectionCount();this.actions.get("group").setEnabled(1<a.getSelectionCount()||d&&!a.isContainer(a.getSelectionCell()));this.actions.get("ungroup").setEnabled(1==a.getSelectionCount()&&(0<a.getModel().getChildCount(a.getSelectionCell())||d&&a.isContainer(a.getSelectionCell())));this.actions.get("removeFromGroup").setEnabled(d&&a.getModel().isVertex(a.getModel().getParent(a.getSelectionCell())));a.view.getState(a.getSelectionCell());this.menus.get("navigation").setEnabled(b||null!=a.view.currentRoot);
this.actions.get("collapsible").setEnabled(e&&(a.isContainer(a.getSelectionCell())||0<a.model.getChildCount(a.getSelectionCell())));this.actions.get("home").setEnabled(null!=a.view.currentRoot);this.actions.get("exitGroup").setEnabled(null!=a.view.currentRoot);this.actions.get("enterGroup").setEnabled(1==a.getSelectionCount()&&a.isValidRoot(a.getSelectionCell()));b=1==a.getSelectionCount()&&a.isCellFoldable(a.getSelectionCell());this.actions.get("expand").setEnabled(b);this.actions.get("collapse").setEnabled(b);
this.actions.get("editLink").setEnabled(1==a.getSelectionCount());this.actions.get("openLink").setEnabled(1==a.getSelectionCount()&&null!=a.getLinkForCell(a.getSelectionCell()));this.actions.get("guides").setEnabled(a.isEnabled());this.actions.get("grid").setEnabled(!this.editor.chromeless||this.editor.editable);b=a.isEnabled()&&!a.isCellLocked(a.getDefaultParent());this.menus.get("layout").setEnabled(b);this.menus.get("insert").setEnabled(b);this.menus.get("direction").setEnabled(b&&e);this.menus.get("align").setEnabled(b&&
e&&1<a.getSelectionCount());this.menus.get("distribute").setEnabled(b&&e&&1<a.getSelectionCount());this.actions.get("selectVertices").setEnabled(b);this.actions.get("selectEdges").setEnabled(b);this.actions.get("selectAll").setEnabled(b);this.actions.get("selectNone").setEnabled(b);this.updatePasteActionStates()};EditorUi.prototype.zeroOffset=new mxPoint(0,0);EditorUi.prototype.getDiagramContainerOffset=function(){return this.zeroOffset};
EditorUi.prototype.refresh=function(a){a=null!=a?a:!0;var b=mxClient.IS_IE&&(null==document.documentMode||5==document.documentMode),e=this.container.clientWidth,d=this.container.clientHeight;this.container==document.body&&(e=document.body.clientWidth||document.documentElement.clientWidth,d=b?document.body.clientHeight||document.documentElement.clientHeight:document.documentElement.clientHeight);var k=0;mxClient.IS_IOS&&!window.navigator.standalone&&window.innerHeight!=document.documentElement.clientHeight&&
-(k=document.documentElement.clientHeight-window.innerHeight,window.scrollTo(0,0));var m=Math.max(0,Math.min(this.hsplitPosition,e-this.splitSize-20)),q=0;null!=this.menubar&&(this.menubarContainer.style.height=this.menubarHeight+"px",q+=this.menubarHeight);null!=this.toolbar&&(this.toolbarContainer.style.top=this.menubarHeight+"px",this.toolbarContainer.style.height=this.toolbarHeight+"px",q+=this.toolbarHeight);0<q&&!mxClient.IS_QUIRKS&&(q+=1);var c=0;if(null!=this.sidebarFooterContainer){var f=
-this.footerHeight+k,c=Math.max(0,Math.min(d-q-f,this.sidebarFooterHeight));this.sidebarFooterContainer.style.width=m+"px";this.sidebarFooterContainer.style.height=c+"px";this.sidebarFooterContainer.style.bottom=f+"px"}f=null!=this.format?this.formatWidth:0;this.sidebarContainer.style.top=q+"px";this.sidebarContainer.style.width=m+"px";this.formatContainer.style.top=q+"px";this.formatContainer.style.width=f+"px";this.formatContainer.style.display=null!=this.format?"":"none";var g=this.getDiagramContainerOffset(),
-p=null!=this.hsplit.parentNode?m+this.splitSize:0;this.diagramContainer.style.left=p+g.x+"px";this.diagramContainer.style.top=q+g.y+"px";this.footerContainer.style.height=this.footerHeight+"px";this.hsplit.style.top=this.sidebarContainer.style.top;this.hsplit.style.bottom=this.footerHeight+k+"px";this.hsplit.style.left=m+"px";this.footerContainer.style.display=0==this.footerHeight?"none":"";null!=this.tabContainer&&(this.tabContainer.style.left=p+"px");b?(this.menubarContainer.style.width=e+"px",
-this.toolbarContainer.style.width=this.menubarContainer.style.width,b=Math.max(0,d-this.footerHeight-this.menubarHeight-this.toolbarHeight),this.sidebarContainer.style.height=b-c+"px",this.formatContainer.style.height=b+"px",this.diagramContainer.style.width=null!=this.hsplit.parentNode?Math.max(0,e-m-this.splitSize-f)+"px":e+"px",this.footerContainer.style.width=this.menubarContainer.style.width,c=Math.max(0,d-this.footerHeight-this.menubarHeight-this.toolbarHeight),null!=this.tabContainer&&(this.tabContainer.style.width=
+(k=document.documentElement.clientHeight-window.innerHeight,window.scrollTo(0,0));var l=Math.max(0,Math.min(this.hsplitPosition,e-this.splitSize-20)),q=0;null!=this.menubar&&(this.menubarContainer.style.height=this.menubarHeight+"px",q+=this.menubarHeight);null!=this.toolbar&&(this.toolbarContainer.style.top=this.menubarHeight+"px",this.toolbarContainer.style.height=this.toolbarHeight+"px",q+=this.toolbarHeight);0<q&&!mxClient.IS_QUIRKS&&(q+=1);var c=0;if(null!=this.sidebarFooterContainer){var f=
+this.footerHeight+k,c=Math.max(0,Math.min(d-q-f,this.sidebarFooterHeight));this.sidebarFooterContainer.style.width=l+"px";this.sidebarFooterContainer.style.height=c+"px";this.sidebarFooterContainer.style.bottom=f+"px"}f=null!=this.format?this.formatWidth:0;this.sidebarContainer.style.top=q+"px";this.sidebarContainer.style.width=l+"px";this.formatContainer.style.top=q+"px";this.formatContainer.style.width=f+"px";this.formatContainer.style.display=null!=this.format?"":"none";var g=this.getDiagramContainerOffset(),
+p=null!=this.hsplit.parentNode?l+this.splitSize:0;this.diagramContainer.style.left=p+g.x+"px";this.diagramContainer.style.top=q+g.y+"px";this.footerContainer.style.height=this.footerHeight+"px";this.hsplit.style.top=this.sidebarContainer.style.top;this.hsplit.style.bottom=this.footerHeight+k+"px";this.hsplit.style.left=l+"px";this.footerContainer.style.display=0==this.footerHeight?"none":"";null!=this.tabContainer&&(this.tabContainer.style.left=p+"px");b?(this.menubarContainer.style.width=e+"px",
+this.toolbarContainer.style.width=this.menubarContainer.style.width,b=Math.max(0,d-this.footerHeight-this.menubarHeight-this.toolbarHeight),this.sidebarContainer.style.height=b-c+"px",this.formatContainer.style.height=b+"px",this.diagramContainer.style.width=null!=this.hsplit.parentNode?Math.max(0,e-l-this.splitSize-f)+"px":e+"px",this.footerContainer.style.width=this.menubarContainer.style.width,c=Math.max(0,d-this.footerHeight-this.menubarHeight-this.toolbarHeight),null!=this.tabContainer&&(this.tabContainer.style.width=
this.diagramContainer.style.width,this.tabContainer.style.bottom=this.footerHeight+k+"px",c-=this.tabContainer.clientHeight),this.diagramContainer.style.height=c+"px",this.hsplit.style.height=c+"px"):(0<this.footerHeight&&(this.footerContainer.style.bottom=k+"px"),this.diagramContainer.style.right=f+"px",e=0,null!=this.tabContainer&&(this.tabContainer.style.bottom=this.footerHeight+k+"px",this.tabContainer.style.right=this.diagramContainer.style.right,e=this.tabContainer.clientHeight),this.sidebarContainer.style.bottom=
this.footerHeight+c+k+"px",this.formatContainer.style.bottom=this.footerHeight+k+"px",this.diagramContainer.style.bottom=this.footerHeight+k+e+"px");a&&this.editor.graph.sizeDidChange()};EditorUi.prototype.createTabContainer=function(){return null};
EditorUi.prototype.createDivs=function(){this.menubarContainer=this.createDiv("geMenubarContainer");this.toolbarContainer=this.createDiv("geToolbarContainer");this.sidebarContainer=this.createDiv("geSidebarContainer");this.formatContainer=this.createDiv("geSidebarContainer geFormatContainer");this.diagramContainer=this.createDiv("geDiagramContainer");this.footerContainer=this.createDiv("geFooterContainer");this.hsplit=this.createDiv("geHsplit");this.hsplit.setAttribute("title",mxResources.get("collapseExpand"));
@@ -2232,12 +2232,13 @@ this.sidebar=this.editor.chromeless?null:this.createSidebar(this.sidebarContaine
this.container.appendChild(this.sidebarFooterContainer);this.container.appendChild(this.diagramContainer);null!=this.container&&null!=this.tabContainer&&this.container.appendChild(this.tabContainer);this.toolbar=this.editor.chromeless?null:this.createToolbar(this.createDiv("geToolbar"));null!=this.toolbar&&(this.toolbarContainer.appendChild(this.toolbar.container),this.container.appendChild(this.toolbarContainer));null!=this.sidebar&&(this.container.appendChild(this.hsplit),this.addSplitHandler(this.hsplit,
!0,0,mxUtils.bind(this,function(a){this.hsplitPosition=a;this.refresh()})))};EditorUi.prototype.createStatusContainer=function(){var a=document.createElement("a");a.className="geItem geStatus";420>screen.width&&(a.style.maxWidth=Math.max(20,screen.width-320)+"px",a.style.overflow="hidden");return a};EditorUi.prototype.setStatusText=function(a){this.statusContainer.innerHTML=a};EditorUi.prototype.createToolbar=function(a){return new Toolbar(this,a)};
EditorUi.prototype.createSidebar=function(a){return new Sidebar(this,a)};EditorUi.prototype.createFormat=function(a){return new Format(this,a)};EditorUi.prototype.createFooter=function(){return this.createDiv("geFooter")};EditorUi.prototype.createDiv=function(a){var b=document.createElement("div");b.className=a;return b};
-EditorUi.prototype.addSplitHandler=function(a,b,e,d){function k(a){if(null!=q){var l=new mxPoint(mxEvent.getClientX(a),mxEvent.getClientY(a));d(Math.max(0,c+(b?l.x-q.x:q.y-l.y)-e));mxEvent.consume(a);c!=p()&&(f=!0,g=null)}}function m(a){k(a);q=c=null}var q=null,c=null,f=!0,g=null;mxClient.IS_POINTER&&(a.style.touchAction="none");var p=mxUtils.bind(this,function(){var c=parseInt(b?a.style.left:a.style.bottom);b||(c=c+e-this.footerHeight);return c});mxEvent.addGestureListeners(a,function(a){q=new mxPoint(mxEvent.getClientX(a),
-mxEvent.getClientY(a));c=p();f=!1;mxEvent.consume(a)});mxEvent.addListener(a,"click",mxUtils.bind(this,function(a){if(!f&&this.hsplitClickEnabled){var c=null!=g?g-e:0;g=p();d(c);mxEvent.consume(a)}}));mxEvent.addGestureListeners(document,null,k,m);this.destroyFunctions.push(function(){mxEvent.removeGestureListeners(document,null,k,m)})};
-EditorUi.prototype.handleError=function(a,b,e,d,k){a=null!=a&&null!=a.error?a.error:a;if(null!=a||null!=b){k=mxUtils.htmlEntities(mxResources.get("unknownError"));var m=mxResources.get("ok");b=null!=b?b:mxResources.get("error");null!=a&&null!=a.message&&(k=mxUtils.htmlEntities(a.message));this.showError(b,k,m,e,null,null,null,null,null,null,null,null,d?e:null)}else null!=e&&e()};
-EditorUi.prototype.showError=function(a,b,e,d,k,m,q,c,f,g,p,l,n){a=new ErrorDialog(this,a,b,e||mxResources.get("ok"),d,k,m,q,l,c,f);b=Math.ceil(null!=b?b.length/50:1);this.showDialog(a.container,g||340,p||100+20*b,!0,!1,n);a.init()};EditorUi.prototype.showDialog=function(a,b,e,d,k,m,q,c,f,g){this.editor.graph.tooltipHandler.hideTooltip();null==this.dialogs&&(this.dialogs=[]);this.dialog=new Dialog(this,a,b,e,d,k,m,q,c,f,g);this.dialogs.push(this.dialog)};
+EditorUi.prototype.addSplitHandler=function(a,b,e,d){function k(a){if(null!=q){var m=new mxPoint(mxEvent.getClientX(a),mxEvent.getClientY(a));d(Math.max(0,c+(b?m.x-q.x:q.y-m.y)-e));mxEvent.consume(a);c!=p()&&(f=!0,g=null)}}function l(a){k(a);q=c=null}var q=null,c=null,f=!0,g=null;mxClient.IS_POINTER&&(a.style.touchAction="none");var p=mxUtils.bind(this,function(){var c=parseInt(b?a.style.left:a.style.bottom);b||(c=c+e-this.footerHeight);return c});mxEvent.addGestureListeners(a,function(a){q=new mxPoint(mxEvent.getClientX(a),
+mxEvent.getClientY(a));c=p();f=!1;mxEvent.consume(a)});mxEvent.addListener(a,"click",mxUtils.bind(this,function(a){if(!f&&this.hsplitClickEnabled){var c=null!=g?g-e:0;g=p();d(c);mxEvent.consume(a)}}));mxEvent.addGestureListeners(document,null,k,l);this.destroyFunctions.push(function(){mxEvent.removeGestureListeners(document,null,k,l)})};
+EditorUi.prototype.handleError=function(a,b,e,d,k){a=null!=a&&null!=a.error?a.error:a;if(null!=a||null!=b){k=mxUtils.htmlEntities(mxResources.get("unknownError"));var l=mxResources.get("ok");b=null!=b?b:mxResources.get("error");null!=a&&null!=a.message&&(k=mxUtils.htmlEntities(a.message));this.showError(b,k,l,e,null,null,null,null,null,null,null,null,d?e:null)}else null!=e&&e()};
+EditorUi.prototype.showError=function(a,b,e,d,k,l,q,c,f,g,p,m,n){a=new ErrorDialog(this,a,b,e||mxResources.get("ok"),d,k,l,q,m,c,f);b=Math.ceil(null!=b?b.length/50:1);this.showDialog(a.container,g||340,p||100+20*b,!0,!1,n);a.init()};EditorUi.prototype.showDialog=function(a,b,e,d,k,l,q,c,f,g){this.editor.graph.tooltipHandler.hideTooltip();null==this.dialogs&&(this.dialogs=[]);this.dialog=new Dialog(this,a,b,e,d,k,l,q,c,f,g);this.dialogs.push(this.dialog)};
EditorUi.prototype.hideDialog=function(a,b){if(null!=this.dialogs&&0<this.dialogs.length){var e=this.dialogs.pop();0==e.close(a,b)?this.dialogs.push(e):(this.dialog=0<this.dialogs.length?this.dialogs[this.dialogs.length-1]:null,this.editor.fireEvent(new mxEventObject("hideDialog")),null==this.dialog&&"hidden"!=this.editor.graph.container.style.visibility&&window.setTimeout(mxUtils.bind(this,function(){this.editor.graph.isEditing()&&null!=this.editor.graph.cellEditor.textarea?this.editor.graph.cellEditor.textarea.focus():
-(mxUtils.clearSelection(),this.editor.graph.container.focus())}),0))}};EditorUi.prototype.pickColor=function(a,b){var e=this.editor.graph,d=e.cellEditor.saveSelection(),k=226+17*(Math.ceil(ColorDialog.prototype.presetColors.length/12)+Math.ceil(ColorDialog.prototype.defaultColors.length/12)),m=new ColorDialog(this,a||"none",function(a){e.cellEditor.restoreSelection(d);b(a)},function(){e.cellEditor.restoreSelection(d)});this.showDialog(m.container,230,k,!0,!1);m.init()};
+(mxUtils.clearSelection(),this.editor.graph.container.focus())}),0))}};EditorUi.prototype.ctrlEnter=function(){var a=this.editor.graph;if(a.isEnabled())try{for(var b=a.getSelectionCells(),e=new mxDictionary,d=[],k=0;k<b.length;k++){var l=a.isTableCell(b[k])?a.model.getParent(b[k]):b[k];null==l||e.get(l)||(e.put(l,!0),d.push(l))}a.setSelectionCells(a.duplicateCells(d,!1))}catch(q){this.handleError(q)}};
+EditorUi.prototype.pickColor=function(a,b){var e=this.editor.graph,d=e.cellEditor.saveSelection(),k=226+17*(Math.ceil(ColorDialog.prototype.presetColors.length/12)+Math.ceil(ColorDialog.prototype.defaultColors.length/12)),l=new ColorDialog(this,a||"none",function(a){e.cellEditor.restoreSelection(d);b(a)},function(){e.cellEditor.restoreSelection(d)});this.showDialog(l.container,230,k,!0,!1);l.init()};
EditorUi.prototype.openFile=function(){window.openFile=new OpenFile(mxUtils.bind(this,function(a){this.hideDialog(a)}));this.showDialog((new OpenDialog(this)).container,Editor.useLocalStorage?640:320,Editor.useLocalStorage?480:220,!0,!0,function(){window.openFile=null})};
EditorUi.prototype.extractGraphModelFromHtml=function(a){var b=null;try{var e=a.indexOf("&lt;mxGraphModel ");if(0<=e){var d=a.lastIndexOf("&lt;/mxGraphModel&gt;");d>e&&(b=a.substring(e,d+21).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}}catch(k){}return b};
EditorUi.prototype.extractGraphModelFromEvent=function(a){var b=null,e=null;null!=a&&(a=null!=a.dataTransfer?a.dataTransfer:a.clipboardData,null!=a&&(10==document.documentMode||11==document.documentMode?e=a.getData("Text"):(e=0<=mxUtils.indexOf(a.types,"text/html")?a.getData("text/html"):null,mxUtils.indexOf(a.types,null==e||0==e.length)&&(e=a.getData("text/plain"))),null!=e&&(e=Graph.zapGremlins(mxUtils.trim(e)),a=this.extractGraphModelFromHtml(e),null!=a&&(e=a))));null!=e&&this.isCompatibleString(e)&&
@@ -2245,48 +2246,47 @@ EditorUi.prototype.extractGraphModelFromEvent=function(a){var b=null,e=null;null
EditorUi.prototype.save=function(a){if(null!=a){this.editor.graph.isEditing()&&this.editor.graph.stopEditing();var b=mxUtils.getXml(this.editor.getGraphXml());try{if(Editor.useLocalStorage){if(null!=localStorage.getItem(a)&&!mxUtils.confirm(mxResources.get("replaceIt",[a])))return;localStorage.setItem(a,b);this.editor.setStatus(mxUtils.htmlEntities(mxResources.get("saved"))+" "+new Date)}else if(b.length<MAX_REQUEST_SIZE)(new mxXmlRequest(SAVE_URL,"filename="+encodeURIComponent(a)+"&xml="+encodeURIComponent(b))).simulate(document,
"_blank");else{mxUtils.alert(mxResources.get("drawingTooLarge"));mxUtils.popup(b);return}this.editor.setModified(!1);this.editor.setFilename(a);this.updateDocumentTitle()}catch(e){this.editor.setStatus(mxUtils.htmlEntities(mxResources.get("errorSavingFile")))}}};
EditorUi.prototype.executeLayout=function(a,b,e){var d=this.editor.graph;if(d.isEnabled()){d.getModel().beginUpdate();try{a()}catch(k){throw k;}finally{this.allowAnimation&&b&&(null==navigator.userAgent||0>navigator.userAgent.indexOf("Camino"))?(a=new mxMorphing(d),a.addListener(mxEvent.DONE,mxUtils.bind(this,function(){d.getModel().endUpdate();null!=e&&e()})),a.startAnimation()):(d.getModel().endUpdate(),null!=e&&e())}}};
-EditorUi.prototype.showImageDialog=function(a,b,e,d){d=this.editor.graph.cellEditor;var k=d.saveSelection(),m=mxUtils.prompt(a,b);d.restoreSelection(k);if(null!=m&&0<m.length){var q=new Image;q.onload=function(){e(m,q.width,q.height)};q.onerror=function(){e(null);mxUtils.alert(mxResources.get("fileNotFound"))};q.src=m}else e(null)};EditorUi.prototype.showLinkDialog=function(a,b,e){a=new LinkDialog(this,a,b,e);this.showDialog(a.container,420,90,!0,!0);a.init()};
+EditorUi.prototype.showImageDialog=function(a,b,e,d){d=this.editor.graph.cellEditor;var k=d.saveSelection(),l=mxUtils.prompt(a,b);d.restoreSelection(k);if(null!=l&&0<l.length){var q=new Image;q.onload=function(){e(l,q.width,q.height)};q.onerror=function(){e(null);mxUtils.alert(mxResources.get("fileNotFound"))};q.src=l}else e(null)};EditorUi.prototype.showLinkDialog=function(a,b,e){a=new LinkDialog(this,a,b,e);this.showDialog(a.container,420,90,!0,!0);a.init()};
EditorUi.prototype.showDataDialog=function(a){null!=a&&(a=new EditDataDialog(this,a),this.showDialog(a.container,480,420,!0,!1,null,!1),a.init())};
EditorUi.prototype.showBackgroundImageDialog=function(a){a=null!=a?a:mxUtils.bind(this,function(a){a=new ChangePageSetup(this,null,a);a.ignoreColor=!0;this.editor.graph.model.execute(a)});var b=mxUtils.prompt(mxResources.get("backgroundImage"),"");if(null!=b&&0<b.length){var e=new Image;e.onload=function(){a(new mxImage(b,e.width,e.height))};e.onerror=function(){a(null);mxUtils.alert(mxResources.get("fileNotFound"))};e.src=b}else a(null)};
EditorUi.prototype.setBackgroundImage=function(a){this.editor.graph.setBackgroundImage(a);this.editor.graph.view.validateBackgroundImage();this.fireEvent(new mxEventObject("backgroundImageChanged"))};EditorUi.prototype.confirm=function(a,b,e){mxUtils.confirm(a)?null!=b&&b():null!=e&&e()};
EditorUi.prototype.createOutline=function(a){var b=new mxOutline(this.editor.graph);b.border=20;mxEvent.addListener(window,"resize",function(){b.update()});this.addListener("pageFormatChanged",function(){b.update()});return b};EditorUi.prototype.altShiftActions={67:"clearWaypoints",65:"connectionArrows",76:"editLink",80:"connectionPoints",84:"editTooltip",86:"pasteSize",88:"copySize"};
-EditorUi.prototype.createKeyHandler=function(a){function b(a,f,b){q.push(function(){if(!d.isSelectionEmpty()&&d.isEnabled())if(f=null!=f?f:1,b){d.getModel().beginUpdate();try{for(var c=d.getSelectionCells(),g=0;g<c.length;g++)if(d.getModel().isVertex(c[g])&&d.isCellResizable(c[g])){var e=d.getCellGeometry(c[g]);null!=e&&(e=e.clone(),37==a?e.width=Math.max(0,e.width-f):38==a?e.height=Math.max(0,e.height-f):39==a?e.width+=f:40==a&&(e.height+=f),d.getModel().setGeometry(c[g],e))}}finally{d.getModel().endUpdate()}}else{var l=
-d.getSelectionCell(),e=d.model.getParent(l),c=null;1==d.getSelectionCount()&&d.model.isVertex(l)&&null!=d.layoutManager&&!d.isCellLocked(l)&&(c=d.layoutManager.getLayout(e));if(null!=c&&c.constructor==mxStackLayout)c=e.getIndex(l),37==a||38==a?d.model.add(e,l,Math.max(0,c-1)):39!=a&&40!=a||d.model.add(e,l,Math.min(d.model.getChildCount(e),c+1));else{c=d.getMovableCells(d.getSelectionCells());l=[];for(g=0;g<c.length;g++)e=d.getCurrentCellStyle(c[g]),"1"==mxUtils.getValue(e,"part","0")?(e=d.model.getParent(c[g]),
-d.model.isVertex(e)&&0>mxUtils.indexOf(c,e)&&l.push(e)):l.push(c[g]);0<l.length&&(c=e=0,37==a?e=-f:38==a?c=-f:39==a?e=f:40==a&&(c=f),d.moveCells(l,e,c))}}});null!=c&&window.clearTimeout(c);c=window.setTimeout(function(){if(0<q.length){d.getModel().beginUpdate();try{for(var a=0;a<q.length;a++)q[a]();q=[]}finally{d.getModel().endUpdate()}}},200)}var e=this,d=this.editor.graph,k=new mxKeyHandler(d),m=k.isEventIgnored;k.isEventIgnored=function(a){return!(mxEvent.isShiftDown(a)&&9==a.keyCode)&&(!this.isControlDown(a)||
-mxEvent.isShiftDown(a)||90!=a.keyCode&&89!=a.keyCode&&188!=a.keyCode&&190!=a.keyCode&&85!=a.keyCode)&&(66!=a.keyCode&&73!=a.keyCode||!this.isControlDown(a)||this.graph.cellEditor.isContentEditing()&&!mxClient.IS_FF&&!mxClient.IS_SF)&&m.apply(this,arguments)};k.isEnabledForEvent=function(a){return!mxEvent.isConsumed(a)&&this.isGraphEvent(a)&&this.isEnabled()&&(null==e.dialogs||0==e.dialogs.length)};k.isControlDown=function(a){return mxEvent.isControlDown(a)||mxClient.IS_MAC&&a.metaKey};var q=[],c=
+EditorUi.prototype.createKeyHandler=function(a){function b(a,f,b){q.push(function(){if(!d.isSelectionEmpty()&&d.isEnabled())if(f=null!=f?f:1,b){d.getModel().beginUpdate();try{for(var c=d.getSelectionCells(),g=0;g<c.length;g++)if(d.getModel().isVertex(c[g])&&d.isCellResizable(c[g])){var e=d.getCellGeometry(c[g]);null!=e&&(e=e.clone(),37==a?e.width=Math.max(0,e.width-f):38==a?e.height=Math.max(0,e.height-f):39==a?e.width+=f:40==a&&(e.height+=f),d.getModel().setGeometry(c[g],e))}}finally{d.getModel().endUpdate()}}else{var m=
+d.getSelectionCell(),e=d.model.getParent(m),c=null;1==d.getSelectionCount()&&d.model.isVertex(m)&&null!=d.layoutManager&&!d.isCellLocked(m)&&(c=d.layoutManager.getLayout(e));if(null!=c&&c.constructor==mxStackLayout)c=e.getIndex(m),37==a||38==a?d.model.add(e,m,Math.max(0,c-1)):39!=a&&40!=a||d.model.add(e,m,Math.min(d.model.getChildCount(e),c+1));else{c=d.getMovableCells(d.getSelectionCells());m=[];for(g=0;g<c.length;g++)e=d.getCurrentCellStyle(c[g]),"1"==mxUtils.getValue(e,"part","0")?(e=d.model.getParent(c[g]),
+d.model.isVertex(e)&&0>mxUtils.indexOf(c,e)&&m.push(e)):m.push(c[g]);0<m.length&&(c=e=0,37==a?e=-f:38==a?c=-f:39==a?e=f:40==a&&(c=f),d.moveCells(m,e,c))}}});null!=c&&window.clearTimeout(c);c=window.setTimeout(function(){if(0<q.length){d.getModel().beginUpdate();try{for(var a=0;a<q.length;a++)q[a]();q=[]}finally{d.getModel().endUpdate()}}},200)}var e=this,d=this.editor.graph,k=new mxKeyHandler(d),l=k.isEventIgnored;k.isEventIgnored=function(a){return!(mxEvent.isShiftDown(a)&&9==a.keyCode)&&(!this.isControlDown(a)||
+mxEvent.isShiftDown(a)||90!=a.keyCode&&89!=a.keyCode&&188!=a.keyCode&&190!=a.keyCode&&85!=a.keyCode)&&(66!=a.keyCode&&73!=a.keyCode||!this.isControlDown(a)||this.graph.cellEditor.isContentEditing()&&!mxClient.IS_FF&&!mxClient.IS_SF)&&l.apply(this,arguments)};k.isEnabledForEvent=function(a){return!mxEvent.isConsumed(a)&&this.isGraphEvent(a)&&this.isEnabled()&&(null==e.dialogs||0==e.dialogs.length)};k.isControlDown=function(a){return mxEvent.isControlDown(a)||mxClient.IS_MAC&&a.metaKey};var q=[],c=
null,f={37:mxConstants.DIRECTION_WEST,38:mxConstants.DIRECTION_NORTH,39:mxConstants.DIRECTION_EAST,40:mxConstants.DIRECTION_SOUTH},g=k.getFunction;mxKeyHandler.prototype.getFunction=function(a){if(d.isEnabled()){if(mxEvent.isShiftDown(a)&&mxEvent.isAltDown(a)){var c=e.actions.get(e.altShiftActions[a.keyCode]);if(null!=c)return c.funct}if(9==a.keyCode&&mxEvent.isAltDown(a))return d.cellEditor.isContentEditing()?function(){document.execCommand("outdent",!1,null)}:mxEvent.isShiftDown(a)?function(){d.selectParentCell()}:
function(){d.selectChildCell()};if(null!=f[a.keyCode]&&!d.isSelectionEmpty())if(!this.isControlDown(a)&&mxEvent.isShiftDown(a)&&mxEvent.isAltDown(a)){if(d.model.isVertex(d.getSelectionCell()))return function(){var c=d.connectVertex(d.getSelectionCell(),f[a.keyCode],d.defaultEdgeLength,a,!0);null!=c&&0<c.length&&(1==c.length&&d.model.isEdge(c[0])?d.setSelectionCell(d.model.getTerminal(c[0],!1)):d.setSelectionCell(c[c.length-1]),d.scrollCellToVisible(d.getSelectionCell()),null!=e.hoverIcons&&e.hoverIcons.update(d.view.getState(d.getSelectionCell())))}}else return this.isControlDown(a)?
-function(){b(a.keyCode,mxEvent.isShiftDown(a)?d.gridSize:null,!0)}:function(){b(a.keyCode,mxEvent.isShiftDown(a)?d.gridSize:null)}}return g.apply(this,arguments)};k.bindAction=mxUtils.bind(this,function(a,c,f,d){var b=this.actions.get(f);null!=b&&(f=function(){b.isEnabled()&&b.funct()},c?d?k.bindControlShiftKey(a,f):k.bindControlKey(a,f):d?k.bindShiftKey(a,f):k.bindKey(a,f))});var p=this,l=k.escape;k.escape=function(a){l.apply(this,arguments)};k.enter=function(){};k.bindControlShiftKey(36,function(){d.exitGroup()});
-k.bindControlShiftKey(35,function(){d.enterGroup()});k.bindShiftKey(36,function(){d.home()});k.bindKey(35,function(){d.refresh()});k.bindAction(107,!0,"zoomIn");k.bindAction(109,!0,"zoomOut");k.bindAction(80,!0,"print");k.bindAction(79,!0,"outline",!0);if(!this.editor.chromeless||this.editor.editable)k.bindControlKey(36,function(){d.isEnabled()&&d.foldCells(!0)}),k.bindControlKey(35,function(){d.isEnabled()&&d.foldCells(!1)}),k.bindControlKey(13,function(){if(d.isEnabled())try{d.setSelectionCells(d.duplicateCells(d.getSelectionCells(),
-!1))}catch(n){p.handleError(n)}}),k.bindAction(8,!1,"delete"),k.bindAction(8,!0,"deleteAll"),k.bindAction(46,!1,"delete"),k.bindAction(46,!0,"deleteAll"),k.bindAction(36,!1,"resetView"),k.bindAction(72,!0,"fitWindow",!0),k.bindAction(74,!0,"fitPage"),k.bindAction(74,!0,"fitTwoPages",!0),k.bindAction(48,!0,"customZoom"),k.bindAction(82,!0,"turn"),k.bindAction(82,!0,"clearDefaultStyle",!0),k.bindAction(83,!0,"save"),k.bindAction(83,!0,"saveAs",!0),k.bindAction(65,!0,"selectAll"),k.bindAction(65,!0,
-"selectNone",!0),k.bindAction(73,!0,"selectVertices",!0),k.bindAction(69,!0,"selectEdges",!0),k.bindAction(69,!0,"editStyle"),k.bindAction(66,!0,"bold"),k.bindAction(66,!0,"toBack",!0),k.bindAction(70,!0,"toFront",!0),k.bindAction(68,!0,"duplicate"),k.bindAction(68,!0,"setAsDefaultStyle",!0),k.bindAction(90,!0,"undo"),k.bindAction(89,!0,"autosize",!0),k.bindAction(88,!0,"cut"),k.bindAction(67,!0,"copy"),k.bindAction(86,!0,"paste"),k.bindAction(71,!0,"group"),k.bindAction(77,!0,"editData"),k.bindAction(71,
-!0,"grid",!0),k.bindAction(73,!0,"italic"),k.bindAction(76,!0,"lockUnlock"),k.bindAction(76,!0,"layers",!0),k.bindAction(80,!0,"formatPanel",!0),k.bindAction(85,!0,"underline"),k.bindAction(85,!0,"ungroup",!0),k.bindAction(190,!0,"superscript"),k.bindAction(188,!0,"subscript"),k.bindAction(9,!1,"indent",!0),k.bindKey(13,function(){d.isEnabled()&&d.startEditingAtCell()}),k.bindKey(113,function(){d.isEnabled()&&d.startEditingAtCell()});mxClient.IS_WIN?k.bindAction(89,!0,"redo"):k.bindAction(90,!0,"redo",
-!0);return k};
-EditorUi.prototype.destroy=function(){null!=this.editor&&(this.editor.destroy(),this.editor=null);null!=this.menubar&&(this.menubar.destroy(),this.menubar=null);null!=this.toolbar&&(this.toolbar.destroy(),this.toolbar=null);null!=this.sidebar&&(this.sidebar.destroy(),this.sidebar=null);null!=this.keyHandler&&(this.keyHandler.destroy(),this.keyHandler=null);null!=this.keydownHandler&&(mxEvent.removeListener(document,"keydown",this.keydownHandler),this.keydownHandler=null);null!=this.keyupHandler&&(mxEvent.removeListener(document,
-"keyup",this.keyupHandler),this.keyupHandler=null);null!=this.resizeHandler&&(mxEvent.removeListener(window,"resize",this.resizeHandler),this.resizeHandler=null);null!=this.gestureHandler&&(mxEvent.removeGestureListeners(document,this.gestureHandler),this.gestureHandler=null);null!=this.orientationChangeHandler&&(mxEvent.removeListener(window,"orientationchange",this.orientationChangeHandler),this.orientationChangeHandler=null);null!=this.scrollHandler&&(mxEvent.removeListener(window,"scroll",this.scrollHandler),
-this.scrollHandler=null);if(null!=this.destroyFunctions){for(var a=0;a<this.destroyFunctions.length;a++)this.destroyFunctions[a]();this.destroyFunctions=null}for(var b=[this.menubarContainer,this.toolbarContainer,this.sidebarContainer,this.formatContainer,this.diagramContainer,this.footerContainer,this.chromelessToolbar,this.hsplit,this.sidebarFooterContainer,this.layersDialog],a=0;a<b.length;a++)null!=b[a]&&null!=b[a].parentNode&&b[a].parentNode.removeChild(b[a])};"undefined"!==typeof html4&&(html4.ATTRIBS["a::target"]=0,html4.ATTRIBS["source::src"]=0,html4.ATTRIBS["video::src"]=0);(function(){var a=[["nbsp","160"],["shy","173"]],b=mxUtils.parseXml;mxUtils.parseXml=function(e){for(var d=0;d<a.length;d++)e=e.replace(new RegExp("&"+a[d][0]+";","g"),"&#"+a[d][1]+";");return b(e)}})();
+function(){b(a.keyCode,mxEvent.isShiftDown(a)?d.gridSize:null,!0)}:function(){b(a.keyCode,mxEvent.isShiftDown(a)?d.gridSize:null)}}return g.apply(this,arguments)};k.bindAction=mxUtils.bind(this,function(a,c,f,d){var b=this.actions.get(f);null!=b&&(f=function(){b.isEnabled()&&b.funct()},c?d?k.bindControlShiftKey(a,f):k.bindControlKey(a,f):d?k.bindShiftKey(a,f):k.bindKey(a,f))});var p=this,m=k.escape;k.escape=function(a){m.apply(this,arguments)};k.enter=function(){};k.bindControlShiftKey(36,function(){d.exitGroup()});
+k.bindControlShiftKey(35,function(){d.enterGroup()});k.bindShiftKey(36,function(){d.home()});k.bindKey(35,function(){d.refresh()});k.bindAction(107,!0,"zoomIn");k.bindAction(109,!0,"zoomOut");k.bindAction(80,!0,"print");k.bindAction(79,!0,"outline",!0);if(!this.editor.chromeless||this.editor.editable)k.bindControlKey(36,function(){d.isEnabled()&&d.foldCells(!0)}),k.bindControlKey(35,function(){d.isEnabled()&&d.foldCells(!1)}),k.bindControlKey(13,function(){p.ctrlEnter()}),k.bindAction(8,!1,"delete"),
+k.bindAction(8,!0,"deleteAll"),k.bindAction(46,!1,"delete"),k.bindAction(46,!0,"deleteAll"),k.bindAction(36,!1,"resetView"),k.bindAction(72,!0,"fitWindow",!0),k.bindAction(74,!0,"fitPage"),k.bindAction(74,!0,"fitTwoPages",!0),k.bindAction(48,!0,"customZoom"),k.bindAction(82,!0,"turn"),k.bindAction(82,!0,"clearDefaultStyle",!0),k.bindAction(83,!0,"save"),k.bindAction(83,!0,"saveAs",!0),k.bindAction(65,!0,"selectAll"),k.bindAction(65,!0,"selectNone",!0),k.bindAction(73,!0,"selectVertices",!0),k.bindAction(69,
+!0,"selectEdges",!0),k.bindAction(69,!0,"editStyle"),k.bindAction(66,!0,"bold"),k.bindAction(66,!0,"toBack",!0),k.bindAction(70,!0,"toFront",!0),k.bindAction(68,!0,"duplicate"),k.bindAction(68,!0,"setAsDefaultStyle",!0),k.bindAction(90,!0,"undo"),k.bindAction(89,!0,"autosize",!0),k.bindAction(88,!0,"cut"),k.bindAction(67,!0,"copy"),k.bindAction(86,!0,"paste"),k.bindAction(71,!0,"group"),k.bindAction(77,!0,"editData"),k.bindAction(71,!0,"grid",!0),k.bindAction(73,!0,"italic"),k.bindAction(76,!0,"lockUnlock"),
+k.bindAction(76,!0,"layers",!0),k.bindAction(80,!0,"formatPanel",!0),k.bindAction(85,!0,"underline"),k.bindAction(85,!0,"ungroup",!0),k.bindAction(190,!0,"superscript"),k.bindAction(188,!0,"subscript"),k.bindAction(9,!1,"indent",!0),k.bindKey(13,function(){d.isEnabled()&&d.startEditingAtCell()}),k.bindKey(113,function(){d.isEnabled()&&d.startEditingAtCell()});mxClient.IS_WIN?k.bindAction(89,!0,"redo"):k.bindAction(90,!0,"redo",!0);return k};
+EditorUi.prototype.destroy=function(){null!=this.editor&&(this.editor.destroy(),this.editor=null);null!=this.menubar&&(this.menubar.destroy(),this.menubar=null);null!=this.toolbar&&(this.toolbar.destroy(),this.toolbar=null);null!=this.sidebar&&(this.sidebar.destroy(),this.sidebar=null);null!=this.keyHandler&&(this.keyHandler.destroy(),this.keyHandler=null);null!=this.keydownHandler&&(mxEvent.removeListener(document,"keydown",this.keydownHandler),this.keydownHandler=null);null!=this.keyupHandler&&
+(mxEvent.removeListener(document,"keyup",this.keyupHandler),this.keyupHandler=null);null!=this.resizeHandler&&(mxEvent.removeListener(window,"resize",this.resizeHandler),this.resizeHandler=null);null!=this.gestureHandler&&(mxEvent.removeGestureListeners(document,this.gestureHandler),this.gestureHandler=null);null!=this.orientationChangeHandler&&(mxEvent.removeListener(window,"orientationchange",this.orientationChangeHandler),this.orientationChangeHandler=null);null!=this.scrollHandler&&(mxEvent.removeListener(window,
+"scroll",this.scrollHandler),this.scrollHandler=null);if(null!=this.destroyFunctions){for(var a=0;a<this.destroyFunctions.length;a++)this.destroyFunctions[a]();this.destroyFunctions=null}for(var b=[this.menubarContainer,this.toolbarContainer,this.sidebarContainer,this.formatContainer,this.diagramContainer,this.footerContainer,this.chromelessToolbar,this.hsplit,this.sidebarFooterContainer,this.layersDialog],a=0;a<b.length;a++)null!=b[a]&&null!=b[a].parentNode&&b[a].parentNode.removeChild(b[a])};"undefined"!==typeof html4&&(html4.ATTRIBS["a::target"]=0,html4.ATTRIBS["source::src"]=0,html4.ATTRIBS["video::src"]=0);(function(){var a=[["nbsp","160"],["shy","173"]],b=mxUtils.parseXml;mxUtils.parseXml=function(e){for(var d=0;d<a.length;d++)e=e.replace(new RegExp("&"+a[d][0]+";","g"),"&#"+a[d][1]+";");return b(e)}})();
Date.prototype.toISOString||function(){function a(a){a=String(a);1===a.length&&(a="0"+a);return a}Date.prototype.toISOString=function(){return this.getUTCFullYear()+"-"+a(this.getUTCMonth()+1)+"-"+a(this.getUTCDate())+"T"+a(this.getUTCHours())+":"+a(this.getUTCMinutes())+":"+a(this.getUTCSeconds())+"."+String((this.getUTCMilliseconds()/1E3).toFixed(3)).slice(2,5)+"Z"}}();Date.now||(Date.now=function(){return(new Date).getTime()});mxConstants.POINTS=1;mxConstants.MILLIMETERS=2;mxConstants.INCHES=3;
mxConstants.PIXELS_PER_MM=3.937;mxConstants.PIXELS_PER_INCH=100;mxConstants.SHADOW_OPACITY=.25;mxConstants.SHADOWCOLOR="#000000";mxConstants.VML_SHADOWCOLOR="#d0d0d0";mxGraph.prototype.pageBreakColor="#c0c0c0";mxGraph.prototype.pageScale=1;(function(){try{if(null!=navigator&&null!=navigator.language){var a=navigator.language.toLowerCase();mxGraph.prototype.pageFormat="en-us"===a||"en-ca"===a||"es-mx"===a?mxConstants.PAGE_FORMAT_LETTER_PORTRAIT:mxConstants.PAGE_FORMAT_A4_PORTRAIT}}catch(b){}})();
mxText.prototype.baseSpacingTop=5;mxText.prototype.baseSpacingBottom=1;mxGraphModel.prototype.ignoreRelativeEdgeParent=!1;mxGraphView.prototype.gridImage=mxClient.IS_SVG?"data:image/gif;base64,R0lGODlhCgAKAJEAAAAAAP///8zMzP///yH5BAEAAAMALAAAAAAKAAoAAAIJ1I6py+0Po2wFADs=":IMAGE_PATH+"/grid.gif";mxGraphView.prototype.gridSteps=4;mxGraphView.prototype.minGridSize=4;mxGraphView.prototype.defaultGridColor="#d0d0d0";mxGraphView.prototype.gridColor=mxGraphView.prototype.defaultGridColor;
mxGraphView.prototype.unit=mxConstants.POINTS;mxGraphView.prototype.setUnit=function(a){this.unit!=a&&(this.unit=a,this.fireEvent(new mxEventObject("unitChanged","unit",a)))};mxSvgCanvas2D.prototype.foAltText="[Not supported by viewer]";mxShape.prototype.getConstraints=function(a,b,e){return null};
-Graph=function(a,b,e,d,k,m){mxGraph.call(this,a,b,e,d);this.themes=k||this.defaultThemes;this.currentEdgeStyle=mxUtils.clone(this.defaultEdgeStyle);this.currentVertexStyle=mxUtils.clone(this.defaultVertexStyle);this.standalone=null!=m?m:!1;a=this.baseUrl;b=a.indexOf("//");this.domainPathUrl=this.domainUrl="";0<b&&(b=a.indexOf("/",b+2),0<b&&(this.domainUrl=a.substring(0,b)),b=a.lastIndexOf("/"),0<b&&(this.domainPathUrl=a.substring(0,b+1)));this.isHtmlLabel=function(a){a=this.getCurrentCellStyle(a);
+Graph=function(a,b,e,d,k,l){mxGraph.call(this,a,b,e,d);this.themes=k||this.defaultThemes;this.currentEdgeStyle=mxUtils.clone(this.defaultEdgeStyle);this.currentVertexStyle=mxUtils.clone(this.defaultVertexStyle);this.standalone=null!=l?l:!1;a=this.baseUrl;b=a.indexOf("//");this.domainPathUrl=this.domainUrl="";0<b&&(b=a.indexOf("/",b+2),0<b&&(this.domainUrl=a.substring(0,b)),b=a.lastIndexOf("/"),0<b&&(this.domainPathUrl=a.substring(0,b+1)));this.isHtmlLabel=function(a){a=this.getCurrentCellStyle(a);
return null!=a?"1"==a.html||"wrap"==a[mxConstants.STYLE_WHITE_SPACE]:!1};if(this.edgeMode){var q=null,c=null,f=null,g=null,p=!1;this.addListener(mxEvent.FIRE_MOUSE_EVENT,mxUtils.bind(this,function(a,d){if("mouseDown"==d.getProperty("eventName")&&this.isEnabled()){var b=d.getProperty("event");if(!mxEvent.isControlDown(b.getEvent())&&!mxEvent.isShiftDown(b.getEvent())){var e=b.getState();null!=e&&this.model.isEdge(e.cell)&&(q=new mxPoint(b.getGraphX(),b.getGraphY()),p=this.isCellSelected(e.cell),f=
e,c=b,null!=e.text&&null!=e.text.boundingBox&&mxUtils.contains(e.text.boundingBox,b.getGraphX(),b.getGraphY())?g=mxEvent.LABEL_HANDLE:(e=this.selectionCellsHandler.getHandler(e.cell),null!=e&&null!=e.bends&&0<e.bends.length&&(g=e.getHandleForEvent(b))))}}}));this.addMouseListener({mouseDown:function(a,c){},mouseMove:mxUtils.bind(this,function(a,d){var b=this.selectionCellsHandler.handlers.map,e;for(e in b)if(null!=b[e].index)return;if(this.isEnabled()&&!this.panningHandler.isActive()&&!mxEvent.isControlDown(d.getEvent())&&
-!mxEvent.isShiftDown(d.getEvent())&&!mxEvent.isAltDown(d.getEvent()))if(e=this.tolerance,null!=q&&null!=f&&null!=c){if(b=f,Math.abs(q.x-d.getGraphX())>e||Math.abs(q.y-d.getGraphY())>e){this.isCellSelected(b.cell)||this.setSelectionCell(b.cell);var l=this.selectionCellsHandler.getHandler(b.cell);if(null!=l&&null!=l.bends&&0<l.bends.length){var n=l.getHandleForEvent(c),u=this.view.getEdgeStyle(b);e=u==mxEdgeStyle.EntityRelation;p||g!=mxEvent.LABEL_HANDLE||(n=g);if(e&&0!=n&&n!=l.bends.length-1&&n!=mxEvent.LABEL_HANDLE)!e||
-null==b.visibleSourceState&&null==b.visibleTargetState||(this.graphHandler.reset(),d.consume());else if(n==mxEvent.LABEL_HANDLE||0==n||null!=b.visibleSourceState||n==l.bends.length-1||null!=b.visibleTargetState)e||n==mxEvent.LABEL_HANDLE||(e=b.absolutePoints,null!=e&&(null==u&&null==n||u==mxEdgeStyle.OrthConnector)&&(n=g,null==n&&(n=new mxRectangle(q.x,q.y),n.grow(mxEdgeHandler.prototype.handleImage.width/2),mxUtils.contains(n,e[0].x,e[0].y)?n=0:mxUtils.contains(n,e[e.length-1].x,e[e.length-1].y)?
-n=l.bends.length-1:null!=u&&(2==e.length||3==e.length&&(0==Math.round(e[0].x-e[1].x)&&0==Math.round(e[1].x-e[2].x)||0==Math.round(e[0].y-e[1].y)&&0==Math.round(e[1].y-e[2].y)))?n=2:(n=mxUtils.findNearestSegment(b,q.x,q.y),n=null==u?mxEvent.VIRTUAL_HANDLE-n:n+1))),null==n&&(n=mxEvent.VIRTUAL_HANDLE)),l.start(d.getGraphX(),d.getGraphX(),n),g=q=c=f=null,p=!1,d.consume(),this.graphHandler.reset()}}}else if(b=d.getState(),null!=b&&this.model.isEdge(b.cell)){l=null;e=b.absolutePoints;if(null!=e)if(n=new mxRectangle(d.getGraphX(),
-d.getGraphY()),n.grow(mxEdgeHandler.prototype.handleImage.width/2),null!=b.text&&null!=b.text.boundingBox&&mxUtils.contains(b.text.boundingBox,d.getGraphX(),d.getGraphY()))l="move";else if(mxUtils.contains(n,e[0].x,e[0].y)||mxUtils.contains(n,e[e.length-1].x,e[e.length-1].y))l="pointer";else if(null!=b.visibleSourceState||null!=b.visibleTargetState)u=this.view.getEdgeStyle(b),l="crosshair",u!=mxEdgeStyle.EntityRelation&&this.isOrthogonal(b)&&(u=mxUtils.findNearestSegment(b,d.getGraphX(),d.getGraphY()),
-u<e.length-1&&0<=u&&(l=0==Math.round(e[u].x-e[u+1].x)?"col-resize":"row-resize"));null!=l&&b.setCursor(l)}}),mouseUp:mxUtils.bind(this,function(a,d){g=q=c=f=null})})}this.cellRenderer.getLabelValue=function(a){var c=mxCellRenderer.prototype.getLabelValue.apply(this,arguments);a.view.graph.isHtmlLabel(a.cell)&&(c=1!=a.style.html?mxUtils.htmlEntities(c,!1):a.view.graph.sanitizeHtml(c));return c};if("undefined"!==typeof mxVertexHandler){this.setConnectable(!0);this.setDropEnabled(!0);this.setPanning(!0);
-this.setTooltips(!0);this.setAllowLoops(!0);this.allowAutoPanning=!0;this.constrainChildren=this.resetEdgesOnConnect=!1;this.constrainRelativeChildren=!0;this.graphHandler.scrollOnMove=!1;this.graphHandler.scaleGrid=!0;this.connectionHandler.setCreateTarget(!1);this.connectionHandler.insertBeforeSource=!0;this.connectionHandler.isValidSource=function(a,c){return!1};this.alternateEdgeStyle="vertical";null==d&&this.loadStylesheet();var l=this.graphHandler.getGuideStates;this.graphHandler.getGuideStates=
-function(){var a=l.apply(this,arguments);if(this.graph.pageVisible){for(var c=[],f=this.graph.pageFormat,d=this.graph.pageScale,b=f.width*d,f=f.height*d,d=this.graph.view.translate,e=this.graph.view.scale,g=this.graph.getPageLayout(),p=0;p<g.width;p++)c.push(new mxRectangle(((g.x+p)*b+d.x)*e,(g.y*f+d.y)*e,b*e,f*e));for(p=1;p<g.height;p++)c.push(new mxRectangle((g.x*b+d.x)*e,((g.y+p)*f+d.y)*e,b*e,f*e));a=c.concat(a)}return a};mxDragSource.prototype.dragElementZIndex=mxPopupMenu.prototype.zIndex;mxGuide.prototype.getGuideColor=
+!mxEvent.isShiftDown(d.getEvent())&&!mxEvent.isAltDown(d.getEvent()))if(e=this.tolerance,null!=q&&null!=f&&null!=c){if(b=f,Math.abs(q.x-d.getGraphX())>e||Math.abs(q.y-d.getGraphY())>e){this.isCellSelected(b.cell)||this.setSelectionCell(b.cell);var m=this.selectionCellsHandler.getHandler(b.cell);if(null!=m&&null!=m.bends&&0<m.bends.length){var n=m.getHandleForEvent(c),u=this.view.getEdgeStyle(b);e=u==mxEdgeStyle.EntityRelation;p||g!=mxEvent.LABEL_HANDLE||(n=g);if(e&&0!=n&&n!=m.bends.length-1&&n!=mxEvent.LABEL_HANDLE)!e||
+null==b.visibleSourceState&&null==b.visibleTargetState||(this.graphHandler.reset(),d.consume());else if(n==mxEvent.LABEL_HANDLE||0==n||null!=b.visibleSourceState||n==m.bends.length-1||null!=b.visibleTargetState)e||n==mxEvent.LABEL_HANDLE||(e=b.absolutePoints,null!=e&&(null==u&&null==n||u==mxEdgeStyle.OrthConnector)&&(n=g,null==n&&(n=new mxRectangle(q.x,q.y),n.grow(mxEdgeHandler.prototype.handleImage.width/2),mxUtils.contains(n,e[0].x,e[0].y)?n=0:mxUtils.contains(n,e[e.length-1].x,e[e.length-1].y)?
+n=m.bends.length-1:null!=u&&(2==e.length||3==e.length&&(0==Math.round(e[0].x-e[1].x)&&0==Math.round(e[1].x-e[2].x)||0==Math.round(e[0].y-e[1].y)&&0==Math.round(e[1].y-e[2].y)))?n=2:(n=mxUtils.findNearestSegment(b,q.x,q.y),n=null==u?mxEvent.VIRTUAL_HANDLE-n:n+1))),null==n&&(n=mxEvent.VIRTUAL_HANDLE)),m.start(d.getGraphX(),d.getGraphX(),n),g=q=c=f=null,p=!1,d.consume(),this.graphHandler.reset()}}}else if(b=d.getState(),null!=b&&this.model.isEdge(b.cell)){m=null;e=b.absolutePoints;if(null!=e)if(n=new mxRectangle(d.getGraphX(),
+d.getGraphY()),n.grow(mxEdgeHandler.prototype.handleImage.width/2),null!=b.text&&null!=b.text.boundingBox&&mxUtils.contains(b.text.boundingBox,d.getGraphX(),d.getGraphY()))m="move";else if(mxUtils.contains(n,e[0].x,e[0].y)||mxUtils.contains(n,e[e.length-1].x,e[e.length-1].y))m="pointer";else if(null!=b.visibleSourceState||null!=b.visibleTargetState)u=this.view.getEdgeStyle(b),m="crosshair",u!=mxEdgeStyle.EntityRelation&&this.isOrthogonal(b)&&(u=mxUtils.findNearestSegment(b,d.getGraphX(),d.getGraphY()),
+u<e.length-1&&0<=u&&(m=0==Math.round(e[u].x-e[u+1].x)?"col-resize":"row-resize"));null!=m&&b.setCursor(m)}}),mouseUp:mxUtils.bind(this,function(a,d){g=q=c=f=null})})}this.cellRenderer.getLabelValue=function(a){var c=mxCellRenderer.prototype.getLabelValue.apply(this,arguments);a.view.graph.isHtmlLabel(a.cell)&&(c=1!=a.style.html?mxUtils.htmlEntities(c,!1):a.view.graph.sanitizeHtml(c));return c};if("undefined"!==typeof mxVertexHandler){this.setConnectable(!0);this.setDropEnabled(!0);this.setPanning(!0);
+this.setTooltips(!0);this.setAllowLoops(!0);this.allowAutoPanning=!0;this.constrainChildren=this.resetEdgesOnConnect=!1;this.constrainRelativeChildren=!0;this.graphHandler.scrollOnMove=!1;this.graphHandler.scaleGrid=!0;this.connectionHandler.setCreateTarget(!1);this.connectionHandler.insertBeforeSource=!0;this.connectionHandler.isValidSource=function(a,c){return!1};this.alternateEdgeStyle="vertical";null==d&&this.loadStylesheet();var m=this.graphHandler.getGuideStates;this.graphHandler.getGuideStates=
+function(){var a=m.apply(this,arguments);if(this.graph.pageVisible){for(var c=[],f=this.graph.pageFormat,d=this.graph.pageScale,b=f.width*d,f=f.height*d,d=this.graph.view.translate,e=this.graph.view.scale,g=this.graph.getPageLayout(),p=0;p<g.width;p++)c.push(new mxRectangle(((g.x+p)*b+d.x)*e,(g.y*f+d.y)*e,b*e,f*e));for(p=1;p<g.height;p++)c.push(new mxRectangle((g.x*b+d.x)*e,((g.y+p)*f+d.y)*e,b*e,f*e));a=c.concat(a)}return a};mxDragSource.prototype.dragElementZIndex=mxPopupMenu.prototype.zIndex;mxGuide.prototype.getGuideColor=
function(a,c){return null==a.cell?"#ffa500":mxConstants.GUIDE_COLOR};this.graphHandler.createPreviewShape=function(a){this.previewColor="#000000"==this.graph.background?"#ffffff":mxGraphHandler.prototype.previewColor;return mxGraphHandler.prototype.createPreviewShape.apply(this,arguments)};var n=this.graphHandler.getCells;this.graphHandler.getCells=function(a){for(var c=n.apply(this,arguments),f=new mxDictionary,d=[],b=0;b<c.length;b++){var e=this.graph.isTableRow(c[b])&&this.graph.isCellSelected(c[b])?
c[b]:this.graph.getCompositeParent(c[b]);null==e||f.get(e)||(f.put(e,!0),d.push(e))}return d};var v=this.graphHandler.start;this.graphHandler.start=function(a,c,f,d){a=this.graph.getCompositeParent(a);v.apply(this,arguments)};this.connectionHandler.createTargetVertex=function(a,c){c=this.graph.getCompositeParent(c);return mxConnectionHandler.prototype.createTargetVertex.apply(this,arguments)};var t=new mxRubberband(this);this.getRubberband=function(){return t};var u=(new Date).getTime(),A=0,B=this.connectionHandler.mouseMove;
this.connectionHandler.mouseMove=function(){var a=this.currentState;B.apply(this,arguments);a!=this.currentState?(u=(new Date).getTime(),A=0):A=(new Date).getTime()-u};var D=this.connectionHandler.isOutlineConnectEvent;this.connectionHandler.isOutlineConnectEvent=function(a){return null!=this.currentState&&a.getState()==this.currentState&&2E3<A||(null==this.currentState||"0"!=mxUtils.getValue(this.currentState.style,"outlineConnect","1"))&&D.apply(this,arguments)};var C=this.isToggleEvent;this.isToggleEvent=
function(a){return C.apply(this,arguments)||!mxClient.IS_CHROMEOS&&mxEvent.isShiftDown(a)};var x=t.isForceRubberbandEvent;t.isForceRubberbandEvent=function(a){return x.apply(this,arguments)&&!mxEvent.isShiftDown(a.getEvent())&&!mxEvent.isControlDown(a.getEvent())||mxClient.IS_CHROMEOS&&mxEvent.isShiftDown(a.getEvent())||mxUtils.hasScrollbars(this.graph.container)&&mxClient.IS_FF&&mxClient.IS_WIN&&null==a.getState()&&mxEvent.isTouchEvent(a.getEvent())};var F=null;this.panningHandler.addListener(mxEvent.PAN_START,
mxUtils.bind(this,function(){this.isEnabled()&&(F=this.container.style.cursor,this.container.style.cursor="move")}));this.panningHandler.addListener(mxEvent.PAN_END,mxUtils.bind(this,function(){this.isEnabled()&&(this.container.style.cursor=F)}));this.popupMenuHandler.autoExpand=!0;this.popupMenuHandler.isSelectOnPopup=function(a){return mxEvent.isMouseEvent(a.getEvent())};var G=this.click;this.click=function(a){var c=null==a.state&&null!=a.sourceState&&this.isCellLocked(a.sourceState.cell);if(this.isEnabled()&&
!c||a.isConsumed())return G.apply(this,arguments);var f=c?a.sourceState.cell:a.getCell();null!=f&&(f=this.getClickableLinkForCell(f),null!=f&&(this.isCustomLink(f)?this.customLinkClicked(f):this.openLink(f)));this.isEnabled()&&c&&this.clearSelection()};this.tooltipHandler.getStateForEvent=function(a){return a.sourceState};this.getCursorForMouseEvent=function(a){var c=null==a.state&&null!=a.sourceState&&this.isCellLocked(a.sourceState.cell);return this.getCursorForCell(c?a.sourceState.cell:a.getCell())};
-var E=this.getCursorForCell;this.getCursorForCell=function(a){if(!this.isEnabled()||this.isCellLocked(a)){if(null!=this.getClickableLinkForCell(a))return"pointer";if(this.isCellLocked(a))return"default"}return E.apply(this,arguments)};this.selectRegion=function(a,c){var f=this.getAllCells(a.x,a.y,a.width,a.height);this.selectCellsForEvent(f,c);return f};this.getAllCells=function(a,c,f,d,b,e){e=null!=e?e:[];if(0<f||0<d){var g=this.getModel(),l=a+f,p=c+d;null==b&&(b=this.getCurrentRoot(),null==b&&(b=
-g.getRoot()));if(null!=b)for(var n=g.getChildCount(b),u=0;u<n;u++){var t=g.getChildAt(b,u),y=this.view.getState(t);if(null!=y&&this.isCellVisible(t)&&"1"!=mxUtils.getValue(y.style,"locked","0")){var z=mxUtils.getValue(y.style,mxConstants.STYLE_ROTATION)||0;0!=z&&(y=mxUtils.getBoundingBox(y,z));(g.isEdge(t)||g.isVertex(t))&&y.x>=a&&y.y+y.height<=p&&y.y>=c&&y.x+y.width<=l&&e.push(t);this.getAllCells(a,c,f,d,t,e)}}}return e};var J=this.graphHandler.shouldRemoveCellsFromParent;this.graphHandler.shouldRemoveCellsFromParent=
+var E=this.getCursorForCell;this.getCursorForCell=function(a){if(!this.isEnabled()||this.isCellLocked(a)){if(null!=this.getClickableLinkForCell(a))return"pointer";if(this.isCellLocked(a))return"default"}return E.apply(this,arguments)};this.selectRegion=function(a,c){var f=this.getAllCells(a.x,a.y,a.width,a.height);this.selectCellsForEvent(f,c);return f};this.getAllCells=function(a,c,f,d,b,e){e=null!=e?e:[];if(0<f||0<d){var g=this.getModel(),m=a+f,p=c+d;null==b&&(b=this.getCurrentRoot(),null==b&&(b=
+g.getRoot()));if(null!=b)for(var n=g.getChildCount(b),u=0;u<n;u++){var t=g.getChildAt(b,u),y=this.view.getState(t);if(null!=y&&this.isCellVisible(t)&&"1"!=mxUtils.getValue(y.style,"locked","0")){var z=mxUtils.getValue(y.style,mxConstants.STYLE_ROTATION)||0;0!=z&&(y=mxUtils.getBoundingBox(y,z));(g.isEdge(t)||g.isVertex(t))&&y.x>=a&&y.y+y.height<=p&&y.y>=c&&y.x+y.width<=m&&e.push(t);this.getAllCells(a,c,f,d,t,e)}}}return e};var J=this.graphHandler.shouldRemoveCellsFromParent;this.graphHandler.shouldRemoveCellsFromParent=
function(a,c,f){return this.graph.isCellSelected(a)?!1:J.apply(this,arguments)};this.isCellLocked=function(a){for(a=this.view.getState(a);null!=a;){if("1"==mxUtils.getValue(a.style,"locked","0"))return!0;a=this.view.getState(this.model.getParent(a.cell))}return!1};var H=null;this.addListener(mxEvent.FIRE_MOUSE_EVENT,mxUtils.bind(this,function(a,c){if("mouseDown"==c.getProperty("eventName")){var f=c.getProperty("event").getState();H=null==f||this.isSelectionEmpty()||this.isCellSelected(f.cell)?null:
this.getSelectionCells()}}));this.addListener(mxEvent.TAP_AND_HOLD,mxUtils.bind(this,function(a,c){if(!mxEvent.isMultiTouchEvent(c)){var f=c.getProperty("event"),d=c.getProperty("cell");null==d?(f=mxUtils.convertPoint(this.container,mxEvent.getClientX(f),mxEvent.getClientY(f)),t.start(f.x,f.y)):null!=H?this.addSelectionCells(H):1<this.getSelectionCount()&&this.isCellSelected(d)&&this.removeSelectionCell(d);H=null;c.consume()}}));this.connectionHandler.selectCells=function(a,c){this.graph.setSelectionCell(c||
a)};this.connectionHandler.constraintHandler.isStateIgnored=function(a,c){return c&&a.view.graph.isCellSelected(a.cell)};this.selectionModel.addListener(mxEvent.CHANGE,mxUtils.bind(this,function(){var a=this.connectionHandler.constraintHandler;null!=a.currentFocus&&a.isStateIgnored(a.currentFocus,!0)&&(a.currentFocus=null,a.constraints=null,a.destroyIcons());a.destroyFocusHighlight()}));Graph.touchStyle&&this.initTouch();var y=this.updateMouseEvent;this.updateMouseEvent=function(a){a=y.apply(this,
@@ -2299,18 +2299,18 @@ Graph.removePasteFormatting=function(a){for(;null!=a;)null!=a.firstChild&&Graph.
mxUtils.extend(Graph,mxGraph);Graph.prototype.minFitScale=null;Graph.prototype.maxFitScale=null;Graph.prototype.linkPolicy="frame"==urlParams.target?"blank":urlParams.target||"auto";Graph.prototype.linkTarget="frame"==urlParams.target?"_self":"_blank";Graph.prototype.linkRelation="nofollow noopener noreferrer";Graph.prototype.defaultScrollbars=!mxClient.IS_IOS;Graph.prototype.defaultPageVisible=!0;Graph.prototype.lightbox=!1;Graph.prototype.defaultPageBackgroundColor="#ffffff";
Graph.prototype.defaultPageBorderColor="#ffffff";Graph.prototype.scrollTileSize=new mxRectangle(0,0,400,400);Graph.prototype.transparentBackground=!0;Graph.prototype.selectParentAfterDelete=!1;Graph.prototype.defaultEdgeLength=80;Graph.prototype.edgeMode=!1;Graph.prototype.connectionArrowsEnabled=!0;Graph.prototype.placeholderPattern=RegExp("%(date{.*}|[^%^{^}]+)%","g");Graph.prototype.absoluteUrlPattern=/^(?:[a-z]+:)?\/\//i;Graph.prototype.defaultThemeName="default";
Graph.prototype.defaultThemes={};Graph.prototype.baseUrl=null!=urlParams.base?decodeURIComponent(urlParams.base):(window!=window.top?document.referrer:document.location.toString()).split("#")[0];Graph.prototype.editAfterInsert=!1;Graph.prototype.builtInProperties=["label","tooltip","placeholders","placeholder"];Graph.prototype.standalone=!1;
-Graph.prototype.init=function(a){mxGraph.prototype.init.apply(this,arguments);this.cellRenderer.initializeLabel=function(a,e){mxCellRenderer.prototype.initializeLabel.apply(this,arguments);var d=a.view.graph.tolerance,b=!0,m=null,q=mxUtils.bind(this,function(a){b=!0;m=new mxPoint(mxEvent.getClientX(a),mxEvent.getClientY(a))}),c=mxUtils.bind(this,function(a){b=b&&null!=m&&Math.abs(m.x-mxEvent.getClientX(a))<d&&Math.abs(m.y-mxEvent.getClientY(a))<d}),f=mxUtils.bind(this,function(c){if(b)for(var f=mxEvent.getSource(c);null!=
+Graph.prototype.init=function(a){mxGraph.prototype.init.apply(this,arguments);this.cellRenderer.initializeLabel=function(a,e){mxCellRenderer.prototype.initializeLabel.apply(this,arguments);var d=a.view.graph.tolerance,b=!0,l=null,q=mxUtils.bind(this,function(a){b=!0;l=new mxPoint(mxEvent.getClientX(a),mxEvent.getClientY(a))}),c=mxUtils.bind(this,function(a){b=b&&null!=l&&Math.abs(l.x-mxEvent.getClientX(a))<d&&Math.abs(l.y-mxEvent.getClientY(a))<d}),f=mxUtils.bind(this,function(c){if(b)for(var f=mxEvent.getSource(c);null!=
f&&f!=e.node;){if("a"==f.nodeName.toLowerCase()){a.view.graph.labelLinkClicked(a,f,c);break}f=f.parentNode}});mxEvent.addGestureListeners(e.node,q,c,f);mxEvent.addListener(e.node,"click",function(a){mxEvent.consume(a)})};this.initLayoutManager()};
(function(){Graph.prototype.useCssTransforms=!1;Graph.prototype.currentScale=1;Graph.prototype.currentTranslate=new mxPoint(0,0);Graph.prototype.isFastZoomEnabled=function(){return"nocss"!=urlParams.zoom&&!mxClient.NO_FO&&!mxClient.IS_EDGE&&!this.useCssTransforms&&this.isCssTransformsSupported()};Graph.prototype.isCssTransformsSupported=function(){return this.dialect==mxConstants.DIALECT_SVG&&!mxClient.NO_FO&&(!this.lightbox||!mxClient.IS_SF)};Graph.prototype.getCellAt=function(a,b,e,q,c,f){this.useCssTransforms&&
-(a=a/this.currentScale-this.currentTranslate.x,b=b/this.currentScale-this.currentTranslate.y);return this.getScaledCellAt.apply(this,arguments)};Graph.prototype.getScaledCellAt=function(a,b,e,q,c,f){q=null!=q?q:!0;c=null!=c?c:!0;null==e&&(e=this.getCurrentRoot(),null==e&&(e=this.getModel().getRoot()));if(null!=e)for(var d=this.model.getChildCount(e)-1;0<=d;d--){var p=this.model.getChildAt(e,d),l=this.getScaledCellAt(a,b,p,q,c,f);if(null!=l)return l;if(this.isCellVisible(p)&&(c&&this.model.isEdge(p)||
-q&&this.model.isVertex(p))&&(l=this.view.getState(p),null!=l&&(null==f||!f(l,a,b))&&this.intersects(l,a,b)))return p}return null};Graph.prototype.isRecursiveVertexResize=function(a){return!this.isSwimlane(a.cell)&&0<this.model.getChildCount(a.cell)&&!this.isCellCollapsed(a.cell)&&"1"==mxUtils.getValue(a.style,"recursiveResize","1")&&null==mxUtils.getValue(a.style,"childLayout",null)};Graph.prototype.isPart=function(a){return"1"==mxUtils.getValue(this.getCurrentCellStyle(a),"part","0")};Graph.prototype.getCompositeParent=
+(a=a/this.currentScale-this.currentTranslate.x,b=b/this.currentScale-this.currentTranslate.y);return this.getScaledCellAt.apply(this,arguments)};Graph.prototype.getScaledCellAt=function(a,b,e,q,c,f){q=null!=q?q:!0;c=null!=c?c:!0;null==e&&(e=this.getCurrentRoot(),null==e&&(e=this.getModel().getRoot()));if(null!=e)for(var d=this.model.getChildCount(e)-1;0<=d;d--){var p=this.model.getChildAt(e,d),m=this.getScaledCellAt(a,b,p,q,c,f);if(null!=m)return m;if(this.isCellVisible(p)&&(c&&this.model.isEdge(p)||
+q&&this.model.isVertex(p))&&(m=this.view.getState(p),null!=m&&(null==f||!f(m,a,b))&&this.intersects(m,a,b)))return p}return null};Graph.prototype.isRecursiveVertexResize=function(a){return!this.isSwimlane(a.cell)&&0<this.model.getChildCount(a.cell)&&!this.isCellCollapsed(a.cell)&&"1"==mxUtils.getValue(a.style,"recursiveResize","1")&&null==mxUtils.getValue(a.style,"childLayout",null)};Graph.prototype.isPart=function(a){return"1"==mxUtils.getValue(this.getCurrentCellStyle(a),"part","0")};Graph.prototype.getCompositeParent=
function(a){for(;this.isPart(a);){var d=this.model.getParent(a);if(!this.model.isVertex(d))break;a=d}return a};mxCellHighlight.prototype.getStrokeWidth=function(a){a=this.strokeWidth;this.graph.useCssTransforms&&(a/=this.graph.currentScale);return a};mxGraphView.prototype.getGraphBounds=function(){var a=this.graphBounds;if(this.graph.useCssTransforms)var b=this.graph.currentTranslate,e=this.graph.currentScale,a=new mxRectangle((a.x+b.x)*e,(a.y+b.y)*e,a.width*e,a.height*e);return a};mxGraphView.prototype.viewStateChanged=
function(){this.graph.useCssTransforms?this.validate():this.revalidate();this.graph.sizeDidChange()};var a=mxGraphView.prototype.validate;mxGraphView.prototype.validate=function(d){this.graph.useCssTransforms&&(this.graph.currentScale=this.scale,this.graph.currentTranslate.x=this.translate.x,this.graph.currentTranslate.y=this.translate.y,this.scale=1,this.translate.x=0,this.translate.y=0);a.apply(this,arguments);this.graph.useCssTransforms&&(this.graph.updateCssTransform(),this.scale=this.graph.currentScale,
this.translate.x=this.graph.currentTranslate.x,this.translate.y=this.graph.currentTranslate.y)};Graph.prototype.updateCssTransform=function(){var a=this.view.getDrawPane();if(null!=a)if(a=a.parentNode,this.useCssTransforms){var b=a.getAttribute("transform");a.setAttribute("transformOrigin","0 0");var e=Math.round(100*this.currentScale)/100;a.setAttribute("transform","scale("+e+","+e+")translate("+Math.round(100*this.currentTranslate.x)/100+","+Math.round(100*this.currentTranslate.y)/100+")");if(b!=
-a.getAttribute("transform"))try{if(mxClient.IS_EDGE){var q=a.style.display;a.style.display="none";a.getBBox();a.style.display=q}}catch(c){}}else a.removeAttribute("transformOrigin"),a.removeAttribute("transform")};var b=mxGraphView.prototype.validateBackgroundPage;mxGraphView.prototype.validateBackgroundPage=function(){var a=this.graph.useCssTransforms,e=this.scale,m=this.translate;a&&(this.scale=this.graph.currentScale,this.translate=this.graph.currentTranslate);b.apply(this,arguments);a&&(this.scale=
-e,this.translate=m)};var e=mxGraph.prototype.updatePageBreaks;mxGraph.prototype.updatePageBreaks=function(a,b,m){var d=this.useCssTransforms,c=this.view.scale,f=this.view.translate;d&&(this.view.scale=1,this.view.translate=new mxPoint(0,0),this.useCssTransforms=!1);e.apply(this,arguments);d&&(this.view.scale=c,this.view.translate=f,this.useCssTransforms=!0)}})();Graph.prototype.isLightboxView=function(){return this.lightbox};Graph.prototype.isViewer=function(){return!1};
+a.getAttribute("transform"))try{if(mxClient.IS_EDGE){var q=a.style.display;a.style.display="none";a.getBBox();a.style.display=q}}catch(c){}}else a.removeAttribute("transformOrigin"),a.removeAttribute("transform")};var b=mxGraphView.prototype.validateBackgroundPage;mxGraphView.prototype.validateBackgroundPage=function(){var a=this.graph.useCssTransforms,e=this.scale,l=this.translate;a&&(this.scale=this.graph.currentScale,this.translate=this.graph.currentTranslate);b.apply(this,arguments);a&&(this.scale=
+e,this.translate=l)};var e=mxGraph.prototype.updatePageBreaks;mxGraph.prototype.updatePageBreaks=function(a,b,l){var d=this.useCssTransforms,c=this.view.scale,f=this.view.translate;d&&(this.view.scale=1,this.view.translate=new mxPoint(0,0),this.useCssTransforms=!1);e.apply(this,arguments);d&&(this.view.scale=c,this.view.translate=f,this.useCssTransforms=!0)}})();Graph.prototype.isLightboxView=function(){return this.lightbox};Graph.prototype.isViewer=function(){return!1};
Graph.prototype.labelLinkClicked=function(a,b,e){b=b.getAttribute("href");if(null!=b&&!this.isCustomLink(b)&&mxEvent.isLeftMouseButton(e)&&!mxEvent.isPopupTrigger(e)||mxEvent.isTouchEvent(e)){if(!this.isEnabled()||this.isCellLocked(a.cell))a=this.isBlankLink(b)?this.linkTarget:"_top",this.openLink(this.getAbsoluteUrl(b),a);mxEvent.consume(e)}};
-Graph.prototype.openLink=function(a,b,e){var d=window;try{if("_self"==b&&window!=window.top)window.location.href=a;else if(a.substring(0,this.baseUrl.length)==this.baseUrl&&"#"==a.charAt(this.baseUrl.length)&&"_top"==b&&window==window.top){var k=a.split("#")[1];window.location.hash=="#"+k&&(window.location.hash="");window.location.hash=k}else d=window.open(a,null!=b?b:"_blank"),null==d||e||(d.opener=null)}catch(m){}return d};
+Graph.prototype.openLink=function(a,b,e){var d=window;try{if("_self"==b&&window!=window.top)window.location.href=a;else if(a.substring(0,this.baseUrl.length)==this.baseUrl&&"#"==a.charAt(this.baseUrl.length)&&"_top"==b&&window==window.top){var k=a.split("#")[1];window.location.hash=="#"+k&&(window.location.hash="");window.location.hash=k}else d=window.open(a,null!=b?b:"_blank"),null==d||e||(d.opener=null)}catch(l){}return d};
Graph.prototype.getLinkTitle=function(a){return a.substring(a.lastIndexOf("/")+1)};Graph.prototype.isCustomLink=function(a){return"data:"==a.substring(0,5)};Graph.prototype.customLinkClicked=function(a){return!1};Graph.prototype.isExternalProtocol=function(a){return"mailto:"===a.substring(0,7)};Graph.prototype.isBlankLink=function(a){return!this.isExternalProtocol(a)&&("blank"===this.linkPolicy||"self"!==this.linkPolicy&&!this.isRelativeUrl(a)&&a.substring(0,this.domainUrl.length)!==this.domainUrl)};
Graph.prototype.isRelativeUrl=function(a){return null!=a&&!this.absoluteUrlPattern.test(a)&&"data:"!==a.substring(0,5)&&!this.isExternalProtocol(a)};Graph.prototype.getAbsoluteUrl=function(a){null!=a&&this.isRelativeUrl(a)&&(a="#"==a.charAt(0)?this.baseUrl+a:"/"==a.charAt(0)?this.domainUrl+a:this.domainPathUrl+a);return a};
Graph.prototype.initLayoutManager=function(){this.layoutManager=new mxLayoutManager(this);this.layoutManager.hasLayout=function(a,b){return null!=this.graph.getCellStyle(a).childLayout};this.layoutManager.getLayout=function(a,b){if(b!=mxEvent.BEGIN_UPDATE){var e=this.graph.getCellStyle(a);if("stackLayout"==e.childLayout){var d=new mxStackLayout(this.graph,!0);d.resizeParentMax="1"==mxUtils.getValue(e,"resizeParentMax","1");d.horizontal="1"==mxUtils.getValue(e,"horizontalStack","1");d.resizeParent=
@@ -2325,31 +2325,31 @@ Graph.prototype.isSplitTarget=function(a,b,e){return!this.model.isEdge(b[0])&&!m
Graph.prototype.isLabelMovable=function(a){var b=this.getCurrentCellStyle(a);return!this.isCellLocked(a)&&(this.model.isEdge(a)&&this.edgeLabelsMovable||this.model.isVertex(a)&&(this.vertexLabelsMovable||"1"==mxUtils.getValue(b,"labelMovable","0")))};Graph.prototype.setGridSize=function(a){this.gridSize=a;this.fireEvent(new mxEventObject("gridSizeChanged"))};
Graph.prototype.getClickableLinkForCell=function(a){do{var b=this.getLinkForCell(a);if(null!=b)return b;a=this.model.getParent(a)}while(null!=a);return null};Graph.prototype.getGlobalVariable=function(a){var b=null;"date"==a?b=(new Date).toLocaleDateString():"time"==a?b=(new Date).toLocaleTimeString():"timestamp"==a?b=(new Date).toLocaleString():"date{"==a.substring(0,5)&&(a=a.substring(5,a.length-1),b=this.formatDate(new Date,a));return b};
Graph.prototype.formatDate=function(a,b,e){null==this.dateFormatCache&&(this.dateFormatCache={i18n:{dayNames:"Sun Mon Tue Wed Thu Fri Sat Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),monthNames:"Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec January February March April May June July August September October November December".split(" ")},masks:{"default":"ddd mmm dd yyyy HH:MM:ss",shortDate:"m/d/yy",mediumDate:"mmm d, yyyy",longDate:"mmmm d, yyyy",fullDate:"dddd, mmmm d, yyyy",
-shortTime:"h:MM TT",mediumTime:"h:MM:ss TT",longTime:"h:MM:ss TT Z",isoDate:"yyyy-mm-dd",isoTime:"HH:MM:ss",isoDateTime:"yyyy-mm-dd'T'HH:MM:ss",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"}});var d=this.dateFormatCache,k=/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,m=/[^-+\dA-Z]/g,q=function(a,c){a=String(a);for(c=c||2;a.length<c;)a="0"+a;return a};1!=arguments.length||"[object String]"!=Object.prototype.toString.call(a)||
-/\d/.test(a)||(b=a,a=void 0);a=a?new Date(a):new Date;if(isNaN(a))throw SyntaxError("invalid date");b=String(d.masks[b]||b||d.masks["default"]);"UTC:"==b.slice(0,4)&&(b=b.slice(4),e=!0);var c=e?"getUTC":"get",f=a[c+"Date"](),g=a[c+"Day"](),p=a[c+"Month"](),l=a[c+"FullYear"](),n=a[c+"Hours"](),v=a[c+"Minutes"](),t=a[c+"Seconds"](),c=a[c+"Milliseconds"](),u=e?0:a.getTimezoneOffset(),A={d:f,dd:q(f),ddd:d.i18n.dayNames[g],dddd:d.i18n.dayNames[g+7],m:p+1,mm:q(p+1),mmm:d.i18n.monthNames[p],mmmm:d.i18n.monthNames[p+
-12],yy:String(l).slice(2),yyyy:l,h:n%12||12,hh:q(n%12||12),H:n,HH:q(n),M:v,MM:q(v),s:t,ss:q(t),l:q(c,3),L:q(99<c?Math.round(c/10):c),t:12>n?"a":"p",tt:12>n?"am":"pm",T:12>n?"A":"P",TT:12>n?"AM":"PM",Z:e?"UTC":(String(a).match(k)||[""]).pop().replace(m,""),o:(0<u?"-":"+")+q(100*Math.floor(Math.abs(u)/60)+Math.abs(u)%60,4),S:["th","st","nd","rd"][3<f%10?0:(10!=f%100-f%10)*f%10]};return b.replace(/d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZ]|"[^"]*"|'[^']*'/g,function(a){return a in A?A[a]:a.slice(1,
+shortTime:"h:MM TT",mediumTime:"h:MM:ss TT",longTime:"h:MM:ss TT Z",isoDate:"yyyy-mm-dd",isoTime:"HH:MM:ss",isoDateTime:"yyyy-mm-dd'T'HH:MM:ss",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"}});var d=this.dateFormatCache,k=/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,l=/[^-+\dA-Z]/g,q=function(a,c){a=String(a);for(c=c||2;a.length<c;)a="0"+a;return a};1!=arguments.length||"[object String]"!=Object.prototype.toString.call(a)||
+/\d/.test(a)||(b=a,a=void 0);a=a?new Date(a):new Date;if(isNaN(a))throw SyntaxError("invalid date");b=String(d.masks[b]||b||d.masks["default"]);"UTC:"==b.slice(0,4)&&(b=b.slice(4),e=!0);var c=e?"getUTC":"get",f=a[c+"Date"](),g=a[c+"Day"](),p=a[c+"Month"](),m=a[c+"FullYear"](),n=a[c+"Hours"](),v=a[c+"Minutes"](),t=a[c+"Seconds"](),c=a[c+"Milliseconds"](),u=e?0:a.getTimezoneOffset(),A={d:f,dd:q(f),ddd:d.i18n.dayNames[g],dddd:d.i18n.dayNames[g+7],m:p+1,mm:q(p+1),mmm:d.i18n.monthNames[p],mmmm:d.i18n.monthNames[p+
+12],yy:String(m).slice(2),yyyy:m,h:n%12||12,hh:q(n%12||12),H:n,HH:q(n),M:v,MM:q(v),s:t,ss:q(t),l:q(c,3),L:q(99<c?Math.round(c/10):c),t:12>n?"a":"p",tt:12>n?"am":"pm",T:12>n?"A":"P",TT:12>n?"AM":"PM",Z:e?"UTC":(String(a).match(k)||[""]).pop().replace(l,""),o:(0<u?"-":"+")+q(100*Math.floor(Math.abs(u)/60)+Math.abs(u)%60,4),S:["th","st","nd","rd"][3<f%10?0:(10!=f%100-f%10)*f%10]};return b.replace(/d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZ]|"[^"]*"|'[^']*'/g,function(a){return a in A?A[a]:a.slice(1,
a.length-1)})};
Graph.prototype.createLayersDialog=function(){var a=document.createElement("div");a.style.position="absolute";for(var b=this.getModel(),e=b.getChildCount(b.root),d=0;d<e;d++)mxUtils.bind(this,function(d){var e=document.createElement("div");e.style.overflow="hidden";e.style.textOverflow="ellipsis";e.style.padding="2px";e.style.whiteSpace="nowrap";var k=document.createElement("input");k.style.display="inline-block";k.setAttribute("type","checkbox");b.isVisible(d)&&(k.setAttribute("checked","checked"),
k.defaultChecked=!0);e.appendChild(k);var c=this.convertValueToString(d)||mxResources.get("background")||"Background";e.setAttribute("title",c);mxUtils.write(e,c);a.appendChild(e);mxEvent.addListener(k,"click",function(){null!=k.getAttribute("checked")?k.removeAttribute("checked"):k.setAttribute("checked","checked");b.setVisible(d,k.checked)})})(b.getChildAt(b.root,d));return a};
-Graph.prototype.replacePlaceholders=function(a,b){var e=[];if(null!=b){for(var d=0;match=this.placeholderPattern.exec(b);){var k=match[0];if(2<k.length&&"%label%"!=k&&"%tooltip%"!=k){var m=null;if(match.index>d&&"%"==b.charAt(match.index-1))m=k.substring(1);else{var q=k.substring(1,k.length-1);if(0>q.indexOf("{"))for(var c=a;null==m&&null!=c;)null!=c.value&&"object"==typeof c.value&&(m=c.hasAttribute(q)?null!=c.getAttribute(q)?c.getAttribute(q):"":null),c=this.model.getParent(c);null==m&&(m=this.getGlobalVariable(q))}e.push(b.substring(d,
-match.index)+(null!=m?m:k));d=match.index+k.length}}e.push(b.substring(d))}return e.join("")};Graph.prototype.restoreSelection=function(a){if(null!=a&&0<a.length){for(var b=[],e=0;e<a.length;e++){var d=this.model.getCell(a[e].id);null!=d&&b.push(d)}this.setSelectionCells(b)}else this.clearSelection()};
+Graph.prototype.replacePlaceholders=function(a,b){var e=[];if(null!=b){for(var d=0;match=this.placeholderPattern.exec(b);){var k=match[0];if(2<k.length&&"%label%"!=k&&"%tooltip%"!=k){var l=null;if(match.index>d&&"%"==b.charAt(match.index-1))l=k.substring(1);else{var q=k.substring(1,k.length-1);if(0>q.indexOf("{"))for(var c=a;null==l&&null!=c;)null!=c.value&&"object"==typeof c.value&&(l=c.hasAttribute(q)?null!=c.getAttribute(q)?c.getAttribute(q):"":null),c=this.model.getParent(c);null==l&&(l=this.getGlobalVariable(q))}e.push(b.substring(d,
+match.index)+(null!=l?l:k));d=match.index+k.length}}e.push(b.substring(d))}return e.join("")};Graph.prototype.restoreSelection=function(a){if(null!=a&&0<a.length){for(var b=[],e=0;e<a.length;e++){var d=this.model.getCell(a[e].id);null!=d&&b.push(d)}this.setSelectionCells(b)}else this.clearSelection()};
Graph.prototype.selectCellsForConnectVertex=function(a,b,e){2==a.length&&this.model.isVertex(a[1])?(this.setSelectionCell(a[1]),this.scrollCellToVisible(a[1]),null!=e&&(mxEvent.isTouchEvent(b)?e.update(e.getState(this.view.getState(a[1]))):e.reset())):this.setSelectionCells(a)};
-Graph.prototype.connectVertex=function(a,b,e,d,k,m){if(a.geometry.relative&&this.model.isEdge(a.parent))return[];m=m?m:!1;var q=a.geometry.relative&&null!=a.parent.geometry?new mxPoint(a.parent.geometry.width*a.geometry.x,a.parent.geometry.height*a.geometry.y):new mxPoint(a.geometry.x,a.geometry.y);b==mxConstants.DIRECTION_NORTH?(q.x+=a.geometry.width/2,q.y-=e):b==mxConstants.DIRECTION_SOUTH?(q.x+=a.geometry.width/2,q.y+=a.geometry.height+e):(q.x=b==mxConstants.DIRECTION_WEST?q.x-e:q.x+(a.geometry.width+
-e),q.y+=a.geometry.height/2);e=this.view.getState(this.model.getParent(a));var c=this.view.scale,f=this.view.translate,g=f.x*c,f=f.y*c;null!=e&&this.model.isVertex(e.cell)&&(g=e.x,f=e.y);this.model.isVertex(a.parent)&&a.geometry.relative&&(q.x+=a.parent.geometry.x,q.y+=a.parent.geometry.y);m=m||mxEvent.isControlDown(d)&&!k?null:this.getCellAt(g+q.x*c,f+q.y*c);this.model.isAncestor(m,a)&&(m=null);for(e=m;null!=e;){if(this.isCellLocked(e)){m=null;break}e=this.model.getParent(e)}null!=m&&(e=this.view.getState(a),
-c=this.view.getState(m),null!=e&&null!=c&&mxUtils.intersects(e,c)&&(m=null));if(k=!mxEvent.isShiftDown(d)||k)b==mxConstants.DIRECTION_NORTH?q.y-=a.geometry.height/2:b==mxConstants.DIRECTION_SOUTH?q.y+=a.geometry.height/2:q.x=b==mxConstants.DIRECTION_WEST?q.x-a.geometry.width/2:q.x+a.geometry.width/2;null==m||this.isCellConnectable(m)||(e=this.getModel().getParent(m),this.getModel().isVertex(e)&&this.isCellConnectable(e)&&(m=e));if(m==a||this.model.isEdge(m)||!this.isCellConnectable(m))m=null;e=[];
-this.model.beginUpdate();try{var p=null!=m&&this.isSwimlane(m),c=p?null:m;if(null==c&&k){for(var g=a,l=this.getCellGeometry(a);null!=l&&l.relative;)g=this.getModel().getParent(g),l=this.getCellGeometry(g);g=this.getCompositeParent(g);c=this.duplicateCells([g],!1)[0];l=this.getCellGeometry(c);null!=l&&(l.x=q.x-l.width/2,l.y=q.y-l.height/2);p&&(this.addCells([c],m,null,null,null,!0),m=null)}p=null;null!=this.layoutManager&&(p=this.layoutManager.getLayout(this.model.getParent(a)));var n=mxEvent.isControlDown(d)&&
-k||null==m&&null!=p&&p.constructor==mxStackLayout?null:this.insertEdge(this.model.getParent(a),null,"",a,c,this.createCurrentEdgeStyle());if(null!=n&&this.connectionHandler.insertBeforeSource){var v=null;for(d=a;null!=d.parent&&null!=d.geometry&&d.geometry.relative&&d.parent!=n.parent;)d=this.model.getParent(d);null!=d&&null!=d.parent&&d.parent==n.parent&&(v=d.parent.getIndex(d),this.model.add(d.parent,n,v))}null==m&&null!=c&&null!=p&&null!=a.parent&&p.constructor==mxStackLayout&&b==mxConstants.DIRECTION_WEST&&
-(v=a.parent.getIndex(a),this.model.add(a.parent,c,v));null!=n&&e.push(n);null==m&&null!=c&&e.push(c);null==c&&null!=n&&n.geometry.setTerminalPoint(q,!1);null!=n&&this.fireEvent(new mxEventObject("cellsInserted","cells",[n]))}finally{this.model.endUpdate()}return e};
+Graph.prototype.connectVertex=function(a,b,e,d,k,l){if(a.geometry.relative&&this.model.isEdge(a.parent))return[];l=l?l:!1;var q=a.geometry.relative&&null!=a.parent.geometry?new mxPoint(a.parent.geometry.width*a.geometry.x,a.parent.geometry.height*a.geometry.y):new mxPoint(a.geometry.x,a.geometry.y);b==mxConstants.DIRECTION_NORTH?(q.x+=a.geometry.width/2,q.y-=e):b==mxConstants.DIRECTION_SOUTH?(q.x+=a.geometry.width/2,q.y+=a.geometry.height+e):(q.x=b==mxConstants.DIRECTION_WEST?q.x-e:q.x+(a.geometry.width+
+e),q.y+=a.geometry.height/2);e=this.view.getState(this.model.getParent(a));var c=this.view.scale,f=this.view.translate,g=f.x*c,f=f.y*c;null!=e&&this.model.isVertex(e.cell)&&(g=e.x,f=e.y);this.model.isVertex(a.parent)&&a.geometry.relative&&(q.x+=a.parent.geometry.x,q.y+=a.parent.geometry.y);l=l||mxEvent.isControlDown(d)&&!k?null:this.getCellAt(g+q.x*c,f+q.y*c);this.model.isAncestor(l,a)&&(l=null);for(e=l;null!=e;){if(this.isCellLocked(e)){l=null;break}e=this.model.getParent(e)}null!=l&&(e=this.view.getState(a),
+c=this.view.getState(l),null!=e&&null!=c&&mxUtils.intersects(e,c)&&(l=null));if(k=!mxEvent.isShiftDown(d)||k)b==mxConstants.DIRECTION_NORTH?q.y-=a.geometry.height/2:b==mxConstants.DIRECTION_SOUTH?q.y+=a.geometry.height/2:q.x=b==mxConstants.DIRECTION_WEST?q.x-a.geometry.width/2:q.x+a.geometry.width/2;null==l||this.isCellConnectable(l)||(e=this.getModel().getParent(l),this.getModel().isVertex(e)&&this.isCellConnectable(e)&&(l=e));if(l==a||this.model.isEdge(l)||!this.isCellConnectable(l))l=null;e=[];
+this.model.beginUpdate();try{var p=null!=l&&this.isSwimlane(l),c=p?null:l;if(null==c&&k){for(var g=a,m=this.getCellGeometry(a);null!=m&&m.relative;)g=this.getModel().getParent(g),m=this.getCellGeometry(g);g=this.getCompositeParent(g);c=this.duplicateCells([g],!1)[0];m=this.getCellGeometry(c);null!=m&&(m.x=q.x-m.width/2,m.y=q.y-m.height/2);p&&(this.addCells([c],l,null,null,null,!0),l=null)}p=null;null!=this.layoutManager&&(p=this.layoutManager.getLayout(this.model.getParent(a)));var n=mxEvent.isControlDown(d)&&
+k||null==l&&null!=p&&p.constructor==mxStackLayout?null:this.insertEdge(this.model.getParent(a),null,"",a,c,this.createCurrentEdgeStyle());if(null!=n&&this.connectionHandler.insertBeforeSource){var v=null;for(d=a;null!=d.parent&&null!=d.geometry&&d.geometry.relative&&d.parent!=n.parent;)d=this.model.getParent(d);null!=d&&null!=d.parent&&d.parent==n.parent&&(v=d.parent.getIndex(d),this.model.add(d.parent,n,v))}null==l&&null!=c&&null!=p&&null!=a.parent&&p.constructor==mxStackLayout&&b==mxConstants.DIRECTION_WEST&&
+(v=a.parent.getIndex(a),this.model.add(a.parent,c,v));null!=n&&e.push(n);null==l&&null!=c&&e.push(c);null==c&&null!=n&&n.geometry.setTerminalPoint(q,!1);null!=n&&this.fireEvent(new mxEventObject("cellsInserted","cells",[n]))}finally{this.model.endUpdate()}return e};
Graph.prototype.getIndexableText=function(){var a=document.createElement("div"),b=[],e,d;for(d in this.model.cells)if(e=this.model.cells[d],this.model.isVertex(e)||this.model.isEdge(e))this.isHtmlLabel(e)?(a.innerHTML=this.getLabel(e),e=mxUtils.extractTextWithWhitespace([a])):e=this.getLabel(e),e=mxUtils.trim(e.replace(/[\x00-\x1F\x7F-\x9F]|\s+/g," ")),0<e.length&&b.push(e);return b.join(" ")};
Graph.prototype.convertValueToString=function(a){var b=this.model.getValue(a);if(null!=b&&"object"==typeof b){if(this.isReplacePlaceholders(a)&&null!=a.getAttribute("placeholder")){for(var b=a.getAttribute("placeholder"),e=a,d=null;null==d&&null!=e;)null!=e.value&&"object"==typeof e.value&&(d=e.hasAttribute(b)?null!=e.getAttribute(b)?e.getAttribute(b):"":null),e=this.model.getParent(e);return d||""}return b.getAttribute("label")||""}return mxGraph.prototype.convertValueToString.apply(this,arguments)};
Graph.prototype.getLinksForState=function(a){return null!=a&&null!=a.text&&null!=a.text.node?a.text.node.getElementsByTagName("a"):null};Graph.prototype.getLinkForCell=function(a){return null!=a.value&&"object"==typeof a.value?(a=a.value.getAttribute("link"),null!=a&&"javascript:"===a.toLowerCase().substring(0,11)&&(a=a.substring(11)),a):null};
Graph.prototype.getCellStyle=function(a){var b=mxGraph.prototype.getCellStyle.apply(this,arguments);if(null!=a&&null!=this.layoutManager){var e=this.model.getParent(a);this.model.isVertex(e)&&this.isCellCollapsed(a)&&(e=this.layoutManager.getLayout(e),null!=e&&e.constructor==mxStackLayout&&(b[mxConstants.STYLE_HORIZONTAL]=!e.horizontal))}return b};
Graph.prototype.updateAlternateBounds=function(a,b,e){if(null!=a&&null!=b&&null!=this.layoutManager&&null!=b.alternateBounds){var d=this.layoutManager.getLayout(this.model.getParent(a));null!=d&&d.constructor==mxStackLayout&&(d.horizontal?b.alternateBounds.height=0:b.alternateBounds.width=0)}mxGraph.prototype.updateAlternateBounds.apply(this,arguments)};Graph.prototype.isMoveCellsEvent=function(a,b){return mxEvent.isShiftDown(a)||"1"==mxUtils.getValue(b.style,"moveCells","0")};
-Graph.prototype.foldCells=function(a,b,e,d,k){b=null!=b?b:!1;null==e&&(e=this.getFoldableCells(this.getSelectionCells(),a));if(null!=e){this.model.beginUpdate();try{if(mxGraph.prototype.foldCells.apply(this,arguments),null!=this.layoutManager)for(var m=0;m<e.length;m++){var q=this.view.getState(e[m]),c=this.getCellGeometry(e[m]);if(null!=q&&null!=c){var f=Math.round(c.width-q.width/this.view.scale),g=Math.round(c.height-q.height/this.view.scale);if(0!=g||0!=f){var p=this.model.getParent(e[m]),l=this.layoutManager.getLayout(p);
-null==l?null!=k&&this.isMoveCellsEvent(k,q)&&this.moveSiblings(q,p,f,g):null!=k&&mxEvent.isAltDown(k)||l.constructor!=mxStackLayout||l.resizeLast||this.resizeParentStacks(p,l,f,g)}}}}finally{this.model.endUpdate()}this.isEnabled()&&this.setSelectionCells(e)}};
-Graph.prototype.moveSiblings=function(a,b,e,d){this.model.beginUpdate();try{var k=this.getCellsBeyond(a.x,a.y,b,!0,!0);for(b=0;b<k.length;b++)if(k[b]!=a.cell){var m=this.view.getState(k[b]),q=this.getCellGeometry(k[b]);null!=m&&null!=q&&(q=q.clone(),q.translate(Math.round(e*Math.max(0,Math.min(1,(m.x-a.x)/a.width))),Math.round(d*Math.max(0,Math.min(1,(m.y-a.y)/a.height)))),this.model.setGeometry(k[b],q))}}finally{this.model.endUpdate()}};
-Graph.prototype.resizeParentStacks=function(a,b,e,d){if(null!=this.layoutManager&&null!=b&&b.constructor==mxStackLayout&&!b.resizeLast){this.model.beginUpdate();try{for(var k=b.horizontal;null!=a&&null!=b&&b.constructor==mxStackLayout&&b.horizontal==k&&!b.resizeLast;){var m=this.getCellGeometry(a),q=this.view.getState(a);null!=q&&null!=m&&(m=m.clone(),b.horizontal?m.width+=e+Math.min(0,q.width/this.view.scale-m.width):m.height+=d+Math.min(0,q.height/this.view.scale-m.height),this.model.setGeometry(a,
-m));a=this.model.getParent(a);b=this.layoutManager.getLayout(a)}}finally{this.model.endUpdate()}}};Graph.prototype.isContainer=function(a){var b=this.getCurrentCellStyle(a);return this.isSwimlane(a)?"0"!=b.container:"1"==b.container};Graph.prototype.isExtendParent=function(a){var b=this.model.getParent(a);return null!=b&&(b=this.getCurrentCellStyle(b),null!=b.expand)?"0"!=b.expand:mxGraph.prototype.isExtendParent.apply(this,arguments)};
+Graph.prototype.foldCells=function(a,b,e,d,k){b=null!=b?b:!1;null==e&&(e=this.getFoldableCells(this.getSelectionCells(),a));if(null!=e){this.model.beginUpdate();try{if(mxGraph.prototype.foldCells.apply(this,arguments),null!=this.layoutManager)for(var l=0;l<e.length;l++){var q=this.view.getState(e[l]),c=this.getCellGeometry(e[l]);if(null!=q&&null!=c){var f=Math.round(c.width-q.width/this.view.scale),g=Math.round(c.height-q.height/this.view.scale);if(0!=g||0!=f){var p=this.model.getParent(e[l]),m=this.layoutManager.getLayout(p);
+null==m?null!=k&&this.isMoveCellsEvent(k,q)&&this.moveSiblings(q,p,f,g):null!=k&&mxEvent.isAltDown(k)||m.constructor!=mxStackLayout||m.resizeLast||this.resizeParentStacks(p,m,f,g)}}}}finally{this.model.endUpdate()}this.isEnabled()&&this.setSelectionCells(e)}};
+Graph.prototype.moveSiblings=function(a,b,e,d){this.model.beginUpdate();try{var k=this.getCellsBeyond(a.x,a.y,b,!0,!0);for(b=0;b<k.length;b++)if(k[b]!=a.cell){var l=this.view.getState(k[b]),q=this.getCellGeometry(k[b]);null!=l&&null!=q&&(q=q.clone(),q.translate(Math.round(e*Math.max(0,Math.min(1,(l.x-a.x)/a.width))),Math.round(d*Math.max(0,Math.min(1,(l.y-a.y)/a.height)))),this.model.setGeometry(k[b],q))}}finally{this.model.endUpdate()}};
+Graph.prototype.resizeParentStacks=function(a,b,e,d){if(null!=this.layoutManager&&null!=b&&b.constructor==mxStackLayout&&!b.resizeLast){this.model.beginUpdate();try{for(var k=b.horizontal;null!=a&&null!=b&&b.constructor==mxStackLayout&&b.horizontal==k&&!b.resizeLast;){var l=this.getCellGeometry(a),q=this.view.getState(a);null!=q&&null!=l&&(l=l.clone(),b.horizontal?l.width+=e+Math.min(0,q.width/this.view.scale-l.width):l.height+=d+Math.min(0,q.height/this.view.scale-l.height),this.model.setGeometry(a,
+l));a=this.model.getParent(a);b=this.layoutManager.getLayout(a)}}finally{this.model.endUpdate()}}};Graph.prototype.isContainer=function(a){var b=this.getCurrentCellStyle(a);return this.isSwimlane(a)?"0"!=b.container:"1"==b.container};Graph.prototype.isExtendParent=function(a){var b=this.model.getParent(a);return null!=b&&(b=this.getCurrentCellStyle(b),null!=b.expand)?"0"!=b.expand:mxGraph.prototype.isExtendParent.apply(this,arguments)};
Graph.prototype.isCellConnectable=function(a){var b=this.getCurrentCellStyle(a);return null!=b.connectable?"0"!=b.connectable:mxGraph.prototype.isCellConnectable.apply(this,arguments)};Graph.prototype.isLabelMovable=function(a){var b=this.getCurrentCellStyle(a);return null!=b.movableLabel?"0"!=b.movableLabel:mxGraph.prototype.isLabelMovable.apply(this,arguments)};Graph.prototype.selectAll=function(a){a=a||this.getDefaultParent();this.isCellLocked(a)||mxGraph.prototype.selectAll.apply(this,arguments)};
Graph.prototype.selectCells=function(a,b,e){e=e||this.getDefaultParent();this.isCellLocked(e)||mxGraph.prototype.selectCells.apply(this,arguments)};Graph.prototype.getSwimlaneAt=function(a,b,e){var d=mxGraph.prototype.getSwimlaneAt.apply(this,arguments);this.isCellLocked(d)&&(d=null);return d};
Graph.prototype.isCellFoldable=function(a){var b=this.getCurrentCellStyle(a);return this.foldingEnabled&&("1"==b.treeFolding||!this.isCellLocked(a)&&(this.isContainer(a)&&"0"!=b.collapsible||!this.isContainer(a)&&"1"==b.collapsible))};Graph.prototype.reset=function(){this.isEditing()&&this.stopEditing(!0);this.escape();this.isSelectionEmpty()||this.clearSelection()};
@@ -2365,8 +2365,8 @@ IMAGE_PATH+"/refresh.png",38,38);HoverIcons.prototype.tolerance=mxClient.IS_TOUC
HoverIcons.prototype.init=function(){this.arrowUp=this.createArrow(this.triangleUp,mxResources.get("plusTooltip"));this.arrowRight=this.createArrow(this.triangleRight,mxResources.get("plusTooltip"));this.arrowDown=this.createArrow(this.triangleDown,mxResources.get("plusTooltip"));this.arrowLeft=this.createArrow(this.triangleLeft,mxResources.get("plusTooltip"));this.elts=[this.arrowUp,this.arrowRight,this.arrowDown,this.arrowLeft];this.resetHandler=mxUtils.bind(this,function(){this.reset()});this.repaintHandler=
mxUtils.bind(this,function(){this.repaint()});this.graph.selectionModel.addListener(mxEvent.CHANGE,this.resetHandler);this.graph.model.addListener(mxEvent.CHANGE,this.repaintHandler);this.graph.view.addListener(mxEvent.SCALE_AND_TRANSLATE,this.repaintHandler);this.graph.view.addListener(mxEvent.TRANSLATE,this.repaintHandler);this.graph.view.addListener(mxEvent.SCALE,this.repaintHandler);this.graph.view.addListener(mxEvent.DOWN,this.repaintHandler);this.graph.view.addListener(mxEvent.UP,this.repaintHandler);
this.graph.addListener(mxEvent.ROOT,this.repaintHandler);this.graph.addListener(mxEvent.ESCAPE,this.resetHandler);mxEvent.addListener(this.graph.container,"scroll",this.resetHandler);this.graph.addListener(mxEvent.ESCAPE,mxUtils.bind(this,function(){this.mouseDownPoint=null}));mxEvent.addListener(this.graph.container,"mouseleave",mxUtils.bind(this,function(a){null!=a.relatedTarget&&mxEvent.getSource(a)==this.graph.container&&this.setDisplay("none")}));this.graph.addListener(mxEvent.START_EDITING,
-mxUtils.bind(this,function(a){this.reset()}));var a=this.graph.click;this.graph.click=mxUtils.bind(this,function(b){a.apply(this.graph,arguments);null==this.currentState||this.graph.isCellSelected(this.currentState.cell)||!mxEvent.isTouchEvent(b.getEvent())||this.graph.model.isVertex(b.getCell())||this.reset()});var b=!1;this.graph.addMouseListener({mouseDown:mxUtils.bind(this,function(a,d){b=!1;var e=d.getEvent();if(this.isResetEvent(e))this.reset();else if(!this.isActive()){var m=this.getState(d.getState());
-null==m&&mxEvent.isTouchEvent(e)||this.update(m)}this.setDisplay("none")}),mouseMove:mxUtils.bind(this,function(a,d){var e=d.getEvent();this.isResetEvent(e)?this.reset():this.graph.isMouseDown||mxEvent.isTouchEvent(e)||this.update(this.getState(d.getState()),d.getGraphX(),d.getGraphY());null!=this.graph.connectionHandler&&null!=this.graph.connectionHandler.shape&&(b=!0)}),mouseUp:mxUtils.bind(this,function(a,d){var e=d.getEvent();mxUtils.convertPoint(this.graph.container,mxEvent.getClientX(e),mxEvent.getClientY(e));
+mxUtils.bind(this,function(a){this.reset()}));var a=this.graph.click;this.graph.click=mxUtils.bind(this,function(b){a.apply(this.graph,arguments);null==this.currentState||this.graph.isCellSelected(this.currentState.cell)||!mxEvent.isTouchEvent(b.getEvent())||this.graph.model.isVertex(b.getCell())||this.reset()});var b=!1;this.graph.addMouseListener({mouseDown:mxUtils.bind(this,function(a,d){b=!1;var e=d.getEvent();if(this.isResetEvent(e))this.reset();else if(!this.isActive()){var l=this.getState(d.getState());
+null==l&&mxEvent.isTouchEvent(e)||this.update(l)}this.setDisplay("none")}),mouseMove:mxUtils.bind(this,function(a,d){var e=d.getEvent();this.isResetEvent(e)?this.reset():this.graph.isMouseDown||mxEvent.isTouchEvent(e)||this.update(this.getState(d.getState()),d.getGraphX(),d.getGraphY());null!=this.graph.connectionHandler&&null!=this.graph.connectionHandler.shape&&(b=!0)}),mouseUp:mxUtils.bind(this,function(a,d){var e=d.getEvent();mxUtils.convertPoint(this.graph.container,mxEvent.getClientX(e),mxEvent.getClientY(e));
this.isResetEvent(e)?this.reset():this.isActive()&&!b&&null!=this.mouseDownPoint?this.click(this.currentState,this.getDirection(),d):this.isActive()?1==this.graph.getSelectionCount()&&this.graph.model.isEdge(this.graph.getSelectionCell())?this.reset():this.update(this.getState(this.graph.view.getState(this.graph.getCellAt(d.getGraphX(),d.getGraphY())))):mxEvent.isTouchEvent(e)||null!=this.bbox&&mxUtils.contains(this.bbox,d.getGraphX(),d.getGraphY())?(this.setDisplay(""),this.repaint()):mxEvent.isTouchEvent(e)||
this.reset();b=!1;this.resetActiveArrow()})})};HoverIcons.prototype.isResetEvent=function(a,b){return mxEvent.isAltDown(a)||null==this.activeArrow&&mxEvent.isShiftDown(a)||mxEvent.isMetaDown(a)||mxEvent.isPopupTrigger(a)&&!mxEvent.isControlDown(a)};
HoverIcons.prototype.createArrow=function(a,b){var e=null;mxClient.IS_IE&&!mxClient.IS_SVG?(mxClient.IS_IE6&&"CSS1Compat"!=document.compatMode?(e=document.createElement(mxClient.VML_PREFIX+":image"),e.setAttribute("src",a.src),e.style.borderStyle="none"):(e=document.createElement("div"),e.style.backgroundImage="url("+a.src+")",e.style.backgroundPosition="center",e.style.backgroundRepeat="no-repeat"),e.style.width=a.width+4+"px",e.style.height=a.height+4+"px",e.style.display=mxClient.IS_QUIRKS?"inline":
@@ -2376,13 +2376,13 @@ this.resetActiveArrow()}));return e};HoverIcons.prototype.resetActiveArrow=funct
HoverIcons.prototype.visitNodes=function(a){for(var b=0;b<this.elts.length;b++)null!=this.elts[b]&&a(this.elts[b])};HoverIcons.prototype.removeNodes=function(){this.visitNodes(function(a){null!=a.parentNode&&a.parentNode.removeChild(a)})};HoverIcons.prototype.setDisplay=function(a){this.visitNodes(function(b){b.style.display=a})};HoverIcons.prototype.isActive=function(){return null!=this.activeArrow&&null!=this.currentState};
HoverIcons.prototype.drag=function(a,b,e){this.graph.popupMenuHandler.hideMenu();this.graph.stopEditing(!1);null!=this.currentState&&(this.graph.connectionHandler.start(this.currentState,b,e),this.graph.isMouseTrigger=mxEvent.isMouseEvent(a),this.graph.isMouseDown=!0,b=this.graph.selectionCellsHandler.getHandler(this.currentState.cell),null!=b&&b.setHandlesVisible(!1),b=this.graph.connectionHandler.edgeState,null!=a&&mxEvent.isShiftDown(a)&&mxEvent.isControlDown(a)&&null!=b&&"orthogonalEdgeStyle"===
mxUtils.getValue(b.style,mxConstants.STYLE_EDGE,null)&&(a=this.getDirection(),b.cell.style=mxUtils.setStyle(b.cell.style,"sourcePortConstraint",a),b.style.sourcePortConstraint=a))};HoverIcons.prototype.getStateAt=function(a,b,e){return this.graph.view.getState(this.graph.getCellAt(b,e))};
-HoverIcons.prototype.click=function(a,b,e){var d=e.getEvent(),k=e.getGraphX(),m=e.getGraphY(),k=this.getStateAt(a,k,m);null==k||!this.graph.model.isEdge(k.cell)||mxEvent.isControlDown(d)||k.getVisibleTerminalState(!0)!=a&&k.getVisibleTerminalState(!1)!=a?null!=a&&this.graph.selectCellsForConnectVertex(this.graph.connectVertex(a.cell,b,this.graph.defaultEdgeLength,d),d,this):(this.graph.setSelectionCell(k.cell),this.reset());e.consume()};
+HoverIcons.prototype.click=function(a,b,e){var d=e.getEvent(),k=e.getGraphX(),l=e.getGraphY(),k=this.getStateAt(a,k,l);null==k||!this.graph.model.isEdge(k.cell)||mxEvent.isControlDown(d)||k.getVisibleTerminalState(!0)!=a&&k.getVisibleTerminalState(!1)!=a?null!=a&&this.graph.selectCellsForConnectVertex(this.graph.connectVertex(a.cell,b,this.graph.defaultEdgeLength,d),d,this):(this.graph.setSelectionCell(k.cell),this.reset());e.consume()};
HoverIcons.prototype.reset=function(a){null!=a&&!a||null==this.updateThread||window.clearTimeout(this.updateThread);this.activeArrow=this.currentState=this.mouseDownPoint=null;this.removeNodes();this.bbox=null};
HoverIcons.prototype.repaint=function(){this.bbox=null;if(null!=this.currentState){this.currentState=this.getState(this.currentState);if(null!=this.currentState&&this.graph.model.isVertex(this.currentState.cell)&&this.graph.isCellConnectable(this.currentState.cell)){var a=mxRectangle.fromRectangle(this.currentState);null!=this.currentState.shape&&null!=this.currentState.shape.boundingBox&&(a=mxRectangle.fromRectangle(this.currentState.shape.boundingBox));a.grow(this.graph.tolerance);a.grow(this.arrowSpacing);
var b=this.graph.selectionCellsHandler.getHandler(this.currentState.cell),e=null;null!=b&&(a.x-=b.horizontalOffset/2,a.y-=b.verticalOffset/2,a.width+=b.horizontalOffset,a.height+=b.verticalOffset,null!=b.rotationShape&&null!=b.rotationShape.node&&"hidden"!=b.rotationShape.node.style.visibility&&"none"!=b.rotationShape.node.style.display&&null!=b.rotationShape.boundingBox&&(e=b.rotationShape.boundingBox));b=mxUtils.bind(this,function(a,f,d){if(null!=e){var c=new mxRectangle(f,d,a.clientWidth,a.clientHeight);
mxUtils.intersects(c,e)&&(a==this.arrowUp?d-=c.y+c.height-e.y:a==this.arrowRight?f+=e.x+e.width-c.x:a==this.arrowDown?d+=e.y+e.height-c.y:a==this.arrowLeft&&(f-=c.x+c.width-e.x))}a.style.left=f+"px";a.style.top=d+"px";mxUtils.setOpacity(a,this.inactiveOpacity)});b(this.arrowUp,Math.round(this.currentState.getCenterX()-this.triangleUp.width/2-this.tolerance),Math.round(a.y-this.triangleUp.height-this.tolerance));b(this.arrowRight,Math.round(a.x+a.width-this.tolerance),Math.round(this.currentState.getCenterY()-
this.triangleRight.height/2-this.tolerance));b(this.arrowDown,parseInt(this.arrowUp.style.left),Math.round(a.y+a.height-this.tolerance));b(this.arrowLeft,Math.round(a.x-this.triangleLeft.width-this.tolerance),parseInt(this.arrowRight.style.top));if(this.checkCollisions){var b=this.graph.getCellAt(a.x+a.width+this.triangleRight.width/2,this.currentState.getCenterY()),d=this.graph.getCellAt(a.x-this.triangleLeft.width/2,this.currentState.getCenterY()),k=this.graph.getCellAt(this.currentState.getCenterX(),
-a.y-this.triangleUp.height/2),a=this.graph.getCellAt(this.currentState.getCenterX(),a.y+a.height+this.triangleDown.height/2);null!=b&&b==d&&d==k&&k==a&&(a=k=d=b=null);var m=this.graph.getCellGeometry(this.currentState.cell),q=mxUtils.bind(this,function(a,f){var c=this.graph.model.isVertex(a)&&this.graph.getCellGeometry(a);null==a||this.graph.model.isAncestor(a,this.currentState.cell)||this.graph.isSwimlane(a)||!(null==c||null==m||c.height<3*m.height&&c.width<3*m.width)?f.style.visibility="visible":
+a.y-this.triangleUp.height/2),a=this.graph.getCellAt(this.currentState.getCenterX(),a.y+a.height+this.triangleDown.height/2);null!=b&&b==d&&d==k&&k==a&&(a=k=d=b=null);var l=this.graph.getCellGeometry(this.currentState.cell),q=mxUtils.bind(this,function(a,f){var c=this.graph.model.isVertex(a)&&this.graph.getCellGeometry(a);null==a||this.graph.model.isAncestor(a,this.currentState.cell)||this.graph.isSwimlane(a)||!(null==c||null==l||c.height<3*l.height&&c.width<3*l.width)?f.style.visibility="visible":
f.style.visibility="hidden"});q(b,this.arrowRight);q(d,this.arrowLeft);q(k,this.arrowUp);q(a,this.arrowDown)}else this.arrowLeft.style.visibility="visible",this.arrowRight.style.visibility="visible",this.arrowUp.style.visibility="visible",this.arrowDown.style.visibility="visible";this.graph.tooltipHandler.isEnabled()?(this.arrowLeft.setAttribute("title",mxResources.get("plusTooltip")),this.arrowRight.setAttribute("title",mxResources.get("plusTooltip")),this.arrowUp.setAttribute("title",mxResources.get("plusTooltip")),
this.arrowDown.setAttribute("title",mxResources.get("plusTooltip"))):(this.arrowLeft.removeAttribute("title"),this.arrowRight.removeAttribute("title"),this.arrowUp.removeAttribute("title"),this.arrowDown.removeAttribute("title"))}else this.reset();null!=this.currentState&&(this.bbox=this.computeBoundingBox(),null!=this.bbox&&this.bbox.grow(10))}};
HoverIcons.prototype.computeBoundingBox=function(){var a=this.graph.model.isEdge(this.currentState.cell)?null:mxRectangle.fromRectangle(this.currentState);this.visitNodes(function(b){null!=b.parentNode&&(b=new mxRectangle(b.offsetLeft,b.offsetTop,b.offsetWidth,b.offsetHeight),null==a?a=b:a.add(b))});return a};
@@ -2390,36 +2390,36 @@ HoverIcons.prototype.getState=function(a){if(null!=a)if(a=a.cell,this.graph.getM
HoverIcons.prototype.update=function(a,b,e){if(!this.graph.connectionArrowsEnabled||null!=a&&"0"==mxUtils.getValue(a.style,"allowArrows","1"))this.reset();else{null!=a&&null!=a.cell.geometry&&a.cell.geometry.relative&&this.graph.model.isEdge(a.cell.parent)&&(a=null);var d=null;this.prev!=a||this.isActive()?(this.startTime=(new Date).getTime(),this.prev=a,d=0,null!=this.updateThread&&window.clearTimeout(this.updateThread),null!=a&&(this.updateThread=window.setTimeout(mxUtils.bind(this,function(){this.isActive()||
this.graph.isMouseDown||this.graph.panningHandler.isActive()||(this.prev=a,this.update(a,b,e))}),this.updateDelay+10))):null!=this.startTime&&(d=(new Date).getTime()-this.startTime);this.setDisplay("");null!=this.currentState&&this.currentState!=a&&d<this.activationDelay&&null!=this.bbox&&!mxUtils.contains(this.bbox,b,e)?this.reset(!1):(null!=this.currentState||d>this.activationDelay)&&this.currentState!=a&&(d>this.updateDelay&&null!=a||null==this.bbox||null==b||null==e||!mxUtils.contains(this.bbox,
b,e))&&(null!=a&&this.graph.isEnabled()?(this.removeNodes(),this.setCurrentState(a),this.repaint(),this.graph.connectionHandler.constraintHandler.currentFocus!=a&&this.graph.connectionHandler.constraintHandler.reset()):this.reset())}};
-HoverIcons.prototype.setCurrentState=function(a){"eastwest"!=a.style.portConstraint&&(this.graph.container.appendChild(this.arrowUp),this.graph.container.appendChild(this.arrowDown));this.graph.container.appendChild(this.arrowRight);this.graph.container.appendChild(this.arrowLeft);this.currentState=a};Graph.prototype.createParent=function(a,b,e,d,k){a=this.cloneCell(a);for(var m=0;m<e;m++){var q=this.cloneCell(b),c=this.getCellGeometry(q);null!=c&&(c.x+=m*d,c.y+=m*k);a.insert(q)}return a};
+HoverIcons.prototype.setCurrentState=function(a){"eastwest"!=a.style.portConstraint&&(this.graph.container.appendChild(this.arrowUp),this.graph.container.appendChild(this.arrowDown));this.graph.container.appendChild(this.arrowRight);this.graph.container.appendChild(this.arrowLeft);this.currentState=a};Graph.prototype.createParent=function(a,b,e,d,k){a=this.cloneCell(a);for(var l=0;l<e;l++){var q=this.cloneCell(b),c=this.getCellGeometry(q);null!=c&&(c.x+=l*d,c.y+=l*k);a.insert(q)}return a};
Graph.prototype.createTable=function(a,b,e,d){e=null!=e?e:40;d=null!=d?d:30;return this.createParent(this.createVertex(null,null,"",0,0,b*e,a*d,"swimlane;startSize=0;html=1;whiteSpace=wrap;container=0;collapsible=0;containerType=table;fillColor=none;childLayout=tableLayout;resizeLast=1;resizeParent=0;horizontalStack=0;dropTarget=0;"),this.createParent(this.createVertex(null,null,"",0,0,b*e,d,"shape=partialRectangle;html=1;whiteSpace=wrap;container=0;collapsible=0;points=[[0,0.5],[1,0.5]];fillColor=none;strokeColor=none;portConstraint=eastwest;resizeLast=1;resizeParent=0;part=1;"),
this.createVertex(null,null,"",0,0,e,d,"shape=partialRectangle;html=1;whiteSpace=wrap;connectable=0;part=1;fillColor=none;left=0;top=0;"),b,e,0),a,0,d)};
-Graph.prototype.createCrossFunctionalSwimlane=function(a,b,e,d){e=null!=e?e:120;d=null!=d?d:120;var k=this.createVertex(null,null,"",0,0,b*e,a*d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;containerType=table;container=0;dropTarget=0;childLayout=tableLayout;resizeLast=1;resizeParent=0;horizontalStack=0;"),m=mxUtils.getValue(this.getCellStyle(k),mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE);k.geometry.width+=m;k.geometry.height+=m;var q=this.createVertex(null,
-null,"",0,m,b*e+m,d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;horizontal=0;points=[[0,0.5],[1,0.5]];part=1;portConstraint=eastwest;resizeLast=1;resizeParent=0;container=0;");k.insert(this.createParent(q,this.createVertex(null,null,"",m,0,e,d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;connectable=0;part=1;"),b,e,0));return 1<a?(q.geometry.y=d+m,this.createParent(k,this.createParent(q,this.createVertex(null,null,"",m,0,e,d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;connectable=0;part=1;startSize=0;"),
+Graph.prototype.createCrossFunctionalSwimlane=function(a,b,e,d){e=null!=e?e:120;d=null!=d?d:120;var k=this.createVertex(null,null,"",0,0,b*e,a*d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;containerType=table;container=0;dropTarget=0;childLayout=tableLayout;resizeLast=1;resizeParent=0;horizontalStack=0;"),l=mxUtils.getValue(this.getCellStyle(k),mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE);k.geometry.width+=l;k.geometry.height+=l;var q=this.createVertex(null,
+null,"",0,l,b*e+l,d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;horizontal=0;points=[[0,0.5],[1,0.5]];part=1;portConstraint=eastwest;resizeLast=1;resizeParent=0;container=0;");k.insert(this.createParent(q,this.createVertex(null,null,"",l,0,e,d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;connectable=0;part=1;"),b,e,0));return 1<a?(q.geometry.y=d+l,this.createParent(k,this.createParent(q,this.createVertex(null,null,"",l,0,e,d,"swimlane;html=1;whiteSpace=wrap;collapsible=0;recursiveResize=0;expand=0;connectable=0;part=1;startSize=0;"),
b,e,0),a-1,0,d)):k};Graph.prototype.isTableCell=function(a){return this.model.isVertex(a)&&this.isTableRow(this.model.getParent(a))};Graph.prototype.isTableRow=function(a){return this.model.isVertex(a)&&this.isTable(this.model.getParent(a))};Graph.prototype.isTable=function(a){a=this.getCellStyle(a);return null!=a&&"table"==a.containerType};
-Graph.prototype.updateTableRowHeight=function(a,b){var e=this.getModel();e.beginUpdate();try{var d=this.getCellGeometry(a);if(null!=d){d=d.clone();d.height+=b;e.setGeometry(a,d);var k=e.getParent(a),m=this.getCellGeometry(k);null!=m&&(m=m.clone(),m.height+=b,e.setGeometry(k,m))}}finally{e.endUpdate()}};
-Graph.prototype.updateTableColumnWidth=function(a,b){var e=this.getModel(),d=e.getParent(a),k=e.getParent(d),m=d.getIndex(a);e.beginUpdate();try{for(var q=0;q<e.getChildCount(k);q++)if(d=e.getChildAt(k,q),e.isVertex(d)){var c=e.getChildAt(d,m);if(e.isVertex(c)){var f=this.getCellGeometry(c);null!=f&&(f=f.clone(),f.width+=b,e.setGeometry(c,f))}m<e.getChildCount(d)-1&&(c=e.getChildAt(d,m+1),e.isVertex(c)&&(f=this.getCellGeometry(c),null!=f&&(f=f.clone(),f.x+=b,f.width-=b,e.setGeometry(c,f))))}}finally{e.endUpdate()}};
-function TableLayout(a){mxGraphLayout.call(this,a)}TableLayout.prototype=new mxStackLayout;TableLayout.prototype.constructor=TableLayout;TableLayout.prototype.isHorizontal=function(){return!1};TableLayout.prototype.getLayout=function(a,b){for(var e=this.graph.getModel(),d=[],k=0,m=0;m<e.getChildCount(a);m++){var q=e.getChildAt(a,m);if(!this.isVertexIgnored(q)){var c=this.graph.getCellGeometry(q);null!=c&&(k+=b?c.height:c.width,d.push(q))}}return[d,k]};
-TableLayout.prototype.execute=function(a){if(null!=a){var b=this.graph.getActualStartSize(a),e=this.graph.getCellGeometry(a),d=this.graph.getModel();d.beginUpdate();try{var k=this.getLayout(a,!0),m=k[0],q=k[1],c=b.y;for(a=0;a<m.length;a++){var f=e.height-b.y-b.height,g=this.graph.getCellGeometry(m[a]),g=g.clone();g.x=b.x;g.y=Math.round(c);g.width=e.width;var p=g.height/q*f,c=c+p;g.height=Math.round(c)-g.y;d.setGeometry(m[a],g);for(var l=this.graph.getActualStartSize(m[a]),n=this.getLayout(m[a],!1),
-v=n[0],t=n[1],u=l.x,k=0;k<v.length;k++){var A=this.graph.getCellGeometry(v[k]),B=g.width-l.x-l.width,A=A.clone();A.x=Math.round(u);A.y=0;A.height=Math.round(p);u+=A.width/t*B;A.width=Math.round(u)-A.x;d.setGeometry(v[k],A)}}}finally{d.endUpdate()}}};
+Graph.prototype.updateTableRowHeight=function(a,b){var e=this.getModel();e.beginUpdate();try{var d=this.getCellGeometry(a);if(null!=d){d=d.clone();d.height+=b;e.setGeometry(a,d);var k=e.getParent(a),l=this.getCellGeometry(k);null!=l&&(l=l.clone(),l.height+=b,e.setGeometry(k,l))}}finally{e.endUpdate()}};
+Graph.prototype.updateTableColumnWidth=function(a,b){var e=this.getModel(),d=e.getParent(a),k=e.getParent(d),l=d.getIndex(a);e.beginUpdate();try{for(var q=0;q<e.getChildCount(k);q++)if(d=e.getChildAt(k,q),e.isVertex(d)){var c=e.getChildAt(d,l);if(e.isVertex(c)){var f=this.getCellGeometry(c);null!=f&&(f=f.clone(),f.width+=b,e.setGeometry(c,f))}l<e.getChildCount(d)-1&&(c=e.getChildAt(d,l+1),e.isVertex(c)&&(f=this.getCellGeometry(c),null!=f&&(f=f.clone(),f.x+=b,f.width-=b,e.setGeometry(c,f))))}}finally{e.endUpdate()}};
+function TableLayout(a){mxGraphLayout.call(this,a)}TableLayout.prototype=new mxStackLayout;TableLayout.prototype.constructor=TableLayout;TableLayout.prototype.isHorizontal=function(){return!1};TableLayout.prototype.getLayout=function(a,b){for(var e=this.graph.getModel(),d=[],k=0,l=0;l<e.getChildCount(a);l++){var q=e.getChildAt(a,l);if(!this.isVertexIgnored(q)){var c=this.graph.getCellGeometry(q);null!=c&&(k+=b?c.height:c.width,d.push(q))}}return[d,k]};
+TableLayout.prototype.execute=function(a){if(null!=a){var b=this.graph.getActualStartSize(a),e=this.graph.getCellGeometry(a),d=this.graph.getModel();d.beginUpdate();try{var k=this.getLayout(a,!0),l=k[0],q=k[1],c=b.y;for(a=0;a<l.length;a++){var f=e.height-b.y-b.height,g=this.graph.getCellGeometry(l[a]),g=g.clone();g.x=b.x;g.y=Math.round(c);g.width=e.width;var p=g.height/q*f,c=c+p;g.height=Math.round(c)-g.y;d.setGeometry(l[a],g);for(var m=this.graph.getActualStartSize(l[a]),n=this.getLayout(l[a],!1),
+v=n[0],t=n[1],u=m.x,k=0;k<v.length;k++){var A=this.graph.getCellGeometry(v[k]),B=g.width-m.x-m.width,A=A.clone();A.x=Math.round(u);A.y=0;A.height=Math.round(p);u+=A.width/t*B;A.width=Math.round(u)-A.x;d.setGeometry(v[k],A)}}}finally{d.endUpdate()}}};
(function(){var a=mxGraphView.prototype.resetValidationState;mxGraphView.prototype.resetValidationState=function(){a.apply(this,arguments);this.validEdges=[]};var b=mxGraphView.prototype.validateCellState;mxGraphView.prototype.validateCellState=function(a,c){c=null!=c?c:!0;var f=this.getState(a);null!=f&&c&&this.graph.model.isEdge(f.cell)&&null!=f.style&&1!=f.style[mxConstants.STYLE_CURVED]&&!f.invalid&&this.updateLineJumps(f)&&this.graph.cellRenderer.redraw(f,!1,this.isRendering());f=b.apply(this,
arguments);null!=f&&c&&this.graph.model.isEdge(f.cell)&&null!=f.style&&1!=f.style[mxConstants.STYLE_CURVED]&&this.validEdges.push(f);return f};var e=mxCellRenderer.prototype.isShapeInvalid;mxCellRenderer.prototype.isShapeInvalid=function(a,c){return e.apply(this,arguments)||null!=a.routedPoints&&null!=c.routedPoints&&!mxUtils.equalPoints(c.routedPoints,a.routedPoints)};var d=mxGraphView.prototype.updateCellState;mxGraphView.prototype.updateCellState=function(a){d.apply(this,arguments);this.graph.model.isEdge(a.cell)&&
1!=a.style[mxConstants.STYLE_CURVED]&&this.updateLineJumps(a)};mxGraphView.prototype.updateLineJumps=function(a){var c=a.absolutePoints;if(Graph.lineJumpsEnabled){var f=null!=a.routedPoints,d=null;if(null!=c&&null!=this.validEdges&&"none"!==mxUtils.getValue(a.style,"jumpStyle","none")){for(var b=function(c,f,b){var e=new mxPoint(f,b);e.type=c;d.push(e);e=null!=a.routedPoints?a.routedPoints[d.length-1]:null;return null==e||e.type!=c||e.x!=f||e.y!=b},e=.5*this.scale,f=!1,d=[],t=0;t<c.length-1;t++){for(var u=
-c[t+1],k=c[t],m=[],q=c[t+2];t<c.length-2&&mxUtils.ptSegDistSq(k.x,k.y,q.x,q.y,u.x,u.y)<1*this.scale*this.scale;)u=q,t++,q=c[t+2];for(var f=b(0,k.x,k.y)||f,C=0;C<this.validEdges.length;C++){var x=this.validEdges[C],F=x.absolutePoints;if(null!=F&&mxUtils.intersects(a,x)&&"1"!=x.style.noJump)for(x=0;x<F.length-1;x++){for(var G=F[x+1],E=F[x],q=F[x+2];x<F.length-2&&mxUtils.ptSegDistSq(E.x,E.y,q.x,q.y,G.x,G.y)<1*this.scale*this.scale;)G=q,x++,q=F[x+2];q=mxUtils.intersection(k.x,k.y,u.x,u.y,E.x,E.y,G.x,
-G.y);if(null!=q&&(Math.abs(q.x-k.x)>e||Math.abs(q.y-k.y)>e)&&(Math.abs(q.x-u.x)>e||Math.abs(q.y-u.y)>e)&&(Math.abs(q.x-E.x)>e||Math.abs(q.y-E.y)>e)&&(Math.abs(q.x-G.x)>e||Math.abs(q.y-G.y)>e)){G=q.x-k.x;E=q.y-k.y;q={distSq:G*G+E*E,x:q.x,y:q.y};for(G=0;G<m.length;G++)if(m[G].distSq>q.distSq){m.splice(G,0,q);q=null;break}null==q||0!=m.length&&m[m.length-1].x===q.x&&m[m.length-1].y===q.y||m.push(q)}}}for(x=0;x<m.length;x++)f=b(1,m[x].x,m[x].y)||f}q=c[c.length-1];f=b(0,q.x,q.y)||f}a.routedPoints=d;return f}return!1};
+c[t+1],k=c[t],l=[],q=c[t+2];t<c.length-2&&mxUtils.ptSegDistSq(k.x,k.y,q.x,q.y,u.x,u.y)<1*this.scale*this.scale;)u=q,t++,q=c[t+2];for(var f=b(0,k.x,k.y)||f,C=0;C<this.validEdges.length;C++){var x=this.validEdges[C],F=x.absolutePoints;if(null!=F&&mxUtils.intersects(a,x)&&"1"!=x.style.noJump)for(x=0;x<F.length-1;x++){for(var G=F[x+1],E=F[x],q=F[x+2];x<F.length-2&&mxUtils.ptSegDistSq(E.x,E.y,q.x,q.y,G.x,G.y)<1*this.scale*this.scale;)G=q,x++,q=F[x+2];q=mxUtils.intersection(k.x,k.y,u.x,u.y,E.x,E.y,G.x,
+G.y);if(null!=q&&(Math.abs(q.x-k.x)>e||Math.abs(q.y-k.y)>e)&&(Math.abs(q.x-u.x)>e||Math.abs(q.y-u.y)>e)&&(Math.abs(q.x-E.x)>e||Math.abs(q.y-E.y)>e)&&(Math.abs(q.x-G.x)>e||Math.abs(q.y-G.y)>e)){G=q.x-k.x;E=q.y-k.y;q={distSq:G*G+E*E,x:q.x,y:q.y};for(G=0;G<l.length;G++)if(l[G].distSq>q.distSq){l.splice(G,0,q);q=null;break}null==q||0!=l.length&&l[l.length-1].x===q.x&&l[l.length-1].y===q.y||l.push(q)}}}for(x=0;x<l.length;x++)f=b(1,l[x].x,l[x].y)||f}q=c[c.length-1];f=b(0,q.x,q.y)||f}a.routedPoints=d;return f}return!1};
var k=mxConnector.prototype.paintLine;mxConnector.prototype.paintLine=function(a,c,d){this.routedPoints=null!=this.state?this.state.routedPoints:null;if(this.outline||null==this.state||null==this.style||null==this.state.routedPoints||0==this.state.routedPoints.length)k.apply(this,arguments);else{var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2,b=(parseInt(mxUtils.getValue(this.style,"jumpSize",Graph.defaultJumpSize))-2)/2+this.strokewidth,e=mxUtils.getValue(this.style,
-"jumpStyle","none"),g=!0,p=null,m=null,q=[],D=null;a.begin();for(var C=0;C<this.state.routedPoints.length;C++){var x=this.state.routedPoints[C],F=new mxPoint(x.x/this.scale,x.y/this.scale);0==C?F=c[0]:C==this.state.routedPoints.length-1&&(F=c[c.length-1]);var G=!1;if(null!=p&&1==x.type){var E=this.state.routedPoints[C+1],x=E.x/this.scale-F.x,E=E.y/this.scale-F.y,x=x*x+E*E;null==D&&(D=new mxPoint(F.x-p.x,F.y-p.y),m=Math.sqrt(D.x*D.x+D.y*D.y),0<m?(D.x=D.x*b/m,D.y=D.y*b/m):D=null);x>b*b&&0<m&&(x=p.x-
-F.x,E=p.y-F.y,x=x*x+E*E,x>b*b&&(G=new mxPoint(F.x-D.x,F.y-D.y),x=new mxPoint(F.x+D.x,F.y+D.y),q.push(G),this.addPoints(a,q,d,f,!1,null,g),q=0>Math.round(D.x)||0==Math.round(D.x)&&0>=Math.round(D.y)?1:-1,g=!1,"sharp"==e?(a.lineTo(G.x-D.y*q,G.y+D.x*q),a.lineTo(x.x-D.y*q,x.y+D.x*q),a.lineTo(x.x,x.y)):"arc"==e?(q*=1.3,a.curveTo(G.x-D.y*q,G.y+D.x*q,x.x-D.y*q,x.y+D.x*q,x.x,x.y)):(a.moveTo(x.x,x.y),g=!0),q=[x],G=!0))}else D=null;G||(q.push(F),p=F)}this.addPoints(a,q,d,f,!1,null,g);a.stroke()}};var m=mxGraphView.prototype.updateFloatingTerminalPoint;
-mxGraphView.prototype.updateFloatingTerminalPoint=function(a,c,d,b){if(null==c||null==a||"1"!=c.style.snapToPoint&&"1"!=a.style.snapToPoint)m.apply(this,arguments);else{c=this.getTerminalPort(a,c,b);var f=this.getNextPoint(a,d,b),e=this.graph.isOrthogonal(a),g=mxUtils.toRadians(Number(c.style[mxConstants.STYLE_ROTATION]||"0")),l=new mxPoint(c.getCenterX(),c.getCenterY());if(0!=g)var p=Math.cos(-g),k=Math.sin(-g),f=mxUtils.getRotatedPoint(f,p,k,l);p=parseFloat(a.style[mxConstants.STYLE_PERIMETER_SPACING]||
-0);p+=parseFloat(a.style[b?mxConstants.STYLE_SOURCE_PERIMETER_SPACING:mxConstants.STYLE_TARGET_PERIMETER_SPACING]||0);f=this.getPerimeterPoint(c,f,0==g&&e,p);0!=g&&(p=Math.cos(g),k=Math.sin(g),f=mxUtils.getRotatedPoint(f,p,k,l));a.setAbsoluteTerminalPoint(this.snapToAnchorPoint(a,c,d,b,f),b)}};mxGraphView.prototype.snapToAnchorPoint=function(a,c,d,b,e){if(null!=c&&null!=a){a=this.graph.getAllConnectionConstraints(c);b=d=null;if(null!=a)for(var f=0;f<a.length;f++){var g=this.graph.getConnectionPoint(c,
-a[f]);if(null!=g){var l=(g.x-e.x)*(g.x-e.x)+(g.y-e.y)*(g.y-e.y);if(null==b||l<b)d=g,b=l}}null!=d&&(e=d)}return e};var q=mxStencil.prototype.evaluateTextAttribute;mxStencil.prototype.evaluateTextAttribute=function(a,c,d){var f=q.apply(this,arguments);"1"==a.getAttribute("placeholders")&&null!=d.state&&(f=d.state.view.graph.replacePlaceholders(d.state.cell,f));return f};var c=mxCellRenderer.prototype.createShape;mxCellRenderer.prototype.createShape=function(a){if(null!=a.style&&"undefined"!==typeof pako){var f=
+"jumpStyle","none"),g=!0,p=null,l=null,q=[],D=null;a.begin();for(var C=0;C<this.state.routedPoints.length;C++){var x=this.state.routedPoints[C],F=new mxPoint(x.x/this.scale,x.y/this.scale);0==C?F=c[0]:C==this.state.routedPoints.length-1&&(F=c[c.length-1]);var G=!1;if(null!=p&&1==x.type){var E=this.state.routedPoints[C+1],x=E.x/this.scale-F.x,E=E.y/this.scale-F.y,x=x*x+E*E;null==D&&(D=new mxPoint(F.x-p.x,F.y-p.y),l=Math.sqrt(D.x*D.x+D.y*D.y),0<l?(D.x=D.x*b/l,D.y=D.y*b/l):D=null);x>b*b&&0<l&&(x=p.x-
+F.x,E=p.y-F.y,x=x*x+E*E,x>b*b&&(G=new mxPoint(F.x-D.x,F.y-D.y),x=new mxPoint(F.x+D.x,F.y+D.y),q.push(G),this.addPoints(a,q,d,f,!1,null,g),q=0>Math.round(D.x)||0==Math.round(D.x)&&0>=Math.round(D.y)?1:-1,g=!1,"sharp"==e?(a.lineTo(G.x-D.y*q,G.y+D.x*q),a.lineTo(x.x-D.y*q,x.y+D.x*q),a.lineTo(x.x,x.y)):"arc"==e?(q*=1.3,a.curveTo(G.x-D.y*q,G.y+D.x*q,x.x-D.y*q,x.y+D.x*q,x.x,x.y)):(a.moveTo(x.x,x.y),g=!0),q=[x],G=!0))}else D=null;G||(q.push(F),p=F)}this.addPoints(a,q,d,f,!1,null,g);a.stroke()}};var l=mxGraphView.prototype.updateFloatingTerminalPoint;
+mxGraphView.prototype.updateFloatingTerminalPoint=function(a,c,d,b){if(null==c||null==a||"1"!=c.style.snapToPoint&&"1"!=a.style.snapToPoint)l.apply(this,arguments);else{c=this.getTerminalPort(a,c,b);var f=this.getNextPoint(a,d,b),e=this.graph.isOrthogonal(a),g=mxUtils.toRadians(Number(c.style[mxConstants.STYLE_ROTATION]||"0")),m=new mxPoint(c.getCenterX(),c.getCenterY());if(0!=g)var p=Math.cos(-g),k=Math.sin(-g),f=mxUtils.getRotatedPoint(f,p,k,m);p=parseFloat(a.style[mxConstants.STYLE_PERIMETER_SPACING]||
+0);p+=parseFloat(a.style[b?mxConstants.STYLE_SOURCE_PERIMETER_SPACING:mxConstants.STYLE_TARGET_PERIMETER_SPACING]||0);f=this.getPerimeterPoint(c,f,0==g&&e,p);0!=g&&(p=Math.cos(g),k=Math.sin(g),f=mxUtils.getRotatedPoint(f,p,k,m));a.setAbsoluteTerminalPoint(this.snapToAnchorPoint(a,c,d,b,f),b)}};mxGraphView.prototype.snapToAnchorPoint=function(a,c,d,b,e){if(null!=c&&null!=a){a=this.graph.getAllConnectionConstraints(c);b=d=null;if(null!=a)for(var f=0;f<a.length;f++){var g=this.graph.getConnectionPoint(c,
+a[f]);if(null!=g){var m=(g.x-e.x)*(g.x-e.x)+(g.y-e.y)*(g.y-e.y);if(null==b||m<b)d=g,b=m}}null!=d&&(e=d)}return e};var q=mxStencil.prototype.evaluateTextAttribute;mxStencil.prototype.evaluateTextAttribute=function(a,c,d){var f=q.apply(this,arguments);"1"==a.getAttribute("placeholders")&&null!=d.state&&(f=d.state.view.graph.replacePlaceholders(d.state.cell,f));return f};var c=mxCellRenderer.prototype.createShape;mxCellRenderer.prototype.createShape=function(a){if(null!=a.style&&"undefined"!==typeof pako){var f=
mxUtils.getValue(a.style,mxConstants.STYLE_SHAPE,null);if(null!=f&&"string"===typeof f&&"stencil("==f.substring(0,8))try{var d=f.substring(8,f.length-1),b=mxUtils.parseXml(Graph.decompress(d));return new mxShape(new mxStencil(b.documentElement))}catch(n){null!=window.console&&console.log("Error in shape: "+n)}}return c.apply(this,arguments)}})();mxStencilRegistry.libraries={};mxStencilRegistry.dynamicLoading=!0;mxStencilRegistry.allowEval=!0;mxStencilRegistry.packages=[];
-mxStencilRegistry.getStencil=function(a){var b=mxStencilRegistry.stencils[a];if(null==b&&null==mxCellRenderer.defaultShapes[a]&&mxStencilRegistry.dynamicLoading){var e=mxStencilRegistry.getBasenameForStencil(a);if(null!=e){b=mxStencilRegistry.libraries[e];if(null!=b){if(null==mxStencilRegistry.packages[e]){for(var d=0;d<b.length;d++){var k=b[d];if(".xml"==k.toLowerCase().substring(k.length-4,k.length))mxStencilRegistry.loadStencilSet(k,null);else if(".js"==k.toLowerCase().substring(k.length-3,k.length))try{if(mxStencilRegistry.allowEval){var m=
-mxUtils.load(k);null!=m&&200<=m.getStatus()&&299>=m.getStatus()&&eval.call(window,m.getText())}}catch(q){null!=window.console&&console.log("error in getStencil:",k,q)}}mxStencilRegistry.packages[e]=1}}else e=e.replace("_-_","_"),mxStencilRegistry.loadStencilSet(STENCIL_PATH+"/"+e+".xml",null);b=mxStencilRegistry.stencils[a]}}return b};
+mxStencilRegistry.getStencil=function(a){var b=mxStencilRegistry.stencils[a];if(null==b&&null==mxCellRenderer.defaultShapes[a]&&mxStencilRegistry.dynamicLoading){var e=mxStencilRegistry.getBasenameForStencil(a);if(null!=e){b=mxStencilRegistry.libraries[e];if(null!=b){if(null==mxStencilRegistry.packages[e]){for(var d=0;d<b.length;d++){var k=b[d];if(".xml"==k.toLowerCase().substring(k.length-4,k.length))mxStencilRegistry.loadStencilSet(k,null);else if(".js"==k.toLowerCase().substring(k.length-3,k.length))try{if(mxStencilRegistry.allowEval){var l=
+mxUtils.load(k);null!=l&&200<=l.getStatus()&&299>=l.getStatus()&&eval.call(window,l.getText())}}catch(q){null!=window.console&&console.log("error in getStencil:",k,q)}}mxStencilRegistry.packages[e]=1}}else e=e.replace("_-_","_"),mxStencilRegistry.loadStencilSet(STENCIL_PATH+"/"+e+".xml",null);b=mxStencilRegistry.stencils[a]}}return b};
mxStencilRegistry.getBasenameForStencil=function(a){var b=null;if(null!=a&&"string"===typeof a&&(a=a.split("."),0<a.length&&"mxgraph"==a[0]))for(var b=a[1],e=2;e<a.length-1;e++)b+="/"+a[e];return b};
-mxStencilRegistry.loadStencilSet=function(a,b,e,d){var k=mxStencilRegistry.packages[a];if(null!=e&&e||null==k){var m=!1;if(null==k)try{if(d){mxStencilRegistry.loadStencil(a,mxUtils.bind(this,function(d){null!=d&&null!=d.documentElement&&(mxStencilRegistry.packages[a]=d,m=!0,mxStencilRegistry.parseStencilSet(d.documentElement,b,m))}));return}k=mxStencilRegistry.loadStencil(a);mxStencilRegistry.packages[a]=k;m=!0}catch(q){null!=window.console&&console.log("error in loadStencilSet:",a,q)}null!=k&&null!=
-k.documentElement&&mxStencilRegistry.parseStencilSet(k.documentElement,b,m)}};mxStencilRegistry.loadStencil=function(a,b){if(null!=b)mxUtils.get(a,mxUtils.bind(this,function(a){b(200<=a.getStatus()&&299>=a.getStatus()?a.getXml():null)}));else return mxUtils.load(a).getXml()};mxStencilRegistry.parseStencilSets=function(a){for(var b=0;b<a.length;b++)mxStencilRegistry.parseStencilSet(mxUtils.parseXml(a[b]).documentElement)};
-mxStencilRegistry.parseStencilSet=function(a,b,e){if("stencils"==a.nodeName)for(var d=a.firstChild;null!=d;)"shapes"==d.nodeName&&mxStencilRegistry.parseStencilSet(d,b,e),d=d.nextSibling;else{e=null!=e?e:!0;var d=a.firstChild,k="";a=a.getAttribute("name");for(null!=a&&(k=a+".");null!=d;){if(d.nodeType==mxConstants.NODETYPE_ELEMENT&&(a=d.getAttribute("name"),null!=a)){var k=k.toLowerCase(),m=a.replace(/ /g,"_");e&&mxStencilRegistry.addStencil(k+m.toLowerCase(),new mxStencil(d));if(null!=b){var q=d.getAttribute("w"),
-c=d.getAttribute("h"),q=null==q?80:parseInt(q,10),c=null==c?80:parseInt(c,10);b(k,m,a,q,c)}}d=d.nextSibling}}};
+mxStencilRegistry.loadStencilSet=function(a,b,e,d){var k=mxStencilRegistry.packages[a];if(null!=e&&e||null==k){var l=!1;if(null==k)try{if(d){mxStencilRegistry.loadStencil(a,mxUtils.bind(this,function(d){null!=d&&null!=d.documentElement&&(mxStencilRegistry.packages[a]=d,l=!0,mxStencilRegistry.parseStencilSet(d.documentElement,b,l))}));return}k=mxStencilRegistry.loadStencil(a);mxStencilRegistry.packages[a]=k;l=!0}catch(q){null!=window.console&&console.log("error in loadStencilSet:",a,q)}null!=k&&null!=
+k.documentElement&&mxStencilRegistry.parseStencilSet(k.documentElement,b,l)}};mxStencilRegistry.loadStencil=function(a,b){if(null!=b)mxUtils.get(a,mxUtils.bind(this,function(a){b(200<=a.getStatus()&&299>=a.getStatus()?a.getXml():null)}));else return mxUtils.load(a).getXml()};mxStencilRegistry.parseStencilSets=function(a){for(var b=0;b<a.length;b++)mxStencilRegistry.parseStencilSet(mxUtils.parseXml(a[b]).documentElement)};
+mxStencilRegistry.parseStencilSet=function(a,b,e){if("stencils"==a.nodeName)for(var d=a.firstChild;null!=d;)"shapes"==d.nodeName&&mxStencilRegistry.parseStencilSet(d,b,e),d=d.nextSibling;else{e=null!=e?e:!0;var d=a.firstChild,k="";a=a.getAttribute("name");for(null!=a&&(k=a+".");null!=d;){if(d.nodeType==mxConstants.NODETYPE_ELEMENT&&(a=d.getAttribute("name"),null!=a)){var k=k.toLowerCase(),l=a.replace(/ /g,"_");e&&mxStencilRegistry.addStencil(k+l.toLowerCase(),new mxStencil(d));if(null!=b){var q=d.getAttribute("w"),
+c=d.getAttribute("h"),q=null==q?80:parseInt(q,10),c=null==c?80:parseInt(c,10);b(k,l,a,q,c)}}d=d.nextSibling}}};
"undefined"!=typeof mxVertexHandler&&function(){function a(){var a=document.createElement("div");a.className="geHint";a.style.whiteSpace="nowrap";a.style.position="absolute";return a}function b(a,c){switch(c){case mxConstants.POINTS:return a;case mxConstants.MILLIMETERS:return(a/mxConstants.PIXELS_PER_MM).toFixed(1);case mxConstants.INCHES:return(a/mxConstants.PIXELS_PER_INCH).toFixed(2)}}mxConstants.HANDLE_FILLCOLOR="#29b6f2";mxConstants.HANDLE_STROKECOLOR="#0088cf";mxConstants.VERTEX_SELECTION_COLOR=
"#00a8ff";mxConstants.OUTLINE_COLOR="#00a8ff";mxConstants.OUTLINE_HANDLE_FILLCOLOR="#99ccff";mxConstants.OUTLINE_HANDLE_STROKECOLOR="#00a8ff";mxConstants.CONNECT_HANDLE_FILLCOLOR="#cee7ff";mxConstants.EDGE_SELECTION_COLOR="#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=5;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGraphHandler.prototype.removeEmptyParents=
!0;mxRubberband.prototype.fadeOut=!0;mxGuide.prototype.isEnabledForEvent=function(a){return!mxEvent.isAltDown(a)};var e=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(a){return mxEvent.isControlDown(a)||e.apply(this,arguments)};mxConstraintHandler.prototype.createHighlightShape=function(){var a=new mxEllipse(null,this.highlightColor,this.highlightColor,0);a.opacity=mxConstants.HIGHLIGHT_OPACITY;return a};mxConnectionHandler.prototype.livePreview=
@@ -2429,22 +2429,22 @@ orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edg
(a+="jumpStyle="+this.currentEdgeStyle.jumpStyle+";");null!=this.currentEdgeStyle.jumpSize&&(a+="jumpSize="+this.currentEdgeStyle.jumpSize+";");null!=this.currentEdgeStyle.orthogonalLoop?a+="orthogonalLoop="+this.currentEdgeStyle.orthogonalLoop+";":null!=Graph.prototype.defaultEdgeStyle.orthogonalLoop&&(a+="orthogonalLoop="+Graph.prototype.defaultEdgeStyle.orthogonalLoop+";");null!=this.currentEdgeStyle.jettySize?a+="jettySize="+this.currentEdgeStyle.jettySize+";":null!=Graph.prototype.defaultEdgeStyle.jettySize&&
(a+="jettySize="+Graph.prototype.defaultEdgeStyle.jettySize+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(a+="elbow="+this.currentEdgeStyle.elbow+";");return a=null!=this.currentEdgeStyle.html?a+("html="+this.currentEdgeStyle.html+";"):a+"html=1;"};Graph.prototype.getPagePadding=function(){return new mxPoint(0,0)};Graph.prototype.loadStylesheet=function(){var a=null!=this.themes?this.themes[this.defaultThemeName]:mxStyleRegistry.dynamicLoading?mxUtils.load(STYLE_PATH+
"/default.xml").getDocumentElement():null;null!=a&&(new mxCodec(a.ownerDocument)).decode(a,this.getStylesheet())};Graph.prototype.createCellLookup=function(a,c){c=null!=c?c:{};for(var f=0;f<a.length;f++){var d=a[f];c[mxObjectIdentity.get(d)]=d.getId();for(var b=this.model.getChildCount(d),e=0;e<b;e++)this.createCellLookup([this.model.getChildAt(d,e)],c)}return c};Graph.prototype.createCellMapping=function(a,c,f){f=null!=f?f:{};for(var d in a){var b=c[d];null==f[b]&&(f[b]=a[d].getId()||"")}return f};
-Graph.prototype.importGraphModel=function(a,c,f,d){c=null!=c?c:0;f=null!=f?f:0;var b=new mxCodec(a.ownerDocument),e=new mxGraphModel;b.decode(a,e);a=[];var b={},g={},l=e.getChildren(this.cloneCell(e.root,this.isCloneInvalidEdges(),b));if(null!=l){var p=this.createCellLookup([e.root]),l=l.slice();this.model.beginUpdate();try{if(1!=l.length||this.isCellLocked(this.getDefaultParent()))for(e=0;e<l.length;e++){var n=this.model.getChildren(this.moveCells([l[e]],c,f,!1,this.model.getRoot())[0]);null!=n&&
-(a=a.concat(n))}else a=this.moveCells(e.getChildren(l[0]),c,f,!1,this.getDefaultParent()),g[e.getChildAt(e.root,0).getId()]=this.getDefaultParent().getId();if(null!=a&&(this.createCellMapping(b,p,g),this.updateCustomLinks(g,a),d)){this.isGridEnabled()&&(c=this.snap(c),f=this.snap(f));var u=this.getBoundingBoxFromGeometry(a,!0);null!=u&&this.moveCells(a,c-u.x,f-u.y)}}finally{this.model.endUpdate()}}return a};Graph.prototype.encodeCells=function(a){for(var c={},f=this.cloneCells(a,null,c),d=new mxDictionary,
+Graph.prototype.importGraphModel=function(a,c,f,d){c=null!=c?c:0;f=null!=f?f:0;var b=new mxCodec(a.ownerDocument),e=new mxGraphModel;b.decode(a,e);a=[];var b={},g={},m=e.getChildren(this.cloneCell(e.root,this.isCloneInvalidEdges(),b));if(null!=m){var p=this.createCellLookup([e.root]),m=m.slice();this.model.beginUpdate();try{if(1!=m.length||this.isCellLocked(this.getDefaultParent()))for(e=0;e<m.length;e++){var n=this.model.getChildren(this.moveCells([m[e]],c,f,!1,this.model.getRoot())[0]);null!=n&&
+(a=a.concat(n))}else a=this.moveCells(e.getChildren(m[0]),c,f,!1,this.getDefaultParent()),g[e.getChildAt(e.root,0).getId()]=this.getDefaultParent().getId();if(null!=a&&(this.createCellMapping(b,p,g),this.updateCustomLinks(g,a),d)){this.isGridEnabled()&&(c=this.snap(c),f=this.snap(f));var u=this.getBoundingBoxFromGeometry(a,!0);null!=u&&this.moveCells(a,c-u.x,f-u.y)}}finally{this.model.endUpdate()}}return a};Graph.prototype.encodeCells=function(a){for(var c={},f=this.cloneCells(a,null,c),d=new mxDictionary,
b=0;b<a.length;b++)d.put(a[b],!0);for(b=0;b<f.length;b++){var e=this.view.getState(a[b]);if(null!=e){var g=this.getCellGeometry(f[b]);null==g||!g.relative||this.model.isEdge(a[b])||d.get(this.model.getParent(a[b]))||(g.relative=!1,g.x=e.x/e.view.scale-e.view.translate.x,g.y=e.y/e.view.scale-e.view.translate.y)}}d=new mxCodec;e=new mxGraphModel;g=e.getChildAt(e.getRoot(),0);for(b=0;b<f.length;b++)e.add(g,f[b]);this.updateCustomLinks(this.createCellMapping(c,this.createCellLookup(a)),f);return d.encode(e)};
-var m=Graph.prototype.selectCell;Graph.prototype.selectCell=function(a,c,f){if(c||f)m.apply(this,arguments);else{var d=this.getSelectionCell(),b=null,e=[],g=mxUtils.bind(this,function(c){if(null!=this.view.getState(c)&&(this.model.isVertex(c)||this.model.isEdge(c)))if(e.push(c),c==d)b=e.length-1;else if(a&&null==d&&0<e.length||null!=b&&a&&e.length>b||!a&&0<b)return;for(var f=0;f<this.model.getChildCount(c);f++)g(this.model.getChildAt(c,f))});g(this.model.root);0<e.length&&(b=null!=b?mxUtils.mod(b+
-(a?1:-1),e.length):0,this.setSelectionCell(e[b]))}};var q=Graph.prototype.moveCells;Graph.prototype.moveCells=function(a,c,f,d,b,e,g){g=null!=g?g:{};var l=q.apply(this,arguments);d&&this.updateCustomLinks(this.createCellMapping(g,this.createCellLookup(a)),l);return l};var c=Graph.prototype.removeCells;Graph.prototype.removeCells=function(a,f){var d=[];this.model.beginUpdate();try{for(var b=0;b<a.length;b++)this.isTableCell(a[b])||this.isTableRow(a[b])?this.labelChanged(a[b],""):d.push(a[b]);d=c.apply(this,
+var l=Graph.prototype.selectCell;Graph.prototype.selectCell=function(a,c,f){if(c||f)l.apply(this,arguments);else{var d=this.getSelectionCell(),b=null,e=[],g=mxUtils.bind(this,function(c){if(null!=this.view.getState(c)&&(this.model.isVertex(c)||this.model.isEdge(c)))if(e.push(c),c==d)b=e.length-1;else if(a&&null==d&&0<e.length||null!=b&&a&&e.length>b||!a&&0<b)return;for(var f=0;f<this.model.getChildCount(c);f++)g(this.model.getChildAt(c,f))});g(this.model.root);0<e.length&&(b=null!=b?mxUtils.mod(b+
+(a?1:-1),e.length):0,this.setSelectionCell(e[b]))}};var q=Graph.prototype.moveCells;Graph.prototype.moveCells=function(a,c,f,d,b,e,g){g=null!=g?g:{};var m=q.apply(this,arguments);d&&this.updateCustomLinks(this.createCellMapping(g,this.createCellLookup(a)),m);return m};var c=Graph.prototype.removeCells;Graph.prototype.removeCells=function(a,f){var d=[];this.model.beginUpdate();try{for(var b=0;b<a.length;b++)this.isTableCell(a[b])||this.isTableRow(a[b])?this.labelChanged(a[b],""):d.push(a[b]);d=c.apply(this,
[d,f])}finally{this.model.endUpdate()}return d};Graph.prototype.updateCustomLinks=function(a,c){for(var f=0;f<c.length;f++)null!=c[f]&&this.updateCustomLinksForCell(a,c[f])};Graph.prototype.updateCustomLinksForCell=function(a,c){};Graph.prototype.getAllConnectionConstraints=function(a,c){if(null!=a){var f=mxUtils.getValue(a.style,"points",null);if(null!=f){var d=[];try{for(var b=JSON.parse(f),f=0;f<b.length;f++){var e=b[f];d.push(new mxConnectionConstraint(new mxPoint(e[0],e[1]),2<e.length?"0"!=e[2]:
!0,null,3<e.length?e[3]:0,4<e.length?e[4]:0))}}catch(ma){}return d}if(null!=a.shape&&null!=a.shape.bounds){e=a.shape.direction;b=a.shape.bounds;f=a.shape.scale;d=b.width/f;b=b.height/f;if(e==mxConstants.DIRECTION_NORTH||e==mxConstants.DIRECTION_SOUTH)e=d,d=b,b=e;f=a.shape.getConstraints(a.style,d,b);if(null!=f)return f;if(null!=a.shape.stencil&&null!=a.shape.stencil.constraints)return a.shape.stencil.constraints;if(null!=a.shape.constraints)return a.shape.constraints}}return null};Graph.prototype.flipEdge=
function(a){if(null!=a){var c=this.getCurrentCellStyle(a),c=mxUtils.getValue(c,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL;this.setCellStyles(mxConstants.STYLE_ELBOW,c,[a])}};Graph.prototype.isValidRoot=function(a){for(var c=this.model.getChildCount(a),f=0,d=0;d<c;d++){var b=this.model.getChildAt(a,d);this.model.isVertex(b)&&(b=this.getCellGeometry(b),null==b||b.relative||f++)}return 0<f||this.isContainer(a)};
Graph.prototype.isValidDropTarget=function(a){var c=this.getCurrentCellStyle(a);return("1"!=mxUtils.getValue(c,"part","0")||this.isContainer(a))&&"0"!=mxUtils.getValue(c,"dropTarget","1")&&(mxGraph.prototype.isValidDropTarget.apply(this,arguments)||this.isContainer(a))};Graph.prototype.createGroupCell=function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var c=mxGraph.prototype.isExtendParentsOnAdd.apply(this,
arguments);if(c&&null!=a&&null!=this.layoutManager){var f=this.model.getParent(a);null!=f&&(f=this.layoutManager.getLayout(f),null!=f&&f.constructor==mxStackLayout&&(c=!1))}return c};Graph.prototype.getPreferredSizeForCell=function(a){var c=mxGraph.prototype.getPreferredSizeForCell.apply(this,arguments);null!=c&&(c.width+=10,c.height+=4,this.gridEnabled&&(c.width=this.snap(c.width),c.height=this.snap(c.height)));return c};Graph.prototype.turnShapes=function(a,c){var f=this.getModel(),d=[];f.beginUpdate();
-try{for(var b=0;b<a.length;b++){var e=a[b];if(f.isEdge(e)){var g=f.getTerminal(e,!0),l=f.getTerminal(e,!1);f.setTerminal(e,l,!0);f.setTerminal(e,g,!1);var p=f.getGeometry(e);if(null!=p){p=p.clone();null!=p.points&&p.points.reverse();var n=p.getTerminalPoint(!0),u=p.getTerminalPoint(!1);p.setTerminalPoint(n,!1);p.setTerminalPoint(u,!0);f.setGeometry(e,p);var y=this.view.getState(e),t=this.view.getState(g),z=this.view.getState(l);if(null!=y){var v=null!=t?this.getConnectionConstraint(y,t,!0):null,m=
-null!=z?this.getConnectionConstraint(y,z,!1):null;this.setConnectionConstraint(e,g,!0,m);this.setConnectionConstraint(e,l,!1,v)}d.push(e)}}else if(f.isVertex(e)&&(p=this.getCellGeometry(e),null!=p)){p=p.clone();p.x+=p.width/2-p.height/2;p.y+=p.height/2-p.width/2;var k=p.width;p.width=p.height;p.height=k;f.setGeometry(e,p);var Y=this.view.getState(e);if(null!=Y){var K=[mxConstants.DIRECTION_EAST,mxConstants.DIRECTION_SOUTH,mxConstants.DIRECTION_WEST,mxConstants.DIRECTION_NORTH],L=mxUtils.getValue(Y.style,
+try{for(var b=0;b<a.length;b++){var e=a[b];if(f.isEdge(e)){var g=f.getTerminal(e,!0),m=f.getTerminal(e,!1);f.setTerminal(e,m,!0);f.setTerminal(e,g,!1);var p=f.getGeometry(e);if(null!=p){p=p.clone();null!=p.points&&p.points.reverse();var n=p.getTerminalPoint(!0),u=p.getTerminalPoint(!1);p.setTerminalPoint(n,!1);p.setTerminalPoint(u,!0);f.setGeometry(e,p);var y=this.view.getState(e),t=this.view.getState(g),z=this.view.getState(m);if(null!=y){var l=null!=t?this.getConnectionConstraint(y,t,!0):null,k=
+null!=z?this.getConnectionConstraint(y,z,!1):null;this.setConnectionConstraint(e,g,!0,k);this.setConnectionConstraint(e,m,!1,l)}d.push(e)}}else if(f.isVertex(e)&&(p=this.getCellGeometry(e),null!=p)){p=p.clone();p.x+=p.width/2-p.height/2;p.y+=p.height/2-p.width/2;var v=p.width;p.width=p.height;p.height=v;f.setGeometry(e,p);var Y=this.view.getState(e);if(null!=Y){var K=[mxConstants.DIRECTION_EAST,mxConstants.DIRECTION_SOUTH,mxConstants.DIRECTION_WEST,mxConstants.DIRECTION_NORTH],L=mxUtils.getValue(Y.style,
mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST);this.setCellStyles(mxConstants.STYLE_DIRECTION,K[mxUtils.mod(mxUtils.indexOf(K,L)+(c?-1:1),K.length)],[e])}d.push(e)}}}finally{f.endUpdate()}return d};Graph.prototype.stencilHasPlaceholders=function(a){if(null!=a&&null!=a.fgNode)for(a=a.fgNode.firstChild;null!=a;){if("text"==a.nodeName&&"1"==a.getAttribute("placeholders"))return!0;a=a.nextSibling}return!1};Graph.prototype.processChange=function(a){mxGraph.prototype.processChange.apply(this,arguments);
a instanceof mxValueChange&&null!=a.cell&&null!=a.cell.value&&"object"==typeof a.cell.value&&this.invalidateDescendantsWithPlaceholders(a.cell)};Graph.prototype.invalidateDescendantsWithPlaceholders=function(a){a=this.model.getDescendants(a);if(0<a.length)for(var c=0;c<a.length;c++){var f=this.view.getState(a[c]);null!=f&&null!=f.shape&&null!=f.shape.stencil&&this.stencilHasPlaceholders(f.shape.stencil)?this.removeStateForCell(a[c]):this.isReplacePlaceholders(a[c])&&this.view.invalidate(a[c],!1,!1)}};
Graph.prototype.replaceElement=function(a,c){for(var f=a.ownerDocument.createElement(null!=c?c:"span"),d=Array.prototype.slice.call(a.attributes);attr=d.pop();)f.setAttribute(attr.nodeName,attr.nodeValue);f.innerHTML=a.innerHTML;a.parentNode.replaceChild(f,a)};Graph.prototype.processElements=function(a,c){if(null!=a)for(var f=a.getElementsByTagName("*"),d=0;d<f.length;d++)c(f[d])};Graph.prototype.updateLabelElements=function(a,c,f){a=null!=a?a:this.getSelectionCells();for(var d=document.createElement("div"),
-b=0;b<a.length;b++)if(this.isHtmlLabel(a[b])){var e=this.convertValueToString(a[b]);if(null!=e&&0<e.length){d.innerHTML=e;for(var g=d.getElementsByTagName(null!=f?f:"*"),l=0;l<g.length;l++)c(g[l]);d.innerHTML!=e&&this.cellLabelChanged(a[b],d.innerHTML)}}};Graph.prototype.cellLabelChanged=function(a,c,f){c=Graph.zapGremlins(c);this.model.beginUpdate();try{if(null!=a.value&&"object"==typeof a.value){if(this.isReplacePlaceholders(a)&&null!=a.getAttribute("placeholder"))for(var d=a.getAttribute("placeholder"),
+b=0;b<a.length;b++)if(this.isHtmlLabel(a[b])){var e=this.convertValueToString(a[b]);if(null!=e&&0<e.length){d.innerHTML=e;for(var g=d.getElementsByTagName(null!=f?f:"*"),m=0;m<g.length;m++)c(g[m]);d.innerHTML!=e&&this.cellLabelChanged(a[b],d.innerHTML)}}};Graph.prototype.cellLabelChanged=function(a,c,f){c=Graph.zapGremlins(c);this.model.beginUpdate();try{if(null!=a.value&&"object"==typeof a.value){if(this.isReplacePlaceholders(a)&&null!=a.getAttribute("placeholder"))for(var d=a.getAttribute("placeholder"),
b=a;null!=b;){if(b==this.model.getRoot()||null!=b.value&&"object"==typeof b.value&&b.hasAttribute(d)){this.setAttributeForCell(b,d,c);break}b=this.model.getParent(b)}var e=a.value.cloneNode(!0);e.setAttribute("label",c);c=e}mxGraph.prototype.cellLabelChanged.apply(this,arguments)}finally{this.model.endUpdate()}};Graph.prototype.cellsRemoved=function(a){if(null!=a){for(var c=new mxDictionary,f=0;f<a.length;f++)c.put(a[f],!0);for(var d=[],f=0;f<a.length;f++){var b=this.model.getParent(a[f]);null==b||
c.get(b)||(c.put(b,!0),d.push(b))}for(f=0;f<d.length;f++)if(b=this.view.getState(d[f]),null!=b&&(this.model.isEdge(b.cell)||this.model.isVertex(b.cell))&&this.isCellDeletable(b.cell)&&this.isTransparentState(b)){for(var e=!0,g=0;g<this.model.getChildCount(b.cell)&&e;g++)c.get(this.model.getChildAt(b.cell,g))||(e=!1);e&&a.push(b.cell)}}mxGraph.prototype.cellsRemoved.apply(this,arguments)};Graph.prototype.removeCellsAfterUngroup=function(a){for(var c=[],f=0;f<a.length;f++)this.isCellDeletable(a[f])&&
this.isTransparentState(this.view.getState(a[f]))&&c.push(a[f]);a=c;mxGraph.prototype.removeCellsAfterUngroup.apply(this,arguments)};Graph.prototype.setLinkForCell=function(a,c){this.setAttributeForCell(a,"link",c)};Graph.prototype.setTooltipForCell=function(a,c){this.setAttributeForCell(a,"tooltip",c)};Graph.prototype.getAttributeForCell=function(a,c,f){a=null!=a.value&&"object"===typeof a.value?a.value.getAttribute(c):null;return null!=a?a:f};Graph.prototype.setAttributeForCell=function(a,c,f){var b;
@@ -2456,31 +2456,31 @@ this.view.translate.x,f=this.container.scrollTop/this.view.scale-this.view.trans
this.view.translate.x-a.width/2),this.snap(this.container.clientHeight/2/this.view.scale-this.view.translate.y-a.height/2))};Graph.prototype.isMouseInsertPoint=function(){return!1};Graph.prototype.addText=function(a,c,f){var b=new mxCell;b.value="Text";b.geometry=new mxGeometry(0,0,0,0);b.vertex=!0;if(null!=f&&this.model.isEdge(f.cell)){b.style="edgeLabel;html=1;align=center;verticalAlign=middle;resizable=0;points=[];";b.geometry.relative=!0;b.connectable=!1;var d=this.view.getRelativePoint(f,a,c);
b.geometry.x=Math.round(1E4*d.x)/1E4;b.geometry.y=Math.round(d.y);b.geometry.offset=new mxPoint(0,0);var d=this.view.getPoint(f,b.geometry),e=this.view.scale;b.geometry.offset=new mxPoint(Math.round((a-d.x)/e),Math.round((c-d.y)/e))}else d=this.view.translate,b.style="text;html=1;align=center;verticalAlign=middle;resizable=0;points=[];",b.geometry.width=40,b.geometry.height=20,b.geometry.x=Math.round(a/this.view.scale)-d.x-(null!=f?f.origin.x:0),b.geometry.y=Math.round(c/this.view.scale)-d.y-(null!=
f?f.origin.y:0),b.style+="autosize=1;";this.getModel().beginUpdate();try{this.addCells([b],null!=f?f.cell:null),this.fireEvent(new mxEventObject("textInserted","cells",[b])),this.autoSizeCell(b)}finally{this.getModel().endUpdate()}return b};Graph.prototype.addClickHandler=function(a,c,f){var b=mxUtils.bind(this,function(){var a=this.container.getElementsByTagName("a");if(null!=a)for(var f=0;f<a.length;f++){var b=this.getAbsoluteUrl(a[f].getAttribute("href"));null!=b&&(a[f].setAttribute("rel",this.linkRelation),
-a[f].setAttribute("href",b),null!=c&&mxEvent.addGestureListeners(a[f],null,null,c))}});this.model.addListener(mxEvent.CHANGE,b);b();var d=this.container.style.cursor,e=this.getTolerance(),g=this,l={currentState:null,currentLink:null,highlight:null!=a&&""!=a&&a!=mxConstants.NONE?new mxCellHighlight(g,a,4):null,startX:0,startY:0,scrollLeft:0,scrollTop:0,updateCurrentState:function(a){var c=a.sourceState;if(null==c||null==g.getLinkForCell(c.cell))a=g.getCellAt(a.getGraphX(),a.getGraphY(),null,null,null,
+a[f].setAttribute("href",b),null!=c&&mxEvent.addGestureListeners(a[f],null,null,c))}});this.model.addListener(mxEvent.CHANGE,b);b();var d=this.container.style.cursor,e=this.getTolerance(),g=this,m={currentState:null,currentLink:null,highlight:null!=a&&""!=a&&a!=mxConstants.NONE?new mxCellHighlight(g,a,4):null,startX:0,startY:0,scrollLeft:0,scrollTop:0,updateCurrentState:function(a){var c=a.sourceState;if(null==c||null==g.getLinkForCell(c.cell))a=g.getCellAt(a.getGraphX(),a.getGraphY(),null,null,null,
function(a,c,f){return null==g.getLinkForCell(a.cell)}),c=g.view.getState(a);c!=this.currentState&&(null!=this.currentState&&this.clear(),this.currentState=c,null!=this.currentState&&this.activate(this.currentState))},mouseDown:function(a,c){this.startX=c.getGraphX();this.startY=c.getGraphY();this.scrollLeft=g.container.scrollLeft;this.scrollTop=g.container.scrollTop;null==this.currentLink&&"auto"==g.container.style.overflow&&(g.container.style.cursor="move");this.updateCurrentState(c)},mouseMove:function(a,
c){if(g.isMouseDown){if(null!=this.currentLink){var f=Math.abs(this.startX-c.getGraphX()),b=Math.abs(this.startY-c.getGraphY());(f>e||b>e)&&this.clear()}}else{for(f=c.getSource();null!=f&&"a"!=f.nodeName.toLowerCase();)f=f.parentNode;null!=f?this.clear():(null!=g.tooltipHandler&&null!=this.currentLink&&null!=this.currentState&&g.tooltipHandler.reset(c,!0,this.currentState),(null==this.currentState||c.getState()!=this.currentState&&null!=c.sourceState||!g.intersects(this.currentState,c.getGraphX(),
-c.getGraphY()))&&this.updateCurrentState(c))}},mouseUp:function(a,b){for(var d=b.getSource(),l=b.getEvent();null!=d&&"a"!=d.nodeName.toLowerCase();)d=d.parentNode;null==d&&Math.abs(this.scrollLeft-g.container.scrollLeft)<e&&Math.abs(this.scrollTop-g.container.scrollTop)<e&&(null==b.sourceState||!b.isSource(b.sourceState.control))&&((mxEvent.isLeftMouseButton(l)||mxEvent.isMiddleMouseButton(l))&&!mxEvent.isPopupTrigger(l)||mxEvent.isTouchEvent(l))&&(null!=this.currentLink?(d=g.isBlankLink(this.currentLink),
-"data:"!==this.currentLink.substring(0,5)&&d||null==c||c(l,this.currentLink),mxEvent.isConsumed(l)||(l=mxEvent.isMiddleMouseButton(l)?"_blank":d?g.linkTarget:"_top",g.openLink(this.currentLink,l),b.consume())):null!=f&&!b.isConsumed()&&Math.abs(this.scrollLeft-g.container.scrollLeft)<e&&Math.abs(this.scrollTop-g.container.scrollTop)<e&&Math.abs(this.startX-b.getGraphX())<e&&Math.abs(this.startY-b.getGraphY())<e&&f(b.getEvent()));this.clear()},activate:function(a){this.currentLink=g.getAbsoluteUrl(g.getLinkForCell(a.cell));
-null!=this.currentLink&&(g.container.style.cursor="pointer",null!=this.highlight&&this.highlight.highlight(a))},clear:function(){null!=g.container&&(g.container.style.cursor=d);this.currentLink=this.currentState=null;null!=this.highlight&&this.highlight.hide();null!=g.tooltipHandler&&g.tooltipHandler.hide()}};g.click=function(a){};g.addMouseListener(l);mxEvent.addListener(document,"mouseleave",function(a){l.clear()})};Graph.prototype.duplicateCells=function(a,c){a=null!=a?a:this.getSelectionCells();
-c=null!=c?c:!0;a=this.model.getTopmostCells(a);var f=this.getModel(),b=this.gridSize,d=[];f.beginUpdate();try{for(var e=this.cloneCells(a,!1,null,!0),g=0;g<a.length;g++){var l=f.getParent(a[g]),p=this.moveCells([e[g]],b,b,!1)[0];d.push(p);if(c)f.add(l,e[g]);else{var n=l.getIndex(a[g]);f.add(l,e[g],n+1)}}}finally{f.endUpdate()}return d};Graph.prototype.insertImage=function(a,c,f){if(null!=a&&null!=this.cellEditor.textarea){for(var b=this.cellEditor.textarea.getElementsByTagName("img"),d=[],e=0;e<b.length;e++)d.push(b[e]);
+c.getGraphY()))&&this.updateCurrentState(c))}},mouseUp:function(a,b){for(var d=b.getSource(),m=b.getEvent();null!=d&&"a"!=d.nodeName.toLowerCase();)d=d.parentNode;null==d&&Math.abs(this.scrollLeft-g.container.scrollLeft)<e&&Math.abs(this.scrollTop-g.container.scrollTop)<e&&(null==b.sourceState||!b.isSource(b.sourceState.control))&&((mxEvent.isLeftMouseButton(m)||mxEvent.isMiddleMouseButton(m))&&!mxEvent.isPopupTrigger(m)||mxEvent.isTouchEvent(m))&&(null!=this.currentLink?(d=g.isBlankLink(this.currentLink),
+"data:"!==this.currentLink.substring(0,5)&&d||null==c||c(m,this.currentLink),mxEvent.isConsumed(m)||(m=mxEvent.isMiddleMouseButton(m)?"_blank":d?g.linkTarget:"_top",g.openLink(this.currentLink,m),b.consume())):null!=f&&!b.isConsumed()&&Math.abs(this.scrollLeft-g.container.scrollLeft)<e&&Math.abs(this.scrollTop-g.container.scrollTop)<e&&Math.abs(this.startX-b.getGraphX())<e&&Math.abs(this.startY-b.getGraphY())<e&&f(b.getEvent()));this.clear()},activate:function(a){this.currentLink=g.getAbsoluteUrl(g.getLinkForCell(a.cell));
+null!=this.currentLink&&(g.container.style.cursor="pointer",null!=this.highlight&&this.highlight.highlight(a))},clear:function(){null!=g.container&&(g.container.style.cursor=d);this.currentLink=this.currentState=null;null!=this.highlight&&this.highlight.hide();null!=g.tooltipHandler&&g.tooltipHandler.hide()}};g.click=function(a){};g.addMouseListener(m);mxEvent.addListener(document,"mouseleave",function(a){m.clear()})};Graph.prototype.duplicateCells=function(a,c){a=null!=a?a:this.getSelectionCells();
+c=null!=c?c:!0;a=this.model.getTopmostCells(a);var f=this.getModel(),b=this.gridSize,d=[];f.beginUpdate();try{for(var e=this.cloneCells(a,!1,null,!0),g=0;g<a.length;g++){var m=f.getParent(a[g]),p=this.moveCells([e[g]],b,b,!1)[0];d.push(p);if(c)f.add(m,e[g]);else{var n=m.getIndex(a[g]);f.add(m,e[g],n+1)}}}finally{f.endUpdate()}return d};Graph.prototype.insertImage=function(a,c,f){if(null!=a&&null!=this.cellEditor.textarea){for(var b=this.cellEditor.textarea.getElementsByTagName("img"),d=[],e=0;e<b.length;e++)d.push(b[e]);
document.execCommand("insertimage",!1,a);a=this.cellEditor.textarea.getElementsByTagName("img");if(a.length==d.length+1)for(e=a.length-1;0<=e;e--)if(0==e||a[e]!=d[e-1]){a[e].setAttribute("width",c);a[e].setAttribute("height",f);break}}};Graph.prototype.insertLink=function(a){if(null!=this.cellEditor.textarea)if(0==a.length)document.execCommand("unlink",!1);else if(mxClient.IS_FF){for(var c=this.cellEditor.textarea.getElementsByTagName("a"),f=[],b=0;b<c.length;b++)f.push(c[b]);document.execCommand("createlink",
!1,mxUtils.trim(a));c=this.cellEditor.textarea.getElementsByTagName("a");if(c.length==f.length+1)for(b=c.length-1;0<=b;b--)if(c[b]!=f[b-1]){for(c=c[b].getElementsByTagName("a");0<c.length;){for(f=c[0].parentNode;null!=c[0].firstChild;)f.insertBefore(c[0].firstChild,c[0]);f.removeChild(c[0])}break}}else document.execCommand("createlink",!1,mxUtils.trim(a))};Graph.prototype.isCellResizable=function(a){var c=mxGraph.prototype.isCellResizable.apply(this,arguments),f=this.getCurrentCellStyle(a);return!this.isTableCell(a)&&
-!this.isTableRow(a)&&(c||"0"!=mxUtils.getValue(f,mxConstants.STYLE_RESIZABLE,"1")&&"wrap"==f[mxConstants.STYLE_WHITE_SPACE])};Graph.prototype.distributeCells=function(a,c){null==c&&(c=this.getSelectionCells());if(null!=c&&1<c.length){for(var f=[],b=null,d=null,e=0;e<c.length;e++)if(this.getModel().isVertex(c[e])){var g=this.view.getState(c[e]);if(null!=g){var l=a?g.getCenterX():g.getCenterY(),b=null!=b?Math.max(b,l):l,d=null!=d?Math.min(d,l):l;f.push(g)}}if(2<f.length){f.sort(function(c,f){return a?
-c.x-f.x:c.y-f.y});g=this.view.translate;l=this.view.scale;d=d/l-(a?g.x:g.y);b=b/l-(a?g.x:g.y);this.getModel().beginUpdate();try{for(var p=(b-d)/(f.length-1),b=d,e=1;e<f.length-1;e++){var n=this.view.getState(this.model.getParent(f[e].cell)),u=this.getCellGeometry(f[e].cell),b=b+p;null!=u&&null!=n&&(u=u.clone(),a?u.x=Math.round(b-u.width/2)-n.origin.x:u.y=Math.round(b-u.height/2)-n.origin.y,this.getModel().setGeometry(f[e].cell,u))}}finally{this.getModel().endUpdate()}}}return c};Graph.prototype.isCloneEvent=
-function(a){return mxClient.IS_MAC&&mxEvent.isMetaDown(a)||mxEvent.isControlDown(a)};Graph.prototype.createSvgImageExport=function(){var a=new mxImageExport;a.getLinkForCellState=mxUtils.bind(this,function(a,c){return this.getLinkForCell(a.cell)});return a};Graph.prototype.getSvg=function(a,c,f,b,d,e,g,l,p,n){var u=this.useCssTransforms;u&&(this.useCssTransforms=!1,this.view.revalidate(),this.sizeDidChange());try{c=null!=c?c:1;f=null!=f?f:0;d=null!=d?d:!0;e=null!=e?e:!0;g=null!=g?g:!0;var y=e||b?
-this.getGraphBounds():this.getBoundingBox(this.getSelectionCells());if(null==y)throw Error(mxResources.get("drawingEmpty"));var t=this.view.scale,z=mxUtils.createXmlDocument(),v=null!=z.createElementNS?z.createElementNS(mxConstants.NS_SVG,"svg"):z.createElement("svg");null!=a&&(null!=v.style?v.style.backgroundColor=a:v.setAttribute("style","background-color:"+a));null==z.createElementNS?(v.setAttribute("xmlns",mxConstants.NS_SVG),v.setAttribute("xmlns:xlink",mxConstants.NS_XLINK)):v.setAttributeNS("http://www.w3.org/2000/xmlns/",
-"xmlns:xlink",mxConstants.NS_XLINK);a=c/t;var m=Math.max(1,Math.ceil(y.width*a)+2*f)+(n?5:0),k=Math.max(1,Math.ceil(y.height*a)+2*f)+(n?5:0);v.setAttribute("version","1.1");v.setAttribute("width",m+"px");v.setAttribute("height",k+"px");v.setAttribute("viewBox",(d?"-0.5 -0.5":"0 0")+" "+m+" "+k);z.appendChild(v);var K=null!=z.createElementNS?z.createElementNS(mxConstants.NS_SVG,"g"):z.createElement("g");v.appendChild(K);var L=this.createSvgCanvas(K);L.foOffset=d?-.5:0;L.textOffset=d?-.5:0;L.imageOffset=
-d?-.5:0;L.translate(Math.floor((f/c-y.x)/t),Math.floor((f/c-y.y)/t));var q=document.createElement("div"),x=L.getAlternateText;L.getAlternateText=function(a,c,f,b,d,e,g,l,p,n,u,y,t){if(null!=e&&0<this.state.fontSize)try{mxUtils.isNode(e)?e=e.innerText:(q.innerHTML=e,e=mxUtils.extractTextWithWhitespace(q.childNodes));for(var z=Math.ceil(2*b/this.state.fontSize),da=[],Ja=0,v=0;(0==z||Ja<z)&&v<e.length;){var Ka=e.charCodeAt(v);if(10==Ka||13==Ka){if(0<Ja)break}else da.push(e.charAt(v)),255>Ka&&Ja++;v++}da.length<
-e.length&&1<e.length-da.length&&(e=mxUtils.trim(da.join(""))+"...");return e}catch(Ua){return x.apply(this,arguments)}else return x.apply(this,arguments)};var O=this.backgroundImage;if(null!=O){c=t/c;var I=this.view.translate,A=new mxRectangle(I.x*c,I.y*c,O.width*c,O.height*c);mxUtils.intersects(y,A)&&L.image(I.x,I.y,O.width,O.height,O.src,!0)}L.scale(a);L.textEnabled=g;l=null!=l?l:this.createSvgImageExport();var B=l.drawCellState,Y=l.getLinkForCellState;l.getLinkForCellState=function(a,c){var f=
-Y.apply(this,arguments);return null==f||a.view.graph.isCustomLink(f)?null:f};l.drawCellState=function(a,c){for(var f=a.view.graph,b=f.isCellSelected(a.cell),d=f.model.getParent(a.cell);!e&&!b&&null!=d;)b=f.isCellSelected(d),d=f.model.getParent(d);(e||b)&&B.apply(this,arguments)};l.drawState(this.getView().getState(this.model.root),L);this.updateSvgLinks(v,p,!0);this.addForeignObjectWarning(L,v);return v}finally{u&&(this.useCssTransforms=!0,this.view.revalidate(),this.sizeDidChange())}};Graph.prototype.addForeignObjectWarning=
+!this.isTableRow(a)&&(c||"0"!=mxUtils.getValue(f,mxConstants.STYLE_RESIZABLE,"1")&&"wrap"==f[mxConstants.STYLE_WHITE_SPACE])};Graph.prototype.distributeCells=function(a,c){null==c&&(c=this.getSelectionCells());if(null!=c&&1<c.length){for(var f=[],b=null,d=null,e=0;e<c.length;e++)if(this.getModel().isVertex(c[e])){var g=this.view.getState(c[e]);if(null!=g){var m=a?g.getCenterX():g.getCenterY(),b=null!=b?Math.max(b,m):m,d=null!=d?Math.min(d,m):m;f.push(g)}}if(2<f.length){f.sort(function(c,f){return a?
+c.x-f.x:c.y-f.y});g=this.view.translate;m=this.view.scale;d=d/m-(a?g.x:g.y);b=b/m-(a?g.x:g.y);this.getModel().beginUpdate();try{for(var p=(b-d)/(f.length-1),b=d,e=1;e<f.length-1;e++){var n=this.view.getState(this.model.getParent(f[e].cell)),u=this.getCellGeometry(f[e].cell),b=b+p;null!=u&&null!=n&&(u=u.clone(),a?u.x=Math.round(b-u.width/2)-n.origin.x:u.y=Math.round(b-u.height/2)-n.origin.y,this.getModel().setGeometry(f[e].cell,u))}}finally{this.getModel().endUpdate()}}}return c};Graph.prototype.isCloneEvent=
+function(a){return mxClient.IS_MAC&&mxEvent.isMetaDown(a)||mxEvent.isControlDown(a)};Graph.prototype.createSvgImageExport=function(){var a=new mxImageExport;a.getLinkForCellState=mxUtils.bind(this,function(a,c){return this.getLinkForCell(a.cell)});return a};Graph.prototype.getSvg=function(a,c,f,b,d,e,g,m,p,n){var u=this.useCssTransforms;u&&(this.useCssTransforms=!1,this.view.revalidate(),this.sizeDidChange());try{c=null!=c?c:1;f=null!=f?f:0;d=null!=d?d:!0;e=null!=e?e:!0;g=null!=g?g:!0;var y=e||b?
+this.getGraphBounds():this.getBoundingBox(this.getSelectionCells());if(null==y)throw Error(mxResources.get("drawingEmpty"));var t=this.view.scale,z=mxUtils.createXmlDocument(),l=null!=z.createElementNS?z.createElementNS(mxConstants.NS_SVG,"svg"):z.createElement("svg");null!=a&&(null!=l.style?l.style.backgroundColor=a:l.setAttribute("style","background-color:"+a));null==z.createElementNS?(l.setAttribute("xmlns",mxConstants.NS_SVG),l.setAttribute("xmlns:xlink",mxConstants.NS_XLINK)):l.setAttributeNS("http://www.w3.org/2000/xmlns/",
+"xmlns:xlink",mxConstants.NS_XLINK);a=c/t;var k=Math.max(1,Math.ceil(y.width*a)+2*f)+(n?5:0),v=Math.max(1,Math.ceil(y.height*a)+2*f)+(n?5:0);l.setAttribute("version","1.1");l.setAttribute("width",k+"px");l.setAttribute("height",v+"px");l.setAttribute("viewBox",(d?"-0.5 -0.5":"0 0")+" "+k+" "+v);z.appendChild(l);var K=null!=z.createElementNS?z.createElementNS(mxConstants.NS_SVG,"g"):z.createElement("g");l.appendChild(K);var L=this.createSvgCanvas(K);L.foOffset=d?-.5:0;L.textOffset=d?-.5:0;L.imageOffset=
+d?-.5:0;L.translate(Math.floor((f/c-y.x)/t),Math.floor((f/c-y.y)/t));var q=document.createElement("div"),x=L.getAlternateText;L.getAlternateText=function(a,c,f,b,d,e,g,m,p,n,u,y,t){if(null!=e&&0<this.state.fontSize)try{mxUtils.isNode(e)?e=e.innerText:(q.innerHTML=e,e=mxUtils.extractTextWithWhitespace(q.childNodes));for(var z=Math.ceil(2*b/this.state.fontSize),da=[],Ja=0,l=0;(0==z||Ja<z)&&l<e.length;){var Ka=e.charCodeAt(l);if(10==Ka||13==Ka){if(0<Ja)break}else da.push(e.charAt(l)),255>Ka&&Ja++;l++}da.length<
+e.length&&1<e.length-da.length&&(e=mxUtils.trim(da.join(""))+"...");return e}catch(Ua){return x.apply(this,arguments)}else return x.apply(this,arguments)};var O=this.backgroundImage;if(null!=O){c=t/c;var I=this.view.translate,A=new mxRectangle(I.x*c,I.y*c,O.width*c,O.height*c);mxUtils.intersects(y,A)&&L.image(I.x,I.y,O.width,O.height,O.src,!0)}L.scale(a);L.textEnabled=g;m=null!=m?m:this.createSvgImageExport();var B=m.drawCellState,Y=m.getLinkForCellState;m.getLinkForCellState=function(a,c){var f=
+Y.apply(this,arguments);return null==f||a.view.graph.isCustomLink(f)?null:f};m.drawCellState=function(a,c){for(var f=a.view.graph,b=f.isCellSelected(a.cell),d=f.model.getParent(a.cell);!e&&!b&&null!=d;)b=f.isCellSelected(d),d=f.model.getParent(d);(e||b)&&B.apply(this,arguments)};m.drawState(this.getView().getState(this.model.root),L);this.updateSvgLinks(l,p,!0);this.addForeignObjectWarning(L,l);return l}finally{u&&(this.useCssTransforms=!0,this.view.revalidate(),this.sizeDidChange())}};Graph.prototype.addForeignObjectWarning=
function(a,c){if(0<c.getElementsByTagName("foreignObject").length){var f=a.createElement("switch"),b=a.createElement("g");b.setAttribute("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility");var d=a.createElement("a");d.setAttribute("transform","translate(0,-5)");null==d.setAttributeNS||c.ownerDocument!=document&&null==document.documentMode?(d.setAttribute("xlink:href",Graph.foreignObjectWarningLink),d.setAttribute("target","_blank")):(d.setAttributeNS(mxConstants.NS_XLINK,"xlink:href",
Graph.foreignObjectWarningLink),d.setAttributeNS(mxConstants.NS_XLINK,"target","_blank"));var e=a.createElement("text");e.setAttribute("text-anchor","middle");e.setAttribute("font-size","10px");e.setAttribute("x","50%");e.setAttribute("y","100%");mxUtils.write(e,Graph.foreignObjectWarningText);f.appendChild(b);d.appendChild(e);f.appendChild(d);c.appendChild(f)}};Graph.prototype.updateSvgLinks=function(a,c,f){a=a.getElementsByTagName("a");for(var b=0;b<a.length;b++){var d=a[b].getAttribute("href");
null==d&&(d=a[b].getAttribute("xlink:href"));null!=d&&(null!=c&&/^https?:\/\//.test(d)?a[b].setAttribute("target",c):f&&this.isCustomLink(d)&&a[b].setAttribute("href","javascript:void(0);"))}};Graph.prototype.createSvgCanvas=function(a){a=new mxSvgCanvas2D(a);a.pointerEvents=!0;return a};Graph.prototype.getSelectedElement=function(){var a=null;if(window.getSelection){var c=window.getSelection();c.getRangeAt&&c.rangeCount&&(a=c.getRangeAt(0).commonAncestorContainer)}else document.selection&&(a=document.selection.createRange().parentElement());
return a};Graph.prototype.getParentByName=function(a,c,f){for(;null!=a&&a.nodeName!=c;){if(a==f)return null;a=a.parentNode}return a};Graph.prototype.getParentByNames=function(a,c,f){for(;null!=a&&!(0<=mxUtils.indexOf(c,a.nodeName));){if(a==f)return null;a=a.parentNode}return a};Graph.prototype.selectNode=function(a){var c=null;if(window.getSelection){if(c=window.getSelection(),c.getRangeAt&&c.rangeCount){var f=document.createRange();f.selectNode(a);c.removeAllRanges();c.addRange(f)}}else(c=document.selection)&&
-"Control"!=c.type&&(a=c.createRange(),a.collapse(!0),f=c.createRange(),f.setEndPoint("StartToStart",a),f.select())};Graph.prototype.insertTableColumn=function(a,c){var f=this.getModel();f.beginUpdate();try{var b=a,d=0;if(this.isTableCell(a))var e=f.getParent(a),b=f.getParent(e),d=e.getIndex(a);else this.isTableRow(a)&&(b=f.getParent(a)),c||(d=f.getChildCount(f.getChildAt(b,0))-1);for(var g=0;g<f.getChildCount(b);g++){var e=f.getChildAt(b,g),l=f.getChildAt(e,d),p=f.cloneCell(l),n=this.getCellGeometry(p);
+"Control"!=c.type&&(a=c.createRange(),a.collapse(!0),f=c.createRange(),f.setEndPoint("StartToStart",a),f.select())};Graph.prototype.insertTableColumn=function(a,c){var f=this.getModel();f.beginUpdate();try{var b=a,d=0;if(this.isTableCell(a))var e=f.getParent(a),b=f.getParent(e),d=e.getIndex(a);else this.isTableRow(a)&&(b=f.getParent(a)),c||(d=f.getChildCount(f.getChildAt(b,0))-1);for(var g=0;g<f.getChildCount(b);g++){var e=f.getChildAt(b,g),m=f.getChildAt(e,d),p=f.cloneCell(m),n=this.getCellGeometry(p);
p.value=null;if(null!=n){n.width=Graph.minTableColumnWidth;var u=this.getCellGeometry(e);null!=u&&(n.height=u.height)}f.add(e,p,d+(c?0:1))}var y=this.getCellGeometry(b);null!=y&&(y=y.clone(),y.width+=Graph.minTableColumnWidth,f.setGeometry(b,y))}finally{f.endUpdate()}};Graph.prototype.insertTableRow=function(a,c){var f=this.getModel();f.beginUpdate();try{var b=a,d=0;if(this.isTableCell(a))var e=f.getParent(a),b=f.getParent(e),d=b.getIndex(e);else this.isTableRow(a)?(b=f.getParent(a),d=b.getIndex(a)):
-c||(d=f.getChildCount(b)-1);e=f.cloneCell(f.getChildAt(b,d));e.value=null;var g=this.getCellGeometry(e);if(null!=g){g.height=Graph.minTableRowHeight;for(var l=0;l<f.getChildCount(e);l++){a=f.getChildAt(e,l);a.value=null;var p=this.getCellGeometry(a);null!=p&&(p.height=g.height)}f.add(b,e,d+(c?0:1));var n=this.getCellGeometry(b);null!=n&&(n=n.clone(),n.height+=g.height,f.setGeometry(b,n))}}finally{f.endUpdate()}};Graph.prototype.deleteTableColumn=function(a){var c=this.getModel();c.beginUpdate();try{var f=
-a,b=0;if(this.isTableCell(a))var d=c.getParent(a),f=c.getParent(d),b=d.getIndex(a);else this.isTableRow(a)?(f=c.getParent(a),b=c.getChildCount(a)-1):this.isTable(a)&&(b=c.getChildCount(c.getChildAt(a,0))-1);for(var e=a=0;e<c.getChildCount(f);e++){var d=c.getChildAt(f,e),g=c.getChildAt(d,b);c.remove(g);var l=this.getCellGeometry(g);null!=l&&(a=Math.max(a,l.width))}var p=this.getCellGeometry(f);null!=p&&(p=p.clone(),p.width-=a,c.setGeometry(f,p))}finally{c.endUpdate()}};Graph.prototype.deleteTableRow=
+c||(d=f.getChildCount(b)-1);e=f.cloneCell(f.getChildAt(b,d));e.value=null;var g=this.getCellGeometry(e);if(null!=g){g.height=Graph.minTableRowHeight;for(var m=0;m<f.getChildCount(e);m++){a=f.getChildAt(e,m);a.value=null;var p=this.getCellGeometry(a);null!=p&&(p.height=g.height)}f.add(b,e,d+(c?0:1));var n=this.getCellGeometry(b);null!=n&&(n=n.clone(),n.height+=g.height,f.setGeometry(b,n))}}finally{f.endUpdate()}};Graph.prototype.deleteTableColumn=function(a){var c=this.getModel();c.beginUpdate();try{var f=
+a,b=0;if(this.isTableCell(a))var d=c.getParent(a),f=c.getParent(d),b=d.getIndex(a);else this.isTableRow(a)?(f=c.getParent(a),b=c.getChildCount(a)-1):this.isTable(a)&&(b=c.getChildCount(c.getChildAt(a,0))-1);for(var e=a=0;e<c.getChildCount(f);e++){var d=c.getChildAt(f,e),g=c.getChildAt(d,b);c.remove(g);var m=this.getCellGeometry(g);null!=m&&(a=Math.max(a,m.width))}var p=this.getCellGeometry(f);null!=p&&(p=p.clone(),p.width-=a,c.setGeometry(f,p))}finally{c.endUpdate()}};Graph.prototype.deleteTableRow=
function(a){var c=this.getModel();c.beginUpdate();try{var f=a;this.isTableCell(a)?f=c.getParent(a):this.isTable(a)&&(f=c.getChildAt(a,c.getChildCount(a)-1));var b=c.getParent(f);c.remove(f);a=0;var d=this.getCellGeometry(f);null!=d&&(a=d.height);var e=this.getCellGeometry(b);null!=e&&(e=e.clone(),e.height-=a,c.setGeometry(b,e))}finally{c.endUpdate()}};Graph.prototype.insertRow=function(a,c){for(var f=a.tBodies[0],b=f.rows[0].cells,d=0,e=0;e<b.length;e++)var g=b[e].getAttribute("colspan"),d=d+(null!=
g?parseInt(g):1);f=f.insertRow(c);for(e=0;e<d;e++)mxUtils.br(f.insertCell(-1));return f.cells[0]};Graph.prototype.deleteRow=function(a,c){a.tBodies[0].deleteRow(c)};Graph.prototype.insertColumn=function(a,c){var f=a.tHead;if(null!=f)for(var b=0;b<f.rows.length;b++){var d=document.createElement("th");f.rows[b].appendChild(d);mxUtils.br(d)}f=a.tBodies[0];for(b=0;b<f.rows.length;b++)d=f.rows[b].insertCell(c),mxUtils.br(d);return f.rows[0].cells[0<=c?c:f.rows[0].cells.length-1]};Graph.prototype.deleteColumn=
function(a,c){if(0<=c)for(var f=a.tBodies[0].rows,b=0;b<f.length;b++)f[b].cells.length>c&&f[b].deleteCell(c)};Graph.prototype.pasteHtmlAtCaret=function(a){var c;if(window.getSelection){if(c=window.getSelection(),c.getRangeAt&&c.rangeCount){c=c.getRangeAt(0);c.deleteContents();var f=document.createElement("div");f.innerHTML=a;a=document.createDocumentFragment();for(var b;b=f.firstChild;)lastNode=a.appendChild(b);c.insertNode(a)}}else(c=document.selection)&&"Control"!=c.type&&c.createRange().pasteHTML(a)};
@@ -2493,12 +2493,12 @@ function(a){f||window.getSelection().containsNode(a,!0)?(a.removeAttribute("alig
return null};mxCellEditor.prototype.restoreSelection=function(a){try{if(a)if(window.getSelection){sel=window.getSelection();sel.removeAllRanges();for(var c=0,f=a.length;c<f;++c)sel.addRange(a[c])}else document.selection&&a.select&&a.select()}catch(ja){}};var f=mxCellRenderer.prototype.initializeLabel;mxCellRenderer.prototype.initializeLabel=function(a){null!=a.text&&(a.text.replaceLinefeeds="0"!=mxUtils.getValue(a.style,"nl2Br","1"));f.apply(this,arguments)};var g=mxConstraintHandler.prototype.update;
mxConstraintHandler.prototype.update=function(a,c){this.isKeepFocusEvent(a)||!mxEvent.isAltDown(a.getEvent())?g.apply(this,arguments):this.reset()};mxGuide.prototype.createGuideShape=function(a){return new mxPolyline([],mxConstants.GUIDE_COLOR,mxConstants.GUIDE_STROKEWIDTH)};mxCellEditor.prototype.escapeCancelsEditing=!1;var p=mxCellEditor.prototype.startEditing;mxCellEditor.prototype.startEditing=function(a,c){p.apply(this,arguments);var f=this.graph.view.getState(a);this.textarea.className=null!=
f&&1==f.style.html?"mxCellEditor geContentEditable":"mxCellEditor mxPlainTextEditor";this.codeViewMode=!1;this.switchSelectionState=null;this.graph.setSelectionCell(a);var f=this.graph.getModel().getParent(a),b=this.graph.getCellGeometry(a);this.graph.getModel().isEdge(f)&&null!=b&&b.relative||this.graph.getModel().isEdge(a)?mxClient.IS_QUIRKS?this.textarea.style.border="gray dotted 1px":this.textarea.style.outline=mxClient.IS_IE||mxClient.IS_IE11||mxClient.IS_FF&&mxClient.IS_WIN?"gray dotted 1px":
-"":mxClient.IS_QUIRKS&&(this.textarea.style.outline="none",this.textarea.style.border="")};var l=mxCellEditor.prototype.installListeners;mxCellEditor.prototype.installListeners=function(a){function c(a,f){f.originalNode=a;a=a.firstChild;for(var b=f.firstChild;null!=a&&null!=b;)c(a,b),a=a.nextSibling,b=b.nextSibling;return f}function f(a,c){if(null!=a)if(c.originalNode!=a)b(a);else for(a=a.firstChild,c=c.firstChild;null!=a;){var d=a.nextSibling;null==c?b(a):(f(a,c),c=c.nextSibling);a=d}}function b(a){for(var c=
-a.firstChild;null!=c;){var f=c.nextSibling;b(c);c=f}1==a.nodeType&&("BR"===a.nodeName||null!=a.firstChild)||3==a.nodeType&&0!=mxUtils.trim(mxUtils.getTextContent(a)).length?(3==a.nodeType&&mxUtils.setTextContent(a,mxUtils.getTextContent(a).replace(/\n|\r/g,"")),1==a.nodeType&&(a.removeAttribute("style"),a.removeAttribute("class"),a.removeAttribute("width"),a.removeAttribute("cellpadding"),a.removeAttribute("cellspacing"),a.removeAttribute("border"))):a.parentNode.removeChild(a)}l.apply(this,arguments);
+"":mxClient.IS_QUIRKS&&(this.textarea.style.outline="none",this.textarea.style.border="")};var m=mxCellEditor.prototype.installListeners;mxCellEditor.prototype.installListeners=function(a){function c(a,f){f.originalNode=a;a=a.firstChild;for(var b=f.firstChild;null!=a&&null!=b;)c(a,b),a=a.nextSibling,b=b.nextSibling;return f}function f(a,c){if(null!=a)if(c.originalNode!=a)b(a);else for(a=a.firstChild,c=c.firstChild;null!=a;){var d=a.nextSibling;null==c?b(a):(f(a,c),c=c.nextSibling);a=d}}function b(a){for(var c=
+a.firstChild;null!=c;){var f=c.nextSibling;b(c);c=f}1==a.nodeType&&("BR"===a.nodeName||null!=a.firstChild)||3==a.nodeType&&0!=mxUtils.trim(mxUtils.getTextContent(a)).length?(3==a.nodeType&&mxUtils.setTextContent(a,mxUtils.getTextContent(a).replace(/\n|\r/g,"")),1==a.nodeType&&(a.removeAttribute("style"),a.removeAttribute("class"),a.removeAttribute("width"),a.removeAttribute("cellpadding"),a.removeAttribute("cellspacing"),a.removeAttribute("border"))):a.parentNode.removeChild(a)}m.apply(this,arguments);
mxClient.IS_QUIRKS||7===document.documentMode||8===document.documentMode||mxEvent.addListener(this.textarea,"paste",mxUtils.bind(this,function(a){var b=c(this.textarea,this.textarea.cloneNode(!0));window.setTimeout(mxUtils.bind(this,function(){null!=this.textarea&&(0<=this.textarea.innerHTML.indexOf("<o:OfficeDocumentSettings>")||0<=this.textarea.innerHTML.indexOf("\x3c!--[if !mso]>")?f(this.textarea,b):Graph.removePasteFormatting(this.textarea))}),0)}))};mxCellEditor.prototype.toggleViewMode=function(){var a=
this.graph.view.getState(this.editingCell);if(null!=a){var c=null!=a&&"0"!=mxUtils.getValue(a.style,"nl2Br","1"),f=this.saveSelection();if(this.codeViewMode){p=mxUtils.extractTextWithWhitespace(this.textarea.childNodes);0<p.length&&"\n"==p.charAt(p.length-1)&&(p=p.substring(0,p.length-1));p=this.graph.sanitizeHtml(c?p.replace(/\n/g,"<br/>"):p,!0);this.textarea.className="mxCellEditor geContentEditable";var b=mxUtils.getValue(a.style,mxConstants.STYLE_FONTSIZE,mxConstants.DEFAULT_FONTSIZE),c=mxUtils.getValue(a.style,
-mxConstants.STYLE_FONTFAMILY,mxConstants.DEFAULT_FONTFAMILY),d=mxUtils.getValue(a.style,mxConstants.STYLE_ALIGN,mxConstants.ALIGN_LEFT),e=(mxUtils.getValue(a.style,mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD,g=(mxUtils.getValue(a.style,mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC,l=[];(mxUtils.getValue(a.style,mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&l.push("underline");(mxUtils.getValue(a.style,
-mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_STRIKETHROUGH)==mxConstants.FONT_STRIKETHROUGH&&l.push("line-through");this.textarea.style.lineHeight=mxConstants.ABSOLUTE_LINE_HEIGHT?Math.round(b*mxConstants.LINE_HEIGHT)+"px":mxConstants.LINE_HEIGHT;this.textarea.style.fontSize=Math.round(b)+"px";this.textarea.style.textDecoration=l.join(" ");this.textarea.style.fontWeight=e?"bold":"normal";this.textarea.style.fontStyle=g?"italic":"";this.textarea.style.fontFamily=c;this.textarea.style.textAlign=
+mxConstants.STYLE_FONTFAMILY,mxConstants.DEFAULT_FONTFAMILY),d=mxUtils.getValue(a.style,mxConstants.STYLE_ALIGN,mxConstants.ALIGN_LEFT),e=(mxUtils.getValue(a.style,mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD,g=(mxUtils.getValue(a.style,mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC,m=[];(mxUtils.getValue(a.style,mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&m.push("underline");(mxUtils.getValue(a.style,
+mxConstants.STYLE_FONTSTYLE,0)&mxConstants.FONT_STRIKETHROUGH)==mxConstants.FONT_STRIKETHROUGH&&m.push("line-through");this.textarea.style.lineHeight=mxConstants.ABSOLUTE_LINE_HEIGHT?Math.round(b*mxConstants.LINE_HEIGHT)+"px":mxConstants.LINE_HEIGHT;this.textarea.style.fontSize=Math.round(b)+"px";this.textarea.style.textDecoration=m.join(" ");this.textarea.style.fontWeight=e?"bold":"normal";this.textarea.style.fontStyle=g?"italic":"";this.textarea.style.fontFamily=c;this.textarea.style.textAlign=
d;this.textarea.style.padding="0px";this.textarea.innerHTML!=p&&(this.textarea.innerHTML=p,0==this.textarea.innerHTML.length&&(this.textarea.innerHTML=this.getEmptyLabelText(),this.clearOnChange=0<this.textarea.innerHTML.length));this.codeViewMode=!1}else{this.clearOnChange&&this.textarea.innerHTML==this.getEmptyLabelText()&&(this.clearOnChange=!1,this.textarea.innerHTML="");var p=mxUtils.htmlEntities(this.textarea.innerHTML);mxClient.IS_QUIRKS||8==document.documentMode||(p=mxUtils.replaceTrailingNewlines(p,
"<div><br></div>"));p=this.graph.sanitizeHtml(c?p.replace(/\n/g,"").replace(/&lt;br\s*.?&gt;/g,"<br>"):p,!0);this.textarea.className="mxCellEditor mxPlainTextEditor";var b=mxConstants.DEFAULT_FONTSIZE;this.textarea.style.lineHeight=mxConstants.ABSOLUTE_LINE_HEIGHT?Math.round(b*mxConstants.LINE_HEIGHT)+"px":mxConstants.LINE_HEIGHT;this.textarea.style.fontSize=Math.round(b)+"px";this.textarea.style.textDecoration="";this.textarea.style.fontWeight="normal";this.textarea.style.fontStyle="";this.textarea.style.fontFamily=
mxConstants.DEFAULT_FONTFAMILY;this.textarea.style.textAlign="left";this.textarea.style.padding="2px";this.textarea.innerHTML!=p&&(this.textarea.innerHTML=p);this.codeViewMode=!0}this.textarea.focus();null!=this.switchSelectionState&&this.restoreSelection(this.switchSelectionState);this.switchSelectionState=f;this.resize()}};var n=mxCellEditor.prototype.resize;mxCellEditor.prototype.resize=function(a,c){if(null!=this.textarea)if(a=this.graph.getView().getState(this.editingCell),this.codeViewMode&&
@@ -2539,8 +2539,8 @@ function(a){return!mxEvent.isShiftDown(a.getEvent())};if(Graph.touchStyle){if(mx
function(a){var c=a.getEvent();return null==a.getState()&&!mxEvent.isMouseEvent(c)||mxEvent.isPopupTrigger(c)&&(null==a.getState()||mxEvent.isControlDown(c)||mxEvent.isShiftDown(c))};var K=mxGraphHandler.prototype.mouseDown;mxGraphHandler.prototype.mouseDown=function(a,c){K.apply(this,arguments);mxEvent.isTouchEvent(c.getEvent())&&this.graph.isCellSelected(c.getCell())&&1<this.graph.getSelectionCount()&&(this.delayedSelection=!1)}}else mxPanningHandler.prototype.isPanningTrigger=function(a){var c=
a.getEvent();return mxEvent.isLeftMouseButton(c)&&(this.useLeftButtonForPanning&&null==a.getState()||mxEvent.isControlDown(c)&&!mxEvent.isShiftDown(c))||this.usePopupTrigger&&mxEvent.isPopupTrigger(c)};mxRubberband.prototype.isSpaceEvent=function(a){return this.graph.isEnabled()&&!this.graph.isCellLocked(this.graph.getDefaultParent())&&mxEvent.isControlDown(a.getEvent())&&mxEvent.isShiftDown(a.getEvent())};mxRubberband.prototype.cancelled=!1;mxRubberband.prototype.cancel=function(){this.isActive()&&
(this.cancelled=!0,this.reset())};mxRubberband.prototype.mouseUp=function(a,c){if(this.cancelled)this.cancelled=!1,c.consume();else{var f=null!=this.div&&"none"!=this.div.style.display,b=null,d=null,e=null,g=null;null!=this.first&&null!=this.currentX&&null!=this.currentY&&(b=this.first.x,d=this.first.y,e=(this.currentX-b)/this.graph.view.scale,g=(this.currentY-d)/this.graph.view.scale,mxEvent.isAltDown(c.getEvent())||(e=this.graph.snap(e),g=this.graph.snap(g),this.graph.isGridEnabled()||(Math.abs(e)<
-this.graph.tolerance&&(e=0),Math.abs(g)<this.graph.tolerance&&(g=0))));this.reset();if(f){if(mxEvent.isAltDown(c.getEvent())&&this.graph.isToggleEvent(c.getEvent())){var e=new mxRectangle(this.x,this.y,this.width,this.height),l=this.graph.getCells(e.x,e.y,e.width,e.height);this.graph.removeSelectionCells(l)}else if(this.isSpaceEvent(c)){this.graph.model.beginUpdate();try{for(l=this.graph.getCellsBeyond(b,d,this.graph.getDefaultParent(),!0,!0),f=0;f<l.length;f++)if(this.graph.isCellMovable(l[f])){var p=
-this.graph.view.getState(l[f]),n=this.graph.getCellGeometry(l[f]);null!=p&&null!=n&&(n=n.clone(),n.translate(e,g),this.graph.model.setGeometry(l[f],n))}}finally{this.graph.model.endUpdate()}}else e=new mxRectangle(this.x,this.y,this.width,this.height),this.graph.selectRegion(e,c.getEvent());c.consume()}}};mxRubberband.prototype.mouseMove=function(a,c){if(!c.isConsumed()&&null!=this.first){var f=mxUtils.getScrollOrigin(this.graph.container),b=mxUtils.getOffset(this.graph.container);f.x-=b.x;f.y-=b.y;
+this.graph.tolerance&&(e=0),Math.abs(g)<this.graph.tolerance&&(g=0))));this.reset();if(f){if(mxEvent.isAltDown(c.getEvent())&&this.graph.isToggleEvent(c.getEvent())){var e=new mxRectangle(this.x,this.y,this.width,this.height),m=this.graph.getCells(e.x,e.y,e.width,e.height);this.graph.removeSelectionCells(m)}else if(this.isSpaceEvent(c)){this.graph.model.beginUpdate();try{for(m=this.graph.getCellsBeyond(b,d,this.graph.getDefaultParent(),!0,!0),f=0;f<m.length;f++)if(this.graph.isCellMovable(m[f])){var p=
+this.graph.view.getState(m[f]),n=this.graph.getCellGeometry(m[f]);null!=p&&null!=n&&(n=n.clone(),n.translate(e,g),this.graph.model.setGeometry(m[f],n))}}finally{this.graph.model.endUpdate()}}else e=new mxRectangle(this.x,this.y,this.width,this.height),this.graph.selectRegion(e,c.getEvent());c.consume()}}};mxRubberband.prototype.mouseMove=function(a,c){if(!c.isConsumed()&&null!=this.first){var f=mxUtils.getScrollOrigin(this.graph.container),b=mxUtils.getOffset(this.graph.container);f.x-=b.x;f.y-=b.y;
var b=c.getX()+f.x,f=c.getY()+f.y,d=this.first.x-b,e=this.first.y-f,g=this.graph.tolerance;if(null!=this.div||Math.abs(d)>g||Math.abs(e)>g)null==this.div&&(this.div=this.createShape()),mxUtils.clearSelection(),this.update(b,f),this.isSpaceEvent(c)?(b=this.x+this.width,f=this.y+this.height,d=this.graph.view.scale,mxEvent.isAltDown(c.getEvent())||(this.width=this.graph.snap(this.width/d)*d,this.height=this.graph.snap(this.height/d)*d,this.graph.isGridEnabled()||(this.width<this.graph.tolerance&&(this.width=
0),this.height<this.graph.tolerance&&(this.height=0)),this.x<this.first.x&&(this.x=b-this.width),this.y<this.first.y&&(this.y=f-this.height)),this.div.style.borderStyle="dashed",this.div.style.backgroundColor="white",this.div.style.left=this.x+"px",this.div.style.top=this.y+"px",this.div.style.width=Math.max(0,this.width)+"px",this.div.style.height=this.graph.container.clientHeight+"px",this.div.style.borderWidth=0>=this.width?"0px 1px 0px 0px":"0px 1px 0px 1px",null==this.secondDiv&&(this.secondDiv=
this.div.cloneNode(!0),this.div.parentNode.appendChild(this.secondDiv)),this.secondDiv.style.left=this.x+"px",this.secondDiv.style.top=this.y+"px",this.secondDiv.style.width=this.graph.container.clientWidth+"px",this.secondDiv.style.height=Math.max(0,this.height)+"px",this.secondDiv.style.borderWidth=0>=this.height?"1px 0px 0px 0px":"1px 0px 1px 0px"):(this.div.style.backgroundColor="",this.div.style.borderWidth="",this.div.style.borderStyle="",null!=this.secondDiv&&(this.secondDiv.parentNode.removeChild(this.secondDiv),
@@ -2568,12 +2568,12 @@ this.state.y-22,this.state.width+24,this.state.height+22),f=mxUtils.getBoundingB
this.verticalOffset/2+Editor.hintOffset)+"px"}};var M=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=function(){M.apply(this,arguments);if(null!=this.moveHandles){for(var a=0;a<this.moveHandles.length;a++)this.moveHandles[a].parentNode.removeChild(this.moveHandles[a]);this.moveHandles=null}null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.changeHandler&&(this.graph.getSelectionModel().removeListener(this.changeHandler),this.graph.getModel().removeListener(this.changeHandler),
this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var ca=mxEdgeHandler.prototype.redrawHandles;mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(ca.apply(this),null!=this.state&&null!=this.linkHint)){var a=this.state;null!=this.state.text&&null!=this.state.text.bounds&&(a=new mxRectangle(a.x,a.y,a.width,a.height),a.add(this.state.text.bounds));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-
this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(a.y+a.height+Editor.hintOffset)+"px"}};var P=mxEdgeHandler.prototype.reset;mxEdgeHandler.prototype.reset=function(){P.apply(this,arguments);null!=this.linkHint&&(this.linkHint.style.visibility="")};var aa=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){aa.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),
-this.graph.getSelectionModel().removeListener(this.changeHandler),this.changeHandler=null)}}();(function(){function a(){mxCylinder.call(this)}function b(){mxActor.call(this)}function e(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function k(){mxCylinder.call(this)}function m(){mxActor.call(this)}function q(){mxCylinder.call(this)}function c(){mxActor.call(this)}function f(){mxActor.call(this)}function g(){mxActor.call(this)}function p(){mxActor.call(this)}function l(){mxActor.call(this)}function n(){mxActor.call(this)}function v(){mxActor.call(this)}function t(a,c){this.canvas=
+this.graph.getSelectionModel().removeListener(this.changeHandler),this.changeHandler=null)}}();(function(){function a(){mxCylinder.call(this)}function b(){mxActor.call(this)}function e(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function k(){mxCylinder.call(this)}function l(){mxActor.call(this)}function q(){mxCylinder.call(this)}function c(){mxActor.call(this)}function f(){mxActor.call(this)}function g(){mxActor.call(this)}function p(){mxActor.call(this)}function m(){mxActor.call(this)}function n(){mxActor.call(this)}function v(){mxActor.call(this)}function t(a,c){this.canvas=
a;this.canvas.setLineJoin("round");this.canvas.setLineCap("round");this.defaultVariation=c;this.originalLineTo=this.canvas.lineTo;this.canvas.lineTo=mxUtils.bind(this,t.prototype.lineTo);this.originalMoveTo=this.canvas.moveTo;this.canvas.moveTo=mxUtils.bind(this,t.prototype.moveTo);this.originalClose=this.canvas.close;this.canvas.close=mxUtils.bind(this,t.prototype.close);this.originalQuadTo=this.canvas.quadTo;this.canvas.quadTo=mxUtils.bind(this,t.prototype.quadTo);this.originalCurveTo=this.canvas.curveTo;
this.canvas.curveTo=mxUtils.bind(this,t.prototype.curveTo);this.originalArcTo=this.canvas.arcTo;this.canvas.arcTo=mxUtils.bind(this,t.prototype.arcTo)}function u(){mxRectangleShape.call(this)}function A(){mxRectangleShape.call(this)}function B(){mxActor.call(this)}function D(){mxActor.call(this)}function C(){mxActor.call(this)}function x(){mxRectangleShape.call(this)}function F(){mxRectangleShape.call(this)}function G(){mxCylinder.call(this)}function E(){mxShape.call(this)}function J(){mxShape.call(this)}
function H(){mxEllipse.call(this)}function y(){mxShape.call(this)}function K(){mxShape.call(this)}function z(){mxRectangleShape.call(this)}function L(){mxShape.call(this)}function O(){mxShape.call(this)}function I(){mxShape.call(this)}function U(){mxShape.call(this)}function ea(){mxShape.call(this)}function ba(){mxCylinder.call(this)}function ha(){mxCylinder.call(this)}function fa(){mxRectangleShape.call(this)}function S(){mxDoubleEllipse.call(this)}function X(){mxDoubleEllipse.call(this)}function Z(){mxArrowConnector.call(this);
this.spacing=0}function ia(){mxArrowConnector.call(this);this.spacing=0}function V(){mxActor.call(this)}function T(){mxRectangleShape.call(this)}function Q(){mxActor.call(this)}function M(){mxActor.call(this)}function ca(){mxActor.call(this)}function P(){mxActor.call(this)}function aa(){mxActor.call(this)}function Y(){mxActor.call(this)}function za(){mxActor.call(this)}function N(){mxActor.call(this)}function ja(){mxActor.call(this)}function W(){mxActor.call(this)}function ga(){mxEllipse.call(this)}
-function ma(){mxEllipse.call(this)}function ta(){mxEllipse.call(this)}function ka(){mxRhombus.call(this)}function pa(){mxEllipse.call(this)}function oa(){mxEllipse.call(this)}function Aa(){mxEllipse.call(this)}function ua(){mxEllipse.call(this)}function qa(){mxActor.call(this)}function ra(){mxActor.call(this)}function sa(){mxActor.call(this)}function na(){mxConnector.call(this)}function Da(a,c,f,b,d,e,g,l,p,n){g+=p;var da=b.clone();b.x-=d*(2*g+p);b.y-=e*(2*g+p);d*=g+p;e*=g+p;return function(){a.ellipse(da.x-
+function ma(){mxEllipse.call(this)}function ta(){mxEllipse.call(this)}function ka(){mxRhombus.call(this)}function pa(){mxEllipse.call(this)}function oa(){mxEllipse.call(this)}function Aa(){mxEllipse.call(this)}function ua(){mxEllipse.call(this)}function qa(){mxActor.call(this)}function ra(){mxActor.call(this)}function sa(){mxActor.call(this)}function na(){mxConnector.call(this)}function Da(a,c,f,b,d,e,g,m,p,n){g+=p;var da=b.clone();b.x-=d*(2*g+p);b.y-=e*(2*g+p);d*=g+p;e*=g+p;return function(){a.ellipse(da.x-
d-g,da.y-e-g,2*g,2*g);n?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,mxCylinder);a.prototype.size=20;a.prototype.darkOpacity=0;a.prototype.darkOpacity2=0;a.prototype.paintVertexShape=function(a,c,f,b,d){var e=Math.max(0,Math.min(b,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.size))))),g=Math.max(-1,Math.min(1,parseFloat(mxUtils.getValue(this.style,"darkOpacity",this.darkOpacity)))),da=Math.max(-1,Math.min(1,parseFloat(mxUtils.getValue(this.style,"darkOpacity2",this.darkOpacity2))));
a.translate(c,f);a.begin();a.moveTo(0,0);a.lineTo(b-e,0);a.lineTo(b,e);a.lineTo(b,d);a.lineTo(e,d);a.lineTo(0,d-e);a.lineTo(0,0);a.close();a.end();a.fillAndStroke();this.outline||(a.setShadow(!1),0!=g&&(a.setFillAlpha(Math.abs(g)),a.setFillColor(0>g?"#FFFFFF":"#000000"),a.begin(),a.moveTo(0,0),a.lineTo(b-e,0),a.lineTo(b,e),a.lineTo(e,e),a.close(),a.fill()),0!=da&&(a.setFillAlpha(Math.abs(da)),a.setFillColor(0>da?"#FFFFFF":"#000000"),a.begin(),a.moveTo(0,0),a.lineTo(e,e),a.lineTo(e,d),a.lineTo(0,d-
e),a.close(),a.fill()),a.begin(),a.moveTo(e,d),a.lineTo(e,e),a.lineTo(0,0),a.moveTo(e,e),a.lineTo(b,e),a.end(),a.stroke())};a.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?(a=parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale,new mxRectangle(a,a,0,0)):null};mxCellRenderer.registerShape("cube",a);var wa=Math.tan(mxUtils.toRadians(30)),la=(.5-wa)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,c,f,b,d){c=
@@ -2581,19 +2581,19 @@ Math.min(b,d/wa);a.translate((b-c)/2,(d-c)/2+c/4);a.moveTo(0,.25*c);a.lineTo(.5*
c,c*la),a.lineTo(c,.25*c),a.lineTo(c,.75*c),a.lineTo(.5*c,(1-la)*c),a.lineTo(0,.75*c),a.close());a.end()};mxCellRenderer.registerShape("isoCube",e);mxUtils.extend(d,mxCylinder);d.prototype.redrawPath=function(a,c,f,b,d,e){c=Math.min(d/2,Math.round(d/8)+this.strokewidth-1);if(e&&null!=this.fill||!e&&null==this.fill)a.moveTo(0,c),a.curveTo(0,2*c,b,2*c,b,c),e||(a.stroke(),a.begin()),a.translate(0,c/2),a.moveTo(0,c),a.curveTo(0,2*c,b,2*c,b,c),e||(a.stroke(),a.begin()),a.translate(0,c/2),a.moveTo(0,c),
a.curveTo(0,2*c,b,2*c,b,c),e||(a.stroke(),a.begin()),a.translate(0,-c);e||(a.moveTo(0,c),a.curveTo(0,-c/3,b,-c/3,b,c),a.lineTo(b,d-c),a.curveTo(b,d+c/3,0,d+c/3,0,d-c),a.close())};d.prototype.getLabelMargins=function(a){return new mxRectangle(0,2.5*Math.min(a.height/2,Math.round(a.height/8)+this.strokewidth-1),0,0)};mxCellRenderer.registerShape("datastore",d);mxUtils.extend(k,mxCylinder);k.prototype.size=30;k.prototype.darkOpacity=0;k.prototype.paintVertexShape=function(a,c,f,b,d){var e=Math.max(0,
Math.min(b,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.size))))),g=Math.max(-1,Math.min(1,parseFloat(mxUtils.getValue(this.style,"darkOpacity",this.darkOpacity))));a.translate(c,f);a.begin();a.moveTo(0,0);a.lineTo(b-e,0);a.lineTo(b,e);a.lineTo(b,d);a.lineTo(0,d);a.lineTo(0,0);a.close();a.end();a.fillAndStroke();this.outline||(a.setShadow(!1),0!=g&&(a.setFillAlpha(Math.abs(g)),a.setFillColor(0>g?"#FFFFFF":"#000000"),a.begin(),a.moveTo(b-e,0),a.lineTo(b-e,e),a.lineTo(b,e),a.close(),
-a.fill()),a.begin(),a.moveTo(b-e,0),a.lineTo(b-e,e),a.lineTo(b,e),a.end(),a.stroke())};mxCellRenderer.registerShape("note",k);mxUtils.extend(m,mxActor);m.prototype.redrawPath=function(a,c,f,b,d){a.moveTo(0,0);a.quadTo(b/2,.5*d,b,0);a.quadTo(.5*b,d/2,b,d);a.quadTo(b/2,.5*d,0,d);a.quadTo(.5*b,d/2,0,0);a.end()};mxCellRenderer.registerShape("switch",m);mxUtils.extend(q,mxCylinder);q.prototype.tabWidth=60;q.prototype.tabHeight=20;q.prototype.tabPosition="right";q.prototype.redrawPath=function(a,c,f,b,
+a.fill()),a.begin(),a.moveTo(b-e,0),a.lineTo(b-e,e),a.lineTo(b,e),a.end(),a.stroke())};mxCellRenderer.registerShape("note",k);mxUtils.extend(l,mxActor);l.prototype.redrawPath=function(a,c,f,b,d){a.moveTo(0,0);a.quadTo(b/2,.5*d,b,0);a.quadTo(.5*b,d/2,b,d);a.quadTo(b/2,.5*d,0,d);a.quadTo(.5*b,d/2,0,0);a.end()};mxCellRenderer.registerShape("switch",l);mxUtils.extend(q,mxCylinder);q.prototype.tabWidth=60;q.prototype.tabHeight=20;q.prototype.tabPosition="right";q.prototype.redrawPath=function(a,c,f,b,
d,e){c=Math.max(0,Math.min(b,parseFloat(mxUtils.getValue(this.style,"tabWidth",this.tabWidth))));f=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"tabHeight",this.tabHeight))));var g=mxUtils.getValue(this.style,"tabPosition",this.tabPosition);e?"left"==g?(a.moveTo(0,f),a.lineTo(c,f)):(a.moveTo(b-c,f),a.lineTo(b,f)):("left"==g?(a.moveTo(0,0),a.lineTo(c,0),a.lineTo(c,f),a.lineTo(b,f)):(a.moveTo(0,f),a.lineTo(b-c,f),a.lineTo(b-c,0),a.lineTo(b,0)),a.lineTo(b,d),a.lineTo(0,d),a.lineTo(0,
f),a.close());a.end()};mxCellRenderer.registerShape("folder",q);mxUtils.extend(c,mxActor);c.prototype.size=30;c.prototype.isRoundable=function(){return!0};c.prototype.redrawPath=function(a,c,f,b,d){c=Math.max(0,Math.min(b,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(c,0),new mxPoint(b,0),new mxPoint(b,d),new mxPoint(0,d),new mxPoint(0,c)],this.isRounded,f,!0);
a.end()};mxCellRenderer.registerShape("card",c);mxUtils.extend(f,mxActor);f.prototype.size=.4;f.prototype.redrawPath=function(a,c,f,b,d){c=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,c/2);a.quadTo(b/4,1.4*c,b/2,c/2);a.quadTo(3*b/4,c*(1-1.4),b,c/2);a.lineTo(b,d-c/2);a.quadTo(3*b/4,d-1.4*c,b/2,d-c/2);a.quadTo(b/4,d-c*(1-1.4),0,d-c/2);a.lineTo(0,c/2);a.close();a.end()};f.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.style,"boundedLbl",
!1)){var c=mxUtils.getValue(this.style,"size",this.size),f=a.width,b=a.height;if(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)return c*=b,new mxRectangle(a.x,a.y+c,f,b-2*c);c*=f;return new mxRectangle(a.x+c,a.y,f-2*c,b)}return a};mxCellRenderer.registerShape("tape",f);mxUtils.extend(g,mxActor);g.prototype.size=.3;g.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,
"size",this.size))*a.height):null};g.prototype.redrawPath=function(a,c,f,b,d){c=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,0);a.lineTo(b,0);a.lineTo(b,d-c/2);a.quadTo(3*b/4,d-1.4*c,b/2,d-c/2);a.quadTo(b/4,d-c*(1-1.4),0,d-c/2);a.lineTo(0,c/2);a.close();a.end()};mxCellRenderer.registerShape("document",g);var ya=mxCylinder.prototype.getCylinderSize;mxCylinder.prototype.getCylinderSize=function(a,c,f,b){var d=mxUtils.getValue(this.style,"size");return null!=
d?b*Math.max(0,Math.min(1,d)):ya.apply(this,arguments)};mxCylinder.prototype.getLabelMargins=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var c=2*mxUtils.getValue(this.style,"size",.15);return new mxRectangle(0,Math.min(this.maxHeight*this.scale,a.height*c),0,0)}return null};mxUtils.extend(p,mxActor);p.prototype.size=.2;p.prototype.isRoundable=function(){return!0};p.prototype.redrawPath=function(a,c,f,b,d){c=b*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));
-f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,d),new mxPoint(c,0),new mxPoint(b,0),new mxPoint(b-c,d)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("parallelogram",p);mxUtils.extend(l,mxActor);l.prototype.size=.2;l.prototype.isRoundable=function(){return!0};l.prototype.redrawPath=function(a,c,f,b,d){c=b*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));f=mxUtils.getValue(this.style,
-mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,d),new mxPoint(c,0),new mxPoint(b-c,0),new mxPoint(b,d)],this.isRounded,f,!0)};mxCellRenderer.registerShape("trapezoid",l);mxUtils.extend(n,mxActor);n.prototype.size=.5;n.prototype.redrawPath=function(a,c,f,b,d){a.setFillColor(null);c=b*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,
+f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,d),new mxPoint(c,0),new mxPoint(b,0),new mxPoint(b-c,d)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("parallelogram",p);mxUtils.extend(m,mxActor);m.prototype.size=.2;m.prototype.isRoundable=function(){return!0};m.prototype.redrawPath=function(a,c,f,b,d){c=b*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));f=mxUtils.getValue(this.style,
+mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,d),new mxPoint(c,0),new mxPoint(b-c,0),new mxPoint(b,d)],this.isRounded,f,!0)};mxCellRenderer.registerShape("trapezoid",m);mxUtils.extend(n,mxActor);n.prototype.size=.5;n.prototype.redrawPath=function(a,c,f,b,d){a.setFillColor(null);c=b*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,
[new mxPoint(b,0),new mxPoint(c,0),new mxPoint(c,d/2),new mxPoint(0,d/2),new mxPoint(c,d/2),new mxPoint(c,d),new mxPoint(b,d)],this.isRounded,f,!1);a.end()};mxCellRenderer.registerShape("curlyBracket",n);mxUtils.extend(v,mxActor);v.prototype.redrawPath=function(a,c,f,b,d){a.setStrokeWidth(1);a.setFillColor(this.stroke);c=b/5;a.rect(0,0,c,d);a.fillAndStroke();a.rect(2*c,0,c,d);a.fillAndStroke();a.rect(4*c,0,c,d);a.fillAndStroke()};mxCellRenderer.registerShape("parallelMarker",v);t.prototype.moveTo=
function(a,c){this.originalMoveTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=c;this.firstX=a;this.firstY=c};t.prototype.close=function(){null!=this.firstX&&null!=this.firstY&&(this.lineTo(this.firstX,this.firstY),this.originalClose.apply(this.canvas,arguments));this.originalClose.apply(this.canvas,arguments)};t.prototype.quadTo=function(a,c,f,b){this.originalQuadTo.apply(this.canvas,arguments);this.lastX=f;this.lastY=b};t.prototype.curveTo=function(a,c,f,b,d,e){this.originalCurveTo.apply(this.canvas,
arguments);this.lastX=d;this.lastY=e};t.prototype.arcTo=function(a,c,f,b,d,e,g){this.originalArcTo.apply(this.canvas,arguments);this.lastX=e;this.lastY=g};t.prototype.lineTo=function(a,c){if(null!=this.lastX&&null!=this.lastY){var f=function(a){return"number"===typeof a?a?0>a?-1:1:a===a?0:NaN:NaN},b=Math.abs(a-this.lastX),d=Math.abs(c-this.lastY),e=Math.sqrt(b*b+d*d);if(2>e){this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=c;return}var g=Math.round(e/10),da=this.defaultVariation;
-5>g&&(g=5,da/=3);for(var l=f(a-this.lastX)*b/g,f=f(c-this.lastY)*d/g,b=b/e,d=d/e,e=0;e<g;e++){var p=(Math.random()-.5)*da;this.originalLineTo.call(this.canvas,l*e+this.lastX-p*d,f*e+this.lastY-p*b)}this.originalLineTo.call(this.canvas,a,c)}else this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=c};t.prototype.destroy=function(){this.canvas.lineTo=this.originalLineTo;this.canvas.moveTo=this.originalMoveTo;this.canvas.close=this.originalClose;this.canvas.quadTo=this.originalQuadTo;
+5>g&&(g=5,da/=3);for(var m=f(a-this.lastX)*b/g,f=f(c-this.lastY)*d/g,b=b/e,d=d/e,e=0;e<g;e++){var p=(Math.random()-.5)*da;this.originalLineTo.call(this.canvas,m*e+this.lastX-p*d,f*e+this.lastY-p*b)}this.originalLineTo.call(this.canvas,a,c)}else this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=c};t.prototype.destroy=function(){this.canvas.lineTo=this.originalLineTo;this.canvas.moveTo=this.originalMoveTo;this.canvas.close=this.originalClose;this.canvas.quadTo=this.originalQuadTo;
this.canvas.curveTo=this.originalCurveTo;this.canvas.arcTo=this.originalArcTo};var La=mxShape.prototype.paint;mxShape.prototype.defaultJiggle=1.5;mxShape.prototype.paint=function(a){null!=this.style&&"0"!=mxUtils.getValue(this.style,"comic","0")&&null==a.handHiggle&&(a.handJiggle=new t(a,mxUtils.getValue(this.style,"jiggle",this.defaultJiggle)));La.apply(this,arguments);null!=a.handJiggle&&(a.handJiggle.destroy(),delete a.handJiggle)};mxRhombus.prototype.defaultJiggle=2;var Ma=mxRectangleShape.prototype.isHtmlAllowed;
mxRectangleShape.prototype.isHtmlAllowed=function(){return(null==this.style||"0"==mxUtils.getValue(this.style,"comic","0"))&&Ma.apply(this,arguments)};var Sa=mxRectangleShape.prototype.paintBackground;mxRectangleShape.prototype.paintBackground=function(a,c,f,b,d){if(null==a.handJiggle)Sa.apply(this,arguments);else{var e=!0;null!=this.style&&(e="1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1"));if(e||null!=this.fill&&this.fill!=mxConstants.NONE||null!=this.stroke&&this.stroke!=
mxConstants.NONE)e||null!=this.fill&&this.fill!=mxConstants.NONE||(a.pointerEvents=!1),a.begin(),this.isRounded?("1"==mxUtils.getValue(this.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?e=Math.min(b/2,Math.min(d/2,mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2)):(e=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,e=Math.min(b*e,d*e)),a.moveTo(c+e,f),a.lineTo(c+b-e,f),a.quadTo(c+b,f,c+b,f+e),a.lineTo(c+b,f+d-e),a.quadTo(c+
@@ -2608,34 +2608,34 @@ parseFloat(mxUtils.getValue(this.style,"base",this.base))));this.addPoints(a,[ne
function(){return!1};x.prototype.paintForeground=function(a,c,f,b,d){var e=Math.min(b/5,d/5)+1;a.begin();a.moveTo(c+b/2,f+e);a.lineTo(c+b/2,f+d-e);a.moveTo(c+e,f+d/2);a.lineTo(c+b-e,f+d/2);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("plus",x);var Pa=mxRhombus.prototype.paintVertexShape;mxRhombus.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var c=(2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||
0))*this.scale;return new mxRectangle(a.x+c,a.y+c,a.width-2*c,a.height-2*c)}return a};mxRhombus.prototype.paintVertexShape=function(a,c,f,b,d){Pa.apply(this,arguments);if(!this.outline&&1==this.style["double"]){var e=2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);c+=e;f+=e;b-=2*e;d-=2*e;0<b&&0<d&&(a.setShadow(!1),Pa.apply(this,[a,c,f,b,d]))}};mxUtils.extend(F,mxRectangleShape);F.prototype.isHtmlAllowed=function(){return!1};F.prototype.getLabelBounds=function(a){if(1==
this.style["double"]){var c=(Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+c,a.y+c,a.width-2*c,a.height-2*c)}return a};F.prototype.paintForeground=function(a,c,f,b,d){if(null!=this.style){if(!this.outline&&1==this.style["double"]){var e=Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);c+=e;f+=e;b-=2*e;d-=2*e;0<b&&0<d&&mxRectangleShape.prototype.paintBackground.apply(this,arguments)}a.setDashed(!1);
-var e=0,g;do{g=mxCellRenderer.defaultShapes[this.style["symbol"+e]];if(null!=g){var l=this.style["symbol"+e+"Align"],da=this.style["symbol"+e+"VerticalAlign"],p=this.style["symbol"+e+"Width"],n=this.style["symbol"+e+"Height"],u=this.style["symbol"+e+"Spacing"]||0,y=this.style["symbol"+e+"VSpacing"]||u,t=this.style["symbol"+e+"ArcSpacing"];null!=t&&(t*=this.getArcSize(b+this.strokewidth,d+this.strokewidth),u+=t,y+=t);var t=c,z=f,t=l==mxConstants.ALIGN_CENTER?t+(b-p)/2:l==mxConstants.ALIGN_RIGHT?t+
-(b-p-u):t+u,z=da==mxConstants.ALIGN_MIDDLE?z+(d-n)/2:da==mxConstants.ALIGN_BOTTOM?z+(d-n-y):z+y;a.save();l=new g;l.style=this.style;g.prototype.paintVertexShape.call(l,a,t,z,p,n);a.restore()}e++}while(null!=g)}mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("ext",F);mxUtils.extend(G,mxCylinder);G.prototype.redrawPath=function(a,c,f,b,d,e){e?(a.moveTo(0,0),a.lineTo(b/2,d/2),a.lineTo(b,0),a.end()):(a.moveTo(0,0),a.lineTo(b,0),a.lineTo(b,d),a.lineTo(0,d),
+var e=0,g;do{g=mxCellRenderer.defaultShapes[this.style["symbol"+e]];if(null!=g){var m=this.style["symbol"+e+"Align"],da=this.style["symbol"+e+"VerticalAlign"],p=this.style["symbol"+e+"Width"],n=this.style["symbol"+e+"Height"],u=this.style["symbol"+e+"Spacing"]||0,y=this.style["symbol"+e+"VSpacing"]||u,t=this.style["symbol"+e+"ArcSpacing"];null!=t&&(t*=this.getArcSize(b+this.strokewidth,d+this.strokewidth),u+=t,y+=t);var t=c,z=f,t=m==mxConstants.ALIGN_CENTER?t+(b-p)/2:m==mxConstants.ALIGN_RIGHT?t+
+(b-p-u):t+u,z=da==mxConstants.ALIGN_MIDDLE?z+(d-n)/2:da==mxConstants.ALIGN_BOTTOM?z+(d-n-y):z+y;a.save();m=new g;m.style=this.style;g.prototype.paintVertexShape.call(m,a,t,z,p,n);a.restore()}e++}while(null!=g)}mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("ext",F);mxUtils.extend(G,mxCylinder);G.prototype.redrawPath=function(a,c,f,b,d,e){e?(a.moveTo(0,0),a.lineTo(b/2,d/2),a.lineTo(b,0),a.end()):(a.moveTo(0,0),a.lineTo(b,0),a.lineTo(b,d),a.lineTo(0,d),
a.close())};mxCellRenderer.registerShape("message",G);mxUtils.extend(E,mxShape);E.prototype.paintBackground=function(a,c,f,b,d){a.translate(c,f);a.ellipse(b/4,0,b/2,d/4);a.fillAndStroke();a.begin();a.moveTo(b/2,d/4);a.lineTo(b/2,2*d/3);a.moveTo(b/2,d/3);a.lineTo(0,d/3);a.moveTo(b/2,d/3);a.lineTo(b,d/3);a.moveTo(b/2,2*d/3);a.lineTo(0,d);a.moveTo(b/2,2*d/3);a.lineTo(b,d);a.end();a.stroke()};mxCellRenderer.registerShape("umlActor",E);mxUtils.extend(J,mxShape);J.prototype.getLabelMargins=function(a){return new mxRectangle(a.width/
6,0,0,0)};J.prototype.paintBackground=function(a,c,f,b,d){a.translate(c,f);a.begin();a.moveTo(0,d/4);a.lineTo(0,3*d/4);a.end();a.stroke();a.begin();a.moveTo(0,d/2);a.lineTo(b/6,d/2);a.end();a.stroke();a.ellipse(b/6,0,5*b/6,d);a.fillAndStroke()};mxCellRenderer.registerShape("umlBoundary",J);mxUtils.extend(H,mxEllipse);H.prototype.paintVertexShape=function(a,c,f,b,d){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(c+b/8,f+d);a.lineTo(c+7*b/8,f+d);a.end();a.stroke()};mxCellRenderer.registerShape("umlEntity",
H);mxUtils.extend(y,mxShape);y.prototype.paintVertexShape=function(a,c,f,b,d){a.translate(c,f);a.begin();a.moveTo(b,0);a.lineTo(0,d);a.moveTo(0,0);a.lineTo(b,d);a.end();a.stroke()};mxCellRenderer.registerShape("umlDestroy",y);mxUtils.extend(K,mxShape);K.prototype.getLabelBounds=function(a){return new mxRectangle(a.x,a.y+a.height/8,a.width,7*a.height/8)};K.prototype.paintBackground=function(a,c,f,b,d){a.translate(c,f);a.begin();a.moveTo(3*b/8,d/8*1.1);a.lineTo(5*b/8,0);a.end();a.stroke();a.ellipse(0,
d/8,b,7*d/8);a.fillAndStroke()};K.prototype.paintForeground=function(a,c,f,b,d){a.begin();a.moveTo(3*b/8,d/8*1.1);a.lineTo(5*b/8,d/4);a.end();a.stroke()};mxCellRenderer.registerShape("umlControl",K);mxUtils.extend(z,mxRectangleShape);z.prototype.size=40;z.prototype.isHtmlAllowed=function(){return!1};z.prototype.getLabelBounds=function(a){var c=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale));return new mxRectangle(a.x,a.y,a.width,c)};z.prototype.paintBackground=
function(a,c,f,b,d){var e=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.size)))),g=mxUtils.getValue(this.style,"participant");null==g||null==this.state?mxRectangleShape.prototype.paintBackground.call(this,a,c,f,b,e):(g=this.state.view.graph.cellRenderer.getShape(g),null!=g&&g!=z&&(g=new g,g.apply(this.state),a.save(),g.paintVertexShape(a,c,f,b,e),a.restore()));e<d&&(a.setDashed(!0),a.begin(),a.moveTo(c+b/2,f+e),a.lineTo(c+b/2,f+d),a.end(),a.stroke())};z.prototype.paintForeground=
function(a,c,f,b,d){var e=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.size))));mxRectangleShape.prototype.paintForeground.call(this,a,c,f,b,Math.min(d,e))};mxCellRenderer.registerShape("umlLifeline",z);mxUtils.extend(L,mxShape);L.prototype.width=60;L.prototype.height=30;L.prototype.corner=10;L.prototype.getLabelMargins=function(a){return new mxRectangle(0,0,a.width-parseFloat(mxUtils.getValue(this.style,"width",this.width)*this.scale),a.height-parseFloat(mxUtils.getValue(this.style,
-"height",this.height)*this.scale))};L.prototype.paintBackground=function(a,c,f,b,d){var e=this.corner,g=Math.min(b,Math.max(e,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),l=Math.min(d,Math.max(1.5*e,parseFloat(mxUtils.getValue(this.style,"height",this.height)))),p=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE);p!=mxConstants.NONE&&(a.setFillColor(p),a.rect(c,f,b,d),a.fill());null!=this.fill&&this.fill!=mxConstants.NONE&&this.gradient&&this.gradient!=
-mxConstants.NONE?(this.getGradientBounds(a,c,f,b,d),a.setGradient(this.fill,this.gradient,c,f,b,d,this.gradientDirection)):a.setFillColor(this.fill);a.begin();a.moveTo(c,f);a.lineTo(c+g,f);a.lineTo(c+g,f+Math.max(0,l-1.5*e));a.lineTo(c+Math.max(0,g-e),f+l);a.lineTo(c,f+l);a.close();a.fillAndStroke();a.begin();a.moveTo(c+g,f);a.lineTo(c+b,f);a.lineTo(c+b,f+d);a.lineTo(c,f+d);a.lineTo(c,f+l);a.stroke()};mxCellRenderer.registerShape("umlFrame",L);mxPerimeter.LifelinePerimeter=function(a,c,f,b){b=z.prototype.size;
+"height",this.height)*this.scale))};L.prototype.paintBackground=function(a,c,f,b,d){var e=this.corner,g=Math.min(b,Math.max(e,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),m=Math.min(d,Math.max(1.5*e,parseFloat(mxUtils.getValue(this.style,"height",this.height)))),p=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE);p!=mxConstants.NONE&&(a.setFillColor(p),a.rect(c,f,b,d),a.fill());null!=this.fill&&this.fill!=mxConstants.NONE&&this.gradient&&this.gradient!=
+mxConstants.NONE?(this.getGradientBounds(a,c,f,b,d),a.setGradient(this.fill,this.gradient,c,f,b,d,this.gradientDirection)):a.setFillColor(this.fill);a.begin();a.moveTo(c,f);a.lineTo(c+g,f);a.lineTo(c+g,f+Math.max(0,m-1.5*e));a.lineTo(c+Math.max(0,g-e),f+m);a.lineTo(c,f+m);a.close();a.fillAndStroke();a.begin();a.moveTo(c+g,f);a.lineTo(c+b,f);a.lineTo(c+b,f+d);a.lineTo(c,f+d);a.lineTo(c,f+m);a.stroke()};mxCellRenderer.registerShape("umlFrame",L);mxPerimeter.LifelinePerimeter=function(a,c,f,b){b=z.prototype.size;
null!=c&&(b=mxUtils.getValue(c.style,"size",b)*c.view.scale);c=parseFloat(c.style[mxConstants.STYLE_STROKEWIDTH]||1)*c.view.scale/2-1;f.x<a.getCenterX()&&(c=-1*(c+1));return new mxPoint(a.getCenterX()+c,Math.min(a.y+a.height,Math.max(a.y+b,f.y)))};mxStyleRegistry.putValue("lifelinePerimeter",mxPerimeter.LifelinePerimeter);mxPerimeter.OrthogonalPerimeter=function(a,c,f,b){b=!0;return mxPerimeter.RectanglePerimeter.apply(this,arguments)};mxStyleRegistry.putValue("orthogonalPerimeter",mxPerimeter.OrthogonalPerimeter);
mxPerimeter.BackbonePerimeter=function(a,c,f,b){b=parseFloat(c.style[mxConstants.STYLE_STROKEWIDTH]||1)*c.view.scale/2-1;null!=c.style.backboneSize&&(b+=parseFloat(c.style.backboneSize)*c.view.scale/2-1);if("south"==c.style[mxConstants.STYLE_DIRECTION]||"north"==c.style[mxConstants.STYLE_DIRECTION])return f.x<a.getCenterX()&&(b=-1*(b+1)),new mxPoint(a.getCenterX()+b,Math.min(a.y+a.height,Math.max(a.y,f.y)));f.y<a.getCenterY()&&(b=-1*(b+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,f.x)),
a.getCenterY()+b)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxPerimeter.CalloutPerimeter=function(a,c,f,b){return mxPerimeter.RectanglePerimeter(mxUtils.getDirectedBounds(a,new mxRectangle(0,0,0,Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(c.style,"size",B.prototype.size))*c.view.scale))),c.style),c,f,b)};mxStyleRegistry.putValue("calloutPerimeter",mxPerimeter.CalloutPerimeter);mxPerimeter.ParallelogramPerimeter=function(a,c,f,b){var d=p.prototype.size;
-null!=c&&(d=mxUtils.getValue(c.style,"size",d));var e=a.x,g=a.y,l=a.width,n=a.height;c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;c==mxConstants.DIRECTION_NORTH||c==mxConstants.DIRECTION_SOUTH?(d=n*Math.max(0,Math.min(1,d)),g=[new mxPoint(e,g),new mxPoint(e+l,g+d),new mxPoint(e+l,g+n),new mxPoint(e,g+n-d),new mxPoint(e,g)]):(d=l*Math.max(0,Math.min(1,d)),g=[new mxPoint(e+d,g),new mxPoint(e+l,g),new mxPoint(e+l-d,g+n),new mxPoint(e,
-g+n),new mxPoint(e+d,g)]);n=a.getCenterX();a=a.getCenterY();a=new mxPoint(n,a);b&&(f.x<e||f.x>e+l?a.y=f.y:a.x=f.x);return mxUtils.getPerimeterPoint(g,a,f)};mxStyleRegistry.putValue("parallelogramPerimeter",mxPerimeter.ParallelogramPerimeter);mxPerimeter.TrapezoidPerimeter=function(a,c,f,b){var d=l.prototype.size;null!=c&&(d=mxUtils.getValue(c.style,"size",d));var e=a.x,g=a.y,p=a.width,n=a.height;c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;
+null!=c&&(d=mxUtils.getValue(c.style,"size",d));var e=a.x,g=a.y,m=a.width,n=a.height;c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;c==mxConstants.DIRECTION_NORTH||c==mxConstants.DIRECTION_SOUTH?(d=n*Math.max(0,Math.min(1,d)),g=[new mxPoint(e,g),new mxPoint(e+m,g+d),new mxPoint(e+m,g+n),new mxPoint(e,g+n-d),new mxPoint(e,g)]):(d=m*Math.max(0,Math.min(1,d)),g=[new mxPoint(e+d,g),new mxPoint(e+m,g),new mxPoint(e+m-d,g+n),new mxPoint(e,
+g+n),new mxPoint(e+d,g)]);n=a.getCenterX();a=a.getCenterY();a=new mxPoint(n,a);b&&(f.x<e||f.x>e+m?a.y=f.y:a.x=f.x);return mxUtils.getPerimeterPoint(g,a,f)};mxStyleRegistry.putValue("parallelogramPerimeter",mxPerimeter.ParallelogramPerimeter);mxPerimeter.TrapezoidPerimeter=function(a,c,f,b){var d=m.prototype.size;null!=c&&(d=mxUtils.getValue(c.style,"size",d));var e=a.x,g=a.y,p=a.width,n=a.height;c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;
c==mxConstants.DIRECTION_EAST?(d=p*Math.max(0,Math.min(1,d)),g=[new mxPoint(e+d,g),new mxPoint(e+p-d,g),new mxPoint(e+p,g+n),new mxPoint(e,g+n),new mxPoint(e+d,g)]):c==mxConstants.DIRECTION_WEST?(d=p*Math.max(0,Math.min(1,d)),g=[new mxPoint(e,g),new mxPoint(e+p,g),new mxPoint(e+p-d,g+n),new mxPoint(e+d,g+n),new mxPoint(e,g)]):c==mxConstants.DIRECTION_NORTH?(d=n*Math.max(0,Math.min(1,d)),g=[new mxPoint(e,g+d),new mxPoint(e+p,g),new mxPoint(e+p,g+n),new mxPoint(e,g+n-d),new mxPoint(e,g+d)]):(d=n*Math.max(0,
Math.min(1,d)),g=[new mxPoint(e,g),new mxPoint(e+p,g+d),new mxPoint(e+p,g+n-d),new mxPoint(e,g+n),new mxPoint(e,g)]);n=a.getCenterX();a=a.getCenterY();a=new mxPoint(n,a);b&&(f.x<e||f.x>e+p?a.y=f.y:a.x=f.x);return mxUtils.getPerimeterPoint(g,a,f)};mxStyleRegistry.putValue("trapezoidPerimeter",mxPerimeter.TrapezoidPerimeter);mxPerimeter.StepPerimeter=function(a,c,f,b){var d="0"!=mxUtils.getValue(c.style,"fixedSize","0"),e=d?D.prototype.fixedSize:D.prototype.size;null!=c&&(e=mxUtils.getValue(c.style,
-"size",e));var g=a.x,l=a.y,p=a.width,n=a.height,u=a.getCenterX();a=a.getCenterY();c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;c==mxConstants.DIRECTION_EAST?(d=d?Math.max(0,Math.min(p,e)):p*Math.max(0,Math.min(1,e)),l=[new mxPoint(g,l),new mxPoint(g+p-d,l),new mxPoint(g+p,a),new mxPoint(g+p-d,l+n),new mxPoint(g,l+n),new mxPoint(g+d,a),new mxPoint(g,l)]):c==mxConstants.DIRECTION_WEST?(d=d?Math.max(0,Math.min(p,e)):p*Math.max(0,
-Math.min(1,e)),l=[new mxPoint(g+d,l),new mxPoint(g+p,l),new mxPoint(g+p-d,a),new mxPoint(g+p,l+n),new mxPoint(g+d,l+n),new mxPoint(g,a),new mxPoint(g+d,l)]):c==mxConstants.DIRECTION_NORTH?(d=d?Math.max(0,Math.min(n,e)):n*Math.max(0,Math.min(1,e)),l=[new mxPoint(g,l+d),new mxPoint(u,l),new mxPoint(g+p,l+d),new mxPoint(g+p,l+n),new mxPoint(u,l+n-d),new mxPoint(g,l+n),new mxPoint(g,l+d)]):(d=d?Math.max(0,Math.min(n,e)):n*Math.max(0,Math.min(1,e)),l=[new mxPoint(g,l),new mxPoint(u,l+d),new mxPoint(g+
-p,l),new mxPoint(g+p,l+n-d),new mxPoint(u,l+n),new mxPoint(g,l+n-d),new mxPoint(g,l)]);u=new mxPoint(u,a);b&&(f.x<g||f.x>g+p?u.y=f.y:u.x=f.x);return mxUtils.getPerimeterPoint(l,u,f)};mxStyleRegistry.putValue("stepPerimeter",mxPerimeter.StepPerimeter);mxPerimeter.HexagonPerimeter2=function(a,c,f,b){var d=C.prototype.size;null!=c&&(d=mxUtils.getValue(c.style,"size",d));var e=a.x,g=a.y,l=a.width,p=a.height,n=a.getCenterX();a=a.getCenterY();c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,
-mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;c==mxConstants.DIRECTION_NORTH||c==mxConstants.DIRECTION_SOUTH?(d=p*Math.max(0,Math.min(1,d)),g=[new mxPoint(n,g),new mxPoint(e+l,g+d),new mxPoint(e+l,g+p-d),new mxPoint(n,g+p),new mxPoint(e,g+p-d),new mxPoint(e,g+d),new mxPoint(n,g)]):(d=l*Math.max(0,Math.min(1,d)),g=[new mxPoint(e+d,g),new mxPoint(e+l-d,g),new mxPoint(e+l,a),new mxPoint(e+l-d,g+p),new mxPoint(e+d,g+p),new mxPoint(e,a),new mxPoint(e+d,g)]);n=new mxPoint(n,a);b&&(f.x<e||f.x>e+
-l?n.y=f.y:n.x=f.x);return mxUtils.getPerimeterPoint(g,n,f)};mxStyleRegistry.putValue("hexagonPerimeter2",mxPerimeter.HexagonPerimeter2);mxUtils.extend(O,mxShape);O.prototype.size=10;O.prototype.paintBackground=function(a,c,f,b,d){var e=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(c,f);a.ellipse((b-e)/2,0,e,e);a.fillAndStroke();a.begin();a.moveTo(b/2,e);a.lineTo(b/2,d);a.end();a.stroke()};mxCellRenderer.registerShape("lollipop",O);mxUtils.extend(I,mxShape);I.prototype.size=
+"size",e));var g=a.x,m=a.y,p=a.width,n=a.height,u=a.getCenterX();a=a.getCenterY();c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;c==mxConstants.DIRECTION_EAST?(d=d?Math.max(0,Math.min(p,e)):p*Math.max(0,Math.min(1,e)),m=[new mxPoint(g,m),new mxPoint(g+p-d,m),new mxPoint(g+p,a),new mxPoint(g+p-d,m+n),new mxPoint(g,m+n),new mxPoint(g+d,a),new mxPoint(g,m)]):c==mxConstants.DIRECTION_WEST?(d=d?Math.max(0,Math.min(p,e)):p*Math.max(0,
+Math.min(1,e)),m=[new mxPoint(g+d,m),new mxPoint(g+p,m),new mxPoint(g+p-d,a),new mxPoint(g+p,m+n),new mxPoint(g+d,m+n),new mxPoint(g,a),new mxPoint(g+d,m)]):c==mxConstants.DIRECTION_NORTH?(d=d?Math.max(0,Math.min(n,e)):n*Math.max(0,Math.min(1,e)),m=[new mxPoint(g,m+d),new mxPoint(u,m),new mxPoint(g+p,m+d),new mxPoint(g+p,m+n),new mxPoint(u,m+n-d),new mxPoint(g,m+n),new mxPoint(g,m+d)]):(d=d?Math.max(0,Math.min(n,e)):n*Math.max(0,Math.min(1,e)),m=[new mxPoint(g,m),new mxPoint(u,m+d),new mxPoint(g+
+p,m),new mxPoint(g+p,m+n-d),new mxPoint(u,m+n),new mxPoint(g,m+n-d),new mxPoint(g,m)]);u=new mxPoint(u,a);b&&(f.x<g||f.x>g+p?u.y=f.y:u.x=f.x);return mxUtils.getPerimeterPoint(m,u,f)};mxStyleRegistry.putValue("stepPerimeter",mxPerimeter.StepPerimeter);mxPerimeter.HexagonPerimeter2=function(a,c,f,b){var d=C.prototype.size;null!=c&&(d=mxUtils.getValue(c.style,"size",d));var e=a.x,g=a.y,m=a.width,p=a.height,n=a.getCenterX();a=a.getCenterY();c=null!=c?mxUtils.getValue(c.style,mxConstants.STYLE_DIRECTION,
+mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;c==mxConstants.DIRECTION_NORTH||c==mxConstants.DIRECTION_SOUTH?(d=p*Math.max(0,Math.min(1,d)),g=[new mxPoint(n,g),new mxPoint(e+m,g+d),new mxPoint(e+m,g+p-d),new mxPoint(n,g+p),new mxPoint(e,g+p-d),new mxPoint(e,g+d),new mxPoint(n,g)]):(d=m*Math.max(0,Math.min(1,d)),g=[new mxPoint(e+d,g),new mxPoint(e+m-d,g),new mxPoint(e+m,a),new mxPoint(e+m-d,g+p),new mxPoint(e+d,g+p),new mxPoint(e,a),new mxPoint(e+d,g)]);n=new mxPoint(n,a);b&&(f.x<e||f.x>e+
+m?n.y=f.y:n.x=f.x);return mxUtils.getPerimeterPoint(g,n,f)};mxStyleRegistry.putValue("hexagonPerimeter2",mxPerimeter.HexagonPerimeter2);mxUtils.extend(O,mxShape);O.prototype.size=10;O.prototype.paintBackground=function(a,c,f,b,d){var e=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(c,f);a.ellipse((b-e)/2,0,e,e);a.fillAndStroke();a.begin();a.moveTo(b/2,e);a.lineTo(b/2,d);a.end();a.stroke()};mxCellRenderer.registerShape("lollipop",O);mxUtils.extend(I,mxShape);I.prototype.size=
10;I.prototype.inset=2;I.prototype.paintBackground=function(a,c,f,b,d){var e=parseFloat(mxUtils.getValue(this.style,"size",this.size)),g=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(c,f);a.begin();a.moveTo(b/2,e+g);a.lineTo(b/2,d);a.end();a.stroke();a.begin();a.moveTo((b-e)/2-g,e/2);a.quadTo((b-e)/2-g,e+g,b/2,e+g);a.quadTo((b+e)/2+g,e+g,(b+e)/2+g,e/2);a.end();a.stroke()};mxCellRenderer.registerShape("requires",I);mxUtils.extend(U,mxShape);U.prototype.paintBackground=
function(a,c,f,b,d){a.translate(c,f);a.begin();a.moveTo(0,0);a.quadTo(b,0,b,d/2);a.quadTo(b,d,0,d);a.end();a.stroke()};mxCellRenderer.registerShape("requiredInterface",U);mxUtils.extend(ea,mxShape);ea.prototype.inset=2;ea.prototype.paintBackground=function(a,c,f,b,d){var e=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(c,f);a.ellipse(0,e,b-2*e,d-2*e);a.fillAndStroke();a.begin();a.moveTo(b/2,0);a.quadTo(b,0,b,d/2);a.quadTo(b,d,b/2,d);a.end();a.stroke()};mxCellRenderer.registerShape("providedRequiredInterface",
-ea);mxUtils.extend(ba,mxCylinder);ba.prototype.jettyWidth=20;ba.prototype.jettyHeight=10;ba.prototype.redrawPath=function(a,c,f,b,d,e){var g=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));c=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));f=g/2;var g=f+g/2,l=Math.min(c,d-c),p=Math.min(l+2*c,d-c);e?(a.moveTo(f,l),a.lineTo(g,l),a.lineTo(g,l+c),a.lineTo(f,l+c),a.moveTo(f,p),a.lineTo(g,p),a.lineTo(g,p+c),a.lineTo(f,p+c)):(a.moveTo(f,0),a.lineTo(b,0),a.lineTo(b,
-d),a.lineTo(f,d),a.lineTo(f,p+c),a.lineTo(0,p+c),a.lineTo(0,p),a.lineTo(f,p),a.lineTo(f,l+c),a.lineTo(0,l+c),a.lineTo(0,l),a.lineTo(f,l),a.close());a.end()};mxCellRenderer.registerShape("module",ba);mxUtils.extend(ha,mxCylinder);ha.prototype.jettyWidth=32;ha.prototype.jettyHeight=12;ha.prototype.redrawPath=function(a,c,f,b,d,e){var g=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));c=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));f=g/2;var g=f+g/2,l=.3*
-d-c/2,p=.7*d-c/2;e?(a.moveTo(f,l),a.lineTo(g,l),a.lineTo(g,l+c),a.lineTo(f,l+c),a.moveTo(f,p),a.lineTo(g,p),a.lineTo(g,p+c),a.lineTo(f,p+c)):(a.moveTo(f,0),a.lineTo(b,0),a.lineTo(b,d),a.lineTo(f,d),a.lineTo(f,p+c),a.lineTo(0,p+c),a.lineTo(0,p),a.lineTo(f,p),a.lineTo(f,l+c),a.lineTo(0,l+c),a.lineTo(0,l),a.lineTo(f,l),a.close());a.end()};mxCellRenderer.registerShape("component",ha);mxUtils.extend(fa,mxRectangleShape);fa.prototype.paintForeground=function(a,c,f,b,d){var e=b/2,g=d/2,l=mxUtils.getValue(this.style,
-mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;a.begin();this.addPoints(a,[new mxPoint(c+e,f),new mxPoint(c+b,f+g),new mxPoint(c+e,f+d),new mxPoint(c,f+g)],this.isRounded,l,!0);a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("associativeEntity",fa);mxUtils.extend(S,mxDoubleEllipse);S.prototype.outerStroke=!0;S.prototype.paintVertexShape=function(a,c,f,b,d){var e=Math.min(4,Math.min(b/5,d/5));0<b&&0<d&&(a.ellipse(c+e,f+e,b-2*e,d-2*e),
+ea);mxUtils.extend(ba,mxCylinder);ba.prototype.jettyWidth=20;ba.prototype.jettyHeight=10;ba.prototype.redrawPath=function(a,c,f,b,d,e){var g=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));c=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));f=g/2;var g=f+g/2,m=Math.min(c,d-c),p=Math.min(m+2*c,d-c);e?(a.moveTo(f,m),a.lineTo(g,m),a.lineTo(g,m+c),a.lineTo(f,m+c),a.moveTo(f,p),a.lineTo(g,p),a.lineTo(g,p+c),a.lineTo(f,p+c)):(a.moveTo(f,0),a.lineTo(b,0),a.lineTo(b,
+d),a.lineTo(f,d),a.lineTo(f,p+c),a.lineTo(0,p+c),a.lineTo(0,p),a.lineTo(f,p),a.lineTo(f,m+c),a.lineTo(0,m+c),a.lineTo(0,m),a.lineTo(f,m),a.close());a.end()};mxCellRenderer.registerShape("module",ba);mxUtils.extend(ha,mxCylinder);ha.prototype.jettyWidth=32;ha.prototype.jettyHeight=12;ha.prototype.redrawPath=function(a,c,f,b,d,e){var g=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));c=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));f=g/2;var g=f+g/2,m=.3*
+d-c/2,p=.7*d-c/2;e?(a.moveTo(f,m),a.lineTo(g,m),a.lineTo(g,m+c),a.lineTo(f,m+c),a.moveTo(f,p),a.lineTo(g,p),a.lineTo(g,p+c),a.lineTo(f,p+c)):(a.moveTo(f,0),a.lineTo(b,0),a.lineTo(b,d),a.lineTo(f,d),a.lineTo(f,p+c),a.lineTo(0,p+c),a.lineTo(0,p),a.lineTo(f,p),a.lineTo(f,m+c),a.lineTo(0,m+c),a.lineTo(0,m),a.lineTo(f,m),a.close());a.end()};mxCellRenderer.registerShape("component",ha);mxUtils.extend(fa,mxRectangleShape);fa.prototype.paintForeground=function(a,c,f,b,d){var e=b/2,g=d/2,m=mxUtils.getValue(this.style,
+mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;a.begin();this.addPoints(a,[new mxPoint(c+e,f),new mxPoint(c+b,f+g),new mxPoint(c+e,f+d),new mxPoint(c,f+g)],this.isRounded,m,!0);a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("associativeEntity",fa);mxUtils.extend(S,mxDoubleEllipse);S.prototype.outerStroke=!0;S.prototype.paintVertexShape=function(a,c,f,b,d){var e=Math.min(4,Math.min(b/5,d/5));0<b&&0<d&&(a.ellipse(c+e,f+e,b-2*e,d-2*e),
a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(c,f,b,d),a.stroke())};mxCellRenderer.registerShape("endState",S);mxUtils.extend(X,S);X.prototype.outerStroke=!1;mxCellRenderer.registerShape("startState",X);mxUtils.extend(Z,mxArrowConnector);Z.prototype.defaultWidth=4;Z.prototype.isOpenEnded=function(){return!0};Z.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};Z.prototype.isArrowRounded=function(){return this.isRounded};
mxCellRenderer.registerShape("link",Z);mxUtils.extend(ia,mxArrowConnector);ia.prototype.defaultWidth=10;ia.prototype.defaultArrowWidth=20;ia.prototype.getStartArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"startWidth",this.defaultArrowWidth)};ia.prototype.getEndArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"endWidth",this.defaultArrowWidth)};ia.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+
Math.max(0,this.strokewidth-1)};mxCellRenderer.registerShape("flexArrow",ia);mxUtils.extend(V,mxActor);V.prototype.size=30;V.prototype.isRoundable=function(){return!0};V.prototype.redrawPath=function(a,c,f,b,d){c=Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.size)));f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,d),new mxPoint(0,c),new mxPoint(b,0),new mxPoint(b,d)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("manualInput",
@@ -2658,27 +2658,27 @@ d):a.moveTo(c,f+d),"1"==mxUtils.getValue(this.style,"left","1")&&a.lineTo(c,f),a
ua);mxUtils.extend(qa,mxActor);qa.prototype.redrawPath=function(a,c,f,b,d){c=Math.min(b,d/2);a.moveTo(0,0);a.lineTo(b-c,0);a.quadTo(b,0,b,d/2);a.quadTo(b,d,b-c,d);a.lineTo(0,d);a.close();a.end()};mxCellRenderer.registerShape("delay",qa);mxUtils.extend(ra,mxActor);ra.prototype.size=.2;ra.prototype.redrawPath=function(a,c,f,b,d){c=Math.min(d,b);var e=Math.max(0,Math.min(c,c*parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=(d-e)/2;f=c+e;var g=(b-e)/2,e=g+e;a.moveTo(0,c);a.lineTo(g,c);a.lineTo(g,
0);a.lineTo(e,0);a.lineTo(e,c);a.lineTo(b,c);a.lineTo(b,f);a.lineTo(e,f);a.lineTo(e,d);a.lineTo(g,d);a.lineTo(g,f);a.lineTo(0,f);a.close();a.end()};mxCellRenderer.registerShape("cross",ra);mxUtils.extend(sa,mxActor);sa.prototype.size=.25;sa.prototype.redrawPath=function(a,c,f,b,d){c=Math.min(b,d/2);f=Math.min(b-c,Math.max(0,parseFloat(mxUtils.getValue(this.style,"size",this.size)))*b);a.moveTo(0,d/2);a.lineTo(f,0);a.lineTo(b-c,0);a.quadTo(b,0,b,d/2);a.quadTo(b,d,b-c,d);a.lineTo(f,d);a.close();a.end()};
mxCellRenderer.registerShape("display",sa);mxUtils.extend(na,mxConnector);na.prototype.origPaintEdgeShape=na.prototype.paintEdgeShape;na.prototype.paintEdgeShape=function(a,c,f){for(var b=[],d=0;d<c.length;d++)b.push(mxUtils.clone(c[d]));var d=a.state.dashed,e=a.state.fixDash;na.prototype.origPaintEdgeShape.apply(this,[a,b,f]);3<=a.state.strokeWidth&&(b=mxUtils.getValue(this.style,"fillColor",null),null!=b&&(a.setStrokeColor(b),a.setStrokeWidth(a.state.strokeWidth-2),a.setDashed(d,e),na.prototype.origPaintEdgeShape.apply(this,
-[a,c,f])))};mxCellRenderer.registerShape("filledEdge",na);"undefined"!==typeof StyleFormatPanel&&function(){var a=StyleFormatPanel.prototype.getCustomColors;StyleFormatPanel.prototype.getCustomColors=function(){var c=this.format.getSelectionState(),f=a.apply(this,arguments);"umlFrame"==c.style.shape&&f.push({title:mxResources.get("laneColor"),key:"swimlaneFillColor",defaultValue:"#ffffff"});return f}}();mxMarker.addMarker("dash",function(a,c,f,b,d,e,g,l,p,n){var u=d*(g+p+1),y=e*(g+p+1);return function(){a.begin();
-a.moveTo(b.x-u/2-y/2,b.y-y/2+u/2);a.lineTo(b.x+y/2-3*u/2,b.y-3*y/2-u/2);a.stroke()}});mxMarker.addMarker("box",function(a,c,f,b,d,e,g,l,p,n){var u=d*(g+p+1),y=e*(g+p+1),t=b.x+u/2,z=b.y+y/2;b.x-=u;b.y-=y;return function(){a.begin();a.moveTo(t-u/2-y/2,z-y/2+u/2);a.lineTo(t-u/2+y/2,z-y/2-u/2);a.lineTo(t+y/2-3*u/2,z-3*y/2-u/2);a.lineTo(t-y/2-3*u/2,z-3*y/2+u/2);a.close();n?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("cross",function(a,c,f,b,d,e,g,l,p,n){var u=d*(g+p+1),y=e*(g+p+1);return function(){a.begin();
-a.moveTo(b.x-u/2-y/2,b.y-y/2+u/2);a.lineTo(b.x+y/2-3*u/2,b.y-3*y/2-u/2);a.moveTo(b.x-u/2+y/2,b.y-y/2-u/2);a.lineTo(b.x-y/2-3*u/2,b.y-3*y/2+u/2);a.stroke()}});mxMarker.addMarker("circle",Da);mxMarker.addMarker("circlePlus",function(a,c,f,b,d,e,g,l,p,n){var u=b.clone(),y=Da.apply(this,arguments),t=d*(g+2*p),z=e*(g+2*p);return function(){y.apply(this,arguments);a.begin();a.moveTo(u.x-d*p,u.y-e*p);a.lineTo(u.x-2*t+d*p,u.y-2*z+e*p);a.moveTo(u.x-t-z+e*p,u.y-z+t-d*p);a.lineTo(u.x+z-t-e*p,u.y-z-t+d*p);a.stroke()}});
-mxMarker.addMarker("halfCircle",function(a,c,f,b,d,e,g,l,p,n){var u=d*(g+p+1),y=e*(g+p+1),t=b.clone();b.x-=u;b.y-=y;return function(){a.begin();a.moveTo(t.x-y,t.y+u);a.quadTo(b.x-y,b.y+u,b.x,b.y);a.quadTo(b.x+y,b.y-u,t.x+y,t.y-u);a.stroke()}});mxMarker.addMarker("async",function(a,c,f,b,d,e,g,l,p,n){c=d*p*1.118;f=e*p*1.118;d*=g+p;e*=g+p;var u=b.clone();u.x-=c;u.y-=f;b.x+=1*-d-c;b.y+=1*-e-f;return function(){a.begin();a.moveTo(u.x,u.y);l?a.lineTo(u.x-d-e/2,u.y-e+d/2):a.lineTo(u.x+e/2-d,u.y-e-d/2);
-a.lineTo(u.x-d,u.y-e);a.close();n?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("openAsync",function(a){a=null!=a?a:2;return function(c,f,b,d,e,g,l,p,n,u){e*=l+n;g*=l+n;var y=d.clone();return function(){c.begin();c.moveTo(y.x,y.y);p?c.lineTo(y.x-e-g/a,y.y-g+e/a):c.lineTo(y.x+g/a-e,y.y-g-e/a);c.stroke()}}}(2));if("undefined"!==typeof mxVertexHandler){var Na=function(a,c,f){return Ba(a,["width"],c,function(c,b,d,e,g){g=a.shape.getEdgeWidth()*a.view.scale+f;return new mxPoint(e.x+b*c/4+d*g/2,e.y+
-d*c/4-b*g/2)},function(c,b,d,e,g,l){c=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,l.x,l.y));a.style.width=Math.round(2*c)/a.view.scale-f})},Ba=function(a,c,f,b,d){return R(a,c,function(c){var d=a.absolutePoints,e=d.length-1;c=a.view.translate;var g=a.view.scale,l=f?d[0]:d[e],d=f?d[1]:d[e-1],e=d.x-l.x,p=d.y-l.y,n=Math.sqrt(e*e+p*p),l=b.call(this,n,e/n,p/n,l,d);return new mxPoint(l.x/g-c.x,l.y/g-c.y)},function(c,b,e){var g=a.absolutePoints,l=g.length-1;c=a.view.translate;var p=a.view.scale,n=f?g[0]:
-g[l],g=f?g[1]:g[l-1],l=g.x-n.x,u=g.y-n.y,y=Math.sqrt(l*l+u*u);b.x=(b.x+c.x)*p;b.y=(b.y+c.y)*p;d.call(this,y,l/y,u/y,n,g,b,e)})},xa=function(a){return function(c){return[R(c,["arrowWidth","arrowSize"],function(c){var f=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"arrowWidth",P.prototype.arrowWidth))),b=Math.max(0,Math.min(a,mxUtils.getValue(this.state.style,"arrowSize",P.prototype.arrowSize)));return new mxPoint(c.x+(1-b)*c.width,c.y+(1-f)*c.height/2)},function(c,f){this.state.style.arrowWidth=
+[a,c,f])))};mxCellRenderer.registerShape("filledEdge",na);"undefined"!==typeof StyleFormatPanel&&function(){var a=StyleFormatPanel.prototype.getCustomColors;StyleFormatPanel.prototype.getCustomColors=function(){var c=this.format.getSelectionState(),f=a.apply(this,arguments);"umlFrame"==c.style.shape&&f.push({title:mxResources.get("laneColor"),key:"swimlaneFillColor",defaultValue:"#ffffff"});return f}}();mxMarker.addMarker("dash",function(a,c,f,b,d,e,g,m,p,n){var u=d*(g+p+1),y=e*(g+p+1);return function(){a.begin();
+a.moveTo(b.x-u/2-y/2,b.y-y/2+u/2);a.lineTo(b.x+y/2-3*u/2,b.y-3*y/2-u/2);a.stroke()}});mxMarker.addMarker("box",function(a,c,f,b,d,e,g,m,p,n){var u=d*(g+p+1),y=e*(g+p+1),t=b.x+u/2,z=b.y+y/2;b.x-=u;b.y-=y;return function(){a.begin();a.moveTo(t-u/2-y/2,z-y/2+u/2);a.lineTo(t-u/2+y/2,z-y/2-u/2);a.lineTo(t+y/2-3*u/2,z-3*y/2-u/2);a.lineTo(t-y/2-3*u/2,z-3*y/2+u/2);a.close();n?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("cross",function(a,c,f,b,d,e,g,m,p,n){var u=d*(g+p+1),y=e*(g+p+1);return function(){a.begin();
+a.moveTo(b.x-u/2-y/2,b.y-y/2+u/2);a.lineTo(b.x+y/2-3*u/2,b.y-3*y/2-u/2);a.moveTo(b.x-u/2+y/2,b.y-y/2-u/2);a.lineTo(b.x-y/2-3*u/2,b.y-3*y/2+u/2);a.stroke()}});mxMarker.addMarker("circle",Da);mxMarker.addMarker("circlePlus",function(a,c,f,b,d,e,g,m,p,n){var u=b.clone(),y=Da.apply(this,arguments),t=d*(g+2*p),z=e*(g+2*p);return function(){y.apply(this,arguments);a.begin();a.moveTo(u.x-d*p,u.y-e*p);a.lineTo(u.x-2*t+d*p,u.y-2*z+e*p);a.moveTo(u.x-t-z+e*p,u.y-z+t-d*p);a.lineTo(u.x+z-t-e*p,u.y-z-t+d*p);a.stroke()}});
+mxMarker.addMarker("halfCircle",function(a,c,f,b,d,e,g,m,p,n){var u=d*(g+p+1),y=e*(g+p+1),t=b.clone();b.x-=u;b.y-=y;return function(){a.begin();a.moveTo(t.x-y,t.y+u);a.quadTo(b.x-y,b.y+u,b.x,b.y);a.quadTo(b.x+y,b.y-u,t.x+y,t.y-u);a.stroke()}});mxMarker.addMarker("async",function(a,c,f,b,d,e,g,m,p,n){c=d*p*1.118;f=e*p*1.118;d*=g+p;e*=g+p;var u=b.clone();u.x-=c;u.y-=f;b.x+=1*-d-c;b.y+=1*-e-f;return function(){a.begin();a.moveTo(u.x,u.y);m?a.lineTo(u.x-d-e/2,u.y-e+d/2):a.lineTo(u.x+e/2-d,u.y-e-d/2);
+a.lineTo(u.x-d,u.y-e);a.close();n?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("openAsync",function(a){a=null!=a?a:2;return function(c,f,b,d,e,g,m,p,n,u){e*=m+n;g*=m+n;var y=d.clone();return function(){c.begin();c.moveTo(y.x,y.y);p?c.lineTo(y.x-e-g/a,y.y-g+e/a):c.lineTo(y.x+g/a-e,y.y-g-e/a);c.stroke()}}}(2));if("undefined"!==typeof mxVertexHandler){var Na=function(a,c,f){return Ba(a,["width"],c,function(c,b,d,e,g){g=a.shape.getEdgeWidth()*a.view.scale+f;return new mxPoint(e.x+b*c/4+d*g/2,e.y+
+d*c/4-b*g/2)},function(c,b,d,e,g,m){c=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,m.x,m.y));a.style.width=Math.round(2*c)/a.view.scale-f})},Ba=function(a,c,f,b,d){return R(a,c,function(c){var d=a.absolutePoints,e=d.length-1;c=a.view.translate;var g=a.view.scale,m=f?d[0]:d[e],d=f?d[1]:d[e-1],e=d.x-m.x,p=d.y-m.y,n=Math.sqrt(e*e+p*p),m=b.call(this,n,e/n,p/n,m,d);return new mxPoint(m.x/g-c.x,m.y/g-c.y)},function(c,b,e){var g=a.absolutePoints,m=g.length-1;c=a.view.translate;var p=a.view.scale,n=f?g[0]:
+g[m],g=f?g[1]:g[m-1],m=g.x-n.x,u=g.y-n.y,y=Math.sqrt(m*m+u*u);b.x=(b.x+c.x)*p;b.y=(b.y+c.y)*p;d.call(this,y,m/y,u/y,n,g,b,e)})},xa=function(a){return function(c){return[R(c,["arrowWidth","arrowSize"],function(c){var f=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"arrowWidth",P.prototype.arrowWidth))),b=Math.max(0,Math.min(a,mxUtils.getValue(this.state.style,"arrowSize",P.prototype.arrowSize)));return new mxPoint(c.x+(1-b)*c.width,c.y+(1-f)*c.height/2)},function(c,f){this.state.style.arrowWidth=
Math.max(0,Math.min(1,Math.abs(c.y+c.height/2-f.y)/c.height*2));this.state.style.arrowSize=Math.max(0,Math.min(a,(c.x+c.width-f.x)/c.width))})]}},Ia=function(a,c,f){return function(b){var d=[R(b,["size"],function(f){var b=Math.max(0,Math.min(f.width,Math.min(f.height,parseFloat(mxUtils.getValue(this.state.style,"size",c)))))*a;return new mxPoint(f.x+b,f.y+b)},function(c,f){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(c.width,f.x-c.x),Math.min(c.height,f.y-c.y)))/a)})];f&&mxUtils.getValue(b.style,
mxConstants.STYLE_ROUNDED,!1)&&d.push(va(b));return d}},Ea=function(a,c,f,b,d){f=null!=f?f:1;return function(e){var g=[R(e,["size"],function(c){var f=null!=d?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null,b=parseFloat(mxUtils.getValue(this.state.style,"size",f?d:a));return new mxPoint(c.x+Math.max(0,Math.min(c.width,b*(f?1:c.width))),c.getCenterY())},function(a,c,b){var g=null!=d?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null;a=g?c.x-a.x:Math.max(0,Math.min(f,(c.x-a.x)/
-a.width));g&&!mxEvent.isAltDown(b.getEvent())&&(a=e.view.graph.snap(a));this.state.style.size=a},null,b)];c&&mxUtils.getValue(e.style,mxConstants.STYLE_ROUNDED,!1)&&g.push(va(e));return g}},Oa=function(a){return function(c){var f=[R(c,["size"],function(c){var f=Math.max(0,Math.min(a,parseFloat(mxUtils.getValue(this.state.style,"size",l.prototype.size))));return new mxPoint(c.x+f*c.width*.75,c.y+c.height/4)},function(c,f){this.state.style.size=Math.max(0,Math.min(a,(f.x-c.x)/(.75*c.width)))},null,
+a.width));g&&!mxEvent.isAltDown(b.getEvent())&&(a=e.view.graph.snap(a));this.state.style.size=a},null,b)];c&&mxUtils.getValue(e.style,mxConstants.STYLE_ROUNDED,!1)&&g.push(va(e));return g}},Oa=function(a){return function(c){var f=[R(c,["size"],function(c){var f=Math.max(0,Math.min(a,parseFloat(mxUtils.getValue(this.state.style,"size",m.prototype.size))));return new mxPoint(c.x+f*c.width*.75,c.y+c.height/4)},function(c,f){this.state.style.size=Math.max(0,Math.min(a,(f.x-c.x)/(.75*c.width)))},null,
!0)];mxUtils.getValue(c.style,mxConstants.STYLE_ROUNDED,!1)&&f.push(va(c));return f}},Ca=function(){return function(a){var c=[];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&c.push(va(a));return c}},va=function(a,c){return R(a,[mxConstants.STYLE_ARCSIZE],function(f){var b=null!=c?c:f.height/8;if("1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)){var d=mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;return new mxPoint(f.x+f.width-Math.min(f.width/
2,d),f.y+b)}d=Math.max(0,parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)))/100;return new mxPoint(f.x+f.width-Math.min(Math.max(f.width/2,f.height/2),Math.min(f.width,f.height)*d),f.y+b)},function(c,f,b){"1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.max(0,Math.min(c.width,2*(c.x+c.width-f.x)))):this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.min(50,
-Math.max(0,100*(c.width-f.x+c.x)/Math.min(c.width,c.height))))})},R=function(a,c,f,b,d,e){var g=new mxHandle(a,null,mxVertexHandler.prototype.secondaryHandleImage);g.execute=function(){for(var a=0;a<c.length;a++)this.copyStyle(c[a])};g.getPosition=f;g.setPosition=b;g.ignoreGrid=null!=d?d:!0;if(e){var l=g.positionChanged;g.positionChanged=function(){l.apply(this,arguments);a.view.invalidate(this.state.cell);a.view.validate()}}return g},Fa={link:function(a){return[Na(a,!0,10),Na(a,!1,10)]},flexArrow:function(a){var c=
+Math.max(0,100*(c.width-f.x+c.x)/Math.min(c.width,c.height))))})},R=function(a,c,f,b,d,e){var g=new mxHandle(a,null,mxVertexHandler.prototype.secondaryHandleImage);g.execute=function(){for(var a=0;a<c.length;a++)this.copyStyle(c[a])};g.getPosition=f;g.setPosition=b;g.ignoreGrid=null!=d?d:!0;if(e){var m=g.positionChanged;g.positionChanged=function(){m.apply(this,arguments);a.view.invalidate(this.state.cell);a.view.validate()}}return g},Fa={link:function(a){return[Na(a,!0,10),Na(a,!1,10)]},flexArrow:function(a){var c=
a.view.graph.gridSize/a.view.scale,f=[];mxUtils.getValue(a.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE&&(f.push(Ba(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(c,f,b,d,e){c=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;e=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)+b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)-f*
-c/2)},function(f,b,d,e,g,l,p){f=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,l.x,l.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,l.x,l.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*f)/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]);mxEvent.isAltDown(p.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<
-c/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE])})),f.push(Ba(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(c,f,b,d,e){c=(a.shape.getStartArrowWidth()-a.shape.strokewidth)*a.view.scale;e=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)+b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)-f*c/2)},function(f,b,d,e,g,l,p){f=
-Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,l.x,l.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,l.x,l.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.startWidth=Math.max(0,Math.round(2*f)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE],a.style.endWidth=a.style.startWidth);mxEvent.isAltDown(p.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-
+c/2)},function(f,b,d,e,g,m,p){f=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,m.x,m.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,m.x,m.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*f)/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]);mxEvent.isAltDown(p.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<
+c/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE])})),f.push(Ba(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(c,f,b,d,e){c=(a.shape.getStartArrowWidth()-a.shape.strokewidth)*a.view.scale;e=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)+b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)-f*c/2)},function(f,b,d,e,g,m,p){f=
+Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,m.x,m.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,m.x,m.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.startWidth=Math.max(0,Math.round(2*f)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE],a.style.endWidth=a.style.startWidth);mxEvent.isAltDown(p.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-
parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<c/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]),Math.abs(parseFloat(a.style.startWidth)-parseFloat(a.style.endWidth))<c&&(a.style.startWidth=a.style.endWidth))})));mxUtils.getValue(a.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE&&(f.push(Ba(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!1,function(c,f,b,d,e){c=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;e=3*mxUtils.getNumber(a.style,
-mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)-b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)+f*c/2)},function(f,b,d,e,g,l,p){f=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,l.x,l.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,l.x,l.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*f)/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=
+mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)-b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)+f*c/2)},function(f,b,d,e,g,m,p){f=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,m.x,m.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,m.x,m.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*f)/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=
a.style[mxConstants.STYLE_ENDSIZE]);mxEvent.isAltDown(p.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<c/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE])})),f.push(Ba(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!1,function(c,f,b,d,e){c=(a.shape.getEndArrowWidth()-a.shape.strokewidth)*a.view.scale;e=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/
-5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)-b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)+f*c/2)},function(f,b,d,e,g,l,p){f=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,l.x,l.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,l.x,l.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.endWidth=Math.max(0,Math.round(2*f)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=
+5)*a.view.scale;return new mxPoint(d.x+f*(e+a.shape.strokewidth*a.view.scale)-b*c/2,d.y+b*(e+a.shape.strokewidth*a.view.scale)+f*c/2)},function(f,b,d,e,g,m,p){f=Math.sqrt(mxUtils.ptSegDistSq(e.x,e.y,g.x,g.y,m.x,m.y));b=mxUtils.ptLineDist(e.x,e.y,e.x+d,e.y-b,m.x,m.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(b-a.shape.strokewidth)/3)/100/a.view.scale;a.style.endWidth=Math.max(0,Math.round(2*f)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(p.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=
a.style[mxConstants.STYLE_ENDSIZE],a.style.startWidth=a.style.endWidth);mxEvent.isAltDown(p.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<c/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]),Math.abs(parseFloat(a.style.endWidth)-parseFloat(a.style.startWidth))<c&&(a.style.endWidth=a.style.startWidth))})));return f},swimlane:function(a){var c=[R(a,[mxConstants.STYLE_STARTSIZE],function(c){var f=parseFloat(mxUtils.getValue(a.style,
mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));return 1==mxUtils.getValue(a.style,mxConstants.STYLE_HORIZONTAL,1)?new mxPoint(c.getCenterX(),c.y+Math.max(0,Math.min(c.height,f))):new mxPoint(c.x+Math.max(0,Math.min(c.width,f)),c.getCenterY())},function(c,f){a.style[mxConstants.STYLE_STARTSIZE]=1==mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,1)?Math.round(Math.max(0,Math.min(c.height,f.y-c.y))):Math.round(Math.max(0,Math.min(c.width,f.x-c.x)))})];if(mxUtils.getValue(a.style,
mxConstants.STYLE_ROUNDED)){var f=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));c.push(va(a,f/2))}return c},label:Ca(),ext:Ca(),rectangle:Ca(),triangle:Ca(),rhombus:Ca(),umlLifeline:function(a){return[R(a,["size"],function(a){var c=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",z.prototype.size))));return new mxPoint(a.getCenterX(),a.y+c)},function(a,c){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,
@@ -2699,8 +2699,8 @@ c){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,c.x-a.x-a.widt
["size"],function(a){var c=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",W.prototype.size))));return new mxPoint(a.getCenterX(),a.y+(1-c)*a.height)},function(a,c){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-c.y)/a.height))})]},step:Ea(D.prototype.size,!0,null,!0,D.prototype.fixedSize),hexagon:Ea(C.prototype.size,!0,.5,!0),curlyBracket:Ea(n.prototype.size,!1),display:Ea(sa.prototype.size,!1),cube:Ia(1,a.prototype.size,!1),card:Ia(.5,c.prototype.size,!0),loopLimit:Ia(.5,
ja.prototype.size,!0),trapezoid:Oa(.5),parallelogram:Oa(1)};Graph.createHandle=R;Graph.handleFactory=Fa;var Qa=mxVertexHandler.prototype.createCustomHandles;mxVertexHandler.prototype.createCustomHandles=function(){var a=Qa.apply(this,arguments);if(this.graph.isCellRotatable(this.state.cell)){var c=this.state.style.shape;null==mxCellRenderer.defaultShapes[c]&&null==mxStencilRegistry.getStencil(c)&&(c=mxConstants.SHAPE_RECTANGLE);c=Fa[c];null==c&&null!=this.state.shape&&this.state.shape.isRoundable()&&
(c=Fa[mxConstants.SHAPE_RECTANGLE]);null!=c&&(c=c(this.state),null!=c&&(a=null==a?c:a.concat(c)))}return a};mxEdgeHandler.prototype.createCustomHandles=function(){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_CONNECTOR);a=Fa[a];return null!=a?a(this.state):null}}else Graph.createHandle=function(){},Graph.handleFactory={};var Ga=new mxPoint(1,0),Ha=new mxPoint(1,0),xa=mxUtils.toRadians(-30),Ga=mxUtils.getRotatedPoint(Ga,
-Math.cos(xa),Math.sin(xa)),xa=mxUtils.toRadians(-150),Ha=mxUtils.getRotatedPoint(Ha,Math.cos(xa),Math.sin(xa));mxEdgeStyle.IsometricConnector=function(a,c,f,b,d){var e=a.view;b=null!=b&&0<b.length?b[0]:null;var g=a.absolutePoints,l=g[0],g=g[g.length-1];null!=b&&(b=e.transformControlPoint(a,b));null==l&&null!=c&&(l=new mxPoint(c.getCenterX(),c.getCenterY()));null==g&&null!=f&&(g=new mxPoint(f.getCenterX(),f.getCenterY()));var p=Ga.x,n=Ga.y,u=Ha.x,y=Ha.y,t="horizontal"==mxUtils.getValue(a.style,"elbow",
-"horizontal");if(null!=g&&null!=l){a=function(a,c,f){a-=z.x;var b=c-z.y;c=(y*a-u*b)/(p*y-n*u);a=(n*a-p*b)/(n*u-p*y);t?(f&&(z=new mxPoint(z.x+p*c,z.y+n*c),d.push(z)),z=new mxPoint(z.x+u*a,z.y+y*a)):(f&&(z=new mxPoint(z.x+u*a,z.y+y*a),d.push(z)),z=new mxPoint(z.x+p*c,z.y+n*c));d.push(z)};var z=l;null==b&&(b=new mxPoint(l.x+(g.x-l.x)/2,l.y+(g.y-l.y)/2));a(b.x,b.y,!0);a(g.x,g.y,!1)}};mxStyleRegistry.putValue("isometricEdgeStyle",mxEdgeStyle.IsometricConnector);var Ra=Graph.prototype.createEdgeHandler;
+Math.cos(xa),Math.sin(xa)),xa=mxUtils.toRadians(-150),Ha=mxUtils.getRotatedPoint(Ha,Math.cos(xa),Math.sin(xa));mxEdgeStyle.IsometricConnector=function(a,c,f,b,d){var e=a.view;b=null!=b&&0<b.length?b[0]:null;var g=a.absolutePoints,m=g[0],g=g[g.length-1];null!=b&&(b=e.transformControlPoint(a,b));null==m&&null!=c&&(m=new mxPoint(c.getCenterX(),c.getCenterY()));null==g&&null!=f&&(g=new mxPoint(f.getCenterX(),f.getCenterY()));var p=Ga.x,n=Ga.y,u=Ha.x,y=Ha.y,t="horizontal"==mxUtils.getValue(a.style,"elbow",
+"horizontal");if(null!=g&&null!=m){a=function(a,c,f){a-=z.x;var b=c-z.y;c=(y*a-u*b)/(p*y-n*u);a=(n*a-p*b)/(n*u-p*y);t?(f&&(z=new mxPoint(z.x+p*c,z.y+n*c),d.push(z)),z=new mxPoint(z.x+u*a,z.y+y*a)):(f&&(z=new mxPoint(z.x+u*a,z.y+y*a),d.push(z)),z=new mxPoint(z.x+p*c,z.y+n*c));d.push(z)};var z=m;null==b&&(b=new mxPoint(m.x+(g.x-m.x)/2,m.y+(g.y-m.y)/2));a(b.x,b.y,!0);a(g.x,g.y,!1)}};mxStyleRegistry.putValue("isometricEdgeStyle",mxEdgeStyle.IsometricConnector);var Ra=Graph.prototype.createEdgeHandler;
Graph.prototype.createEdgeHandler=function(a,c){if(c==mxEdgeStyle.IsometricConnector){var f=new mxElbowEdgeHandler(a);f.snapToTerminals=!1;return f}return Ra.apply(this,arguments)};b.prototype.constraints=[];e.prototype.getConstraints=function(a,c,f){a=[];var b=Math.tan(mxUtils.toRadians(30)),d=(.5-b)/2,b=Math.min(c,f/(.5+b));c=(c-b)/2;f=(f-b)/2;a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c,f+.25*b));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c+.5*b,f+b*d));a.push(new mxConnectionConstraint(new mxPoint(0,
0),!1,null,c+b,f+.25*b));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c+b,f+.75*b));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c+.5*b,f+(1-d)*b));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c,f+.75*b));return a};B.prototype.getConstraints=function(a,c,f){a=[];mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE);var b=Math.max(0,Math.min(f,parseFloat(mxUtils.getValue(this.style,"size",this.size))));parseFloat(mxUtils.getValue(this.style,
"position",this.position));var d=c*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position2",this.position2))));parseFloat(mxUtils.getValue(this.style,"base",this.base));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1));a.push(new mxConnectionConstraint(new mxPoint(.25,0),!1));a.push(new mxConnectionConstraint(new mxPoint(.5,0),!1));a.push(new mxConnectionConstraint(new mxPoint(.75,0),!1));a.push(new mxConnectionConstraint(new mxPoint(1,0),!1));a.push(new mxConnectionConstraint(new mxPoint(0,
@@ -2725,14 +2725,14 @@ c),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(
.7),!0),new mxConnectionConstraint(new mxPoint(1,.3),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.7),!0),new mxConnectionConstraint(new mxPoint(.15,.95),!1),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.85,.95),!1)];E.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.1),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.75,.1),!1),new mxConnectionConstraint(new mxPoint(0,
1/3),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(1,1/3),!1),new mxConnectionConstraint(new mxPoint(1,1),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1)];ha.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,
.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxActor.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.25,.2),!1),new mxConnectionConstraint(new mxPoint(.1,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.75,
-.25),!1),new mxConnectionConstraint(new mxPoint(.9,.5),!1),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];m.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(.5,.25),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,
+.25),!1),new mxConnectionConstraint(new mxPoint(.9,.5),!1),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];l.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(.5,.25),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,
.5),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(.5,.75),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];f.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.35),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.65),!1),new mxConnectionConstraint(new mxPoint(1,.35),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,.65),!1),new mxConnectionConstraint(new mxPoint(.25,
1),!1),new mxConnectionConstraint(new mxPoint(.75,0),!1)];D.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,
.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxLine.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];O.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,
1),!1)];mxDoubleEllipse.prototype.constraints=mxEllipse.prototype.constraints;mxRhombus.prototype.constraints=mxEllipse.prototype.constraints;mxTriangle.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0)];mxHexagon.prototype.constraints=
[new mxConnectionConstraint(new mxPoint(.375,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.625,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.375,1),!0),
new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.625,1),!0)];mxCloud.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.25),!1),new mxConnectionConstraint(new mxPoint(.4,.1),!1),new mxConnectionConstraint(new mxPoint(.16,.55),!1),new mxConnectionConstraint(new mxPoint(.07,.4),!1),new mxConnectionConstraint(new mxPoint(.31,.8),!1),new mxConnectionConstraint(new mxPoint(.13,.77),!1),new mxConnectionConstraint(new mxPoint(.8,.8),!1),new mxConnectionConstraint(new mxPoint(.55,
-.95),!1),new mxConnectionConstraint(new mxPoint(.875,.5),!1),new mxConnectionConstraint(new mxPoint(.96,.7),!1),new mxConnectionConstraint(new mxPoint(.625,.2),!1),new mxConnectionConstraint(new mxPoint(.88,.25),!1)];p.prototype.constraints=mxRectangleShape.prototype.constraints;l.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,
+.95),!1),new mxConnectionConstraint(new mxPoint(.875,.5),!1),new mxConnectionConstraint(new mxPoint(.96,.7),!1),new mxConnectionConstraint(new mxPoint(.625,.2),!1),new mxConnectionConstraint(new mxPoint(.88,.25),!1)];p.prototype.constraints=mxRectangleShape.prototype.constraints;m.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,
0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxArrow.prototype.constraints=null;ca.prototype.getConstraints=function(a,c,f){a=[];var b=Math.max(0,Math.min(c,parseFloat(mxUtils.getValue(this.style,"dx",this.dx)))),d=Math.max(0,Math.min(f,parseFloat(mxUtils.getValue(this.style,
"dy",this.dy))));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1));a.push(new mxConnectionConstraint(new mxPoint(.5,0),!1));a.push(new mxConnectionConstraint(new mxPoint(1,0),!1));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c,.5*d));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,c,d));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.75*c+.25*b,d));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(c+b),d));a.push(new mxConnectionConstraint(new mxPoint(0,
0),!1,null,.5*(c+b),.5*(f+d)));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(c+b),f));a.push(new mxConnectionConstraint(new mxPoint(.5,1),!1));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(c-b),f));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(c-b),.5*(f+d)));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.5*(c-b),d));a.push(new mxConnectionConstraint(new mxPoint(0,0),!1,null,.25*c-.25*b,d));a.push(new mxConnectionConstraint(new mxPoint(0,
@@ -2753,7 +2753,7 @@ function(){d.openLink(b.getUrl())});this.addAction("open...",function(){window.o
": "+p.message)}}));b.showDialog((new OpenDialog(this)).container,320,220,!0,!0,function(){window.openFile=null})}).isEnabled=k;this.addAction("save",function(){b.saveFile(!1)},null,null,Editor.ctrlKey+"+S").isEnabled=k;this.addAction("saveAs...",function(){b.saveFile(!0)},null,null,Editor.ctrlKey+"+Shift+S").isEnabled=k;this.addAction("export...",function(){b.showDialog((new ExportDialog(b)).container,300,296,!0,!0)});this.addAction("editDiagram...",function(){var a=new EditDiagramDialog(b);b.showDialog(a.container,
620,420,!0,!1);a.init()});this.addAction("pageSetup...",function(){b.showDialog((new PageSetupDialog(b)).container,320,220,!0,!0)}).isEnabled=k;this.addAction("print...",function(){b.showDialog((new PrintDialog(b)).container,300,180,!0,!0)},null,"sprite-print",Editor.ctrlKey+"+P");this.addAction("preview",function(){mxUtils.show(d,null,10,10)});this.addAction("undo",function(){b.undo()},null,"sprite-undo",Editor.ctrlKey+"+Z");this.addAction("redo",function(){b.redo()},null,"sprite-redo",mxClient.IS_WIN?
Editor.ctrlKey+"+Y":Editor.ctrlKey+"+Shift+Z");this.addAction("cut",function(){mxClipboard.cut(d)},null,"sprite-cut",Editor.ctrlKey+"+X");this.addAction("copy",function(){try{mxClipboard.copy(d)}catch(c){b.handleError(c)}},null,"sprite-copy",Editor.ctrlKey+"+C");this.addAction("paste",function(){d.isEnabled()&&!d.isCellLocked(d.getDefaultParent())&&mxClipboard.paste(d)},!1,"sprite-paste",Editor.ctrlKey+"+V");this.addAction("pasteHere",function(a){if(d.isEnabled()&&!d.isCellLocked(d.getDefaultParent())){d.getModel().beginUpdate();
-try{var c=mxClipboard.paste(d);if(null!=c){a=!0;for(var b=0;b<c.length&&a;b++)a=a&&d.model.isEdge(c[b]);var e=d.view.translate,l=d.view.scale,n=e.x,v=e.y,e=null;if(1==c.length&&a){var t=d.getCellGeometry(c[0]);null!=t&&(e=t.getTerminalPoint(!0))}e=null!=e?e:d.getBoundingBoxFromGeometry(c,a);if(null!=e){var u=Math.round(d.snap(d.popupMenuHandler.triggerX/l-n)),m=Math.round(d.snap(d.popupMenuHandler.triggerY/l-v));d.cellsMoved(c,u-e.x,m-e.y)}}}finally{d.getModel().endUpdate()}}});this.addAction("copySize",
+try{var c=mxClipboard.paste(d);if(null!=c){a=!0;for(var b=0;b<c.length&&a;b++)a=a&&d.model.isEdge(c[b]);var e=d.view.translate,m=d.view.scale,n=e.x,l=e.y,e=null;if(1==c.length&&a){var t=d.getCellGeometry(c[0]);null!=t&&(e=t.getTerminalPoint(!0))}e=null!=e?e:d.getBoundingBoxFromGeometry(c,a);if(null!=e){var u=Math.round(d.snap(d.popupMenuHandler.triggerX/m-n)),k=Math.round(d.snap(d.popupMenuHandler.triggerY/m-l));d.cellsMoved(c,u-e.x,k-e.y)}}}finally{d.getModel().endUpdate()}}});this.addAction("copySize",
function(a){a=d.getSelectionCell();d.isEnabled()&&null!=a&&d.getModel().isVertex(a)&&(a=d.getCellGeometry(a),null!=a&&(b.copiedSize=new mxRectangle(a.x,a.y,a.width,a.height)))},null,null,"Alt+Shift+X");this.addAction("pasteSize",function(a){if(d.isEnabled()&&!d.isSelectionEmpty()&&null!=b.copiedSize){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(a=0;a<c.length;a++)if(d.getModel().isVertex(c[a])){var e=d.getCellGeometry(c[a]);null!=e&&(e=e.clone(),e.width=b.copiedSize.width,e.height=
b.copiedSize.height,d.getModel().setGeometry(c[a],e))}}finally{d.getModel().endUpdate()}}},null,null,"Alt+Shift+V");this.addAction("delete",function(c){a(null!=c&&mxEvent.isShiftDown(c))},null,null,"Delete");this.addAction("deleteAll",function(){a(!0)},null,null,Editor.ctrlKey+"+Delete");this.addAction("duplicate",function(){try{d.setSelectionCells(d.duplicateCells())}catch(c){b.handleError(c)}},null,null,Editor.ctrlKey+"+D");this.put("turn",new Action(mxResources.get("turn")+" / "+mxResources.get("reverse"),
function(a){d.turnShapes(d.getSelectionCells(),null!=a?mxEvent.isShiftDown(a):!1)},null,null,Editor.ctrlKey+"+R"));this.addAction("selectVertices",function(){d.selectVertices(null,!0)},null,null,Editor.ctrlKey+"+Shift+I");this.addAction("selectEdges",function(){d.selectEdges()},null,null,Editor.ctrlKey+"+Shift+E");this.addAction("selectAll",function(){d.selectAll(null,!0)},null,null,Editor.ctrlKey+"+A");this.addAction("selectNone",function(){d.clearSelection()},null,null,Editor.ctrlKey+"+Shift+A");
@@ -2764,26 +2764,26 @@ this.addAction("edit",function(){d.isEnabled()&&d.startEditingAtCell()},null,nul
":",d,function(c){a.setTooltipForCell(f,c)});b.showDialog(d.container,320,200,!0,!0);d.init()}},null,null,"Alt+Shift+T");this.addAction("openLink",function(){var a=d.getLinkForCell(d.getSelectionCell());null!=a&&d.openLink(a)});this.addAction("editLink...",function(){var a=b.editor.graph;if(a.isEnabled()&&!a.isSelectionEmpty()){var f=a.getSelectionCell(),d=a.getLinkForCell(f)||"";b.showLinkDialog(d,mxResources.get("apply"),function(c){c=mxUtils.trim(c);a.setLinkForCell(f,0<c.length?c:null)})}},null,
null,"Alt+Shift+L");this.put("insertImage",new Action(mxResources.get("image")+"...",function(){d.isEnabled()&&!d.isCellLocked(d.getDefaultParent())&&(d.clearSelection(),b.actions.get("image").funct())})).isEnabled=k;this.put("insertLink",new Action(mxResources.get("link")+"...",function(){d.isEnabled()&&!d.isCellLocked(d.getDefaultParent())&&b.showLinkDialog("",mxResources.get("insert"),function(a,f){a=mxUtils.trim(a);if(0<a.length){var c=null,b=d.getLinkTitle(a);null!=f&&0<f.length&&(c=f[0].iconUrl,
b=f[0].name||f[0].type,b=b.charAt(0).toUpperCase()+b.substring(1),30<b.length&&(b=b.substring(0,30)+"..."));var e=d.getFreeInsertPoint(),c=new mxCell(b,new mxGeometry(e.x,e.y,100,40),"fontColor=#0000EE;fontStyle=4;rounded=1;overflow=hidden;"+(null!=c?"shape=label;imageWidth=16;imageHeight=16;spacingLeft=26;align=left;image="+c:"spacing=10;"));c.vertex=!0;d.setLinkForCell(c,a);d.cellSizeUpdated(c,!0);d.getModel().beginUpdate();try{c=d.addCell(c),d.fireEvent(new mxEventObject("cellsInserted","cells",
-[c]))}finally{d.getModel().endUpdate()}d.setSelectionCell(c);d.scrollCellToVisible(d.getSelectionCell())}})})).isEnabled=k;this.addAction("link...",mxUtils.bind(this,function(){var a=b.editor.graph;if(a.isEnabled())if(a.cellEditor.isContentEditing()){var f=a.getSelectedElement(),d=a.getParentByName(f,"A",a.cellEditor.textarea),e="";if(null==d&&null!=f&&null!=f.getElementsByTagName)for(var l=f.getElementsByTagName("a"),n=0;n<l.length&&null==d;n++)l[n].textContent==f.textContent&&(d=l[n]);null!=d&&
-"A"==d.nodeName&&(e=d.getAttribute("href")||"",a.selectNode(d));var v=a.cellEditor.saveSelection();b.showLinkDialog(e,mxResources.get("apply"),mxUtils.bind(this,function(c){a.cellEditor.restoreSelection(v);null!=c&&a.insertLink(c)}))}else a.isSelectionEmpty()?this.get("insertLink").funct():this.get("editLink").funct()})).isEnabled=k;this.addAction("autosize",function(){var a=d.getSelectionCells();if(null!=a){d.getModel().beginUpdate();try{for(var f=0;f<a.length;f++){var b=a[f];if(d.getModel().getChildCount(b))d.updateGroupBounds([b],
-20);else{var e=d.view.getState(b),l=d.getCellGeometry(b);d.getModel().isVertex(b)&&null!=e&&null!=e.text&&null!=l&&d.isWrapping(b)?(l=l.clone(),l.height=e.text.boundingBox.height/d.view.scale,d.getModel().setGeometry(b,l)):d.updateCellSize(b)}}}finally{d.getModel().endUpdate()}}},null,null,Editor.ctrlKey+"+Shift+Y");this.addAction("formattedText",function(){var a=d.getView().getState(d.getSelectionCell());if(null!=a){d.stopEditing();a="1"==a.style.html?null:"1";d.getModel().beginUpdate();try{for(var f=
-d.getSelectionCells(),e=0;e<f.length;e++)if(state=d.getView().getState(f[e]),null!=state){var p=mxUtils.getValue(state.style,"html","0");if("1"==p&&null==a){var l=d.convertValueToString(state.cell);"0"!=mxUtils.getValue(state.style,"nl2Br","1")&&(l=l.replace(/\n/g,"").replace(/<br\s*.?>/g,"\n"));var n=document.createElement("div");n.innerHTML=l;l=mxUtils.extractTextWithWhitespace(n.childNodes);d.cellLabelChanged(state.cell,l);d.setCellStyles("html",a,[f[e]])}else"0"==p&&"1"==a&&(l=mxUtils.htmlEntities(d.convertValueToString(state.cell),
-!1),"0"!=mxUtils.getValue(state.style,"nl2Br","1")&&(l=l.replace(/\n/g,"<br/>")),d.cellLabelChanged(state.cell,d.sanitizeHtml(l)),d.setCellStyles("html",a,[f[e]]))}b.fireEvent(new mxEventObject("styleChanged","keys",["html"],"values",[null!=a?a:"0"],"cells",f))}finally{d.getModel().endUpdate()}}});this.addAction("wordWrap",function(){var a=d.getView().getState(d.getSelectionCell()),f="wrap";d.stopEditing();null!=a&&"wrap"==a.style[mxConstants.STYLE_WHITE_SPACE]&&(f=null);d.setCellStyles(mxConstants.STYLE_WHITE_SPACE,
+[c]))}finally{d.getModel().endUpdate()}d.setSelectionCell(c);d.scrollCellToVisible(d.getSelectionCell())}})})).isEnabled=k;this.addAction("link...",mxUtils.bind(this,function(){var a=b.editor.graph;if(a.isEnabled())if(a.cellEditor.isContentEditing()){var f=a.getSelectedElement(),d=a.getParentByName(f,"A",a.cellEditor.textarea),e="";if(null==d&&null!=f&&null!=f.getElementsByTagName)for(var m=f.getElementsByTagName("a"),n=0;n<m.length&&null==d;n++)m[n].textContent==f.textContent&&(d=m[n]);null!=d&&
+"A"==d.nodeName&&(e=d.getAttribute("href")||"",a.selectNode(d));var l=a.cellEditor.saveSelection();b.showLinkDialog(e,mxResources.get("apply"),mxUtils.bind(this,function(c){a.cellEditor.restoreSelection(l);null!=c&&a.insertLink(c)}))}else a.isSelectionEmpty()?this.get("insertLink").funct():this.get("editLink").funct()})).isEnabled=k;this.addAction("autosize",function(){var a=d.getSelectionCells();if(null!=a){d.getModel().beginUpdate();try{for(var f=0;f<a.length;f++){var b=a[f];if(d.getModel().getChildCount(b))d.updateGroupBounds([b],
+20);else{var e=d.view.getState(b),m=d.getCellGeometry(b);d.getModel().isVertex(b)&&null!=e&&null!=e.text&&null!=m&&d.isWrapping(b)?(m=m.clone(),m.height=e.text.boundingBox.height/d.view.scale,d.getModel().setGeometry(b,m)):d.updateCellSize(b)}}}finally{d.getModel().endUpdate()}}},null,null,Editor.ctrlKey+"+Shift+Y");this.addAction("formattedText",function(){var a=d.getView().getState(d.getSelectionCell());if(null!=a){d.stopEditing();a="1"==a.style.html?null:"1";d.getModel().beginUpdate();try{for(var f=
+d.getSelectionCells(),e=0;e<f.length;e++)if(state=d.getView().getState(f[e]),null!=state){var p=mxUtils.getValue(state.style,"html","0");if("1"==p&&null==a){var m=d.convertValueToString(state.cell);"0"!=mxUtils.getValue(state.style,"nl2Br","1")&&(m=m.replace(/\n/g,"").replace(/<br\s*.?>/g,"\n"));var n=document.createElement("div");n.innerHTML=m;m=mxUtils.extractTextWithWhitespace(n.childNodes);d.cellLabelChanged(state.cell,m);d.setCellStyles("html",a,[f[e]])}else"0"==p&&"1"==a&&(m=mxUtils.htmlEntities(d.convertValueToString(state.cell),
+!1),"0"!=mxUtils.getValue(state.style,"nl2Br","1")&&(m=m.replace(/\n/g,"<br/>")),d.cellLabelChanged(state.cell,d.sanitizeHtml(m)),d.setCellStyles("html",a,[f[e]]))}b.fireEvent(new mxEventObject("styleChanged","keys",["html"],"values",[null!=a?a:"0"],"cells",f))}finally{d.getModel().endUpdate()}}});this.addAction("wordWrap",function(){var a=d.getView().getState(d.getSelectionCell()),f="wrap";d.stopEditing();null!=a&&"wrap"==a.style[mxConstants.STYLE_WHITE_SPACE]&&(f=null);d.setCellStyles(mxConstants.STYLE_WHITE_SPACE,
f)});this.addAction("rotation",function(){var a="0",f=d.getView().getState(d.getSelectionCell());null!=f&&(a=f.style[mxConstants.STYLE_ROTATION]||a);a=new FilenameDialog(b,a,mxResources.get("apply"),function(a){null!=a&&0<a.length&&d.setCellStyles(mxConstants.STYLE_ROTATION,a)},mxResources.get("enterValue")+" ("+mxResources.get("rotation")+" 0-360)");b.showDialog(a.container,375,80,!0,!0);a.init()});this.addAction("resetView",function(){d.zoomTo(1);b.resetScrollbars()},null,null,"Home");this.addAction("zoomIn",
function(a){d.isFastZoomEnabled()?d.lazyZoom(!0,!0,b.buttonZoomDelay):d.zoomIn()},null,null,Editor.ctrlKey+" + (Numpad) / Alt+Mousewheel");this.addAction("zoomOut",function(a){d.isFastZoomEnabled()?d.lazyZoom(!1,!0,b.buttonZoomDelay):d.zoomOut()},null,null,Editor.ctrlKey+" - (Numpad) / Alt+Mousewheel");this.addAction("fitWindow",function(){var a=d.isSelectionEmpty()?d.getGraphBounds():d.getBoundingBox(d.getSelectionCells()),f=d.view.translate,b=d.view.scale;a.width/=b;a.height/=b;a.x=a.x/b-f.x;a.y=
-a.y/b-f.y;var b=d.container.clientWidth-10,e=d.container.clientHeight-10,l=Math.floor(20*Math.min(b/a.width,e/a.height))/20;d.zoomTo(l);mxUtils.hasScrollbars(d.container)&&(d.container.scrollTop=(a.y+f.y)*l-Math.max((e-a.height*l)/2+5,0),d.container.scrollLeft=(a.x+f.x)*l-Math.max((b-a.width*l)/2+5,0))},null,null,Editor.ctrlKey+"+Shift+H");this.addAction("fitPage",mxUtils.bind(this,function(){d.pageVisible||this.get("pageView").funct();var a=d.pageFormat,f=d.pageScale;d.zoomTo(Math.floor(20*Math.min((d.container.clientWidth-
+a.y/b-f.y;var b=d.container.clientWidth-10,e=d.container.clientHeight-10,m=Math.floor(20*Math.min(b/a.width,e/a.height))/20;d.zoomTo(m);mxUtils.hasScrollbars(d.container)&&(d.container.scrollTop=(a.y+f.y)*m-Math.max((e-a.height*m)/2+5,0),d.container.scrollLeft=(a.x+f.x)*m-Math.max((b-a.width*m)/2+5,0))},null,null,Editor.ctrlKey+"+Shift+H");this.addAction("fitPage",mxUtils.bind(this,function(){d.pageVisible||this.get("pageView").funct();var a=d.pageFormat,f=d.pageScale;d.zoomTo(Math.floor(20*Math.min((d.container.clientWidth-
10)/a.width/f,(d.container.clientHeight-10)/a.height/f))/20);mxUtils.hasScrollbars(d.container)&&(a=d.getPagePadding(),d.container.scrollTop=a.y*d.view.scale-1,d.container.scrollLeft=Math.min(a.x*d.view.scale,(d.container.scrollWidth-d.container.clientWidth)/2)-1)}),null,null,Editor.ctrlKey+"+J");this.addAction("fitTwoPages",mxUtils.bind(this,function(){d.pageVisible||this.get("pageView").funct();var a=d.pageFormat,f=d.pageScale;d.zoomTo(Math.floor(20*Math.min((d.container.clientWidth-10)/(2*a.width)/
f,(d.container.clientHeight-10)/a.height/f))/20);mxUtils.hasScrollbars(d.container)&&(a=d.getPagePadding(),d.container.scrollTop=Math.min(a.y,(d.container.scrollHeight-d.container.clientHeight)/2),d.container.scrollLeft=Math.min(a.x,(d.container.scrollWidth-d.container.clientWidth)/2))}),null,null,Editor.ctrlKey+"+Shift+J");this.addAction("fitPageWidth",mxUtils.bind(this,function(){d.pageVisible||this.get("pageView").funct();d.zoomTo(Math.floor(20*(d.container.clientWidth-10)/d.pageFormat.width/d.pageScale)/
20);if(mxUtils.hasScrollbars(d.container)){var a=d.getPagePadding();d.container.scrollLeft=Math.min(a.x*d.view.scale,(d.container.scrollWidth-d.container.clientWidth)/2)}}));this.put("customZoom",new Action(mxResources.get("custom")+"...",mxUtils.bind(this,function(){var a=new FilenameDialog(this.editorUi,parseInt(100*d.getView().getScale()),mxResources.get("apply"),mxUtils.bind(this,function(a){a=parseInt(a);!isNaN(a)&&0<a&&d.zoomTo(a/100)}),mxResources.get("zoom")+" (%)");this.editorUi.showDialog(a.container,
-300,80,!0,!0);a.init()}),null,null,Editor.ctrlKey+"+0"));this.addAction("pageScale...",mxUtils.bind(this,function(){var a=new FilenameDialog(this.editorUi,parseInt(100*d.pageScale),mxResources.get("apply"),mxUtils.bind(this,function(a){a=parseInt(a);!isNaN(a)&&0<a&&(a=new ChangePageSetup(b,null,null,null,a/100),a.ignoreColor=!0,a.ignoreImage=!0,d.model.execute(a))}),mxResources.get("pageScale")+" (%)");this.editorUi.showDialog(a.container,300,80,!0,!0);a.init()}));var m=null,m=this.addAction("grid",
-function(){d.setGridEnabled(!d.isGridEnabled());b.fireEvent(new mxEventObject("gridEnabledChanged"))},null,null,Editor.ctrlKey+"+Shift+G");m.setToggleAction(!0);m.setSelectedCallback(function(){return d.isGridEnabled()});m.setEnabled(!1);m=this.addAction("guides",function(){d.graphHandler.guidesEnabled=!d.graphHandler.guidesEnabled;b.fireEvent(new mxEventObject("guidesEnabledChanged"))});m.setToggleAction(!0);m.setSelectedCallback(function(){return d.graphHandler.guidesEnabled});m.setEnabled(!1);
-m=this.addAction("tooltips",function(){d.tooltipHandler.setEnabled(!d.tooltipHandler.isEnabled())});m.setToggleAction(!0);m.setSelectedCallback(function(){return d.tooltipHandler.isEnabled()});m=this.addAction("collapseExpand",function(){var a=new ChangePageSetup(b);a.ignoreColor=!0;a.ignoreImage=!0;a.foldingEnabled=!d.foldingEnabled;d.model.execute(a)});m.setToggleAction(!0);m.setSelectedCallback(function(){return d.foldingEnabled});m.isEnabled=k;m=this.addAction("scrollbars",function(){b.setScrollbars(!b.hasScrollbars())});
-m.setToggleAction(!0);m.setSelectedCallback(function(){return d.scrollbars});m=this.addAction("pageView",mxUtils.bind(this,function(){b.setPageVisible(!d.pageVisible)}));m.setToggleAction(!0);m.setSelectedCallback(function(){return d.pageVisible});m=this.addAction("connectionArrows",function(){d.connectionArrowsEnabled=!d.connectionArrowsEnabled;b.fireEvent(new mxEventObject("connectionArrowsChanged"))},null,null,"Alt+Shift+A");m.setToggleAction(!0);m.setSelectedCallback(function(){return d.connectionArrowsEnabled});
-m=this.addAction("connectionPoints",function(){d.setConnectable(!d.connectionHandler.isEnabled());b.fireEvent(new mxEventObject("connectionPointsChanged"))},null,null,"Alt+Shift+P");m.setToggleAction(!0);m.setSelectedCallback(function(){return d.connectionHandler.isEnabled()});m=this.addAction("copyConnect",function(){d.connectionHandler.setCreateTarget(!d.connectionHandler.isCreateTarget());b.fireEvent(new mxEventObject("copyConnectChanged"))});m.setToggleAction(!0);m.setSelectedCallback(function(){return d.connectionHandler.isCreateTarget()});
-m.isEnabled=k;m=this.addAction("autosave",function(){b.editor.setAutosave(!b.editor.autosave)});m.setToggleAction(!0);m.setSelectedCallback(function(){return b.editor.autosave});m.isEnabled=k;m.visible=!1;this.addAction("help",function(){var a="";mxResources.isLanguageSupported(mxClient.language)&&(a="_"+mxClient.language);d.openLink(RESOURCES_PATH+"/help"+a+".html")});var q=!1;this.put("about",new Action(mxResources.get("about")+" Graph Editor...",function(){q||(b.showDialog((new AboutDialog(b)).container,
-320,280,!0,!0,function(){q=!1}),q=!0)}));m=mxUtils.bind(this,function(a,f,b,e){return this.addAction(a,function(){if(null!=b&&d.cellEditor.isContentEditing())b();else{d.stopEditing(!1);d.getModel().beginUpdate();try{var a=d.getSelectionCells();d.toggleCellStyleFlags(mxConstants.STYLE_FONTSTYLE,f,a);(f&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD?d.updateLabelElements(d.getSelectionCells(),function(a){a.style.fontWeight=null;"B"==a.nodeName&&d.replaceElement(a)}):(f&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC?
-d.updateLabelElements(d.getSelectionCells(),function(a){a.style.fontStyle=null;"I"==a.nodeName&&d.replaceElement(a)}):(f&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&d.updateLabelElements(d.getSelectionCells(),function(a){a.style.textDecoration=null;"U"==a.nodeName&&d.replaceElement(a)});for(var c=0;c<a.length;c++)0==d.model.getChildCount(a[c])&&d.autoSizeCell(a[c],!1)}finally{d.getModel().endUpdate()}}},null,null,e)});m("bold",mxConstants.FONT_BOLD,function(){document.execCommand("bold",
-!1,null)},Editor.ctrlKey+"+B");m("italic",mxConstants.FONT_ITALIC,function(){document.execCommand("italic",!1,null)},Editor.ctrlKey+"+I");m("underline",mxConstants.FONT_UNDERLINE,function(){document.execCommand("underline",!1,null)},Editor.ctrlKey+"+U");this.addAction("fontColor...",function(){b.menus.pickColor(mxConstants.STYLE_FONTCOLOR,"forecolor","000000")});this.addAction("strokeColor...",function(){b.menus.pickColor(mxConstants.STYLE_STROKECOLOR)});this.addAction("fillColor...",function(){b.menus.pickColor(mxConstants.STYLE_FILLCOLOR)});
+300,80,!0,!0);a.init()}),null,null,Editor.ctrlKey+"+0"));this.addAction("pageScale...",mxUtils.bind(this,function(){var a=new FilenameDialog(this.editorUi,parseInt(100*d.pageScale),mxResources.get("apply"),mxUtils.bind(this,function(a){a=parseInt(a);!isNaN(a)&&0<a&&(a=new ChangePageSetup(b,null,null,null,a/100),a.ignoreColor=!0,a.ignoreImage=!0,d.model.execute(a))}),mxResources.get("pageScale")+" (%)");this.editorUi.showDialog(a.container,300,80,!0,!0);a.init()}));var l=null,l=this.addAction("grid",
+function(){d.setGridEnabled(!d.isGridEnabled());b.fireEvent(new mxEventObject("gridEnabledChanged"))},null,null,Editor.ctrlKey+"+Shift+G");l.setToggleAction(!0);l.setSelectedCallback(function(){return d.isGridEnabled()});l.setEnabled(!1);l=this.addAction("guides",function(){d.graphHandler.guidesEnabled=!d.graphHandler.guidesEnabled;b.fireEvent(new mxEventObject("guidesEnabledChanged"))});l.setToggleAction(!0);l.setSelectedCallback(function(){return d.graphHandler.guidesEnabled});l.setEnabled(!1);
+l=this.addAction("tooltips",function(){d.tooltipHandler.setEnabled(!d.tooltipHandler.isEnabled())});l.setToggleAction(!0);l.setSelectedCallback(function(){return d.tooltipHandler.isEnabled()});l=this.addAction("collapseExpand",function(){var a=new ChangePageSetup(b);a.ignoreColor=!0;a.ignoreImage=!0;a.foldingEnabled=!d.foldingEnabled;d.model.execute(a)});l.setToggleAction(!0);l.setSelectedCallback(function(){return d.foldingEnabled});l.isEnabled=k;l=this.addAction("scrollbars",function(){b.setScrollbars(!b.hasScrollbars())});
+l.setToggleAction(!0);l.setSelectedCallback(function(){return d.scrollbars});l=this.addAction("pageView",mxUtils.bind(this,function(){b.setPageVisible(!d.pageVisible)}));l.setToggleAction(!0);l.setSelectedCallback(function(){return d.pageVisible});l=this.addAction("connectionArrows",function(){d.connectionArrowsEnabled=!d.connectionArrowsEnabled;b.fireEvent(new mxEventObject("connectionArrowsChanged"))},null,null,"Alt+Shift+A");l.setToggleAction(!0);l.setSelectedCallback(function(){return d.connectionArrowsEnabled});
+l=this.addAction("connectionPoints",function(){d.setConnectable(!d.connectionHandler.isEnabled());b.fireEvent(new mxEventObject("connectionPointsChanged"))},null,null,"Alt+Shift+P");l.setToggleAction(!0);l.setSelectedCallback(function(){return d.connectionHandler.isEnabled()});l=this.addAction("copyConnect",function(){d.connectionHandler.setCreateTarget(!d.connectionHandler.isCreateTarget());b.fireEvent(new mxEventObject("copyConnectChanged"))});l.setToggleAction(!0);l.setSelectedCallback(function(){return d.connectionHandler.isCreateTarget()});
+l.isEnabled=k;l=this.addAction("autosave",function(){b.editor.setAutosave(!b.editor.autosave)});l.setToggleAction(!0);l.setSelectedCallback(function(){return b.editor.autosave});l.isEnabled=k;l.visible=!1;this.addAction("help",function(){var a="";mxResources.isLanguageSupported(mxClient.language)&&(a="_"+mxClient.language);d.openLink(RESOURCES_PATH+"/help"+a+".html")});var q=!1;this.put("about",new Action(mxResources.get("about")+" Graph Editor...",function(){q||(b.showDialog((new AboutDialog(b)).container,
+320,280,!0,!0,function(){q=!1}),q=!0)}));l=mxUtils.bind(this,function(a,f,b,e){return this.addAction(a,function(){if(null!=b&&d.cellEditor.isContentEditing())b();else{d.stopEditing(!1);d.getModel().beginUpdate();try{var a=d.getSelectionCells();d.toggleCellStyleFlags(mxConstants.STYLE_FONTSTYLE,f,a);(f&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD?d.updateLabelElements(d.getSelectionCells(),function(a){a.style.fontWeight=null;"B"==a.nodeName&&d.replaceElement(a)}):(f&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC?
+d.updateLabelElements(d.getSelectionCells(),function(a){a.style.fontStyle=null;"I"==a.nodeName&&d.replaceElement(a)}):(f&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&d.updateLabelElements(d.getSelectionCells(),function(a){a.style.textDecoration=null;"U"==a.nodeName&&d.replaceElement(a)});for(var c=0;c<a.length;c++)0==d.model.getChildCount(a[c])&&d.autoSizeCell(a[c],!1)}finally{d.getModel().endUpdate()}}},null,null,e)});l("bold",mxConstants.FONT_BOLD,function(){document.execCommand("bold",
+!1,null)},Editor.ctrlKey+"+B");l("italic",mxConstants.FONT_ITALIC,function(){document.execCommand("italic",!1,null)},Editor.ctrlKey+"+I");l("underline",mxConstants.FONT_UNDERLINE,function(){document.execCommand("underline",!1,null)},Editor.ctrlKey+"+U");this.addAction("fontColor...",function(){b.menus.pickColor(mxConstants.STYLE_FONTCOLOR,"forecolor","000000")});this.addAction("strokeColor...",function(){b.menus.pickColor(mxConstants.STYLE_STROKECOLOR)});this.addAction("fillColor...",function(){b.menus.pickColor(mxConstants.STYLE_FILLCOLOR)});
this.addAction("gradientColor...",function(){b.menus.pickColor(mxConstants.STYLE_GRADIENTCOLOR)});this.addAction("backgroundColor...",function(){b.menus.pickColor(mxConstants.STYLE_LABEL_BACKGROUNDCOLOR,"backcolor")});this.addAction("borderColor...",function(){b.menus.pickColor(mxConstants.STYLE_LABEL_BORDERCOLOR)});this.addAction("vertical",function(){b.menus.toggleStyle(mxConstants.STYLE_HORIZONTAL,!0)});this.addAction("shadow",function(){b.menus.toggleStyle(mxConstants.STYLE_SHADOW)});this.addAction("solid",
function(){d.getModel().beginUpdate();try{d.setCellStyles(mxConstants.STYLE_DASHED,null),d.setCellStyles(mxConstants.STYLE_DASH_PATTERN,null),b.fireEvent(new mxEventObject("styleChanged","keys",[mxConstants.STYLE_DASHED,mxConstants.STYLE_DASH_PATTERN],"values",[null,null],"cells",d.getSelectionCells()))}finally{d.getModel().endUpdate()}});this.addAction("dashed",function(){d.getModel().beginUpdate();try{d.setCellStyles(mxConstants.STYLE_DASHED,"1"),d.setCellStyles(mxConstants.STYLE_DASH_PATTERN,null),
b.fireEvent(new mxEventObject("styleChanged","keys",[mxConstants.STYLE_DASHED,mxConstants.STYLE_DASH_PATTERN],"values",["1",null],"cells",d.getSelectionCells()))}finally{d.getModel().endUpdate()}});this.addAction("dotted",function(){d.getModel().beginUpdate();try{d.setCellStyles(mxConstants.STYLE_DASHED,"1"),d.setCellStyles(mxConstants.STYLE_DASH_PATTERN,"1 4"),b.fireEvent(new mxEventObject("styleChanged","keys",[mxConstants.STYLE_DASHED,mxConstants.STYLE_DASH_PATTERN],"values",["1","1 4"],"cells",
@@ -2792,41 +2792,41 @@ d.getSelectionCells()))}finally{d.getModel().endUpdate()}});this.addAction("shar
e);d.setCellStyles(mxConstants.STYLE_CURVED,null);b.fireEvent(new mxEventObject("styleChanged","keys",[mxConstants.STYLE_ROUNDED,mxConstants.STYLE_CURVED],"values",[e,"0"],"cells",d.getSelectionCells()))}finally{d.getModel().endUpdate()}}});this.addAction("curved",function(){d.getModel().beginUpdate();try{d.setCellStyles(mxConstants.STYLE_ROUNDED,"0"),d.setCellStyles(mxConstants.STYLE_CURVED,"1"),b.fireEvent(new mxEventObject("styleChanged","keys",[mxConstants.STYLE_ROUNDED,mxConstants.STYLE_CURVED],
"values",["0","1"],"cells",d.getSelectionCells()))}finally{d.getModel().endUpdate()}});this.addAction("collapsible",function(){var a=d.view.getState(d.getSelectionCell()),f="1";null!=a&&null!=d.getFoldingImage(a)&&(f="0");d.setCellStyles("collapsible",f);b.fireEvent(new mxEventObject("styleChanged","keys",["collapsible"],"values",[f],"cells",d.getSelectionCells()))});this.addAction("editStyle...",mxUtils.bind(this,function(){var a=d.getSelectionCells();if(null!=a&&0<a.length){var f=d.getModel(),f=
new TextareaDialog(this.editorUi,mxResources.get("editStyle")+":",f.getStyle(a[0])||"",function(c){null!=c&&d.setCellStyle(mxUtils.trim(c),a)},null,null,400,220);this.editorUi.showDialog(f.container,420,300,!0,!0);f.init()}}),null,null,Editor.ctrlKey+"+E");this.addAction("setAsDefaultStyle",function(){d.isEnabled()&&!d.isSelectionEmpty()&&b.setDefaultStyle(d.getSelectionCell())},null,null,Editor.ctrlKey+"+Shift+D");this.addAction("clearDefaultStyle",function(){d.isEnabled()&&b.clearDefaultStyle()},
-null,null,Editor.ctrlKey+"+Shift+R");this.addAction("addWaypoint",function(){var a=d.getSelectionCell();if(null!=a&&d.getModel().isEdge(a)){var f=e.graph.selectionCellsHandler.getHandler(a);if(f instanceof mxEdgeHandler){for(var b=d.view.translate,p=d.view.scale,l=b.x,b=b.y,a=d.getModel().getParent(a),n=d.getCellGeometry(a);d.getModel().isVertex(a)&&null!=n;)l+=n.x,b+=n.y,a=d.getModel().getParent(a),n=d.getCellGeometry(a);l=Math.round(d.snap(d.popupMenuHandler.triggerX/p-l));p=Math.round(d.snap(d.popupMenuHandler.triggerY/
-p-b));f.addPointAt(f.state,l,p)}}});this.addAction("removeWaypoint",function(){var a=b.actions.get("removeWaypoint");null!=a.handler&&a.handler.removePoint(a.handler.state,a.index)});this.addAction("clearWaypoints",function(){var a=d.getSelectionCells();if(null!=a){a=d.addAllEdges(a);d.getModel().beginUpdate();try{for(var f=0;f<a.length;f++){var b=a[f];if(d.getModel().isEdge(b)){var e=d.getCellGeometry(b);null!=e&&(e=e.clone(),e.points=null,d.getModel().setGeometry(b,e))}}}finally{d.getModel().endUpdate()}}},
-null,null,"Alt+Shift+C");m=this.addAction("subscript",mxUtils.bind(this,function(){d.cellEditor.isContentEditing()&&document.execCommand("subscript",!1,null)}),null,null,Editor.ctrlKey+"+,");m=this.addAction("superscript",mxUtils.bind(this,function(){d.cellEditor.isContentEditing()&&document.execCommand("superscript",!1,null)}),null,null,Editor.ctrlKey+"+.");m=this.addAction("indent",mxUtils.bind(this,function(){d.cellEditor.isContentEditing()&&document.execCommand("indent",!1,null)}),null,null,"Shift+Tab");
+null,null,Editor.ctrlKey+"+Shift+R");this.addAction("addWaypoint",function(){var a=d.getSelectionCell();if(null!=a&&d.getModel().isEdge(a)){var f=e.graph.selectionCellsHandler.getHandler(a);if(f instanceof mxEdgeHandler){for(var b=d.view.translate,p=d.view.scale,m=b.x,b=b.y,a=d.getModel().getParent(a),n=d.getCellGeometry(a);d.getModel().isVertex(a)&&null!=n;)m+=n.x,b+=n.y,a=d.getModel().getParent(a),n=d.getCellGeometry(a);m=Math.round(d.snap(d.popupMenuHandler.triggerX/p-m));p=Math.round(d.snap(d.popupMenuHandler.triggerY/
+p-b));f.addPointAt(f.state,m,p)}}});this.addAction("removeWaypoint",function(){var a=b.actions.get("removeWaypoint");null!=a.handler&&a.handler.removePoint(a.handler.state,a.index)});this.addAction("clearWaypoints",function(){var a=d.getSelectionCells();if(null!=a){a=d.addAllEdges(a);d.getModel().beginUpdate();try{for(var b=0;b<a.length;b++){var e=a[b];if(d.getModel().isEdge(e)){var p=d.getCellGeometry(e);null!=p&&(p=p.clone(),p.points=null,d.getModel().setGeometry(e,p))}}}finally{d.getModel().endUpdate()}}},
+null,null,"Alt+Shift+C");l=this.addAction("subscript",mxUtils.bind(this,function(){d.cellEditor.isContentEditing()&&document.execCommand("subscript",!1,null)}),null,null,Editor.ctrlKey+"+,");l=this.addAction("superscript",mxUtils.bind(this,function(){d.cellEditor.isContentEditing()&&document.execCommand("superscript",!1,null)}),null,null,Editor.ctrlKey+"+.");l=this.addAction("indent",mxUtils.bind(this,function(){d.cellEditor.isContentEditing()&&document.execCommand("indent",!1,null)}),null,null,"Shift+Tab");
this.addAction("image...",function(){if(d.isEnabled()&&!d.isCellLocked(d.getDefaultParent())){var a=mxResources.get("image")+" ("+mxResources.get("url")+"):",f=d.getView().getState(d.getSelectionCell()),e="";null!=f&&(e=f.style[mxConstants.STYLE_IMAGE]||e);var p=d.cellEditor.saveSelection();b.showImageDialog(a,e,function(a,c,b){if(d.cellEditor.isContentEditing())d.cellEditor.restoreSelection(p),d.insertImage(a,c,b);else{var f=d.getSelectionCells();if(null!=a&&(0<a.length||0<f.length)){var e=null;
-d.getModel().beginUpdate();try{if(0==f.length){var g=d.getFreeInsertPoint(),e=f=[d.insertVertex(d.getDefaultParent(),null,"",g.x,g.y,c,b,"shape=image;imageAspect=0;aspect=fixed;verticalLabelPosition=bottom;verticalAlign=top;")];d.fireEvent(new mxEventObject("cellsInserted","cells",e))}d.setCellStyles(mxConstants.STYLE_IMAGE,0<a.length?a:null,f);var l=d.getCurrentCellStyle(f[0]);"image"!=l[mxConstants.STYLE_SHAPE]&&"label"!=l[mxConstants.STYLE_SHAPE]?d.setCellStyles(mxConstants.STYLE_SHAPE,"image",
-f):0==a.length&&d.setCellStyles(mxConstants.STYLE_SHAPE,null,f);if(1==d.getSelectionCount()&&null!=c&&null!=b){var n=f[0],v=d.getModel().getGeometry(n);null!=v&&(v=v.clone(),v.width=c,v.height=b,d.getModel().setGeometry(n,v))}}finally{d.getModel().endUpdate()}null!=e&&(d.setSelectionCells(e),d.scrollCellToVisible(e[0]))}}},d.cellEditor.isContentEditing(),!d.cellEditor.isContentEditing())}}).isEnabled=k;m=this.addAction("layers",mxUtils.bind(this,function(){null==this.layersWindow?(this.layersWindow=
-new LayersWindow(b,document.body.offsetWidth-280,120,220,196),this.layersWindow.window.addListener("show",function(){b.fireEvent(new mxEventObject("layers"))}),this.layersWindow.window.addListener("hide",function(){b.fireEvent(new mxEventObject("layers"))}),this.layersWindow.window.setVisible(!0),b.fireEvent(new mxEventObject("layers")),this.layersWindow.init()):this.layersWindow.window.setVisible(!this.layersWindow.window.isVisible())}),null,null,Editor.ctrlKey+"+Shift+L");m.setToggleAction(!0);
-m.setSelectedCallback(mxUtils.bind(this,function(){return null!=this.layersWindow&&this.layersWindow.window.isVisible()}));m=this.addAction("formatPanel",mxUtils.bind(this,function(){b.toggleFormatPanel()}),null,null,Editor.ctrlKey+"+Shift+P");m.setToggleAction(!0);m.setSelectedCallback(mxUtils.bind(this,function(){return 0<b.formatWidth}));m=this.addAction("outline",mxUtils.bind(this,function(){null==this.outlineWindow?(this.outlineWindow=new OutlineWindow(b,document.body.offsetWidth-260,100,180,
-180),this.outlineWindow.window.addListener("show",function(){b.fireEvent(new mxEventObject("outline"))}),this.outlineWindow.window.addListener("hide",function(){b.fireEvent(new mxEventObject("outline"))}),this.outlineWindow.window.setVisible(!0),b.fireEvent(new mxEventObject("outline"))):this.outlineWindow.window.setVisible(!this.outlineWindow.window.isVisible())}),null,null,Editor.ctrlKey+"+Shift+O");m.setToggleAction(!0);m.setSelectedCallback(mxUtils.bind(this,function(){return null!=this.outlineWindow&&
-this.outlineWindow.window.isVisible()}))};Actions.prototype.addAction=function(a,b,e,d,k){var m;"..."==a.substring(a.length-3)?(a=a.substring(0,a.length-3),m=mxResources.get(a)+"..."):m=mxResources.get(a);return this.put(a,new Action(m,b,e,d,k))};Actions.prototype.put=function(a,b){return this.actions[a]=b};Actions.prototype.get=function(a){return this.actions[a]};
+d.getModel().beginUpdate();try{if(0==f.length){var g=d.getFreeInsertPoint(),e=f=[d.insertVertex(d.getDefaultParent(),null,"",g.x,g.y,c,b,"shape=image;imageAspect=0;aspect=fixed;verticalLabelPosition=bottom;verticalAlign=top;")];d.fireEvent(new mxEventObject("cellsInserted","cells",e))}d.setCellStyles(mxConstants.STYLE_IMAGE,0<a.length?a:null,f);var m=d.getCurrentCellStyle(f[0]);"image"!=m[mxConstants.STYLE_SHAPE]&&"label"!=m[mxConstants.STYLE_SHAPE]?d.setCellStyles(mxConstants.STYLE_SHAPE,"image",
+f):0==a.length&&d.setCellStyles(mxConstants.STYLE_SHAPE,null,f);if(1==d.getSelectionCount()&&null!=c&&null!=b){var n=f[0],l=d.getModel().getGeometry(n);null!=l&&(l=l.clone(),l.width=c,l.height=b,d.getModel().setGeometry(n,l))}}finally{d.getModel().endUpdate()}null!=e&&(d.setSelectionCells(e),d.scrollCellToVisible(e[0]))}}},d.cellEditor.isContentEditing(),!d.cellEditor.isContentEditing())}}).isEnabled=k;l=this.addAction("layers",mxUtils.bind(this,function(){null==this.layersWindow?(this.layersWindow=
+new LayersWindow(b,document.body.offsetWidth-280,120,220,196),this.layersWindow.window.addListener("show",function(){b.fireEvent(new mxEventObject("layers"))}),this.layersWindow.window.addListener("hide",function(){b.fireEvent(new mxEventObject("layers"))}),this.layersWindow.window.setVisible(!0),b.fireEvent(new mxEventObject("layers")),this.layersWindow.init()):this.layersWindow.window.setVisible(!this.layersWindow.window.isVisible())}),null,null,Editor.ctrlKey+"+Shift+L");l.setToggleAction(!0);
+l.setSelectedCallback(mxUtils.bind(this,function(){return null!=this.layersWindow&&this.layersWindow.window.isVisible()}));l=this.addAction("formatPanel",mxUtils.bind(this,function(){b.toggleFormatPanel()}),null,null,Editor.ctrlKey+"+Shift+P");l.setToggleAction(!0);l.setSelectedCallback(mxUtils.bind(this,function(){return 0<b.formatWidth}));l=this.addAction("outline",mxUtils.bind(this,function(){null==this.outlineWindow?(this.outlineWindow=new OutlineWindow(b,document.body.offsetWidth-260,100,180,
+180),this.outlineWindow.window.addListener("show",function(){b.fireEvent(new mxEventObject("outline"))}),this.outlineWindow.window.addListener("hide",function(){b.fireEvent(new mxEventObject("outline"))}),this.outlineWindow.window.setVisible(!0),b.fireEvent(new mxEventObject("outline"))):this.outlineWindow.window.setVisible(!this.outlineWindow.window.isVisible())}),null,null,Editor.ctrlKey+"+Shift+O");l.setToggleAction(!0);l.setSelectedCallback(mxUtils.bind(this,function(){return null!=this.outlineWindow&&
+this.outlineWindow.window.isVisible()}))};Actions.prototype.addAction=function(a,b,e,d,k){var l;"..."==a.substring(a.length-3)?(a=a.substring(0,a.length-3),l=mxResources.get(a)+"..."):l=mxResources.get(a);return this.put(a,new Action(l,b,e,d,k))};Actions.prototype.put=function(a,b){return this.actions[a]=b};Actions.prototype.get=function(a){return this.actions[a]};
function Action(a,b,e,d,k){mxEventSource.call(this);this.label=a;this.funct=this.createFunction(b);this.enabled=null!=e?e:!0;this.iconCls=d;this.shortcut=k;this.visible=!0}mxUtils.extend(Action,mxEventSource);Action.prototype.createFunction=function(a){return a};Action.prototype.setEnabled=function(a){this.enabled!=a&&(this.enabled=a,this.fireEvent(new mxEventObject("stateChanged")))};Action.prototype.isEnabled=function(){return this.enabled};
Action.prototype.setToggleAction=function(a){this.toggleAction=a};Action.prototype.setSelectedCallback=function(a){this.selectedCallback=a};Action.prototype.isSelected=function(){return this.selectedCallback()};DrawioFile=function(a,b){mxEventSource.call(this);this.ui=a;this.shadowData=this.data=b||"";this.shadowPages=null;this.created=(new Date).getTime();this.stats={opened:0,merged:0,fileMerged:0,fileReloaded:0,conflicts:0,timeouts:0,saved:0,closed:0,destroyed:0,joined:0,checksumErrors:0,bytesSent:0,bytesReceived:0,msgSent:0,msgReceived:0,cacheHits:0,cacheMiss:0,cacheFail:0}};DrawioFile.SYNC=urlParams.sync||"auto";DrawioFile.LAST_WRITE_WINS=!0;mxUtils.extend(DrawioFile,mxEventSource);
DrawioFile.prototype.allChangesSavedKey="allChangesSaved";DrawioFile.prototype.autosaveDelay=1500;DrawioFile.prototype.maxAutosaveDelay=3E4;DrawioFile.prototype.autosaveThread=null;DrawioFile.prototype.lastAutosave=null;DrawioFile.prototype.lastSaved=null;DrawioFile.prototype.lastChanged=null;DrawioFile.prototype.opened=null;DrawioFile.prototype.modified=!1;DrawioFile.prototype.data=null;DrawioFile.prototype.shadowData=null;DrawioFile.prototype.shadowPages=null;
DrawioFile.prototype.changeListenerEnabled=!0;DrawioFile.prototype.lastAutosaveRevision=null;DrawioFile.prototype.maxAutosaveRevisionDelay=3E5;DrawioFile.prototype.inConflictState=!1;DrawioFile.prototype.invalidChecksum=!1;DrawioFile.prototype.errorReportsEnabled=!1;DrawioFile.prototype.reportEnabled=!0;DrawioFile.prototype.ageStart=null;DrawioFile.prototype.getSize=function(){return null!=this.data?this.data.length:0};
DrawioFile.prototype.synchronizeFile=function(a,b){this.savingFile?null!=b&&b({message:mxResources.get("busy")}):null!=this.sync?this.sync.fileChanged(a,b):this.updateFile(a,b)};
-DrawioFile.prototype.updateFile=function(a,b,e,d){null!=e&&e()||(this.ui.getCurrentFile()!=this||this.invalidChecksum?null!=b&&b():this.getLatestVersion(mxUtils.bind(this,function(k){try{null!=e&&e()||(this.ui.getCurrentFile()!=this||this.invalidChecksum?null!=b&&b():null!=k?this.mergeFile(k,a,b,d):this.reloadFile(a,b))}catch(m){null!=b&&b(m)}}),b))};
-DrawioFile.prototype.mergeFile=function(a,b,e,d){var k=!0;try{this.stats.fileMerged++;var m=null!=this.shadowPages?this.shadowPages:this.ui.getPagesForNode(mxUtils.parseXml(this.shadowData).documentElement),q=this.ui.getPagesForNode(mxUtils.parseXml(a.data).documentElement);if(null!=q&&0<q.length){this.shadowPages=q;this.backupPatch=this.isModified()?this.ui.diffPages(m,this.ui.pages):null;var c=[this.ui.diffPages(null!=d?d:m,this.shadowPages)];if(!this.ignorePatches(c)){var f=this.ui.patchPages(m,
-c[0]);d={};var g=this.ui.getHashValueForPages(f,d),m={},p=this.ui.getHashValueForPages(this.shadowPages,m);"1"==urlParams.test&&EditorUi.debug("File.mergeFile",[this],"backup",this.backupPatch,"patches",c,"checksum",p==g,g);if(null!=g&&g!=p){var l=this.compressReportData(this.getAnonymizedXmlForPages(q)),n=this.compressReportData(this.getAnonymizedXmlForPages(f)),v=this.ui.hashValue(a.getCurrentEtag()),t=this.ui.hashValue(this.getCurrentEtag());this.checksumError(e,c,"Shadow Details: "+JSON.stringify(d)+
-"\nChecksum: "+g+"\nCurrent: "+p+"\nCurrent Details: "+JSON.stringify(m)+"\nFrom: "+v+"\nTo: "+t+"\n\nFile Data:\n"+l+"\nPatched Shadow:\n"+n,null,"mergeFile");return}this.patch(c,DrawioFile.LAST_WRITE_WINS?this.backupPatch:null)}}else throw k=!1,Error(mxResources.get("notADiagramFile"));this.inConflictState=this.invalidChecksum=!1;this.setDescriptor(a.getDescriptor());this.descriptorChanged();this.backupPatch=null;null!=b&&b()}catch(B){this.invalidChecksum=this.inConflictState=!0;this.descriptorChanged();
+DrawioFile.prototype.updateFile=function(a,b,e,d){null!=e&&e()||(this.ui.getCurrentFile()!=this||this.invalidChecksum?null!=b&&b():this.getLatestVersion(mxUtils.bind(this,function(k){try{null!=e&&e()||(this.ui.getCurrentFile()!=this||this.invalidChecksum?null!=b&&b():null!=k?this.mergeFile(k,a,b,d):this.reloadFile(a,b))}catch(l){null!=b&&b(l)}}),b))};
+DrawioFile.prototype.mergeFile=function(a,b,e,d){var k=!0;try{this.stats.fileMerged++;var l=null!=this.shadowPages?this.shadowPages:this.ui.getPagesForNode(mxUtils.parseXml(this.shadowData).documentElement),q=this.ui.getPagesForNode(mxUtils.parseXml(a.data).documentElement);if(null!=q&&0<q.length){this.shadowPages=q;this.backupPatch=this.isModified()?this.ui.diffPages(l,this.ui.pages):null;var c=[this.ui.diffPages(null!=d?d:l,this.shadowPages)];if(!this.ignorePatches(c)){var f=this.ui.patchPages(l,
+c[0]);d={};var g=this.ui.getHashValueForPages(f,d),l={},p=this.ui.getHashValueForPages(this.shadowPages,l);"1"==urlParams.test&&EditorUi.debug("File.mergeFile",[this],"backup",this.backupPatch,"patches",c,"checksum",p==g,g);if(null!=g&&g!=p){var m=this.compressReportData(this.getAnonymizedXmlForPages(q)),n=this.compressReportData(this.getAnonymizedXmlForPages(f)),v=this.ui.hashValue(a.getCurrentEtag()),t=this.ui.hashValue(this.getCurrentEtag());this.checksumError(e,c,"Shadow Details: "+JSON.stringify(d)+
+"\nChecksum: "+g+"\nCurrent: "+p+"\nCurrent Details: "+JSON.stringify(l)+"\nFrom: "+v+"\nTo: "+t+"\n\nFile Data:\n"+m+"\nPatched Shadow:\n"+n,null,"mergeFile");return}this.patch(c,DrawioFile.LAST_WRITE_WINS?this.backupPatch:null)}}else throw k=!1,Error(mxResources.get("notADiagramFile"));this.inConflictState=this.invalidChecksum=!1;this.setDescriptor(a.getDescriptor());this.descriptorChanged();this.backupPatch=null;null!=b&&b()}catch(B){this.invalidChecksum=this.inConflictState=!0;this.descriptorChanged();
null!=e&&e(B);try{if(k)if(this.errorReportsEnabled)this.sendErrorReport("Error in mergeFile",null,B);else{var u=this.getCurrentUser(),A=null!=u?u.id:"unknown";EditorUi.logError("Error in mergeFile",null,this.getMode()+"."+this.getId(),A,B)}}catch(D){}}};
DrawioFile.prototype.getAnonymizedXmlForPages=function(a){var b=new mxCodec(mxUtils.createXmlDocument()),e=b.document.createElement("mxfile");if(null!=a)for(var d=0;d<a.length;d++){var k=b.encode(new mxGraphModel(a[d].root));"1"!=urlParams.dev&&(k=this.ui.anonymizeNode(k,!0));k.setAttribute("id",a[d].getId());a[d].viewState&&this.ui.editor.graph.saveViewState(a[d].viewState,k,!0);e.appendChild(k)}return mxUtils.getPrettyXml(e)};
DrawioFile.prototype.compressReportData=function(a,b,e){b=null!=b?b:1E4;null!=e&&null!=a&&a.length>e?a=a.substring(0,e)+"[...]":null!=a&&a.length>b&&(a=Graph.compress(a)+"\n");return a};
-DrawioFile.prototype.checksumError=function(a,b,e,d,k){this.stats.checksumErrors++;this.invalidChecksum=this.inConflictState=!0;this.descriptorChanged();null!=this.sync&&this.sync.updateOnlineState();null!=a&&a();try{if(this.errorReportsEnabled){if(null!=b)for(a=0;a<b.length;a++)this.ui.anonymizePatch(b[a]);var m=mxUtils.bind(this,function(a){var c=this.compressReportData(JSON.stringify(b,null,2));a=null!=a?this.compressReportData(this.getAnonymizedXmlForPages(this.ui.getPagesForNode(mxUtils.parseXml(a.data).documentElement)),
-25E3):"n/a";this.sendErrorReport("Checksum Error in "+k+" "+this.getHash(),(null!=e?e:"")+"\n\nPatches:\n"+c+(null!=a?"\n\nRemote:\n"+a:""),null,7E4)});null==d?m(null):this.getLatestVersion(mxUtils.bind(this,function(a){null!=a&&a.getCurrentEtag()==d?m(a):m(null)}),function(){})}else{var q=this.getCurrentUser(),c=null!=q?q.id:"unknown";EditorUi.logError("Checksum Error in "+k+" "+this.getId(),null,this.getMode()+"."+this.getId(),"user_"+c+(null!=this.sync?"-client_"+this.sync.clientId:"-nosync"));
+DrawioFile.prototype.checksumError=function(a,b,e,d,k){this.stats.checksumErrors++;this.invalidChecksum=this.inConflictState=!0;this.descriptorChanged();null!=this.sync&&this.sync.updateOnlineState();null!=a&&a();try{if(this.errorReportsEnabled){if(null!=b)for(a=0;a<b.length;a++)this.ui.anonymizePatch(b[a]);var l=mxUtils.bind(this,function(a){var c=this.compressReportData(JSON.stringify(b,null,2));a=null!=a?this.compressReportData(this.getAnonymizedXmlForPages(this.ui.getPagesForNode(mxUtils.parseXml(a.data).documentElement)),
+25E3):"n/a";this.sendErrorReport("Checksum Error in "+k+" "+this.getHash(),(null!=e?e:"")+"\n\nPatches:\n"+c+(null!=a?"\n\nRemote:\n"+a:""),null,7E4)});null==d?l(null):this.getLatestVersion(mxUtils.bind(this,function(a){null!=a&&a.getCurrentEtag()==d?l(a):l(null)}),function(){})}else{var q=this.getCurrentUser(),c=null!=q?q.id:"unknown";EditorUi.logError("Checksum Error in "+k+" "+this.getId(),null,this.getMode()+"."+this.getId(),"user_"+c+(null!=this.sync?"-client_"+this.sync.clientId:"-nosync"));
try{EditorUi.logEvent({category:"CHECKSUM-ERROR-SYNC-FILE-"+this.getHash(),action:k,label:"user_"+c+(null!=this.sync?"-client_"+this.sync.clientId:"-nosync")})}catch(f){}}}catch(f){}};
-DrawioFile.prototype.sendErrorReport=function(a,b,e,d){try{var k=this.compressReportData(this.getAnonymizedXmlForPages(this.shadowPages),25E3),m=this.compressReportData(this.getAnonymizedXmlForPages(this.ui.pages),25E3),q=this.getCurrentUser(),c=null!=q?this.ui.hashValue(q.id):"unknown",f=null!=this.sync?"-client_"+this.sync.clientId:"-nosync",g=this.getTitle(),p=g.lastIndexOf("."),q="xml";0<p&&(q=g.substring(p));var l=null!=e?e.stack:Error().stack;EditorUi.sendReport(a+" "+(new Date).toISOString()+
+DrawioFile.prototype.sendErrorReport=function(a,b,e,d){try{var k=this.compressReportData(this.getAnonymizedXmlForPages(this.shadowPages),25E3),l=this.compressReportData(this.getAnonymizedXmlForPages(this.ui.pages),25E3),q=this.getCurrentUser(),c=null!=q?this.ui.hashValue(q.id):"unknown",f=null!=this.sync?"-client_"+this.sync.clientId:"-nosync",g=this.getTitle(),p=g.lastIndexOf("."),q="xml";0<p&&(q=g.substring(p));var m=null!=e?e.stack:Error().stack;EditorUi.sendReport(a+" "+(new Date).toISOString()+
":\n\nAppVersion="+navigator.appVersion+"\nFile="+this.ui.hashValue(this.getId())+" ("+this.getMode()+")"+(this.isModified()?" modified":"")+"\nSize/Type="+this.getSize()+" ("+q+")\nUser="+c+f+"\nPrefix="+this.ui.editor.graph.model.prefix+"\nSync="+DrawioFile.SYNC+(null!=this.sync?(this.sync.enabled?" enabled":"")+(this.sync.isConnected()?" connected":""):"")+"\nPlugins="+(null!=mxSettings.settings?mxSettings.getPlugins():"null")+"\n\nStats:\n"+JSON.stringify(this.stats,null,2)+(null!=b?"\n\n"+b:
-"")+(null!=e?"\n\nError: "+e.message:"")+"\n\nStack:\n"+l+"\n\nShadow:\n"+k+"\n\nData:\n"+m,d)}catch(n){}};
-DrawioFile.prototype.reloadFile=function(a,b){try{this.ui.spinner.stop();var e=mxUtils.bind(this,function(){this.stats.fileReloaded++;this.reportEnabled=!1;var b=this.ui.editor.graph.getViewState(),e=this.ui.editor.graph.getSelectionCells(),m=this.ui.currentPage;this.ui.loadFile(this.getHash(),!0,null,mxUtils.bind(this,function(){if(null==this.ui.fileLoadedError){this.ui.restoreViewState(m,b,e);null!=this.backupPatch&&this.patch([this.backupPatch]);var d=this.ui.getCurrentFile();null!=d&&(d.stats=
+"")+(null!=e?"\n\nError: "+e.message:"")+"\n\nStack:\n"+m+"\n\nShadow:\n"+k+"\n\nData:\n"+l,d)}catch(n){}};
+DrawioFile.prototype.reloadFile=function(a,b){try{this.ui.spinner.stop();var e=mxUtils.bind(this,function(){this.stats.fileReloaded++;this.reportEnabled=!1;var b=this.ui.editor.graph.getViewState(),e=this.ui.editor.graph.getSelectionCells(),l=this.ui.currentPage;this.ui.loadFile(this.getHash(),!0,null,mxUtils.bind(this,function(){if(null==this.ui.fileLoadedError){this.ui.restoreViewState(l,b,e);null!=this.backupPatch&&this.patch([this.backupPatch]);var d=this.ui.getCurrentFile();null!=d&&(d.stats=
this.stats);null!=a&&a()}}),!0)});this.isModified()&&null==this.backupPatch?this.ui.confirm(mxResources.get("allChangesLost"),mxUtils.bind(this,function(){this.handleFileSuccess("manual"==DrawioFile.SYNC)}),e,mxResources.get("cancel"),mxResources.get("discardChanges")):e()}catch(d){null!=b&&b(d)}};DrawioFile.prototype.copyFile=function(a,b){this.ui.editor.editAsNew(this.ui.getFileData(!0),this.ui.getCopyFilename(this))};
DrawioFile.prototype.ignorePatches=function(a){for(var b=!0,e=0;e<a.length&&b;e++)b=b&&0==Object.keys(a[e]).length;return b};
-DrawioFile.prototype.patch=function(a,b){var e=this.ui.editor.undoManager,d=e.history.slice(),k=e.indexOfNextAdd,m=this.ui.editor.graph;m.container.style.visibility="hidden";var q=this.changeListenerEnabled;this.changeListenerEnabled=!1;var c=m.foldingEnabled,f=m.mathEnabled,g=m.cellRenderer.redraw;m.cellRenderer.redraw=function(a){a.view.graph.isEditing(a.cell)&&(a.view.graph.scrollCellToVisible(a.cell),a.view.graph.cellEditor.resize());g.apply(this,arguments)};m.model.beginUpdate();try{for(var p=
-0;p<a.length;p++)this.ui.pages=this.ui.patchPages(this.ui.pages,a[p],!0,b,this.isModified());0==this.ui.pages.length&&this.ui.pages.push(this.ui.createPage());0>mxUtils.indexOf(this.ui.pages,this.ui.currentPage)&&this.ui.selectPage(this.ui.pages[0],!0)}finally{m.container.style.visibility="";m.model.endUpdate();m.cellRenderer.redraw=g;this.changeListenerEnabled=q;e.history=d;e.indexOfNextAdd=k;e.fireEvent(new mxEventObject(mxEvent.CLEAR));if(null==this.ui.currentPage||this.ui.currentPage.needsUpdate)f!=
-m.mathEnabled?(this.ui.editor.updateGraphComponents(),m.refresh()):(c!=m.foldingEnabled?m.view.revalidate():m.view.validate(),m.sizeDidChange());this.ui.updateTabContainer()}};
-DrawioFile.prototype.save=function(a,b,e,d,k,m){try{if(this.isEditable())if(!k&&this.invalidChecksum)if(null!=e)e({message:mxResources.get("checksum")});else throw Error(mxResources.get("checksum"));else this.updateFileData(),this.clearAutosave(),null!=b&&b();else if(null!=e)e({message:mxResources.get("readOnly")});else throw Error(mxResources.get("readOnly"));}catch(q){if(null!=e)e(q);else throw q;}};
+DrawioFile.prototype.patch=function(a,b){var e=this.ui.editor.undoManager,d=e.history.slice(),k=e.indexOfNextAdd,l=this.ui.editor.graph;l.container.style.visibility="hidden";var q=this.changeListenerEnabled;this.changeListenerEnabled=!1;var c=l.foldingEnabled,f=l.mathEnabled,g=l.cellRenderer.redraw;l.cellRenderer.redraw=function(a){a.view.graph.isEditing(a.cell)&&(a.view.graph.scrollCellToVisible(a.cell),a.view.graph.cellEditor.resize());g.apply(this,arguments)};l.model.beginUpdate();try{for(var p=
+0;p<a.length;p++)this.ui.pages=this.ui.patchPages(this.ui.pages,a[p],!0,b,this.isModified());0==this.ui.pages.length&&this.ui.pages.push(this.ui.createPage());0>mxUtils.indexOf(this.ui.pages,this.ui.currentPage)&&this.ui.selectPage(this.ui.pages[0],!0)}finally{l.container.style.visibility="";l.model.endUpdate();l.cellRenderer.redraw=g;this.changeListenerEnabled=q;e.history=d;e.indexOfNextAdd=k;e.fireEvent(new mxEventObject(mxEvent.CLEAR));if(null==this.ui.currentPage||this.ui.currentPage.needsUpdate)f!=
+l.mathEnabled?(this.ui.editor.updateGraphComponents(),l.refresh()):(c!=l.foldingEnabled?l.view.revalidate():l.view.validate(),l.sizeDidChange());this.ui.updateTabContainer()}};
+DrawioFile.prototype.save=function(a,b,e,d,k,l){try{if(this.isEditable())if(!k&&this.invalidChecksum)if(null!=e)e({message:mxResources.get("checksum")});else throw Error(mxResources.get("checksum"));else this.updateFileData(),this.clearAutosave(),null!=b&&b();else if(null!=e)e({message:mxResources.get("readOnly")});else throw Error(mxResources.get("readOnly"));}catch(q){if(null!=e)e(q);else throw q;}};
DrawioFile.prototype.updateFileData=function(a){this.setData(this.ui.getFileData(null,null,null,null,null,null,null,null,this,null!=a?!a:!this.isCompressed()))};DrawioFile.prototype.isCompressedStorage=function(){return!0};DrawioFile.prototype.isCompressed=function(){var a=null!=this.ui.fileNode?this.ui.fileNode.getAttribute("compressed"):null;return null!=a?"false"!=a:this.isCompressedStorage()&&Editor.compressXml};
DrawioFile.prototype.decompress=function(){this.updateFileData(!1);null!=this.ui.fileNode&&this.ui.fileNode.setAttribute("compressed","false");this.fileChanged()};DrawioFile.prototype.compress=function(){this.updateFileData(!0);null!=this.ui.fileNode&&this.ui.fileNode.setAttribute("compressed","true");this.fileChanged()};DrawioFile.prototype.saveAs=function(a,b,e){};DrawioFile.prototype.saveFile=function(a,b,e,d){};DrawioFile.prototype.getPublicUrl=function(a){a(null)};
DrawioFile.prototype.isRestricted=function(){return!1};DrawioFile.prototype.isModified=function(){return this.modified};DrawioFile.prototype.setModified=function(a){this.modified=a};DrawioFile.prototype.isAutosaveOptional=function(){return!1};DrawioFile.prototype.isAutosave=function(){return!this.inConflictState&&this.ui.editor.autosave};DrawioFile.prototype.isRenamable=function(){return!1};DrawioFile.prototype.rename=function(a,b,e){};DrawioFile.prototype.isMovable=function(){return!1};
@@ -2856,21 +2856,21 @@ window.location.href=e});null==a&&this.isModified()?this.ui.confirm(mxResources.
k)}};DrawioFile.prototype.handleFileSuccess=function(a){this.ui.spinner.stop();this.ui.getCurrentFile()==this&&(this.isModified()?this.fileChanged():a?(this.isTrashed()?this.addAllSavedStatus(mxUtils.htmlEntities(mxResources.get(this.allChangesSavedKey))+" ("+mxUtils.htmlEntities(mxResources.get("fileMovedToTrash"))+")"):this.addAllSavedStatus(),null!=this.sync&&(this.sync.resetUpdateStatusThread(),this.sync.remoteFileChanged&&(this.sync.remoteFileChanged=!1,this.sync.fileChangedNotify()))):this.ui.editor.setStatus(""))};
DrawioFile.prototype.handleFileError=function(a,b){this.ui.spinner.stop();if(this.ui.getCurrentFile()==this)if(this.inConflictState)this.handleConflictError(a,b);else if(this.isModified()&&this.addUnsavedStatus(a),b)this.ui.handleError(a,null!=a?mxResources.get("errorSavingFile"):null);else if(!this.isModified()){var e=null!=a?null!=a.error?a.error.message:a.message:null;null!=e&&60<e.length&&(e=e.substring(0,60)+"...");this.ui.editor.setStatus('<div class="geStatusAlert" style="cursor:pointer;overflow:hidden;">'+
mxUtils.htmlEntities(mxResources.get("error"))+(null!=e?" ("+mxUtils.htmlEntities(e)+")":"")+"</div>")}};
-DrawioFile.prototype.handleConflictError=function(a,b){var e=mxUtils.bind(this,function(){this.handleFileSuccess(!0)}),d=mxUtils.bind(this,function(a){this.handleFileError(a,!0)}),k=mxUtils.bind(this,function(){this.ui.spinner.spin(document.body,mxResources.get("saving"))&&(this.ui.editor.setStatus(""),this.save(!0,e,d,null,!0,this.constructor!=GitHubFile&&this.constructor!=GitLabFile||null==a?null:a.commitMessage))}),m=mxUtils.bind(this,function(){this.ui.spinner.spin(document.body,mxResources.get("updatingDocument"))&&
-this.synchronizeFile(mxUtils.bind(this,function(){this.ui.spinner.stop();this.ui.spinner.spin(document.body,mxResources.get("saving"))&&this.save(!0,e,d,null,null,this.constructor!=GitHubFile&&this.constructor!=GitLabFile||null==a?null:a.commitMessage)}),d)});"none"==DrawioFile.SYNC?this.showCopyDialog(e,d,k):this.invalidChecksum?this.showRefreshDialog(e,d,this.getErrorMessage(a)):b?this.showConflictDialog(k,m):this.addConflictStatus(mxUtils.bind(this,function(){this.ui.editor.setStatus(mxUtils.htmlEntities(mxResources.get("updatingDocument")));
+DrawioFile.prototype.handleConflictError=function(a,b){var e=mxUtils.bind(this,function(){this.handleFileSuccess(!0)}),d=mxUtils.bind(this,function(a){this.handleFileError(a,!0)}),k=mxUtils.bind(this,function(){this.ui.spinner.spin(document.body,mxResources.get("saving"))&&(this.ui.editor.setStatus(""),this.save(!0,e,d,null,!0,this.constructor!=GitHubFile&&this.constructor!=GitLabFile||null==a?null:a.commitMessage))}),l=mxUtils.bind(this,function(){this.ui.spinner.spin(document.body,mxResources.get("updatingDocument"))&&
+this.synchronizeFile(mxUtils.bind(this,function(){this.ui.spinner.stop();this.ui.spinner.spin(document.body,mxResources.get("saving"))&&this.save(!0,e,d,null,null,this.constructor!=GitHubFile&&this.constructor!=GitLabFile||null==a?null:a.commitMessage)}),d)});"none"==DrawioFile.SYNC?this.showCopyDialog(e,d,k):this.invalidChecksum?this.showRefreshDialog(e,d,this.getErrorMessage(a)):b?this.showConflictDialog(k,l):this.addConflictStatus(mxUtils.bind(this,function(){this.ui.editor.setStatus(mxUtils.htmlEntities(mxResources.get("updatingDocument")));
this.synchronizeFile(e,d)}),this.getErrorMessage(a))};DrawioFile.prototype.getErrorMessage=function(a){return null!=a?null!=a.error?a.error.message:a.message:null};DrawioFile.prototype.isOverdue=function(){return null!=this.ageStart&&Date.now()-this.ageStart.getTime()>=this.ui.warnInterval};
DrawioFile.prototype.fileChanged=function(){this.lastChanged=new Date;this.setModified(!0);this.isAutosave()?(this.addAllSavedStatus(mxUtils.htmlEntities(mxResources.get("saving"))+"..."),this.ui.scheduleSanityCheck(),null==this.ageStart&&(this.ageStart=new Date),this.autosave(this.autosaveDelay,this.maxAutosaveDelay,mxUtils.bind(this,function(a){this.ui.stopSanityCheck();null==this.autosaveThread?(this.handleFileSuccess(!0),this.ageStart=null):this.isModified()&&(this.ui.scheduleSanityCheck(),this.ageStart=
this.lastChanged)}),mxUtils.bind(this,function(a){this.handleFileError(a)}))):(this.ageStart=null,this.isAutosaveOptional()&&this.ui.editor.autosave||this.inConflictState||this.addUnsavedStatus())};DrawioFile.prototype.createSecret=function(a,b){var e=Editor.guid(32);null!=this.sync?this.sync.createToken(e,mxUtils.bind(this,function(b){a(e,b)}),b):a(e)};
-DrawioFile.prototype.fileSaved=function(a,b,e,d,k){this.lastSaved=new Date;this.ageStart=null;try{this.stats.saved++,this.invalidChecksum=this.inConflictState=!1,null==this.sync?(this.shadowData=a,this.shadowPages=null,null!=e&&e()):this.sync.fileSaved(this.ui.getPagesForNode(mxUtils.parseXml(a).documentElement),b,e,d,k)}catch(c){this.invalidChecksum=this.inConflictState=!0;this.descriptorChanged();null!=d&&d(c);try{if(this.errorReportsEnabled)this.sendErrorReport("Error in fileSaved",null,c);else{var m=
-this.getCurrentUser(),q=null!=m?m.id:"unknown";EditorUi.logError("Error in fileSaved",null,this.getMode()+"."+this.getId(),q,c)}}catch(f){}}};
+DrawioFile.prototype.fileSaved=function(a,b,e,d,k){this.lastSaved=new Date;this.ageStart=null;try{this.stats.saved++,this.invalidChecksum=this.inConflictState=!1,null==this.sync?(this.shadowData=a,this.shadowPages=null,null!=e&&e()):this.sync.fileSaved(this.ui.getPagesForNode(mxUtils.parseXml(a).documentElement),b,e,d,k)}catch(c){this.invalidChecksum=this.inConflictState=!0;this.descriptorChanged();null!=d&&d(c);try{if(this.errorReportsEnabled)this.sendErrorReport("Error in fileSaved",null,c);else{var l=
+this.getCurrentUser(),q=null!=l?l.id:"unknown";EditorUi.logError("Error in fileSaved",null,this.getMode()+"."+this.getId(),q,c)}}catch(f){}}};
DrawioFile.prototype.autosave=function(a,b,e,d){null==this.lastAutosave&&(this.lastAutosave=Date.now());a=Date.now()-this.lastAutosave<b?a:0;this.clearAutosave();var k=window.setTimeout(mxUtils.bind(this,function(){this.lastAutosave=null;this.autosaveThread==k&&(this.autosaveThread=null);if(this.isModified()&&this.isAutosaveNow()){var a=this.isAutosaveRevision();a&&(this.lastAutosaveRevision=(new Date).getTime());this.save(a,mxUtils.bind(this,function(a){this.autosaveCompleted();null!=e&&e(a)}),mxUtils.bind(this,
function(a){null!=d&&d(a)}))}else this.isModified()||this.ui.editor.setStatus(""),null!=e&&e(null)}),a);this.autosaveThread=k};DrawioFile.prototype.isAutosaveNow=function(){return!0};DrawioFile.prototype.autosaveCompleted=function(){};DrawioFile.prototype.clearAutosave=function(){null!=this.autosaveThread&&(window.clearTimeout(this.autosaveThread),this.autosaveThread=null)};
DrawioFile.prototype.isAutosaveRevision=function(){var a=(new Date).getTime();return null==this.lastAutosaveRevision||a-this.lastAutosaveRevision>this.maxAutosaveRevisionDelay};DrawioFile.prototype.descriptorChanged=function(){this.fireEvent(new mxEventObject("descriptorChanged"))};DrawioFile.prototype.contentChanged=function(){this.fireEvent(new mxEventObject("contentChanged"))};
DrawioFile.prototype.close=function(a){this.updateFileData();this.stats.closed++;this.isAutosave()&&this.isModified()&&this.save(this.isAutosaveRevision(),null,null,a);this.destroy()};DrawioFile.prototype.hasSameExtension=function(a,b){if(null!=a&&null!=b){var e=a.lastIndexOf("."),d=0<e?a.substring(e):"",e=b.lastIndexOf(".");return d===(0<e?b.substring(e):"")}return a==b};
DrawioFile.prototype.removeListeners=function(){null!=this.changeListener&&(this.ui.editor.graph.model.removeListener(this.changeListener),this.ui.editor.graph.removeListener(this.changeListener),this.ui.removeListener(this.changeListener),this.changeListener=null)};DrawioFile.prototype.destroy=function(){this.stats.destroyed++;this.clearAutosave();this.removeListeners();null!=this.sync&&(this.sync.destroy(),this.sync=null)};DrawioFile.prototype.commentsSupported=function(){return!1};
DrawioFile.prototype.commentsRefreshNeeded=function(){return!0};DrawioFile.prototype.commentsSaveNeeded=function(){return!1};DrawioFile.prototype.getComments=function(a,b){a([])};DrawioFile.prototype.addComment=function(a,b,e){b(Date.now())};DrawioFile.prototype.canReplyToReplies=function(){return!0};DrawioFile.prototype.canComment=function(){return!0};DrawioFile.prototype.newComment=function(a,b){return new DrawioComment(this,null,a,Date.now(),Date.now(),!1,b)};LocalFile=function(a,b,e,d){DrawioFile.call(this,a,b);this.title=e;this.mode=d?null:App.MODE_DEVICE};mxUtils.extend(LocalFile,DrawioFile);LocalFile.prototype.isAutosave=function(){return!1};LocalFile.prototype.getMode=function(){return this.mode};LocalFile.prototype.getTitle=function(){return this.title};LocalFile.prototype.isRenamable=function(){return!0};LocalFile.prototype.save=function(a,b,e){this.saveAs(this.title,b,e)};LocalFile.prototype.saveAs=function(a,b,e){this.saveFile(a,!1,b,e)};
-LocalFile.prototype.saveFile=function(a,b,e,d){this.title=a;this.updateFileData();b=this.getData();var k=this.ui.useCanvasForExport&&/(\.png)$/i.test(this.getTitle()),m=mxUtils.bind(this,function(b){if(this.ui.isOfflineApp()||this.ui.isLocalFileSave())this.ui.doSaveLocalFile(b,a,k?"image/png":"text/xml",k);else if(b.length<MAX_REQUEST_SIZE){var c=a.lastIndexOf("."),c=0<c?a.substring(c+1):"xml";(new mxXmlRequest(SAVE_URL,"format="+c+"&xml="+encodeURIComponent(b)+"&filename="+encodeURIComponent(a)+
-(k?"&binary=1":""))).simulate(document,"_blank")}else this.ui.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(b)}));this.setModified(!1);this.contentChanged();null!=e&&e()});k?(b=this.ui.getPngFileProperties(this.ui.fileNode),this.ui.getEmbeddedPng(mxUtils.bind(this,function(a){m(a)}),d,this.ui.getCurrentFile()!=this?this.getData():null,b.scale,b.border)):m(b)};
+LocalFile.prototype.saveFile=function(a,b,e,d){this.title=a;this.updateFileData();b=this.getData();var k=this.ui.useCanvasForExport&&/(\.png)$/i.test(this.getTitle()),l=mxUtils.bind(this,function(b){if(this.ui.isOfflineApp()||this.ui.isLocalFileSave())this.ui.doSaveLocalFile(b,a,k?"image/png":"text/xml",k);else if(b.length<MAX_REQUEST_SIZE){var c=a.lastIndexOf("."),c=0<c?a.substring(c+1):"xml";(new mxXmlRequest(SAVE_URL,"format="+c+"&xml="+encodeURIComponent(b)+"&filename="+encodeURIComponent(a)+
+(k?"&binary=1":""))).simulate(document,"_blank")}else this.ui.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(b)}));this.setModified(!1);this.contentChanged();null!=e&&e()});k?(b=this.ui.getPngFileProperties(this.ui.fileNode),this.ui.getEmbeddedPng(mxUtils.bind(this,function(a){l(a)}),d,this.ui.getCurrentFile()!=this?this.getData():null,b.scale,b.border)):l(b)};
LocalFile.prototype.rename=function(a,b,e){this.title=a;this.descriptorChanged();null!=b&&b()};LocalFile.prototype.open=function(){this.ui.setFileData(this.getData());this.installListeners()};(function(){Editor.prototype.appName="diagrams.net";Editor.prototype.diagramFileTypes=[{description:"diagramXmlDesc",extension:"drawio"},{description:"diagramPngDesc",extension:"png"},{description:"diagramSvgDesc",extension:"svg"},{description:"diagramHtmlDesc",extension:"html"},{description:"diagramXmlDesc",extension:"xml"}];Editor.prototype.libraryFileTypes=[{description:"Library (.drawiolib, .xml)",extensions:["drawiolib","xml"]}];Editor.prototype.fileExtensions=[{ext:"html",title:"filetypeHtml"},
{ext:"png",title:"filetypePng"},{ext:"svg",title:"filetypeSvg"}];Editor.closeImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAZCAMAAADzN3VRAAAApVBMVEUAAAD////k5OT///8AAAB1dXXMzMz9/f39/f37+/v5+fn+/v7///9iYmJaWlqFhYWnp6ejo6OHh4f////////////////7+/v5+fnx8fH///8AAAD///8bGxv7+/v5+fkoKCghISFDQ0MYGBjh4eHY2Njb29tQUFBvb29HR0c/Pz82NjYrKyu/v78SEhLu7u7s7OzV1dVVVVU7OzsVFRXAv78QEBBzqehMAAAAG3RSTlMAA/7p/vz5xZlrTiPL/v78+/v7+OXd2TYQDs8L70ZbAAABKUlEQVQoz3VS13LCMBBUXHChd8iukDslQChJ/v/TchaG4cXS+OSb1c7trU7V60OpdRz2ZtNZL4zXNlcN8BEtSG6+NxIXkeRPoBuQ1cjvZ31/VJFB10ISli6diYfH8iYO3WUNCcNlB0gTrXOtkxTo0O1aKKiBBMhhv2MNBQKoiA5wxlZo0JDzD3AYKbWacyj3fs01wxey0pyEP+R8pWKWXoqtIZ0DDg5pbki9krEKOa6LVDQsdoXEsi46Zqh69KFz7B1u7Hb2yDV8firXDKBlZ4UFiswKGRhXTS93/ECK7yxnJ3+S3y/ThpO+cfSD017nqa18aasabU0/t7d+tk0/1oMEJ1NaD67iwdF68OabFSLn+eHb0+vjy+uk8br9fdrftH0O2menfd7+AQfYM/lNjoDHAAAAAElFTkSuQmCC":
IMAGE_PATH+"/delete.png";Editor.plusImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MDdCMTdENjVCOEM4MTFFNDlCRjVBNDdCODU5NjNBNUMiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MDdCMTdENjZCOEM4MTFFNDlCRjVBNDdCODU5NjNBNUMiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowN0IxN0Q2M0I4QzgxMUU0OUJGNUE0N0I4NTk2M0E1QyIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowN0IxN0Q2NEI4QzgxMUU0OUJGNUE0N0I4NTk2M0E1QyIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PtjrjmgAAAAtSURBVHjaYvz//z8DMigvLwcLdHZ2MiKLMzEQCaivkLGsrOw/dU0cAr4GCDAARQsQbTFrv10AAAAASUVORK5CYII=":
@@ -2903,7 +2903,7 @@ Editor.fastCompress=function(a){return null==a||0==a.length||"undefined"===typeo
(f=d[0].getAttribute("data-mxgraph"),null!=f?(d=JSON.parse(f),null!=d&&null!=d.xml&&(a=mxUtils.parseXml(d.xml),a=a.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(f=mxUtils.getTextContent(d[0]),f=Graph.decompress(f,null,b),0<f.length&&(a=mxUtils.parseXml(f),a=a.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(f=a.getAttribute("content"),null!=f&&"<"!=f.charAt(0)&&"%"!=f.charAt(0)&&(f=unescape(window.atob?atob(f):Base64.decode(cont,f))),null!=f&&"%"==f.charAt(0)&&(f=decodeURIComponent(f)),
null!=f&&0<f.length)a=mxUtils.parseXml(f).documentElement;else throw{message:mxResources.get("notADiagramFile")};null==a||c||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(f=a.getElementsByTagName("diagram"),0<f.length&&(d=f[Math.max(0,Math.min(f.length-1,urlParams.page||0))])),null!=d&&(a=Editor.parseDiagramNode(d,b)));null==a||"mxGraphModel"==a.nodeName||c&&"mxfile"==a.nodeName||(a=null);return a};Editor.parseDiagramNode=function(a,c){var b=mxUtils.trim(mxUtils.getTextContent(a)),f=null;
0<b.length?(b=Graph.decompress(b,null,c),null!=b&&0<b.length&&(f=mxUtils.parseXml(b).documentElement)):(b=mxUtils.getChildNodes(a),0<b.length&&(f=mxUtils.createXmlDocument(),f.appendChild(f.importNode(b[0],!0)),f=f.documentElement));return f};Editor.getDiagramNodeXml=function(a){var c=mxUtils.getTextContent(a),b=null;0<c.length?b=Graph.decompress(c):null!=a.firstChild&&(b=mxUtils.getXml(a.firstChild));return b};Editor.extractGraphModelFromPdf=function(a){a=a.substring(a.indexOf(",")+1);a=window.atob&&
-!mxClient.IS_SF?atob(a):Base64.decode(a,!0);for(var c=null,b="",f=0,d=0,e=[],g=null;d<a.length;){var l=a.charCodeAt(d),d=d+1;10!=l&&(b+=String.fromCharCode(l));l=="/Subject (%3Cmxfile".charCodeAt(f)?f++:f=0;if(19==f){var p=a.indexOf("%3C%2Fmxfile%3E)",d)+15,d=d-9;if(p>d){c=a.substring(d,p);break}}10==l&&("endobj"==b?g=null:"obj"==b.substring(b.length-3,b.length)||"xref"==b||"trailer"==b?(g=[],e[b.split(" ")[0]]=g):null!=g&&g.push(b),b="")}null==c&&(c=Editor.extractGraphModelFromXref(e));null!=c&&
+!mxClient.IS_SF?atob(a):Base64.decode(a,!0);for(var c=null,b="",f=0,d=0,e=[],g=null;d<a.length;){var m=a.charCodeAt(d),d=d+1;10!=m&&(b+=String.fromCharCode(m));m=="/Subject (%3Cmxfile".charCodeAt(f)?f++:f=0;if(19==f){var p=a.indexOf("%3C%2Fmxfile%3E)",d)+15,d=d-9;if(p>d){c=a.substring(d,p);break}}10==m&&("endobj"==b?g=null:"obj"==b.substring(b.length-3,b.length)||"xref"==b||"trailer"==b?(g=[],e[b.split(" ")[0]]=g):null!=g&&g.push(b),b="")}null==c&&(c=Editor.extractGraphModelFromXref(e));null!=c&&
(c=decodeURIComponent(c.replace(/\\\(/g,"(").replace(/\\\)/g,")")));return c};Editor.extractGraphModelFromXref=function(a){var c=a.trailer,b=null;null!=c&&(c=/.* \/Info (\d+) (\d+) R/g.exec(c.join("\n")),null!=c&&0<c.length&&(c=a[c[1]],null!=c&&(c=/.* \/Subject (\d+) (\d+) R/g.exec(c.join("\n")),null!=c&&0<c.length&&(a=a[c[1]],null!=a&&(a=a.join("\n"),b=a.substring(1,a.length-1))))));return b};Editor.extractGraphModelFromPng=function(a){var c=null;try{var b=a.substring(a.indexOf(",")+1),f=window.atob&&
!mxClient.IS_SF?atob(b):Base64.decode(b,!0);EditorUi.parsePng(f,mxUtils.bind(this,function(a,b,d){a=f.substring(a+8,a+8+d);"zTXt"==b?(d=a.indexOf(String.fromCharCode(0)),"mxGraphModel"==a.substring(0,d)&&(a=pako.inflateRaw(a.substring(d+2),{to:"string"}).replace(/\+/g," "),null!=a&&0<a.length&&(c=a))):"tEXt"==b&&(a=a.split(String.fromCharCode(0)),1<a.length&&("mxGraphModel"==a[0]||"mxfile"==a[0])&&(c=a[1]));if(null!=c||"IDAT"==b)return!0}))}catch(O){}null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c));
null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c));return c};Editor.extractParserError=function(a,c){var b=null,f=null!=a?a.getElementsByTagName("parsererror"):null;null!=f&&0<f.length&&(b=c||mxResources.get("invalidChars"),f=f[0].getElementsByTagName("div"),0<f.length&&(b=mxUtils.getTextContent(f[0])));return null!=b?mxUtils.trim(b):b};Editor.configure=function(a,c){if(null!=a){Editor.config=a;Editor.configVersion=a.version;Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;
@@ -2929,27 +2929,27 @@ var c=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\
return null!=this.corsRegExp&&this.corsRegExp.test(a)||"https://raw.githubusercontent.com/"===a.substring(0,34)||"https://cdn.rawgit.com/"===a.substring(0,23)||"https://rawgit.com/"===a.substring(0,19)||/^https?:\/\/[^\/]*\.blob.core.windows.net\//.test(a)||/^https?:\/\/[^\/]*\.diagrams\.new\/proxy/.test(a)||/^https?:\/\/[^\/]*\.draw\.io\/proxy/.test(a)||/^https?:\/\/[^\/]*\.github\.io\//.test(a)};Editor.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var c=
a.convert,b=this;a.convert=function(f){if(null!=f){var d="http://"==f.substring(0,7)||"https://"==f.substring(0,8);d&&!navigator.onLine?f=Editor.svgBrokenImage.src:!d||f.substring(0,a.baseUrl.length)==a.baseUrl||b.crossOriginImages&&b.isCorsEnabledForUrl(f)?"chrome-extension://"==f.substring(0,19)||mxClient.IS_CHROMEAPP||(f=c.apply(this,arguments)):f=PROXY_URL+"?url="+encodeURIComponent(f)}return f};return a};Editor.createSvgDataUri=function(a){return"data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(a)))};
Editor.prototype.convertImageToDataUri=function(a,c){try{var b=!0,f=window.setTimeout(mxUtils.bind(this,function(){b=!1;c(Editor.svgBrokenImage.src)}),this.timeout);if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){window.clearTimeout(f);b&&c(Editor.createSvgDataUri(a.getText()))}),function(){window.clearTimeout(f);b&&c(Editor.svgBrokenImage.src)});else{var d=new Image;this.crossOriginImages&&(d.crossOrigin="anonymous");d.onload=function(){window.clearTimeout(f);if(b)try{var a=document.createElement("canvas"),
-e=a.getContext("2d");a.height=d.height;a.width=d.width;e.drawImage(d,0,0);c(a.toDataURL())}catch(ea){c(Editor.svgBrokenImage.src)}};d.onerror=function(){window.clearTimeout(f);b&&c(Editor.svgBrokenImage.src)};d.src=a}}catch(I){c(Editor.svgBrokenImage.src)}};Editor.prototype.convertImages=function(a,c,b,f){null==f&&(f=this.createImageUrlConverter());var d=0,e=b||{};b=mxUtils.bind(this,function(b,g){for(var l=a.getElementsByTagName(b),p=0;p<l.length;p++)mxUtils.bind(this,function(b){try{if(null!=b){var l=
-f.convert(b.getAttribute(g));if(null!=l&&"data:"!=l.substring(0,5)){var p=e[l];null==p?(d++,this.convertImageToDataUri(l,function(f){null!=f&&(e[l]=f,b.setAttribute(g,f));d--;0==d&&c(a)})):b.setAttribute(g,p)}else null!=l&&b.setAttribute(g,l)}}catch(Z){}})(l[p])});b("image","xlink:href");b("img","src");0==d&&c(a)};Editor.base64Encode=function(a){for(var c="",b=0,f=a.length,d,e,g;b<f;){d=a.charCodeAt(b++)&255;if(b==f){c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(d>>
+e=a.getContext("2d");a.height=d.height;a.width=d.width;e.drawImage(d,0,0);c(a.toDataURL())}catch(ea){c(Editor.svgBrokenImage.src)}};d.onerror=function(){window.clearTimeout(f);b&&c(Editor.svgBrokenImage.src)};d.src=a}}catch(I){c(Editor.svgBrokenImage.src)}};Editor.prototype.convertImages=function(a,c,b,f){null==f&&(f=this.createImageUrlConverter());var d=0,e=b||{};b=mxUtils.bind(this,function(b,g){for(var m=a.getElementsByTagName(b),p=0;p<m.length;p++)mxUtils.bind(this,function(b){try{if(null!=b){var m=
+f.convert(b.getAttribute(g));if(null!=m&&"data:"!=m.substring(0,5)){var p=e[m];null==p?(d++,this.convertImageToDataUri(m,function(f){null!=f&&(e[m]=f,b.setAttribute(g,f));d--;0==d&&c(a)})):b.setAttribute(g,p)}else null!=m&&b.setAttribute(g,m)}}catch(Z){}})(m[p])});b("image","xlink:href");b("img","src");0==d&&c(a)};Editor.base64Encode=function(a){for(var c="",b=0,f=a.length,d,e,g;b<f;){d=a.charCodeAt(b++)&255;if(b==f){c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(d>>
2);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((d&3)<<4);c+="==";break}e=a.charCodeAt(b++);if(b==f){c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(d>>2);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((d&3)<<4|(e&240)>>4);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((e&15)<<2);c+="=";break}g=a.charCodeAt(b++);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(d>>
-2);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((d&3)<<4|(e&240)>>4);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((e&15)<<2|(g&192)>>6);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(g&63)}return c};Editor.prototype.loadUrl=function(a,c,b,f,d,e,g,l){try{var p=!g&&(f||/(\.png)($|\?)/i.test(a)||/(\.jpe?g)($|\?)/i.test(a)||/(\.gif)($|\?)/i.test(a)||/(\.pdf)($|\?)/i.test(a));d=null!=d?d:!0;var n=mxUtils.bind(this,
+2);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((d&3)<<4|(e&240)>>4);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt((e&15)<<2|(g&192)>>6);c+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(g&63)}return c};Editor.prototype.loadUrl=function(a,c,b,f,d,e,g,m){try{var p=!g&&(f||/(\.png)($|\?)/i.test(a)||/(\.jpe?g)($|\?)/i.test(a)||/(\.gif)($|\?)/i.test(a)||/(\.pdf)($|\?)/i.test(a));d=null!=d?d:!0;var n=mxUtils.bind(this,
function(){mxUtils.get(a,mxUtils.bind(this,function(a){if(200<=a.getStatus()&&299>=a.getStatus()){if(null!=c){var f=a.getText();if(p){if((9==document.documentMode||10==document.documentMode)&&"undefined"!==typeof window.mxUtilsBinaryToArray){a=mxUtilsBinaryToArray(a.request.responseBody).toArray();for(var f=Array(a.length),d=0;d<a.length;d++)f[d]=String.fromCharCode(a[d]);f=f.join("")}e=null!=e?e:"data:image/png;base64,";f=e+Editor.base64Encode(f)}c(f)}}else null!=b&&(0==a.getStatus()?b({message:mxResources.get("accessDenied")},
-a):b({message:mxResources.get("error")+" "+a.getStatus()},a))}),function(a){null!=b&&b({message:mxResources.get("error")+" "+a.getStatus()})},p,this.timeout,function(){d&&null!=b&&b({code:App.ERROR_TIMEOUT,retry:n})},l)});n()}catch(fa){null!=b&&b(fa)}};Editor.prototype.embedCssFonts=function(a,c){function b(a){return a.replace(RegExp("^[\\s\"']+","g"),"").replace(RegExp("[\\s\"']+$","g"),"")}var f=a.split("url("),d=0;null==this.cachedFonts&&(this.cachedFonts={});var e=mxUtils.bind(this,function(){if(0==
-d){for(var a=[f[0]],e=1;e<f.length;e++){var g=f[e].indexOf(")");a.push('url("');a.push(this.cachedFonts[b(f[e].substring(0,g))]);a.push('"'+f[e].substring(g))}c(a.join(""))}});if(0<f.length){for(var g=1;g<f.length;g++){var l=f[g].indexOf(")"),p=null,n=f[g].indexOf("format(",l);0<n&&(p=b(f[g].substring(n+7,f[g].indexOf(")",n))));mxUtils.bind(this,function(a){if(null==this.cachedFonts[a]){this.cachedFonts[a]=a;d++;var c="application/x-font-ttf";if("svg"==p||/(\.svg)($|\?)/i.test(a))c="image/svg+xml";
+a):b({message:mxResources.get("error")+" "+a.getStatus()},a))}),function(a){null!=b&&b({message:mxResources.get("error")+" "+a.getStatus()})},p,this.timeout,function(){d&&null!=b&&b({code:App.ERROR_TIMEOUT,retry:n})},m)});n()}catch(fa){null!=b&&b(fa)}};Editor.prototype.embedCssFonts=function(a,c){function b(a){return a.replace(RegExp("^[\\s\"']+","g"),"").replace(RegExp("[\\s\"']+$","g"),"")}var f=a.split("url("),d=0;null==this.cachedFonts&&(this.cachedFonts={});var e=mxUtils.bind(this,function(){if(0==
+d){for(var a=[f[0]],e=1;e<f.length;e++){var g=f[e].indexOf(")");a.push('url("');a.push(this.cachedFonts[b(f[e].substring(0,g))]);a.push('"'+f[e].substring(g))}c(a.join(""))}});if(0<f.length){for(var g=1;g<f.length;g++){var m=f[g].indexOf(")"),p=null,n=f[g].indexOf("format(",m);0<n&&(p=b(f[g].substring(n+7,f[g].indexOf(")",n))));mxUtils.bind(this,function(a){if(null==this.cachedFonts[a]){this.cachedFonts[a]=a;d++;var c="application/x-font-ttf";if("svg"==p||/(\.svg)($|\?)/i.test(a))c="image/svg+xml";
else if("otf"==p||"embedded-opentype"==p||/(\.otf)($|\?)/i.test(a))c="application/x-font-opentype";else if("woff"==p||/(\.woff)($|\?)/i.test(a))c="application/font-woff";else if("woff2"==p||/(\.woff2)($|\?)/i.test(a))c="application/font-woff2";else if("eot"==p||/(\.eot)($|\?)/i.test(a))c="application/vnd.ms-fontobject";else if("sfnt"==p||/(\.sfnt)($|\?)/i.test(a))c="application/font-sfnt";var b=a;/^https?:\/\//.test(b)&&!this.isCorsEnabledForUrl(b)&&(b=PROXY_URL+"?url="+encodeURIComponent(a));this.loadUrl(b,
-mxUtils.bind(this,function(c){this.cachedFonts[a]=c;d--;e()}),mxUtils.bind(this,function(a){d--;e()}),!0,null,"data:"+c+";charset=utf-8;base64,")}})(b(f[g].substring(0,l)),p)}e()}else c(a)};Editor.prototype.loadFonts=function(a){null!=this.fontCss&&null==this.resolvedFontCss?this.embedCssFonts(this.fontCss,mxUtils.bind(this,function(c){this.resolvedFontCss=c;a()})):a()};Editor.prototype.embedExtFonts=function(a){var c=this.graph.extFonts;if(null!=c&&0<c.length){var b="",f=0;null==this.cachedGoogleFonts&&
+mxUtils.bind(this,function(c){this.cachedFonts[a]=c;d--;e()}),mxUtils.bind(this,function(a){d--;e()}),!0,null,"data:"+c+";charset=utf-8;base64,")}})(b(f[g].substring(0,m)),p)}e()}else c(a)};Editor.prototype.loadFonts=function(a){null!=this.fontCss&&null==this.resolvedFontCss?this.embedCssFonts(this.fontCss,mxUtils.bind(this,function(c){this.resolvedFontCss=c;a()})):a()};Editor.prototype.embedExtFonts=function(a){var c=this.graph.extFonts;if(null!=c&&0<c.length){var b="",f=0;null==this.cachedGoogleFonts&&
(this.cachedGoogleFonts={});for(var d=mxUtils.bind(this,function(){0==f&&this.embedCssFonts(b,a)}),e=0;e<c.length;e++)mxUtils.bind(this,function(a,c){0==c.indexOf(Editor.GOOGLE_FONTS)?null==this.cachedGoogleFonts[c]?(f++,this.loadUrl(c,mxUtils.bind(this,function(a){this.cachedGoogleFonts[c]=a;b+=a;f--;d()}),mxUtils.bind(this,function(a){f--;b+="@import url("+c+");";d()}))):b+=this.cachedGoogleFonts[c]:b+='@font-face {font-family: "'+a+'";src: url("'+c+'");}'})(c[e].name,c[e].url);d()}else a()};Editor.prototype.addMathCss=
function(a){a=a.getElementsByTagName("defs");if(null!=a&&0<a.length)for(var c=document.getElementsByTagName("style"),b=0;b<c.length;b++)0<mxUtils.getTextContent(c[b]).indexOf("MathJax")&&a[0].appendChild(c[b].cloneNode(!0))};Editor.prototype.addFontCss=function(a,c){c=null!=c?c:this.fontCss;if(null!=c){var b=a.getElementsByTagName("defs"),f=a.ownerDocument;0==b.length?(b=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"defs"):f.createElement("defs"),null!=a.firstChild?a.insertBefore(b,
-a.firstChild):a.appendChild(b)):b=b[0];f=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"style"):f.createElement("style");f.setAttribute("type","text/css");mxUtils.setTextContent(f,c);b.appendChild(f)}};Editor.prototype.isExportToCanvas=function(){return mxClient.IS_CHROMEAPP||this.useCanvasForExport};Editor.prototype.exportToCanvas=function(a,c,b,f,d,e,g,l,p,n,u,t,v,m,k){try{e=null!=e?e:!0;g=null!=g?g:!0;t=null!=t?t:this.graph;v=null!=v?v:0;var y=p?null:t.background;y==mxConstants.NONE&&
-(y=null);null==y&&(y=f);null==y&&0==p&&(y="#ffffff");this.convertImages(t.getSvg(null,null,null,m,null,g,null,null,null,n),mxUtils.bind(this,function(b){try{var f=new Image;f.onload=mxUtils.bind(this,function(){try{var g=function(){mxClient.IS_SF?window.setTimeout(function(){m.drawImage(f,v/l,v/l);a(p)},0):(m.drawImage(f,v/l,v/l),a(p))},p=document.createElement("canvas"),n=parseInt(b.getAttribute("width")),u=parseInt(b.getAttribute("height"));l=null!=l?l:1;null!=c&&(l=e?Math.min(1,Math.min(3*c/(4*
-u),c/n)):c/n);n=Math.ceil(l*n)+2*v;u=Math.ceil(l*u)+2*v;p.setAttribute("width",n);p.setAttribute("height",u);var m=p.getContext("2d");null!=y&&(m.beginPath(),m.rect(0,0,n,u),m.fillStyle=y,m.fill());m.scale(l,l);if(k){var z=t.view,x=z.scale;z.scale=1;var q=btoa(unescape(encodeURIComponent(z.createSvgGrid(z.gridColor))));z.scale=x;var q="data:image/svg+xml;base64,"+q,A=t.gridSize*z.gridSteps*l,B=t.getGraphBounds(),K=z.translate.x*x,I=z.translate.y*x,D=K+(B.x-K)/x,C=I+(B.y-I)/x,F=new Image;F.onload=
-function(){try{for(var a=-Math.round(A-mxUtils.mod((K-D)*l,A)),c=-Math.round(A-mxUtils.mod((I-C)*l,A));a<n;a+=A)for(var b=c;b<u;b+=A)m.drawImage(F,a/l,b/l);g()}catch(sa){null!=d&&d(sa)}};F.onerror=function(a){null!=d&&d(a)};F.src=q}else g()}catch(ua){null!=d&&d(ua)}});f.onerror=function(a){null!=d&&d(a)};n&&this.graph.addSvgShadow(b);this.graph.mathEnabled&&this.addMathCss(b);var g=mxUtils.bind(this,function(){try{null!=this.resolvedFontCss&&this.addFontCss(b,this.resolvedFontCss),f.src=Editor.createSvgDataUri(mxUtils.getXml(b))}catch(ca){null!=
-d&&d(ca)}});this.embedExtFonts(mxUtils.bind(this,function(a){try{null!=a&&this.addFontCss(b,a),this.loadFonts(g)}catch(P){null!=d&&d(P)}}))}catch(ca){null!=d&&d(ca)}}),b,u)}catch(T){null!=d&&d(T)}};Editor.crcTable=[];for(var k=0;256>k;k++)for(var m=k,q=0;8>q;q++)m=1==(m&1)?3988292384^m>>>1:m>>>1,Editor.crcTable[k]=m;Editor.updateCRC=function(a,c,b,f){for(var d=0;d<f;d++)a=Editor.crcTable[(a^c.charCodeAt(b+d))&255]^a>>>8;return a};Editor.crc32=function(a){for(var c=-1,b=0;b<a.length;b++)c=c>>>8^Editor.crcTable[(c^
-a.charCodeAt(b))&255];return(c^-1)>>>0};Editor.writeGraphModelToPng=function(a,c,b,f,d){function e(a,c){var b=p;p+=c;return a.substring(b,p)}function g(a){a=e(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}function l(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}a=a.substring(a.indexOf(",")+1);a=window.atob?atob(a):Base64.decode(a,!0);var p=0;if(e(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=d&&d();else if(e(a,
-4),"IHDR"!=e(a,4))null!=d&&d();else{e(a,17);d=a.substring(0,p);do{var n=g(a);if("IDAT"==e(a,4)){d=a.substring(0,p-8);"pHYs"==c&&"dpi"==b?(b=Math.round(f/.0254),b=l(b)+l(b)+String.fromCharCode(1)):b=b+String.fromCharCode(0)+("zTXt"==c?String.fromCharCode(0):"")+f;f=4294967295;f=Editor.updateCRC(f,c,0,4);f=Editor.updateCRC(f,b,0,b.length);d+=l(b.length)+c+b+l(f^4294967295);d+=a.substring(p-8,a.length);break}d+=a.substring(p-8,p-4+n);e(a,n);e(a,4)}while(n);return"data:image/png;base64,"+(window.btoa?
+a.firstChild):a.appendChild(b)):b=b[0];f=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"style"):f.createElement("style");f.setAttribute("type","text/css");mxUtils.setTextContent(f,c);b.appendChild(f)}};Editor.prototype.isExportToCanvas=function(){return mxClient.IS_CHROMEAPP||this.useCanvasForExport};Editor.prototype.exportToCanvas=function(a,c,b,f,d,e,g,m,p,n,u,t,l,k,v){try{e=null!=e?e:!0;g=null!=g?g:!0;t=null!=t?t:this.graph;l=null!=l?l:0;var y=p?null:t.background;y==mxConstants.NONE&&
+(y=null);null==y&&(y=f);null==y&&0==p&&(y="#ffffff");this.convertImages(t.getSvg(null,null,null,k,null,g,null,null,null,n),mxUtils.bind(this,function(b){try{var f=new Image;f.onload=mxUtils.bind(this,function(){try{var g=function(){mxClient.IS_SF?window.setTimeout(function(){k.drawImage(f,l/m,l/m);a(p)},0):(k.drawImage(f,l/m,l/m),a(p))},p=document.createElement("canvas"),n=parseInt(b.getAttribute("width")),u=parseInt(b.getAttribute("height"));m=null!=m?m:1;null!=c&&(m=e?Math.min(1,Math.min(3*c/(4*
+u),c/n)):c/n);n=Math.ceil(m*n)+2*l;u=Math.ceil(m*u)+2*l;p.setAttribute("width",n);p.setAttribute("height",u);var k=p.getContext("2d");null!=y&&(k.beginPath(),k.rect(0,0,n,u),k.fillStyle=y,k.fill());k.scale(m,m);if(v){var z=t.view,x=z.scale;z.scale=1;var q=btoa(unescape(encodeURIComponent(z.createSvgGrid(z.gridColor))));z.scale=x;var q="data:image/svg+xml;base64,"+q,A=t.gridSize*z.gridSteps*m,B=t.getGraphBounds(),K=z.translate.x*x,I=z.translate.y*x,D=K+(B.x-K)/x,C=I+(B.y-I)/x,F=new Image;F.onload=
+function(){try{for(var a=-Math.round(A-mxUtils.mod((K-D)*m,A)),c=-Math.round(A-mxUtils.mod((I-C)*m,A));a<n;a+=A)for(var b=c;b<u;b+=A)k.drawImage(F,a/m,b/m);g()}catch(sa){null!=d&&d(sa)}};F.onerror=function(a){null!=d&&d(a)};F.src=q}else g()}catch(ua){null!=d&&d(ua)}});f.onerror=function(a){null!=d&&d(a)};n&&this.graph.addSvgShadow(b);this.graph.mathEnabled&&this.addMathCss(b);var g=mxUtils.bind(this,function(){try{null!=this.resolvedFontCss&&this.addFontCss(b,this.resolvedFontCss),f.src=Editor.createSvgDataUri(mxUtils.getXml(b))}catch(ca){null!=
+d&&d(ca)}});this.embedExtFonts(mxUtils.bind(this,function(a){try{null!=a&&this.addFontCss(b,a),this.loadFonts(g)}catch(P){null!=d&&d(P)}}))}catch(ca){null!=d&&d(ca)}}),b,u)}catch(T){null!=d&&d(T)}};Editor.crcTable=[];for(var k=0;256>k;k++)for(var l=k,q=0;8>q;q++)l=1==(l&1)?3988292384^l>>>1:l>>>1,Editor.crcTable[k]=l;Editor.updateCRC=function(a,c,b,f){for(var d=0;d<f;d++)a=Editor.crcTable[(a^c.charCodeAt(b+d))&255]^a>>>8;return a};Editor.crc32=function(a){for(var c=-1,b=0;b<a.length;b++)c=c>>>8^Editor.crcTable[(c^
+a.charCodeAt(b))&255];return(c^-1)>>>0};Editor.writeGraphModelToPng=function(a,c,b,f,d){function e(a,c){var b=p;p+=c;return a.substring(b,p)}function g(a){a=e(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}function m(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}a=a.substring(a.indexOf(",")+1);a=window.atob?atob(a):Base64.decode(a,!0);var p=0;if(e(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=d&&d();else if(e(a,
+4),"IHDR"!=e(a,4))null!=d&&d();else{e(a,17);d=a.substring(0,p);do{var n=g(a);if("IDAT"==e(a,4)){d=a.substring(0,p-8);"pHYs"==c&&"dpi"==b?(b=Math.round(f/.0254),b=m(b)+m(b)+String.fromCharCode(1)):b=b+String.fromCharCode(0)+("zTXt"==c?String.fromCharCode(0):"")+f;f=4294967295;f=Editor.updateCRC(f,c,0,4);f=Editor.updateCRC(f,b,0,b.length);d+=m(b.length)+c+b+m(f^4294967295);d+=a.substring(p-8,a.length);break}d+=a.substring(p-8,p-4+n);e(a,n);e(a,4)}while(n);return"data:image/png;base64,"+(window.btoa?
btoa(d):Base64.encode(d,!0))}};if(window.ColorDialog){FilenameDialog.filenameHelpLink="https://desk.draw.io/support/solutions/articles/16000091426";var c=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,b){c.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()};var f=ColorDialog.resetRecentColors;ColorDialog.resetRecentColors=function(){f.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()}}window.EditDataDialog&&
(EditDataDialog.getDisplayIdForCell=function(a,c){var b=null;null!=a.editor.graph.getModel().getParent(c)?b=c.getId():null!=a.currentPage&&(b=a.currentPage.getId());return b});if(null!=window.StyleFormatPanel){var g=Format.prototype.init;Format.prototype.init=function(){g.apply(this,arguments);this.editorUi.editor.addListener("fileLoaded",this.update)};var p=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed||this.editorUi.editor.chromeless?
-p.apply(this,arguments):this.clear()};DiagramFormatPanel.prototype.isShadowOptionVisible=function(){var a=this.editorUi.getCurrentFile();return"1"==urlParams.embed||null!=a&&a.isEditable()};DiagramFormatPanel.prototype.isMathOptionVisible=function(a){return!1};var l=DiagramFormatPanel.prototype.addView;DiagramFormatPanel.prototype.addView=function(a){a=l.apply(this,arguments);this.editorUi.getCurrentFile();if(mxClient.IS_SVG&&this.isShadowOptionVisible()){var c=this.editorUi,b=c.editor.graph,f=this.createOption(mxResources.get("shadow"),
+p.apply(this,arguments):this.clear()};DiagramFormatPanel.prototype.isShadowOptionVisible=function(){var a=this.editorUi.getCurrentFile();return"1"==urlParams.embed||null!=a&&a.isEditable()};DiagramFormatPanel.prototype.isMathOptionVisible=function(a){return!1};var m=DiagramFormatPanel.prototype.addView;DiagramFormatPanel.prototype.addView=function(a){a=m.apply(this,arguments);this.editorUi.getCurrentFile();if(mxClient.IS_SVG&&this.isShadowOptionVisible()){var c=this.editorUi,b=c.editor.graph,f=this.createOption(mxResources.get("shadow"),
function(){return b.shadowVisible},function(a){var f=new ChangePageSetup(c);f.ignoreColor=!0;f.ignoreImage=!0;f.shadowVisible=a;b.model.execute(f)},{install:function(a){this.listener=function(){a(b.shadowVisible)};c.addListener("shadowVisibleChanged",this.listener)},destroy:function(){c.removeListener(this.listener)}});Editor.shadowOptionEnabled||(f.getElementsByTagName("input")[0].setAttribute("disabled","disabled"),mxUtils.setOpacity(f,60));a.appendChild(f)}return a};var n=DiagramFormatPanel.prototype.addOptions;
DiagramFormatPanel.prototype.addOptions=function(a){a=n.apply(this,arguments);var c=this.editorUi,b=c.editor.graph;if(b.isEnabled()){var f=c.getCurrentFile();if(null!=f&&f.isAutosaveOptional()){var d=this.createOption(mxResources.get("autosave"),function(){return c.editor.autosave},function(a){c.editor.setAutosave(a);c.editor.autosave&&f.isModified()&&f.fileChanged()},{install:function(a){this.listener=function(){a(c.editor.autosave)};c.editor.addListener("autosaveChanged",this.listener)},destroy:function(){c.editor.removeListener(this.listener)}});
a.appendChild(d)}}if(this.isMathOptionVisible()&&b.isEnabled()&&"undefined"!==typeof MathJax){d=this.createOption(mxResources.get("mathematicalTypesetting"),function(){return b.mathEnabled},function(a){c.actions.get("mathematicalTypesetting").funct()},{install:function(a){this.listener=function(){a(b.mathEnabled)};c.addListener("mathEnabledChanged",this.listener)},destroy:function(){c.removeListener(this.listener)}});d.style.paddingTop="5px";a.appendChild(d);var e=c.menus.createHelpLink("https://desk.draw.io/support/solutions/articles/16000032875");
@@ -2978,30 +2978,30 @@ null;StyleFormatPanel.prototype.findCommonProperties=function(a,c,b){if(null!=c)
Editor.commonVertexProperties):Array.prototype.push.apply(d.shape.customProperties,Editor.commonEdgeProperties)),f(d.shape.customProperties));a=a.getAttribute("customProperties");if(null!=a)try{f(JSON.parse(a))}catch(I){}}};var v=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=function(){var a=this.format.createSelectionState();"image"==a.style.shape||a.containsLabel||this.container.appendChild(this.addStyles(this.createPanel()));v.apply(this,arguments);if(Editor.enableCustomProperties){for(var c=
{},b=a.vertices,f=a.edges,d=0;d<b.length;d++)this.findCommonProperties(b[d],c,0==d);for(d=0;d<f.length;d++)this.findCommonProperties(f[d],c,0==b.length&&0==d);null!=Object.getOwnPropertyNames&&0<Object.getOwnPropertyNames(c).length&&this.container.appendChild(this.addProperties(this.createPanel(),c,a))}};var t=StyleFormatPanel.prototype.addStyleOps;StyleFormatPanel.prototype.addStyleOps=function(a){var c=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));
c.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");c.style.marginBottom="2px";c.style.width="100px";c.style.marginRight="2px";a.appendChild(c);c=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));c.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");c.style.marginBottom="2px";c.style.width="100px";a.appendChild(c);
-mxUtils.br(a);return t.apply(this,arguments)};EditorUi.prototype.propertiesCollapsed=!0;StyleFormatPanel.prototype.addProperties=function(a,c,b){function f(a,c,b,f){t.getModel().beginUpdate();try{var d=[],e=[];if(null!=b.index){for(var g=[],l=b.parentRow.nextSibling;l&&l.getAttribute("data-pName")==a;)g.push(l.getAttribute("data-pValue")),l=l.nextSibling;b.index<g.length?null!=f?g.splice(f,1):g[b.index]=c:g.push(c);null!=b.size&&g.length>b.size&&(g=g.slice(0,b.size));c=g.join(",");null!=b.countProperty&&
-(t.setCellStyles(b.countProperty,g.length,t.getSelectionCells()),d.push(b.countProperty),e.push(g.length))}t.setCellStyles(a,c,t.getSelectionCells());d.push(a);e.push(c);if(null!=b.dependentProps)for(a=0;a<b.dependentProps.length;a++){var p=b.dependentPropsDefVal[a],n=b.dependentPropsVals[a];if(n.length>c)n=n.slice(0,c);else for(var k=n.length;k<c;k++)n.push(p);n=n.join(",");t.setCellStyles(b.dependentProps[a],n,t.getSelectionCells());d.push(b.dependentProps[a]);e.push(n)}if("function"==typeof b.onChange)b.onChange(t,
+mxUtils.br(a);return t.apply(this,arguments)};EditorUi.prototype.propertiesCollapsed=!0;StyleFormatPanel.prototype.addProperties=function(a,c,b){function f(a,c,b,f){t.getModel().beginUpdate();try{var d=[],e=[];if(null!=b.index){for(var g=[],m=b.parentRow.nextSibling;m&&m.getAttribute("data-pName")==a;)g.push(m.getAttribute("data-pValue")),m=m.nextSibling;b.index<g.length?null!=f?g.splice(f,1):g[b.index]=c:g.push(c);null!=b.size&&g.length>b.size&&(g=g.slice(0,b.size));c=g.join(",");null!=b.countProperty&&
+(t.setCellStyles(b.countProperty,g.length,t.getSelectionCells()),d.push(b.countProperty),e.push(g.length))}t.setCellStyles(a,c,t.getSelectionCells());d.push(a);e.push(c);if(null!=b.dependentProps)for(a=0;a<b.dependentProps.length;a++){var p=b.dependentPropsDefVal[a],n=b.dependentPropsVals[a];if(n.length>c)n=n.slice(0,c);else for(var l=n.length;l<c;l++)n.push(p);n=n.join(",");t.setCellStyles(b.dependentProps[a],n,t.getSelectionCells());d.push(b.dependentProps[a]);e.push(n)}if("function"==typeof b.onChange)b.onChange(t,
c);u.editorUi.fireEvent(new mxEventObject("styleChanged","keys",d,"values",e,"cells",t.getSelectionCells()))}finally{t.getModel().endUpdate()}}function d(c,b,f){var d=mxUtils.getOffset(a,!0),e=mxUtils.getOffset(c,!0);b.style.position="absolute";b.style.left=e.x-d.x+"px";b.style.top=e.y-d.y+"px";b.style.width=c.offsetWidth+"px";b.style.height=c.offsetHeight-(f?4:0)+"px";b.style.zIndex=5}function e(a,c,b){var d=document.createElement("div");d.style.width="32px";d.style.height="4px";d.style.margin="2px";
-d.style.border="1px solid black";d.style.background=c&&"none"!=c?c:"url('"+Dialog.prototype.noColorImage+"')";btn=mxUtils.button("",mxUtils.bind(u,function(e){this.editorUi.pickColor(c,function(c){d.style.background="none"==c?"url('"+Dialog.prototype.noColorImage+"')":c;f(a,c,b)});mxEvent.consume(e)}));btn.style.height="12px";btn.style.width="40px";btn.className="geColorBtn";btn.appendChild(d);return btn}function g(a,c,b,d,e,g,l){null!=c&&(c=c.split(","),v.push({name:a,values:c,type:b,defVal:d,countProperty:e,
-parentRow:g,isDeletable:!0,flipBkg:l}));btn=mxUtils.button("+",mxUtils.bind(u,function(c){for(var p=g,u=0;null!=p.nextSibling;)if(p.nextSibling.getAttribute("data-pName")==a)p=p.nextSibling,u++;else break;var t={type:b,parentRow:g,index:u,isDeletable:!0,defVal:d,countProperty:e},u=n(a,"",t,0==u%2,l);f(a,d,t);p.parentNode.insertBefore(u,p.nextSibling);mxEvent.consume(c)}));btn.style.height="16px";btn.style.width="25px";btn.className="geColorBtn";return btn}function l(a,c,b,f,d,e,g){if(0<d){var l=Array(d);
-c=null!=c?c.split(","):[];for(var p=0;p<d;p++)l[p]=null!=c[p]?c[p]:null!=f?f:"";v.push({name:a,values:l,type:b,defVal:f,parentRow:e,flipBkg:g,size:d})}return document.createElement("div")}function p(a,c,b){var d=document.createElement("input");d.type="checkbox";d.checked="1"==c;mxEvent.addListener(d,"change",function(){f(a,d.checked?"1":"0",b)});return d}function n(c,b,n,t,k){var v=n.dispName,m=n.type,z=document.createElement("tr");z.className="gePropRow"+(k?"Dark":"")+(t?"Alt":"")+" gePropNonHeaderRow";
-z.setAttribute("data-pName",c);z.setAttribute("data-pValue",b);t=!1;null!=n.index&&(z.setAttribute("data-index",n.index),v=(null!=v?v:"")+"["+n.index+"]",t=!0);var y=document.createElement("td");y.className="gePropRowCell";y.innerHTML=mxUtils.htmlEntities(mxResources.get(v,null,v));t&&(y.style.textAlign="right");z.appendChild(y);y=document.createElement("td");y.className="gePropRowCell";if("color"==m)y.appendChild(e(c,b,n));else if("bool"==m||"boolean"==m)y.appendChild(p(c,b,n));else if("enum"==m){var x=
-n.enumList;for(k=0;k<x.length;k++)if(v=x[k],v.val==b){y.innerHTML=mxUtils.htmlEntities(mxResources.get(v.dispName,null,v.dispName));break}mxEvent.addListener(y,"click",mxUtils.bind(u,function(){var e=document.createElement("select");d(y,e);for(var g=0;g<x.length;g++){var l=x[g],p=document.createElement("option");p.value=mxUtils.htmlEntities(l.val);p.innerHTML=mxUtils.htmlEntities(mxResources.get(l.dispName,null,l.dispName));e.appendChild(p)}e.value=b;a.appendChild(e);mxEvent.addListener(e,"change",
-function(){var a=mxUtils.htmlEntities(e.value);f(c,a,n)});e.focus();mxEvent.addListener(e,"blur",function(){a.removeChild(e)})}))}else"dynamicArr"==m?y.appendChild(g(c,b,n.subType,n.subDefVal,n.countProperty,z,k)):"staticArr"==m?y.appendChild(l(c,b,n.subType,n.subDefVal,n.size,z,k)):(y.innerHTML=b,mxEvent.addListener(y,"click",mxUtils.bind(u,function(){function e(){var a=g.value,a=0==a.length&&"string"!=m?0:a;n.allowAuto&&(null!=a.trim&&"auto"==a.trim().toLowerCase()?(a="auto",m="string"):(a=parseFloat(a),
-a=isNaN(a)?0:a));null!=n.min&&a<n.min?a=n.min:null!=n.max&&a>n.max&&(a=n.max);a=mxUtils.htmlEntities(("int"==m?parseInt(a):a)+"");f(c,a,n)}var g=document.createElement("input");d(y,g,!0);g.value=b;g.className="gePropEditor";"int"!=m&&"float"!=m||n.allowAuto||(g.type="number",g.step="int"==m?"1":"any",null!=n.min&&(g.min=parseFloat(n.min)),null!=n.max&&(g.max=parseFloat(n.max)));a.appendChild(g);mxEvent.addListener(g,"keypress",function(a){13==a.keyCode&&e()});g.focus();mxEvent.addListener(g,"blur",
-function(){e()})})));n.isDeletable&&(k=mxUtils.button("-",mxUtils.bind(u,function(a){f(c,"",n,n.index);mxEvent.consume(a)})),k.style.height="16px",k.style.width="25px",k.style["float"]="right",k.className="geColorBtn",y.appendChild(k));z.appendChild(y);return z}var u=this,t=this.editorUi.editor.graph,v=[];a.style.position="relative";a.style.padding="0";var m=document.createElement("table");m.style.whiteSpace="nowrap";m.style.width="100%";var k=document.createElement("tr");k.className="gePropHeader";
-var z=document.createElement("th");z.className="gePropHeaderCell";var y=document.createElement("img");y.src=Sidebar.prototype.expandedImage;z.appendChild(y);mxUtils.write(z,mxResources.get("property"));k.style.cursor="pointer";var x=function(){var c=m.querySelectorAll(".gePropNonHeaderRow"),b;if(u.editorUi.propertiesCollapsed){y.src=Sidebar.prototype.collapsedImage;b="none";for(var f=a.childNodes.length-1;0<=f;f--)try{var d=a.childNodes[f],e=d.nodeName.toUpperCase();"INPUT"!=e&&"SELECT"!=e||a.removeChild(d)}catch(pa){}}else y.src=
-Sidebar.prototype.expandedImage,b="";for(f=0;f<c.length;f++)c[f].style.display=b};mxEvent.addListener(k,"click",function(){u.editorUi.propertiesCollapsed=!u.editorUi.propertiesCollapsed;x()});k.appendChild(z);z=document.createElement("th");z.className="gePropHeaderCell";z.innerHTML=mxResources.get("value");k.appendChild(z);m.appendChild(k);var q=!1,A=!1,B;for(B in c)if(k=c[B],"function"!=typeof k.isVisible||k.isVisible(b,this)){var D=null!=b.style[B]?mxUtils.htmlEntities(b.style[B]+""):null!=k.getDefaultValue?
-k.getDefaultValue(b,this):k.defVal;if("separator"==k.type)A=!A;else{if("staticArr"==k.type)k.size=parseInt(b.style[k.sizeProperty]||c[k.sizeProperty].defVal)||0;else if(null!=k.dependentProps){for(var C=k.dependentProps,F=[],K=[],z=0;z<C.length;z++){var E=b.style[C[z]];K.push(c[C[z]].subDefVal);F.push(null!=E?E.split(","):[])}k.dependentPropsDefVal=K;k.dependentPropsVals=F}m.appendChild(n(B,D,k,q,A));q=!q}}for(z=0;z<v.length;z++)for(k=v[z],c=k.parentRow,b=0;b<k.values.length;b++)B=n(k.name,k.values[b],
-{type:k.type,parentRow:k.parentRow,isDeletable:k.isDeletable,index:b,defVal:k.defVal,countProperty:k.countProperty,size:k.size},0==b%2,k.flipBkg),c.parentNode.insertBefore(B,c.nextSibling),c=B;a.appendChild(m);x();return a};StyleFormatPanel.prototype.addStyles=function(a){function c(a){function c(a){var c=mxUtils.button("",function(c){f.getModel().beginUpdate();try{var b=f.getSelectionCells();for(c=0;c<b.length;c++){for(var d=f.getModel().getStyle(b[c]),g=0;g<e.length;g++)d=mxUtils.removeStylename(d,
-e[g]);var l=f.getModel().isVertex(b[c])?f.defaultVertexStyle:f.defaultEdgeStyle;null!=a?(d=mxUtils.setStyle(d,mxConstants.STYLE_GRADIENTCOLOR,a.gradient||mxUtils.getValue(l,mxConstants.STYLE_GRADIENTCOLOR,null)),d=""==a.fill?mxUtils.setStyle(d,mxConstants.STYLE_FILLCOLOR,null):mxUtils.setStyle(d,mxConstants.STYLE_FILLCOLOR,a.fill||mxUtils.getValue(l,mxConstants.STYLE_FILLCOLOR,null)),d=""==a.stroke?mxUtils.setStyle(d,mxConstants.STYLE_STROKECOLOR,null):mxUtils.setStyle(d,mxConstants.STYLE_STROKECOLOR,
-a.stroke||mxUtils.getValue(l,mxConstants.STYLE_STROKECOLOR,null)),f.getModel().isVertex(b[c])&&(d=mxUtils.setStyle(d,mxConstants.STYLE_FONTCOLOR,a.font||mxUtils.getValue(l,mxConstants.STYLE_FONTCOLOR,null)))):(d=mxUtils.setStyle(d,mxConstants.STYLE_FILLCOLOR,mxUtils.getValue(l,mxConstants.STYLE_FILLCOLOR,"#ffffff")),d=mxUtils.setStyle(d,mxConstants.STYLE_STROKECOLOR,mxUtils.getValue(l,mxConstants.STYLE_STROKECOLOR,"#000000")),d=mxUtils.setStyle(d,mxConstants.STYLE_GRADIENTCOLOR,mxUtils.getValue(l,
-mxConstants.STYLE_GRADIENTCOLOR,null)),f.getModel().isVertex(b[c])&&(d=mxUtils.setStyle(d,mxConstants.STYLE_FONTCOLOR,mxUtils.getValue(l,mxConstants.STYLE_FONTCOLOR,null))));f.getModel().setStyle(b[c],d)}}finally{f.getModel().endUpdate()}});c.className="geStyleButton";c.style.width="36px";c.style.height="30px";c.style.margin="0px 6px 6px 0px";if(null!=a)null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?c.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+
+d.style.border="1px solid black";d.style.background=c&&"none"!=c?c:"url('"+Dialog.prototype.noColorImage+"')";btn=mxUtils.button("",mxUtils.bind(u,function(e){this.editorUi.pickColor(c,function(c){d.style.background="none"==c?"url('"+Dialog.prototype.noColorImage+"')":c;f(a,c,b)});mxEvent.consume(e)}));btn.style.height="12px";btn.style.width="40px";btn.className="geColorBtn";btn.appendChild(d);return btn}function g(a,c,b,d,e,g,m){null!=c&&(c=c.split(","),l.push({name:a,values:c,type:b,defVal:d,countProperty:e,
+parentRow:g,isDeletable:!0,flipBkg:m}));btn=mxUtils.button("+",mxUtils.bind(u,function(c){for(var p=g,u=0;null!=p.nextSibling;)if(p.nextSibling.getAttribute("data-pName")==a)p=p.nextSibling,u++;else break;var t={type:b,parentRow:g,index:u,isDeletable:!0,defVal:d,countProperty:e},u=n(a,"",t,0==u%2,m);f(a,d,t);p.parentNode.insertBefore(u,p.nextSibling);mxEvent.consume(c)}));btn.style.height="16px";btn.style.width="25px";btn.className="geColorBtn";return btn}function m(a,c,b,f,d,e,g){if(0<d){var m=Array(d);
+c=null!=c?c.split(","):[];for(var p=0;p<d;p++)m[p]=null!=c[p]?c[p]:null!=f?f:"";l.push({name:a,values:m,type:b,defVal:f,parentRow:e,flipBkg:g,size:d})}return document.createElement("div")}function p(a,c,b){var d=document.createElement("input");d.type="checkbox";d.checked="1"==c;mxEvent.addListener(d,"change",function(){f(a,d.checked?"1":"0",b)});return d}function n(c,b,n,t,l){var v=n.dispName,k=n.type,z=document.createElement("tr");z.className="gePropRow"+(l?"Dark":"")+(t?"Alt":"")+" gePropNonHeaderRow";
+z.setAttribute("data-pName",c);z.setAttribute("data-pValue",b);t=!1;null!=n.index&&(z.setAttribute("data-index",n.index),v=(null!=v?v:"")+"["+n.index+"]",t=!0);var y=document.createElement("td");y.className="gePropRowCell";y.innerHTML=mxUtils.htmlEntities(mxResources.get(v,null,v));t&&(y.style.textAlign="right");z.appendChild(y);y=document.createElement("td");y.className="gePropRowCell";if("color"==k)y.appendChild(e(c,b,n));else if("bool"==k||"boolean"==k)y.appendChild(p(c,b,n));else if("enum"==k){var x=
+n.enumList;for(l=0;l<x.length;l++)if(v=x[l],v.val==b){y.innerHTML=mxUtils.htmlEntities(mxResources.get(v.dispName,null,v.dispName));break}mxEvent.addListener(y,"click",mxUtils.bind(u,function(){var e=document.createElement("select");d(y,e);for(var g=0;g<x.length;g++){var m=x[g],p=document.createElement("option");p.value=mxUtils.htmlEntities(m.val);p.innerHTML=mxUtils.htmlEntities(mxResources.get(m.dispName,null,m.dispName));e.appendChild(p)}e.value=b;a.appendChild(e);mxEvent.addListener(e,"change",
+function(){var a=mxUtils.htmlEntities(e.value);f(c,a,n)});e.focus();mxEvent.addListener(e,"blur",function(){a.removeChild(e)})}))}else"dynamicArr"==k?y.appendChild(g(c,b,n.subType,n.subDefVal,n.countProperty,z,l)):"staticArr"==k?y.appendChild(m(c,b,n.subType,n.subDefVal,n.size,z,l)):(y.innerHTML=b,mxEvent.addListener(y,"click",mxUtils.bind(u,function(){function e(){var a=g.value,a=0==a.length&&"string"!=k?0:a;n.allowAuto&&(null!=a.trim&&"auto"==a.trim().toLowerCase()?(a="auto",k="string"):(a=parseFloat(a),
+a=isNaN(a)?0:a));null!=n.min&&a<n.min?a=n.min:null!=n.max&&a>n.max&&(a=n.max);a=mxUtils.htmlEntities(("int"==k?parseInt(a):a)+"");f(c,a,n)}var g=document.createElement("input");d(y,g,!0);g.value=b;g.className="gePropEditor";"int"!=k&&"float"!=k||n.allowAuto||(g.type="number",g.step="int"==k?"1":"any",null!=n.min&&(g.min=parseFloat(n.min)),null!=n.max&&(g.max=parseFloat(n.max)));a.appendChild(g);mxEvent.addListener(g,"keypress",function(a){13==a.keyCode&&e()});g.focus();mxEvent.addListener(g,"blur",
+function(){e()})})));n.isDeletable&&(l=mxUtils.button("-",mxUtils.bind(u,function(a){f(c,"",n,n.index);mxEvent.consume(a)})),l.style.height="16px",l.style.width="25px",l.style["float"]="right",l.className="geColorBtn",y.appendChild(l));z.appendChild(y);return z}var u=this,t=this.editorUi.editor.graph,l=[];a.style.position="relative";a.style.padding="0";var k=document.createElement("table");k.style.whiteSpace="nowrap";k.style.width="100%";var v=document.createElement("tr");v.className="gePropHeader";
+var z=document.createElement("th");z.className="gePropHeaderCell";var y=document.createElement("img");y.src=Sidebar.prototype.expandedImage;z.appendChild(y);mxUtils.write(z,mxResources.get("property"));v.style.cursor="pointer";var x=function(){var c=k.querySelectorAll(".gePropNonHeaderRow"),b;if(u.editorUi.propertiesCollapsed){y.src=Sidebar.prototype.collapsedImage;b="none";for(var f=a.childNodes.length-1;0<=f;f--)try{var d=a.childNodes[f],e=d.nodeName.toUpperCase();"INPUT"!=e&&"SELECT"!=e||a.removeChild(d)}catch(pa){}}else y.src=
+Sidebar.prototype.expandedImage,b="";for(f=0;f<c.length;f++)c[f].style.display=b};mxEvent.addListener(v,"click",function(){u.editorUi.propertiesCollapsed=!u.editorUi.propertiesCollapsed;x()});v.appendChild(z);z=document.createElement("th");z.className="gePropHeaderCell";z.innerHTML=mxResources.get("value");v.appendChild(z);k.appendChild(v);var q=!1,A=!1,B;for(B in c)if(v=c[B],"function"!=typeof v.isVisible||v.isVisible(b,this)){var D=null!=b.style[B]?mxUtils.htmlEntities(b.style[B]+""):null!=v.getDefaultValue?
+v.getDefaultValue(b,this):v.defVal;if("separator"==v.type)A=!A;else{if("staticArr"==v.type)v.size=parseInt(b.style[v.sizeProperty]||c[v.sizeProperty].defVal)||0;else if(null!=v.dependentProps){for(var C=v.dependentProps,F=[],K=[],z=0;z<C.length;z++){var E=b.style[C[z]];K.push(c[C[z]].subDefVal);F.push(null!=E?E.split(","):[])}v.dependentPropsDefVal=K;v.dependentPropsVals=F}k.appendChild(n(B,D,v,q,A));q=!q}}for(z=0;z<l.length;z++)for(v=l[z],c=v.parentRow,b=0;b<v.values.length;b++)B=n(v.name,v.values[b],
+{type:v.type,parentRow:v.parentRow,isDeletable:v.isDeletable,index:b,defVal:v.defVal,countProperty:v.countProperty,size:v.size},0==b%2,v.flipBkg),c.parentNode.insertBefore(B,c.nextSibling),c=B;a.appendChild(k);x();return a};StyleFormatPanel.prototype.addStyles=function(a){function c(a){function c(a){var c=mxUtils.button("",function(c){f.getModel().beginUpdate();try{var b=f.getSelectionCells();for(c=0;c<b.length;c++){for(var d=f.getModel().getStyle(b[c]),g=0;g<e.length;g++)d=mxUtils.removeStylename(d,
+e[g]);var m=f.getModel().isVertex(b[c])?f.defaultVertexStyle:f.defaultEdgeStyle;null!=a?(d=mxUtils.setStyle(d,mxConstants.STYLE_GRADIENTCOLOR,a.gradient||mxUtils.getValue(m,mxConstants.STYLE_GRADIENTCOLOR,null)),d=""==a.fill?mxUtils.setStyle(d,mxConstants.STYLE_FILLCOLOR,null):mxUtils.setStyle(d,mxConstants.STYLE_FILLCOLOR,a.fill||mxUtils.getValue(m,mxConstants.STYLE_FILLCOLOR,null)),d=""==a.stroke?mxUtils.setStyle(d,mxConstants.STYLE_STROKECOLOR,null):mxUtils.setStyle(d,mxConstants.STYLE_STROKECOLOR,
+a.stroke||mxUtils.getValue(m,mxConstants.STYLE_STROKECOLOR,null)),f.getModel().isVertex(b[c])&&(d=mxUtils.setStyle(d,mxConstants.STYLE_FONTCOLOR,a.font||mxUtils.getValue(m,mxConstants.STYLE_FONTCOLOR,null)))):(d=mxUtils.setStyle(d,mxConstants.STYLE_FILLCOLOR,mxUtils.getValue(m,mxConstants.STYLE_FILLCOLOR,"#ffffff")),d=mxUtils.setStyle(d,mxConstants.STYLE_STROKECOLOR,mxUtils.getValue(m,mxConstants.STYLE_STROKECOLOR,"#000000")),d=mxUtils.setStyle(d,mxConstants.STYLE_GRADIENTCOLOR,mxUtils.getValue(m,
+mxConstants.STYLE_GRADIENTCOLOR,null)),f.getModel().isVertex(b[c])&&(d=mxUtils.setStyle(d,mxConstants.STYLE_FONTCOLOR,mxUtils.getValue(m,mxConstants.STYLE_FONTCOLOR,null))));f.getModel().setStyle(b[c],d)}}finally{f.getModel().endUpdate()}});c.className="geStyleButton";c.style.width="36px";c.style.height="30px";c.style.margin="0px 6px 6px 0px";if(null!=a)null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?c.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+
a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":c.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+" 100%)":a.fill==mxConstants.NONE?c.style.background="url('"+Dialog.prototype.noColorImage+"')":c.style.backgroundColor=""==a.fill?mxUtils.getValue(f.defaultVertexStyle,mxConstants.STYLE_FILLCOLOR,"dark"==uiTheme?"#2a2a2a":"#ffffff"):a.fill||mxUtils.getValue(f.defaultVertexStyle,mxConstants.STYLE_FILLCOLOR,"dark"==uiTheme?"#2a2a2a":"#ffffff"),c.style.border=a.stroke==mxConstants.NONE?
"1px solid transparent":""==a.stroke?"1px solid "+mxUtils.getValue(f.defaultVertexStyle,mxConstants.STYLE_STROKECOLOR,"dark"!=uiTheme?"#2a2a2a":"#ffffff"):"1px solid "+(a.stroke||mxUtils.getValue(f.defaultVertexStyle,mxConstants.STYLE_STROKECOLOR,"dark"!=uiTheme?"#2a2a2a":"#ffffff"));else{var b=mxUtils.getValue(f.defaultVertexStyle,mxConstants.STYLE_FILLCOLOR,"#ffffff"),g=mxUtils.getValue(f.defaultVertexStyle,mxConstants.STYLE_STROKECOLOR,"#000000");c.style.backgroundColor=b;c.style.border="1px solid "+
g}d.appendChild(c)}d.innerHTML="";for(var b=0;b<a.length;b++)0<b&&0==mxUtils.mod(b,4)&&mxUtils.br(d),c(a[b])}function b(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var f=this.editorUi.editor.graph,d=document.createElement("div");d.style.whiteSpace="nowrap";d.style.paddingLeft="24px";d.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(d);
var e="plain-gray plain-blue plain-green plain-turquoise plain-orange plain-yellow plain-red plain-pink plain-purple gray blue green turquoise orange yellow red pink purple".split(" ");null==this.editorUi.currentScheme&&(this.editorUi.currentScheme=0);var g=document.createElement("div");g.style.cssText="position:absolute;left:10px;top:8px;bottom:8px;width:20px;margin:4px;opacity:0.5;background-repeat:no-repeat;background-position:center center;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQBAMAAADQT4M0AAAAIVBMVEUAAAB2dnZ4eHh3d3d1dXVxcXF2dnZ2dnZ2dnZxcXF2dnYmb3w1AAAACnRSTlMAfCTkhhvb7cQSPH2JPgAAADRJREFUCNdjwACMAmBKaiGYs2oJmLPKAZ3DabU8AMRTXpUKopislqFyVzCAuUZgikkBZjoAcMYLnp53P/UAAAAASUVORK5CYII=);";
-mxEvent.addListener(g,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme-1,this.defaultColorSchemes.length);c(this.defaultColorSchemes[this.editorUi.currentScheme])}));var l=document.createElement("div");l.style.cssText="position:absolute;left:202px;top:8px;bottom:8px;width:20px;margin:4px;opacity:0.5;background-repeat:no-repeat;background-position:center center;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQBAMAAADQT4M0AAAAIVBMVEUAAAB2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnYBuwCcAAAACnRSTlMAfCTkhhvb7cQSPH2JPgAAADZJREFUCNdjQAOMAmBKaiGY8loF5rKswsZlrVo8AUiFrTICcbIWK8A5DF1gDoMymMPApIAwHwCS0Qx/U7qCBQAAAABJRU5ErkJggg==);";
-1<this.defaultColorSchemes.length&&(a.appendChild(g),a.appendChild(l));mxEvent.addListener(l,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme+1,this.defaultColorSchemes.length);c(this.defaultColorSchemes[this.editorUi.currentScheme])}));b(g);b(l);c(this.defaultColorSchemes[this.editorUi.currentScheme]);return a};StyleFormatPanel.prototype.addEditOps=function(a){var c=this.format.getSelectionState(),b=null;1==this.editorUi.editor.graph.getSelectionCount()&&
+mxEvent.addListener(g,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme-1,this.defaultColorSchemes.length);c(this.defaultColorSchemes[this.editorUi.currentScheme])}));var m=document.createElement("div");m.style.cssText="position:absolute;left:202px;top:8px;bottom:8px;width:20px;margin:4px;opacity:0.5;background-repeat:no-repeat;background-position:center center;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAQBAMAAADQT4M0AAAAIVBMVEUAAAB2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnZ2dnYBuwCcAAAACnRSTlMAfCTkhhvb7cQSPH2JPgAAADZJREFUCNdjQAOMAmBKaiGY8loF5rKswsZlrVo8AUiFrTICcbIWK8A5DF1gDoMymMPApIAwHwCS0Qx/U7qCBQAAAABJRU5ErkJggg==);";
+1<this.defaultColorSchemes.length&&(a.appendChild(g),a.appendChild(m));mxEvent.addListener(m,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme+1,this.defaultColorSchemes.length);c(this.defaultColorSchemes[this.editorUi.currentScheme])}));b(g);b(m);c(this.defaultColorSchemes[this.editorUi.currentScheme]);return a};StyleFormatPanel.prototype.addEditOps=function(a){var c=this.format.getSelectionState(),b=null;1==this.editorUi.editor.graph.getSelectionCount()&&
(b=mxUtils.button(mxResources.get("editStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("editStyle").funct()})),b.setAttribute("title",mxResources.get("editStyle")+" ("+this.editorUi.actions.get("editStyle").shortcut+")"),b.style.width="202px",b.style.marginBottom="2px",a.appendChild(b));var f=this.editorUi.editor.graph,d=f.view.getState(f.getSelectionCell());1==f.getSelectionCount()&&null!=d&&null!=d.shape&&null!=d.shape.stencil?(c=mxUtils.button(mxResources.get("editShape"),mxUtils.bind(this,
function(a){this.editorUi.actions.get("editShape").funct()})),c.setAttribute("title",mxResources.get("editShape")),c.style.marginBottom="2px",null==b?c.style.width="202px":(b.style.width="100px",c.style.width="100px",c.style.marginLeft="2px"),a.appendChild(c)):c.image&&(c=mxUtils.button(mxResources.get("editImage"),mxUtils.bind(this,function(a){this.editorUi.actions.get("image").funct()})),c.setAttribute("title",mxResources.get("editImage")),c.style.marginBottom="2px",null==b?c.style.width="202px":
(b.style.width="100px",c.style.width="100px",c.style.marginLeft="2px"),a.appendChild(c));return a}}Graph.prototype.defaultThemeName="default-style2";Graph.prototype.lastPasteXml=null;Graph.prototype.pasteCounter=0;Graph.prototype.defaultScrollbars="0"!=urlParams.sb;Graph.prototype.defaultPageVisible="0"!=urlParams.pv;Graph.prototype.shadowId="dropShadow";Graph.prototype.svgShadowColor="#3D4574";Graph.prototype.svgShadowOpacity="0.4";Graph.prototype.svgShadowBlur="1.7";Graph.prototype.svgShadowSize=
@@ -3011,9 +3011,9 @@ this.layoutManager.getLayout=function(a){var c=this.graph.getCellStyle(a);if(nul
c.childLayout)return b=new mxTableLayout(this.graph),b.rows=c.tableRows||2,b.columns=c.tableColumns||2,b.colPercentages=c.colPercentages,b.rowPercentages=c.rowPercentages,b.equalColumns="1"==mxUtils.getValue(c,"equalColumns",b.colPercentages?"0":"1"),b.equalRows="1"==mxUtils.getValue(c,"equalRows",b.rowPercentages?"0":"1"),b.resizeParent="1"==mxUtils.getValue(c,"resizeParent","1"),b.border=c.tableBorder||b.border,b.marginLeft=c.marginLeft||0,b.marginRight=c.marginRight||0,b.marginTop=c.marginTop||
0,b.marginBottom=c.marginBottom||0,b.autoAddCol="1"==mxUtils.getValue(c,"autoAddCol","0"),b.autoAddRow="1"==mxUtils.getValue(c,"autoAddRow",b.autoAddCol?"0":"1"),b.colWidths=c.colWidths||"100",b.rowHeights=c.rowHeights||"50",b}return f.apply(this,arguments)};this.updateGlobalUrlVariables()};var A=Graph.prototype.isFastZoomEnabled;Graph.prototype.isFastZoomEnabled=function(){return A.apply(this,arguments)&&(!this.shadowVisible||!mxClient.IS_SF)};Graph.prototype.updateGlobalUrlVariables=function(){this.globalVars=
Editor.globalVars;if(null!=urlParams.vars)try{this.globalVars=null!=this.globalVars?mxUtils.clone(this.globalVars):{};var a=JSON.parse(decodeURIComponent(urlParams.vars));if(null!=a)for(var c in a)this.globalVars[c]=a[c]}catch(z){null!=window.console&&console.log("Error in vars URL parameter: "+z)}};Graph.prototype.getExportVariables=function(){return null!=this.globalVars?mxUtils.clone(this.globalVars):{}};var B=Graph.prototype.getGlobalVariable;Graph.prototype.getGlobalVariable=function(a){var c=
-B.apply(this,arguments);null==c&&null!=this.globalVars&&(c=this.globalVars[a]);return c};Graph.prototype.getDefaultStylesheet=function(){if(null==this.defaultStylesheet){var a=this.themes["default-style2"];this.defaultStylesheet=(new mxCodec(a.ownerDocument)).decode(a)}return this.defaultStylesheet};Graph.prototype.isViewer=function(){return urlParams.viewer};var D=Graph.prototype.getSvg;Graph.prototype.getSvg=function(a,c,b,f,d,e,g,l,p,n,u){var t=null;null!=this.themes&&"darkTheme"==this.defaultThemeName&&
-(t=this.stylesheet,this.stylesheet=this.getDefaultStylesheet(),this.refresh());var k=D.apply(this,arguments);if(u&&null!=this.extFonts&&0<this.extFonts.length){var v=k.ownerDocument,m=null!=v.createElementNS?v.createElementNS(mxConstants.NS_SVG,"style"):v.createElement("style");null!=v.setAttributeNS?m.setAttributeNS("type","text/css"):m.setAttribute("type","text/css");for(var z="",y="",x=0;x<this.extFonts.length;x++){var q=this.extFonts[x].name,B=this.extFonts[x].url;0==B.indexOf(Editor.GOOGLE_FONTS)?
-z+="@import url("+B+");\n":y+='@font-face {\nfont-family: "'+q+'";\nsrc: url("'+B+'");\n}\n'}m.appendChild(v.createTextNode(z+y));k.getElementsByTagName("defs")[0].appendChild(m)}null!=t&&(this.stylesheet=t,this.refresh());return k};var C=Graph.prototype.createSvgImageExport;Graph.prototype.createSvgImageExport=function(){var a=C.apply(this,arguments);if(this.mathEnabled){this.container.getBoundingClientRect();var c=a.drawText;a.drawText=function(a,b){if(null!=a.text&&null!=a.text.value&&a.text.checkBounds()&&
+B.apply(this,arguments);null==c&&null!=this.globalVars&&(c=this.globalVars[a]);return c};Graph.prototype.getDefaultStylesheet=function(){if(null==this.defaultStylesheet){var a=this.themes["default-style2"];this.defaultStylesheet=(new mxCodec(a.ownerDocument)).decode(a)}return this.defaultStylesheet};Graph.prototype.isViewer=function(){return urlParams.viewer};var D=Graph.prototype.getSvg;Graph.prototype.getSvg=function(a,c,b,f,d,e,g,m,p,n,u){var t=null;null!=this.themes&&"darkTheme"==this.defaultThemeName&&
+(t=this.stylesheet,this.stylesheet=this.getDefaultStylesheet(),this.refresh());var l=D.apply(this,arguments);if(u&&null!=this.extFonts&&0<this.extFonts.length){var k=l.ownerDocument,v=null!=k.createElementNS?k.createElementNS(mxConstants.NS_SVG,"style"):k.createElement("style");null!=k.setAttributeNS?v.setAttributeNS("type","text/css"):v.setAttribute("type","text/css");for(var z="",y="",x=0;x<this.extFonts.length;x++){var q=this.extFonts[x].name,B=this.extFonts[x].url;0==B.indexOf(Editor.GOOGLE_FONTS)?
+z+="@import url("+B+");\n":y+='@font-face {\nfont-family: "'+q+'";\nsrc: url("'+B+'");\n}\n'}v.appendChild(k.createTextNode(z+y));l.getElementsByTagName("defs")[0].appendChild(v)}null!=t&&(this.stylesheet=t,this.refresh());return l};var C=Graph.prototype.createSvgImageExport;Graph.prototype.createSvgImageExport=function(){var a=C.apply(this,arguments);if(this.mathEnabled){this.container.getBoundingClientRect();var c=a.drawText;a.drawText=function(a,b){if(null!=a.text&&null!=a.text.value&&a.text.checkBounds()&&
(mxUtils.isNode(a.text.value)||a.text.dialect==mxConstants.DIALECT_STRICTHTML)){var f=a.text.getContentNode();if(null!=f){f=f.cloneNode(!0);if(f.getElementsByTagNameNS)for(var d=f.getElementsByTagNameNS("http://www.w3.org/1998/Math/MathML","math");0<d.length;)d[0].parentNode.removeChild(d[0]);null!=f.innerHTML&&(d=a.text.value,a.text.value=f.innerHTML,c.apply(this,arguments),a.text.value=d)}}else c.apply(this,arguments)}}return a};var x=mxGraphView.prototype.validateBackgroundPage;mxGraphView.prototype.validateBackgroundPage=
function(){x.apply(this,arguments);if(mxClient.IS_GC&&null!=this.getDrawPane()){var a=this.getDrawPane().parentNode;!this.graph.mathEnabled||mxClient.NO_FO||null!=this.webKitForceRepaintNode&&null!=this.webKitForceRepaintNode.parentNode||"svg"!=this.graph.container.firstChild.nodeName?null==this.webKitForceRepaintNode||this.graph.mathEnabled&&("svg"==this.graph.container.firstChild.nodeName||this.graph.container.firstChild==this.webKitForceRepaintNode)||(null!=this.webKitForceRepaintNode.parentNode&&
this.webKitForceRepaintNode.parentNode.removeChild(this.webKitForceRepaintNode),this.webKitForceRepaintNode=null):(this.webKitForceRepaintNode=document.createElement("div"),this.webKitForceRepaintNode.style.cssText="position:absolute;",a.ownerSVGElement.parentNode.insertBefore(this.webKitForceRepaintNode,a.ownerSVGElement))}};var F=Graph.prototype.loadStylesheet;Graph.prototype.loadStylesheet=function(){F.apply(this,arguments);this.currentStyle="default-style2"};Graph.prototype.handleCustomLink=function(a){if("data:action/json,"==
@@ -3022,8 +3022,8 @@ a.substring(0,17)&&(a=JSON.parse(a.substring(17)),null!=a.actions)){for(var c=0;
null!=b&&"data:action/json,"==b.substring(0,17)&&this.setLinkForCell(c,this.updateCustomLink(a,b));if(this.isHtmlLabel(c)){var f=document.createElement("div");f.innerHTML=this.getLabel(c);for(var d=f.getElementsByTagName("a"),e=!1,g=0;g<d.length;g++)b=d[g].getAttribute("href"),null!=b&&"data:action/json,"==b.substring(0,17)&&(d[g].setAttribute("href",this.updateCustomLink(a,b)),e=!0);e&&this.labelChanged(c,f.innerHTML)}};Graph.prototype.updateCustomLink=function(a,c){if("data:action/json,"==c.substring(0,
17))try{var b=JSON.parse(c.substring(17));null!=b.actions&&(this.updateCustomLinkActions(a,b.actions),c="data:action/json,"+JSON.stringify(b))}catch(L){}return c};Graph.prototype.updateCustomLinkActions=function(a,c){for(var b=0;b<c.length;b++){var f=c[b];this.updateCustomLinkAction(a,f.toggle);this.updateCustomLinkAction(a,f.show);this.updateCustomLinkAction(a,f.hide);this.updateCustomLinkAction(a,f.select);this.updateCustomLinkAction(a,f.highlight);this.updateCustomLinkAction(a,f.scroll)}};Graph.prototype.updateCustomLinkAction=
function(a,c){if(null!=c&&null!=c.cells){for(var b=[],f=0;f<c.cells.length;f++)if("*"==c.cells[f])b.push(c.cells[f]);else{var d=a[c.cells[f]];null!=d?""!=d&&b.push(d):b.push(c.cells[f])}c.cells=b}};Graph.prototype.getCellsForAction=function(a,c){return this.getCellsById(a.cells).concat(this.getCellsForTags(a.tags,null,null,c))};Graph.prototype.getCellsById=function(a){var c=[];if(null!=a)for(var b=0;b<a.length;b++)if("*"==a[b])var f=this.getDefaultParent(),c=c.concat(this.model.filterDescendants(function(a){return a!=
-f},f));else{var d=this.model.getCell(a[b]);null!=d&&c.push(d)}return c};Graph.prototype.getCellsForTags=function(a,c,b,f){var d=[];if(null!=a){c=null!=c?c:this.model.getDescendants(this.model.getRoot());b=null!=b?b:"tags";for(var e=0,g={},l=0;l<a.length;l++)0<a[l].length&&(g[a[l].toLowerCase()]=!0,e++);for(l=0;l<c.length;l++)if(f&&this.model.getParent(c[l])==this.model.root||this.model.isVertex(c[l])||this.model.isEdge(c[l])){var p=null!=c[l].value&&"object"==typeof c[l].value?mxUtils.trim(c[l].value.getAttribute(b)||
-""):"",n=!1;if(0<p.length){if(p=p.toLowerCase().split(" "),p.length>=a.length){for(var u=n=0;u<p.length&&n<e;u++)null!=g[p[u]]&&n++;n=n==e}}else n=0==a.length;n&&d.push(c[l])}}return d};Graph.prototype.toggleCells=function(a){this.model.beginUpdate();try{for(var c=0;c<a.length;c++)this.model.setVisible(a[c],!this.model.isVisible(a[c]))}finally{this.model.endUpdate()}};Graph.prototype.setCellsVisible=function(a,c){this.model.beginUpdate();try{for(var b=0;b<a.length;b++)this.model.setVisible(a[b],c)}finally{this.model.endUpdate()}};
+f},f));else{var d=this.model.getCell(a[b]);null!=d&&c.push(d)}return c};Graph.prototype.getCellsForTags=function(a,c,b,f){var d=[];if(null!=a){c=null!=c?c:this.model.getDescendants(this.model.getRoot());b=null!=b?b:"tags";for(var e=0,g={},m=0;m<a.length;m++)0<a[m].length&&(g[a[m].toLowerCase()]=!0,e++);for(m=0;m<c.length;m++)if(f&&this.model.getParent(c[m])==this.model.root||this.model.isVertex(c[m])||this.model.isEdge(c[m])){var p=null!=c[m].value&&"object"==typeof c[m].value?mxUtils.trim(c[m].value.getAttribute(b)||
+""):"",n=!1;if(0<p.length){if(p=p.toLowerCase().split(" "),p.length>=a.length){for(var u=n=0;u<p.length&&n<e;u++)null!=g[p[u]]&&n++;n=n==e}}else n=0==a.length;n&&d.push(c[m])}}return d};Graph.prototype.toggleCells=function(a){this.model.beginUpdate();try{for(var c=0;c<a.length;c++)this.model.setVisible(a[c],!this.model.isVisible(a[c]))}finally{this.model.endUpdate()}};Graph.prototype.setCellsVisible=function(a,c){this.model.beginUpdate();try{for(var b=0;b<a.length;b++)this.model.setVisible(a[b],c)}finally{this.model.endUpdate()}};
Graph.prototype.highlightCells=function(a,c,b,f){for(var d=0;d<a.length;d++)this.highlightCell(a[d],c,b,f)};Graph.prototype.highlightCell=function(a,c,b,f){c=null!=c?c:mxConstants.DEFAULT_VALID_COLOR;b=null!=b?b:1E3;a=this.view.getState(a);if(null!=a){var d=Math.max(5,mxUtils.getValue(a.style,mxConstants.STYLE_STROKEWIDTH,1)+4),e=new mxCellHighlight(this,c,d,!1);null!=f&&(e.opacity=f);e.highlight(a);window.setTimeout(function(){null!=e.shape&&(mxUtils.setPrefixedStyle(e.shape.node.style,"transition",
"all 1200ms ease-in-out"),e.shape.node.style.opacity=0);window.setTimeout(function(){e.destroy()},1200)},b)}};Graph.prototype.addSvgShadow=function(a,c,b){b=null!=b?b:!1;var f=a.ownerDocument,d=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"filter"):f.createElement("filter");d.setAttribute("id",this.shadowId);var e=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"feGaussianBlur"):f.createElement("feGaussianBlur");e.setAttribute("in","SourceAlpha");e.setAttribute("stdDeviation",
this.svgShadowBlur);e.setAttribute("result","blur");d.appendChild(e);e=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"feOffset"):f.createElement("feOffset");e.setAttribute("in","blur");e.setAttribute("dx",this.svgShadowSize);e.setAttribute("dy",this.svgShadowSize);e.setAttribute("result","offsetBlur");d.appendChild(e);e=null!=f.createElementNS?f.createElementNS(mxConstants.NS_SVG,"feFlood"):f.createElement("feFlood");e.setAttribute("flood-color",this.svgShadowColor);e.setAttribute("flood-opacity",
@@ -3040,41 +3040,41 @@ STENCIL_PATH+"/flowchart.xml"];mxStencilRegistry.libraries.ios=[SHAPES_PATH+"/mo
"/ibm.xml"];mxStencilRegistry.libraries.cabinets=[SHAPES_PATH+"/mxCabinets.js",STENCIL_PATH+"/cabinets.xml"];mxStencilRegistry.libraries.archimate=[SHAPES_PATH+"/mxArchiMate.js"];mxStencilRegistry.libraries.archimate3=[SHAPES_PATH+"/mxArchiMate3.js"];mxStencilRegistry.libraries.sysml=[SHAPES_PATH+"/mxSysML.js"];mxStencilRegistry.libraries.eip=[SHAPES_PATH+"/mxEip.js",STENCIL_PATH+"/eip.xml"];mxStencilRegistry.libraries.networks=[SHAPES_PATH+"/mxNetworks.js",STENCIL_PATH+"/networks.xml"];mxStencilRegistry.libraries.aws3d=
[SHAPES_PATH+"/mxAWS3D.js",STENCIL_PATH+"/aws3d.xml"];mxStencilRegistry.libraries.aws4=[SHAPES_PATH+"/mxAWS4.js",STENCIL_PATH+"/aws4.xml"];mxStencilRegistry.libraries.aws4b=[SHAPES_PATH+"/mxAWS4.js",STENCIL_PATH+"/aws4.xml"];mxStencilRegistry.libraries.veeam=[STENCIL_PATH+"/veeam/2d.xml",STENCIL_PATH+"/veeam/3d.xml",STENCIL_PATH+"/veeam/veeam.xml"];mxStencilRegistry.libraries.veeam2=[STENCIL_PATH+"/veeam/2d.xml",STENCIL_PATH+"/veeam/3d.xml",STENCIL_PATH+"/veeam/veeam2.xml"];mxStencilRegistry.libraries.pid2inst=
[SHAPES_PATH+"/pid2/mxPidInstruments.js"];mxStencilRegistry.libraries.pid2misc=[SHAPES_PATH+"/pid2/mxPidMisc.js",STENCIL_PATH+"/pid/misc.xml"];mxStencilRegistry.libraries.pid2valves=[SHAPES_PATH+"/pid2/mxPidValves.js"];mxStencilRegistry.libraries.pidFlowSensors=[STENCIL_PATH+"/pid/flow_sensors.xml"];mxMarker.getPackageForType=function(a){var c=null;null!=a&&0<a.length&&("ER"==a.substring(0,2)?c="mxgraph.er":"sysML"==a.substring(0,5)&&(c="mxgraph.sysml"));return c};var G=mxMarker.createMarker;mxMarker.createMarker=
-function(a,c,b,f,d,e,g,l,p,n){if(null!=b&&null==mxMarker.markers[b]){var u=this.getPackageForType(b);null!=u&&mxStencilRegistry.getStencil(u)}return G.apply(this,arguments)};PrintDialog.prototype.create=function(a,c){function b(){v.value=Math.max(1,Math.min(l,Math.max(parseInt(v.value),parseInt(k.value))));k.value=Math.max(1,Math.min(l,Math.min(parseInt(v.value),parseInt(k.value))))}function f(c){function b(c,b,e){var g=c.useCssTransforms,l=c.currentTranslate,p=c.currentScale,n=c.view.translate,u=
-c.view.scale;c.useCssTransforms&&(c.useCssTransforms=!1,c.currentTranslate=new mxPoint(0,0),c.currentScale=1,c.view.translate=new mxPoint(0,0),c.view.scale=1);var t=c.getGraphBounds(),k=0,m=0,v=ta.get(),x=1/c.pageScale,A=B.checked;if(A)var x=parseInt(K.value),z=parseInt(ma.value),x=Math.min(v.height*z/(t.height/c.view.scale),v.width*x/(t.width/c.view.scale));else x=parseInt(q.value)/(100*c.pageScale),isNaN(x)&&(f=1/c.pageScale,q.value="100 %");v=mxRectangle.fromRectangle(v);v.width=Math.ceil(v.width*
-f);v.height=Math.ceil(v.height*f);x*=f;!A&&c.pageVisible?(t=c.getPageLayout(),k-=t.x*v.width,m-=t.y*v.height):A=!0;if(null==b){b=PrintDialog.createPrintPreview(c,x,v,0,k,m,A);b.pageSelector=!1;b.mathEnabled=!1;k=a.getCurrentFile();null!=k&&(b.title=k.getTitle());var y=b.writeHead;b.writeHead=function(b){y.apply(this,arguments);null!=a.editor.fontCss&&(b.writeln('<style type="text/css">'),b.writeln(a.editor.fontCss),b.writeln("</style>"));if(null!=c.extFonts)for(var f=0;f<c.extFonts.length;f++){var d=
-c.extFonts[f].name,e=c.extFonts[f].url;0==e.indexOf(Editor.GOOGLE_FONTS)?b.writeln('<link rel="stylesheet" href="'+e+'" charset="UTF-8" type="text/css">'):(b.writeln('<style type="text/css">'),b.writeln('@font-face {\n\tfont-family: "'+d+'";\n\tsrc: url("'+e+'");\n}'),b.writeln("</style>"))}};if("undefined"!==typeof MathJax){var C=b.renderPage;b.renderPage=function(c,b,f,d,e,g){var l=mxClient.NO_FO;mxClient.NO_FO=this.graph.mathEnabled&&!a.editor.useForeignObjectForMath?!0:a.editor.originalNoForeignObject;
-var p=C.apply(this,arguments);mxClient.NO_FO=l;this.graph.mathEnabled?this.mathEnabled=this.mathEnabled||!0:p.className="geDisableMathJax";return p}}k=null;null!=d.themes&&"darkTheme"==d.defaultThemeName&&(k=d.stylesheet,d.stylesheet=d.getDefaultStylesheet(),d.refresh());b.open(null,null,e,!0);null!=k&&(d.stylesheet=k,d.refresh())}else{v=c.background;if(null==v||""==v||v==mxConstants.NONE)v="#ffffff";b.backgroundColor=v;b.autoOrigin=A;b.appendGraph(c,x,k,m,e,!0);if(null!=c.extFonts&&null!=b.wnd)for(e=
-0;e<c.extFonts.length;e++)k=c.extFonts[e].name,m=c.extFonts[e].url,0==m.indexOf(Editor.GOOGLE_FONTS)?b.wnd.document.writeln('<link rel="stylesheet" href="'+m+'" charset="UTF-8" type="text/css">'):(b.wnd.document.writeln('<style type="text/css">'),b.wnd.document.writeln('@font-face {\n\tfont-family: "'+k+'";\n\tsrc: url("'+m+'");\n}'),b.wnd.document.writeln("</style>"))}g&&(c.useCssTransforms=g,c.currentTranslate=l,c.currentScale=p,c.view.translate=n,c.view.scale=u);return b}var f=parseInt(ka.value)/
-100;isNaN(f)&&(f=1,ka.value="100 %");var f=.75*f,e=null;null!=d.themes&&"darkTheme"==d.defaultThemeName&&(e=d.stylesheet,d.stylesheet=d.getDefaultStylesheet(),d.refresh());var g=k.value,l=v.value,n=!u.checked,t=null;n&&(n=g==p&&l==p);if(!n&&null!=a.pages&&a.pages.length){var m=0,n=a.pages.length-1;u.checked||(m=parseInt(g)-1,n=parseInt(l)-1);for(var x=m;x<=n;x++){var A=a.pages[x],g=A==a.currentPage?d:null;if(null==g){var g=a.createTemporaryGraph(d.stylesheet),l=!0,m=!1,z=null,y=null;null==A.viewState&&
-null==A.root&&a.updatePageRoot(A);null!=A.viewState&&(l=A.viewState.pageVisible,m=A.viewState.mathEnabled,z=A.viewState.background,y=A.viewState.backgroundImage,g.extFonts=A.viewState.extFonts);g.background=z;g.backgroundImage=null!=y?new mxImage(y.src,y.width,y.height):null;g.pageVisible=l;g.mathEnabled=m;var C=g.getGlobalVariable;g.getGlobalVariable=function(c){return"page"==c?A.getName():"pagenumber"==c?x+1:"pagecount"==c?null!=a.pages?a.pages.length:1:C.apply(this,arguments)};document.body.appendChild(g.container);
+function(a,c,b,f,d,e,g,m,p,n){if(null!=b&&null==mxMarker.markers[b]){var u=this.getPackageForType(b);null!=u&&mxStencilRegistry.getStencil(u)}return G.apply(this,arguments)};PrintDialog.prototype.create=function(a,c){function b(){k.value=Math.max(1,Math.min(m,Math.max(parseInt(k.value),parseInt(l.value))));l.value=Math.max(1,Math.min(m,Math.min(parseInt(k.value),parseInt(l.value))))}function f(c){function b(c,b,e){var g=c.useCssTransforms,m=c.currentTranslate,p=c.currentScale,n=c.view.translate,u=
+c.view.scale;c.useCssTransforms&&(c.useCssTransforms=!1,c.currentTranslate=new mxPoint(0,0),c.currentScale=1,c.view.translate=new mxPoint(0,0),c.view.scale=1);var t=c.getGraphBounds(),l=0,v=0,k=ta.get(),x=1/c.pageScale,A=B.checked;if(A)var x=parseInt(K.value),z=parseInt(ma.value),x=Math.min(k.height*z/(t.height/c.view.scale),k.width*x/(t.width/c.view.scale));else x=parseInt(q.value)/(100*c.pageScale),isNaN(x)&&(f=1/c.pageScale,q.value="100 %");k=mxRectangle.fromRectangle(k);k.width=Math.ceil(k.width*
+f);k.height=Math.ceil(k.height*f);x*=f;!A&&c.pageVisible?(t=c.getPageLayout(),l-=t.x*k.width,v-=t.y*k.height):A=!0;if(null==b){b=PrintDialog.createPrintPreview(c,x,k,0,l,v,A);b.pageSelector=!1;b.mathEnabled=!1;l=a.getCurrentFile();null!=l&&(b.title=l.getTitle());var y=b.writeHead;b.writeHead=function(b){y.apply(this,arguments);null!=a.editor.fontCss&&(b.writeln('<style type="text/css">'),b.writeln(a.editor.fontCss),b.writeln("</style>"));if(null!=c.extFonts)for(var f=0;f<c.extFonts.length;f++){var d=
+c.extFonts[f].name,e=c.extFonts[f].url;0==e.indexOf(Editor.GOOGLE_FONTS)?b.writeln('<link rel="stylesheet" href="'+e+'" charset="UTF-8" type="text/css">'):(b.writeln('<style type="text/css">'),b.writeln('@font-face {\n\tfont-family: "'+d+'";\n\tsrc: url("'+e+'");\n}'),b.writeln("</style>"))}};if("undefined"!==typeof MathJax){var C=b.renderPage;b.renderPage=function(c,b,f,d,e,g){var m=mxClient.NO_FO;mxClient.NO_FO=this.graph.mathEnabled&&!a.editor.useForeignObjectForMath?!0:a.editor.originalNoForeignObject;
+var p=C.apply(this,arguments);mxClient.NO_FO=m;this.graph.mathEnabled?this.mathEnabled=this.mathEnabled||!0:p.className="geDisableMathJax";return p}}l=null;null!=d.themes&&"darkTheme"==d.defaultThemeName&&(l=d.stylesheet,d.stylesheet=d.getDefaultStylesheet(),d.refresh());b.open(null,null,e,!0);null!=l&&(d.stylesheet=l,d.refresh())}else{k=c.background;if(null==k||""==k||k==mxConstants.NONE)k="#ffffff";b.backgroundColor=k;b.autoOrigin=A;b.appendGraph(c,x,l,v,e,!0);if(null!=c.extFonts&&null!=b.wnd)for(e=
+0;e<c.extFonts.length;e++)l=c.extFonts[e].name,v=c.extFonts[e].url,0==v.indexOf(Editor.GOOGLE_FONTS)?b.wnd.document.writeln('<link rel="stylesheet" href="'+v+'" charset="UTF-8" type="text/css">'):(b.wnd.document.writeln('<style type="text/css">'),b.wnd.document.writeln('@font-face {\n\tfont-family: "'+l+'";\n\tsrc: url("'+v+'");\n}'),b.wnd.document.writeln("</style>"))}g&&(c.useCssTransforms=g,c.currentTranslate=m,c.currentScale=p,c.view.translate=n,c.view.scale=u);return b}var f=parseInt(ka.value)/
+100;isNaN(f)&&(f=1,ka.value="100 %");var f=.75*f,e=null;null!=d.themes&&"darkTheme"==d.defaultThemeName&&(e=d.stylesheet,d.stylesheet=d.getDefaultStylesheet(),d.refresh());var g=l.value,m=k.value,n=!u.checked,t=null;n&&(n=g==p&&m==p);if(!n&&null!=a.pages&&a.pages.length){var v=0,n=a.pages.length-1;u.checked||(v=parseInt(g)-1,n=parseInt(m)-1);for(var x=v;x<=n;x++){var A=a.pages[x],g=A==a.currentPage?d:null;if(null==g){var g=a.createTemporaryGraph(d.stylesheet),m=!0,v=!1,z=null,y=null;null==A.viewState&&
+null==A.root&&a.updatePageRoot(A);null!=A.viewState&&(m=A.viewState.pageVisible,v=A.viewState.mathEnabled,z=A.viewState.background,y=A.viewState.backgroundImage,g.extFonts=A.viewState.extFonts);g.background=z;g.backgroundImage=null!=y?new mxImage(y.src,y.width,y.height):null;g.pageVisible=m;g.mathEnabled=v;var C=g.getGlobalVariable;g.getGlobalVariable=function(c){return"page"==c?A.getName():"pagenumber"==c?x+1:"pagecount"==c?null!=a.pages?a.pages.length:1:C.apply(this,arguments)};document.body.appendChild(g.container);
a.updatePageRoot(A);g.model.setRoot(A.root)}t=b(g,t,x!=n);g!=d&&g.container.parentNode.removeChild(g.container)}}else t=b(d);null==t?a.handleError({message:mxResources.get("errorUpdatingPreview")}):(t.mathEnabled&&(n=t.wnd.document,n.writeln('<script type="text/x-mathjax-config">'),n.writeln("MathJax.Hub.Config({"),n.writeln("showMathMenu: false,"),n.writeln('messageStyle: "none",'),n.writeln('jax: ["input/TeX", "input/MathML", "input/AsciiMath", "output/SVG"],'),n.writeln('extensions: ["tex2jax.js", "mml2jax.js", "asciimath2jax.js"],'),
n.writeln("TeX: {"),n.writeln('extensions: ["AMSmath.js", "AMSsymbols.js", "noErrors.js", "noUndefined.js"]'),n.writeln("},"),n.writeln("SVG: {"),n.writeln('font: "'+(null!=urlParams["math-font"]?decodeURIComponent(urlParams["math-font"]):"TeX")+'"'),n.writeln("},"),n.writeln("tex2jax: {"),n.writeln('ignoreClass: "geDisableMathJax"'),n.writeln("},"),n.writeln("asciimath2jax: {"),n.writeln('ignoreClass: "geDisableMathJax"'),n.writeln("}"),n.writeln("});"),c&&(n.writeln("MathJax.Hub.Queue(function () {"),
-n.writeln("window.print();"),n.writeln("});")),n.writeln("\x3c/script>"),n.writeln('<script type="text/javascript" src="'+DRAW_MATH_URL+'/MathJax.js">\x3c/script>')),t.closeDocument(),!t.mathEnabled&&c&&PrintDialog.printPreview(t));null!=e&&(d.stylesheet=e,d.refresh())}var d=a.editor.graph,e=document.createElement("div"),g=document.createElement("h3");g.style.width="100%";g.style.textAlign="center";g.style.marginTop="0px";mxUtils.write(g,c||mxResources.get("print"));e.appendChild(g);var l=1,p=1,n=
+n.writeln("window.print();"),n.writeln("});")),n.writeln("\x3c/script>"),n.writeln('<script type="text/javascript" src="'+DRAW_MATH_URL+'/MathJax.js">\x3c/script>')),t.closeDocument(),!t.mathEnabled&&c&&PrintDialog.printPreview(t));null!=e&&(d.stylesheet=e,d.refresh())}var d=a.editor.graph,e=document.createElement("div"),g=document.createElement("h3");g.style.width="100%";g.style.textAlign="center";g.style.marginTop="0px";mxUtils.write(g,c||mxResources.get("print"));e.appendChild(g);var m=1,p=1,n=
document.createElement("div");n.style.cssText="border-bottom:1px solid lightGray;padding-bottom:12px;margin-bottom:12px;";var u=document.createElement("input");u.style.cssText="margin-right:8px;margin-bottom:8px;";u.setAttribute("value","all");u.setAttribute("type","radio");u.setAttribute("name","pages-printdialog");n.appendChild(u);g=document.createElement("span");mxUtils.write(g,mxResources.get("printAllPages"));n.appendChild(g);mxUtils.br(n);var t=u.cloneNode(!0);u.setAttribute("checked","checked");
-t.setAttribute("value","range");n.appendChild(t);g=document.createElement("span");mxUtils.write(g,mxResources.get("pages")+":");n.appendChild(g);var k=document.createElement("input");k.style.cssText="margin:0 8px 0 8px;";k.setAttribute("value","1");k.setAttribute("type","number");k.setAttribute("min","1");k.style.width="50px";n.appendChild(k);g=document.createElement("span");mxUtils.write(g,mxResources.get("to"));n.appendChild(g);var v=k.cloneNode(!0);n.appendChild(v);mxEvent.addListener(k,"focus",
-function(){t.checked=!0});mxEvent.addListener(v,"focus",function(){t.checked=!0});mxEvent.addListener(k,"change",b);mxEvent.addListener(v,"change",b);if(null!=a.pages&&(l=a.pages.length,null!=a.currentPage))for(g=0;g<a.pages.length;g++)if(a.currentPage==a.pages[g]){p=g+1;k.value=p;v.value=p;break}k.setAttribute("max",l);v.setAttribute("max",l);1<l&&e.appendChild(n);var m=document.createElement("div");m.style.marginBottom="10px";var x=document.createElement("input");x.style.marginRight="8px";x.setAttribute("value",
-"adjust");x.setAttribute("type","radio");x.setAttribute("name","printZoom");m.appendChild(x);g=document.createElement("span");mxUtils.write(g,mxResources.get("adjustTo"));m.appendChild(g);var q=document.createElement("input");q.style.cssText="margin:0 8px 0 8px;";q.setAttribute("value","100 %");q.style.width="50px";m.appendChild(q);mxEvent.addListener(q,"focus",function(){x.checked=!0});e.appendChild(m);var n=n.cloneNode(!1),B=x.cloneNode(!0);B.setAttribute("value","fit");x.setAttribute("checked",
-"checked");g=document.createElement("div");g.style.cssText="display:inline-block;height:100%;vertical-align:top;padding-top:2px;";g.appendChild(B);n.appendChild(g);m=document.createElement("table");m.style.display="inline-block";var A=document.createElement("tbody"),y=document.createElement("tr"),D=y.cloneNode(!0),C=document.createElement("td"),F=C.cloneNode(!0),E=C.cloneNode(!0),G=C.cloneNode(!0),H=C.cloneNode(!0),J=C.cloneNode(!0);C.style.textAlign="right";G.style.textAlign="right";mxUtils.write(C,
+t.setAttribute("value","range");n.appendChild(t);g=document.createElement("span");mxUtils.write(g,mxResources.get("pages")+":");n.appendChild(g);var l=document.createElement("input");l.style.cssText="margin:0 8px 0 8px;";l.setAttribute("value","1");l.setAttribute("type","number");l.setAttribute("min","1");l.style.width="50px";n.appendChild(l);g=document.createElement("span");mxUtils.write(g,mxResources.get("to"));n.appendChild(g);var k=l.cloneNode(!0);n.appendChild(k);mxEvent.addListener(l,"focus",
+function(){t.checked=!0});mxEvent.addListener(k,"focus",function(){t.checked=!0});mxEvent.addListener(l,"change",b);mxEvent.addListener(k,"change",b);if(null!=a.pages&&(m=a.pages.length,null!=a.currentPage))for(g=0;g<a.pages.length;g++)if(a.currentPage==a.pages[g]){p=g+1;l.value=p;k.value=p;break}l.setAttribute("max",m);k.setAttribute("max",m);1<m&&e.appendChild(n);var v=document.createElement("div");v.style.marginBottom="10px";var x=document.createElement("input");x.style.marginRight="8px";x.setAttribute("value",
+"adjust");x.setAttribute("type","radio");x.setAttribute("name","printZoom");v.appendChild(x);g=document.createElement("span");mxUtils.write(g,mxResources.get("adjustTo"));v.appendChild(g);var q=document.createElement("input");q.style.cssText="margin:0 8px 0 8px;";q.setAttribute("value","100 %");q.style.width="50px";v.appendChild(q);mxEvent.addListener(q,"focus",function(){x.checked=!0});e.appendChild(v);var n=n.cloneNode(!1),B=x.cloneNode(!0);B.setAttribute("value","fit");x.setAttribute("checked",
+"checked");g=document.createElement("div");g.style.cssText="display:inline-block;height:100%;vertical-align:top;padding-top:2px;";g.appendChild(B);n.appendChild(g);v=document.createElement("table");v.style.display="inline-block";var A=document.createElement("tbody"),y=document.createElement("tr"),D=y.cloneNode(!0),C=document.createElement("td"),F=C.cloneNode(!0),E=C.cloneNode(!0),G=C.cloneNode(!0),H=C.cloneNode(!0),J=C.cloneNode(!0);C.style.textAlign="right";G.style.textAlign="right";mxUtils.write(C,
mxResources.get("fitTo"));var K=document.createElement("input");K.style.cssText="margin:0 8px 0 8px;";K.setAttribute("value","1");K.setAttribute("min","1");K.setAttribute("type","number");K.style.width="40px";F.appendChild(K);g=document.createElement("span");mxUtils.write(g,mxResources.get("fitToSheetsAcross"));E.appendChild(g);mxUtils.write(G,mxResources.get("fitToBy"));var ma=K.cloneNode(!0);H.appendChild(ma);mxEvent.addListener(K,"focus",function(){B.checked=!0});mxEvent.addListener(ma,"focus",
-function(){B.checked=!0});g=document.createElement("span");mxUtils.write(g,mxResources.get("fitToSheetsDown"));J.appendChild(g);y.appendChild(C);y.appendChild(F);y.appendChild(E);D.appendChild(G);D.appendChild(H);D.appendChild(J);A.appendChild(y);A.appendChild(D);m.appendChild(A);n.appendChild(m);e.appendChild(n);n=document.createElement("div");g=document.createElement("div");g.style.fontWeight="bold";g.style.marginBottom="12px";mxUtils.write(g,mxResources.get("paperSize"));n.appendChild(g);g=document.createElement("div");
+function(){B.checked=!0});g=document.createElement("span");mxUtils.write(g,mxResources.get("fitToSheetsDown"));J.appendChild(g);y.appendChild(C);y.appendChild(F);y.appendChild(E);D.appendChild(G);D.appendChild(H);D.appendChild(J);A.appendChild(y);A.appendChild(D);v.appendChild(A);n.appendChild(v);e.appendChild(n);n=document.createElement("div");g=document.createElement("div");g.style.fontWeight="bold";g.style.marginBottom="12px";mxUtils.write(g,mxResources.get("paperSize"));n.appendChild(g);g=document.createElement("div");
g.style.marginBottom="12px";var ta=PageSetupDialog.addPageFormatPanel(g,"printdialog",a.editor.graph.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT);n.appendChild(g);g=document.createElement("span");mxUtils.write(g,mxResources.get("pageScale"));n.appendChild(g);var ka=document.createElement("input");ka.style.cssText="margin:0 8px 0 8px;";ka.setAttribute("value","100 %");ka.style.width="60px";n.appendChild(ka);e.appendChild(n);g=document.createElement("div");g.style.cssText="text-align:right;margin:48px 0 0 0;";
-n=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});n.className="geBtn";a.editor.cancelFirst&&g.appendChild(n);a.isOffline()||(m=mxUtils.button(mxResources.get("help"),function(){d.openLink("https://desk.draw.io/support/solutions/articles/16000048947")}),m.className="geBtn",g.appendChild(m));PrintDialog.previewEnabled&&(m=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();f(!1)}),m.className="geBtn",g.appendChild(m));m=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?
-"print":"ok"),function(){a.hideDialog();f(!0)});m.className="geBtn gePrimaryBtn";g.appendChild(m);a.editor.cancelFirst||g.appendChild(n);e.appendChild(g);this.container=e};var E=ChangePageSetup.prototype.execute;ChangePageSetup.prototype.execute=function(){null==this.page&&(this.page=this.ui.currentPage);this.page!=this.ui.currentPage?null!=this.page.viewState&&(this.ignoreColor||(this.page.viewState.background=this.color),this.ignoreImage||(this.page.viewState.backgroundImage=this.image),null!=this.format&&
+n=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});n.className="geBtn";a.editor.cancelFirst&&g.appendChild(n);a.isOffline()||(v=mxUtils.button(mxResources.get("help"),function(){d.openLink("https://desk.draw.io/support/solutions/articles/16000048947")}),v.className="geBtn",g.appendChild(v));PrintDialog.previewEnabled&&(v=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();f(!1)}),v.className="geBtn",g.appendChild(v));v=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?
+"print":"ok"),function(){a.hideDialog();f(!0)});v.className="geBtn gePrimaryBtn";g.appendChild(v);a.editor.cancelFirst||g.appendChild(n);e.appendChild(g);this.container=e};var E=ChangePageSetup.prototype.execute;ChangePageSetup.prototype.execute=function(){null==this.page&&(this.page=this.ui.currentPage);this.page!=this.ui.currentPage?null!=this.page.viewState&&(this.ignoreColor||(this.page.viewState.background=this.color),this.ignoreImage||(this.page.viewState.backgroundImage=this.image),null!=this.format&&
(this.page.viewState.pageFormat=this.format),null!=this.mathEnabled&&(this.page.viewState.mathEnabled=this.mathEnabled),null!=this.shadowVisible&&(this.page.viewState.shadowVisible=this.shadowVisible)):(E.apply(this,arguments),null!=this.mathEnabled&&this.mathEnabled!=this.ui.isMathEnabled()&&(this.ui.setMathEnabled(this.mathEnabled),this.mathEnabled=!this.mathEnabled),null!=this.shadowVisible&&this.shadowVisible!=this.ui.editor.graph.shadowVisible&&(this.ui.editor.graph.setShadowVisible(this.shadowVisible),
this.shadowVisible=!this.shadowVisible))};Editor.prototype.useCanvasForExport=!1;try{var J=document.createElement("canvas"),H=new Image;H.onload=function(){try{J.getContext("2d").drawImage(H,0,0);var a=J.toDataURL("image/png");Editor.prototype.useCanvasForExport=null!=a&&6<a.length}catch(K){}};H.src="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1px" height="1px" version="1.1"><foreignObject pointer-events="all" width="1" height="1"><div xmlns="http://www.w3.org/1999/xhtml"></div></foreignObject></svg>')))}catch(y){}})();
(function(){var a=new mxObjectCodec(new ChangePageSetup,["ui","previousColor","previousImage","previousFormat"]);a.beforeDecode=function(a,e,d){d.ui=a.ui;return e};a.afterDecode=function(a,e,d){d.previousColor=d.color;d.previousImage=d.image;d.previousFormat=d.format;null!=d.foldingEnabled&&(d.foldingEnabled=!d.foldingEnabled);null!=d.mathEnabled&&(d.mathEnabled=!d.mathEnabled);null!=d.shadowVisible&&(d.shadowVisible=!d.shadowVisible);return d};mxCodecRegistry.register(a)})();(function(){EditorUi.VERSION="@DRAWIO-VERSION@";EditorUi.compactUi="atlas"!=uiTheme;mxGraphView.prototype.defaultDarkGridColor="#6e6e6e";"dark"==uiTheme&&(mxGraphView.prototype.gridColor=mxGraphView.prototype.defaultDarkGridColor);EditorUi.enableLogging="1"!=urlParams.stealth&&(/.*\.draw\.io$/.test(window.location.hostname)||/.*\.diagrams\.net$/.test(window.location.hostname))&&"support.draw.io"!=window.location.hostname;EditorUi.drawHost=window.DRAWIO_BASE_URL;EditorUi.lastErrorMessage=null;EditorUi.ignoredAnonymizedChars=
"\n\t`~!@#$%^&*()_+{}|:\"<>?-=[];'./,\n\t";EditorUi.templateFile=TEMPLATE_PATH+"/index.xml";EditorUi.cacheUrl="1"==urlParams.dev?"/cache":window.REALTIME_URL;null==EditorUi.cacheUrl&&"undefined"!==typeof DrawioFile&&(DrawioFile.SYNC="none");Editor.cacheTimeout=1E4;EditorUi.enablePlantUml=EditorUi.enableLogging;EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;EditorUi.enableDrafts=!mxClient.IS_CHROMEAPP&&isLocalStorage&&
!EditorUi.isElectronApp&&"0"!=urlParams.drafts;EditorUi.scratchpadHelpLink="https://desk.draw.io/support/solutions/articles/16000042367";EditorUi.defaultMermaidConfig={theme:"neutral",arrowMarkerAbsolute:!1,flowchart:{htmlLabels:!1},sequence:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,showSequenceNumbers:!1},gantt:{titleTopMargin:25,barHeight:20,barGap:4,
-topPadding:50,leftPadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:4,axisFormat:"%Y-%m-%d"}};EditorUi.logError=function(a,b,d,e,l,n,k){n=null!=n?n:0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";if(EditorUi.enableLogging&&"1"!=urlParams.dev)try{if(a!=EditorUi.lastErrorMessage&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&
-null!=a&&0>a.indexOf("DocumentClosedError")){EditorUi.lastErrorMessage=a;var c=null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"";l=null!=l?l:Error(a);(new Image).src=c+"/log?severity="+n+"&v="+encodeURIComponent(EditorUi.VERSION)+"&msg=clientError:"+encodeURIComponent(a)+":url:"+encodeURIComponent(window.location.href)+":lnum:"+encodeURIComponent(d)+(null!=e?":colno:"+encodeURIComponent(e):"")+(null!=l&&null!=l.stack?"&stack="+encodeURIComponent(l.stack):"")}}catch(u){}try{k||null==window.console||
-console.error(n,a,b,d,e,l)}catch(u){}};EditorUi.logEvent=function(a){if("1"==urlParams.dev)EditorUi.debug("logEvent",a);else if(EditorUi.enableLogging)try{var c=null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"";(new Image).src=c+"/images/1x1.png?v="+encodeURIComponent(EditorUi.VERSION)+(null!=a?"&data="+encodeURIComponent(JSON.stringify(a)):"")}catch(g){}};EditorUi.sendReport=function(a,b){if("1"==urlParams.dev)EditorUi.debug("sendReport",a);else if(EditorUi.enableLogging)try{b=null!=b?b:5E4,a.length>
+topPadding:50,leftPadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"',numberSectionStyles:4,axisFormat:"%Y-%m-%d"}};EditorUi.logError=function(a,b,d,e,m,n,l){n=null!=n?n:0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";if(EditorUi.enableLogging&&"1"!=urlParams.dev)try{if(a!=EditorUi.lastErrorMessage&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&
+null!=a&&0>a.indexOf("DocumentClosedError")){EditorUi.lastErrorMessage=a;var c=null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"";m=null!=m?m:Error(a);(new Image).src=c+"/log?severity="+n+"&v="+encodeURIComponent(EditorUi.VERSION)+"&msg=clientError:"+encodeURIComponent(a)+":url:"+encodeURIComponent(window.location.href)+":lnum:"+encodeURIComponent(d)+(null!=e?":colno:"+encodeURIComponent(e):"")+(null!=m&&null!=m.stack?"&stack="+encodeURIComponent(m.stack):"")}}catch(u){}try{l||null==window.console||
+console.error(n,a,b,d,e,m)}catch(u){}};EditorUi.logEvent=function(a){if("1"==urlParams.dev)EditorUi.debug("logEvent",a);else if(EditorUi.enableLogging)try{var c=null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"";(new Image).src=c+"/images/1x1.png?v="+encodeURIComponent(EditorUi.VERSION)+(null!=a?"&data="+encodeURIComponent(JSON.stringify(a)):"")}catch(g){}};EditorUi.sendReport=function(a,b){if("1"==urlParams.dev)EditorUi.debug("sendReport",a);else if(EditorUi.enableLogging)try{b=null!=b?b:5E4,a.length>
b&&(a=a.substring(0,b)+"\n...[SHORTENED]"),mxUtils.post("/email","version="+encodeURIComponent(EditorUi.VERSION)+"&url="+encodeURIComponent(window.location.href)+"&data="+encodeURIComponent(a))}catch(g){}};EditorUi.debug=function(){try{if(null!=window.console&&"1"==urlParams.test){for(var a=[(new Date).toISOString()],b=0;b<arguments.length;b++)null!=arguments[b]&&a.push(arguments[b]);console.log.apply(console,a)}}catch(g){}};EditorUi.parsePng=function(a,b,d){function c(a,c){var b=e;e+=c;return a.substring(b,
e)}function f(a){a=c(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}var e=0;if(c(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=d&&d();else if(c(a,4),"IHDR"!=c(a,4))null!=d&&d();else{c(a,17);do{d=f(a);var g=c(a,4);if(null!=b&&b(e-8,g,d))break;value=c(a,d);c(a,4);if("IEND"==g)break}while(d)}};EditorUi.removeChildNodes=function(a){for(;null!=a.firstChild;)a.removeChild(a.firstChild)};EditorUi.prototype.emptyDiagramXml='<mxGraphModel><root><mxCell id="0"/><mxCell id="1" parent="0"/></root></mxGraphModel>';
EditorUi.prototype.emptyLibraryXml="<mxlibrary>[]</mxlibrary>";EditorUi.prototype.mode=null;EditorUi.prototype.timeout=Editor.prototype.timeout;EditorUi.prototype.sidebarFooterHeight=38;EditorUi.prototype.defaultCustomShapeStyle="shape=stencil(tZRtTsQgEEBPw1+DJR7AoN6DbWftpAgE0Ortd/jYRGq72R+YNE2YgTePloEJGWblgA18ZuKFDcMj5/Sm8boZq+BgjCX4pTyqk6ZlKROitwusOMXKQDODx5iy4pXxZ5qTHiFHawxB0JrQZH7lCabQ0Fr+XWC1/E8zcsT/gAi+Subo2/3Mh6d/oJb5nU1b5tW7r2knautaa3T+U32o7f7vZwpJkaNDLORJjcu7t59m2jXxqX9un+tt022acsfmoKaQZ+vhhswZtS6Ne/ThQGt0IV0N3Yyv6P3CeT9/tHO0XFI5cAE=);whiteSpace=wrap;html=1;";
EditorUi.prototype.maxBackgroundSize=1600;EditorUi.prototype.maxImageSize=520;EditorUi.prototype.maxTextWidth=520;EditorUi.prototype.resampleThreshold=1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.maxTextBytes=5E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;EditorUi.prototype.formatEnabled="0"!=urlParams.format;EditorUi.prototype.insertTemplateEnabled=!0;EditorUi.prototype.closableScratchpad=
-!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas");EditorUi.prototype.canvasSupported=!(!a.getContext||!a.getContext("2d"))}catch(l){}try{var b=document.createElement("canvas"),d=new Image;d.onload=function(){try{b.getContext("2d").drawImage(d,0,0);var a=b.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=a&&6<a.length}catch(n){}};d.src="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1px" height="1px" version="1.1"><foreignObject pointer-events="all" width="1" height="1"><div xmlns="http://www.w3.org/1999/xhtml"></div></foreignObject></svg>')))}catch(l){}try{b=
-document.createElement("canvas");b.width=b.height=1;var e=b.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==e.match("image/jpeg")}catch(l){}})();EditorUi.prototype.openLink=function(a,b,d){return this.editor.graph.openLink(a,b,d)};EditorUi.prototype.showSplash=function(a){};EditorUi.prototype.getLocalData=function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,d){localStorage.setItem(a,b);null!=d&&d()};EditorUi.prototype.removeLocalData=function(a,b){localStorage.removeItem(a);
+!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas");EditorUi.prototype.canvasSupported=!(!a.getContext||!a.getContext("2d"))}catch(m){}try{var b=document.createElement("canvas"),d=new Image;d.onload=function(){try{b.getContext("2d").drawImage(d,0,0);var a=b.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=a&&6<a.length}catch(n){}};d.src="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1px" height="1px" version="1.1"><foreignObject pointer-events="all" width="1" height="1"><div xmlns="http://www.w3.org/1999/xhtml"></div></foreignObject></svg>')))}catch(m){}try{b=
+document.createElement("canvas");b.width=b.height=1;var e=b.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==e.match("image/jpeg")}catch(m){}})();EditorUi.prototype.openLink=function(a,b,d){return this.editor.graph.openLink(a,b,d)};EditorUi.prototype.showSplash=function(a){};EditorUi.prototype.getLocalData=function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,d){localStorage.setItem(a,b);null!=d&&d()};EditorUi.prototype.removeLocalData=function(a,b){localStorage.removeItem(a);
b()};EditorUi.prototype.setMathEnabled=function(a){this.editor.graph.mathEnabled=a;this.editor.updateGraphComponents();this.editor.graph.refresh();this.fireEvent(new mxEventObject("mathEnabledChanged"))};EditorUi.prototype.isMathEnabled=function(a){return this.editor.graph.mathEnabled};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(a){return this.isOfflineApp()||!navigator.onLine||!a&&"1"==urlParams.stealth};EditorUi.prototype.createSpinner=
function(a,b,d){d=null!=d?d:24;var c=new Spinner({lines:12,length:d,width:Math.round(d/3),radius:Math.round(d/2),rotate:0,color:"dark"==uiTheme?"#c0c0c0":"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),f=c.spin;c.spin=function(d,e){var g=!1;this.active||(f.call(this,d),this.active=!0,null!=e&&(g=document.createElement("div"),g.style.position="absolute",g.style.whiteSpace="nowrap",g.style.background="#4B4243",g.style.color="white",g.style.fontFamily="Helvetica, Arial",g.style.fontSize=
"9pt",g.style.padding="6px",g.style.paddingLeft="10px",g.style.paddingRight="10px",g.style.zIndex=2E9,g.style.left=Math.max(0,a)+"px",g.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(g.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(g.style,"transform","translate(-50%,-50%)"),"dark"!=uiTheme&&mxUtils.setPrefixedStyle(g.style,"boxShadow","2px 2px 3px 0px #ddd"),"..."!=e.substring(e.length-3,e.length)&&"!"!=e.charAt(e.length-1)&&(e+="..."),g.innerHTML=e,d.appendChild(g),c.status=g,mxClient.IS_VML&&
@@ -3082,13 +3082,13 @@ function(a,b,d){d=null!=d?d:24;var c=new Spinner({lines:12,length:d,width:Math.r
c.pause=function(){return function(){}};return c};EditorUi.prototype.isCompatibleString=function(a){try{var c=mxUtils.parseXml(a),b=this.editor.extractGraphModel(c.documentElement,!0);return null!=b&&0==b.getElementsByTagName("parsererror").length}catch(p){}return!1};EditorUi.prototype.isVisioData=function(a){return 8<a.length&&(208==a.charCodeAt(0)&&207==a.charCodeAt(1)&&17==a.charCodeAt(2)&&224==a.charCodeAt(3)&&161==a.charCodeAt(4)&&177==a.charCodeAt(5)&&26==a.charCodeAt(6)&&225==a.charCodeAt(7)||
80==a.charCodeAt(0)&&75==a.charCodeAt(1)&&3==a.charCodeAt(2)&&4==a.charCodeAt(3)||80==a.charCodeAt(0)&&75==a.charCodeAt(1)&&3==a.charCodeAt(2)&&6==a.charCodeAt(3))};EditorUi.prototype.isRemoteVisioData=function(a){return 8<a.length&&(208==a.charCodeAt(0)&&207==a.charCodeAt(1)&&17==a.charCodeAt(2)&&224==a.charCodeAt(3)&&161==a.charCodeAt(4)&&177==a.charCodeAt(5)&&26==a.charCodeAt(6)&&225==a.charCodeAt(7)||60==a.charCodeAt(0)&&63==a.charCodeAt(1)&&120==a.charCodeAt(2)&&109==a.charCodeAt(3)&&108==a.charCodeAt(3))};
EditorUi.prototype.isPngData=function(a){return 8<a.length&&137==a.charCodeAt(0)&&80==a.charCodeAt(1)&&78==a.charCodeAt(2)&&71==a.charCodeAt(3)&&13==a.charCodeAt(4)&&10==a.charCodeAt(5)&&26==a.charCodeAt(6)&&10==a.charCodeAt(7)};var a=EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(c){var b=a.apply(this,arguments);if(null==b)try{var d=c.indexOf("&lt;mxfile ");if(0<=d){var e=c.lastIndexOf("&lt;/mxfile&gt;");e>d&&(b=c.substring(d,e+15).replace(/&gt;/g,
-">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var l=mxUtils.parseXml(c),n=this.editor.extractGraphModel(l.documentElement,null!=this.pages||"hidden"==this.diagramContainer.style.visibility),b=null!=n?mxUtils.getXml(n):""}catch(v){}return b};EditorUi.prototype.validateFileData=function(a){if(null!=a&&0<a.length){var c=a.indexOf('<meta charset="utf-8">');0<=c&&(a=a.slice(0,c)+'<meta charset="utf-8"/>'+a.slice(c+23-1,a.length));a=Graph.zapGremlins(a)}return a};EditorUi.prototype.replaceFileData=
+">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var m=mxUtils.parseXml(c),n=this.editor.extractGraphModel(m.documentElement,null!=this.pages||"hidden"==this.diagramContainer.style.visibility),b=null!=n?mxUtils.getXml(n):""}catch(v){}return b};EditorUi.prototype.validateFileData=function(a){if(null!=a&&0<a.length){var c=a.indexOf('<meta charset="utf-8">');0<=c&&(a=a.slice(0,c)+'<meta charset="utf-8"/>'+a.slice(c+23-1,a.length));a=Graph.zapGremlins(a)}return a};EditorUi.prototype.replaceFileData=
function(a){a=this.validateFileData(a);a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var c=null!=a?this.editor.extractGraphModel(a,!0):null;null!=c&&(a=c);if(null!=a){c=this.editor.graph;c.model.beginUpdate();try{var b=null!=this.pages?this.pages.slice():null,d=a.getElementsByTagName("diagram");if("0"!=urlParams.pages||1<d.length||1==d.length&&d[0].hasAttribute("name")){this.fileNode=a;this.pages=null!=this.pages?this.pages:[];for(var e=d.length-1;0<=e;e--){var n=this.updatePageRoot(new DiagramPage(d[e]));
null==n.getName()&&n.setName(mxResources.get("pageWithNumber",[e+1]));c.model.execute(new ChangePage(this,n,0==e?n:null,0))}}else"0"!=urlParams.pages&&null==this.fileNode&&(this.fileNode=a.ownerDocument.createElement("mxfile"),this.currentPage=new DiagramPage(a.ownerDocument.createElement("diagram")),this.currentPage.setName(mxResources.get("pageWithNumber",[1])),c.model.execute(new ChangePage(this,this.currentPage,this.currentPage,0))),this.editor.setGraphXml(a),null!=this.currentPage&&(this.currentPage.root=
-this.editor.graph.model.root);if(null!=b)for(e=0;e<b.length;e++)c.model.execute(new ChangePage(this,b[e],null))}finally{c.model.endUpdate()}}};EditorUi.prototype.createFileData=function(a,b,d,e,l,n,k,t,u,m,q){b=null!=b?b:this.editor.graph;l=null!=l?l:!1;u=null!=u?u:!0;var c,f=null;null==d||d.getMode()==App.MODE_DEVICE||d.getMode()==App.MODE_BROWSER?c="_blank":f=c=e;if(null==a)return"";var g=a;if("mxfile"!=g.nodeName.toLowerCase()){if(q){var p=a.ownerDocument.createElement("diagram");p.setAttribute("id",
-Editor.guid());p.appendChild(a)}else{p=Graph.zapGremlins(mxUtils.getXml(a));g=Graph.compress(p);if(Graph.decompress(g)!=p)return p;p=a.ownerDocument.createElement("diagram");p.setAttribute("id",Editor.guid());mxUtils.setTextContent(p,g)}g=a.ownerDocument.createElement("mxfile");g.appendChild(p)}m?(g=g.cloneNode(!0),g.removeAttribute("modified"),g.removeAttribute("host"),g.removeAttribute("agent"),g.removeAttribute("etag"),g.removeAttribute("userAgent"),g.removeAttribute("version"),g.removeAttribute("editor"),
+this.editor.graph.model.root);if(null!=b)for(e=0;e<b.length;e++)c.model.execute(new ChangePage(this,b[e],null))}finally{c.model.endUpdate()}}};EditorUi.prototype.createFileData=function(a,b,d,e,m,n,l,t,u,k,q){b=null!=b?b:this.editor.graph;m=null!=m?m:!1;u=null!=u?u:!0;var c,f=null;null==d||d.getMode()==App.MODE_DEVICE||d.getMode()==App.MODE_BROWSER?c="_blank":f=c=e;if(null==a)return"";var g=a;if("mxfile"!=g.nodeName.toLowerCase()){if(q){var p=a.ownerDocument.createElement("diagram");p.setAttribute("id",
+Editor.guid());p.appendChild(a)}else{p=Graph.zapGremlins(mxUtils.getXml(a));g=Graph.compress(p);if(Graph.decompress(g)!=p)return p;p=a.ownerDocument.createElement("diagram");p.setAttribute("id",Editor.guid());mxUtils.setTextContent(p,g)}g=a.ownerDocument.createElement("mxfile");g.appendChild(p)}k?(g=g.cloneNode(!0),g.removeAttribute("modified"),g.removeAttribute("host"),g.removeAttribute("agent"),g.removeAttribute("etag"),g.removeAttribute("userAgent"),g.removeAttribute("version"),g.removeAttribute("editor"),
g.removeAttribute("type")):(g.removeAttribute("userAgent"),g.removeAttribute("version"),g.removeAttribute("editor"),g.removeAttribute("pages"),g.removeAttribute("type"),mxClient.IS_CHROMEAPP?g.setAttribute("host","Chrome"):EditorUi.isElectronApp?g.setAttribute("host","Electron"):g.setAttribute("host",window.location.hostname),g.setAttribute("modified",(new Date).toISOString()),g.setAttribute("agent",navigator.appVersion),g.setAttribute("version",EditorUi.VERSION),g.setAttribute("etag",Editor.guid()),
-a=null!=d?d.getMode():this.mode,null!=a&&g.setAttribute("type",a),1<g.getElementsByTagName("diagram").length&&null!=this.pages&&g.setAttribute("pages",this.pages.length));q=q?mxUtils.getPrettyXml(g):mxUtils.getXml(g);if(!n&&!l&&(k||null!=d&&/(\.html)$/i.test(d.getTitle())))q=this.getHtml2(mxUtils.getXml(g),b,null!=d?d.getTitle():null,c,f);else if(n||!l&&null!=d&&/(\.svg)$/i.test(d.getTitle()))null==d||d.getMode()!=App.MODE_DEVICE&&d.getMode()!=App.MODE_BROWSER||(e=null),q=this.getEmbeddedSvg(q,b,
+a=null!=d?d.getMode():this.mode,null!=a&&g.setAttribute("type",a),1<g.getElementsByTagName("diagram").length&&null!=this.pages&&g.setAttribute("pages",this.pages.length));q=q?mxUtils.getPrettyXml(g):mxUtils.getXml(g);if(!n&&!m&&(l||null!=d&&/(\.html)$/i.test(d.getTitle())))q=this.getHtml2(mxUtils.getXml(g),b,null!=d?d.getTitle():null,c,f);else if(n||!m&&null!=d&&/(\.svg)$/i.test(d.getTitle()))null==d||d.getMode()!=App.MODE_DEVICE&&d.getMode()!=App.MODE_BROWSER||(e=null),q=this.getEmbeddedSvg(q,b,
e,null,t,u,f);return q};EditorUi.prototype.getXmlFileData=function(a,b,d){a=null!=a?a:!0;b=null!=b?b:!1;d=null!=d?d:!Editor.compressXml;var c=this.editor.getGraphXml(a);if(a&&null!=this.fileNode&&null!=this.currentPage)if(a=function(a){var b=a.getElementsByTagName("mxGraphModel"),b=0<b.length?b[0]:null;null==b&&d?(b=mxUtils.trim(mxUtils.getTextContent(a)),a=a.cloneNode(!1),0<b.length&&(b=Graph.decompress(b),null!=b&&0<b.length&&a.appendChild(mxUtils.parseXml(b).documentElement))):null==b||d?a=a.cloneNode(!0):
(a=a.cloneNode(!1),mxUtils.setTextContent(a,Graph.compressNode(b)));c.appendChild(a)},EditorUi.removeChildNodes(this.currentPage.node),mxUtils.setTextContent(this.currentPage.node,Graph.compressNode(c)),c=this.fileNode.cloneNode(!1),b)a(this.currentPage.node);else for(b=0;b<this.pages.length;b++){if(this.currentPage!=this.pages[b]&&this.pages[b].needsUpdate){var f=(new mxCodec(mxUtils.createXmlDocument())).encode(new mxGraphModel(this.pages[b].root));this.editor.graph.saveViewState(this.pages[b].viewState,
f);EditorUi.removeChildNodes(this.pages[b].node);mxUtils.setTextContent(this.pages[b].node,Graph.compressNode(f));delete this.pages[b].needsUpdate}a(this.pages[b].node)}return c};EditorUi.prototype.anonymizeString=function(a,b){for(var c=[],f=0;f<a.length;f++){var d=a.charAt(f);0<=EditorUi.ignoredAnonymizedChars.indexOf(d)?c.push(d):isNaN(parseInt(d))?d.toLowerCase()!=d?c.push(String.fromCharCode(65+Math.round(25*Math.random()))):d.toUpperCase()!=d?c.push(String.fromCharCode(97+Math.round(25*Math.random()))):
@@ -3097,199 +3097,199 @@ n.message}if(null!=a[EditorUi.DIFF_UPDATE]){for(var d in a[EditorUi.DIFF_UPDATE]
delete e.cells[a]}}),c(EditorUi.DIFF_INSERT),c(EditorUi.DIFF_UPDATE),0==Object.keys(e.cells).length&&delete e.cells);0==Object.keys(e).length&&delete a[EditorUi.DIFF_UPDATE][d]}0==Object.keys(a[EditorUi.DIFF_UPDATE]).length&&delete a[EditorUi.DIFF_UPDATE]}return a};EditorUi.prototype.anonymizeAttributes=function(a,b){if(null!=a.attributes)for(var c=0;c<a.attributes.length;c++)"as"!=a.attributes[c].name&&a.setAttribute(a.attributes[c].name,this.anonymizeString(a.attributes[c].value,b));if(null!=a.childNodes)for(c=
0;c<a.childNodes.length;c++)this.anonymizeAttributes(a.childNodes[c],b)};EditorUi.prototype.anonymizeNode=function(a,b){for(var c=a.getElementsByTagName("mxCell"),f=0;f<c.length;f++)null!=c[f].getAttribute("value")&&c[f].setAttribute("value","["+c[f].getAttribute("value").length+"]"),null!=c[f].getAttribute("xmlValue")&&c[f].setAttribute("xmlValue","["+c[f].getAttribute("xmlValue").length+"]"),null!=c[f].getAttribute("style")&&c[f].setAttribute("style","["+c[f].getAttribute("style").length+"]"),null!=
c[f].parentNode&&"root"!=c[f].parentNode.nodeName&&null!=c[f].parentNode.parentNode&&(c[f].setAttribute("id",c[f].parentNode.getAttribute("id")),c[f].parentNode.parentNode.replaceChild(c[f],c[f].parentNode));return a};EditorUi.prototype.synchronizeCurrentFile=function(a){var c=this.getCurrentFile();null!=c&&(c.savingFile?this.handleError({message:mxResources.get("busy")}):!a&&c.invalidChecksum?c.handleFileError(null,!0):this.spinner.spin(document.body,mxResources.get("updatingDocument"))&&(c.clearAutosave(),
-this.editor.setStatus(""),a?c.reloadFile(mxUtils.bind(this,function(){c.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(a){c.handleFileError(a,!0)})):c.synchronizeFile(mxUtils.bind(this,function(){c.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(a){c.handleFileError(a,!0)}))))};EditorUi.prototype.getFileData=function(a,b,d,e,l,n,k,t,u,m){l=null!=l?l:!0;n=null!=n?n:!1;var c=this.editor.graph;if(b||!a&&null!=u&&/(\.svg)$/i.test(u.getTitle()))if(m=
-!1,null!=this.pages&&this.currentPage!=this.pages[0]){var f=c.getGlobalVariable,c=this.createTemporaryGraph(c.getStylesheet()),g=this.pages[0];c.getGlobalVariable=function(a){return"page"==a?g.getName():"pagenumber"==a?1:f.apply(this,arguments)};document.body.appendChild(c.container);c.model.setRoot(g.root)}k=null!=k?k:this.getXmlFileData(l,n,m);u=null!=u?u:this.getCurrentFile();a=this.createFileData(k,c,u,window.location.href,a,b,d,e,l,t,m);c!=this.editor.graph&&c.container.parentNode.removeChild(c.container);
-return a};EditorUi.prototype.getHtml=function(a,b,d,e,l,n){n=null!=n?n:!0;var c=null,f=EditorUi.drawHost+"/js/embed-static.min.js";if(null!=b){var c=n?b.getGraphBounds():b.getBoundingBox(b.getSelectionCells()),g=b.view.scale;n=Math.floor(c.x/g-b.view.translate.x);g=Math.floor(c.y/g-b.view.translate.y);c=b.background;null==l&&(b=this.getBasenames().join(";"),0<b.length&&(f=EditorUi.drawHost+"/embed.js?s="+b));a.setAttribute("x0",n);a.setAttribute("y0",g)}null!=a&&(a.setAttribute("pan","1"),a.setAttribute("zoom",
-"1"),a.setAttribute("resize","0"),a.setAttribute("fit","0"),a.setAttribute("border","20"),a.setAttribute("links","1"),null!=e&&a.setAttribute("edit",e));null!=l&&(l=l.replace(/&/g,"&amp;"));a=null!=a?Graph.zapGremlins(mxUtils.getXml(a)):"";e=Graph.compress(a);Graph.decompress(e)!=a&&(e=encodeURIComponent(a));return(null==l?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+"<!DOCTYPE html>\n<html"+(null!=l?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+
-(null==l?null!=d?"<title>"+mxUtils.htmlEntities(d)+"</title>\n":"":"<title>diagrams.net</title>\n")+(null!=l?'<meta http-equiv="refresh" content="0;URL=\''+l+"'\"/>\n":"")+"</head>\n<body"+(null==l&&null!=c&&c!=mxConstants.NONE?' style="background-color:'+c+';">':">")+'\n<div class="mxgraph" style="position:relative;overflow:auto;width:100%;">\n<div style="width:1px;height:1px;overflow:hidden;">'+e+"</div>\n</div>\n"+(null==l?'<script type="text/javascript" src="'+f+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+
-l+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.getHtml2=function(a,b,d,e,l){b=window.DRAWIO_VIEWER_URL||EditorUi.drawHost+"/js/viewer.min.js";null!=l&&(l=l.replace(/&/g,"&amp;"));a={highlight:"#0000ff",nav:this.editor.graph.foldingEnabled,resize:!0,xml:Graph.zapGremlins(a),toolbar:"pages zoom layers lightbox"};null!=this.pages&&null!=this.currentPage&&(a.page=mxUtils.indexOf(this.pages,this.currentPage));return(null==
-l?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+"<!DOCTYPE html>\n<html"+(null!=l?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+(null==l?null!=d?"<title>"+mxUtils.htmlEntities(d)+"</title>\n":"":"<title>diagrams.net</title>\n")+(null!=l?'<meta http-equiv="refresh" content="0;URL=\''+l+"'\"/>\n":"")+'<meta charset="utf-8"/>\n</head>\n<body>\n<div class="mxgraph" style="max-width:100%;border:1px solid transparent;" data-mxgraph="'+mxUtils.htmlEntities(JSON.stringify(a))+
-'"></div>\n'+(null==l?'<script type="text/javascript" src="'+b+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+l+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.setFileData=function(a){a=this.validateFileData(a);this.pages=this.fileNode=this.currentPage=null;a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var c=Editor.extractParserError(a,
+this.editor.setStatus(""),a?c.reloadFile(mxUtils.bind(this,function(){c.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(a){c.handleFileError(a,!0)})):c.synchronizeFile(mxUtils.bind(this,function(){c.handleFileSuccess("manual"==DrawioFile.SYNC)}),mxUtils.bind(this,function(a){c.handleFileError(a,!0)}))))};EditorUi.prototype.getFileData=function(a,b,d,e,m,n,l,t,u,k){m=null!=m?m:!0;n=null!=n?n:!1;var c=this.editor.graph;if(b||!a&&null!=u&&/(\.svg)$/i.test(u.getTitle()))if(k=
+!1,null!=this.pages&&this.currentPage!=this.pages[0]){var f=c.getGlobalVariable,c=this.createTemporaryGraph(c.getStylesheet()),g=this.pages[0];c.getGlobalVariable=function(a){return"page"==a?g.getName():"pagenumber"==a?1:f.apply(this,arguments)};document.body.appendChild(c.container);c.model.setRoot(g.root)}l=null!=l?l:this.getXmlFileData(m,n,k);u=null!=u?u:this.getCurrentFile();a=this.createFileData(l,c,u,window.location.href,a,b,d,e,m,t,k);c!=this.editor.graph&&c.container.parentNode.removeChild(c.container);
+return a};EditorUi.prototype.getHtml=function(a,b,d,e,m,n){n=null!=n?n:!0;var c=null,f=EditorUi.drawHost+"/js/embed-static.min.js";if(null!=b){var c=n?b.getGraphBounds():b.getBoundingBox(b.getSelectionCells()),g=b.view.scale;n=Math.floor(c.x/g-b.view.translate.x);g=Math.floor(c.y/g-b.view.translate.y);c=b.background;null==m&&(b=this.getBasenames().join(";"),0<b.length&&(f=EditorUi.drawHost+"/embed.js?s="+b));a.setAttribute("x0",n);a.setAttribute("y0",g)}null!=a&&(a.setAttribute("pan","1"),a.setAttribute("zoom",
+"1"),a.setAttribute("resize","0"),a.setAttribute("fit","0"),a.setAttribute("border","20"),a.setAttribute("links","1"),null!=e&&a.setAttribute("edit",e));null!=m&&(m=m.replace(/&/g,"&amp;"));a=null!=a?Graph.zapGremlins(mxUtils.getXml(a)):"";e=Graph.compress(a);Graph.decompress(e)!=a&&(e=encodeURIComponent(a));return(null==m?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+"<!DOCTYPE html>\n<html"+(null!=m?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+
+(null==m?null!=d?"<title>"+mxUtils.htmlEntities(d)+"</title>\n":"":"<title>diagrams.net</title>\n")+(null!=m?'<meta http-equiv="refresh" content="0;URL=\''+m+"'\"/>\n":"")+"</head>\n<body"+(null==m&&null!=c&&c!=mxConstants.NONE?' style="background-color:'+c+';">':">")+'\n<div class="mxgraph" style="position:relative;overflow:auto;width:100%;">\n<div style="width:1px;height:1px;overflow:hidden;">'+e+"</div>\n</div>\n"+(null==m?'<script type="text/javascript" src="'+f+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+
+m+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.getHtml2=function(a,b,d,e,m){b=window.DRAWIO_VIEWER_URL||EditorUi.drawHost+"/js/viewer.min.js";null!=m&&(m=m.replace(/&/g,"&amp;"));a={highlight:"#0000ff",nav:this.editor.graph.foldingEnabled,resize:!0,xml:Graph.zapGremlins(a),toolbar:"pages zoom layers lightbox"};null!=this.pages&&null!=this.currentPage&&(a.page=mxUtils.indexOf(this.pages,this.currentPage));return(null==
+m?'\x3c!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=5,IE=9" ><![endif]--\x3e\n':"")+"<!DOCTYPE html>\n<html"+(null!=m?' xmlns="http://www.w3.org/1999/xhtml">':">")+"\n<head>\n"+(null==m?null!=d?"<title>"+mxUtils.htmlEntities(d)+"</title>\n":"":"<title>diagrams.net</title>\n")+(null!=m?'<meta http-equiv="refresh" content="0;URL=\''+m+"'\"/>\n":"")+'<meta charset="utf-8"/>\n</head>\n<body>\n<div class="mxgraph" style="max-width:100%;border:1px solid transparent;" data-mxgraph="'+mxUtils.htmlEntities(JSON.stringify(a))+
+'"></div>\n'+(null==m?'<script type="text/javascript" src="'+b+'">\x3c/script>':'<a style="position:absolute;top:50%;left:50%;margin-top:-128px;margin-left:-64px;" href="'+m+'" target="_blank"><img border="0" src="'+EditorUi.drawHost+'/images/drawlogo128.png"/></a>')+"\n</body>\n</html>\n"};EditorUi.prototype.setFileData=function(a){a=this.validateFileData(a);this.pages=this.fileNode=this.currentPage=null;a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var c=Editor.extractParserError(a,
mxResources.get("invalidOrMissingFile"));if(c)throw Error(mxResources.get("notADiagramFile")+" ("+c+")");c=null!=a?this.editor.extractGraphModel(a,!0):null;null!=c&&(a=c);if(null!=a&&"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),"0"!=urlParams.pages||1<c.length||1==c.length&&c[0].hasAttribute("name"))){var b=null;this.fileNode=a;this.pages=[];for(var d=0;d<c.length;d++)null==c[d].getAttribute("id")&&c[d].setAttribute("id",d),a=new DiagramPage(c[d]),null==a.getName()&&a.setName(mxResources.get("pageWithNumber",
[d+1])),this.pages.push(a),null!=urlParams["page-id"]&&a.getId()==urlParams["page-id"]&&(b=a);this.currentPage=null!=b?b:this.pages[Math.max(0,Math.min(this.pages.length-1,urlParams.page||0))];a=this.currentPage.node}"0"!=urlParams.pages&&null==this.fileNode&&null!=a&&(this.fileNode=a.ownerDocument.createElement("mxfile"),this.currentPage=new DiagramPage(a.ownerDocument.createElement("diagram")),this.currentPage.setName(mxResources.get("pageWithNumber",[1])),this.pages=[this.currentPage]);this.editor.setGraphXml(a);
-null!=this.currentPage&&(this.currentPage.root=this.editor.graph.model.root);if(null!=urlParams["layer-ids"])try{var e=urlParams["layer-ids"].split(" ");a={};for(d=0;d<e.length;d++)a[e[d]]=!0;for(var n=this.editor.graph.getModel(),k=n.getChildren(n.root),d=0;d<k.length;d++){var t=k[d];n.setVisible(t,a[t.id]||!1)}}catch(u){}};EditorUi.prototype.getBaseFilename=function(a){var c=this.getCurrentFile(),c=null!=c&&null!=c.getTitle()?c.getTitle():this.defaultFilename;if(/(\.xml)$/i.test(c)||/(\.html)$/i.test(c)||
-/(\.svg)$/i.test(c)||/(\.png)$/i.test(c)||/(\.drawio)$/i.test(c))c=c.substring(0,c.lastIndexOf("."));!a&&null!=this.pages&&1<this.pages.length&&null!=this.currentPage&&null!=this.currentPage.node.getAttribute("name")&&0<this.currentPage.getName().length&&(c=c+"-"+this.currentPage.getName());return c};EditorUi.prototype.downloadFile=function(a,b,d,e,l,n,k,t,u,m,q){try{e=null!=e?e:this.editor.graph.isSelectionEmpty();var c=this.getBaseFilename(!l),f=c+"."+a;if("xml"==a){var g='<?xml version="1.0" encoding="UTF-8"?>\n'+
-this.getFileData(!0,null,null,null,e,l,null,null,null,b);this.saveData(f,a,g,"text/xml")}else if("html"==a)g=this.getHtml2(this.getFileData(!0),this.editor.graph,c),this.saveData(f,a,g,"text/html");else if("svg"!=a&&"xmlsvg"!=a||!this.spinner.spin(document.body,mxResources.get("export")))"xmlpng"==a?f=c+".png":"jpeg"==a&&(f=c+".jpg"),this.saveRequest(f,a,mxUtils.bind(this,function(c,b){try{var f=this.editor.graph.pageVisible;null!=n&&(this.editor.graph.pageVisible=n);var d=this.createDownloadRequest(c,
-a,e,b,k,l,t,u,m,q);this.editor.graph.pageVisible=f;return d}catch(L){this.handleError(L)}}));else{var p=null,v=mxUtils.bind(this,function(a){a.length<=MAX_REQUEST_SIZE?this.saveData(f,"svg",a,"image/svg+xml"):this.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(p)}))});if("svg"==a){var A=this.editor.graph.background;if(k||A==mxConstants.NONE)A=null;var B=this.editor.graph.getSvg(A,null,null,null,null,e);d&&this.editor.graph.addSvgShadow(B);
-this.editor.convertImages(B,mxUtils.bind(this,mxUtils.bind(this,function(a){this.spinner.stop();v('<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n'+mxUtils.getXml(a))})))}else f=c+".svg",p=this.getFileData(!1,!0,null,mxUtils.bind(this,function(a){this.spinner.stop();v(a)}),e)}}catch(H){this.handleError(H)}};EditorUi.prototype.createDownloadRequest=function(a,b,d,e,l,n,k,t,u,m){var c=this.editor.graph,f=c.getGraphBounds();
-d=this.getFileData(!0,null,null,null,d,0==n?!1:"xmlpng"!=b);var g="",p="";if(f.width*f.height>MAX_AREA||d.length>MAX_REQUEST_SIZE)throw{message:mxResources.get("drawingTooLarge")};m=m?"1":"0";"pdf"==b&&0==n&&(p="&allPages=1");if("xmlpng"==b&&(m="1",b="png",null!=this.pages&&null!=this.currentPage))for(n=0;n<this.pages.length;n++)if(this.pages[n]==this.currentPage){g="&from="+n;break}n=c.background;"png"==b&&l?n=mxConstants.NONE:l||null!=n&&n!=mxConstants.NONE||(n="#ffffff");l={globalVars:c.getExportVariables()};
-u&&(l.grid={size:c.gridSize,steps:c.view.gridSteps,color:c.view.gridColor});return new mxXmlRequest(EXPORT_URL,"format="+b+g+p+"&bg="+(null!=n?n:mxConstants.NONE)+"&base64="+e+"&embedXml="+m+"&xml="+encodeURIComponent(d)+(null!=a?"&filename="+encodeURIComponent(a):"")+"&extras="+encodeURIComponent(JSON.stringify(l))+(null!=k?"&scale="+k:"")+(null!=t?"&border="+t:""))};EditorUi.prototype.setMode=function(a,b){this.mode=a};EditorUi.prototype.loadDescriptor=function(a,b,d){var c=window.location.hash,
+null!=this.currentPage&&(this.currentPage.root=this.editor.graph.model.root);if(null!=urlParams["layer-ids"])try{var e=urlParams["layer-ids"].split(" ");a={};for(d=0;d<e.length;d++)a[e[d]]=!0;for(var n=this.editor.graph.getModel(),l=n.getChildren(n.root),d=0;d<l.length;d++){var t=l[d];n.setVisible(t,a[t.id]||!1)}}catch(u){}};EditorUi.prototype.getBaseFilename=function(a){var c=this.getCurrentFile(),c=null!=c&&null!=c.getTitle()?c.getTitle():this.defaultFilename;if(/(\.xml)$/i.test(c)||/(\.html)$/i.test(c)||
+/(\.svg)$/i.test(c)||/(\.png)$/i.test(c)||/(\.drawio)$/i.test(c))c=c.substring(0,c.lastIndexOf("."));!a&&null!=this.pages&&1<this.pages.length&&null!=this.currentPage&&null!=this.currentPage.node.getAttribute("name")&&0<this.currentPage.getName().length&&(c=c+"-"+this.currentPage.getName());return c};EditorUi.prototype.downloadFile=function(a,b,d,e,m,n,l,t,u,k,q){try{e=null!=e?e:this.editor.graph.isSelectionEmpty();var c=this.getBaseFilename(!m),f=c+"."+a;if("xml"==a){var g='<?xml version="1.0" encoding="UTF-8"?>\n'+
+this.getFileData(!0,null,null,null,e,m,null,null,null,b);this.saveData(f,a,g,"text/xml")}else if("html"==a)g=this.getHtml2(this.getFileData(!0),this.editor.graph,c),this.saveData(f,a,g,"text/html");else if("svg"!=a&&"xmlsvg"!=a||!this.spinner.spin(document.body,mxResources.get("export")))"xmlpng"==a?f=c+".png":"jpeg"==a&&(f=c+".jpg"),this.saveRequest(f,a,mxUtils.bind(this,function(c,b){try{var f=this.editor.graph.pageVisible;null!=n&&(this.editor.graph.pageVisible=n);var d=this.createDownloadRequest(c,
+a,e,b,l,m,t,u,k,q);this.editor.graph.pageVisible=f;return d}catch(L){this.handleError(L)}}));else{var p=null,v=mxUtils.bind(this,function(a){a.length<=MAX_REQUEST_SIZE?this.saveData(f,"svg",a,"image/svg+xml"):this.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(p)}))});if("svg"==a){var A=this.editor.graph.background;if(l||A==mxConstants.NONE)A=null;var B=this.editor.graph.getSvg(A,null,null,null,null,e);d&&this.editor.graph.addSvgShadow(B);
+this.editor.convertImages(B,mxUtils.bind(this,mxUtils.bind(this,function(a){this.spinner.stop();v('<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n'+mxUtils.getXml(a))})))}else f=c+".svg",p=this.getFileData(!1,!0,null,mxUtils.bind(this,function(a){this.spinner.stop();v(a)}),e)}}catch(H){this.handleError(H)}};EditorUi.prototype.createDownloadRequest=function(a,b,d,e,m,n,l,t,u,k){var c=this.editor.graph,f=c.getGraphBounds();
+d=this.getFileData(!0,null,null,null,d,0==n?!1:"xmlpng"!=b);var g="",p="";if(f.width*f.height>MAX_AREA||d.length>MAX_REQUEST_SIZE)throw{message:mxResources.get("drawingTooLarge")};k=k?"1":"0";"pdf"==b&&0==n&&(p="&allPages=1");if("xmlpng"==b&&(k="1",b="png",null!=this.pages&&null!=this.currentPage))for(n=0;n<this.pages.length;n++)if(this.pages[n]==this.currentPage){g="&from="+n;break}n=c.background;"png"==b&&m?n=mxConstants.NONE:m||null!=n&&n!=mxConstants.NONE||(n="#ffffff");m={globalVars:c.getExportVariables()};
+u&&(m.grid={size:c.gridSize,steps:c.view.gridSteps,color:c.view.gridColor});return new mxXmlRequest(EXPORT_URL,"format="+b+g+p+"&bg="+(null!=n?n:mxConstants.NONE)+"&base64="+e+"&embedXml="+k+"&xml="+encodeURIComponent(d)+(null!=a?"&filename="+encodeURIComponent(a):"")+"&extras="+encodeURIComponent(JSON.stringify(m))+(null!=l?"&scale="+l:"")+(null!=t?"&border="+t:""))};EditorUi.prototype.setMode=function(a,b){this.mode=a};EditorUi.prototype.loadDescriptor=function(a,b,d){var c=window.location.hash,
f=mxUtils.bind(this,function(f){var d=null!=a.data?a.data:"";null!=f&&0<f.length&&(0<d.length&&(d+="\n"),d+=f);f=new LocalFile(this,"csv"!=a.format&&0<d.length?d:this.emptyDiagramXml,null!=urlParams.title?decodeURIComponent(urlParams.title):this.defaultFilename,!0);f.getHash=function(){return c};this.fileLoaded(f);"csv"==a.format&&this.importCsv(d,mxUtils.bind(this,function(a){this.editor.undoManager.clear();this.editor.setModified(!1);this.editor.setStatus("")}));if(null!=a.update){var e=null!=a.interval?
-parseInt(a.interval):6E4,g=null,l=mxUtils.bind(this,function(){var c=this.currentPage;mxUtils.post(a.update,"xml="+encodeURIComponent(mxUtils.getXml(this.editor.getGraphXml())),mxUtils.bind(this,function(a){c===this.currentPage&&(200<=a.getStatus()&&300>=a.getStatus()?(this.updateDiagram(a.getText()),n()):this.handleError({message:mxResources.get("error")+" "+a.getStatus()}))}),mxUtils.bind(this,function(a){this.handleError(a)}))}),n=mxUtils.bind(this,function(){window.clearTimeout(g);g=window.setTimeout(l,
-e)});this.editor.addListener("pageSelected",mxUtils.bind(this,function(){n();l()}));n();l()}null!=b&&b()});if(null!=a.url&&0<a.url.length){var e=a.url;/^https?:\/\//.test(e)&&!this.editor.isCorsEnabledForUrl(e)&&(e=PROXY_URL+"?url="+encodeURIComponent(e));this.editor.loadUrl(e,mxUtils.bind(this,function(a){f(a)}),mxUtils.bind(this,function(a){null!=d&&d(a)}))}else f("")};EditorUi.prototype.updateDiagram=function(a){function c(a){var c=new mxCellOverlay(a.image||e.warningImage,a.tooltip,a.align,a.valign,
-a.offset);c.addListener(mxEvent.CLICK,function(c,b){d.alert(a.tooltip)});return c}var b=null,d=this;if(null!=a&&0<a.length&&(b=mxUtils.parseXml(a),a=null!=b?b.documentElement:null,null!=a&&"updates"==a.nodeName)){var e=this.editor.graph,n=e.getModel();n.beginUpdate();var k=null;try{for(a=a.firstChild;null!=a;){if("update"==a.nodeName){var t=n.getCell(a.getAttribute("id"));if(null!=t){try{var u=a.getAttribute("value");if(null!=u){var m=mxUtils.parseXml(u).documentElement;if(null!=m)if("1"==m.getAttribute("replace-value"))n.setValue(t,
-m);else for(var q=m.attributes,D=0;D<q.length;D++)e.setAttributeForCell(t,q[D].nodeName,0<q[D].nodeValue.length?q[D].nodeValue:null)}}catch(y){null!=window.console&&console.log("Error in value for "+t.id+": "+y)}try{var C=a.getAttribute("style");null!=C&&e.model.setStyle(t,C)}catch(y){null!=window.console&&console.log("Error in style for "+t.id+": "+y)}try{var x=a.getAttribute("icon");if(null!=x){var F=0<x.length?JSON.parse(x):null;null!=F&&F.append||e.removeCellOverlays(t);null!=F&&e.addCellOverlay(t,
+parseInt(a.interval):6E4,g=null,m=mxUtils.bind(this,function(){var c=this.currentPage;mxUtils.post(a.update,"xml="+encodeURIComponent(mxUtils.getXml(this.editor.getGraphXml())),mxUtils.bind(this,function(a){c===this.currentPage&&(200<=a.getStatus()&&300>=a.getStatus()?(this.updateDiagram(a.getText()),n()):this.handleError({message:mxResources.get("error")+" "+a.getStatus()}))}),mxUtils.bind(this,function(a){this.handleError(a)}))}),n=mxUtils.bind(this,function(){window.clearTimeout(g);g=window.setTimeout(m,
+e)});this.editor.addListener("pageSelected",mxUtils.bind(this,function(){n();m()}));n();m()}null!=b&&b()});if(null!=a.url&&0<a.url.length){var e=a.url;/^https?:\/\//.test(e)&&!this.editor.isCorsEnabledForUrl(e)&&(e=PROXY_URL+"?url="+encodeURIComponent(e));this.editor.loadUrl(e,mxUtils.bind(this,function(a){f(a)}),mxUtils.bind(this,function(a){null!=d&&d(a)}))}else f("")};EditorUi.prototype.updateDiagram=function(a){function c(a){var c=new mxCellOverlay(a.image||e.warningImage,a.tooltip,a.align,a.valign,
+a.offset);c.addListener(mxEvent.CLICK,function(c,b){d.alert(a.tooltip)});return c}var b=null,d=this;if(null!=a&&0<a.length&&(b=mxUtils.parseXml(a),a=null!=b?b.documentElement:null,null!=a&&"updates"==a.nodeName)){var e=this.editor.graph,n=e.getModel();n.beginUpdate();var l=null;try{for(a=a.firstChild;null!=a;){if("update"==a.nodeName){var t=n.getCell(a.getAttribute("id"));if(null!=t){try{var u=a.getAttribute("value");if(null!=u){var k=mxUtils.parseXml(u).documentElement;if(null!=k)if("1"==k.getAttribute("replace-value"))n.setValue(t,
+k);else for(var q=k.attributes,D=0;D<q.length;D++)e.setAttributeForCell(t,q[D].nodeName,0<q[D].nodeValue.length?q[D].nodeValue:null)}}catch(y){null!=window.console&&console.log("Error in value for "+t.id+": "+y)}try{var C=a.getAttribute("style");null!=C&&e.model.setStyle(t,C)}catch(y){null!=window.console&&console.log("Error in style for "+t.id+": "+y)}try{var x=a.getAttribute("icon");if(null!=x){var F=0<x.length?JSON.parse(x):null;null!=F&&F.append||e.removeCellOverlays(t);null!=F&&e.addCellOverlay(t,
c(F))}}catch(y){null!=window.console&&console.log("Error in icon for "+t.id+": "+y)}try{var G=a.getAttribute("geometry");if(null!=G){var G=JSON.parse(G),E=e.getCellGeometry(t);if(null!=E){E=E.clone();for(key in G){var J=parseFloat(G[key]);"dx"==key?E.x+=J:"dy"==key?E.y+=J:"dw"==key?E.width+=J:"dh"==key?E.height+=J:E[key]=parseFloat(G[key])}e.model.setGeometry(t,E)}}}catch(y){null!=window.console&&console.log("Error in icon for "+t.id+": "+y)}}}else if("model"==a.nodeName){for(var H=a.firstChild;null!=
-H&&H.nodeType!=mxConstants.NODETYPE_ELEMENT;)H=H.nextSibling;null!=H&&(new mxCodec(a.firstChild)).decode(H,n)}else if("view"==a.nodeName){if(a.hasAttribute("scale")&&(e.view.scale=parseFloat(a.getAttribute("scale"))),a.hasAttribute("dx")||a.hasAttribute("dy"))e.view.translate=new mxPoint(parseFloat(a.getAttribute("dx")||0),parseFloat(a.getAttribute("dy")||0))}else"fit"==a.nodeName&&(k=a.hasAttribute("max-scale")?parseFloat(a.getAttribute("max-scale")):1);a=a.nextSibling}}finally{n.endUpdate()}null!=
-k&&this.chromelessResize&&this.chromelessResize(!0,k)}return b};EditorUi.prototype.getCopyFilename=function(a,b){var c=null!=a&&null!=a.getTitle()?a.getTitle():this.defaultFilename,f="",d=c.lastIndexOf(".");0<=d&&(f=c.substring(d),c=c.substring(0,d));if(b)var e=new Date,d=e.getFullYear(),k=e.getMonth()+1,t=e.getDate(),u=e.getHours(),m=e.getMinutes(),e=e.getSeconds(),c=c+(" "+(d+"-"+k+"-"+t+"-"+u+"-"+m+"-"+e));return c=mxResources.get("copyOf",[c])+f};EditorUi.prototype.fileLoaded=function(a,b){var c=
+H&&H.nodeType!=mxConstants.NODETYPE_ELEMENT;)H=H.nextSibling;null!=H&&(new mxCodec(a.firstChild)).decode(H,n)}else if("view"==a.nodeName){if(a.hasAttribute("scale")&&(e.view.scale=parseFloat(a.getAttribute("scale"))),a.hasAttribute("dx")||a.hasAttribute("dy"))e.view.translate=new mxPoint(parseFloat(a.getAttribute("dx")||0),parseFloat(a.getAttribute("dy")||0))}else"fit"==a.nodeName&&(l=a.hasAttribute("max-scale")?parseFloat(a.getAttribute("max-scale")):1);a=a.nextSibling}}finally{n.endUpdate()}null!=
+l&&this.chromelessResize&&this.chromelessResize(!0,l)}return b};EditorUi.prototype.getCopyFilename=function(a,b){var c=null!=a&&null!=a.getTitle()?a.getTitle():this.defaultFilename,f="",d=c.lastIndexOf(".");0<=d&&(f=c.substring(d),c=c.substring(0,d));if(b)var e=new Date,d=e.getFullYear(),l=e.getMonth()+1,t=e.getDate(),u=e.getHours(),k=e.getMinutes(),e=e.getSeconds(),c=c+(" "+(d+"-"+l+"-"+t+"-"+u+"-"+k+"-"+e));return c=mxResources.get("copyOf",[c])+f};EditorUi.prototype.fileLoaded=function(a,b){var c=
this.getCurrentFile();this.fileLoadedError=null;this.setCurrentFile(null);var f=!1;this.hideDialog();null!=c&&(EditorUi.debug("File.closed",[c]),c.removeListener(this.descriptorChangedListener),c.close());this.editor.graph.model.clear();this.editor.undoManager.clear();var d=mxUtils.bind(this,function(){this.setGraphEnabled(!1);this.setCurrentFile(null);null!=c&&this.updateDocumentTitle();this.editor.graph.model.clear();this.editor.undoManager.clear();this.setBackgroundImage(null);!b&&null!=window.location.hash&&
0<window.location.hash.length&&(window.location.hash="");null!=this.fname&&(this.fnameWrapper.style.display="none",this.fname.innerHTML="",this.fname.setAttribute("title",mxResources.get("rename")));this.editor.setStatus("");this.updateUi();b||this.showSplash()});if(null!=a)try{mxClient.IS_SF&&"min"==uiTheme&&(this.diagramContainer.style.visibility="");this.openingFile=!0;this.setCurrentFile(a);a.addListener("descriptorChanged",this.descriptorChangedListener);a.addListener("contentChanged",this.descriptorChangedListener);
a.open();delete this.openingFile;this.setGraphEnabled(!0);this.setMode(a.getMode());this.editor.graph.model.prefix=Editor.guid()+"-";this.editor.undoManager.clear();this.descriptorChanged();this.updateUi();a.isEditable()?a.isModified()?(a.addUnsavedStatus(),null!=a.backupPatch&&a.patch([a.backupPatch])):this.editor.setStatus(""):this.editor.setStatus('<span class="geStatusAlert" style="margin-left:8px;">'+mxUtils.htmlEntities(mxResources.get("readOnly"))+"</span>");!this.editor.isChromelessView()||
this.editor.editable?(this.editor.graph.selectUnlockedLayer(),this.showLayersDialog(),this.restoreLibraries(),window.self!==window.top&&window.focus()):this.editor.graph.isLightboxView()&&this.lightboxFit();this.chromelessResize&&this.chromelessResize();this.editor.fireEvent(new mxEventObject("fileLoaded"));f=!0;this.isOffline()||null==a.getMode()||EditorUi.logEvent({category:a.getMode().toUpperCase()+"-OPEN-FILE-"+a.getHash(),action:"size_"+a.getSize(),label:"autosave_"+(this.editor.autosave?"on":
"off")});EditorUi.debug("File.opened",[a]);if(this.editor.editable&&this.mode==a.getMode()&&a.getMode()!=App.MODE_DEVICE&&null!=a.getMode())try{this.addRecent({id:a.getHash(),title:a.getTitle(),mode:a.getMode()})}catch(v){}try{mxSettings.setOpenCounter(mxSettings.getOpenCounter()+1),mxSettings.save()}catch(v){}}catch(v){this.fileLoadedError=v;if(EditorUi.enableLogging&&!this.isOffline())try{EditorUi.logEvent({category:"ERROR-LOAD-FILE-"+(null!=a?a.getHash():"none"),action:"message_"+v.message,label:"stack_"+
v.stack})}catch(t){}var e=mxUtils.bind(this,function(){null!=urlParams.url&&this.spinner.spin(document.body,mxResources.get("reconnecting"))?window.location.search=this.getSearch(["url"]):null!=c?this.fileLoaded(c):d()});b?e():this.handleError(v,mxResources.get("errorLoadingFile"),e,!0,null,null,!0)}else d();return f};EditorUi.prototype.getHashValueForPages=function(a,b){var c=0,f=new mxGraphModel,d=new mxCodec;null!=b&&(b.byteCount=0,b.attrCount=0,b.eltCount=0,b.nodeCount=0);for(var e=0;e<a.length;e++){this.updatePageRoot(a[e]);
-var k=a[e].node.cloneNode(!1);k.removeAttribute("name");f.root=a[e].root;var t=d.encode(f);this.editor.graph.saveViewState(a[e].viewState,t,!0);t.removeAttribute("pageWidth");t.removeAttribute("pageHeight");k.appendChild(t);null!=b&&(b.eltCount+=k.getElementsByTagName("*").length,b.nodeCount+=k.getElementsByTagName("mxCell").length);c=(c<<5)-c+this.hashValue(k,function(a,c,b,f){return!f||"mxGeometry"!=a.nodeName&&"mxPoint"!=a.nodeName||"x"!=c&&"y"!=c&&"width"!=c&&"height"!=c?f&&"mxCell"==a.nodeName&&
+var l=a[e].node.cloneNode(!1);l.removeAttribute("name");f.root=a[e].root;var t=d.encode(f);this.editor.graph.saveViewState(a[e].viewState,t,!0);t.removeAttribute("pageWidth");t.removeAttribute("pageHeight");l.appendChild(t);null!=b&&(b.eltCount+=l.getElementsByTagName("*").length,b.nodeCount+=l.getElementsByTagName("mxCell").length);c=(c<<5)-c+this.hashValue(l,function(a,c,b,f){return!f||"mxGeometry"!=a.nodeName&&"mxPoint"!=a.nodeName||"x"!=c&&"y"!=c&&"width"!=c&&"height"!=c?f&&"mxCell"==a.nodeName&&
"previous"==c?null:b:Math.round(b)},b)<<0}return c};EditorUi.prototype.hashValue=function(a,b,d){var c=0;if(null!=a&&"object"===typeof a&&"number"===typeof a.nodeType&&"string"===typeof a.nodeName&&"function"===typeof a.getAttribute){null!=a.nodeName&&(c^=this.hashValue(a.nodeName,b,d));if(null!=a.attributes){null!=d&&(d.attrCount+=a.attributes.length);for(var f=0;f<a.attributes.length;f++){var e=a.attributes[f].name,g=null!=b?b(a,e,a.attributes[f].value,!0):a.attributes[f].value;null!=g&&(c^=this.hashValue(e,
-b,d)+this.hashValue(g,b,d))}}if(null!=a.childNodes)for(f=0;f<a.childNodes.length;f++)c=(c<<5)-c+this.hashValue(a.childNodes[f],b,d)<<0}else if(null!=a&&"function"!==typeof a){a=String(a);b=0;null!=d&&(d.byteCount+=a.length);for(f=0;f<a.length;f++)b=(b<<5)-b+a.charCodeAt(f)<<0;c^=b}return c};EditorUi.prototype.descriptorChanged=function(){};EditorUi.prototype.restoreLibraries=function(){};EditorUi.prototype.saveLibrary=function(a,b,d,e,l,n,k){};EditorUi.prototype.isScratchpadEnabled=function(){return isLocalStorage||
+b,d)+this.hashValue(g,b,d))}}if(null!=a.childNodes)for(f=0;f<a.childNodes.length;f++)c=(c<<5)-c+this.hashValue(a.childNodes[f],b,d)<<0}else if(null!=a&&"function"!==typeof a){a=String(a);b=0;null!=d&&(d.byteCount+=a.length);for(f=0;f<a.length;f++)b=(b<<5)-b+a.charCodeAt(f)<<0;c^=b}return c};EditorUi.prototype.descriptorChanged=function(){};EditorUi.prototype.restoreLibraries=function(){};EditorUi.prototype.saveLibrary=function(a,b,d,e,m,n,l){};EditorUi.prototype.isScratchpadEnabled=function(){return isLocalStorage||
mxClient.IS_CHROMEAPP};EditorUi.prototype.toggleScratchpad=function(){this.isScratchpadEnabled()&&(null==this.scratchpad?StorageFile.getFileContent(this,".scratchpad",mxUtils.bind(this,function(a){null==a&&(a=this.emptyLibraryXml);this.loadLibrary(new StorageLibrary(this,a,".scratchpad"))})):this.closeLibrary(this.scratchpad))};EditorUi.prototype.createLibraryDataFromImages=function(a){var c=mxUtils.createXmlDocument(),b=c.createElement("mxlibrary");mxUtils.setTextContent(b,JSON.stringify(a));c.appendChild(b);
return mxUtils.getXml(c)};EditorUi.prototype.closeLibrary=function(a){null!=a&&(this.removeLibrarySidebar(a.getHash()),a.constructor!=LocalLibrary&&mxSettings.removeCustomLibrary(a.getHash()),".scratchpad"==a.title&&(this.scratchpad=null))};EditorUi.prototype.removeLibrarySidebar=function(a){var c=this.sidebar.palettes[a];if(null!=c){for(var b=0;b<c.length;b++)c[b].parentNode.removeChild(c[b]);delete this.sidebar.palettes[a]}};EditorUi.prototype.repositionLibrary=function(a){var c=this.sidebar.container;
if(null==a){var b=this.sidebar.palettes["L.scratchpad"];null==b&&(b=this.sidebar.palettes.search);null!=b&&(a=b[b.length-1].nextSibling)}a=null!=a?a:c.firstChild.nextSibling.nextSibling;var b=c.lastChild,d=b.previousSibling;c.insertBefore(b,a);c.insertBefore(d,b)};EditorUi.prototype.loadLibrary=function(a,b){var c=mxUtils.parseXml(a.getData());if("mxlibrary"==c.documentElement.nodeName){var d=JSON.parse(mxUtils.getTextContent(c.documentElement));this.libraryLoaded(a,d,c.documentElement.getAttribute("title"),
b)}else throw{message:mxResources.get("notALibraryFile")};};EditorUi.prototype.getLibraryStorageHint=function(a){return""};EditorUi.prototype.libraryLoaded=function(a,b,d,e){if(null!=this.sidebar){a.constructor!=LocalLibrary&&mxSettings.addCustomLibrary(a.getHash());".scratchpad"==a.title&&(this.scratchpad=a);var c=this.sidebar.palettes[a.getHash()],c=null!=c?c[c.length-1].nextSibling:null;this.removeLibrarySidebar(a.getHash());var f=null,g=mxUtils.bind(this,function(c,b){0==c.length&&a.isEditable()?
(null==f&&(f=document.createElement("div"),f.className="geDropTarget",mxUtils.write(f,mxResources.get("dragElementsHere"))),b.appendChild(f)):this.addLibraryEntries(c,b)});null!=this.sidebar&&null!=b&&this.sidebar.addEntries(b);d=null!=d&&0<d.length?d:a.getTitle();var p=this.sidebar.addPalette(a.getHash(),d,null!=e?e:!0,mxUtils.bind(this,function(a){g(b,a)}));this.repositionLibrary(c);var u=p.parentNode.previousSibling;e=u.getAttribute("title");null!=e&&0<e.length&&".scratchpad"!=a.title&&u.setAttribute("title",
-this.getLibraryStorageHint(a)+"\n"+e);var k=document.createElement("div");k.style.position="absolute";k.style.right="0px";k.style.top="0px";k.style.padding="8px";mxClient.IS_QUIRKS||8==document.documentMode||(k.style.backgroundColor="inherit");u.style.position="relative";var m=document.createElement("img");m.setAttribute("src",Dialog.prototype.closeImage);m.setAttribute("title",mxResources.get("close"));m.setAttribute("valign","absmiddle");m.setAttribute("border","0");m.style.cursor="pointer";m.style.margin=
-"0 3px";var q=null;if(".scratchpad"!=a.title||this.closableScratchpad)k.appendChild(m),mxEvent.addListener(m,"click",mxUtils.bind(this,function(c){if(!mxEvent.isConsumed(c)){var b=mxUtils.bind(this,function(){this.closeLibrary(a)});null!=q?this.confirm(mxResources.get("allChangesLost"),null,b,mxResources.get("cancel"),mxResources.get("discardChanges")):b();mxEvent.consume(c)}}));if(a.isEditable()){var C=this.editor.graph,x=null,F=mxUtils.bind(this,function(c){this.showLibraryDialog(a.getTitle(),p,
-b,a,a.getMode());mxEvent.consume(c)}),G=mxUtils.bind(this,function(c){a.setModified(!0);a.isAutosave()?(null!=x&&null!=x.parentNode&&x.parentNode.removeChild(x),x=m.cloneNode(!1),x.setAttribute("src",Editor.spinImage),x.setAttribute("title",mxResources.get("saving")),x.style.cursor="default",x.style.marginRight="2px",x.style.marginTop="-2px",k.insertBefore(x,k.firstChild),u.style.paddingRight=18*k.childNodes.length+"px",this.saveLibrary(a.getTitle(),b,a,a.getMode(),!0,!0,function(){null!=x&&null!=
-x.parentNode&&(x.parentNode.removeChild(x),u.style.paddingRight=18*k.childNodes.length+"px")})):null==q&&(q=m.cloneNode(!1),q.setAttribute("src",IMAGE_PATH+"/download.png"),q.setAttribute("title",mxResources.get("save")),k.insertBefore(q,k.firstChild),mxEvent.addListener(q,"click",mxUtils.bind(this,function(c){this.saveLibrary(a.getTitle(),b,a,a.getMode(),a.constructor==LocalLibrary,!0,function(){null==q||a.isModified()||(u.style.paddingRight=18*k.childNodes.length+"px",q.parentNode.removeChild(q),
-q=null)});mxEvent.consume(c)})),u.style.paddingRight=18*k.childNodes.length+"px")}),E=mxUtils.bind(this,function(a,c,d,e){a=C.cloneCells(mxUtils.sortCells(C.model.getTopmostCells(a)));for(var g=0;g<a.length;g++){var l=C.getCellGeometry(a[g]);null!=l&&l.translate(-c.x,-c.y)}p.appendChild(this.sidebar.createVertexTemplateFromCells(a,c.width,c.height,e||"",!0,!1,!1));a={xml:Graph.compress(mxUtils.getXml(this.editor.graph.encodeCells(a))),w:c.width,h:c.height};null!=e&&(a.title=e);b.push(a);G(d);null!=
+this.getLibraryStorageHint(a)+"\n"+e);var l=document.createElement("div");l.style.position="absolute";l.style.right="0px";l.style.top="0px";l.style.padding="8px";mxClient.IS_QUIRKS||8==document.documentMode||(l.style.backgroundColor="inherit");u.style.position="relative";var k=document.createElement("img");k.setAttribute("src",Dialog.prototype.closeImage);k.setAttribute("title",mxResources.get("close"));k.setAttribute("valign","absmiddle");k.setAttribute("border","0");k.style.cursor="pointer";k.style.margin=
+"0 3px";var q=null;if(".scratchpad"!=a.title||this.closableScratchpad)l.appendChild(k),mxEvent.addListener(k,"click",mxUtils.bind(this,function(c){if(!mxEvent.isConsumed(c)){var b=mxUtils.bind(this,function(){this.closeLibrary(a)});null!=q?this.confirm(mxResources.get("allChangesLost"),null,b,mxResources.get("cancel"),mxResources.get("discardChanges")):b();mxEvent.consume(c)}}));if(a.isEditable()){var C=this.editor.graph,x=null,F=mxUtils.bind(this,function(c){this.showLibraryDialog(a.getTitle(),p,
+b,a,a.getMode());mxEvent.consume(c)}),G=mxUtils.bind(this,function(c){a.setModified(!0);a.isAutosave()?(null!=x&&null!=x.parentNode&&x.parentNode.removeChild(x),x=k.cloneNode(!1),x.setAttribute("src",Editor.spinImage),x.setAttribute("title",mxResources.get("saving")),x.style.cursor="default",x.style.marginRight="2px",x.style.marginTop="-2px",l.insertBefore(x,l.firstChild),u.style.paddingRight=18*l.childNodes.length+"px",this.saveLibrary(a.getTitle(),b,a,a.getMode(),!0,!0,function(){null!=x&&null!=
+x.parentNode&&(x.parentNode.removeChild(x),u.style.paddingRight=18*l.childNodes.length+"px")})):null==q&&(q=k.cloneNode(!1),q.setAttribute("src",IMAGE_PATH+"/download.png"),q.setAttribute("title",mxResources.get("save")),l.insertBefore(q,l.firstChild),mxEvent.addListener(q,"click",mxUtils.bind(this,function(c){this.saveLibrary(a.getTitle(),b,a,a.getMode(),a.constructor==LocalLibrary,!0,function(){null==q||a.isModified()||(u.style.paddingRight=18*l.childNodes.length+"px",q.parentNode.removeChild(q),
+q=null)});mxEvent.consume(c)})),u.style.paddingRight=18*l.childNodes.length+"px")}),E=mxUtils.bind(this,function(a,c,d,e){a=C.cloneCells(mxUtils.sortCells(C.model.getTopmostCells(a)));for(var g=0;g<a.length;g++){var m=C.getCellGeometry(a[g]);null!=m&&m.translate(-c.x,-c.y)}p.appendChild(this.sidebar.createVertexTemplateFromCells(a,c.width,c.height,e||"",!0,!1,!1));a={xml:Graph.compress(mxUtils.getXml(this.editor.graph.encodeCells(a))),w:c.width,h:c.height};null!=e&&(a.title=e);b.push(a);G(d);null!=
f&&null!=f.parentNode&&0<b.length&&(f.parentNode.removeChild(f),f=null)}),J=mxUtils.bind(this,function(a){if(C.isSelectionEmpty())C.getRubberband().isActive()?(C.getRubberband().execute(a),C.getRubberband().reset()):this.showError(mxResources.get("error"),mxResources.get("nothingIsSelected"),mxResources.get("ok"));else{var c=C.getSelectionCells(),b=C.view.getBounds(c),d=C.view.scale;b.x/=d;b.y/=d;b.width/=d;b.height/=d;b.x-=C.view.translate.x;b.y-=C.view.translate.y;E(c,b)}mxEvent.consume(a)});mxEvent.addGestureListeners(p,
function(){},mxUtils.bind(this,function(a){C.isMouseDown&&null!=C.panningManager&&null!=C.graphHandler.first&&(C.graphHandler.suspend(),null!=C.graphHandler.hint&&(C.graphHandler.hint.style.visibility="hidden"),p.style.backgroundColor="#f1f3f4",p.style.cursor="copy",C.panningManager.stop(),C.autoScroll=!1,mxEvent.consume(a))}),mxUtils.bind(this,function(a){C.isMouseDown&&null!=C.panningManager&&null!=C.graphHandler&&(p.style.backgroundColor="",p.style.cursor="default",this.sidebar.showTooltips=!0,
C.panningManager.stop(),C.graphHandler.reset(),C.isMouseDown=!1,C.autoScroll=!0,J(a),mxEvent.consume(a))}));mxEvent.addListener(p,"mouseleave",mxUtils.bind(this,function(a){C.isMouseDown&&null!=C.graphHandler.first&&(C.graphHandler.resume(),null!=C.graphHandler.hint&&(C.graphHandler.hint.style.visibility="visible"),p.style.backgroundColor="",p.style.cursor="",C.autoScroll=!0)}));Graph.fileSupport&&(mxEvent.addListener(p,"dragover",mxUtils.bind(this,function(a){p.style.backgroundColor="#f1f3f4";a.dataTransfer.dropEffect=
-"copy";p.style.cursor="copy";this.sidebar.hideTooltip();a.stopPropagation();a.preventDefault()})),mxEvent.addListener(p,"drop",mxUtils.bind(this,function(a){p.style.cursor="";p.style.backgroundColor="";0<a.dataTransfer.files.length&&this.importFiles(a.dataTransfer.files,0,0,this.maxImageSize,mxUtils.bind(this,function(c,d,e,l,n,u,k,t,m){if(null!=c&&"image/"==d.substring(0,6))c="shape=image;verticalLabelPosition=bottom;verticalAlign=top;imageAspect=0;aspect=fixed;image="+this.convertDataUri(c),c=[new mxCell("",
-new mxGeometry(0,0,n,u),c)],c[0].vertex=!0,E(c,new mxRectangle(0,0,n,u),a,mxEvent.isAltDown(a)?null:k.substring(0,k.lastIndexOf(".")).replace(/_/g," ")),null!=f&&null!=f.parentNode&&0<b.length&&(f.parentNode.removeChild(f),f=null);else{var v=!1,q=mxUtils.bind(this,function(c,d){if(null!=c&&"application/pdf"==d){var e=Editor.extractGraphModelFromPdf(c);null!=e&&0<e.length&&(c=e)}if(null!=c)if(e=mxUtils.parseXml(c),"mxlibrary"==e.documentElement.nodeName)try{var l=JSON.parse(mxUtils.getTextContent(e.documentElement));
-g(l,p);b=b.concat(l);G(a);this.spinner.stop();v=!0}catch(M){}else if("mxfile"==e.documentElement.nodeName)try{for(var n=e.documentElement.getElementsByTagName("diagram"),l=0;l<n.length;l++){var u=this.stringToCells(Editor.getDiagramNodeXml(n[l])),k=this.editor.graph.getBoundingBoxFromGeometry(u);E(u,new mxRectangle(0,0,k.width,k.height),a)}v=!0}catch(M){null!=window.console&&console.log("error in drop handler:",M)}v||(this.spinner.stop(),this.handleError({message:mxResources.get("errorLoadingFile")}));
-null!=f&&null!=f.parentNode&&0<b.length&&(f.parentNode.removeChild(f),f=null)});null!=m&&null!=k&&(/(\.v(dx|sdx?))($|\?)/i.test(k)||/(\.vs(x|sx?))($|\?)/i.test(k))?this.importVisio(m,function(a){q(a,"text/xml")},null,k):!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,k)&&null!=m?this.parseFile(m,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?q(a.responseText,"text/xml"):this.handleError({message:mxResources.get(413==a.status?
-"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))})):q(c,d)}}));a.stopPropagation();a.preventDefault()})),mxEvent.addListener(p,"dragleave",function(a){p.style.cursor="";p.style.backgroundColor="";a.stopPropagation();a.preventDefault()}));m=m.cloneNode(!1);m.setAttribute("src",Editor.editImage);m.setAttribute("title",mxResources.get("edit"));k.insertBefore(m,k.firstChild);mxEvent.addListener(m,"click",F);mxEvent.addListener(p,"dblclick",function(a){mxEvent.getSource(a)==
-p&&F(a)});e=m.cloneNode(!1);e.setAttribute("src",Editor.plusImage);e.setAttribute("title",mxResources.get("add"));k.insertBefore(e,k.firstChild);mxEvent.addListener(e,"click",J);this.isOffline()||".scratchpad"!=a.title||null==EditorUi.scratchpadHelpLink||(e=document.createElement("span"),e.setAttribute("title",mxResources.get("help")),e.style.cssText="color:#a3a3a3;text-decoration:none;margin-right:2px;",mxUtils.write(e,"?"),mxEvent.addGestureListeners(e,mxUtils.bind(this,function(a){this.openLink(EditorUi.scratchpadHelpLink);
-mxEvent.consume(a)})),k.insertBefore(e,k.firstChild))}u.appendChild(k);u.style.paddingRight=18*k.childNodes.length+"px"}};EditorUi.prototype.addLibraryEntries=function(a,b){for(var c=0;c<a.length;c++){var d=a[c],f=d.data;if(null!=f){var f=this.convertDataUri(f),e="shape=image;verticalLabelPosition=bottom;verticalAlign=top;imageAspect=0;";"fixed"==d.aspect&&(e+="aspect=fixed;");b.appendChild(this.sidebar.createVertexTemplate(e+"image="+f,d.w,d.h,"",d.title||"",!1,!1,!0))}else null!=d.xml&&(f=this.stringToCells(Graph.decompress(d.xml)),
+"copy";p.style.cursor="copy";this.sidebar.hideTooltip();a.stopPropagation();a.preventDefault()})),mxEvent.addListener(p,"drop",mxUtils.bind(this,function(a){p.style.cursor="";p.style.backgroundColor="";0<a.dataTransfer.files.length&&this.importFiles(a.dataTransfer.files,0,0,this.maxImageSize,mxUtils.bind(this,function(c,d,e,m,n,u,l,t,k){if(null!=c&&"image/"==d.substring(0,6))c="shape=image;verticalLabelPosition=bottom;verticalAlign=top;imageAspect=0;aspect=fixed;image="+this.convertDataUri(c),c=[new mxCell("",
+new mxGeometry(0,0,n,u),c)],c[0].vertex=!0,E(c,new mxRectangle(0,0,n,u),a,mxEvent.isAltDown(a)?null:l.substring(0,l.lastIndexOf(".")).replace(/_/g," ")),null!=f&&null!=f.parentNode&&0<b.length&&(f.parentNode.removeChild(f),f=null);else{var v=!1,q=mxUtils.bind(this,function(c,d){if(null!=c&&"application/pdf"==d){var e=Editor.extractGraphModelFromPdf(c);null!=e&&0<e.length&&(c=e)}if(null!=c)if(e=mxUtils.parseXml(c),"mxlibrary"==e.documentElement.nodeName)try{var m=JSON.parse(mxUtils.getTextContent(e.documentElement));
+g(m,p);b=b.concat(m);G(a);this.spinner.stop();v=!0}catch(M){}else if("mxfile"==e.documentElement.nodeName)try{for(var n=e.documentElement.getElementsByTagName("diagram"),m=0;m<n.length;m++){var u=this.stringToCells(Editor.getDiagramNodeXml(n[m])),l=this.editor.graph.getBoundingBoxFromGeometry(u);E(u,new mxRectangle(0,0,l.width,l.height),a)}v=!0}catch(M){null!=window.console&&console.log("error in drop handler:",M)}v||(this.spinner.stop(),this.handleError({message:mxResources.get("errorLoadingFile")}));
+null!=f&&null!=f.parentNode&&0<b.length&&(f.parentNode.removeChild(f),f=null)});null!=k&&null!=l&&(/(\.v(dx|sdx?))($|\?)/i.test(l)||/(\.vs(x|sx?))($|\?)/i.test(l))?this.importVisio(k,function(a){q(a,"text/xml")},null,l):!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,l)&&null!=k?this.parseFile(k,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?q(a.responseText,"text/xml"):this.handleError({message:mxResources.get(413==a.status?
+"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))})):q(c,d)}}));a.stopPropagation();a.preventDefault()})),mxEvent.addListener(p,"dragleave",function(a){p.style.cursor="";p.style.backgroundColor="";a.stopPropagation();a.preventDefault()}));k=k.cloneNode(!1);k.setAttribute("src",Editor.editImage);k.setAttribute("title",mxResources.get("edit"));l.insertBefore(k,l.firstChild);mxEvent.addListener(k,"click",F);mxEvent.addListener(p,"dblclick",function(a){mxEvent.getSource(a)==
+p&&F(a)});e=k.cloneNode(!1);e.setAttribute("src",Editor.plusImage);e.setAttribute("title",mxResources.get("add"));l.insertBefore(e,l.firstChild);mxEvent.addListener(e,"click",J);this.isOffline()||".scratchpad"!=a.title||null==EditorUi.scratchpadHelpLink||(e=document.createElement("span"),e.setAttribute("title",mxResources.get("help")),e.style.cssText="color:#a3a3a3;text-decoration:none;margin-right:2px;",mxUtils.write(e,"?"),mxEvent.addGestureListeners(e,mxUtils.bind(this,function(a){this.openLink(EditorUi.scratchpadHelpLink);
+mxEvent.consume(a)})),l.insertBefore(e,l.firstChild))}u.appendChild(l);u.style.paddingRight=18*l.childNodes.length+"px"}};EditorUi.prototype.addLibraryEntries=function(a,b){for(var c=0;c<a.length;c++){var d=a[c],f=d.data;if(null!=f){var f=this.convertDataUri(f),e="shape=image;verticalLabelPosition=bottom;verticalAlign=top;imageAspect=0;";"fixed"==d.aspect&&(e+="aspect=fixed;");b.appendChild(this.sidebar.createVertexTemplate(e+"image="+f,d.w,d.h,"",d.title||"",!1,!1,!0))}else null!=d.xml&&(f=this.stringToCells(Graph.decompress(d.xml)),
0<f.length&&b.appendChild(this.sidebar.createVertexTemplateFromCells(f,d.w,d.h,d.title||"",!0,!1,!0)))}};EditorUi.prototype.getResource=function(a){return null!=a?a[mxLanguage]||a.main:null};EditorUi.prototype.footerHeight=0;"1"==urlParams.savesidebar&&(Sidebar.prototype.thumbWidth=64,Sidebar.prototype.thumbHeight=64);EditorUi.initTheme=function(){"atlas"==uiTheme?(mxClient.link("stylesheet",STYLE_PATH+"/atlas.css"),"undefined"!==typeof Toolbar&&(Toolbar.prototype.unselectedBackground=mxClient.IS_QUIRKS?
"none":"linear-gradient(rgb(255, 255, 255) 0px, rgb(242, 242, 242) 100%)",Toolbar.prototype.selectedBackground="rgb(242, 242, 242)"),Editor.prototype.initialTopSpacing=3,EditorUi.prototype.menubarHeight=41,EditorUi.prototype.toolbarHeight=38):"dark"==uiTheme&&(mxClient.link("stylesheet",STYLE_PATH+"/dark.css"),Dialog.backdropColor="#2a2a2a",Graph.prototype.defaultThemeName="darkTheme",Graph.prototype.defaultPageBackgroundColor="#2a2a2a",Graph.prototype.defaultPageBorderColor="#505759",Format.prototype.inactiveTabBackgroundColor=
"black",BaseFormatPanel.prototype.buttonBackgroundColor="#2a2a2a",Sidebar.prototype.dragPreviewBorder="1px dashed #cccccc",mxGraphHandler.prototype.previewColor="#cccccc",StyleFormatPanel.prototype.defaultStrokeColor="#cccccc",mxConstants.DROP_TARGET_COLOR="#00ff00",mxClient.IS_SVG&&(Editor.helpImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAP1BMVEUAAAD///////////////////////////////////////////////////////////////////////////////9Du/pqAAAAFXRSTlMAT30qCJRBboyDZyCgRzUUdF46MJlgXETgAAAAeklEQVQY022O2w4DIQhEQUURda/9/28tUO2+7CQS5sgQ4F1RapX78YUwRqQjTU8ILqQfKerTKTvACJ4nLX3krt+8aS82oI8aQC4KavRgtvEW/mDvsICgA03PSGRr79MqX1YPNIxzjyqtw8ZnnRo4t5a5undtJYRywau+ds4Cyza3E6YAAAAASUVORK5CYII=",
-Editor.checkmarkImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABUAAAAVCAMAAACeyVWkAAAARVBMVEUAAACZmZkICAgEBASNjY2Dg4MYGBiTk5N5eXl1dXVmZmZQUFBCQkI3NzceHh4MDAykpKSJiYl+fn5sbGxaWlo/Pz8SEhK96uPlAAAAAXRSTlMAQObYZgAAAE5JREFUGNPFzTcSgDAQQ1HJGUfy/Y9K7V1qeOUfzQifCQZai1XHaz11LFysbDbzgDSSWMZiETz3+b8yNUc/MMsktxuC8XQBSncdLwz+8gCCggGXzBcozAAAAABJRU5ErkJggg=="))};EditorUi.initTheme();EditorUi.prototype.showImageDialog=function(a,b,d,e,l){a=new ImageDialog(this,a,b,d,e,l);this.showDialog(a.container,Graph.fileSupport?
-480:360,Graph.fileSupport?200:90,!0,!0);a.init()};EditorUi.prototype.showBackgroundImageDialog=function(a){a=null!=a?a:mxUtils.bind(this,function(a){a=new ChangePageSetup(this,null,a);a.ignoreColor=!0;this.editor.graph.model.execute(a)});var c=new BackgroundImageDialog(this,mxUtils.bind(this,function(c){a(c)}));this.showDialog(c.container,360,200,!0,!0);c.init()};EditorUi.prototype.showLibraryDialog=function(a,b,d,e,l){a=new LibraryDialog(this,a,b,d,e,l);this.showDialog(a.container,640,440,!0,!1,
+Editor.checkmarkImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABUAAAAVCAMAAACeyVWkAAAARVBMVEUAAACZmZkICAgEBASNjY2Dg4MYGBiTk5N5eXl1dXVmZmZQUFBCQkI3NzceHh4MDAykpKSJiYl+fn5sbGxaWlo/Pz8SEhK96uPlAAAAAXRSTlMAQObYZgAAAE5JREFUGNPFzTcSgDAQQ1HJGUfy/Y9K7V1qeOUfzQifCQZai1XHaz11LFysbDbzgDSSWMZiETz3+b8yNUc/MMsktxuC8XQBSncdLwz+8gCCggGXzBcozAAAAABJRU5ErkJggg=="))};EditorUi.initTheme();EditorUi.prototype.showImageDialog=function(a,b,d,e,m){a=new ImageDialog(this,a,b,d,e,m);this.showDialog(a.container,Graph.fileSupport?
+480:360,Graph.fileSupport?200:90,!0,!0);a.init()};EditorUi.prototype.showBackgroundImageDialog=function(a){a=null!=a?a:mxUtils.bind(this,function(a){a=new ChangePageSetup(this,null,a);a.ignoreColor=!0;this.editor.graph.model.execute(a)});var c=new BackgroundImageDialog(this,mxUtils.bind(this,function(c){a(c)}));this.showDialog(c.container,360,200,!0,!0);c.init()};EditorUi.prototype.showLibraryDialog=function(a,b,d,e,m){a=new LibraryDialog(this,a,b,d,e,m);this.showDialog(a.container,640,440,!0,!1,
mxUtils.bind(this,function(a){a&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()}));a.init()};var b=EditorUi.prototype.createFormat;EditorUi.prototype.createFormat=function(a){var c=b.apply(this,arguments);this.editor.graph.addListener("viewStateChanged",mxUtils.bind(this,function(a){this.editor.graph.isSelectionEmpty()&&c.refresh()}));return c};EditorUi.prototype.createSidebarFooterContainer=function(){var a=this.createDiv("geSidebarContainer geSidebarFooter");a.style.position=
"absolute";a.style.overflow="hidden";var b=document.createElement("a");b.className="geTitle";b.style.color="#DF6C0C";b.style.fontWeight="bold";b.style.height="100%";b.style.paddingTop="9px";b.innerHTML='<span style="font-size:18px;margin-right:5px;">+</span>';mxUtils.write(b,mxResources.get("moreShapes")+"...");mxEvent.addListener(b,mxClient.IS_POINTER?"pointerdown":"mousedown",mxUtils.bind(this,function(a){a.preventDefault()}));mxEvent.addListener(b,"click",mxUtils.bind(this,function(a){this.actions.get("shapes").funct();
-mxEvent.consume(a)}));a.appendChild(b);return a};EditorUi.prototype.handleError=function(a,b,d,e,l,n,k){var c=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},f=null!=a&&null!=a.error?a.error:a;if(null!=a&&null!=a.stack&&null!=a.message)try{k?null!=window.console&&console.error("EditorUi.handleError:",a):EditorUi.logError("Caught: "+(null!=a.message?a.message:"null"),null,null,null,a,"INFO")}catch(x){}if(null!=f||null!=b){k=mxUtils.htmlEntities(mxResources.get("unknownError"));
-var g=mxResources.get("ok"),p=null;b=null!=b?b:mxResources.get("error");if(null!=f){null!=f.retry&&(g=mxResources.get("cancel"),p=function(){c();f.retry()});if(404==f.code||404==f.status||403==f.code){k=403==f.code?null!=f.message?mxUtils.htmlEntities(f.message):mxUtils.htmlEntities(mxResources.get("accessDenied")):null!=l?l:mxUtils.htmlEntities(mxResources.get("fileNotFoundOrDenied")+(null!=this.drive&&null!=this.drive.user?" ("+this.drive.user.displayName+", "+this.drive.user.email+")":""));var m=
-null!=n?n:window.location.hash;if(null!=m&&("#G"==m.substring(0,2)||"#Uhttps%3A%2F%2Fdrive.google.com%2Fuc%3Fid%3D"==m.substring(0,45))&&(null!=a&&null!=a.error&&(null!=a.error.errors&&0<a.error.errors.length&&"fileAccess"==a.error.errors[0].reason||null!=a.error.data&&0<a.error.data.length&&"fileAccess"==a.error.data[0].reason)||404==f.code||404==f.status)){m="#U"==m.substring(0,2)?m.substring(45,m.lastIndexOf("%26ex")):m.substring(2);this.showError(b,k,mxResources.get("openInNewWindow"),mxUtils.bind(this,
-function(){this.editor.graph.openLink("https://drive.google.com/open?id="+m);this.handleError(a,b,d,e,l)}),p,mxResources.get("changeUser"),mxUtils.bind(this,function(){function a(){f.innerHTML="";for(var a=0;a<c.length;a++){var b=document.createElement("option");mxUtils.write(b,c[a].displayName);b.value=a;f.appendChild(b);b=document.createElement("option");b.innerHTML="&nbsp;&nbsp;&nbsp;";mxUtils.write(b,"<"+c[a].email+">");b.setAttribute("disabled","disabled");f.appendChild(b)}b=document.createElement("option");
+mxEvent.consume(a)}));a.appendChild(b);return a};EditorUi.prototype.handleError=function(a,b,d,e,m,n,l){var c=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},f=null!=a&&null!=a.error?a.error:a;if(null!=a&&null!=a.stack&&null!=a.message)try{l?null!=window.console&&console.error("EditorUi.handleError:",a):EditorUi.logError("Caught: "+(null!=a.message?a.message:"null"),null,null,null,a,"INFO")}catch(x){}if(null!=f||null!=b){l=mxUtils.htmlEntities(mxResources.get("unknownError"));
+var g=mxResources.get("ok"),p=null;b=null!=b?b:mxResources.get("error");if(null!=f){null!=f.retry&&(g=mxResources.get("cancel"),p=function(){c();f.retry()});if(404==f.code||404==f.status||403==f.code){l=403==f.code?null!=f.message?mxUtils.htmlEntities(f.message):mxUtils.htmlEntities(mxResources.get("accessDenied")):null!=m?m:mxUtils.htmlEntities(mxResources.get("fileNotFoundOrDenied")+(null!=this.drive&&null!=this.drive.user?" ("+this.drive.user.displayName+", "+this.drive.user.email+")":""));var k=
+null!=n?n:window.location.hash;if(null!=k&&("#G"==k.substring(0,2)||"#Uhttps%3A%2F%2Fdrive.google.com%2Fuc%3Fid%3D"==k.substring(0,45))&&(null!=a&&null!=a.error&&(null!=a.error.errors&&0<a.error.errors.length&&"fileAccess"==a.error.errors[0].reason||null!=a.error.data&&0<a.error.data.length&&"fileAccess"==a.error.data[0].reason)||404==f.code||404==f.status)){k="#U"==k.substring(0,2)?k.substring(45,k.lastIndexOf("%26ex")):k.substring(2);this.showError(b,l,mxResources.get("openInNewWindow"),mxUtils.bind(this,
+function(){this.editor.graph.openLink("https://drive.google.com/open?id="+k);this.handleError(a,b,d,e,m)}),p,mxResources.get("changeUser"),mxUtils.bind(this,function(){function a(){f.innerHTML="";for(var a=0;a<c.length;a++){var b=document.createElement("option");mxUtils.write(b,c[a].displayName);b.value=a;f.appendChild(b);b=document.createElement("option");b.innerHTML="&nbsp;&nbsp;&nbsp;";mxUtils.write(b,"<"+c[a].email+">");b.setAttribute("disabled","disabled");f.appendChild(b)}b=document.createElement("option");
mxUtils.write(b,mxResources.get("addAccount"));b.value=c.length;f.appendChild(b)}var c=this.drive.getUsersList(),b=document.createElement("div"),d=document.createElement("span");d.style.marginTop="6px";mxUtils.write(d,mxResources.get("changeUser")+": ");b.appendChild(d);var f=document.createElement("select");f.style.width="200px";a();mxEvent.addListener(f,"change",mxUtils.bind(this,function(){var b=f.value,d=c.length!=b;d&&this.drive.setUser(c[b]);this.drive.authorize(d,mxUtils.bind(this,function(){d||
-(c=this.drive.getUsersList(),a())}),mxUtils.bind(this,function(a){this.handleError(a)}),!0)}));b.appendChild(f);b=new CustomDialog(this,b,mxUtils.bind(this,function(){this.loadFile(window.location.hash.substr(1),!0)}));this.showDialog(b.container,300,75,!0,!0)}),mxResources.get("cancel"),mxUtils.bind(this,function(){this.hideDialog();null!=d&&d()}),480,150);return}}null!=f.message?k=mxUtils.htmlEntities(f.message):null!=f.response&&null!=f.response.error?k=mxUtils.htmlEntities(f.response.error):"undefined"!==
-typeof window.App&&(f.code==App.ERROR_TIMEOUT?k=mxUtils.htmlEntities(mxResources.get("timeout")):f.code==App.ERROR_BUSY&&(k=mxUtils.htmlEntities(mxResources.get("busy"))))}var v=n=null;null!=f&&null!=f.helpLink&&(n=mxResources.get("help"),v=mxUtils.bind(this,function(){return this.editor.graph.openLink(f.helpLink)}));this.showError(b,k,g,d,p,null,null,n,v,null,null,null,e?d:null)}else null!=d&&d()};EditorUi.prototype.alert=function(a,b){var c=new ErrorDialog(this,null,a,mxResources.get("ok"),b);this.showDialog(c.container,
-340,100,!0,!1);c.init()};EditorUi.prototype.confirm=function(a,b,d,e,l,n){var c=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},f=Math.min(200,28*Math.ceil(a.length/50));a=new ConfirmDialog(this,a,function(){c();null!=b&&b()},function(){c();null!=d&&d()},e,l,null,null,null,null,f);this.showDialog(a.container,340,46+f,!0,n);a.init()};EditorUi.prototype.showBanner=function(a,b,d){var c=!1;if(!(this.bannerShowing||this["hideBanner"+a]||isLocalStorage&&null!=mxSettings.settings&&
+(c=this.drive.getUsersList(),a())}),mxUtils.bind(this,function(a){this.handleError(a)}),!0)}));b.appendChild(f);b=new CustomDialog(this,b,mxUtils.bind(this,function(){this.loadFile(window.location.hash.substr(1),!0)}));this.showDialog(b.container,300,75,!0,!0)}),mxResources.get("cancel"),mxUtils.bind(this,function(){this.hideDialog();null!=d&&d()}),480,150);return}}null!=f.message?l=mxUtils.htmlEntities(f.message):null!=f.response&&null!=f.response.error?l=mxUtils.htmlEntities(f.response.error):"undefined"!==
+typeof window.App&&(f.code==App.ERROR_TIMEOUT?l=mxUtils.htmlEntities(mxResources.get("timeout")):f.code==App.ERROR_BUSY&&(l=mxUtils.htmlEntities(mxResources.get("busy"))))}var v=n=null;null!=f&&null!=f.helpLink&&(n=mxResources.get("help"),v=mxUtils.bind(this,function(){return this.editor.graph.openLink(f.helpLink)}));this.showError(b,l,g,d,p,null,null,n,v,null,null,null,e?d:null)}else null!=d&&d()};EditorUi.prototype.alert=function(a,b){var c=new ErrorDialog(this,null,a,mxResources.get("ok"),b);this.showDialog(c.container,
+340,100,!0,!1);c.init()};EditorUi.prototype.confirm=function(a,b,d,e,m,n){var c=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},f=Math.min(200,28*Math.ceil(a.length/50));a=new ConfirmDialog(this,a,function(){c();null!=b&&b()},function(){c();null!=d&&d()},e,m,null,null,null,null,f);this.showDialog(a.container,340,46+f,!0,n);a.init()};EditorUi.prototype.showBanner=function(a,b,d){var c=!1;if(!(this.bannerShowing||this["hideBanner"+a]||isLocalStorage&&null!=mxSettings.settings&&
null!=mxSettings.settings["close"+a])){var f=document.createElement("div");f.style.cssText="position:absolute;bottom:10px;left:50%;max-width:90%;padding:18px 34px 12px 20px;font-size:16px;font-weight:bold;white-space:nowrap;cursor:pointer;z-index:"+mxPopupMenu.prototype.zIndex+";";mxUtils.setPrefixedStyle(f.style,"box-shadow","1px 1px 2px 0px #ddd");mxUtils.setPrefixedStyle(f.style,"transform","translate(-50%,120%)");mxUtils.setPrefixedStyle(f.style,"transition","all 1s ease");f.className="geBtn gePrimaryBtn";
c=document.createElement("img");c.setAttribute("src",IMAGE_PATH+"/logo.png");c.setAttribute("border","0");c.setAttribute("align","absmiddle");c.style.cssText="margin-top:-4px;margin-left:8px;margin-right:12px;width:26px;height:26px;";f.appendChild(c);c=document.createElement("img");c.setAttribute("src",Dialog.prototype.closeImage);c.setAttribute("title",mxResources.get("close"));c.setAttribute("border","0");c.style.cssText="position:absolute;right:10px;top:12px;filter:invert(1);padding:6px;margin:-6px;cursor:default;";
f.appendChild(c);mxUtils.write(f,b);document.body.appendChild(f);this.bannerShowing=!0;var e=document.createElement("div");e.style.cssText="font-size:11px;text-align:center;font-weight:normal;";var g=document.createElement("input");g.setAttribute("type","checkbox");g.setAttribute("id","geDoNotShowAgainCheckbox");g.style.marginRight="6px";e.appendChild(g);b=document.createElement("label");b.setAttribute("for","geDoNotShowAgainCheckbox");mxUtils.write(b,mxResources.get("doNotShowAgain"));e.appendChild(b);
-f.style.paddingBottom="30px";f.appendChild(e);var k=mxUtils.bind(this,function(c){null!=f.parentNode&&(f.parentNode.removeChild(f),this.bannerShowing=!1,g.checked&&(this["hideBanner"+a]=!0,isLocalStorage&&null!=mxSettings.settings&&(mxSettings.settings["close"+a]=Date.now(),mxSettings.save())))});mxEvent.addListener(c,"click",mxUtils.bind(this,function(a){mxEvent.consume(a);k()}));mxEvent.addListener(f,"click",mxUtils.bind(this,function(a){var c=mxEvent.getSource(a);c!=g&&c!=b&&(mxEvent.consume(a),
-d(),k())}));window.setTimeout(mxUtils.bind(this,function(){mxUtils.setPrefixedStyle(f.style,"transform","translate(-50%,0%)")}),500);window.setTimeout(mxUtils.bind(this,function(){mxUtils.setPrefixedStyle(f.style,"transform","translate(-50%,120%)");window.setTimeout(mxUtils.bind(this,function(){k(!0)}),1E3)}),3E4);c=!0}return c};EditorUi.prototype.setCurrentFile=function(a){null!=a&&(a.opened=new Date);this.currentFile=a};EditorUi.prototype.getCurrentFile=function(){return this.currentFile};EditorUi.prototype.isExportToCanvas=
-function(){return this.editor.isExportToCanvas()};EditorUi.prototype.createImageDataUri=function(a,b,d,e){var c=a.toDataURL("image/"+d);if(6>=c.length||c==a.cloneNode(!1).toDataURL("image/"+d))throw{message:"Invalid image"};null!=b&&(c=Editor.writeGraphModelToPng(c,"tEXt","mxfile",encodeURIComponent(b)));0<e&&(c=Editor.writeGraphModelToPng(c,"pHYs","dpi",e));return c};EditorUi.prototype.saveCanvas=function(a,b,d,e,l){var c="jpeg"==d?"jpg":d;e=this.getBaseFilename(e)+"."+c;a=this.createImageDataUri(a,
-b,d,l);this.saveData(e,c,a.substring(a.lastIndexOf(",")+1),"image/"+d,!0)};EditorUi.prototype.isLocalFileSave=function(){return"remote"!=urlParams.save&&(mxClient.IS_IE||"undefined"!==typeof window.Blob&&"undefined"!==typeof window.URL)&&9!=document.documentMode&&8!=document.documentMode&&7!=document.documentMode&&!mxClient.IS_QUIRKS||this.isOfflineApp()||mxClient.IS_IOS};EditorUi.prototype.showTextDialog=function(a,b){var c=new TextareaDialog(this,a,b,null,null,mxResources.get("close"));c.textarea.style.width=
-"600px";c.textarea.style.height="380px";this.showDialog(c.container,620,460,!0,!0,null,null,null,null,!0);c.init();document.execCommand("selectall",!1,null)};EditorUi.prototype.doSaveLocalFile=function(a,b,d,e,l){"text/xml"!=d||/(\.drawio)$/i.test(b)||/(\.xml)$/i.test(b)||(b+=".drawio");if(window.Blob&&navigator.msSaveOrOpenBlob)a=e?this.base64ToBlob(a,d):new Blob([a],{type:d}),navigator.msSaveOrOpenBlob(a,b);else if(mxClient.IS_IE)d=window.open("about:blank","_blank"),null==d?mxUtils.popup(a,!0):
+f.style.paddingBottom="30px";f.appendChild(e);var l=mxUtils.bind(this,function(c){null!=f.parentNode&&(f.parentNode.removeChild(f),this.bannerShowing=!1,g.checked&&(this["hideBanner"+a]=!0,isLocalStorage&&null!=mxSettings.settings&&(mxSettings.settings["close"+a]=Date.now(),mxSettings.save())))});mxEvent.addListener(c,"click",mxUtils.bind(this,function(a){mxEvent.consume(a);l()}));mxEvent.addListener(f,"click",mxUtils.bind(this,function(a){var c=mxEvent.getSource(a);c!=g&&c!=b&&(mxEvent.consume(a),
+d(),l())}));window.setTimeout(mxUtils.bind(this,function(){mxUtils.setPrefixedStyle(f.style,"transform","translate(-50%,0%)")}),500);window.setTimeout(mxUtils.bind(this,function(){mxUtils.setPrefixedStyle(f.style,"transform","translate(-50%,120%)");window.setTimeout(mxUtils.bind(this,function(){l(!0)}),1E3)}),3E4);c=!0}return c};EditorUi.prototype.setCurrentFile=function(a){null!=a&&(a.opened=new Date);this.currentFile=a};EditorUi.prototype.getCurrentFile=function(){return this.currentFile};EditorUi.prototype.isExportToCanvas=
+function(){return this.editor.isExportToCanvas()};EditorUi.prototype.createImageDataUri=function(a,b,d,e){var c=a.toDataURL("image/"+d);if(6>=c.length||c==a.cloneNode(!1).toDataURL("image/"+d))throw{message:"Invalid image"};null!=b&&(c=Editor.writeGraphModelToPng(c,"tEXt","mxfile",encodeURIComponent(b)));0<e&&(c=Editor.writeGraphModelToPng(c,"pHYs","dpi",e));return c};EditorUi.prototype.saveCanvas=function(a,b,d,e,m){var c="jpeg"==d?"jpg":d;e=this.getBaseFilename(e)+"."+c;a=this.createImageDataUri(a,
+b,d,m);this.saveData(e,c,a.substring(a.lastIndexOf(",")+1),"image/"+d,!0)};EditorUi.prototype.isLocalFileSave=function(){return"remote"!=urlParams.save&&(mxClient.IS_IE||"undefined"!==typeof window.Blob&&"undefined"!==typeof window.URL)&&9!=document.documentMode&&8!=document.documentMode&&7!=document.documentMode&&!mxClient.IS_QUIRKS||this.isOfflineApp()||mxClient.IS_IOS};EditorUi.prototype.showTextDialog=function(a,b){var c=new TextareaDialog(this,a,b,null,null,mxResources.get("close"));c.textarea.style.width=
+"600px";c.textarea.style.height="380px";this.showDialog(c.container,620,460,!0,!0,null,null,null,null,!0);c.init();document.execCommand("selectall",!1,null)};EditorUi.prototype.doSaveLocalFile=function(a,b,d,e,m){"text/xml"!=d||/(\.drawio)$/i.test(b)||/(\.xml)$/i.test(b)||(b+=".drawio");if(window.Blob&&navigator.msSaveOrOpenBlob)a=e?this.base64ToBlob(a,d):new Blob([a],{type:d}),navigator.msSaveOrOpenBlob(a,b);else if(mxClient.IS_IE)d=window.open("about:blank","_blank"),null==d?mxUtils.popup(a,!0):
(d.document.write(a),d.document.close(),d.document.execCommand("SaveAs",!0,b),d.close());else if(mxClient.IS_IOS&&this.isOffline())navigator.standalone||null==d||"image/"!=d.substring(0,6)?this.showTextDialog(b+":",a):this.openInNewWindow(a,d,e);else{var c=document.createElement("a"),f=(null==navigator.userAgent||0>navigator.userAgent.indexOf("PaleMoon/"))&&!mxClient.IS_IOS&&"undefined"!==typeof c.download;if(mxClient.IS_GC&&null!=navigator.userAgent)var g=navigator.userAgent.match(/Chrom(e|ium)\/([0-9]+)\./),
-f=65==(g?parseInt(g[2],10):!1)?!1:f;if(f||this.isOffline()){c.href=URL.createObjectURL(e?this.base64ToBlob(a,d):new Blob([a],{type:d}));f?c.download=b:c.setAttribute("target","_blank");document.body.appendChild(c);try{window.setTimeout(function(){URL.revokeObjectURL(c.href)},0),c.click(),c.parentNode.removeChild(c)}catch(u){}}else this.createEchoRequest(a,b,d,e,l).simulate(document,"_blank")}};EditorUi.prototype.createEchoRequest=function(a,b,d,e,l,n){a="xml="+encodeURIComponent(a);return new mxXmlRequest(SAVE_URL,
-a+(null!=d?"&mime="+d:"")+(null!=l?"&format="+l:"")+(null!=n?"&base64="+n:"")+(null!=b?"&filename="+encodeURIComponent(b):"")+(e?"&binary=1":""))};EditorUi.prototype.base64ToBlob=function(a,b){b=b||"";for(var c=atob(a),d=c.length,f=Math.ceil(d/1024),e=Array(f),k=0;k<f;++k){for(var m=1024*k,u=Math.min(m+1024,d),q=Array(u-m),B=0;m<u;++B,++m)q[B]=c[m].charCodeAt(0);e[k]=new Uint8Array(q)}return new Blob(e,{type:b})};EditorUi.prototype.saveLocalFile=function(a,b,d,e,l,n,k){n=null!=n?n:!1;k=null!=k?k:
-"vsdx"!=l&&(!mxClient.IS_IOS||!navigator.standalone);l=this.getServiceCount(n);isLocalStorage&&l++;var c=4>=l?2:6<l?4:3;b=new CreateDialog(this,b,mxUtils.bind(this,function(c,b){try{if("_blank"==b)if(null!=d&&"image/"==d.substring(0,6))this.openInNewWindow(a,d,e);else{var f=window.open("about:blank");null==f?mxUtils.popup(a,!0):(f.document.write("<pre>"+mxUtils.htmlEntities(a,!1)+"</pre>"),f.document.close())}else b==App.MODE_DEVICE||"download"==b?this.doSaveLocalFile(a,c,d,e):null!=c&&0<c.length&&
-this.pickFolder(b,mxUtils.bind(this,function(f){try{this.exportFile(a,c,d,e,b,f)}catch(C){this.handleError(C)}}))}catch(D){this.handleError(D)}}),mxUtils.bind(this,function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,n,k,null,1<l,c,a,d,e);n=this.isServices(l)?l>c?390:270:160;this.showDialog(b.container,400,n,!0,!0);b.init()};EditorUi.prototype.openInNewWindow=function(a,b,d){var c=window.open("about:blank");null==c||null==c.document?mxUtils.popup(a,!0):("image/svg+xml"!=
+f=65==(g?parseInt(g[2],10):!1)?!1:f;if(f||this.isOffline()){c.href=URL.createObjectURL(e?this.base64ToBlob(a,d):new Blob([a],{type:d}));f?c.download=b:c.setAttribute("target","_blank");document.body.appendChild(c);try{window.setTimeout(function(){URL.revokeObjectURL(c.href)},0),c.click(),c.parentNode.removeChild(c)}catch(u){}}else this.createEchoRequest(a,b,d,e,m).simulate(document,"_blank")}};EditorUi.prototype.createEchoRequest=function(a,b,d,e,m,n){a="xml="+encodeURIComponent(a);return new mxXmlRequest(SAVE_URL,
+a+(null!=d?"&mime="+d:"")+(null!=m?"&format="+m:"")+(null!=n?"&base64="+n:"")+(null!=b?"&filename="+encodeURIComponent(b):"")+(e?"&binary=1":""))};EditorUi.prototype.base64ToBlob=function(a,b){b=b||"";for(var c=atob(a),d=c.length,f=Math.ceil(d/1024),e=Array(f),l=0;l<f;++l){for(var k=1024*l,u=Math.min(k+1024,d),q=Array(u-k),B=0;k<u;++B,++k)q[B]=c[k].charCodeAt(0);e[l]=new Uint8Array(q)}return new Blob(e,{type:b})};EditorUi.prototype.saveLocalFile=function(a,b,d,e,m,n,l){n=null!=n?n:!1;l=null!=l?l:
+"vsdx"!=m&&(!mxClient.IS_IOS||!navigator.standalone);m=this.getServiceCount(n);isLocalStorage&&m++;var c=4>=m?2:6<m?4:3;b=new CreateDialog(this,b,mxUtils.bind(this,function(c,b){try{if("_blank"==b)if(null!=d&&"image/"==d.substring(0,6))this.openInNewWindow(a,d,e);else{var f=window.open("about:blank");null==f?mxUtils.popup(a,!0):(f.document.write("<pre>"+mxUtils.htmlEntities(a,!1)+"</pre>"),f.document.close())}else b==App.MODE_DEVICE||"download"==b?this.doSaveLocalFile(a,c,d,e):null!=c&&0<c.length&&
+this.pickFolder(b,mxUtils.bind(this,function(f){try{this.exportFile(a,c,d,e,b,f)}catch(C){this.handleError(C)}}))}catch(D){this.handleError(D)}}),mxUtils.bind(this,function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,n,l,null,1<m,c,a,d,e);n=this.isServices(m)?m>c?390:270:160;this.showDialog(b.container,400,n,!0,!0);b.init()};EditorUi.prototype.openInNewWindow=function(a,b,d){var c=window.open("about:blank");null==c||null==c.document?mxUtils.popup(a,!0):("image/svg+xml"!=
b||mxClient.IS_SVG?"image/svg+xml"==b?c.document.write("<html>"+a+"</html>"):(a=d?a:btoa(unescape(encodeURIComponent(a))),c.document.write('<html><img style="max-width:100%;" src="data:'+b+";base64,"+a+'"/></html>')):c.document.write("<html><pre>"+mxUtils.htmlEntities(a,!1)+"</pre></html>"),c.document.close())};var e=EditorUi.prototype.addChromelessToolbarItems;EditorUi.prototype.addChromelessToolbarItems=function(a){if(this.isExportToCanvas()){this.exportDialog=null;var c=a(mxUtils.bind(this,function(a){var b=
mxUtils.bind(this,function(){mxEvent.removeListener(this.editor.graph.container,"click",b);null!=this.exportDialog&&(this.exportDialog.parentNode.removeChild(this.exportDialog),this.exportDialog=null)});if(null!=this.exportDialog)b.apply(this);else{this.exportDialog=document.createElement("div");var d=c.getBoundingClientRect();mxUtils.setPrefixedStyle(this.exportDialog.style,"borderRadius","5px");this.exportDialog.style.position="fixed";this.exportDialog.style.textAlign="center";this.exportDialog.style.fontFamily=
"Helvetica,Arial";this.exportDialog.style.backgroundColor="#000000";this.exportDialog.style.width="50px";this.exportDialog.style.height="50px";this.exportDialog.style.padding="4px 2px 4px 2px";this.exportDialog.style.color="#ffffff";mxUtils.setOpacity(this.exportDialog,70);this.exportDialog.style.left=d.left+"px";this.exportDialog.style.bottom=parseInt(this.chromelessToolbar.style.bottom)+this.chromelessToolbar.offsetHeight+4+"px";d=mxUtils.getCurrentStyle(this.editor.graph.container);this.exportDialog.style.zIndex=
d.zIndex;var f=new Spinner({lines:8,length:6,width:5,radius:6,rotate:0,color:"#fff",speed:1.5,trail:60,shadow:!1,hwaccel:!1,top:"28px",zIndex:2E9});f.spin(this.exportDialog);this.editor.exportToCanvas(mxUtils.bind(this,function(a){f.stop();this.exportDialog.style.width="auto";this.exportDialog.style.height="auto";this.exportDialog.style.padding="10px";var c=this.createImageDataUri(a,null,"png");a=document.createElement("img");a.style.maxWidth="140px";a.style.maxHeight="140px";a.style.cursor="pointer";
a.style.backgroundColor="white";a.setAttribute("title",mxResources.get("openInNewWindow"));a.setAttribute("border","0");a.setAttribute("src",c);this.exportDialog.appendChild(a);mxEvent.addListener(a,"click",mxUtils.bind(this,function(){this.openInNewWindow(c.substring(c.indexOf(",")+1),"image/png",!0);b.apply(this,arguments)}))}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a)}));mxEvent.addListener(this.editor.graph.container,"click",b);document.body.appendChild(this.exportDialog)}mxEvent.consume(a)}),
-Editor.cameraLargeImage,mxResources.get("export"))}e.apply(this,arguments)};EditorUi.prototype.saveData=function(a,b,d,e,l){this.isLocalFileSave()?this.saveLocalFile(d,a,e,l,b):this.saveRequest(a,b,mxUtils.bind(this,function(a,c){return this.createEchoRequest(d,a,e,l,b,c)}),d,l,e)};EditorUi.prototype.saveRequest=function(a,b,d,e,l,n,k){k=null!=k?k:!mxClient.IS_IOS||!navigator.standalone;var c=this.getServiceCount(!1);isLocalStorage&&c++;var f=4>=c?2:6<c?4:3;a=new CreateDialog(this,a,mxUtils.bind(this,
+Editor.cameraLargeImage,mxResources.get("export"))}e.apply(this,arguments)};EditorUi.prototype.saveData=function(a,b,d,e,m){this.isLocalFileSave()?this.saveLocalFile(d,a,e,m,b):this.saveRequest(a,b,mxUtils.bind(this,function(a,c){return this.createEchoRequest(d,a,e,m,b,c)}),d,m,e)};EditorUi.prototype.saveRequest=function(a,b,d,e,m,n,l){l=null!=l?l:!mxClient.IS_IOS||!navigator.standalone;var c=this.getServiceCount(!1);isLocalStorage&&c++;var f=4>=c?2:6<c?4:3;a=new CreateDialog(this,a,mxUtils.bind(this,
function(a,c){if("_blank"==c||null!=a&&0<a.length){var f=d("_blank"==c?null:a,c==App.MODE_DEVICE||"download"==c||null==c||"_blank"==c?"0":"1");null!=f&&(c==App.MODE_DEVICE||"download"==c||"_blank"==c?f.simulate(document,"_blank"):this.pickFolder(c,mxUtils.bind(this,function(d){n=null!=n?n:"pdf"==b?"application/pdf":"image/"+b;if(null!=e)try{this.exportFile(e,a,n,!0,c,d)}catch(x){this.handleError(x)}else this.spinner.spin(document.body,mxResources.get("saving"))&&f.send(mxUtils.bind(this,function(){this.spinner.stop();
-if(200<=f.getStatus()&&299>=f.getStatus())try{this.exportFile(f.getText(),a,n,!0,c,d)}catch(x){this.handleError(x)}else this.handleError({message:mxResources.get("errorSavingFile")})}),function(a){this.spinner.stop();this.handleError(a)})})))}}),mxUtils.bind(this,function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,!1,k,null,1<c,f,e,n,l);c=this.isServices(c)?4<c?390:270:160;this.showDialog(a.container,380,c,!0,!0);a.init()};EditorUi.prototype.isServices=function(a){return 1!=
-a};EditorUi.prototype.getEditBlankXml=function(){return this.getFileData(!0)};EditorUi.prototype.exportFile=function(a,b,d,e,l,n){};EditorUi.prototype.pickFolder=function(a,b,d){b(null)};EditorUi.prototype.exportSvg=function(a,b,d,e,l,n,k,m,u,q){if(this.spinner.spin(document.body,mxResources.get("export")))try{var c=this.editor.graph.isSelectionEmpty();d=null!=d?d:c;var f=b?null:this.editor.graph.background;f==mxConstants.NONE&&(f=null);null==f&&0==b&&(f="#ffffff");var g=this.editor.graph.getSvg(f,
-a,k,m,null,d,null,null,"blank"==q?"_blank":"self"==q?"_top":null,null,!0);e&&this.editor.graph.addSvgShadow(g);var p=this.getBaseFilename()+".svg",t=mxUtils.bind(this,function(a){this.spinner.stop();l&&a.setAttribute("content",this.getFileData(!0,null,null,null,d,u,null,null,null,!1));var c='<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n'+mxUtils.getXml(a);this.isLocalFileSave()||c.length<=MAX_REQUEST_SIZE?
-this.saveData(p,"svg",c,"image/svg+xml"):this.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(c)}))});this.editor.addFontCss(g);this.editor.graph.mathEnabled&&this.editor.addMathCss(g);n?(null==this.thumbImageCache&&(this.thumbImageCache={}),this.editor.convertImages(g,t,this.thumbImageCache)):t(g)}catch(G){this.handleError(G)}};EditorUi.prototype.addRadiobox=function(a,b,d,e,l,n,k){return this.addCheckbox(a,d,e,l,n,k,!0,
-b)};EditorUi.prototype.addCheckbox=function(a,b,d,e,l,n,k,m){n=null!=n?n:!0;var c=document.createElement("input");c.style.marginRight="8px";c.style.marginTop="16px";c.setAttribute("type",k?"radio":"checkbox");k="geCheckbox-"+Editor.guid();c.id=k;null!=m&&c.setAttribute("name",m);d&&(c.setAttribute("checked","checked"),c.defaultChecked=!0);e&&c.setAttribute("disabled","disabled");n&&(a.appendChild(c),d=document.createElement("label"),mxUtils.write(d,b),d.setAttribute("for",k),a.appendChild(d),l||mxUtils.br(a));
+if(200<=f.getStatus()&&299>=f.getStatus())try{this.exportFile(f.getText(),a,n,!0,c,d)}catch(x){this.handleError(x)}else this.handleError({message:mxResources.get("errorSavingFile")})}),function(a){this.spinner.stop();this.handleError(a)})})))}}),mxUtils.bind(this,function(){this.hideDialog()}),mxResources.get("saveAs"),mxResources.get("download"),!1,!1,l,null,1<c,f,e,n,m);c=this.isServices(c)?4<c?390:270:160;this.showDialog(a.container,380,c,!0,!0);a.init()};EditorUi.prototype.isServices=function(a){return 1!=
+a};EditorUi.prototype.getEditBlankXml=function(){return this.getFileData(!0)};EditorUi.prototype.exportFile=function(a,b,d,e,m,n){};EditorUi.prototype.pickFolder=function(a,b,d){b(null)};EditorUi.prototype.exportSvg=function(a,b,d,e,m,n,l,k,u,q){if(this.spinner.spin(document.body,mxResources.get("export")))try{var c=this.editor.graph.isSelectionEmpty();d=null!=d?d:c;var f=b?null:this.editor.graph.background;f==mxConstants.NONE&&(f=null);null==f&&0==b&&(f="#ffffff");var g=this.editor.graph.getSvg(f,
+a,l,k,null,d,null,null,"blank"==q?"_blank":"self"==q?"_top":null,null,!0);e&&this.editor.graph.addSvgShadow(g);var p=this.getBaseFilename()+".svg",t=mxUtils.bind(this,function(a){this.spinner.stop();m&&a.setAttribute("content",this.getFileData(!0,null,null,null,d,u,null,null,null,!1));var c='<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n'+mxUtils.getXml(a);this.isLocalFileSave()||c.length<=MAX_REQUEST_SIZE?
+this.saveData(p,"svg",c,"image/svg+xml"):this.handleError({message:mxResources.get("drawingTooLarge")},mxResources.get("error"),mxUtils.bind(this,function(){mxUtils.popup(c)}))});this.editor.addFontCss(g);this.editor.graph.mathEnabled&&this.editor.addMathCss(g);n?(null==this.thumbImageCache&&(this.thumbImageCache={}),this.editor.convertImages(g,t,this.thumbImageCache)):t(g)}catch(G){this.handleError(G)}};EditorUi.prototype.addRadiobox=function(a,b,d,e,m,n,l){return this.addCheckbox(a,d,e,m,n,l,!0,
+b)};EditorUi.prototype.addCheckbox=function(a,b,d,e,m,n,l,k){n=null!=n?n:!0;var c=document.createElement("input");c.style.marginRight="8px";c.style.marginTop="16px";c.setAttribute("type",l?"radio":"checkbox");l="geCheckbox-"+Editor.guid();c.id=l;null!=k&&c.setAttribute("name",k);d&&(c.setAttribute("checked","checked"),c.defaultChecked=!0);e&&c.setAttribute("disabled","disabled");n&&(a.appendChild(c),d=document.createElement("label"),mxUtils.write(d,b),d.setAttribute("for",l),a.appendChild(d),m||mxUtils.br(a));
return c};EditorUi.prototype.addEditButton=function(a,b){var c=this.addCheckbox(a,mxResources.get("edit")+":",!0,null,!0);c.style.marginLeft="24px";var d=this.getCurrentFile(),f="";null!=d&&d.getMode()!=App.MODE_DEVICE&&d.getMode()!=App.MODE_BROWSER&&(f=window.location.href);var e=document.createElement("select");e.style.width="120px";e.style.marginLeft="8px";e.style.marginRight="10px";e.className="geBtn";d=document.createElement("option");d.setAttribute("value","blank");mxUtils.write(d,mxResources.get("makeCopy"));
e.appendChild(d);d=document.createElement("option");d.setAttribute("value","custom");mxUtils.write(d,mxResources.get("custom")+"...");e.appendChild(d);a.appendChild(e);mxEvent.addListener(e,"change",mxUtils.bind(this,function(){if("custom"==e.value){var a=new FilenameDialog(this,f,mxResources.get("ok"),function(a){null!=a?f=a:e.value="blank"},mxResources.get("url"),null,null,null,null,function(){e.value="blank"});this.showDialog(a.container,300,80,!0,!1);a.init()}}));mxEvent.addListener(c,"change",
-mxUtils.bind(this,function(){c.checked&&(null==b||b.checked)?e.removeAttribute("disabled"):e.setAttribute("disabled","disabled")}));mxUtils.br(a);return{getLink:function(){return c.checked?"blank"===e.value?"_blank":f:null},getEditInput:function(){return c},getEditSelect:function(){return e}}};EditorUi.prototype.addLinkSection=function(a,b){function c(){k.innerHTML='<div style="width:100%;height:100%;box-sizing:border-box;'+(null!=e&&e!=mxConstants.NONE?"border:1px solid black;background-color:"+
+mxUtils.bind(this,function(){c.checked&&(null==b||b.checked)?e.removeAttribute("disabled"):e.setAttribute("disabled","disabled")}));mxUtils.br(a);return{getLink:function(){return c.checked?"blank"===e.value?"_blank":f:null},getEditInput:function(){return c},getEditSelect:function(){return e}}};EditorUi.prototype.addLinkSection=function(a,b){function c(){l.innerHTML='<div style="width:100%;height:100%;box-sizing:border-box;'+(null!=e&&e!=mxConstants.NONE?"border:1px solid black;background-color:"+
e:"background-position:center center;background-repeat:no-repeat;background-image:url('"+Dialog.prototype.closeImage+"')")+';"></div>'}mxUtils.write(a,mxResources.get("links")+":");var d=document.createElement("select");d.style.width="100px";d.style.marginLeft="8px";d.style.marginRight="10px";d.className="geBtn";var f=document.createElement("option");f.setAttribute("value","auto");mxUtils.write(f,mxResources.get("automatic"));d.appendChild(f);f=document.createElement("option");f.setAttribute("value",
-"blank");mxUtils.write(f,mxResources.get("openInNewWindow"));d.appendChild(f);f=document.createElement("option");f.setAttribute("value","self");mxUtils.write(f,mxResources.get("openInThisWindow"));d.appendChild(f);b&&(f=document.createElement("option"),f.setAttribute("value","frame"),mxUtils.write(f,mxResources.get("openInThisWindow")+" ("+mxResources.get("iframe")+")"),d.appendChild(f));a.appendChild(d);mxUtils.write(a,mxResources.get("borderColor")+":");var e="#0000ff",k=null,k=mxUtils.button("",
-mxUtils.bind(this,function(a){this.pickColor(e||"none",function(a){e=a;c()});mxEvent.consume(a)}));c();k.style.padding=mxClient.IS_FF?"4px 2px 4px 2px":"4px";k.style.marginLeft="4px";k.style.height="22px";k.style.width="22px";k.style.position="relative";k.style.top=mxClient.IS_IE||mxClient.IS_IE11||mxClient.IS_EDGE?"6px":"1px";k.className="geColorBtn";a.appendChild(k);mxUtils.br(a);return{getColor:function(){return e},getTarget:function(){return d.value},focus:function(){d.focus()}}};EditorUi.prototype.createLink=
-function(a,b,d,e,l,n,k,m){var c=this.getCurrentFile(),f=[];e&&(f.push("lightbox=1"),"auto"!=a&&f.push("target="+a),null!=b&&b!=mxConstants.NONE&&f.push("highlight="+("#"==b.charAt(0)?b.substring(1):b)),null!=l&&0<l.length&&f.push("edit="+encodeURIComponent(l)),n&&f.push("layers=1"),this.editor.graph.foldingEnabled&&f.push("nav=1"));d&&null!=this.currentPage&&null!=this.pages&&this.currentPage!=this.pages[0]&&f.push("page-id="+this.currentPage.getId());a=!0;null!=k?d="#U"+encodeURIComponent(k):(c=
-this.getCurrentFile(),m||null==c||c.constructor!=window.DriveFile?d="#R"+encodeURIComponent(d?this.getFileData(!0,null,null,null,null,null,null,!0,null,!1):Graph.compress(mxUtils.getXml(this.editor.getGraphXml()))):(d="#"+c.getHash(),a=!1));a&&null!=c&&null!=c.getTitle()&&c.getTitle()!=this.defaultFilename&&f.push("title="+encodeURIComponent(c.getTitle()));return(mxClient.IS_CHROMEAPP||EditorUi.isElectronApp||!/.*\.draw\.io$/.test(window.location.hostname)?EditorUi.drawHost:"https://"+window.location.host)+
-"/"+(0<f.length?"?"+f.join("&"):"")+d};EditorUi.prototype.createHtml=function(a,b,d,e,l,n,k,m,u,q,B){this.getBasenames();var c={};""!=l&&l!=mxConstants.NONE&&(c.highlight=l);"auto"!==e&&(c.target=e);u||(c.lightbox=!1);c.nav=this.editor.graph.foldingEnabled;d=parseInt(d);isNaN(d)||100==d||(c.zoom=d/100);d=[];k&&(d.push("pages"),c.resize=!0,null!=this.pages&&null!=this.currentPage&&(c.page=mxUtils.indexOf(this.pages,this.currentPage)));b&&(d.push("zoom"),c.resize=!0);m&&d.push("layers");0<d.length&&
-(u&&d.push("lightbox"),c.toolbar=d.join(" "));null!=q&&0<q.length&&(c.edit=q);null!=a?c.url=a:c.xml=this.getFileData(!0,null,null,null,null,!k);b='<div class="mxgraph" style="'+(n?"max-width:100%;":"")+(""!=d?"border:1px solid transparent;":"")+'" data-mxgraph="'+mxUtils.htmlEntities(JSON.stringify(c))+'"></div>';a=null!=a?"&fetch="+encodeURIComponent(a):"";B(b,'<script type="text/javascript" src="'+(0<a.length?("1"==urlParams.dev?"https://test.draw.io/embed2.js?dev=1":EditorUi.drawHost+"/embed2.js?")+
+"blank");mxUtils.write(f,mxResources.get("openInNewWindow"));d.appendChild(f);f=document.createElement("option");f.setAttribute("value","self");mxUtils.write(f,mxResources.get("openInThisWindow"));d.appendChild(f);b&&(f=document.createElement("option"),f.setAttribute("value","frame"),mxUtils.write(f,mxResources.get("openInThisWindow")+" ("+mxResources.get("iframe")+")"),d.appendChild(f));a.appendChild(d);mxUtils.write(a,mxResources.get("borderColor")+":");var e="#0000ff",l=null,l=mxUtils.button("",
+mxUtils.bind(this,function(a){this.pickColor(e||"none",function(a){e=a;c()});mxEvent.consume(a)}));c();l.style.padding=mxClient.IS_FF?"4px 2px 4px 2px":"4px";l.style.marginLeft="4px";l.style.height="22px";l.style.width="22px";l.style.position="relative";l.style.top=mxClient.IS_IE||mxClient.IS_IE11||mxClient.IS_EDGE?"6px":"1px";l.className="geColorBtn";a.appendChild(l);mxUtils.br(a);return{getColor:function(){return e},getTarget:function(){return d.value},focus:function(){d.focus()}}};EditorUi.prototype.createLink=
+function(a,b,d,e,m,n,l,k){var c=this.getCurrentFile(),f=[];e&&(f.push("lightbox=1"),"auto"!=a&&f.push("target="+a),null!=b&&b!=mxConstants.NONE&&f.push("highlight="+("#"==b.charAt(0)?b.substring(1):b)),null!=m&&0<m.length&&f.push("edit="+encodeURIComponent(m)),n&&f.push("layers=1"),this.editor.graph.foldingEnabled&&f.push("nav=1"));d&&null!=this.currentPage&&null!=this.pages&&this.currentPage!=this.pages[0]&&f.push("page-id="+this.currentPage.getId());a=!0;null!=l?d="#U"+encodeURIComponent(l):(c=
+this.getCurrentFile(),k||null==c||c.constructor!=window.DriveFile?d="#R"+encodeURIComponent(d?this.getFileData(!0,null,null,null,null,null,null,!0,null,!1):Graph.compress(mxUtils.getXml(this.editor.getGraphXml()))):(d="#"+c.getHash(),a=!1));a&&null!=c&&null!=c.getTitle()&&c.getTitle()!=this.defaultFilename&&f.push("title="+encodeURIComponent(c.getTitle()));return(mxClient.IS_CHROMEAPP||EditorUi.isElectronApp||!/.*\.draw\.io$/.test(window.location.hostname)?EditorUi.drawHost:"https://"+window.location.host)+
+"/"+(0<f.length?"?"+f.join("&"):"")+d};EditorUi.prototype.createHtml=function(a,b,d,e,m,n,l,k,u,q,B){this.getBasenames();var c={};""!=m&&m!=mxConstants.NONE&&(c.highlight=m);"auto"!==e&&(c.target=e);u||(c.lightbox=!1);c.nav=this.editor.graph.foldingEnabled;d=parseInt(d);isNaN(d)||100==d||(c.zoom=d/100);d=[];l&&(d.push("pages"),c.resize=!0,null!=this.pages&&null!=this.currentPage&&(c.page=mxUtils.indexOf(this.pages,this.currentPage)));b&&(d.push("zoom"),c.resize=!0);k&&d.push("layers");0<d.length&&
+(u&&d.push("lightbox"),c.toolbar=d.join(" "));null!=q&&0<q.length&&(c.edit=q);null!=a?c.url=a:c.xml=this.getFileData(!0,null,null,null,null,!l);b='<div class="mxgraph" style="'+(n?"max-width:100%;":"")+(""!=d?"border:1px solid transparent;":"")+'" data-mxgraph="'+mxUtils.htmlEntities(JSON.stringify(c))+'"></div>';a=null!=a?"&fetch="+encodeURIComponent(a):"";B(b,'<script type="text/javascript" src="'+(0<a.length?("1"==urlParams.dev?"https://test.draw.io/embed2.js?dev=1":EditorUi.drawHost+"/embed2.js?")+
a:"1"==urlParams.dev?"https://test.draw.io/js/viewer.min.js":window.VIEWER_URL?window.VIEWER_URL:EditorUi.drawHost+"/js/viewer.min.js")+'">\x3c/script>')};EditorUi.prototype.showHtmlDialog=function(a,b,d,e){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=document.createElement("h3");mxUtils.write(f,mxResources.get("html"));f.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:12px";c.appendChild(f);var g=document.createElement("div");g.style.cssText="border-bottom:1px solid lightGray;padding-bottom:8px;margin-bottom:12px;";
-var p=document.createElement("input");p.style.cssText="margin-right:8px;margin-top:8px;margin-bottom:8px;";p.setAttribute("value","url");p.setAttribute("type","radio");p.setAttribute("name","type-embedhtmldialog");f=p.cloneNode(!0);f.setAttribute("value","copy");g.appendChild(f);var u=document.createElement("span");mxUtils.write(u,mxResources.get("includeCopyOfMyDiagram"));g.appendChild(u);mxUtils.br(g);g.appendChild(p);u=document.createElement("span");mxUtils.write(u,mxResources.get("publicDiagramUrl"));
-g.appendChild(u);var k=this.getCurrentFile();null==d&&null!=k&&k.constructor==window.DriveFile&&(u=document.createElement("a"),u.style.paddingLeft="12px",u.style.color="gray",u.setAttribute("href","javascript:void(0);"),mxUtils.write(u,mxResources.get("share")),g.appendChild(u),mxEvent.addListener(u,"click",mxUtils.bind(this,function(){this.hideDialog();this.drive.showPermissions(k.getId())})));f.setAttribute("checked","checked");null==d&&p.setAttribute("disabled","disabled");c.appendChild(g);var m=
-this.addLinkSection(c),q=this.addCheckbox(c,mxResources.get("zoom"),!0,null,!0);mxUtils.write(c,":");var C=document.createElement("input");C.setAttribute("type","text");C.style.marginRight="16px";C.style.width="60px";C.style.marginLeft="4px";C.style.marginRight="12px";C.value="100%";c.appendChild(C);var x=this.addCheckbox(c,mxResources.get("fit"),!0),g=null!=this.pages&&1<this.pages.length,F=F=this.addCheckbox(c,mxResources.get("allPages"),g,!g),G=this.addCheckbox(c,mxResources.get("layers"),!0),
-E=this.addCheckbox(c,mxResources.get("lightbox"),!0),J=this.addEditButton(c,E),H=J.getEditInput();H.style.marginBottom="16px";mxEvent.addListener(E,"change",function(){E.checked?H.removeAttribute("disabled"):H.setAttribute("disabled","disabled");H.checked&&E.checked?J.getEditSelect().removeAttribute("disabled"):J.getEditSelect().setAttribute("disabled","disabled")});a=new CustomDialog(this,c,mxUtils.bind(this,function(){e(p.checked?d:null,q.checked,C.value,m.getTarget(),m.getColor(),x.checked,F.checked,
-G.checked,E.checked,J.getLink())}),null,a,b);this.showDialog(a.container,340,384,!0,!0);f.focus()};EditorUi.prototype.showPublishLinkDialog=function(a,b,d,e,l,n){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=document.createElement("h3");mxUtils.write(f,a||mxResources.get("link"));f.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:12px";c.appendChild(f);var g=this.getCurrentFile(),f="https://desk.draw.io/support/solutions/articles/16000051941";a=0;if(null!=
-g&&g.constructor==window.DriveFile&&!b){a=80;var f="https://desk.draw.io/support/solutions/articles/16000039384",p=document.createElement("div");p.style.cssText="border-bottom:1px solid lightGray;padding-bottom:14px;padding-top:6px;margin-bottom:14px;text-align:center;";var k=document.createElement("div");k.style.whiteSpace="normal";mxUtils.write(k,mxResources.get("linkAccountRequired"));p.appendChild(k);k=mxUtils.button(mxResources.get("share"),mxUtils.bind(this,function(){this.drive.showPermissions(g.getId())}));
-k.style.marginTop="12px";k.className="geBtn";p.appendChild(k);c.appendChild(p);k=document.createElement("a");k.style.paddingLeft="12px";k.style.color="gray";k.style.fontSize="11px";k.setAttribute("href","javascript:void(0);");mxUtils.write(k,mxResources.get("check"));p.appendChild(k);mxEvent.addListener(k,"click",mxUtils.bind(this,function(){this.spinner.spin(document.body,mxResources.get("loading"))&&this.getPublicUrl(this.getCurrentFile(),mxUtils.bind(this,function(a){this.spinner.stop();a=new ErrorDialog(this,
-null,mxResources.get(null!=a?"diagramIsPublic":"diagramIsNotPublic"),mxResources.get("ok"));this.showDialog(a.container,300,80,!0,!1);a.init()}))}))}var m=null,q=null;if(null!=d||null!=e)a+=30,mxUtils.write(c,mxResources.get("width")+":"),m=document.createElement("input"),m.setAttribute("type","text"),m.style.marginRight="16px",m.style.width="50px",m.style.marginLeft="6px",m.style.marginRight="16px",m.style.marginBottom="10px",m.value="100%",c.appendChild(m),mxUtils.write(c,mxResources.get("height")+
+var p=document.createElement("input");p.style.cssText="margin-right:8px;margin-top:8px;margin-bottom:8px;";p.setAttribute("value","url");p.setAttribute("type","radio");p.setAttribute("name","type-embedhtmldialog");f=p.cloneNode(!0);f.setAttribute("value","copy");g.appendChild(f);var l=document.createElement("span");mxUtils.write(l,mxResources.get("includeCopyOfMyDiagram"));g.appendChild(l);mxUtils.br(g);g.appendChild(p);l=document.createElement("span");mxUtils.write(l,mxResources.get("publicDiagramUrl"));
+g.appendChild(l);var k=this.getCurrentFile();null==d&&null!=k&&k.constructor==window.DriveFile&&(l=document.createElement("a"),l.style.paddingLeft="12px",l.style.color="gray",l.setAttribute("href","javascript:void(0);"),mxUtils.write(l,mxResources.get("share")),g.appendChild(l),mxEvent.addListener(l,"click",mxUtils.bind(this,function(){this.hideDialog();this.drive.showPermissions(k.getId())})));f.setAttribute("checked","checked");null==d&&p.setAttribute("disabled","disabled");c.appendChild(g);var q=
+this.addLinkSection(c),D=this.addCheckbox(c,mxResources.get("zoom"),!0,null,!0);mxUtils.write(c,":");var C=document.createElement("input");C.setAttribute("type","text");C.style.marginRight="16px";C.style.width="60px";C.style.marginLeft="4px";C.style.marginRight="12px";C.value="100%";c.appendChild(C);var x=this.addCheckbox(c,mxResources.get("fit"),!0),g=null!=this.pages&&1<this.pages.length,F=F=this.addCheckbox(c,mxResources.get("allPages"),g,!g),G=this.addCheckbox(c,mxResources.get("layers"),!0),
+E=this.addCheckbox(c,mxResources.get("lightbox"),!0),J=this.addEditButton(c,E),H=J.getEditInput();H.style.marginBottom="16px";mxEvent.addListener(E,"change",function(){E.checked?H.removeAttribute("disabled"):H.setAttribute("disabled","disabled");H.checked&&E.checked?J.getEditSelect().removeAttribute("disabled"):J.getEditSelect().setAttribute("disabled","disabled")});a=new CustomDialog(this,c,mxUtils.bind(this,function(){e(p.checked?d:null,D.checked,C.value,q.getTarget(),q.getColor(),x.checked,F.checked,
+G.checked,E.checked,J.getLink())}),null,a,b);this.showDialog(a.container,340,384,!0,!0);f.focus()};EditorUi.prototype.showPublishLinkDialog=function(a,b,d,e,m,n){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=document.createElement("h3");mxUtils.write(f,a||mxResources.get("link"));f.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:12px";c.appendChild(f);var g=this.getCurrentFile(),f="https://desk.draw.io/support/solutions/articles/16000051941";a=0;if(null!=
+g&&g.constructor==window.DriveFile&&!b){a=80;var f="https://desk.draw.io/support/solutions/articles/16000039384",p=document.createElement("div");p.style.cssText="border-bottom:1px solid lightGray;padding-bottom:14px;padding-top:6px;margin-bottom:14px;text-align:center;";var l=document.createElement("div");l.style.whiteSpace="normal";mxUtils.write(l,mxResources.get("linkAccountRequired"));p.appendChild(l);l=mxUtils.button(mxResources.get("share"),mxUtils.bind(this,function(){this.drive.showPermissions(g.getId())}));
+l.style.marginTop="12px";l.className="geBtn";p.appendChild(l);c.appendChild(p);l=document.createElement("a");l.style.paddingLeft="12px";l.style.color="gray";l.style.fontSize="11px";l.setAttribute("href","javascript:void(0);");mxUtils.write(l,mxResources.get("check"));p.appendChild(l);mxEvent.addListener(l,"click",mxUtils.bind(this,function(){this.spinner.spin(document.body,mxResources.get("loading"))&&this.getPublicUrl(this.getCurrentFile(),mxUtils.bind(this,function(a){this.spinner.stop();a=new ErrorDialog(this,
+null,mxResources.get(null!=a?"diagramIsPublic":"diagramIsNotPublic"),mxResources.get("ok"));this.showDialog(a.container,300,80,!0,!1);a.init()}))}))}var k=null,q=null;if(null!=d||null!=e)a+=30,mxUtils.write(c,mxResources.get("width")+":"),k=document.createElement("input"),k.setAttribute("type","text"),k.style.marginRight="16px",k.style.width="50px",k.style.marginLeft="6px",k.style.marginRight="16px",k.style.marginBottom="10px",k.value="100%",c.appendChild(k),mxUtils.write(c,mxResources.get("height")+
":"),q=document.createElement("input"),q.setAttribute("type","text"),q.style.width="50px",q.style.marginLeft="6px",q.style.marginBottom="10px",q.value=e+"px",c.appendChild(q),mxUtils.br(c);var x=this.addLinkSection(c,n);d=null!=this.pages&&1<this.pages.length;var F=null;if(null==g||g.constructor!=window.DriveFile||b)F=this.addCheckbox(c,mxResources.get("allPages"),d,!d);var G=this.addCheckbox(c,mxResources.get("lightbox"),!0),E=this.addEditButton(c,G),J=E.getEditInput(),H=this.addCheckbox(c,mxResources.get("layers"),
-!0);H.style.marginLeft=J.style.marginLeft;H.style.marginBottom="16px";H.style.marginTop="8px";mxEvent.addListener(G,"change",function(){G.checked?(H.removeAttribute("disabled"),J.removeAttribute("disabled")):(H.setAttribute("disabled","disabled"),J.setAttribute("disabled","disabled"));J.checked&&G.checked?E.getEditSelect().removeAttribute("disabled"):E.getEditSelect().setAttribute("disabled","disabled")});b=new CustomDialog(this,c,mxUtils.bind(this,function(){l(x.getTarget(),x.getColor(),null==F?
-!0:F.checked,G.checked,E.getLink(),H.checked,null!=m?m.value:null,null!=q?q.value:null)}),null,mxResources.get("create"),f);this.showDialog(b.container,340,254+a,!0,!0);null!=m?(m.focus(),mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode||mxClient.IS_QUIRKS?m.select():document.execCommand("selectAll",!1,null)):x.focus()};EditorUi.prototype.showRemoteExportDialog=function(a,b,d,e,l){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=document.createElement("h3");mxUtils.write(f,
-mxResources.get("image"));f.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:"+(l?"10":"4")+"px";c.appendChild(f);if(l){mxUtils.write(c,mxResources.get("zoom")+":");var g=document.createElement("input");g.setAttribute("type","text");g.style.marginRight="16px";g.style.width="60px";g.style.marginLeft="4px";g.style.marginRight="12px";g.value=this.lastExportZoom||"100%";c.appendChild(g);mxUtils.write(c,mxResources.get("borderWidth")+":");var p=document.createElement("input");p.setAttribute("type",
-"text");p.style.marginRight="16px";p.style.width="60px";p.style.marginLeft="4px";p.value=this.lastExportBorder||"0";c.appendChild(p);mxUtils.br(c)}var k=this.addCheckbox(c,mxResources.get("selectionOnly"),!1,this.editor.graph.isSelectionEmpty()),m=e?null:this.addCheckbox(c,mxResources.get("includeCopyOfMyDiagram"),!0),f=this.editor.graph,q=e?null:this.addCheckbox(c,mxResources.get("transparentBackground"),f.background==mxConstants.NONE||null==f.background);null!=q&&(q.style.marginBottom="16px");a=
-new CustomDialog(this,c,mxUtils.bind(this,function(){var a=parseInt(g.value)/100||1,c=parseInt(p.value)||0;d(!k.checked,null!=m?m.checked:!1,null!=q?q.checked:!1,a,c)}),null,a,b);this.showDialog(a.container,300,(l?25:0)+(e?125:210),!0,!0)};EditorUi.prototype.showExportDialog=function(a,b,d,e,l,n,k,m){k=null!=k?k:!0;var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=this.editor.graph,g="jpeg"==m?196:300,p=document.createElement("h3");mxUtils.write(p,a);p.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:10px";
+!0);H.style.marginLeft=J.style.marginLeft;H.style.marginBottom="16px";H.style.marginTop="8px";mxEvent.addListener(G,"change",function(){G.checked?(H.removeAttribute("disabled"),J.removeAttribute("disabled")):(H.setAttribute("disabled","disabled"),J.setAttribute("disabled","disabled"));J.checked&&G.checked?E.getEditSelect().removeAttribute("disabled"):E.getEditSelect().setAttribute("disabled","disabled")});b=new CustomDialog(this,c,mxUtils.bind(this,function(){m(x.getTarget(),x.getColor(),null==F?
+!0:F.checked,G.checked,E.getLink(),H.checked,null!=k?k.value:null,null!=q?q.value:null)}),null,mxResources.get("create"),f);this.showDialog(b.container,340,254+a,!0,!0);null!=k?(k.focus(),mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode||mxClient.IS_QUIRKS?k.select():document.execCommand("selectAll",!1,null)):x.focus()};EditorUi.prototype.showRemoteExportDialog=function(a,b,d,e,m){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=document.createElement("h3");mxUtils.write(f,
+mxResources.get("image"));f.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:"+(m?"10":"4")+"px";c.appendChild(f);if(m){mxUtils.write(c,mxResources.get("zoom")+":");var g=document.createElement("input");g.setAttribute("type","text");g.style.marginRight="16px";g.style.width="60px";g.style.marginLeft="4px";g.style.marginRight="12px";g.value=this.lastExportZoom||"100%";c.appendChild(g);mxUtils.write(c,mxResources.get("borderWidth")+":");var p=document.createElement("input");p.setAttribute("type",
+"text");p.style.marginRight="16px";p.style.width="60px";p.style.marginLeft="4px";p.value=this.lastExportBorder||"0";c.appendChild(p);mxUtils.br(c)}var l=this.addCheckbox(c,mxResources.get("selectionOnly"),!1,this.editor.graph.isSelectionEmpty()),k=e?null:this.addCheckbox(c,mxResources.get("includeCopyOfMyDiagram"),!0),f=this.editor.graph,q=e?null:this.addCheckbox(c,mxResources.get("transparentBackground"),f.background==mxConstants.NONE||null==f.background);null!=q&&(q.style.marginBottom="16px");a=
+new CustomDialog(this,c,mxUtils.bind(this,function(){var a=parseInt(g.value)/100||1,c=parseInt(p.value)||0;d(!l.checked,null!=k?k.checked:!1,null!=q?q.checked:!1,a,c)}),null,a,b);this.showDialog(a.container,300,(m?25:0)+(e?125:210),!0,!0)};EditorUi.prototype.showExportDialog=function(a,b,d,e,m,n,l,k){l=null!=l?l:!0;var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=this.editor.graph,g="jpeg"==k?196:300,p=document.createElement("h3");mxUtils.write(p,a);p.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:10px";
c.appendChild(p);mxUtils.write(c,mxResources.get("zoom")+":");var t=document.createElement("input");t.setAttribute("type","text");t.style.marginRight="16px";t.style.width="60px";t.style.marginLeft="4px";t.style.marginRight="12px";t.value=this.lastExportZoom||"100%";c.appendChild(t);mxUtils.write(c,mxResources.get("borderWidth")+":");var q=document.createElement("input");q.setAttribute("type","text");q.style.marginRight="16px";q.style.width="60px";q.style.marginLeft="4px";q.value=this.lastExportBorder||
-"0";c.appendChild(q);mxUtils.br(c);var v=this.addCheckbox(c,mxResources.get("transparentBackground"),!1,null,null,"jpeg"!=m),G=this.addCheckbox(c,mxResources.get("selectionOnly"),!1,f.isSelectionEmpty()),E=document.createElement("input");E.style.marginTop="16px";E.style.marginRight="8px";E.style.marginLeft="24px";E.setAttribute("disabled","disabled");E.setAttribute("type","checkbox");n&&(c.appendChild(E),mxUtils.write(c,mxResources.get("crop")),mxUtils.br(c),g+=26,mxEvent.addListener(G,"change",function(){G.checked?
+"0";c.appendChild(q);mxUtils.br(c);var v=this.addCheckbox(c,mxResources.get("transparentBackground"),!1,null,null,"jpeg"!=k),G=this.addCheckbox(c,mxResources.get("selectionOnly"),!1,f.isSelectionEmpty()),E=document.createElement("input");E.style.marginTop="16px";E.style.marginRight="8px";E.style.marginLeft="24px";E.setAttribute("disabled","disabled");E.setAttribute("type","checkbox");n&&(c.appendChild(E),mxUtils.write(c,mxResources.get("crop")),mxUtils.br(c),g+=26,mxEvent.addListener(G,"change",function(){G.checked?
E.removeAttribute("disabled"):E.setAttribute("disabled","disabled")}));f.isSelectionEmpty()||(E.setAttribute("checked","checked"),E.defaultChecked=!0);var J=this.addCheckbox(c,mxResources.get("shadow"),f.shadowVisible),H=document.createElement("input");H.style.marginTop="16px";H.style.marginRight="8px";H.setAttribute("type","checkbox");!this.isOffline()&&this.canvasSupported||H.setAttribute("disabled","disabled");b&&(c.appendChild(H),mxUtils.write(c,mxResources.get("embedImages")),mxUtils.br(c),g+=
-26);var y=null;if("png"==m||"jpeg"==m)y=this.addCheckbox(c,mxResources.get("grid"),!1,this.isOffline()||!this.canvasSupported,!1,!0),g+=26;var K=this.addCheckbox(c,mxResources.get("includeCopyOfMyDiagram"),k,null,null,"jpeg"!=m),z=null!=this.pages&&1<this.pages.length,L=this.addCheckbox(c,z?mxResources.get("allPages"):"",z,!z,null,"jpeg"!=m);L.style.marginLeft="24px";L.style.marginBottom="16px";z?g+=26:L.style.display="none";mxEvent.addListener(K,"change",function(){K.checked&&z?L.removeAttribute("disabled"):
-L.setAttribute("disabled","disabled")});k&&z||L.setAttribute("disabled","disabled");var O=document.createElement("select");O.style.maxWidth="260px";O.style.marginLeft="8px";O.style.marginRight="10px";O.className="geBtn";a=document.createElement("option");a.setAttribute("value","auto");mxUtils.write(a,mxResources.get("automatic"));O.appendChild(a);a=document.createElement("option");a.setAttribute("value","blank");mxUtils.write(a,mxResources.get("openInNewWindow"));O.appendChild(a);a=document.createElement("option");
-a.setAttribute("value","self");mxUtils.write(a,mxResources.get("openInThisWindow"));O.appendChild(a);"svg"==m&&(mxUtils.write(c,mxResources.get("links")+":"),c.appendChild(O),mxUtils.br(c),mxUtils.br(c),g+=26);d=new CustomDialog(this,c,mxUtils.bind(this,function(){this.lastExportBorder=q.value;this.lastExportZoom=t.value;l(t.value,v.checked,!G.checked,J.checked,K.checked,H.checked,q.value,E.checked,!L.checked,O.value,null!=y?y.checked:null)}),null,d,e);this.showDialog(d.container,340,g,!0,!0,null,
-null,null,null,!0);t.focus();mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode||mxClient.IS_QUIRKS?t.select():document.execCommand("selectAll",!1,null)};EditorUi.prototype.showEmbedImageDialog=function(a,b,d,e,l){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=this.editor.graph;if(null!=b){var g=document.createElement("h3");mxUtils.write(g,b);g.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:4px";c.appendChild(g)}var p=this.addCheckbox(c,mxResources.get("fit"),
-!0),k=this.addCheckbox(c,mxResources.get("shadow"),f.shadowVisible&&e,!e),m=this.addCheckbox(c,d),q=this.addCheckbox(c,mxResources.get("lightbox"),!0),C=this.addEditButton(c,q),x=C.getEditInput(),F=1<f.model.getChildCount(f.model.getRoot()),G=this.addCheckbox(c,mxResources.get("layers"),F,!F);G.style.marginLeft=x.style.marginLeft;G.style.marginBottom="12px";G.style.marginTop="8px";mxEvent.addListener(q,"change",function(){q.checked?(F&&G.removeAttribute("disabled"),x.removeAttribute("disabled")):
-(G.setAttribute("disabled","disabled"),x.setAttribute("disabled","disabled"));x.checked&&q.checked?C.getEditSelect().removeAttribute("disabled"):C.getEditSelect().setAttribute("disabled","disabled")});b=new CustomDialog(this,c,mxUtils.bind(this,function(){a(p.checked,k.checked,m.checked,q.checked,C.getLink(),G.checked)}),null,mxResources.get("embed"),l);this.showDialog(b.container,280,280,!0,!0)};EditorUi.prototype.createEmbedImage=function(a,b,d,e,l,n,k,m){function c(c){var b=" ",g="";e&&(b=" onclick=\"(function(img){if(img.wnd!=null&&!img.wnd.closed){img.wnd.focus();}else{var r=function(evt){if(evt.data=='ready'&&evt.source==img.wnd){img.wnd.postMessage(decodeURIComponent(img.getAttribute('src')),'*');window.removeEventListener('message',r);}};window.addEventListener('message',r);img.wnd=window.open('"+
-EditorUi.drawHost+"/?client=1&lightbox=1"+(l?"&edit=_blank":"")+(n?"&layers=1":"")+"');}})(this);\"",g+="cursor:pointer;");a&&(g+="max-width:100%;");var p="";d&&(p=' width="'+Math.round(f.width)+'" height="'+Math.round(f.height)+'"');k('<img src="'+c+'"'+p+(""!=g?' style="'+g+'"':"")+b+"/>")}var f=this.editor.graph.getGraphBounds();if(this.isExportToCanvas())this.editor.exportToCanvas(mxUtils.bind(this,function(a){var b=e?this.getFileData(!0):null;a=this.createImageDataUri(a,b,"png");c(a)}),null,
-null,null,mxUtils.bind(this,function(a){m({message:mxResources.get("unknownError")})}),null,!0,d?2:1,null,b);else if(b=this.getFileData(!0),f.width*f.height<=MAX_AREA&&b.length<=MAX_REQUEST_SIZE){var g="";d&&(g="&w="+Math.round(2*f.width)+"&h="+Math.round(2*f.height));var p=new mxXmlRequest(EXPORT_URL,"format=png&base64=1&embedXml="+(e?"1":"0")+g+"&xml="+encodeURIComponent(b));p.send(mxUtils.bind(this,function(){200<=p.getStatus()&&299>=p.getStatus()?c("data:image/png;base64,"+p.getText()):m({message:mxResources.get("unknownError")})}))}else m({message:mxResources.get("drawingTooLarge")})};
-EditorUi.prototype.createEmbedSvg=function(a,b,d,e,l,n,k){var c=this.editor.graph.getSvg(null,null,null,null,null,null,null,null,null,null,!d),f=c.getElementsByTagName("a");if(null!=f)for(var g=0;g<f.length;g++){var p=f[g].getAttribute("href");null!=p&&"#"==p.charAt(0)&&"_blank"==f[g].getAttribute("target")&&f[g].removeAttribute("target")}e&&c.setAttribute("content",this.getFileData(!0));b&&this.editor.graph.addSvgShadow(c);if(d){var m=" ",q="";e&&(m="onclick=\"(function(img){if(img.wnd!=null&&!img.wnd.closed){img.wnd.focus();}else{var r=function(evt){if(evt.data=='ready'&&evt.source==img.wnd){img.wnd.postMessage(decodeURIComponent(img.getAttribute('src')),'*');window.removeEventListener('message',r);}};window.addEventListener('message',r);img.wnd=window.open('"+
-EditorUi.drawHost+"/?client=1&lightbox=1"+(l?"&edit=_blank":"")+(n?"&layers=1":"")+"');}})(this);\"",q+="cursor:pointer;");a&&(q+="max-width:100%;");this.editor.convertImages(c,mxUtils.bind(this,function(a){k('<img src="'+Editor.createSvgDataUri(mxUtils.getXml(a))+'"'+(""!=q?' style="'+q+'"':"")+m+"/>")}))}else q="",e&&(c.setAttribute("onclick","(function(svg){var src=window.event.target||window.event.srcElement;while (src!=null&&src.nodeName.toLowerCase()!='a'){src=src.parentNode;}if(src==null){if(svg.wnd!=null&&!svg.wnd.closed){svg.wnd.focus();}else{var r=function(evt){if(evt.data=='ready'&&evt.source==svg.wnd){svg.wnd.postMessage(decodeURIComponent(svg.getAttribute('content')),'*');window.removeEventListener('message',r);}};window.addEventListener('message',r);svg.wnd=window.open('"+
-EditorUi.drawHost+"/?client=1&lightbox=1"+(l?"&edit=_blank":"")+(n?"&layers=1":"")+"');}}})(this);"),q+="cursor:pointer;"),a&&(a=parseInt(c.getAttribute("width")),b=parseInt(c.getAttribute("height")),c.setAttribute("viewBox","-0.5 -0.5 "+a+" "+b),q+="max-width:100%;max-height:"+b+"px;",c.removeAttribute("height")),""!=q&&c.setAttribute("style",q),this.editor.addFontCss(c),this.editor.graph.mathEnabled&&this.editor.addMathCss(c),k(mxUtils.getXml(c))};EditorUi.prototype.timeSince=function(a){a=Math.floor((new Date-
+26);var y=null;if("png"==k||"jpeg"==k)y=this.addCheckbox(c,mxResources.get("grid"),!1,this.isOffline()||!this.canvasSupported,!1,!0),g+=26;var K=this.addCheckbox(c,mxResources.get("includeCopyOfMyDiagram"),l,null,null,"jpeg"!=k),z=null!=this.pages&&1<this.pages.length,L=this.addCheckbox(c,z?mxResources.get("allPages"):"",z,!z,null,"jpeg"!=k);L.style.marginLeft="24px";L.style.marginBottom="16px";z?g+=26:L.style.display="none";mxEvent.addListener(K,"change",function(){K.checked&&z?L.removeAttribute("disabled"):
+L.setAttribute("disabled","disabled")});l&&z||L.setAttribute("disabled","disabled");var O=document.createElement("select");O.style.maxWidth="260px";O.style.marginLeft="8px";O.style.marginRight="10px";O.className="geBtn";a=document.createElement("option");a.setAttribute("value","auto");mxUtils.write(a,mxResources.get("automatic"));O.appendChild(a);a=document.createElement("option");a.setAttribute("value","blank");mxUtils.write(a,mxResources.get("openInNewWindow"));O.appendChild(a);a=document.createElement("option");
+a.setAttribute("value","self");mxUtils.write(a,mxResources.get("openInThisWindow"));O.appendChild(a);"svg"==k&&(mxUtils.write(c,mxResources.get("links")+":"),c.appendChild(O),mxUtils.br(c),mxUtils.br(c),g+=26);d=new CustomDialog(this,c,mxUtils.bind(this,function(){this.lastExportBorder=q.value;this.lastExportZoom=t.value;m(t.value,v.checked,!G.checked,J.checked,K.checked,H.checked,q.value,E.checked,!L.checked,O.value,null!=y?y.checked:null)}),null,d,e);this.showDialog(d.container,340,g,!0,!0,null,
+null,null,null,!0);t.focus();mxClient.IS_GC||mxClient.IS_FF||5<=document.documentMode||mxClient.IS_QUIRKS?t.select():document.execCommand("selectAll",!1,null)};EditorUi.prototype.showEmbedImageDialog=function(a,b,d,e,m){var c=document.createElement("div");c.style.whiteSpace="nowrap";var f=this.editor.graph;if(null!=b){var g=document.createElement("h3");mxUtils.write(g,b);g.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:4px";c.appendChild(g)}var p=this.addCheckbox(c,mxResources.get("fit"),
+!0),l=this.addCheckbox(c,mxResources.get("shadow"),f.shadowVisible&&e,!e),k=this.addCheckbox(c,d),q=this.addCheckbox(c,mxResources.get("lightbox"),!0),C=this.addEditButton(c,q),x=C.getEditInput(),F=1<f.model.getChildCount(f.model.getRoot()),G=this.addCheckbox(c,mxResources.get("layers"),F,!F);G.style.marginLeft=x.style.marginLeft;G.style.marginBottom="12px";G.style.marginTop="8px";mxEvent.addListener(q,"change",function(){q.checked?(F&&G.removeAttribute("disabled"),x.removeAttribute("disabled")):
+(G.setAttribute("disabled","disabled"),x.setAttribute("disabled","disabled"));x.checked&&q.checked?C.getEditSelect().removeAttribute("disabled"):C.getEditSelect().setAttribute("disabled","disabled")});b=new CustomDialog(this,c,mxUtils.bind(this,function(){a(p.checked,l.checked,k.checked,q.checked,C.getLink(),G.checked)}),null,mxResources.get("embed"),m);this.showDialog(b.container,280,280,!0,!0)};EditorUi.prototype.createEmbedImage=function(a,b,d,e,m,n,l,k){function c(c){var b=" ",g="";e&&(b=" onclick=\"(function(img){if(img.wnd!=null&&!img.wnd.closed){img.wnd.focus();}else{var r=function(evt){if(evt.data=='ready'&&evt.source==img.wnd){img.wnd.postMessage(decodeURIComponent(img.getAttribute('src')),'*');window.removeEventListener('message',r);}};window.addEventListener('message',r);img.wnd=window.open('"+
+EditorUi.drawHost+"/?client=1&lightbox=1"+(m?"&edit=_blank":"")+(n?"&layers=1":"")+"');}})(this);\"",g+="cursor:pointer;");a&&(g+="max-width:100%;");var p="";d&&(p=' width="'+Math.round(f.width)+'" height="'+Math.round(f.height)+'"');l('<img src="'+c+'"'+p+(""!=g?' style="'+g+'"':"")+b+"/>")}var f=this.editor.graph.getGraphBounds();if(this.isExportToCanvas())this.editor.exportToCanvas(mxUtils.bind(this,function(a){var b=e?this.getFileData(!0):null;a=this.createImageDataUri(a,b,"png");c(a)}),null,
+null,null,mxUtils.bind(this,function(a){k({message:mxResources.get("unknownError")})}),null,!0,d?2:1,null,b);else if(b=this.getFileData(!0),f.width*f.height<=MAX_AREA&&b.length<=MAX_REQUEST_SIZE){var g="";d&&(g="&w="+Math.round(2*f.width)+"&h="+Math.round(2*f.height));var p=new mxXmlRequest(EXPORT_URL,"format=png&base64=1&embedXml="+(e?"1":"0")+g+"&xml="+encodeURIComponent(b));p.send(mxUtils.bind(this,function(){200<=p.getStatus()&&299>=p.getStatus()?c("data:image/png;base64,"+p.getText()):k({message:mxResources.get("unknownError")})}))}else k({message:mxResources.get("drawingTooLarge")})};
+EditorUi.prototype.createEmbedSvg=function(a,b,d,e,m,n,l){var c=this.editor.graph.getSvg(null,null,null,null,null,null,null,null,null,null,!d),f=c.getElementsByTagName("a");if(null!=f)for(var g=0;g<f.length;g++){var p=f[g].getAttribute("href");null!=p&&"#"==p.charAt(0)&&"_blank"==f[g].getAttribute("target")&&f[g].removeAttribute("target")}e&&c.setAttribute("content",this.getFileData(!0));b&&this.editor.graph.addSvgShadow(c);if(d){var k=" ",q="";e&&(k="onclick=\"(function(img){if(img.wnd!=null&&!img.wnd.closed){img.wnd.focus();}else{var r=function(evt){if(evt.data=='ready'&&evt.source==img.wnd){img.wnd.postMessage(decodeURIComponent(img.getAttribute('src')),'*');window.removeEventListener('message',r);}};window.addEventListener('message',r);img.wnd=window.open('"+
+EditorUi.drawHost+"/?client=1&lightbox=1"+(m?"&edit=_blank":"")+(n?"&layers=1":"")+"');}})(this);\"",q+="cursor:pointer;");a&&(q+="max-width:100%;");this.editor.convertImages(c,mxUtils.bind(this,function(a){l('<img src="'+Editor.createSvgDataUri(mxUtils.getXml(a))+'"'+(""!=q?' style="'+q+'"':"")+k+"/>")}))}else q="",e&&(c.setAttribute("onclick","(function(svg){var src=window.event.target||window.event.srcElement;while (src!=null&&src.nodeName.toLowerCase()!='a'){src=src.parentNode;}if(src==null){if(svg.wnd!=null&&!svg.wnd.closed){svg.wnd.focus();}else{var r=function(evt){if(evt.data=='ready'&&evt.source==svg.wnd){svg.wnd.postMessage(decodeURIComponent(svg.getAttribute('content')),'*');window.removeEventListener('message',r);}};window.addEventListener('message',r);svg.wnd=window.open('"+
+EditorUi.drawHost+"/?client=1&lightbox=1"+(m?"&edit=_blank":"")+(n?"&layers=1":"")+"');}}})(this);"),q+="cursor:pointer;"),a&&(a=parseInt(c.getAttribute("width")),b=parseInt(c.getAttribute("height")),c.setAttribute("viewBox","-0.5 -0.5 "+a+" "+b),q+="max-width:100%;max-height:"+b+"px;",c.removeAttribute("height")),""!=q&&c.setAttribute("style",q),this.editor.addFontCss(c),this.editor.graph.mathEnabled&&this.editor.addMathCss(c),l(mxUtils.getXml(c))};EditorUi.prototype.timeSince=function(a){a=Math.floor((new Date-
a)/1E3);var c=Math.floor(a/31536E3);if(1<c)return c+" "+mxResources.get("years");c=Math.floor(a/2592E3);if(1<c)return c+" "+mxResources.get("months");c=Math.floor(a/86400);if(1<c)return c+" "+mxResources.get("days");c=Math.floor(a/3600);if(1<c)return c+" "+mxResources.get("hours");c=Math.floor(a/60);return 1<c?c+" "+mxResources.get("minutes"):1==c?c+" "+mxResources.get("minute"):null};EditorUi.prototype.decodeNodeIntoGraph=function(a,b){if(null!=a){var c=null;if("diagram"==a.nodeName)c=a;else if("mxfile"==
a.nodeName){var d=a.getElementsByTagName("diagram");if(0<d.length){var c=d[0],f=b.getGlobalVariable;b.getGlobalVariable=function(a){return"page"==a?c.getAttribute("name")||mxResources.get("pageWithNumber",[1]):"pagenumber"==a?1:f.apply(this,arguments)}}}null!=c&&(a=Editor.parseDiagramNode(c))}d=this.editor.graph;try{this.editor.graph=b,this.editor.setGraphXml(a)}catch(n){}finally{this.editor.graph=d}return a};EditorUi.prototype.getPngFileProperties=function(a){var c=1,b=0;if(null!=a){if(a.hasAttribute("scale")){var d=
-parseFloat(a.getAttribute("scale"));!isNaN(d)&&0<d&&(c=d)}a.hasAttribute("border")&&(d=parseInt(a.getAttribute("border")),!isNaN(d)&&0<d&&(b=d))}return{scale:c,border:b}};EditorUi.prototype.getEmbeddedPng=function(a,b,d,e,l){try{var c=this.editor.graph,f=null!=c.themes&&"darkTheme"==c.defaultThemeName,g=null;if(null!=d&&0<d.length)c=this.createTemporaryGraph(this.editor.graph.getStylesheet()),document.body.appendChild(c.container),this.decodeNodeIntoGraph(this.editor.extractGraphModel(mxUtils.parseXml(d).documentElement,
-!0),c),g=d;else if(f||null!=this.pages&&this.currentPage!=this.pages[0]){var c=this.createTemporaryGraph(c.getStylesheet()),p=c.getGlobalVariable,k=this.pages[0];c.getGlobalVariable=function(a){return"page"==a?k.getName():"pagenumber"==a?1:p.apply(this,arguments)};document.body.appendChild(c.container);c.model.setRoot(k.root)}this.editor.exportToCanvas(mxUtils.bind(this,function(d){try{null==g&&(g=this.getFileData(!0,null,null,null,null,null,null,null,null,!1));var f=d.toDataURL("image/png"),f=Editor.writeGraphModelToPng(f,
-"tEXt","mxfile",encodeURIComponent(g));a(f.substring(f.lastIndexOf(",")+1));c!=this.editor.graph&&c.container.parentNode.removeChild(c.container)}catch(C){null!=b&&b(C)}}),null,null,null,mxUtils.bind(this,function(a){null!=b&&b(a)}),null,null,e,null,c.shadowVisible,null,c,l)}catch(B){null!=b&&b(B)}};EditorUi.prototype.getEmbeddedSvg=function(a,b,d,e,l,n,k,m){m=null!=m?m:!0;k=b.background;k==mxConstants.NONE&&(k=null);n=b.getSvg(k,null,null,null,null,n);b.shadowVisible&&b.addSvgShadow(n);null!=a&&
-n.setAttribute("content",a);null!=d&&n.setAttribute("resource",d);if(null!=l)this.embedFonts(n,mxUtils.bind(this,function(a){m?this.editor.convertImages(a,mxUtils.bind(this,function(a){l((e?"":'<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n')+mxUtils.getXml(a))})):l((e?"":'<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n')+
+parseFloat(a.getAttribute("scale"));!isNaN(d)&&0<d&&(c=d)}a.hasAttribute("border")&&(d=parseInt(a.getAttribute("border")),!isNaN(d)&&0<d&&(b=d))}return{scale:c,border:b}};EditorUi.prototype.getEmbeddedPng=function(a,b,d,e,m){try{var c=this.editor.graph,f=null!=c.themes&&"darkTheme"==c.defaultThemeName,g=null;if(null!=d&&0<d.length)c=this.createTemporaryGraph(this.editor.graph.getStylesheet()),document.body.appendChild(c.container),this.decodeNodeIntoGraph(this.editor.extractGraphModel(mxUtils.parseXml(d).documentElement,
+!0),c),g=d;else if(f||null!=this.pages&&this.currentPage!=this.pages[0]){var c=this.createTemporaryGraph(c.getStylesheet()),p=c.getGlobalVariable,l=this.pages[0];c.getGlobalVariable=function(a){return"page"==a?l.getName():"pagenumber"==a?1:p.apply(this,arguments)};document.body.appendChild(c.container);c.model.setRoot(l.root)}this.editor.exportToCanvas(mxUtils.bind(this,function(d){try{null==g&&(g=this.getFileData(!0,null,null,null,null,null,null,null,null,!1));var f=d.toDataURL("image/png"),f=Editor.writeGraphModelToPng(f,
+"tEXt","mxfile",encodeURIComponent(g));a(f.substring(f.lastIndexOf(",")+1));c!=this.editor.graph&&c.container.parentNode.removeChild(c.container)}catch(C){null!=b&&b(C)}}),null,null,null,mxUtils.bind(this,function(a){null!=b&&b(a)}),null,null,e,null,c.shadowVisible,null,c,m)}catch(B){null!=b&&b(B)}};EditorUi.prototype.getEmbeddedSvg=function(a,b,d,e,m,n,l,k){k=null!=k?k:!0;l=b.background;l==mxConstants.NONE&&(l=null);n=b.getSvg(l,null,null,null,null,n);b.shadowVisible&&b.addSvgShadow(n);null!=a&&
+n.setAttribute("content",a);null!=d&&n.setAttribute("resource",d);if(null!=m)this.embedFonts(n,mxUtils.bind(this,function(a){k?this.editor.convertImages(a,mxUtils.bind(this,function(a){m((e?"":'<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n')+mxUtils.getXml(a))})):m((e?"":'<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n')+
mxUtils.getXml(a))}));else return(e?"":'<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">\n')+mxUtils.getXml(n)};EditorUi.prototype.embedFonts=function(a,b){this.editor.loadFonts(mxUtils.bind(this,function(){try{null!=this.editor.resolvedFontCss&&this.editor.addFontCss(a,this.editor.resolvedFontCss),this.editor.embedExtFonts(mxUtils.bind(this,function(c){try{null!=c&&this.editor.addFontCss(a,c),b(a)}catch(p){b(a)}}))}catch(g){b(a)}}))};
-EditorUi.prototype.exportImage=function(a,b,d,e,l,n,k,m,u,q,B){u=null!=u?u:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var c=this.editor.graph.isSelectionEmpty();d=null!=d?d:c;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.editor.exportToCanvas(mxUtils.bind(this,function(a){this.spinner.stop();try{this.saveCanvas(a,l?this.getFileData(!0,null,null,null,d,m):null,u,null==this.pages||0==this.pages.length,B)}catch(x){"Invalid image"==x.message?this.downloadFile(u):
-this.handleError(x)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a)}),null,d,a||1,b,e,null,null,n,k,q)}catch(C){this.spinner.stop(),this.handleError(C)}}};EditorUi.prototype.isCorsEnabledForUrl=function(a){return this.editor.isCorsEnabledForUrl(a)};EditorUi.prototype.importXml=function(a,b,d,e,l){b=null!=b?b:0;d=null!=d?d:0;var c=[];try{var f=this.editor.graph;if(null!=a&&0<a.length){f.model.beginUpdate();try{var g=mxUtils.parseXml(a);a={};var p=
-this.editor.extractGraphModel(g.documentElement,null!=this.pages);if(null!=p&&"mxfile"==p.nodeName&&null!=this.pages){var k=p.getElementsByTagName("diagram");if(1==k.length)p=Editor.parseDiagramNode(k[0]),null!=this.currentPage&&(a[k[0].getAttribute("id")]=this.currentPage.getId());else if(1<k.length){var g=[],m=0;null!=this.pages&&1==this.pages.length&&this.isDiagramEmpty()&&(a[k[0].getAttribute("id")]=this.pages[0].getId(),p=Editor.parseDiagramNode(k[0]),e=!1,m=1);for(;m<k.length;m++){var q=k[m].getAttribute("id");
-k[m].removeAttribute("id");var C=this.updatePageRoot(new DiagramPage(k[m]));a[q]=k[m].getAttribute("id");var x=this.pages.length;null==C.getName()&&C.setName(mxResources.get("pageWithNumber",[x+1]));f.model.execute(new ChangePage(this,C,C,x,!0));g.push(C)}this.updatePageLinks(a,g)}}if(null!=p&&"mxGraphModel"===p.nodeName&&(c=f.importGraphModel(p,b,d,e),null!=c))for(m=0;m<c.length;m++)this.updatePageLinksForCell(a,c[m])}finally{f.model.endUpdate()}}}catch(F){if(l)throw F;this.handleError(F)}return c};
-EditorUi.prototype.updatePageLinks=function(a,b){for(var c=0;c<b.length;c++)this.updatePageLinksForCell(a,b[c].root)};EditorUi.prototype.updatePageLinksForCell=function(a,b){var c=document.createElement("div"),d=this.editor.graph,f=d.getLinkForCell(b);null!=f&&d.setLinkForCell(b,this.updatePageLink(a,f));if(d.isHtmlLabel(b)){c.innerHTML=d.getLabel(b);for(var e=c.getElementsByTagName("a"),k=!1,m=0;m<e.length;m++)f=e[m].getAttribute("href"),null!=f&&(e[m].setAttribute("href",this.updatePageLink(a,f)),
-k=!0);k&&d.labelChanged(b,c.innerHTML)}for(m=0;m<d.model.getChildCount(b);m++)this.updatePageLinksForCell(a,d.model.getChildAt(b,m))};EditorUi.prototype.updatePageLink=function(a,b){if("data:page/id,"==b.substring(0,13)){var c=a[b.substring(b.indexOf(",")+1)];b=null!=c?"data:page/id,"+c:null}else if("data:action/json,"==b.substring(0,17))try{var d=JSON.parse(b.substring(17));if(null!=d.actions){for(var f=0;f<d.actions.length;f++){var e=d.actions[f];null!=e.open&&"data:page/id,"==e.open.substring(0,
+EditorUi.prototype.exportImage=function(a,b,d,e,m,n,l,k,u,q,B){u=null!=u?u:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var c=this.editor.graph.isSelectionEmpty();d=null!=d?d:c;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.editor.exportToCanvas(mxUtils.bind(this,function(a){this.spinner.stop();try{this.saveCanvas(a,m?this.getFileData(!0,null,null,null,d,k):null,u,null==this.pages||0==this.pages.length,B)}catch(x){"Invalid image"==x.message?this.downloadFile(u):
+this.handleError(x)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a)}),null,d,a||1,b,e,null,null,n,l,q)}catch(C){this.spinner.stop(),this.handleError(C)}}};EditorUi.prototype.isCorsEnabledForUrl=function(a){return this.editor.isCorsEnabledForUrl(a)};EditorUi.prototype.importXml=function(a,b,d,e,m){b=null!=b?b:0;d=null!=d?d:0;var c=[];try{var f=this.editor.graph;if(null!=a&&0<a.length){f.model.beginUpdate();try{var g=mxUtils.parseXml(a);a={};var l=
+this.editor.extractGraphModel(g.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var p=l.getElementsByTagName("diagram");if(1==p.length)l=Editor.parseDiagramNode(p[0]),null!=this.currentPage&&(a[p[0].getAttribute("id")]=this.currentPage.getId());else if(1<p.length){var g=[],k=0;null!=this.pages&&1==this.pages.length&&this.isDiagramEmpty()&&(a[p[0].getAttribute("id")]=this.pages[0].getId(),l=Editor.parseDiagramNode(p[0]),e=!1,k=1);for(;k<p.length;k++){var q=p[k].getAttribute("id");
+p[k].removeAttribute("id");var C=this.updatePageRoot(new DiagramPage(p[k]));a[q]=p[k].getAttribute("id");var x=this.pages.length;null==C.getName()&&C.setName(mxResources.get("pageWithNumber",[x+1]));f.model.execute(new ChangePage(this,C,C,x,!0));g.push(C)}this.updatePageLinks(a,g)}}if(null!=l&&"mxGraphModel"===l.nodeName&&(c=f.importGraphModel(l,b,d,e),null!=c))for(k=0;k<c.length;k++)this.updatePageLinksForCell(a,c[k])}finally{f.model.endUpdate()}}}catch(F){if(m)throw F;this.handleError(F)}return c};
+EditorUi.prototype.updatePageLinks=function(a,b){for(var c=0;c<b.length;c++)this.updatePageLinksForCell(a,b[c].root)};EditorUi.prototype.updatePageLinksForCell=function(a,b){var c=document.createElement("div"),d=this.editor.graph,f=d.getLinkForCell(b);null!=f&&d.setLinkForCell(b,this.updatePageLink(a,f));if(d.isHtmlLabel(b)){c.innerHTML=d.getLabel(b);for(var e=c.getElementsByTagName("a"),l=!1,k=0;k<e.length;k++)f=e[k].getAttribute("href"),null!=f&&(e[k].setAttribute("href",this.updatePageLink(a,f)),
+l=!0);l&&d.labelChanged(b,c.innerHTML)}for(k=0;k<d.model.getChildCount(b);k++)this.updatePageLinksForCell(a,d.model.getChildAt(b,k))};EditorUi.prototype.updatePageLink=function(a,b){if("data:page/id,"==b.substring(0,13)){var c=a[b.substring(b.indexOf(",")+1)];b=null!=c?"data:page/id,"+c:null}else if("data:action/json,"==b.substring(0,17))try{var d=JSON.parse(b.substring(17));if(null!=d.actions){for(var f=0;f<d.actions.length;f++){var e=d.actions[f];null!=e.open&&"data:page/id,"==e.open.substring(0,
13)&&(c=a[e.open.substring(e.open.indexOf(",")+1)],null!=c?e.open="data:page/id,"+c:delete e.open)}b="data:action/json,"+JSON.stringify(d)}}catch(v){}return b};EditorUi.prototype.isRemoteVisioFormat=function(a){return/(\.v(sd|dx))($|\?)/i.test(a)||/(\.vs(s|x))($|\?)/i.test(a)};EditorUi.prototype.importVisio=function(a,b,d,e){e=null!=e?e:a.name;d=null!=d?d:mxUtils.bind(this,function(a){this.handleError(a)});var c=mxUtils.bind(this,function(){this.loadingExtensions=!1;if(this.doImportVisio){var c=this.isRemoteVisioFormat(e);
-try{var f="UNKNOWN-VISIO",g=e.lastIndexOf(".");if(0<=g&&g<e.length)f=e.substring(g+1).toUpperCase();else{var l=e.lastIndexOf("/");0<=l&&l<e.length&&(e=e.substring(l+1))}EditorUi.logEvent({category:f+"-MS-IMPORT-FILE",action:"filename_"+e,label:c?"remote":"local"})}catch(B){}if(c)if(null==VSD_CONVERT_URL||this.isOffline())d({message:"conf"==this.getServiceName()?mxResources.get("vsdNoConfig"):mxResources.get("serviceUnavailableOrBlocked")});else{c=new FormData;c.append("file1",a,e);var k=new XMLHttpRequest;
-k.open("POST",VSD_CONVERT_URL);k.responseType="blob";this.addRemoteServiceSecurityCheck(k);k.onreadystatechange=mxUtils.bind(this,function(){if(4==k.readyState)if(200<=k.status&&299>=k.status)try{var a=k.response;if("text/xml"==a.type){var c=new FileReader;c.onload=mxUtils.bind(this,function(a){try{b(a.target.result)}catch(x){d({message:mxResources.get("errorLoadingFile")})}});c.readAsText(a)}else this.doImportVisio(a,b,d,e)}catch(C){d(C)}else d({})});k.send(c)}else try{this.doImportVisio(a,b,d,e)}catch(B){d(B)}}else this.spinner.stop(),
-this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")})});this.doImportVisio||this.loadingExtensions||this.isOffline(!0)?c():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",c))};EditorUi.prototype.importGraphML=function(a,b,d){d=null!=d?d:mxUtils.bind(this,function(a){this.handleError(a)});var c=mxUtils.bind(this,function(){this.loadingExtensions=!1;if(this.doImportGraphML)try{this.doImportGraphML(a,b,d)}catch(l){d(l)}else this.spinner.stop(),this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")})});
+try{var f="UNKNOWN-VISIO",g=e.lastIndexOf(".");if(0<=g&&g<e.length)f=e.substring(g+1).toUpperCase();else{var m=e.lastIndexOf("/");0<=m&&m<e.length&&(e=e.substring(m+1))}EditorUi.logEvent({category:f+"-MS-IMPORT-FILE",action:"filename_"+e,label:c?"remote":"local"})}catch(B){}if(c)if(null==VSD_CONVERT_URL||this.isOffline())d({message:"conf"==this.getServiceName()?mxResources.get("vsdNoConfig"):mxResources.get("serviceUnavailableOrBlocked")});else{c=new FormData;c.append("file1",a,e);var l=new XMLHttpRequest;
+l.open("POST",VSD_CONVERT_URL);l.responseType="blob";this.addRemoteServiceSecurityCheck(l);l.onreadystatechange=mxUtils.bind(this,function(){if(4==l.readyState)if(200<=l.status&&299>=l.status)try{var a=l.response;if("text/xml"==a.type){var c=new FileReader;c.onload=mxUtils.bind(this,function(a){try{b(a.target.result)}catch(x){d({message:mxResources.get("errorLoadingFile")})}});c.readAsText(a)}else this.doImportVisio(a,b,d,e)}catch(C){d(C)}else d({})});l.send(c)}else try{this.doImportVisio(a,b,d,e)}catch(B){d(B)}}else this.spinner.stop(),
+this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")})});this.doImportVisio||this.loadingExtensions||this.isOffline(!0)?c():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",c))};EditorUi.prototype.importGraphML=function(a,b,d){d=null!=d?d:mxUtils.bind(this,function(a){this.handleError(a)});var c=mxUtils.bind(this,function(){this.loadingExtensions=!1;if(this.doImportGraphML)try{this.doImportGraphML(a,b,d)}catch(m){d(m)}else this.spinner.stop(),this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")})});
this.doImportGraphML||this.loadingExtensions||this.isOffline(!0)?c():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",c))};EditorUi.prototype.exportVisio=function(){var a=mxUtils.bind(this,function(){this.loadingExtensions=!1;if("undefined"!==typeof VsdxExport)try{(new VsdxExport(this)).exportCurrentDiagrams()||this.handleError({message:mxResources.get("unknownError")})}catch(f){this.handleError(f)}else this.spinner.stop(),this.handleError({message:mxResources.get("serviceUnavailableOrBlocked")})});
-"undefined"!==typeof VsdxExport||this.loadingExtensions||this.isOffline(!0)?a():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",a))};EditorUi.prototype.convertLucidChart=function(a,b,d){var c=mxUtils.bind(this,function(){this.loadingExtensions=!1;if("undefined"!==typeof window.LucidImporter){try{EditorUi.logEvent({category:"LUCIDCHART-IMPORT-FILE",action:"size_"+a.length}),EditorUi.debug("convertLucidChart",a)}catch(l){}try{b(LucidImporter.importState(JSON.parse(a)))}catch(l){null!=window.console&&
-console.error(l),d(l)}}else d({message:mxResources.get("serviceUnavailableOrBlocked")})});"undefined"!==typeof window.LucidImporter||this.loadingExtensions||this.isOffline(!0)?window.setTimeout(c,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("js/diagramly/Extensions.js",c):mxscript("js/extensions.min.js",c))};EditorUi.prototype.generateMermaidImage=function(a,b,d,e){var c=this,f=function(){try{this.loadingMermaid=!1,b=null!=b?b:EditorUi.defaultMermaidConfig,b.securityLevel="strict",b.startOnLoad=
+"undefined"!==typeof VsdxExport||this.loadingExtensions||this.isOffline(!0)?a():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",a))};EditorUi.prototype.convertLucidChart=function(a,b,d){var c=mxUtils.bind(this,function(){this.loadingExtensions=!1;if("undefined"!==typeof window.LucidImporter){try{EditorUi.logEvent({category:"LUCIDCHART-IMPORT-FILE",action:"size_"+a.length}),EditorUi.debug("convertLucidChart",a)}catch(m){}try{b(LucidImporter.importState(JSON.parse(a)))}catch(m){null!=window.console&&
+console.error(m),d(m)}}else d({message:mxResources.get("serviceUnavailableOrBlocked")})});"undefined"!==typeof window.LucidImporter||this.loadingExtensions||this.isOffline(!0)?window.setTimeout(c,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("js/diagramly/Extensions.js",c):mxscript("js/extensions.min.js",c))};EditorUi.prototype.generateMermaidImage=function(a,b,d,e){var c=this,f=function(){try{this.loadingMermaid=!1,b=null!=b?b:EditorUi.defaultMermaidConfig,b.securityLevel="strict",b.startOnLoad=
!1,mermaid.mermaidAPI.initialize(b),mermaid.mermaidAPI.render("geMermaidOutput-"+(new Date).getTime(),a,function(a){try{if(mxClient.IS_IE||mxClient.IS_IE11)a=a.replace(/ xmlns:\S*="http:\/\/www.w3.org\/XML\/1998\/namespace"/g,"").replace(/ (NS xml|\S*):space="preserve"/g,' xml:space="preserve"');var b=mxUtils.parseXml(a).getElementsByTagName("svg");if(0<b.length){var f=parseFloat(b[0].getAttribute("width")),g=parseFloat(b[0].getAttribute("height"));d(c.convertDataUri(Editor.createSvgDataUri(a)),f,
g)}else e({message:mxResources.get("invalidInput")})}catch(B){e(B)}})}catch(v){e(v)}};"undefined"!==typeof mermaid||this.loadingMermaid||this.isOffline(!0)?f():(this.loadingMermaid=!0,"1"==urlParams.dev?mxscript("js/mermaid/mermaid.min.js",f):mxscript("js/extensions.min.js",f))};EditorUi.prototype.generatePlantUmlImage=function(a,b,d,e){function c(a,c,b){c1=a>>2;c2=(a&3)<<4|c>>4;c3=(c&15)<<2|b>>6;c4=b&63;r="";r+=f(c1&63);r+=f(c2&63);r+=f(c3&63);return r+=f(c4&63)}function f(a){if(10>a)return String.fromCharCode(48+
a);a-=10;if(26>a)return String.fromCharCode(65+a);a-=26;if(26>a)return String.fromCharCode(97+a);a-=26;return 0==a?"-":1==a?"_":"?"}var g=new XMLHttpRequest;g.open("GET",("txt"==b?PLANT_URL+"/txt/":"png"==b?PLANT_URL+"/png/":PLANT_URL+"/svg/")+function(a){r="";for(i=0;i<a.length;i+=3)r=i+2==a.length?r+c(a.charCodeAt(i),a.charCodeAt(i+1),0):i+1==a.length?r+c(a.charCodeAt(i),0,0):r+c(a.charCodeAt(i),a.charCodeAt(i+1),a.charCodeAt(i+2));return r}(pako.deflateRaw(a,{to:"string"})),!0);"txt"!=b&&(g.responseType=
-"blob");g.onload=function(a){if(200<=this.status&&300>this.status)if("txt"==b)d(this.response);else{var c=new FileReader;c.readAsDataURL(this.response);c.onloadend=function(a){var b=new Image;b.onload=function(){try{var a=b.width,f=b.height;if(0==a&&0==f){var g=c.result,l=g.indexOf(","),k=decodeURIComponent(escape(atob(g.substring(l+1)))),n=mxUtils.parseXml(k).getElementsByTagName("svg");0<n.length&&(a=parseFloat(n[0].getAttribute("width")),f=parseFloat(n[0].getAttribute("height")))}d(c.result,a,
-f)}catch(J){e(J)}};b.src=c.result};c.onerror=function(a){e(a)}}else e(a)};g.onerror=function(a){e(a)};g.send()};EditorUi.prototype.insertAsPreText=function(a,b,d){var c=this.editor.graph,f=null;c.getModel().beginUpdate();try{f=c.insertVertex(null,null,"<pre>"+a+"</pre>",b,d,1,1,"text;html=1;align=left;verticalAlign=top;"),c.updateCellSize(f,!0)}finally{c.getModel().endUpdate()}return f};EditorUi.prototype.insertTextAt=function(a,b,d,e,l,k,m){k=null!=k?k:!0;m=null!=m?m:!0;if(null!=a)if(Graph.fileSupport&&
-!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(a))this.parseFile(new Blob([a.replace(/\s+/g," ")],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&200<=a.status&&299>=a.status&&this.editor.graph.setSelectionCells(this.insertTextAt(a.responseText,b,d,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(l||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var c=this.editor.graph;if("data:application/pdf;base64,"==a.substring(0,28)){var f=
-Editor.extractGraphModelFromPdf(a);if(null!=f&&0<f.length)return this.importXml(f,b,d,k,!0)}if("data:image/png;base64,"==a.substring(0,22)&&(f=this.extractGraphModelFromPng(a),null!=f&&0<f.length))return this.importXml(f,b,d,k,!0);if("data:image/svg+xml;"==a.substring(0,19))try{f=null;"data:image/svg+xml;base64,"==a.substring(0,26)?(f=a.substring(a.indexOf(",")+1),f=window.atob&&!mxClient.IS_SF?atob(f):Base64.decode(f,!0)):f=decodeURIComponent(a.substring(a.indexOf(",")+1));var g=this.importXml(f,
-b,d,k,!0);if(0<g.length)return g}catch(D){}this.loadImage(a,mxUtils.bind(this,function(f){if("data:"==a.substring(0,5))this.resizeImage(f,a,mxUtils.bind(this,function(a,f,e){c.setSelectionCell(c.insertVertex(null,null,"",c.snap(b),c.snap(d),f,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+this.convertDataUri(a)+";"))}),m,this.maxImageSize);else{var e=Math.min(1,Math.min(this.maxImageSize/f.width,this.maxImageSize/f.height)),
+"blob");g.onload=function(a){if(200<=this.status&&300>this.status)if("txt"==b)d(this.response);else{var c=new FileReader;c.readAsDataURL(this.response);c.onloadend=function(a){var b=new Image;b.onload=function(){try{var a=b.width,f=b.height;if(0==a&&0==f){var g=c.result,m=g.indexOf(","),l=decodeURIComponent(escape(atob(g.substring(m+1)))),n=mxUtils.parseXml(l).getElementsByTagName("svg");0<n.length&&(a=parseFloat(n[0].getAttribute("width")),f=parseFloat(n[0].getAttribute("height")))}d(c.result,a,
+f)}catch(J){e(J)}};b.src=c.result};c.onerror=function(a){e(a)}}else e(a)};g.onerror=function(a){e(a)};g.send()};EditorUi.prototype.insertAsPreText=function(a,b,d){var c=this.editor.graph,f=null;c.getModel().beginUpdate();try{f=c.insertVertex(null,null,"<pre>"+a+"</pre>",b,d,1,1,"text;html=1;align=left;verticalAlign=top;"),c.updateCellSize(f,!0)}finally{c.getModel().endUpdate()}return f};EditorUi.prototype.insertTextAt=function(a,b,d,e,m,l,k){l=null!=l?l:!0;k=null!=k?k:!0;if(null!=a)if(Graph.fileSupport&&
+!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(a))this.parseFile(new Blob([a.replace(/\s+/g," ")],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&200<=a.status&&299>=a.status&&this.editor.graph.setSelectionCells(this.insertTextAt(a.responseText,b,d,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(m||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var c=this.editor.graph;if("data:application/pdf;base64,"==a.substring(0,28)){var f=
+Editor.extractGraphModelFromPdf(a);if(null!=f&&0<f.length)return this.importXml(f,b,d,l,!0)}if("data:image/png;base64,"==a.substring(0,22)&&(f=this.extractGraphModelFromPng(a),null!=f&&0<f.length))return this.importXml(f,b,d,l,!0);if("data:image/svg+xml;"==a.substring(0,19))try{f=null;"data:image/svg+xml;base64,"==a.substring(0,26)?(f=a.substring(a.indexOf(",")+1),f=window.atob&&!mxClient.IS_SF?atob(f):Base64.decode(f,!0)):f=decodeURIComponent(a.substring(a.indexOf(",")+1));var g=this.importXml(f,
+b,d,l,!0);if(0<g.length)return g}catch(D){}this.loadImage(a,mxUtils.bind(this,function(f){if("data:"==a.substring(0,5))this.resizeImage(f,a,mxUtils.bind(this,function(a,f,e){c.setSelectionCell(c.insertVertex(null,null,"",c.snap(b),c.snap(d),f,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+this.convertDataUri(a)+";"))}),k,this.maxImageSize);else{var e=Math.min(1,Math.min(this.maxImageSize/f.width,this.maxImageSize/f.height)),
g=Math.round(f.width*e);f=Math.round(f.height*e);c.setSelectionCell(c.insertVertex(null,null,"",c.snap(b),c.snap(d),g,f,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";"))}}),mxUtils.bind(this,function(){var f=null;c.getModel().beginUpdate();try{f=c.insertVertex(c.getDefaultParent(),null,a,c.snap(b),c.snap(d),1,1,"text;"+(e?"html=1;":"")),c.updateCellSize(f),c.fireEvent(new mxEventObject("textInserted","cells",[f]))}finally{c.getModel().endUpdate()}c.setSelectionCell(f)}))}else{a=
-Graph.zapGremlins(mxUtils.trim(a));if(this.isCompatibleString(a))return this.importXml(a,b,d,k);if(0<a.length)if(this.isLucidChartData(a))this.convertLucidChart(a,mxUtils.bind(this,function(c){this.editor.graph.setSelectionCells(this.importXml(c,b,d,k));!this.isOffline()&&(/.*\.diagrams\.net$/.test(window.location.hostname)||/.*\.appspot\.com$/.test(window.location.hostname)||/.*\.draw\.io$/.test(window.location.hostname))&&this.showBanner("LucidChartImportSurvey",mxResources.get("notSatisfiedWithImport"),
-mxUtils.bind(this,function(){var c=new FeedbackDialog(this,"Lucidchart Import Feedback",!0,a);this.showDialog(c.container,610,360,!0,!1);c.init()}))}),mxUtils.bind(this,function(a){this.handleError(a)}));else{c=this.editor.graph;l=null;c.getModel().beginUpdate();try{l=c.insertVertex(c.getDefaultParent(),null,"",c.snap(b),c.snap(d),1,1,"text;whiteSpace=wrap;"+(e?"html=1;":""));c.fireEvent(new mxEventObject("textInserted","cells",[l]));"<"==a.charAt(0)&&a.indexOf(">")==a.length-1&&(a=mxUtils.htmlEntities(a));
-a.length>this.maxTextBytes&&(a=a.substring(0,this.maxTextBytes)+"...");l.value=a;c.updateCellSize(l);if(0<this.maxTextWidth&&l.geometry.width>this.maxTextWidth){var n=c.getPreferredSizeForCell(l,this.maxTextWidth);l.geometry.width=n.width;l.geometry.height=n.height}Graph.isLink(l.value)&&c.setLinkForCell(l,l.value);l.geometry.width+=c.gridSize;l.geometry.height+=c.gridSize}finally{c.getModel().endUpdate()}return[l]}}return[]};EditorUi.prototype.formatFileSize=function(a){var c=-1;do a/=1024,c++;while(1024<
+Graph.zapGremlins(mxUtils.trim(a));if(this.isCompatibleString(a))return this.importXml(a,b,d,l);if(0<a.length)if(this.isLucidChartData(a))this.convertLucidChart(a,mxUtils.bind(this,function(c){this.editor.graph.setSelectionCells(this.importXml(c,b,d,l));!this.isOffline()&&(/.*\.diagrams\.net$/.test(window.location.hostname)||/.*\.appspot\.com$/.test(window.location.hostname)||/.*\.draw\.io$/.test(window.location.hostname))&&this.showBanner("LucidChartImportSurvey",mxResources.get("notSatisfiedWithImport"),
+mxUtils.bind(this,function(){var c=new FeedbackDialog(this,"Lucidchart Import Feedback",!0,a);this.showDialog(c.container,610,360,!0,!1);c.init()}))}),mxUtils.bind(this,function(a){this.handleError(a)}));else{c=this.editor.graph;m=null;c.getModel().beginUpdate();try{m=c.insertVertex(c.getDefaultParent(),null,"",c.snap(b),c.snap(d),1,1,"text;whiteSpace=wrap;"+(e?"html=1;":""));c.fireEvent(new mxEventObject("textInserted","cells",[m]));"<"==a.charAt(0)&&a.indexOf(">")==a.length-1&&(a=mxUtils.htmlEntities(a));
+a.length>this.maxTextBytes&&(a=a.substring(0,this.maxTextBytes)+"...");m.value=a;c.updateCellSize(m);if(0<this.maxTextWidth&&m.geometry.width>this.maxTextWidth){var n=c.getPreferredSizeForCell(m,this.maxTextWidth);m.geometry.width=n.width;m.geometry.height=n.height}Graph.isLink(m.value)&&c.setLinkForCell(m,m.value);m.geometry.width+=c.gridSize;m.geometry.height+=c.gridSize}finally{c.getModel().endUpdate()}return[m]}}return[]};EditorUi.prototype.formatFileSize=function(a){var c=-1;do a/=1024,c++;while(1024<
a);return Math.max(a,.1).toFixed(1)+" kB; MB; GB; TB;PB;EB;ZB;YB".split(";")[c]};EditorUi.prototype.convertDataUri=function(a){if("data:"==a.substring(0,5)){var c=a.indexOf(";");0<c&&(a=a.substring(0,c)+a.substring(a.indexOf(",",c+1)))}return a};EditorUi.prototype.isRemoteFileFormat=function(a,b){return/(\"contentType\":\s*\"application\/gliffy\+json\")/.test(a)};EditorUi.prototype.isLucidChartData=function(a){return null!=a&&('{"state":"{\\"Properties\\":'==a.substring(0,26)||'{"Properties":'==a.substring(0,
14))};EditorUi.prototype.importLocalFile=function(a,b){if(a&&Graph.fileSupport){if(null==this.importFileInputElt){var c=document.createElement("input");c.setAttribute("type","file");mxEvent.addListener(c,"change",mxUtils.bind(this,function(){null!=c.files&&(this.importFiles(c.files,null,null,this.maxImageSize),c.type="",c.type="file",c.value="")}));c.style.display="none";document.body.appendChild(c);this.importFileInputElt=c}this.importFileInputElt.click()}else{window.openNew=!1;window.openKey="import";
if(!b){var d=Editor.useLocalStorage;Editor.useLocalStorage=!a}window.openFile=new OpenFile(mxUtils.bind(this,function(a){this.hideDialog(a)}));window.openFile.setConsumer(mxUtils.bind(this,function(a,c){if(null!=c&&Graph.fileSupport&&/(\.v(dx|sdx?))($|\?)/i.test(c)){var b=new Blob([a],{type:"application/octet-stream"});this.importVisio(b,mxUtils.bind(this,function(a){this.importXml(a,0,0,!0)}),null,c)}else this.editor.graph.setSelectionCells(this.importXml(a,0,0,!0))}));this.showDialog((new OpenDialog(this)).container,
-360,220,!0,!0,function(){window.openFile=null});if(!b){var f=this.dialog,e=f.close;this.dialog.close=mxUtils.bind(this,function(a){Editor.useLocalStorage=d;e.apply(f,arguments);a&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()})}}};EditorUi.prototype.importZipFile=function(a,b,d){var c=this,f=mxUtils.bind(this,function(){this.loadingExtensions=!1;"undefined"!==typeof JSZip?JSZip.loadAsync(a).then(function(f){if(0==Object.keys(f.files).length)d();else{var e=0,g,l=!1;f.forEach(function(a,
-c){var f=c.name.toLowerCase();"diagram/diagram.xml"==f?(l=!0,c.async("string").then(function(a){0==a.indexOf("<mxfile ")?b(a):d()})):0==f.indexOf("versions/")&&(f=parseInt(f.substr(9)),f>e&&(e=f,g=c))});0<e?g.async("string").then(function(f){!c.isOffline()&&(new XMLHttpRequest).upload&&c.isRemoteFileFormat(f,a.name)?c.parseFile(new Blob([f],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&(200<=a.status&&299>=a.status?b(a.responseText):d())}),a.name):d()}):l||d()}},
-function(a){d(a)}):d()});"undefined"!==typeof JSZip||this.loadingExtensions||this.isOffline(!0)?f():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",f))};EditorUi.prototype.importFile=function(a,b,d,e,l,k,m,t,u,q,B){q=null!=q?q:!0;var c=!1,f=null,g=mxUtils.bind(this,function(a){var c=null;null!=a&&"<mxlibrary"==a.substring(0,10)?this.loadLibrary(new LocalLibrary(this,a,m)):c=this.importXml(a,d,e,q);null!=t&&t(c)});"image"==b.substring(0,5)?(u=!1,"image/png"==b.substring(0,9)&&(b=B?null:
-this.extractGraphModelFromPng(a),null!=b&&0<b.length&&(f=this.importXml(b,d,e,q),u=!0)),u||(b=this.editor.graph,B=a.indexOf(";"),0<B&&(a=a.substring(0,B)+a.substring(a.indexOf(",",B+1))),q&&b.isGridEnabled()&&(d=b.snap(d),e=b.snap(e)),f=[b.insertVertex(null,null,"",d,e,l,k,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";")])):/(\.*<graphml )/.test(a)?(c=!0,this.importGraphML(a,g)):null!=u&&null!=m&&(/(\.v(dx|sdx?))($|\?)/i.test(m)||
-/(\.vs(x|sx?))($|\?)/i.test(m))?(c=!0,this.importVisio(u,g)):!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(a,m)?(c=!0,this.parseFile(null!=u?u:new Blob([a],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&(200<=a.status&&299>=a.status?g(a.responseText):null!=t&&t(null))}),m)):0==a.indexOf("PK")&&null!=u?(c=!0,this.importZipFile(u,g,mxUtils.bind(this,function(){f=this.insertTextAt(this.validateFileData(a),d,e,!0,null,q);t(f)}))):/(\.v(sd|dx))($|\?)/i.test(m)||
-/(\.vs(s|x))($|\?)/i.test(m)||(f=this.insertTextAt(this.validateFileData(a),d,e,!0,null,q));c||null==t||t(f);return f};EditorUi.prototype.importFiles=function(a,b,d,e,l,k,m,t,u,q,B,D){e=null!=e?e:this.maxImageSize;q=null!=q?q:this.maxImageBytes;var c=null!=b&&null!=d,f=!0;b=null!=b?b:0;d=null!=d?d:0;var g=!1;if(!mxClient.IS_CHROMEAPP&&null!=a)for(var n=B||this.resampleThreshold,p=0;p<a.length;p++)if("image/"==a[p].type.substring(0,6)&&a[p].size>n){g=!0;break}var v=mxUtils.bind(this,function(){var g=
-this.editor.graph,n=g.gridSize;l=null!=l?l:mxUtils.bind(this,function(a,b,d,f,e,g,l,k,n){try{return null!=a&&"<mxlibrary"==a.substring(0,10)?(this.spinner.stop(),this.loadLibrary(new LocalLibrary(this,a,l)),null):this.importFile(a,b,d,f,e,g,l,k,n,c,D)}catch(V){return this.handleError(V),null}});k=null!=k?k:mxUtils.bind(this,function(a){g.setSelectionCells(a)});if(this.spinner.spin(document.body,mxResources.get("loading")))for(var p=a.length,u=p,v=[],x=mxUtils.bind(this,function(a,c){v[a]=c;if(0==
---u){this.spinner.stop();if(null!=t)t(v);else{var b=[];g.getModel().beginUpdate();try{for(var d=0;d<v.length;d++){var f=v[d]();null!=f&&(b=b.concat(f))}}finally{g.getModel().endUpdate()}}k(b)}}),F=0;F<p;F++)mxUtils.bind(this,function(c){var k=a[c];if(null!=k){var p=new FileReader;p.onload=mxUtils.bind(this,function(a){if(null==m||m(k))if("image/"==k.type.substring(0,6))if("image/svg"==k.type.substring(0,9)){var p=a.target.result,u=p.indexOf(","),t=decodeURIComponent(escape(atob(p.substring(u+1)))),
-v=mxUtils.parseXml(t),t=v.getElementsByTagName("svg");if(0<t.length){var t=t[0],z=D?null:t.getAttribute("content");null!=z&&"<"!=z.charAt(0)&&"%"!=z.charAt(0)&&(z=unescape(window.atob?atob(z):Base64.decode(z,!0)));null!=z&&"%"==z.charAt(0)&&(z=decodeURIComponent(z));null==z||"<mxfile "!==z.substring(0,8)&&"<mxGraphModel "!==z.substring(0,14)?x(c,mxUtils.bind(this,function(){try{if(p.substring(0,u+1),null!=v){var a=v.getElementsByTagName("svg");if(0<a.length){var f=a[0],m=f.getAttribute("width"),t=
-f.getAttribute("height"),m=null!=m&&"%"!=m.charAt(m.length-1)?parseFloat(m):NaN,t=null!=t&&"%"!=t.charAt(t.length-1)?parseFloat(t):NaN,q=f.getAttribute("viewBox");if(null==q||0==q.length)f.setAttribute("viewBox","0 0 "+m+" "+t);else if(isNaN(m)||isNaN(t)){var z=q.split(" ");3<z.length&&(m=parseFloat(z[2]),t=parseFloat(z[3]))}p=Editor.createSvgDataUri(mxUtils.getXml(f));var x=Math.min(1,Math.min(e/Math.max(1,m)),e/Math.max(1,t)),F=l(p,k.type,b+c*n,d+c*n,Math.max(1,Math.round(m*x)),Math.max(1,Math.round(t*
-x)),k.name);if(isNaN(m)||isNaN(t)){var y=new Image;y.onload=mxUtils.bind(this,function(){m=Math.max(1,y.width);t=Math.max(1,y.height);F[0].geometry.width=m;F[0].geometry.height=t;f.setAttribute("viewBox","0 0 "+m+" "+t);p=Editor.createSvgDataUri(mxUtils.getXml(f));var a=p.indexOf(";");0<a&&(p=p.substring(0,a)+p.substring(p.indexOf(",",a+1)));g.setCellStyles("image",p,[F[0]])});y.src=Editor.createSvgDataUri(mxUtils.getXml(f))}return F}}}catch(W){}return null})):x(c,mxUtils.bind(this,function(){return l(z,
-"text/xml",b+c*n,d+c*n,0,0,k.name)}))}else x(c,mxUtils.bind(this,function(){return null}))}else{t=!1;if("image/png"==k.type){var F=D?null:this.extractGraphModelFromPng(a.target.result);if(null!=F&&0<F.length){var y=new Image;y.src=a.target.result;x(c,mxUtils.bind(this,function(){return l(F,"text/xml",b+c*n,d+c*n,y.width,y.height,k.name)}));t=!0}}t||(mxClient.IS_CHROMEAPP?(this.spinner.stop(),this.showError(mxResources.get("error"),mxResources.get("dragAndDropNotSupported"),mxResources.get("cancel"),
-mxUtils.bind(this,function(){}),null,mxResources.get("ok"),mxUtils.bind(this,function(){this.actions.get("import").funct()}))):this.loadImage(a.target.result,mxUtils.bind(this,function(g){this.resizeImage(g,a.target.result,mxUtils.bind(this,function(g,m,p){x(c,mxUtils.bind(this,function(){if(null!=g&&g.length<q){var u=f&&this.isResampleImage(a.target.result,B)?Math.min(1,Math.min(e/m,e/p)):1;return l(g,k.type,b+c*n,d+c*n,Math.round(m*u),Math.round(p*u),k.name)}this.handleError({message:mxResources.get("imageTooBig")});
-return null}))}),f,e,B)}),mxUtils.bind(this,function(){this.handleError({message:mxResources.get("invalidOrMissingFile")})})))}else p=a.target.result,l(p,k.type,b+c*n,d+c*n,240,160,k.name,function(a){x(c,function(){return a})},k)});/(\.v(dx|sdx?))($|\?)/i.test(k.name)||/(\.vs(x|sx?))($|\?)/i.test(k.name)?l(null,k.type,b+c*n,d+c*n,240,160,k.name,function(a){x(c,function(){return a})},k):"image"==k.type.substring(0,5)||"application/pdf"==k.type?p.readAsDataURL(k):p.readAsText(k)}})(F)});if(g){g=[];
+360,220,!0,!0,function(){window.openFile=null});if(!b){var f=this.dialog,e=f.close;this.dialog.close=mxUtils.bind(this,function(a){Editor.useLocalStorage=d;e.apply(f,arguments);a&&null==this.getCurrentFile()&&"1"!=urlParams.embed&&this.showSplash()})}}};EditorUi.prototype.importZipFile=function(a,b,d){var c=this,f=mxUtils.bind(this,function(){this.loadingExtensions=!1;"undefined"!==typeof JSZip?JSZip.loadAsync(a).then(function(f){if(0==Object.keys(f.files).length)d();else{var e=0,g,m=!1;f.forEach(function(a,
+c){var f=c.name.toLowerCase();"diagram/diagram.xml"==f?(m=!0,c.async("string").then(function(a){0==a.indexOf("<mxfile ")?b(a):d()})):0==f.indexOf("versions/")&&(f=parseInt(f.substr(9)),f>e&&(e=f,g=c))});0<e?g.async("string").then(function(f){!c.isOffline()&&(new XMLHttpRequest).upload&&c.isRemoteFileFormat(f,a.name)?c.parseFile(new Blob([f],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&(200<=a.status&&299>=a.status?b(a.responseText):d())}),a.name):d()}):m||d()}},
+function(a){d(a)}):d()});"undefined"!==typeof JSZip||this.loadingExtensions||this.isOffline(!0)?f():(this.loadingExtensions=!0,mxscript("js/extensions.min.js",f))};EditorUi.prototype.importFile=function(a,b,d,e,m,l,k,t,u,q,B){q=null!=q?q:!0;var c=!1,f=null,g=mxUtils.bind(this,function(a){var c=null;null!=a&&"<mxlibrary"==a.substring(0,10)?this.loadLibrary(new LocalLibrary(this,a,k)):c=this.importXml(a,d,e,q);null!=t&&t(c)});"image"==b.substring(0,5)?(u=!1,"image/png"==b.substring(0,9)&&(b=B?null:
+this.extractGraphModelFromPng(a),null!=b&&0<b.length&&(f=this.importXml(b,d,e,q),u=!0)),u||(b=this.editor.graph,B=a.indexOf(";"),0<B&&(a=a.substring(0,B)+a.substring(a.indexOf(",",B+1))),q&&b.isGridEnabled()&&(d=b.snap(d),e=b.snap(e)),f=[b.insertVertex(null,null,"",d,e,m,l,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";")])):/(\.*<graphml )/.test(a)?(c=!0,this.importGraphML(a,g)):null!=u&&null!=k&&(/(\.v(dx|sdx?))($|\?)/i.test(k)||
+/(\.vs(x|sx?))($|\?)/i.test(k))?(c=!0,this.importVisio(u,g)):!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(a,k)?(c=!0,this.parseFile(null!=u?u:new Blob([a],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&(200<=a.status&&299>=a.status?g(a.responseText):null!=t&&t(null))}),k)):0==a.indexOf("PK")&&null!=u?(c=!0,this.importZipFile(u,g,mxUtils.bind(this,function(){f=this.insertTextAt(this.validateFileData(a),d,e,!0,null,q);t(f)}))):/(\.v(sd|dx))($|\?)/i.test(k)||
+/(\.vs(s|x))($|\?)/i.test(k)||(f=this.insertTextAt(this.validateFileData(a),d,e,!0,null,q));c||null==t||t(f);return f};EditorUi.prototype.importFiles=function(a,b,d,e,m,l,k,t,u,q,B,D){e=null!=e?e:this.maxImageSize;q=null!=q?q:this.maxImageBytes;var c=null!=b&&null!=d,f=!0;b=null!=b?b:0;d=null!=d?d:0;var g=!1;if(!mxClient.IS_CHROMEAPP&&null!=a)for(var n=B||this.resampleThreshold,p=0;p<a.length;p++)if("image/"==a[p].type.substring(0,6)&&a[p].size>n){g=!0;break}var v=mxUtils.bind(this,function(){var g=
+this.editor.graph,n=g.gridSize;m=null!=m?m:mxUtils.bind(this,function(a,b,d,f,e,g,m,l,n){try{return null!=a&&"<mxlibrary"==a.substring(0,10)?(this.spinner.stop(),this.loadLibrary(new LocalLibrary(this,a,m)),null):this.importFile(a,b,d,f,e,g,m,l,n,c,D)}catch(V){return this.handleError(V),null}});l=null!=l?l:mxUtils.bind(this,function(a){g.setSelectionCells(a)});if(this.spinner.spin(document.body,mxResources.get("loading")))for(var p=a.length,u=p,v=[],x=mxUtils.bind(this,function(a,c){v[a]=c;if(0==
+--u){this.spinner.stop();if(null!=t)t(v);else{var b=[];g.getModel().beginUpdate();try{for(var d=0;d<v.length;d++){var f=v[d]();null!=f&&(b=b.concat(f))}}finally{g.getModel().endUpdate()}}l(b)}}),F=0;F<p;F++)mxUtils.bind(this,function(c){var l=a[c];if(null!=l){var p=new FileReader;p.onload=mxUtils.bind(this,function(a){if(null==k||k(l))if("image/"==l.type.substring(0,6))if("image/svg"==l.type.substring(0,9)){var p=a.target.result,u=p.indexOf(","),t=decodeURIComponent(escape(atob(p.substring(u+1)))),
+v=mxUtils.parseXml(t),t=v.getElementsByTagName("svg");if(0<t.length){var t=t[0],z=D?null:t.getAttribute("content");null!=z&&"<"!=z.charAt(0)&&"%"!=z.charAt(0)&&(z=unescape(window.atob?atob(z):Base64.decode(z,!0)));null!=z&&"%"==z.charAt(0)&&(z=decodeURIComponent(z));null==z||"<mxfile "!==z.substring(0,8)&&"<mxGraphModel "!==z.substring(0,14)?x(c,mxUtils.bind(this,function(){try{if(p.substring(0,u+1),null!=v){var a=v.getElementsByTagName("svg");if(0<a.length){var f=a[0],k=f.getAttribute("width"),t=
+f.getAttribute("height"),k=null!=k&&"%"!=k.charAt(k.length-1)?parseFloat(k):NaN,t=null!=t&&"%"!=t.charAt(t.length-1)?parseFloat(t):NaN,q=f.getAttribute("viewBox");if(null==q||0==q.length)f.setAttribute("viewBox","0 0 "+k+" "+t);else if(isNaN(k)||isNaN(t)){var z=q.split(" ");3<z.length&&(k=parseFloat(z[2]),t=parseFloat(z[3]))}p=Editor.createSvgDataUri(mxUtils.getXml(f));var x=Math.min(1,Math.min(e/Math.max(1,k)),e/Math.max(1,t)),F=m(p,l.type,b+c*n,d+c*n,Math.max(1,Math.round(k*x)),Math.max(1,Math.round(t*
+x)),l.name);if(isNaN(k)||isNaN(t)){var y=new Image;y.onload=mxUtils.bind(this,function(){k=Math.max(1,y.width);t=Math.max(1,y.height);F[0].geometry.width=k;F[0].geometry.height=t;f.setAttribute("viewBox","0 0 "+k+" "+t);p=Editor.createSvgDataUri(mxUtils.getXml(f));var a=p.indexOf(";");0<a&&(p=p.substring(0,a)+p.substring(p.indexOf(",",a+1)));g.setCellStyles("image",p,[F[0]])});y.src=Editor.createSvgDataUri(mxUtils.getXml(f))}return F}}}catch(W){}return null})):x(c,mxUtils.bind(this,function(){return m(z,
+"text/xml",b+c*n,d+c*n,0,0,l.name)}))}else x(c,mxUtils.bind(this,function(){return null}))}else{t=!1;if("image/png"==l.type){var F=D?null:this.extractGraphModelFromPng(a.target.result);if(null!=F&&0<F.length){var y=new Image;y.src=a.target.result;x(c,mxUtils.bind(this,function(){return m(F,"text/xml",b+c*n,d+c*n,y.width,y.height,l.name)}));t=!0}}t||(mxClient.IS_CHROMEAPP?(this.spinner.stop(),this.showError(mxResources.get("error"),mxResources.get("dragAndDropNotSupported"),mxResources.get("cancel"),
+mxUtils.bind(this,function(){}),null,mxResources.get("ok"),mxUtils.bind(this,function(){this.actions.get("import").funct()}))):this.loadImage(a.target.result,mxUtils.bind(this,function(g){this.resizeImage(g,a.target.result,mxUtils.bind(this,function(g,k,p){x(c,mxUtils.bind(this,function(){if(null!=g&&g.length<q){var u=f&&this.isResampleImage(a.target.result,B)?Math.min(1,Math.min(e/k,e/p)):1;return m(g,l.type,b+c*n,d+c*n,Math.round(k*u),Math.round(p*u),l.name)}this.handleError({message:mxResources.get("imageTooBig")});
+return null}))}),f,e,B)}),mxUtils.bind(this,function(){this.handleError({message:mxResources.get("invalidOrMissingFile")})})))}else p=a.target.result,m(p,l.type,b+c*n,d+c*n,240,160,l.name,function(a){x(c,function(){return a})},l)});/(\.v(dx|sdx?))($|\?)/i.test(l.name)||/(\.vs(x|sx?))($|\?)/i.test(l.name)?m(null,l.type,b+c*n,d+c*n,240,160,l.name,function(a){x(c,function(){return a})},l):"image"==l.type.substring(0,5)||"application/pdf"==l.type?p.readAsDataURL(l):p.readAsText(l)}})(F)});if(g){g=[];
for(p=0;p<a.length;p++)g.push(a[p]);a=g;this.confirmImageResize(function(a){f=a;v()},u)}else v()};EditorUi.prototype.confirmImageResize=function(a,b){b=null!=b?b:!1;var c=null!=this.spinner&&null!=this.spinner.pause?this.spinner.pause():function(){},d=isLocalStorage||mxClient.IS_CHROMEAPP?mxSettings.getResizeImages():null,f=function(d,f){if(d||b)mxSettings.setResizeImages(d?f:null),mxSettings.save();c();a(f)};null==d||b?this.showDialog((new ConfirmDialog(this,mxResources.get("resizeLargeImages"),
function(a){f(a,!0)},function(a){f(a,!1)},mxResources.get("resize"),mxResources.get("actualSize"),'<img style="margin-top:8px;" src="'+Editor.loResImage+'"/>','<img style="margin-top:8px;" src="'+Editor.hiResImage+'"/>',isLocalStorage||mxClient.IS_CHROMEAPP)).container,340,isLocalStorage||mxClient.IS_CHROMEAPP?220:200,!0,!0):f(!1,d)};EditorUi.prototype.parseFile=function(a,b,d){d=null!=d?d:a.name;var c=new FormData;c.append("format","xml");c.append("upfile",a,d);var f=new XMLHttpRequest;f.open("POST",
-OPEN_URL);f.onreadystatechange=function(){b(f)};f.send(c);try{EditorUi.logEvent({category:"GLIFFY-IMPORT-FILE",action:"size_"+a.size})}catch(n){}};EditorUi.prototype.isResampleImage=function(a,b){b=null!=b?b:this.resampleThreshold;return a.length>b};EditorUi.prototype.resizeImage=function(a,b,d,e,l,k){l=null!=l?l:this.maxImageSize;var c=Math.max(1,a.width),f=Math.max(1,a.height);if(e&&this.isResampleImage(b,k))try{var g=Math.max(c/l,f/l);if(1<g){var m=Math.round(c/g),n=Math.round(f/g),p=document.createElement("canvas");
-p.width=m;p.height=n;p.getContext("2d").drawImage(a,0,0,m,n);var q=p.toDataURL();if(q.length<b.length){var x=document.createElement("canvas");x.width=m;x.height=n;var F=x.toDataURL();q!==F&&(b=q,c=m,f=n)}}}catch(G){}d(b,c,f)};EditorUi.prototype.extractGraphModelFromPng=function(a){return Editor.extractGraphModelFromPng(a)};EditorUi.prototype.loadImage=function(a,b,d){try{var c=new Image;c.onload=function(){c.width=0<c.width?c.width:120;c.height=0<c.height?c.height:120;b(c)};null!=d&&(c.onerror=d);
-c.src=a}catch(l){if(null!=d)d(l);else throw l;}};var d=EditorUi.prototype.init;EditorUi.prototype.init=function(){mxStencilRegistry.allowEval=mxStencilRegistry.allowEval&&!this.isOfflineApp();"undefined"!==typeof window.mxSettings&&(this.formatWidth=mxSettings.getFormatWidth());var a=this,b=this.editor.graph;b.cellEditor.editPlantUmlData=function(c,d,f){var e=JSON.parse(f);d=new TextareaDialog(a,mxResources.get("plantUml")+":",e.data,function(d){null!=d&&a.spinner.spin(document.body,mxResources.get("inserting"))&&
-a.generatePlantUmlImage(d,e.format,function(f,g,l){a.spinner.stop();b.getModel().beginUpdate();try{if("txt"==e.format)b.labelChanged(c,"<pre>"+f+"</pre>"),b.updateCellSize(c,!0);else{b.setCellStyles("image",a.convertDataUri(f),[c]);var k=b.model.getGeometry(c);null!=k&&(k=k.clone(),k.width=g,k.height=l,b.cellsResized([c],[k],!1))}b.setAttributeForCell(c,"plantUmlData",JSON.stringify({data:d,format:e.format}))}finally{b.getModel().endUpdate()}},function(c){a.handleError(c)})},null,null,400,220);a.showDialog(d.container,
-420,300,!0,!0);d.init()};b.cellEditor.editMermaidData=function(c,d,f){var e=JSON.parse(f);d=new TextareaDialog(a,mxResources.get("mermaid")+":",e.data,function(d){null!=d&&a.spinner.spin(document.body,mxResources.get("inserting"))&&a.generateMermaidImage(d,e.config,function(f,g,l){a.spinner.stop();b.getModel().beginUpdate();try{b.setCellStyles("image",f,[c]);var k=b.model.getGeometry(c);null!=k&&(k=k.clone(),k.width=Math.max(k.width,g),k.height=Math.max(k.height,l),b.cellsResized([c],[k],!1));b.setAttributeForCell(c,
+OPEN_URL);f.onreadystatechange=function(){b(f)};f.send(c);try{EditorUi.logEvent({category:"GLIFFY-IMPORT-FILE",action:"size_"+a.size})}catch(n){}};EditorUi.prototype.isResampleImage=function(a,b){b=null!=b?b:this.resampleThreshold;return a.length>b};EditorUi.prototype.resizeImage=function(a,b,d,e,m,l){m=null!=m?m:this.maxImageSize;var c=Math.max(1,a.width),f=Math.max(1,a.height);if(e&&this.isResampleImage(b,l))try{var g=Math.max(c/m,f/m);if(1<g){var k=Math.round(c/g),n=Math.round(f/g),p=document.createElement("canvas");
+p.width=k;p.height=n;p.getContext("2d").drawImage(a,0,0,k,n);var q=p.toDataURL();if(q.length<b.length){var x=document.createElement("canvas");x.width=k;x.height=n;var F=x.toDataURL();q!==F&&(b=q,c=k,f=n)}}}catch(G){}d(b,c,f)};EditorUi.prototype.extractGraphModelFromPng=function(a){return Editor.extractGraphModelFromPng(a)};EditorUi.prototype.loadImage=function(a,b,d){try{var c=new Image;c.onload=function(){c.width=0<c.width?c.width:120;c.height=0<c.height?c.height:120;b(c)};null!=d&&(c.onerror=d);
+c.src=a}catch(m){if(null!=d)d(m);else throw m;}};var d=EditorUi.prototype.init;EditorUi.prototype.init=function(){mxStencilRegistry.allowEval=mxStencilRegistry.allowEval&&!this.isOfflineApp();"undefined"!==typeof window.mxSettings&&(this.formatWidth=mxSettings.getFormatWidth());var a=this,b=this.editor.graph;b.cellEditor.editPlantUmlData=function(c,d,f){var e=JSON.parse(f);d=new TextareaDialog(a,mxResources.get("plantUml")+":",e.data,function(d){null!=d&&a.spinner.spin(document.body,mxResources.get("inserting"))&&
+a.generatePlantUmlImage(d,e.format,function(f,g,m){a.spinner.stop();b.getModel().beginUpdate();try{if("txt"==e.format)b.labelChanged(c,"<pre>"+f+"</pre>"),b.updateCellSize(c,!0);else{b.setCellStyles("image",a.convertDataUri(f),[c]);var l=b.model.getGeometry(c);null!=l&&(l=l.clone(),l.width=g,l.height=m,b.cellsResized([c],[l],!1))}b.setAttributeForCell(c,"plantUmlData",JSON.stringify({data:d,format:e.format}))}finally{b.getModel().endUpdate()}},function(c){a.handleError(c)})},null,null,400,220);a.showDialog(d.container,
+420,300,!0,!0);d.init()};b.cellEditor.editMermaidData=function(c,d,f){var e=JSON.parse(f);d=new TextareaDialog(a,mxResources.get("mermaid")+":",e.data,function(d){null!=d&&a.spinner.spin(document.body,mxResources.get("inserting"))&&a.generateMermaidImage(d,e.config,function(f,g,m){a.spinner.stop();b.getModel().beginUpdate();try{b.setCellStyles("image",f,[c]);var l=b.model.getGeometry(c);null!=l&&(l=l.clone(),l.width=Math.max(l.width,g),l.height=Math.max(l.height,m),b.cellsResized([c],[l],!1));b.setAttributeForCell(c,
"mermaidData",JSON.stringify({data:d,config:e.config},null,2))}finally{b.getModel().endUpdate()}},function(c){a.handleError(c)})},null,null,400,220);a.showDialog(d.container,420,300,!0,!0);d.init()};var e=b.cellEditor.startEditing;b.cellEditor.startEditing=function(c,b){try{var d=this.graph.getAttributeForCell(c,"plantUmlData");null!=d?this.editPlantUmlData(c,b,d):(d=this.graph.getAttributeForCell(c,"mermaidData"),null!=d?this.editMermaidData(c,b,d):e.apply(this,arguments))}catch(G){a.handleError(G)}};
-b.getLinkTitle=function(c){return a.getLinkTitle(c)};b.customLinkClicked=function(c){var b=!1;try{a.handleCustomLink(c),b=!0}catch(F){a.handleError(F)}return b};var k=this.clearDefaultStyle;this.clearDefaultStyle=function(){k.apply(this,arguments)};this.isOffline()||"undefined"===typeof window.EditDataDialog||(EditDataDialog.placeholderHelpLink="https://desk.draw.io/support/solutions/articles/16000051979");var l=a.editor.getEditBlankUrl;this.editor.getEditBlankUrl=function(c){c=null!=c?c:"";if(null!=
-a.pages&&null!=a.currentPage)for(var b=0;b<a.pages.length;b++)if(a.pages[b]==a.currentPage){0<b&&(c+=(0<c.length?"&":"?")+"page="+b);break}"1"==urlParams.dev&&(c+=(0<c.length?"&":"?")+"dev=1&drawdev=1");return l.apply(this,arguments)};var m=b.addClickHandler;b.addClickHandler=function(a,c,d){var f=c;c=function(a,c){if(null==c){var d=mxEvent.getSource(a);"a"==d.nodeName.toLowerCase()&&(c=d.getAttribute("href"))}null!=c&&b.isCustomLink(c)&&(mxEvent.isTouchEvent(a)||!mxEvent.isPopupTrigger(a))&&b.customLinkClicked(c)&&
-mxEvent.consume(a);null!=f&&f(a,c)};m.call(this,a,c,d)};d.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(b.view.canvas.ownerSVGElement,null,!0);a.actions.get("print").funct=function(){a.showDialog((new PrintDialog(a)).container,360,null!=a.pages&&1<a.pages.length?450:370,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var q=b.getExportVariables;b.getExportVariables=function(){var c=q.apply(this,arguments),b=a.getCurrentFile();null!=b&&(c.filename=b.getTitle());
+b.getLinkTitle=function(c){return a.getLinkTitle(c)};b.customLinkClicked=function(c){var b=!1;try{a.handleCustomLink(c),b=!0}catch(F){a.handleError(F)}return b};var l=this.clearDefaultStyle;this.clearDefaultStyle=function(){l.apply(this,arguments)};this.isOffline()||"undefined"===typeof window.EditDataDialog||(EditDataDialog.placeholderHelpLink="https://desk.draw.io/support/solutions/articles/16000051979");var m=a.editor.getEditBlankUrl;this.editor.getEditBlankUrl=function(c){c=null!=c?c:"";if(null!=
+a.pages&&null!=a.currentPage)for(var b=0;b<a.pages.length;b++)if(a.pages[b]==a.currentPage){0<b&&(c+=(0<c.length?"&":"?")+"page="+b);break}"1"==urlParams.dev&&(c+=(0<c.length?"&":"?")+"dev=1&drawdev=1");return m.apply(this,arguments)};var k=b.addClickHandler;b.addClickHandler=function(a,c,d){var f=c;c=function(a,c){if(null==c){var d=mxEvent.getSource(a);"a"==d.nodeName.toLowerCase()&&(c=d.getAttribute("href"))}null!=c&&b.isCustomLink(c)&&(mxEvent.isTouchEvent(a)||!mxEvent.isPopupTrigger(a))&&b.customLinkClicked(c)&&
+mxEvent.consume(a);null!=f&&f(a,c)};k.call(this,a,c,d)};d.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(b.view.canvas.ownerSVGElement,null,!0);a.actions.get("print").funct=function(){a.showDialog((new PrintDialog(a)).container,360,null!=a.pages&&1<a.pages.length?450:370,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var q=b.getExportVariables;b.getExportVariables=function(){var c=q.apply(this,arguments),b=a.getCurrentFile();null!=b&&(c.filename=b.getTitle());
c.pagecount=null!=a.pages?a.pages.length:1;c.page=null!=a.currentPage?a.currentPage.getName():"";c.pagenumber=null!=a.pages&&null!=a.currentPage?mxUtils.indexOf(a.pages,a.currentPage)+1:1;return c};var t=b.getGlobalVariable;b.getGlobalVariable=function(c){var b=a.getCurrentFile();return"filename"==c&&null!=b?b.getTitle():"page"==c&&null!=a.currentPage?a.currentPage.getName():"pagenumber"==c?null!=a.currentPage&&null!=a.pages?mxUtils.indexOf(a.pages,a.currentPage)+1:1:"pagecount"==c?null!=a.pages?
a.pages.length:1:t.apply(this,arguments)};var u=b.labelLinkClicked;b.labelLinkClicked=function(a,c,d){var f=c.getAttribute("href");if(null==f||!b.isCustomLink(f)||!mxEvent.isTouchEvent(d)&&mxEvent.isPopupTrigger(d))u.apply(this,arguments);else{if(!b.isEnabled()||null!=a&&b.isCellLocked(a.cell))b.customLinkClicked(f),b.getRubberband().reset();mxEvent.consume(d)}};this.editor.getOrCreateFilename=function(){var c=a.defaultFilename,b=a.getCurrentFile();null!=b&&(c=null!=b.getTitle()?b.getTitle():c);return c};
var A=this.actions.get("print");A.setEnabled(!mxClient.IS_IOS||!navigator.standalone);A.visible=A.isEnabled();if(!this.editor.chromeless||this.editor.editable)this.keyHandler.bindAction(70,!0,"find"),this.keyHandler.bindAction(67,!0,"copyStyle",!0),this.keyHandler.bindAction(86,!0,"pasteStyle",!0),this.keyHandler.bindAction(77,!0,"editGeometry",!0),this.keyHandler.bindAction(88,!0,"insertText",!0),this.keyHandler.bindAction(75,!0,"insertRectangle"),this.keyHandler.bindAction(75,!0,"insertEllipse",
@@ -3301,17 +3301,17 @@ A.setUnit(mxSettings.getUnit()),A.addListener("unitChanged",function(a,c){mxSett
"text"),this.styleInput.style.position="absolute",this.styleInput.style.top="14px",this.styleInput.style.left="2px",this.styleInput.style.width="98%",this.styleInput.style.visibility="hidden",this.styleInput.style.opacity="0.9",mxEvent.addListener(this.styleInput,"change",mxUtils.bind(this,function(){this.editor.graph.getModel().setStyle(this.editor.graph.getSelectionCell(),this.styleInput.value)})),A.appendChild(this.styleInput),this.editor.graph.getSelectionModel().addListener(mxEvent.CHANGE,mxUtils.bind(this,
function(a,c){if(0<this.editor.graph.getSelectionCount()){var b=this.editor.graph.getSelectionCell(),b=this.editor.graph.getModel().getStyle(b);this.styleInput.value=b||"";this.styleInput.style.visibility="visible"}else this.styleInput.style.visibility="hidden"})));var B=this.isSelectionAllowed;this.isSelectionAllowed=function(a){return mxEvent.getSource(a)==this.styleInput?!0:B.apply(this,arguments)}}A=document.getElementById("geInfo");null!=A&&A.parentNode.removeChild(A);if(Graph.fileSupport&&(!this.editor.chromeless||
this.editor.editable)){var D=null;mxEvent.addListener(b.container,"dragleave",function(a){b.isEnabled()&&(null!=D&&(D.parentNode.removeChild(D),D=null),a.stopPropagation(),a.preventDefault())});mxEvent.addListener(b.container,"dragover",mxUtils.bind(this,function(a){null==D&&(!mxClient.IS_IE||10<document.documentMode)&&(D=this.highlightElement(b.container));null!=this.sidebar&&this.sidebar.hideTooltip();a.stopPropagation();a.preventDefault()}));mxEvent.addListener(b.container,"drop",mxUtils.bind(this,
-function(a){null!=D&&(D.parentNode.removeChild(D),D=null);if(b.isEnabled()){var c=mxUtils.convertPoint(b.container,mxEvent.getClientX(a),mxEvent.getClientY(a)),d=b.view.translate,f=b.view.scale,e=c.x/f-d.x,g=c.y/f-d.y;if(0<a.dataTransfer.files.length)mxEvent.isAltDown(a)&&(g=e=null),this.importFiles(a.dataTransfer.files,e,g,this.maxImageSize,null,null,null,null,mxEvent.isControlDown(a),null,null,mxEvent.isShiftDown(a));else{mxEvent.isAltDown(a)&&(g=e=0);var l=0<=mxUtils.indexOf(a.dataTransfer.types,
-"text/uri-list")?a.dataTransfer.getData("text/uri-list"):null,c=this.extractGraphModelFromEvent(a,null!=this.pages);if(null!=c)b.setSelectionCells(this.importXml(c,e,g,!0));else if(0<=mxUtils.indexOf(a.dataTransfer.types,"text/html")){var k=a.dataTransfer.getData("text/html"),c=document.createElement("div");c.innerHTML=k;var m=null,d=c.getElementsByTagName("img");null!=d&&1==d.length?(k=d[0].getAttribute("src"),/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(k)||(m=!0)):(d=c.getElementsByTagName("a"),null!=
-d&&1==d.length?k=d[0].getAttribute("href"):(c=c.getElementsByTagName("pre"),null!=c&&1==c.length&&(k=mxUtils.getTextContent(c[0]))));var n=!0,p=mxUtils.bind(this,function(){b.setSelectionCells(this.insertTextAt(k,e,g,!0,m,null,n))});m&&k.length>this.resampleThreshold?this.confirmImageResize(function(a){n=a;p()},mxEvent.isControlDown(a)):p()}else null!=l&&/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(l)?this.loadImage(decodeURIComponent(l),mxUtils.bind(this,function(a){var c=Math.max(1,a.width);a=Math.max(1,
-a.height);var d=this.maxImageSize,d=Math.min(1,Math.min(d/Math.max(1,c)),d/Math.max(1,a));b.setSelectionCell(b.insertVertex(null,null,"",e,g,c*d,a*d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+l+";"))}),mxUtils.bind(this,function(a){b.setSelectionCells(this.insertTextAt(l,e,g,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&b.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),e,g,!0))}}a.stopPropagation();
-a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode();this.installSettings()};EditorUi.prototype.installImagePasteHandler=function(){if(!mxClient.IS_IE){var a=this.editor.graph;a.container.addEventListener("paste",mxUtils.bind(this,function(c){if(!mxEvent.isConsumed(c))try{for(var b=c.clipboardData||c.originalEvent.clipboardData,d=!1,f=0;f<b.types.length;f++)if("text/"===b.types[f].substring(0,5)){d=!0;break}if(!d){var e=b.items;for(index in e){var k=e[index];
-if("file"===k.kind){if(a.isEditing())this.importFiles([k.getAsFile()],0,0,this.maxImageSize,function(c,b,d,f,e,g){a.insertImage(c,e,g)},function(){},function(a){return"image/"==a.type.substring(0,6)},function(a){for(var c=0;c<a.length;c++)a[c]()});else{var m=this.editor.graph.getInsertPoint();this.importFiles([k.getAsFile()],m.x,m.y,this.maxImageSize);mxEvent.consume(c)}break}}}}catch(u){}}),!1)}};EditorUi.prototype.installNativeClipboardHandler=function(){function a(){window.setTimeout(function(){d.innerHTML=
+function(a){null!=D&&(D.parentNode.removeChild(D),D=null);if(b.isEnabled()){var c=mxUtils.convertPoint(b.container,mxEvent.getClientX(a),mxEvent.getClientY(a)),d=b.view.translate,f=b.view.scale,e=c.x/f-d.x,g=c.y/f-d.y;if(0<a.dataTransfer.files.length)mxEvent.isAltDown(a)&&(g=e=null),this.importFiles(a.dataTransfer.files,e,g,this.maxImageSize,null,null,null,null,mxEvent.isControlDown(a),null,null,mxEvent.isShiftDown(a));else{mxEvent.isAltDown(a)&&(g=e=0);var m=0<=mxUtils.indexOf(a.dataTransfer.types,
+"text/uri-list")?a.dataTransfer.getData("text/uri-list"):null,c=this.extractGraphModelFromEvent(a,null!=this.pages);if(null!=c)b.setSelectionCells(this.importXml(c,e,g,!0));else if(0<=mxUtils.indexOf(a.dataTransfer.types,"text/html")){var l=a.dataTransfer.getData("text/html"),c=document.createElement("div");c.innerHTML=l;var k=null,d=c.getElementsByTagName("img");null!=d&&1==d.length?(l=d[0].getAttribute("src"),/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(l)||(k=!0)):(d=c.getElementsByTagName("a"),null!=
+d&&1==d.length?l=d[0].getAttribute("href"):(c=c.getElementsByTagName("pre"),null!=c&&1==c.length&&(l=mxUtils.getTextContent(c[0]))));var n=!0,p=mxUtils.bind(this,function(){b.setSelectionCells(this.insertTextAt(l,e,g,!0,k,null,n))});k&&l.length>this.resampleThreshold?this.confirmImageResize(function(a){n=a;p()},mxEvent.isControlDown(a)):p()}else null!=m&&/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(m)?this.loadImage(decodeURIComponent(m),mxUtils.bind(this,function(a){var c=Math.max(1,a.width);a=Math.max(1,
+a.height);var d=this.maxImageSize,d=Math.min(1,Math.min(d/Math.max(1,c)),d/Math.max(1,a));b.setSelectionCell(b.insertVertex(null,null,"",e,g,c*d,a*d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+m+";"))}),mxUtils.bind(this,function(a){b.setSelectionCells(this.insertTextAt(m,e,g,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&b.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),e,g,!0))}}a.stopPropagation();
+a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode();this.installSettings()};EditorUi.prototype.installImagePasteHandler=function(){if(!mxClient.IS_IE){var a=this.editor.graph;a.container.addEventListener("paste",mxUtils.bind(this,function(c){if(!mxEvent.isConsumed(c))try{for(var b=c.clipboardData||c.originalEvent.clipboardData,d=!1,f=0;f<b.types.length;f++)if("text/"===b.types[f].substring(0,5)){d=!0;break}if(!d){var e=b.items;for(index in e){var l=e[index];
+if("file"===l.kind){if(a.isEditing())this.importFiles([l.getAsFile()],0,0,this.maxImageSize,function(c,b,d,f,e,g){a.insertImage(c,e,g)},function(){},function(a){return"image/"==a.type.substring(0,6)},function(a){for(var c=0;c<a.length;c++)a[c]()});else{var k=this.editor.graph.getInsertPoint();this.importFiles([l.getAsFile()],k.x,k.y,this.maxImageSize);mxEvent.consume(c)}break}}}}catch(u){}}),!1)}};EditorUi.prototype.installNativeClipboardHandler=function(){function a(){window.setTimeout(function(){d.innerHTML=
"&nbsp;";d.focus();document.execCommand("selectAll",!1,null)},0)}var b=this.editor.graph,d=document.createElement("div");d.setAttribute("autocomplete","off");d.setAttribute("autocorrect","off");d.setAttribute("autocapitalize","off");d.setAttribute("spellcheck","false");d.style.textRendering="optimizeSpeed";d.style.fontFamily="monospace";d.style.wordBreak="break-all";d.style.background="transparent";d.style.color="transparent";d.style.position="absolute";d.style.whiteSpace="nowrap";d.style.overflow=
"hidden";d.style.display="block";d.style.fontSize="1";d.style.zIndex="-1";d.style.resize="none";d.style.outline="none";d.style.width="1px";d.style.height="1px";mxUtils.setOpacity(d,0);d.contentEditable=!0;d.innerHTML="&nbsp;";var e=!1;this.keyHandler.bindControlKey(88,null);this.keyHandler.bindControlKey(67,null);this.keyHandler.bindControlKey(86,null);mxEvent.addListener(document,"keydown",mxUtils.bind(this,function(a){var c=mxEvent.getSource(a);null==b.container||!b.isEnabled()||b.isMouseDown||
b.isEditing()||null!=this.dialog||"INPUT"==c.nodeName||"TEXTAREA"==c.nodeName||!(224==a.keyCode||!mxClient.IS_MAC&&17==a.keyCode||mxClient.IS_MAC&&91==a.keyCode)||e||(d.style.left=b.container.scrollLeft+10+"px",d.style.top=b.container.scrollTop+10+"px",b.container.appendChild(d),e=!0,mxClient.IS_QUIRKS?window.setTimeout(function(){d.focus();document.execCommand("selectAll",!1,null)},0):(d.focus(),document.execCommand("selectAll",!1,null)))}));mxEvent.addListener(document,"keyup",mxUtils.bind(this,
function(a){var c=a.keyCode;window.setTimeout(mxUtils.bind(this,function(){!e||224!=c&&17!=c&&91!=c||(e=!1,b.isEditing()||null!=this.dialog||null==b.container||b.container.focus(),d.parentNode.removeChild(d),null==this.dialog&&mxUtils.clearSelection())}),0)}));mxEvent.addListener(d,"copy",mxUtils.bind(this,function(c){if(b.isEnabled())try{mxClipboard.copy(b),this.copyCells(d),a()}catch(v){this.handleError(v)}}));mxEvent.addListener(d,"cut",mxUtils.bind(this,function(c){if(b.isEnabled())try{mxClipboard.copy(b),
-this.copyCells(d,!0),a()}catch(v){this.handleError(v)}}));mxEvent.addListener(d,"paste",mxUtils.bind(this,function(a){b.isEnabled()&&!b.isCellLocked(b.getDefaultParent())&&((new Date).getTime(),d.innerHTML="&nbsp;",d.focus(),null!=a.clipboardData&&this.pasteCells(a,d,!0,!0),mxEvent.isConsumed(a)||window.setTimeout(mxUtils.bind(this,function(){this.pasteCells(a,d,!1,!0)}),0))}),!0);var l=this.isSelectionAllowed;this.isSelectionAllowed=function(a){return mxEvent.getSource(a)==d?!0:l.apply(this,arguments)}};
+this.copyCells(d,!0),a()}catch(v){this.handleError(v)}}));mxEvent.addListener(d,"paste",mxUtils.bind(this,function(a){b.isEnabled()&&!b.isCellLocked(b.getDefaultParent())&&((new Date).getTime(),d.innerHTML="&nbsp;",d.focus(),null!=a.clipboardData&&this.pasteCells(a,d,!0,!0),mxEvent.isConsumed(a)||window.setTimeout(mxUtils.bind(this,function(){this.pasteCells(a,d,!1,!0)}),0))}),!0);var m=this.isSelectionAllowed;this.isSelectionAllowed=function(a){return mxEvent.getSource(a)==d?!0:m.apply(this,arguments)}};
EditorUi.prototype.getLinkTitle=function(a){var c=Graph.prototype.getLinkTitle.apply(this,arguments);if("data:page/id,"==a.substring(0,13)){var b=a.indexOf(",");0<b&&(c=this.getPageById(a.substring(b+1)),c=null!=c?c.getName():mxResources.get("pageNotFound"))}else"data:"==a.substring(0,5)&&(c=mxResources.get("action"));return c};EditorUi.prototype.handleCustomLink=function(a){if("data:page/id,"==a.substring(0,13)){var c=a.indexOf(",");if(a=this.getPageById(a.substring(c+1)))this.selectPage(a);else throw Error(mxResources.get("pageNotFound")||
"Page not found");}else this.editor.graph.handleCustomLink(a)};EditorUi.prototype.isSettingsEnabled=function(){return"undefined"!==typeof window.mxSettings&&(isLocalStorage||mxClient.IS_CHROMEAPP)};EditorUi.prototype.installSettings=function(){if(this.isSettingsEnabled()){ColorDialog.recentColors=mxSettings.getRecentColors();if(isLocalStorage)try{window.addEventListener("storage",mxUtils.bind(this,function(a){a.key==mxSettings.key&&(mxSettings.load(),ColorDialog.recentColors=mxSettings.getRecentColors(),
this.menus.customFonts=mxSettings.getCustomFonts())}),!1)}catch(c){}this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[]));this.menus.customFonts=mxSettings.getCustomFonts();this.addListener("customFontsChanged",mxUtils.bind(this,function(a,b){var c=b.getProperty("customFonts");this.menus.customFonts=c;mxSettings.setCustomFonts(c);mxSettings.save()}));this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget());this.fireEvent(new mxEventObject("copyConnectChanged"));
@@ -3321,15 +3321,15 @@ function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor,"dark"==u
null):(c.lastPasteXml=f,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=function(a,b,d,e){if(!mxEvent.isConsumed(a)){var c=b,f=!1;if(d&&null!=a.clipboardData&&a.clipboardData.getData){var g=a.clipboardData.getData("text/html");if(null!=g&&0<g.length){c=document.createElement("div");c.innerHTML=g;f=!0;g=c.getElementsByTagName("style");if(null!=g)for(;0<g.length;)g[0].parentNode.removeChild(g[0]);null!=c.firstChild&&c.firstChild.nodeType==mxConstants.NODETYPE_ELEMENT&&
null!=c.firstChild.nextSibling&&c.firstChild.nextSibling.nodeType==mxConstants.NODETYPE_ELEMENT&&"META"==c.firstChild.nodeName&&"A"==c.firstChild.nextSibling.nodeName&&null==c.firstChild.nextSibling.nextSibling&&(g=null==c.firstChild.nextSibling.innerText?mxUtils.getTextContent(c.firstChild.nextSibling):c.firstChild.nextSibling.innerText,g==c.firstChild.nextSibling.getAttribute("href")&&(mxUtils.setTextContent(c,g),f=!1));Graph.removePasteFormatting(c)}else g=a.clipboardData.getData("text/plain"),
null!=g&&0<g.length&&(c=document.createElement("div"),mxUtils.setTextContent(c,g))}g=c.getElementsByTagName("span");if(null!=g&&0<g.length&&"application/vnd.lucid.chart.objects"===g[0].getAttribute("data-lucid-type"))d=g[0].getAttribute("data-lucid-content"),null!=d&&0<d.length&&(this.convertLucidChart(d,mxUtils.bind(this,function(a){var c=this.editor.graph;c.lastPasteXml==a?c.pasteCounter++:(c.lastPasteXml=a,c.pasteCounter=0);var b=c.pasteCounter*c.gridSize;c.setSelectionCells(this.importXml(a,b,
-b));c.scrollCellToVisible(c.getSelectionCell())}),mxUtils.bind(this,function(a){this.handleError(a)})),mxEvent.consume(a));else{var f=f?c.innerHTML:mxUtils.trim(null==c.innerText?mxUtils.getTextContent(c):c.innerText),k=!1;try{var m=f.lastIndexOf("%3E");0<=m&&m<f.length-3&&(f=f.substring(0,m+3))}catch(x){}try{var g=c.getElementsByTagName("span"),p=null!=g&&0<g.length?mxUtils.trim(decodeURIComponent(g[0].textContent)):decodeURIComponent(f);this.isCompatibleString(p)&&(k=!0,f=p)}catch(x){}try{var q=
-this.editor.graph;if(null!=f&&0<f.length){q.lastPasteXml==f?q.pasteCounter++:(q.lastPasteXml=f,q.pasteCounter=0);var D=q.pasteCounter*q.gridSize;if(k||this.isCompatibleString(f))q.setSelectionCells(this.importXml(f,D,D));else if(e&&1==q.getSelectionCount())q.labelChanged(q.getSelectionCell(),f),Graph.isLink(f)&&q.setLinkForCell(q.getSelectionCell(),f);else{var C=q.getInsertPoint();q.isMouseInsertPoint()&&(D=0,q.lastPasteXml==f&&0<q.pasteCounter&&q.pasteCounter--);q.setSelectionCells(this.insertTextAt(f,
+b));c.scrollCellToVisible(c.getSelectionCell())}),mxUtils.bind(this,function(a){this.handleError(a)})),mxEvent.consume(a));else{var f=f?c.innerHTML:mxUtils.trim(null==c.innerText?mxUtils.getTextContent(c):c.innerText),l=!1;try{var k=f.lastIndexOf("%3E");0<=k&&k<f.length-3&&(f=f.substring(0,k+3))}catch(x){}try{var g=c.getElementsByTagName("span"),p=null!=g&&0<g.length?mxUtils.trim(decodeURIComponent(g[0].textContent)):decodeURIComponent(f);this.isCompatibleString(p)&&(l=!0,f=p)}catch(x){}try{var q=
+this.editor.graph;if(null!=f&&0<f.length){q.lastPasteXml==f?q.pasteCounter++:(q.lastPasteXml=f,q.pasteCounter=0);var D=q.pasteCounter*q.gridSize;if(l||this.isCompatibleString(f))q.setSelectionCells(this.importXml(f,D,D));else if(e&&1==q.getSelectionCount())q.labelChanged(q.getSelectionCell(),f),Graph.isLink(f)&&q.setLinkForCell(q.getSelectionCell(),f);else{var C=q.getInsertPoint();q.isMouseInsertPoint()&&(D=0,q.lastPasteXml==f&&0<q.pasteCounter&&q.pasteCounter--);q.setSelectionCells(this.insertTextAt(f,
C.x+D,C.y+D,!0))}q.isSelectionEmpty()||(q.scrollCellToVisible(q.getSelectionCell()),null!=this.hoverIcons&&this.hoverIcons.update(q.view.getState(q.getSelectionCell())));try{mxEvent.consume(a)}catch(x){}}else d||(q.lastPasteXml=null,q.pasteCounter=0)}catch(x){this.handleError(x)}}}b.innerHTML="&nbsp;"};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var c=null,b=0;b<a.length;b++)mxEvent.addListener(a[b],"dragleave",function(a){null!=c&&(c.parentNode.removeChild(c),c=null);
a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[b],"dragover",mxUtils.bind(this,function(a){(this.editor.graph.isEnabled()||"1"!=urlParams.embed)&&null==c&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(c=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[b],"drop",mxUtils.bind(this,function(a){null!=c&&(c.parentNode.removeChild(c),c=null);if(this.editor.graph.isEnabled()||"1"!=urlParams.embed)if(0<a.dataTransfer.files.length)this.hideDialog(),
"1"==urlParams.embed?this.importFiles(a.dataTransfer.files,0,0,this.maxImageSize,null,null,null,null,!mxEvent.isControlDown(a)&&!mxEvent.isShiftDown(a)):this.openFiles(a.dataTransfer.files,!0);else{var b=this.extractGraphModelFromEvent(a);if(null==b){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?b=d.getData("Text"):(b=null,b=0<=mxUtils.indexOf(d.types,"text/uri-list")?a.dataTransfer.getData("text/uri-list"):0<=mxUtils.indexOf(d.types,
"text/html")?d.getData("text/html"):null,null!=b&&0<b.length?(d=document.createElement("div"),d.innerHTML=b,d=d.getElementsByTagName("img"),0<d.length&&(b=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(b=d.getData("text/plain"))),null!=b&&("data:image/png;base64,"==b.substring(0,22)?(b=this.extractGraphModelFromPng(b),null!=b&&0<b.length&&this.openLocalFile(b,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(b)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(b))).send(mxUtils.bind(this,
function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(b)&&(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(b):window.openWindow((mxClient.IS_CHROMEAPP?EditorUi.drawHost+"/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(b)))))}else this.openLocalFile(b,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var c=0,b=0,d,e;if(null==a){e=document.body;
-var k=document.documentElement;d=(e.clientWidth||k.clientWidth)-3;e=Math.max(e.clientHeight||0,k.clientHeight)-3}else c=a.offsetTop,b=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;k=document.createElement("div");k.style.zIndex=mxPopupMenu.prototype.zIndex+2;k.style.border="3px dotted rgb(254, 137, 12)";k.style.pointerEvents="none";k.style.position="absolute";k.style.top=c+"px";k.style.left=b+"px";k.style.width=Math.max(0,d-3)+"px";k.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?
-this.editor.graph.container.appendChild(k):document.body.appendChild(k);return k};EditorUi.prototype.stringToCells=function(a){a=mxUtils.parseXml(a);var c=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=c){var b=new mxCodec(c.ownerDocument),d=new mxGraphModel;b.decode(c,d);c=d.getChildAt(d.getRoot(),0);for(b=0;b<d.getChildCount(c);b++)a.push(d.getChildAt(c,b))}return a};EditorUi.prototype.openFiles=function(a,b){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var c=
+var l=document.documentElement;d=(e.clientWidth||l.clientWidth)-3;e=Math.max(e.clientHeight||0,l.clientHeight)-3}else c=a.offsetTop,b=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;l=document.createElement("div");l.style.zIndex=mxPopupMenu.prototype.zIndex+2;l.style.border="3px dotted rgb(254, 137, 12)";l.style.pointerEvents="none";l.style.position="absolute";l.style.top=c+"px";l.style.left=b+"px";l.style.width=Math.max(0,d-3)+"px";l.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?
+this.editor.graph.container.appendChild(l):document.body.appendChild(l);return l};EditorUi.prototype.stringToCells=function(a){a=mxUtils.parseXml(a);var c=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=c){var b=new mxCodec(c.ownerDocument),d=new mxGraphModel;b.decode(c,d);c=d.getChildAt(d.getRoot(),0);for(b=0;b<d.getChildCount(c);b++)a.push(d.getChildAt(c,b))}return a};EditorUi.prototype.openFiles=function(a,b){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var c=
0;c<a.length;c++)mxUtils.bind(this,function(a){var c=new FileReader;c.onload=mxUtils.bind(this,function(c){try{var d=c.target.result,f=a.name;if(null!=f&&0<f.length){!this.useCanvasForExport&&/(\.png)$/i.test(f)?f=f.substring(0,f.length-4)+".drawio":/(\.pdf)$/i.test(f)&&(f=f.substring(0,f.length-4)+".drawio");var e=mxUtils.bind(this,function(a){f=0<=f.lastIndexOf(".")?f.substring(0,f.lastIndexOf("."))+".drawio":f+".drawio";if("<mxlibrary"==a.substring(0,10)){null==this.getCurrentFile()&&"1"!=urlParams.embed&&
this.openLocalFile(this.emptyDiagramXml,this.defaultFilename,b);try{this.loadLibrary(new LocalLibrary(this,a,f))}catch(D){this.handleError(D,mxResources.get("errorLoadingFile"))}}else this.openLocalFile(a,f,b)});if(/(\.v(dx|sdx?))($|\?)/i.test(f)||/(\.vs(x|sx?))($|\?)/i.test(f))this.importVisio(a,mxUtils.bind(this,function(a){this.spinner.stop();e(a)}));else if(/(\.*<graphml )/.test(d))this.importGraphML(d,mxUtils.bind(this,function(a){this.spinner.stop();e(a)}));else if(Graph.fileSupport&&!this.isOffline()&&
(new XMLHttpRequest).upload&&this.isRemoteFileFormat(d,f))this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?e(a.responseText):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))}));else if(this.isLucidChartData(d))/(\.json)$/i.test(f)&&(f=f.substring(0,f.length-5)+".drawio"),this.convertLucidChart(d,mxUtils.bind(this,function(a){this.spinner.stop();this.openLocalFile(a,
@@ -3343,41 +3343,41 @@ a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebar
this.actions.layersWindow.window.setVisible(!1),null!=this.menus.tagsWindow&&this.menus.tagsWindow.window.setVisible(!1),null!=this.menus.findWindow&&this.menus.findWindow.window.setVisible(!1))};EditorUi.prototype.initializeEmbedMode=function(){this.setGraphEnabled(!1);(window.opener||window.parent)!=window&&("1"!=urlParams.spin||this.spinner.spin(document.body,mxResources.get("loading")))&&this.installMessageHandler(mxUtils.bind(this,function(a,b,d){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);
null!=a&&0<a.length?(this.setFileData(a),this.editor.isChromelessView()?this.editor.graph.isLightboxView()&&this.lightboxFit():this.showLayersDialog(),this.chromelessResize&&this.chromelessResize()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=null!=d?d:!1;this.updateUi();window.self!==window.top&&window.focus();null!=this.format&&this.format.refresh()}))};EditorUi.prototype.showLayersDialog=function(){1<
this.editor.graph.getModel().getChildCount(this.editor.graph.getModel().getRoot())&&(null==this.actions.layersWindow?this.actions.get("layers").funct():this.actions.layersWindow.window.setVisible(!0))};EditorUi.prototype.getPublicUrl=function(a,b){null!=a?a.getPublicUrl(b):b(null)};EditorUi.prototype.createLoadMessage=function(a){var c=this.editor.graph;return{event:a,pageVisible:c.pageVisible,translate:c.view.translate,bounds:c.getGraphBounds(),currentPage:this.getSelectedPageIndex(),scale:c.view.scale,
-page:c.view.getBackgroundPageBounds()}};EditorUi.prototype.installMessageHandler=function(a){var c=null,b=!1,d=!1,e=null,k=mxUtils.bind(this,function(a,c){this.editor.modified&&"0"!=urlParams.modified?null!=urlParams.modified&&this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(urlParams.modified))):this.editor.setStatus("")});this.editor.graph.model.addListener(mxEvent.CHANGE,k);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){if(f.source==(window.opener||window.parent)){var g=
-f.data,k=mxUtils.bind(this,function(a){if(null!=a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"data:image/png;base64,"==a.substring(0,22)?a=this.extractGraphModelFromPng(a):"data:image/svg+xml;base64,"==a.substring(0,26)?a=atob(a.substring(26)):"data:image/svg+xml;utf8,"==a.substring(0,24)&&(a=a.substring(24)),null!=a&&("%"==a.charAt(0)?a=decodeURIComponent(a):"<"!=a.charAt(0)&&(a=Graph.decompress(a)))}catch(ia){}return a});if("json"==urlParams.proto){try{g=JSON.parse(g)}catch(Z){g=null}try{if(null==
-g)return;if("dialog"==g.action){this.showError(null!=g.titleKey?mxResources.get(g.titleKey):g.title,null!=g.messageKey?mxResources.get(g.messageKey):g.message,null!=g.buttonKey?mxResources.get(g.buttonKey):g.button);null!=g.modified&&(this.editor.modified=g.modified);return}if("prompt"==g.action){this.spinner.stop();var l=new FilenameDialog(this,g.defaultValue||"",null!=g.okKey?mxResources.get(g.okKey):null,function(a){null!=a&&m.postMessage(JSON.stringify({event:"prompt",value:a,message:g}),"*")},
-null!=g.titleKey?mxResources.get(g.titleKey):g.title);this.showDialog(l.container,300,80,!0,!1);l.init();return}if("draft"==g.action){var n=k(g.xml);this.spinner.stop();l=new DraftDialog(this,mxResources.get("draftFound",[g.name||this.defaultFilename]),n,mxUtils.bind(this,function(){this.hideDialog();m.postMessage(JSON.stringify({event:"draft",result:"edit",message:g}),"*")}),mxUtils.bind(this,function(){this.hideDialog();m.postMessage(JSON.stringify({event:"draft",result:"discard",message:g}),"*")}),
-g.editKey?mxResources.get(g.editKey):null,g.discardKey?mxResources.get(g.discardKey):null,g.ignore?mxUtils.bind(this,function(){this.hideDialog();m.postMessage(JSON.stringify({event:"draft",result:"ignore",message:g}),"*")}):null);this.showDialog(l.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{l.init()}catch(Z){m.postMessage(JSON.stringify({event:"draft",error:Z.toString(),message:g}),"*")}return}if("template"==g.action){this.spinner.stop();var p=
-1==g.enableRecent,q=1==g.enableSearch,t=1==g.enableCustomTemp,l=new NewDialog(this,!1,null!=g.callback,mxUtils.bind(this,function(c,b){c=c||this.emptyDiagramXml;null!=g.callback?m.postMessage(JSON.stringify({event:"template",xml:c,blank:c==this.emptyDiagramXml,name:b}),"*"):(a(c,f,c!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}),null,null,null,null,null,null,null,p?mxUtils.bind(this,function(a){this.remoteInvoke("getRecentDiagrams",null,null,a,function(){a(null,"Network Error!")})}):
-null,q?mxUtils.bind(this,function(a,c){this.remoteInvoke("searchDiagrams",[a],null,c,function(){c(null,"Network Error!")})}):null,mxUtils.bind(this,function(a,c,b){m.postMessage(JSON.stringify({event:"template",docUrl:a,info:c,name:b}),"*")}),null,null,t?mxUtils.bind(this,function(a){this.remoteInvoke("getCustomTemplates",null,null,a,function(){a({},0)})}):null);this.showDialog(l.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));l.init();return}if("textContent"==
-g.action){var v=this.getDiagramTextContent();m.postMessage(JSON.stringify({event:"textContent",data:v,message:g}),"*");return}if("status"==g.action){null!=g.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(g.messageKey))):null!=g.message&&this.editor.setStatus(mxUtils.htmlEntities(g.message));null!=g.modified&&(this.editor.modified=g.modified);return}if("spinner"==g.action){var E=null!=g.messageKey?mxResources.get(g.messageKey):g.message;null==g.show||g.show?this.spinner.spin(document.body,
+page:c.view.getBackgroundPageBounds()}};EditorUi.prototype.installMessageHandler=function(a){var c=null,b=!1,d=!1,e=null,l=mxUtils.bind(this,function(a,c){this.editor.modified&&"0"!=urlParams.modified?null!=urlParams.modified&&this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(urlParams.modified))):this.editor.setStatus("")});this.editor.graph.model.addListener(mxEvent.CHANGE,l);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){if(f.source==(window.opener||window.parent)){var g=
+f.data,l=mxUtils.bind(this,function(a){if(null!=a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"data:image/png;base64,"==a.substring(0,22)?a=this.extractGraphModelFromPng(a):"data:image/svg+xml;base64,"==a.substring(0,26)?a=atob(a.substring(26)):"data:image/svg+xml;utf8,"==a.substring(0,24)&&(a=a.substring(24)),null!=a&&("%"==a.charAt(0)?a=decodeURIComponent(a):"<"!=a.charAt(0)&&(a=Graph.decompress(a)))}catch(ia){}return a});if("json"==urlParams.proto){try{g=JSON.parse(g)}catch(Z){g=null}try{if(null==
+g)return;if("dialog"==g.action){this.showError(null!=g.titleKey?mxResources.get(g.titleKey):g.title,null!=g.messageKey?mxResources.get(g.messageKey):g.message,null!=g.buttonKey?mxResources.get(g.buttonKey):g.button);null!=g.modified&&(this.editor.modified=g.modified);return}if("prompt"==g.action){this.spinner.stop();var m=new FilenameDialog(this,g.defaultValue||"",null!=g.okKey?mxResources.get(g.okKey):null,function(a){null!=a&&k.postMessage(JSON.stringify({event:"prompt",value:a,message:g}),"*")},
+null!=g.titleKey?mxResources.get(g.titleKey):g.title);this.showDialog(m.container,300,80,!0,!1);m.init();return}if("draft"==g.action){var n=l(g.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[g.name||this.defaultFilename]),n,mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"edit",message:g}),"*")}),mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"discard",message:g}),"*")}),
+g.editKey?mxResources.get(g.editKey):null,g.discardKey?mxResources.get(g.discardKey):null,g.ignore?mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"ignore",message:g}),"*")}):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(Z){k.postMessage(JSON.stringify({event:"draft",error:Z.toString(),message:g}),"*")}return}if("template"==g.action){this.spinner.stop();var p=
+1==g.enableRecent,q=1==g.enableSearch,t=1==g.enableCustomTemp,m=new NewDialog(this,!1,null!=g.callback,mxUtils.bind(this,function(c,b){c=c||this.emptyDiagramXml;null!=g.callback?k.postMessage(JSON.stringify({event:"template",xml:c,blank:c==this.emptyDiagramXml,name:b}),"*"):(a(c,f,c!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}),null,null,null,null,null,null,null,p?mxUtils.bind(this,function(a){this.remoteInvoke("getRecentDiagrams",null,null,a,function(){a(null,"Network Error!")})}):
+null,q?mxUtils.bind(this,function(a,c){this.remoteInvoke("searchDiagrams",[a],null,c,function(){c(null,"Network Error!")})}):null,mxUtils.bind(this,function(a,c,b){k.postMessage(JSON.stringify({event:"template",docUrl:a,info:c,name:b}),"*")}),null,null,t?mxUtils.bind(this,function(a){this.remoteInvoke("getCustomTemplates",null,null,a,function(){a({},0)})}):null);this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("textContent"==
+g.action){var v=this.getDiagramTextContent();k.postMessage(JSON.stringify({event:"textContent",data:v,message:g}),"*");return}if("status"==g.action){null!=g.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(g.messageKey))):null!=g.message&&this.editor.setStatus(mxUtils.htmlEntities(g.message));null!=g.modified&&(this.editor.modified=g.modified);return}if("spinner"==g.action){var E=null!=g.messageKey?mxResources.get(g.messageKey):g.message;null==g.show||g.show?this.spinner.spin(document.body,
E):this.spinner.stop();return}if("export"==g.action){if("png"==g.format||"xmlpng"==g.format){if(null==g.spin&&null==g.spinKey||this.spinner.spin(document.body,null!=g.spinKey?mxResources.get(g.spinKey):g.spin)){var J=null!=g.xml?g.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var H=this.editor.graph,y=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();var c=this.createLoadMessage("export");c.format=g.format;c.message=g;c.data=a;c.xml=encodeURIComponent(J);
-m.postMessage(JSON.stringify(c),"*")}),K=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==g.format&&(a=Editor.writeGraphModelToPng(a,"tEXt","mxfile",encodeURIComponent(J)));H!=this.editor.graph&&H.container.parentNode.removeChild(H.container);y(a)}),z=g.pageId||(null!=this.pages?this.pages[0].getId():null);if(this.isExportToCanvas()){if(null!=this.pages&&this.currentPage.getId()!=z){for(var L=H.getGlobalVariable,H=this.createTemporaryGraph(H.getStylesheet()),O,I=0;I<this.pages.length;I++)if(this.pages[I].getId()==
-z){O=this.updatePageRoot(this.pages[I]);break}H.getGlobalVariable=function(a){return"page"==a?O.getName():"pagenumber"==a?1:L.apply(this,arguments)};document.body.appendChild(H.container);H.model.setRoot(O.root)}if(null!=g.layerIds){for(var U=H.model,ea=U.getChildCells(U.getRoot()),l={},I=0;I<g.layerIds.length;I++)l[g.layerIds[I]]=!0;for(I=0;I<ea.length;I++)U.setVisible(ea[I],l[ea[I].id]||!1)}this.editor.exportToCanvas(mxUtils.bind(this,function(a){K(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,
+k.postMessage(JSON.stringify(c),"*")}),K=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==g.format&&(a=Editor.writeGraphModelToPng(a,"tEXt","mxfile",encodeURIComponent(J)));H!=this.editor.graph&&H.container.parentNode.removeChild(H.container);y(a)}),z=g.pageId||(null!=this.pages?this.pages[0].getId():null);if(this.isExportToCanvas()){if(null!=this.pages&&this.currentPage.getId()!=z){for(var L=H.getGlobalVariable,H=this.createTemporaryGraph(H.getStylesheet()),O,I=0;I<this.pages.length;I++)if(this.pages[I].getId()==
+z){O=this.updatePageRoot(this.pages[I]);break}H.getGlobalVariable=function(a){return"page"==a?O.getName():"pagenumber"==a?1:L.apply(this,arguments)};document.body.appendChild(H.container);H.model.setRoot(O.root)}if(null!=g.layerIds){for(var U=H.model,ea=U.getChildCells(U.getRoot()),m={},I=0;I<g.layerIds.length;I++)m[g.layerIds[I]]=!0;for(I=0;I<ea.length;I++)U.setVisible(ea[I],m[ea[I].id]||!1)}this.editor.exportToCanvas(mxUtils.bind(this,function(a){K(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,
function(){K(null)}),null,null,g.scale,null,null,null,H)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+("xmlpng"==g.format?"1":"0")+(null!=z?"&pageId="+z:"")+(null!=g.layerIds?"&extras="+encodeURIComponent(JSON.stringify({layerIds:g.layerIds})):"")+(null!=g.scale?"&scale="+g.scale:"")+"&base64=1&xml="+encodeURIComponent(J))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()?y("data:image/png;base64,"+a.getText()):K(null)}),mxUtils.bind(this,function(){K(null)}))}}else{null!=
g.xml&&0<g.xml.length&&this.setFileData(g.xml);E=this.createLoadMessage("export");if("html2"==g.format||"html"==g.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length)){var ba=this.getXmlFileData();E.xml=mxUtils.getXml(ba);E.data=this.getFileData(null,null,!0,null,null,null,ba);E.format=g.format}else if("html"==g.format)J=this.editor.getGraphXml(),E.data=this.getHtml(J,this.editor.graph),E.xml=mxUtils.getXml(J),E.format=g.format;else{mxSvgCanvas2D.prototype.foAltText=null;var ha=this.editor.graph.background;
-ha==mxConstants.NONE&&(ha=null);E.xml=this.getFileData(!0,null,null,null,null,null,null,null,null,!1);E.format="svg";var fa=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();E.data=Editor.createSvgDataUri(a);m.postMessage(JSON.stringify(E),"*")});if("xmlsvg"==g.format)(null==g.spin&&null==g.spinKey||this.spinner.spin(document.body,null!=g.spinKey?mxResources.get(g.spinKey):g.spin))&&this.getEmbeddedSvg(E.xml,this.editor.graph,null,!0,fa,null,null,g.embedImages);else if(null==
-g.spin&&null==g.spinKey||this.spinner.spin(document.body,null!=g.spinKey?mxResources.get(g.spinKey):g.spin)){this.editor.graph.setEnabled(!1);var S=this.editor.graph.getSvg(ha);this.embedFonts(S,mxUtils.bind(this,function(a){g.embedImages||null==g.embedImages?this.editor.convertImages(a,mxUtils.bind(this,function(a){fa(mxUtils.getXml(a))})):fa(mxUtils.getXml(a))}))}return}m.postMessage(JSON.stringify(E),"*")}return}if("load"==g.action)d=1==g.autosave,this.hideDialog(),null!=g.modified&&null==urlParams.modified&&
+ha==mxConstants.NONE&&(ha=null);E.xml=this.getFileData(!0,null,null,null,null,null,null,null,null,!1);E.format="svg";var fa=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();E.data=Editor.createSvgDataUri(a);k.postMessage(JSON.stringify(E),"*")});if("xmlsvg"==g.format)(null==g.spin&&null==g.spinKey||this.spinner.spin(document.body,null!=g.spinKey?mxResources.get(g.spinKey):g.spin))&&this.getEmbeddedSvg(E.xml,this.editor.graph,null,!0,fa,null,null,g.embedImages);else if(null==
+g.spin&&null==g.spinKey||this.spinner.spin(document.body,null!=g.spinKey?mxResources.get(g.spinKey):g.spin)){this.editor.graph.setEnabled(!1);var S=this.editor.graph.getSvg(ha);this.embedFonts(S,mxUtils.bind(this,function(a){g.embedImages||null==g.embedImages?this.editor.convertImages(a,mxUtils.bind(this,function(a){fa(mxUtils.getXml(a))})):fa(mxUtils.getXml(a))}))}return}k.postMessage(JSON.stringify(E),"*")}return}if("load"==g.action)d=1==g.autosave,this.hideDialog(),null!=g.modified&&null==urlParams.modified&&
(urlParams.modified=g.modified),null!=g.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=g.saveAndExit),null!=g.title&&null!=this.buttonContainer&&(n=document.createElement("span"),mxUtils.write(n,g.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight="12px",this.buttonContainer.style.paddingTop="6px",this.buttonContainer.style.right="25px"):"min"!=uiTheme&&(this.buttonContainer.style.paddingRight="38px",this.buttonContainer.style.paddingTop="6px"),null!=this.embedFilenameSpan&&
-this.embedFilenameSpan.parentNode.removeChild(this.embedFilenameSpan),this.buttonContainer.appendChild(n),this.embedFilenameSpan=n),g=null!=g.xmlpng?this.extractGraphModelFromPng(g.xmlpng):g.xml;else{"remoteInvokeReady"==g.action?this.handleRemoteInvokeReady(m):"remoteInvoke"==g.action?this.handleRemoteInvoke(g,f.origin):"remoteInvokeResponse"==g.action?this.handleRemoteInvokeResponse(g):m.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(g)}),"*");return}}catch(Z){this.handleError(Z)}}var X=
-mxUtils.bind(this,function(f,g){b=!0;try{a(f,g)}catch(T){this.handleError(T)}b=!1;null!=urlParams.modified&&this.editor.setStatus("");var k=mxUtils.bind(this,function(){return"0"!=urlParams.pages||null!=this.pages&&1<this.pages.length?this.getFileData(!0):mxUtils.getXml(this.editor.getGraphXml())});e=k();d&&null==c&&(c=mxUtils.bind(this,function(a,c){var d=k();if(d!=e&&!b){var f=this.createLoadMessage("autosave");f.xml=d;d=JSON.stringify(f);(window.opener||window.parent).postMessage(d,"*")}e=d}),
+this.embedFilenameSpan.parentNode.removeChild(this.embedFilenameSpan),this.buttonContainer.appendChild(n),this.embedFilenameSpan=n),g=null!=g.xmlpng?this.extractGraphModelFromPng(g.xmlpng):g.xml;else{"remoteInvokeReady"==g.action?this.handleRemoteInvokeReady(k):"remoteInvoke"==g.action?this.handleRemoteInvoke(g,f.origin):"remoteInvokeResponse"==g.action?this.handleRemoteInvokeResponse(g):k.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(g)}),"*");return}}catch(Z){this.handleError(Z)}}var X=
+mxUtils.bind(this,function(f,g){b=!0;try{a(f,g)}catch(T){this.handleError(T)}b=!1;null!=urlParams.modified&&this.editor.setStatus("");var l=mxUtils.bind(this,function(){return"0"!=urlParams.pages||null!=this.pages&&1<this.pages.length?this.getFileData(!0):mxUtils.getXml(this.editor.getGraphXml())});e=l();d&&null==c&&(c=mxUtils.bind(this,function(a,c){var d=l();if(d!=e&&!b){var f=this.createLoadMessage("autosave");f.xml=d;d=JSON.stringify(f);(window.opener||window.parent).postMessage(d,"*")}e=d}),
this.editor.graph.model.addListener(mxEvent.CHANGE,c),this.editor.graph.addListener("gridSizeChanged",c),this.editor.graph.addListener("shadowVisibleChanged",c),this.addListener("pageFormatChanged",c),this.addListener("pageScaleChanged",c),this.addListener("backgroundColorChanged",c),this.addListener("backgroundImageChanged",c),this.addListener("foldingEnabledChanged",c),this.addListener("mathEnabledChanged",c),this.addListener("gridEnabledChanged",c),this.addListener("guidesEnabledChanged",c),this.addListener("pageViewChanged",
-c));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||m.postMessage(JSON.stringify(this.createLoadMessage("load")),"*")});null!=g&&"function"===typeof g.substring&&"data:application/vnd.visio;base64,"==g.substring(0,34)?(k="0M8R4KGxGuE"==g.substring(34,45)?"raw.vsd":"raw.vsdx",this.importVisio(this.base64ToBlob(g.substring(g.indexOf(",")+1)),function(a){X(a,f)},mxUtils.bind(this,function(a){this.handleError(a)}),k)):null!=g&&"function"===typeof g.substring&&!this.isOffline()&&(new XMLHttpRequest).upload&&
-this.isRemoteFileFormat(g,"")?this.parseFile(new Blob([g],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&200<=a.status&&299>=a.status&&"<mxGraphModel"==a.responseText.substring(0,13)&&X(a.responseText,f)}),""):null!=g&&"function"===typeof g.substring&&this.isLucidChartData(g)?this.convertLucidChart(g,mxUtils.bind(this,function(a){X(a)}),mxUtils.bind(this,function(a){this.handleError(a)})):(g=k(g),X(g,f))}}));var m=window.opener||window.parent,k="json"==urlParams.proto?
-JSON.stringify({event:"init"}):urlParams.ready||"ready";m.postMessage(k,"*")};EditorUi.prototype.addEmbedButtons=function(){if(null!=this.menubar){var a=document.createElement("div");a.style.display="inline-block";a.style.position="absolute";a.style.paddingTop="atlas"==uiTheme?"2px":"0px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");b.className="geBigButton";"1"==urlParams.noSaveBtn?(mxUtils.write(b,mxResources.get("saveAndExit")),b.setAttribute("title",
+c));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||k.postMessage(JSON.stringify(this.createLoadMessage("load")),"*")});null!=g&&"function"===typeof g.substring&&"data:application/vnd.visio;base64,"==g.substring(0,34)?(l="0M8R4KGxGuE"==g.substring(34,45)?"raw.vsd":"raw.vsdx",this.importVisio(this.base64ToBlob(g.substring(g.indexOf(",")+1)),function(a){X(a,f)},mxUtils.bind(this,function(a){this.handleError(a)}),l)):null!=g&&"function"===typeof g.substring&&!this.isOffline()&&(new XMLHttpRequest).upload&&
+this.isRemoteFileFormat(g,"")?this.parseFile(new Blob([g],{type:"application/octet-stream"}),mxUtils.bind(this,function(a){4==a.readyState&&200<=a.status&&299>=a.status&&"<mxGraphModel"==a.responseText.substring(0,13)&&X(a.responseText,f)}),""):null!=g&&"function"===typeof g.substring&&this.isLucidChartData(g)?this.convertLucidChart(g,mxUtils.bind(this,function(a){X(a)}),mxUtils.bind(this,function(a){this.handleError(a)})):(g=l(g),X(g,f))}}));var k=window.opener||window.parent,l="json"==urlParams.proto?
+JSON.stringify({event:"init"}):urlParams.ready||"ready";k.postMessage(l,"*")};EditorUi.prototype.addEmbedButtons=function(){if(null!=this.menubar){var a=document.createElement("div");a.style.display="inline-block";a.style.position="absolute";a.style.paddingTop="atlas"==uiTheme?"2px":"0px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");b.className="geBigButton";"1"==urlParams.noSaveBtn?(mxUtils.write(b,mxResources.get("saveAndExit")),b.setAttribute("title",
mxResources.get("saveAndExit")),mxEvent.addListener(b,"click",mxUtils.bind(this,function(){this.actions.get("saveAndExit").funct()})),a.appendChild(b)):(mxUtils.write(b,mxResources.get("save")),b.setAttribute("title",mxResources.get("save")+" ("+Editor.ctrlKey+"+S)"),mxEvent.addListener(b,"click",mxUtils.bind(this,function(){this.actions.get("save").funct()})),a.appendChild(b),"1"==urlParams.saveAndExit&&(b=document.createElement("a"),mxUtils.write(b,mxResources.get("saveAndExit")),b.setAttribute("title",
mxResources.get("saveAndExit")),b.className="geBigButton geBigStandardButton",b.style.marginLeft="6px",mxEvent.addListener(b,"click",mxUtils.bind(this,function(){this.actions.get("saveAndExit").funct()})),a.appendChild(b)));b=document.createElement("a");mxUtils.write(b,mxResources.get("exit"));b.setAttribute("title",mxResources.get("exit"));b.className="geBigButton geBigStandardButton";b.style.marginLeft="6px";b.style.marginRight="20px";mxEvent.addListener(b,"click",mxUtils.bind(this,function(){this.actions.get("exit").funct()}));
a.appendChild(b);this.toolbar.container.appendChild(a);this.toolbar.staticElements.push(a);a.style.right="atlas"!=uiTheme?"52px":"42px"}};EditorUi.prototype.showImportCsvDialog=function(){null==this.importCsvDialog&&(this.importCsvDialog=new TextareaDialog(this,mxResources.get("csv")+":",Editor.defaultCsvValue,mxUtils.bind(this,function(a){this.importCsv(a)}),null,null,620,430,null,!0,!0,mxResources.get("import"),this.isOffline()?null:"https://drawio-app.com/import-from-csv-to-drawio/"));this.showDialog(this.importCsvDialog.container,
-640,520,!0,!0,null,null,null,null,!0);this.importCsvDialog.init()};EditorUi.prototype.executeLayoutList=function(a,b){for(var c=this.editor.graph,d=c.getSelectionCells(),f=0;f<a.length;f++){var e=new window[a[f].layout](c);if(null!=a[f].config)for(var k in a[f].config)e[k]=a[f].config[k];this.executeLayout(function(){e.execute(c.getDefaultParent(),0==d.length?null:d)},f==a.length-1,b)}};EditorUi.prototype.importCsv=function(a,b){try{var c=a.split("\n"),d=[],f=[],e={};if(0<c.length){var k={},m=null,
+640,520,!0,!0,null,null,null,null,!0);this.importCsvDialog.init()};EditorUi.prototype.executeLayoutList=function(a,b){for(var c=this.editor.graph,d=c.getSelectionCells(),f=0;f<a.length;f++){var e=new window[a[f].layout](c);if(null!=a[f].config)for(var l in a[f].config)e[l]=a[f].config[l];this.executeLayout(function(){e.execute(c.getDefaultParent(),0==d.length?null:d)},f==a.length-1,b)}};EditorUi.prototype.importCsv=function(a,b){try{var c=a.split("\n"),d=[],f=[],e={};if(0<c.length){var l={},k=null,
q=null,A=null,B=null,D=null,C=null,x=null,F=null,G="",E="auto",J="auto",H=null,y=null,K=40,z=40,L=100,O=0,I=this.editor.graph;I.getGraphBounds();for(var U=function(){null!=b?b(oa):(I.setSelectionCells(oa),I.scrollCellToVisible(I.getSelectionCell()))},ea=I.getFreeInsertPoint(),ba=ea.x,ha=ea.y,ea=ha,fa=null,S="auto",F=null,X=[],Z=null,ia=null,V=0;V<c.length&&"#"==c[V].charAt(0);){a=c[V];for(V++;V<c.length&&"\\"==a.charAt(a.length-1)&&"#"==c[V].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(c[V].substring(1)),
-V++;if("#"!=a.charAt(1)){var T=a.indexOf(":");if(0<T){var Q=mxUtils.trim(a.substring(1,T)),M=mxUtils.trim(a.substring(T+1));"label"==Q?fa=I.sanitizeHtml(M):"labelname"==Q&&0<M.length&&"-"!=M?B=M:"labels"==Q&&0<M.length&&"-"!=M?D=JSON.parse(M):"style"==Q?m=M:"parentstyle"==Q?C=M:"stylename"==Q&&0<M.length&&"-"!=M?A=M:"styles"==Q&&0<M.length&&"-"!=M?q=JSON.parse(M):"identity"==Q&&0<M.length&&"-"!=M?x=M:"parent"==Q&&0<M.length&&"-"!=M?F=M:"namespace"==Q&&0<M.length&&"-"!=M?G=M:"width"==Q?E=M:"height"==
+V++;if("#"!=a.charAt(1)){var T=a.indexOf(":");if(0<T){var Q=mxUtils.trim(a.substring(1,T)),M=mxUtils.trim(a.substring(T+1));"label"==Q?fa=I.sanitizeHtml(M):"labelname"==Q&&0<M.length&&"-"!=M?B=M:"labels"==Q&&0<M.length&&"-"!=M?D=JSON.parse(M):"style"==Q?k=M:"parentstyle"==Q?C=M:"stylename"==Q&&0<M.length&&"-"!=M?A=M:"styles"==Q&&0<M.length&&"-"!=M?q=JSON.parse(M):"identity"==Q&&0<M.length&&"-"!=M?x=M:"parent"==Q&&0<M.length&&"-"!=M?F=M:"namespace"==Q&&0<M.length&&"-"!=M?G=M:"width"==Q?E=M:"height"==
Q?J=M:"left"==Q&&0<M.length?H=M:"top"==Q&&0<M.length?y=M:"ignore"==Q?ia=M.split(","):"connect"==Q?X.push(JSON.parse(M)):"link"==Q?Z=M:"padding"==Q?O=parseFloat(M):"edgespacing"==Q?K=parseFloat(M):"nodespacing"==Q?z=parseFloat(M):"levelspacing"==Q?L=parseFloat(M):"layout"==Q&&(S=M)}}}if(null==c[V])throw Error(mxResources.get("invalidOrMissingFile"));for(var ca=this.editor.csvToArray(c[V]),Q=T=null,M=[],P=0;P<ca.length;P++)x==ca[P]&&(T=P),F==ca[P]&&(Q=P),M.push(mxUtils.trim(ca[P]).replace(/[^a-z0-9]+/ig,
-"_").replace(/^\d+/,"").replace(/_+$/,""));null==fa&&(fa="%"+M[0]+"%");if(null!=X)for(var aa=0;aa<X.length;aa++)null==k[X[aa].to]&&(k[X[aa].to]={});x=[];for(P=V+1;P<c.length;P++){var Y=this.editor.csvToArray(c[P]);if(null==Y){var za=40<c[P].length?c[P].substring(0,40)+"...":c[P];throw Error(za+" ("+P+"):\n"+mxResources.get("containsValidationErrors"));}0<Y.length&&x.push(Y)}I.model.beginUpdate();try{for(P=0;P<x.length;P++){var Y=x[P],N=null,ja=null!=T?G+Y[T]:null;null!=ja&&(N=I.model.getCell(ja));
-var c=null!=N,W=new mxCell(fa,new mxGeometry(ba,ea,0,0),m||"whiteSpace=wrap;html=1;");W.vertex=!0;W.id=ja;for(var ga=0;ga<Y.length;ga++)I.setAttributeForCell(W,M[ga],Y[ga]);if(null!=B&&null!=D){var ma=D[W.getAttribute(B)];null!=ma&&I.labelChanged(W,ma)}if(null!=A&&null!=q){var ta=q[W.getAttribute(A)];null!=ta&&(W.style=ta)}I.setAttributeForCell(W,"placeholders","1");W.style=I.replacePlaceholders(W,W.style);c&&(I.model.setGeometry(N,W.geometry),I.model.setStyle(N,W.style),0>mxUtils.indexOf(f,N)&&f.push(N));
-N=W;if(!c)for(aa=0;aa<X.length;aa++)k[X[aa].to][N.getAttribute(X[aa].to)]=N;null!=Z&&"link"!=Z&&(I.setLinkForCell(N,N.getAttribute(Z)),I.setAttributeForCell(N,Z,null));I.fireEvent(new mxEventObject("cellsInserted","cells",[N]));var ka=this.editor.graph.getPreferredSizeForCell(N);N.vertex&&(null!=H&&null!=N.getAttribute(H)&&(N.geometry.x=ba+parseFloat(N.getAttribute(H))),null!=y&&null!=N.getAttribute(y)&&(N.geometry.y=ha+parseFloat(N.getAttribute(y))),"@"==E.charAt(0)&&null!=N.getAttribute(E.substring(1))?
+"_").replace(/^\d+/,"").replace(/_+$/,""));null==fa&&(fa="%"+M[0]+"%");if(null!=X)for(var aa=0;aa<X.length;aa++)null==l[X[aa].to]&&(l[X[aa].to]={});x=[];for(P=V+1;P<c.length;P++){var Y=this.editor.csvToArray(c[P]);if(null==Y){var za=40<c[P].length?c[P].substring(0,40)+"...":c[P];throw Error(za+" ("+P+"):\n"+mxResources.get("containsValidationErrors"));}0<Y.length&&x.push(Y)}I.model.beginUpdate();try{for(P=0;P<x.length;P++){var Y=x[P],N=null,ja=null!=T?G+Y[T]:null;null!=ja&&(N=I.model.getCell(ja));
+var c=null!=N,W=new mxCell(fa,new mxGeometry(ba,ea,0,0),k||"whiteSpace=wrap;html=1;");W.vertex=!0;W.id=ja;for(var ga=0;ga<Y.length;ga++)I.setAttributeForCell(W,M[ga],Y[ga]);if(null!=B&&null!=D){var ma=D[W.getAttribute(B)];null!=ma&&I.labelChanged(W,ma)}if(null!=A&&null!=q){var ta=q[W.getAttribute(A)];null!=ta&&(W.style=ta)}I.setAttributeForCell(W,"placeholders","1");W.style=I.replacePlaceholders(W,W.style);c&&(I.model.setGeometry(N,W.geometry),I.model.setStyle(N,W.style),0>mxUtils.indexOf(f,N)&&f.push(N));
+N=W;if(!c)for(aa=0;aa<X.length;aa++)l[X[aa].to][N.getAttribute(X[aa].to)]=N;null!=Z&&"link"!=Z&&(I.setLinkForCell(N,N.getAttribute(Z)),I.setAttributeForCell(N,Z,null));I.fireEvent(new mxEventObject("cellsInserted","cells",[N]));var ka=this.editor.graph.getPreferredSizeForCell(N);N.vertex&&(null!=H&&null!=N.getAttribute(H)&&(N.geometry.x=ba+parseFloat(N.getAttribute(H))),null!=y&&null!=N.getAttribute(y)&&(N.geometry.y=ha+parseFloat(N.getAttribute(y))),"@"==E.charAt(0)&&null!=N.getAttribute(E.substring(1))?
N.geometry.width=parseFloat(N.getAttribute(E.substring(1))):N.geometry.width="auto"==E?ka.width+O:parseFloat(E),"@"==J.charAt(0)&&null!=N.getAttribute(J.substring(1))?N.geometry.height=parseFloat(N.getAttribute(J.substring(1))):N.geometry.height="auto"==J?ka.height+O:parseFloat(J),ea+=N.geometry.height+z);c?(null==e[ja]&&(e[ja]=[]),e[ja].push(N)):(F=null!=Q?I.model.getCell(G+Y[Q]):null,d.push(N),null!=F?(F.style=I.replacePlaceholders(F,C),I.addCell(N,F)):f.push(I.addCell(N)))}for(var pa=f.slice(),
-oa=f.slice(),aa=0;aa<X.length;aa++)for(var Aa=X[aa],P=0;P<d.length;P++){var N=d[P],ua=mxUtils.bind(this,function(a,c,b){var d=c.getAttribute(b.from);if(null!=d&&(I.setAttributeForCell(c,b.from,null),""!=d))for(var d=d.split(","),f=0;f<d.length;f++){var e=k[b.to][d[f]];if(null!=e){var g=b.label;null!=b.fromlabel&&(g=(c.getAttribute(b.fromlabel)||"")+(g||""));null!=b.tolabel&&(g=(g||"")+(e.getAttribute(b.tolabel)||""));var l="target"==b.placeholders==!b.invert?e:a,l=null!=b.style?I.replacePlaceholders(l,
-b.style):I.createCurrentEdgeStyle();oa.push(I.insertEdge(null,null,g||"",b.invert?e:a,b.invert?a:e,l));mxUtils.remove(b.invert?a:e,pa)}}});ua(N,N,Aa);if(null!=e[N.id])for(ga=0;ga<e[N.id].length;ga++)ua(N,e[N.id][ga],Aa)}if(null!=ia)for(P=0;P<d.length;P++)for(N=d[P],ga=0;ga<ia.length;ga++)I.setAttributeForCell(N,mxUtils.trim(ia[ga]),null);if(0<f.length){var qa=new mxParallelEdgeLayout(I);qa.spacing=K;var ra=function(){0<qa.spacing&&qa.execute(I.getDefaultParent());for(var a=0;a<f.length;a++){var c=
+oa=f.slice(),aa=0;aa<X.length;aa++)for(var Aa=X[aa],P=0;P<d.length;P++){var N=d[P],ua=mxUtils.bind(this,function(a,c,b){var d=c.getAttribute(b.from);if(null!=d&&(I.setAttributeForCell(c,b.from,null),""!=d))for(var d=d.split(","),f=0;f<d.length;f++){var e=l[b.to][d[f]];if(null!=e){var g=b.label;null!=b.fromlabel&&(g=(c.getAttribute(b.fromlabel)||"")+(g||""));null!=b.tolabel&&(g=(g||"")+(e.getAttribute(b.tolabel)||""));var m="target"==b.placeholders==!b.invert?e:a,m=null!=b.style?I.replacePlaceholders(m,
+b.style):I.createCurrentEdgeStyle();oa.push(I.insertEdge(null,null,g||"",b.invert?e:a,b.invert?a:e,m));mxUtils.remove(b.invert?a:e,pa)}}});ua(N,N,Aa);if(null!=e[N.id])for(ga=0;ga<e[N.id].length;ga++)ua(N,e[N.id][ga],Aa)}if(null!=ia)for(P=0;P<d.length;P++)for(N=d[P],ga=0;ga<ia.length;ga++)I.setAttributeForCell(N,mxUtils.trim(ia[ga]),null);if(0<f.length){var qa=new mxParallelEdgeLayout(I);qa.spacing=K;var ra=function(){0<qa.spacing&&qa.execute(I.getDefaultParent());for(var a=0;a<f.length;a++){var c=
I.getCellGeometry(f[a]);c.x=Math.round(I.snap(c.x));c.y=Math.round(I.snap(c.y));"auto"==E&&(c.width=Math.round(I.snap(c.width)));"auto"==J&&(c.height=Math.round(I.snap(c.height)))}};if("["==S.charAt(0)){var sa=U;I.view.validate();this.executeLayoutList(JSON.parse(S),function(){ra();sa()});U=null}else if("circle"==S){var na=new mxCircleLayout(I);na.resetEdges=!1;var Da=na.isVertexIgnored;na.isVertexIgnored=function(a){return Da.apply(this,arguments)||0>mxUtils.indexOf(f,a)};this.executeLayout(function(){na.execute(I.getDefaultParent());
ra()},!0,U);U=null}else if("horizontaltree"==S||"verticaltree"==S||"auto"==S&&oa.length==2*f.length-1&&1==pa.length){I.view.validate();var wa=new mxCompactTreeLayout(I,"horizontaltree"==S);wa.levelDistance=z;wa.edgeRouting=!1;wa.resetEdges=!1;this.executeLayout(function(){wa.execute(I.getDefaultParent(),0<pa.length?pa[0]:null)},!0,U);U=null}else if("horizontalflow"==S||"verticalflow"==S||"auto"==S&&1==pa.length){I.view.validate();var la=new mxHierarchicalLayout(I,"horizontalflow"==S?mxConstants.DIRECTION_WEST:
mxConstants.DIRECTION_NORTH);la.intraCellSpacing=z;la.parallelEdgeSpacing=K;la.interRankCellSpacing=L;la.disableEdgeStyle=!1;this.executeLayout(function(){la.execute(I.getDefaultParent(),oa);I.moveCells(oa,ba,ha)},!0,U);U=null}else if("organic"==S||"auto"==S&&oa.length>f.length){I.view.validate();var ya=new mxFastOrganicLayout(I);ya.forceConstant=3*z;ya.resetEdges=!1;var La=ya.isVertexIgnored;ya.isVertexIgnored=function(a){return La.apply(this,arguments)||0>mxUtils.indexOf(f,a)};qa=new mxParallelEdgeLayout(I);
@@ -3385,70 +3385,70 @@ qa.spacing=K;this.executeLayout(function(){ya.execute(I.getDefaultParent());ra()
function(a){a=null!=a?a:window.location.pathname;var c=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var b="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),d;for(d in urlParams)0>mxUtils.indexOf(b,d)&&(a=0==c?a+"?":a+"&",null!=urlParams[d]&&(a+=d+"="+urlParams[d],c++))}return a};EditorUi.prototype.showLinkDialog=function(a,b,d){a=new LinkDialog(this,a,b,d,!0);this.showDialog(a.container,560,130,!0,!0);a.init()};var k=
EditorUi.prototype.createOutline;EditorUi.prototype.createOutline=function(a){var c=k.apply(this,arguments),b=this.editor.graph,d=c.getSourceGraphBounds;c.getSourceGraphBounds=function(){if(mxUtils.hasScrollbars(b.container)&&b.pageVisible&&null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),c=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width-2*a.x/c),Math.ceil(this.source.minimumGraphSize.height-2*a.y/c))}return d.apply(this,arguments)};
var e=c.getSourceContainerSize;c.getSourceContainerSize=function(){if(mxUtils.hasScrollbars(b.container)&&null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),c=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width*c-2*a.x),Math.ceil(this.source.minimumGraphSize.height*c-2*a.y))}return e.apply(this,arguments)};c.getOutlineOffset=function(a){if(mxUtils.hasScrollbars(b.container)&&null!=this.source.minimumGraphSize){var d=this.source.getPagePadding();
-return new mxPoint(Math.round(Math.max(0,(c.outline.container.clientWidth/a-(this.source.minimumGraphSize.width-2*d.x))/2)-d.x),Math.round(Math.max(0,(c.outline.container.clientHeight/a-(this.source.minimumGraphSize.height-2*d.y))/2)-d.y-5/a))}return new mxPoint(8/a,8/a)};var m=c.init;c.init=function(){m.apply(this,arguments);c.outline.view.getBackgroundPageBounds=function(){var a=b.getPageLayout(),c=b.getPageSize();return new mxRectangle(this.scale*(this.translate.x+a.x*c.width),this.scale*(this.translate.y+
+return new mxPoint(Math.round(Math.max(0,(c.outline.container.clientWidth/a-(this.source.minimumGraphSize.width-2*d.x))/2)-d.x),Math.round(Math.max(0,(c.outline.container.clientHeight/a-(this.source.minimumGraphSize.height-2*d.y))/2)-d.y-5/a))}return new mxPoint(8/a,8/a)};var l=c.init;c.init=function(){l.apply(this,arguments);c.outline.view.getBackgroundPageBounds=function(){var a=b.getPageLayout(),c=b.getPageSize();return new mxRectangle(this.scale*(this.translate.x+a.x*c.width),this.scale*(this.translate.y+
a.y*c.height),this.scale*a.width*c.width,this.scale*a.height*c.height)};c.outline.view.validateBackgroundPage()};this.editor.addListener("pageSelected",function(a,b){var d=b.getProperty("change"),f=c.source,e=c.outline;e.pageScale=f.pageScale;e.pageFormat=f.pageFormat;e.background=f.background;e.pageVisible=f.pageVisible;e.background=f.background;var g=mxUtils.getCurrentStyle(f.container);e.container.style.backgroundColor=g.backgroundColor;null!=f.view.backgroundPageShape&&null!=e.view.backgroundPageShape&&
(e.view.backgroundPageShape.fill=f.view.backgroundPageShape.fill);c.outline.view.clear(d.previousPage.root,!0);c.outline.view.validate()});return c};EditorUi.prototype.getServiceCount=function(a,b){var c=1;null==this.drive&&"function"!==typeof window.DriveClient||c++;b||null==this.dropbox&&"function"!==typeof window.DropboxClient||c++;null==this.oneDrive&&"function"!==typeof window.OneDriveClient||c++;b||null==this.gitHub||c++;b||null==this.gitLab||c++;b&&a&&isLocalStorage&&"1"==urlParams.browser&&
c++;return c};EditorUi.prototype.updateUi=function(){this.updateButtonContainer();this.updateActionStates();var a=this.getCurrentFile(),b=null!=a||"1"==urlParams.embed&&this.editor.graph.isEnabled();this.menus.get("viewPanels").setEnabled(b);this.menus.get("viewZoom").setEnabled(b);var d=("1"!=urlParams.embed||!this.editor.graph.isEnabled())&&(null==a||a.isRestricted());this.actions.get("makeCopy").setEnabled(!d);this.actions.get("print").setEnabled(!d);this.menus.get("exportAs").setEnabled(!d);this.menus.get("embed").setEnabled(!d);
d="1"!=urlParams.embed||this.editor.graph.isEnabled();this.menus.get("extras").setEnabled(d);Editor.enableCustomLibraries&&(this.menus.get("openLibraryFrom").setEnabled(d),this.menus.get("newLibrary").setEnabled(d));a="1"==urlParams.embed&&this.editor.graph.isEnabled()||null!=a&&a.isEditable();this.actions.get("image").setEnabled(b);this.actions.get("zoomIn").setEnabled(b);this.actions.get("zoomOut").setEnabled(b);this.actions.get("resetView").setEnabled(b);this.actions.get("undo").setEnabled(this.canUndo()&&
a);this.actions.get("redo").setEnabled(this.canRedo()&&a);this.menus.get("edit").setEnabled(b);this.menus.get("view").setEnabled(b);this.menus.get("importFrom").setEnabled(a);this.menus.get("arrange").setEnabled(a);null!=this.toolbar&&(null!=this.toolbar.edgeShapeMenu&&this.toolbar.edgeShapeMenu.setEnabled(a),null!=this.toolbar.edgeStyleMenu&&this.toolbar.edgeStyleMenu.setEnabled(a));this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=
-function(){};EditorUi.prototype.scheduleSanityCheck=function(){};EditorUi.prototype.stopSanityCheck=function(){};EditorUi.prototype.isDiagramActive=function(){var a=this.getCurrentFile();return null!=a&&a.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled()};var m=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){m.apply(this,arguments);var a=this.editor.graph,b=this.isDiagramActive(),d=this.getCurrentFile();this.actions.get("pageSetup").setEnabled(b);
+function(){};EditorUi.prototype.scheduleSanityCheck=function(){};EditorUi.prototype.stopSanityCheck=function(){};EditorUi.prototype.isDiagramActive=function(){var a=this.getCurrentFile();return null!=a&&a.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled()};var l=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){l.apply(this,arguments);var a=this.editor.graph,b=this.isDiagramActive(),d=this.getCurrentFile();this.actions.get("pageSetup").setEnabled(b);
this.actions.get("autosave").setEnabled(null!=d&&d.isEditable()&&d.isAutosaveOptional());this.actions.get("guides").setEnabled(b);this.actions.get("editData").setEnabled(b);this.actions.get("shadowVisible").setEnabled(b);this.actions.get("connectionArrows").setEnabled(b);this.actions.get("connectionPoints").setEnabled(b);this.actions.get("copyStyle").setEnabled(b&&!a.isSelectionEmpty());this.actions.get("pasteStyle").setEnabled(b&&!a.isSelectionEmpty());this.actions.get("editGeometry").setEnabled(a.getModel().isVertex(a.getSelectionCell()));
this.actions.get("createShape").setEnabled(b);this.actions.get("createRevision").setEnabled(b);this.actions.get("moveToFolder").setEnabled(null!=d);this.actions.get("makeCopy").setEnabled(null!=d&&!d.isRestricted());this.actions.get("editDiagram").setEnabled(b&&(null==d||!d.isRestricted()));this.actions.get("publishLink").setEnabled(null!=d&&!d.isRestricted());this.actions.get("tags").setEnabled("hidden"!=this.diagramContainer.style.visibility);this.actions.get("find").setEnabled("hidden"!=this.diagramContainer.style.visibility);
this.actions.get("layers").setEnabled("hidden"!=this.diagramContainer.style.visibility);this.actions.get("outline").setEnabled("hidden"!=this.diagramContainer.style.visibility);this.actions.get("rename").setEnabled(null!=d&&d.isRenamable()||"1"==urlParams.embed);this.actions.get("close").setEnabled(null!=d);this.menus.get("publish").setEnabled(null!=d&&!d.isRestricted());a=a.view.getState(a.getSelectionCell());this.actions.get("editShape").setEnabled(b&&null!=a&&null!=a.shape&&null!=a.shape.stencil)};
-var q=EditorUi.prototype.destroy;EditorUi.prototype.destroy=function(){null!=this.exportDialog&&(this.exportDialog.parentNode.removeChild(this.exportDialog),this.exportDialog=null);q.apply(this,arguments)};null!=window.ExportDialog&&(ExportDialog.showXmlOption=!1,ExportDialog.showGifOption=!1,ExportDialog.exportFile=function(a,b,d,e,k,m,q){var c=a.editor.graph;if("xml"==d)a.hideDialog(),a.saveData(b,"xml",mxUtils.getXml(a.editor.getGraphXml()),"text/xml");else if("svg"==d)a.hideDialog(),a.saveData(b,
-"svg",mxUtils.getXml(c.getSvg(e,k,m)),"image/svg+xml");else{var f=a.getFileData(!0,null,null,null,null,!0),g=c.getGraphBounds(),l=Math.floor(g.width*k/c.view.scale),n=Math.floor(g.height*k/c.view.scale);if(f.length<=MAX_REQUEST_SIZE&&l*n<MAX_AREA)if(a.hideDialog(),"png"!=d&&"jpg"!=d&&"jpeg"!=d||!a.isExportToCanvas()){var p={globalVars:c.getExportVariables()};a.saveRequest(b,d,function(a,c){return new mxXmlRequest(EXPORT_URL,"format="+d+"&base64="+(c||"0")+(null!=a?"&filename="+encodeURIComponent(a):
-"")+"&extras="+encodeURIComponent(JSON.stringify(p))+(0<q?"&dpi="+q:"")+"&bg="+(null!=e?e:"none")+"&w="+l+"&h="+n+"&border="+m+"&xml="+encodeURIComponent(f))})}else"png"==d?a.exportImage(k,null==e||"none"==e,!0,!1,!1,m,!0,!1,null,null,q):a.exportImage(k,!1,!0,!1,!1,m,!0,!1,"jpeg");else mxUtils.alert(mxResources.get("drawingTooLarge"))}});EditorUi.prototype.getDiagramTextContent=function(){this.editor.graph.setEnabled(!1);var a=this.editor.graph,b="";if(null!=this.pages)for(var d=0;d<this.pages.length;d++){var e=
+var q=EditorUi.prototype.destroy;EditorUi.prototype.destroy=function(){null!=this.exportDialog&&(this.exportDialog.parentNode.removeChild(this.exportDialog),this.exportDialog=null);q.apply(this,arguments)};null!=window.ExportDialog&&(ExportDialog.showXmlOption=!1,ExportDialog.showGifOption=!1,ExportDialog.exportFile=function(a,b,d,e,l,k,q){var c=a.editor.graph;if("xml"==d)a.hideDialog(),a.saveData(b,"xml",mxUtils.getXml(a.editor.getGraphXml()),"text/xml");else if("svg"==d)a.hideDialog(),a.saveData(b,
+"svg",mxUtils.getXml(c.getSvg(e,l,k)),"image/svg+xml");else{var f=a.getFileData(!0,null,null,null,null,!0),g=c.getGraphBounds(),m=Math.floor(g.width*l/c.view.scale),n=Math.floor(g.height*l/c.view.scale);if(f.length<=MAX_REQUEST_SIZE&&m*n<MAX_AREA)if(a.hideDialog(),"png"!=d&&"jpg"!=d&&"jpeg"!=d||!a.isExportToCanvas()){var p={globalVars:c.getExportVariables()};a.saveRequest(b,d,function(a,c){return new mxXmlRequest(EXPORT_URL,"format="+d+"&base64="+(c||"0")+(null!=a?"&filename="+encodeURIComponent(a):
+"")+"&extras="+encodeURIComponent(JSON.stringify(p))+(0<q?"&dpi="+q:"")+"&bg="+(null!=e?e:"none")+"&w="+m+"&h="+n+"&border="+k+"&xml="+encodeURIComponent(f))})}else"png"==d?a.exportImage(l,null==e||"none"==e,!0,!1,!1,k,!0,!1,null,null,q):a.exportImage(l,!1,!0,!1,!1,k,!0,!1,"jpeg");else mxUtils.alert(mxResources.get("drawingTooLarge"))}});EditorUi.prototype.getDiagramTextContent=function(){this.editor.graph.setEnabled(!1);var a=this.editor.graph,b="";if(null!=this.pages)for(var d=0;d<this.pages.length;d++){var e=
a;this.currentPage!=this.pages[d]&&(e=this.createTemporaryGraph(a.getStylesheet()),this.updatePageRoot(this.pages[d]),e.model.setRoot(this.pages[d].root));b+=this.pages[d].getName()+" "+e.getIndexableText()+" "}else b=a.getIndexableText();this.editor.graph.setEnabled(!0);return b};EditorUi.prototype.showRemotelyStoredLibrary=function(a){var c={},b=document.createElement("div");b.style.whiteSpace="nowrap";var d=document.createElement("h3");mxUtils.write(d,mxUtils.htmlEntities(a));d.style.cssText="width:100%;text-align:center;margin-top:0px;margin-bottom:12px";
-b.appendChild(d);var e=document.createElement("div");e.style.cssText="border:1px solid lightGray;overflow: auto;height:300px";e.innerHTML='<div style="text-align:center;padding:8px;"><img src="/images/spin.gif"></div>';var k={};try{var m=mxSettings.getCustomLibraries();for(a=0;a<m.length;a++){var q=m[a];if("R"==q.substring(0,1)){var u=JSON.parse(decodeURIComponent(q.substring(1)));k[u[0]]={id:u[0],title:u[1],downloadUrl:u[2]}}}}catch(A){}this.remoteInvoke("getCustomLibraries",null,null,function(a){e.innerHTML=
-"";if(0==a.length)e.innerHTML='<div style="text-align:center;padding-top:20px;color:gray;">'+mxUtils.htmlEntities(mxResources.get("noLibraries"))+"</div>";else for(var b=0;b<a.length;b++){var d=a[b];k[d.id]&&(c[d.id]=d);var f=this.addCheckbox(e,d.title,k[d.id]);(function(a,b){mxEvent.addListener(b,"change",function(){this.checked?c[a.id]=a:delete c[a.id]})})(d,f)}},mxUtils.bind(this,function(a){e.innerHTML="";var c=document.createElement("div");c.style.padding="8px";c.style.textAlign="center";mxUtils.write(c,
-mxResources.get("error")+": ");mxUtils.write(c,null!=a&&null!=a.message?a.message:mxResources.get("unknownError"));e.appendChild(c)}));b.appendChild(e);b=new CustomDialog(this,b,mxUtils.bind(this,function(){this.spinner.spin(document.body,mxResources.get("loading"));var a=0,b;for(b in c)null==k[b]&&(a++,mxUtils.bind(this,function(c){this.remoteInvoke("getFileContent",[c.downloadUrl],null,mxUtils.bind(this,function(b){a--;0==a&&this.spinner.stop();try{this.loadLibrary(new RemoteLibrary(this,b,c))}catch(x){this.handleError(x,
-mxResources.get("errorLoadingFile"))}}),mxUtils.bind(this,function(){a--;0==a&&this.spinner.stop();this.handleError(null,mxResources.get("errorLoadingFile"))}))})(c[b]));for(b in k)c[b]||this.closeLibrary(new RemoteLibrary(this,null,k[b]));0==a&&this.spinner.stop()}),null,null,"https://desk.draw.io/support/solutions/articles/16000092763");this.showDialog(b.container,340,375,!0,!0,null,null,null,null,!0)};EditorUi.prototype.remoteInvokableFns={getDiagramTextContent:{isAsync:!1},getLocalStorageFile:{isAsync:!1,
+b.appendChild(d);var e=document.createElement("div");e.style.cssText="border:1px solid lightGray;overflow: auto;height:300px";e.innerHTML='<div style="text-align:center;padding:8px;"><img src="/images/spin.gif"></div>';var l={};try{var k=mxSettings.getCustomLibraries();for(a=0;a<k.length;a++){var q=k[a];if("R"==q.substring(0,1)){var u=JSON.parse(decodeURIComponent(q.substring(1)));l[u[0]]={id:u[0],title:u[1],downloadUrl:u[2]}}}}catch(A){}this.remoteInvoke("getCustomLibraries",null,null,function(a){e.innerHTML=
+"";if(0==a.length)e.innerHTML='<div style="text-align:center;padding-top:20px;color:gray;">'+mxUtils.htmlEntities(mxResources.get("noLibraries"))+"</div>";else for(var b=0;b<a.length;b++){var d=a[b];l[d.id]&&(c[d.id]=d);var f=this.addCheckbox(e,d.title,l[d.id]);(function(a,b){mxEvent.addListener(b,"change",function(){this.checked?c[a.id]=a:delete c[a.id]})})(d,f)}},mxUtils.bind(this,function(a){e.innerHTML="";var c=document.createElement("div");c.style.padding="8px";c.style.textAlign="center";mxUtils.write(c,
+mxResources.get("error")+": ");mxUtils.write(c,null!=a&&null!=a.message?a.message:mxResources.get("unknownError"));e.appendChild(c)}));b.appendChild(e);b=new CustomDialog(this,b,mxUtils.bind(this,function(){this.spinner.spin(document.body,mxResources.get("loading"));var a=0,b;for(b in c)null==l[b]&&(a++,mxUtils.bind(this,function(c){this.remoteInvoke("getFileContent",[c.downloadUrl],null,mxUtils.bind(this,function(b){a--;0==a&&this.spinner.stop();try{this.loadLibrary(new RemoteLibrary(this,b,c))}catch(x){this.handleError(x,
+mxResources.get("errorLoadingFile"))}}),mxUtils.bind(this,function(){a--;0==a&&this.spinner.stop();this.handleError(null,mxResources.get("errorLoadingFile"))}))})(c[b]));for(b in l)c[b]||this.closeLibrary(new RemoteLibrary(this,null,l[b]));0==a&&this.spinner.stop()}),null,null,"https://desk.draw.io/support/solutions/articles/16000092763");this.showDialog(b.container,340,375,!0,!0,null,null,null,null,!0)};EditorUi.prototype.remoteInvokableFns={getDiagramTextContent:{isAsync:!1},getLocalStorageFile:{isAsync:!1,
allowedDomains:["app.diagrams.net"]},getLocalStorageFileNames:{isAsync:!1,allowedDomains:["app.diagrams.net"]},setMigratedFlag:{isAsync:!1,allowedDomains:["app.diagrams.net"]}};EditorUi.prototype.remoteInvokeCallbacks=[];EditorUi.prototype.remoteInvokeQueue=[];EditorUi.prototype.handleRemoteInvokeReady=function(a){this.remoteWin=a;for(var c=0;c<this.remoteInvokeQueue.length;c++)a.postMessage(this.remoteInvokeQueue[c],"*");this.remoteInvokeQueue=[]};EditorUi.prototype.handleRemoteInvokeResponse=function(a){var c=
-a.msgMarkers,b=this.remoteInvokeCallbacks[c.callbackId];if(null==b)throw Error("No callback for "+(null!=c?c.callbackId:"null"));a.error?b.error&&b.error(a.error.errResp):b.callback&&b.callback.apply(this,a.resp);this.remoteInvokeCallbacks[c.callbackId]=null};EditorUi.prototype.remoteInvoke=function(a,b,d,e,k){var c=!0,f=window.setTimeout(mxUtils.bind(this,function(){c=!1;k({code:App.ERROR_TIMEOUT,message:mxResources.get("timeout")})}),this.timeout),g=mxUtils.bind(this,function(){window.clearTimeout(f);
-c&&e.apply(this,arguments)});d=d||{};d.callbackId=this.remoteInvokeCallbacks.length;this.remoteInvokeCallbacks.push({callback:g,error:k});a=JSON.stringify({event:"remoteInvoke",funtionName:a,functionArgs:b,msgMarkers:d});null!=this.remoteWin?this.remoteWin.postMessage(a,"*"):this.remoteInvokeQueue.push(a)};EditorUi.prototype.handleRemoteInvoke=function(a,b){var c=mxUtils.bind(this,function(c,b){var d={event:"remoteInvokeResponse",msgMarkers:a.msgMarkers};null!=b?d.error={errResp:b}:null!=c&&(d.resp=
-c);this.remoteWin.postMessage(JSON.stringify(d),"*")});try{var d=a.funtionName,f=this.remoteInvokableFns[d];if(null!=f&&"function"===typeof this[d]){if(f.allowedDomains){for(var e=!1,k=0;k<f.allowedDomains.length;k++)if(b=="https://"+f.allowedDomains[k]){e=!0;break}if(!e){c(null,"Invalid Call: "+d+" is not allowed.");return}}var m=a.functionArgs;Array.isArray(m)||(m=[]);if(f.isAsync)m.push(function(){c(Array.prototype.slice.apply(arguments))}),m.push(function(a){c(null,a||"Unkown Error")}),this[d].apply(this,
-m);else{var q=this[d].apply(this,m);c([q])}}else c(null,"Invalid Call: "+d+" is not found.")}catch(A){c(null,"Invalid Call: An error occured, "+A.message)}};EditorUi.prototype.openDatabase=function(a,b){if(null==this.database){var c=window.indexedDB||window.mozIndexedDB||window.webkitIndexedDB;if(null!=c)try{var d=c.open("database",2);d.onupgradeneeded=function(a){try{var c=d.result;1>a.oldVersion&&c.createObjectStore("objects",{keyPath:"key"});2>a.oldVersion&&(c.createObjectStore("files",{keyPath:"title"}),
+a.msgMarkers,b=this.remoteInvokeCallbacks[c.callbackId];if(null==b)throw Error("No callback for "+(null!=c?c.callbackId:"null"));a.error?b.error&&b.error(a.error.errResp):b.callback&&b.callback.apply(this,a.resp);this.remoteInvokeCallbacks[c.callbackId]=null};EditorUi.prototype.remoteInvoke=function(a,b,d,e,l){var c=!0,f=window.setTimeout(mxUtils.bind(this,function(){c=!1;l({code:App.ERROR_TIMEOUT,message:mxResources.get("timeout")})}),this.timeout),g=mxUtils.bind(this,function(){window.clearTimeout(f);
+c&&e.apply(this,arguments)});d=d||{};d.callbackId=this.remoteInvokeCallbacks.length;this.remoteInvokeCallbacks.push({callback:g,error:l});a=JSON.stringify({event:"remoteInvoke",funtionName:a,functionArgs:b,msgMarkers:d});null!=this.remoteWin?this.remoteWin.postMessage(a,"*"):this.remoteInvokeQueue.push(a)};EditorUi.prototype.handleRemoteInvoke=function(a,b){var c=mxUtils.bind(this,function(c,b){var d={event:"remoteInvokeResponse",msgMarkers:a.msgMarkers};null!=b?d.error={errResp:b}:null!=c&&(d.resp=
+c);this.remoteWin.postMessage(JSON.stringify(d),"*")});try{var d=a.funtionName,f=this.remoteInvokableFns[d];if(null!=f&&"function"===typeof this[d]){if(f.allowedDomains){for(var e=!1,l=0;l<f.allowedDomains.length;l++)if(b=="https://"+f.allowedDomains[l]){e=!0;break}if(!e){c(null,"Invalid Call: "+d+" is not allowed.");return}}var k=a.functionArgs;Array.isArray(k)||(k=[]);if(f.isAsync)k.push(function(){c(Array.prototype.slice.apply(arguments))}),k.push(function(a){c(null,a||"Unkown Error")}),this[d].apply(this,
+k);else{var q=this[d].apply(this,k);c([q])}}else c(null,"Invalid Call: "+d+" is not found.")}catch(A){c(null,"Invalid Call: An error occured, "+A.message)}};EditorUi.prototype.openDatabase=function(a,b){if(null==this.database){var c=window.indexedDB||window.mozIndexedDB||window.webkitIndexedDB;if(null!=c)try{var d=c.open("database",2);d.onupgradeneeded=function(a){try{var c=d.result;1>a.oldVersion&&c.createObjectStore("objects",{keyPath:"key"});2>a.oldVersion&&(c.createObjectStore("files",{keyPath:"title"}),
c.createObjectStore("filesInfo",{keyPath:"title"}),EditorUi.migrateStorageFiles=isLocalStorage)}catch(v){null!=b&&b(v)}};d.onsuccess=mxUtils.bind(this,function(c){var b=d.result;this.database=b;EditorUi.migrateStorageFiles&&(StorageFile.migrate(b),EditorUi.migrateStorageFiles=!1);"app.diagrams.net"!=location.host||this.drawioMigrationStarted||(this.drawioMigrationStarted=!0,this.getDatabaseItem(".drawioMigrated3",mxUtils.bind(this,function(a){if(!a||"1"==urlParams.forceMigration){var c=document.createElement("iframe");
-c.style.display="none";c.setAttribute("src","https://www.draw.io?embed=1&proto=json&forceMigration="+urlParams.forceMigration);document.body.appendChild(c);var b=!0,d=!1,f,e=0,g=mxUtils.bind(this,function(){d=!0;this.setDatabaseItem(".drawioMigrated3",!0);c.contentWindow.postMessage(JSON.stringify({action:"remoteInvoke",funtionName:"setMigratedFlag"}),"*")}),k=mxUtils.bind(this,function(){e++;l()}),l=mxUtils.bind(this,function(){try{if(e>=f.length)g();else{var a=f[e];StorageFile.getFileContent(this,
-a,mxUtils.bind(this,function(b){null==b||".scratchpad"==a&&b==this.emptyLibraryXml?c.contentWindow.postMessage(JSON.stringify({action:"remoteInvoke",funtionName:"getLocalStorageFile",functionArgs:[a]}),"*"):k()}),k)}}catch(J){console.log(J)}}),m=mxUtils.bind(this,function(a){try{this.setDatabaseItem(null,[{title:a.title,size:a.data.length,lastModified:Date.now(),type:a.isLib?"L":"F"},{title:a.title,data:a.data}],k,k,["filesInfo","files"])}catch(J){console.log(J)}});a=mxUtils.bind(this,function(a){try{if(a.source==
-c.contentWindow){var e={};try{e=JSON.parse(a.data)}catch(H){}"init"==e.event?(c.contentWindow.postMessage(JSON.stringify({action:"remoteInvokeReady"}),"*"),c.contentWindow.postMessage(JSON.stringify({action:"remoteInvoke",funtionName:"getLocalStorageFileNames"}),"*")):"remoteInvokeResponse"!=e.event||d||(b?null!=e.resp&&0<e.resp.length&&null!=e.resp[0]?(f=e.resp[0],b=!1,l()):g():null!=e.resp&&0<e.resp.length&&null!=e.resp[0]?m(e.resp[0]):k())}}catch(H){console.log(H)}});window.addEventListener("message",
-a)}})));a(b);b.onversionchange=function(){b.close()}});d.onerror=b;d.onblocked=function(){}}catch(l){null!=b&&b(l)}else null!=b&&b()}else a(this.database)};EditorUi.prototype.setDatabaseItem=function(a,b,d,e,k){this.openDatabase(mxUtils.bind(this,function(c){try{k=k||"objects";Array.isArray(k)||(k=[k],a=[a],b=[b]);var f=c.transaction(k,"readwrite");f.oncomplete=d;f.onerror=e;for(c=0;c<k.length;c++)f.objectStore(k[c]).put(null!=a&&null!=a[c]?{key:a[c],data:b[c]}:b[c])}catch(t){null!=e&&e(t)}}),e)};
+c.style.display="none";c.setAttribute("src","https://www.draw.io?embed=1&proto=json&forceMigration="+urlParams.forceMigration);document.body.appendChild(c);var b=!0,d=!1,f,e=0,g=mxUtils.bind(this,function(){d=!0;this.setDatabaseItem(".drawioMigrated3",!0);c.contentWindow.postMessage(JSON.stringify({action:"remoteInvoke",funtionName:"setMigratedFlag"}),"*")}),l=mxUtils.bind(this,function(){e++;m()}),m=mxUtils.bind(this,function(){try{if(e>=f.length)g();else{var a=f[e];StorageFile.getFileContent(this,
+a,mxUtils.bind(this,function(b){null==b||".scratchpad"==a&&b==this.emptyLibraryXml?c.contentWindow.postMessage(JSON.stringify({action:"remoteInvoke",funtionName:"getLocalStorageFile",functionArgs:[a]}),"*"):l()}),l)}}catch(J){console.log(J)}}),k=mxUtils.bind(this,function(a){try{this.setDatabaseItem(null,[{title:a.title,size:a.data.length,lastModified:Date.now(),type:a.isLib?"L":"F"},{title:a.title,data:a.data}],l,l,["filesInfo","files"])}catch(J){console.log(J)}});a=mxUtils.bind(this,function(a){try{if(a.source==
+c.contentWindow){var e={};try{e=JSON.parse(a.data)}catch(H){}"init"==e.event?(c.contentWindow.postMessage(JSON.stringify({action:"remoteInvokeReady"}),"*"),c.contentWindow.postMessage(JSON.stringify({action:"remoteInvoke",funtionName:"getLocalStorageFileNames"}),"*")):"remoteInvokeResponse"!=e.event||d||(b?null!=e.resp&&0<e.resp.length&&null!=e.resp[0]?(f=e.resp[0],b=!1,m()):g():null!=e.resp&&0<e.resp.length&&null!=e.resp[0]?k(e.resp[0]):l())}}catch(H){console.log(H)}});window.addEventListener("message",
+a)}})));a(b);b.onversionchange=function(){b.close()}});d.onerror=b;d.onblocked=function(){}}catch(m){null!=b&&b(m)}else null!=b&&b()}else a(this.database)};EditorUi.prototype.setDatabaseItem=function(a,b,d,e,l){this.openDatabase(mxUtils.bind(this,function(c){try{l=l||"objects";Array.isArray(l)||(l=[l],a=[a],b=[b]);var f=c.transaction(l,"readwrite");f.oncomplete=d;f.onerror=e;for(c=0;c<l.length;c++)f.objectStore(l[c]).put(null!=a&&null!=a[c]?{key:a[c],data:b[c]}:b[c])}catch(t){null!=e&&e(t)}}),e)};
EditorUi.prototype.removeDatabaseItem=function(a,b,d,e){this.openDatabase(mxUtils.bind(this,function(c){e=e||"objects";Array.isArray(e)||(e=[e],a=[a]);c=c.transaction(e,"readwrite");c.oncomplete=b;c.onerror=d;for(var f=0;f<e.length;f++)c.objectStore(e[f])["delete"](a[f])}),d)};EditorUi.prototype.getDatabaseItem=function(a,b,d,e){this.openDatabase(mxUtils.bind(this,function(c){try{e=e||"objects";var f=c.transaction([e],"readonly").objectStore(e).get(a);f.onsuccess=function(){b(f.result)};f.onerror=
d}catch(v){null!=d&&d(v)}}),d)};EditorUi.prototype.getDatabaseItems=function(a,b,d){this.openDatabase(mxUtils.bind(this,function(c){try{d=d||"objects";var e=c.transaction([d],"readonly").objectStore(d).openCursor(IDBKeyRange.lowerBound(0)),f=[];e.onsuccess=function(c){null==c.target.result?a(f):(f.push(c.target.result.value),c.target.result["continue"]())};e.onerror=b}catch(v){null!=b&&b(v)}}),b)};EditorUi.prototype.getDatabaseItemKeys=function(a,b,d){this.openDatabase(mxUtils.bind(this,function(c){try{d=
d||"objects";var e=c.transaction([d],"readonly").objectStore(d).getAllKeys();e.onsuccess=function(){a(e.result)};e.onerror=b}catch(n){null!=b&&b(n)}}),b)};EditorUi.prototype.commentsSupported=function(){var a=this.getCurrentFile();return null!=a?a.commentsSupported():!1};EditorUi.prototype.commentsRefreshNeeded=function(){var a=this.getCurrentFile();return null!=a?a.commentsRefreshNeeded():!0};EditorUi.prototype.commentsSaveNeeded=function(){var a=this.getCurrentFile();return null!=a?a.commentsSaveNeeded():
!1};EditorUi.prototype.getComments=function(a,b){var c=this.getCurrentFile();null!=c?c.getComments(a,b):a([])};EditorUi.prototype.addComment=function(a,b,d){var c=this.getCurrentFile();null!=c?c.addComment(a,b,d):b(Date.now())};EditorUi.prototype.canReplyToReplies=function(){var a=this.getCurrentFile();return null!=a?a.canReplyToReplies():!0};EditorUi.prototype.canComment=function(){var a=this.getCurrentFile();return null!=a?a.canComment():!0};EditorUi.prototype.newComment=function(a,b){var c=this.getCurrentFile();
return null!=c?c.newComment(a,b):new DrawioComment(this,null,a,Date.now(),Date.now(),!1,b)};EditorUi.prototype.isRevisionHistorySupported=function(){var a=this.getCurrentFile();return null!=a&&a.isRevisionHistorySupported()};EditorUi.prototype.getRevisions=function(a,b){var c=this.getCurrentFile();null!=c&&c.getRevisions?c.getRevisions(a,b):b({message:mxResources.get("unknownError")})};EditorUi.prototype.isRevisionHistoryEnabled=function(){var a=this.getCurrentFile();return null!=a&&(a.constructor==
-DriveFile&&a.isEditable()||a.constructor==DropboxFile)};EditorUi.prototype.getServiceName=function(){return"draw.io"};EditorUi.prototype.addRemoteServiceSecurityCheck=function(a){a.setRequestHeader("Content-Language","da, mi, en, de-DE")};EditorUi.prototype.loadUrl=function(a,b,d,e,k,m,q,t){EditorUi.logEvent("SHOULD NOT BE CALLED: loadUrl");return this.editor.loadUrl(a,b,d,e,k,m,q,t)};EditorUi.prototype.loadFonts=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: loadFonts");return this.editor.loadFonts(a)};
-EditorUi.prototype.createSvgDataUri=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: createSvgDataUri");return Editor.createSvgDataUri(a)};EditorUi.prototype.embedCssFonts=function(a,b){EditorUi.logEvent("SHOULD NOT BE CALLED: embedCssFonts");return this.editor.embedCssFonts(a,b)};EditorUi.prototype.embedExtFonts=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: embedExtFonts");return this.editor.embedExtFonts(a)};EditorUi.prototype.exportToCanvas=function(a,b,d,e,k,m,q,t,u,A,B,D,C,x,F){EditorUi.logEvent("SHOULD NOT BE CALLED: exportToCanvas");
-return this.editor.exportToCanvas(a,b,d,e,k,m,q,t,u,A,B,D,C,x,F)};EditorUi.prototype.createImageUrlConverter=function(){EditorUi.logEvent("SHOULD NOT BE CALLED: createImageUrlConverter");return this.editor.createImageUrlConverter()};EditorUi.prototype.convertImages=function(a,b,d,e){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImages");return this.editor.convertImages(a,b,d,e)};EditorUi.prototype.convertImageToDataUri=function(a,b){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImageToDataUri");
-return this.editor.convertImageToDataUri(a,b)};EditorUi.prototype.base64Encode=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: base64Encode");return Editor.base64Encode(a)};EditorUi.prototype.updateCRC=function(a,b,d,e){EditorUi.logEvent("SHOULD NOT BE CALLED: updateCRC");return Editor.updateCRC(a,b,d,e)};EditorUi.prototype.crc32=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: crc32");return Editor.crc32(a)};EditorUi.prototype.writeGraphModelToPng=function(a,b,d,e,k){EditorUi.logEvent("SHOULD NOT BE CALLED: writeGraphModelToPng");
-return Editor.writeGraphModelToPng(a,b,d,e,k)};EditorUi.prototype.getLocalStorageFileNames=function(){if("1"==localStorage.getItem(".localStorageMigrated")&&"1"!=urlParams.forceMigration)return null;for(var a=[],b=0;b<localStorage.length;b++){var d=localStorage.key(b),e=localStorage.getItem(d);if(0<d.length&&(".scratchpad"==d||"."!=d.charAt(0))&&0<e.length){var k="<mxfile "===e.substring(0,8)||"<?xml"===e.substring(0,5)||"\x3c!--[if IE]>"===e.substring(0,12),e="<mxlibrary>"===e.substring(0,11);(k||
+DriveFile&&a.isEditable()||a.constructor==DropboxFile)};EditorUi.prototype.getServiceName=function(){return"draw.io"};EditorUi.prototype.addRemoteServiceSecurityCheck=function(a){a.setRequestHeader("Content-Language","da, mi, en, de-DE")};EditorUi.prototype.loadUrl=function(a,b,d,e,l,k,q,t){EditorUi.logEvent("SHOULD NOT BE CALLED: loadUrl");return this.editor.loadUrl(a,b,d,e,l,k,q,t)};EditorUi.prototype.loadFonts=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: loadFonts");return this.editor.loadFonts(a)};
+EditorUi.prototype.createSvgDataUri=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: createSvgDataUri");return Editor.createSvgDataUri(a)};EditorUi.prototype.embedCssFonts=function(a,b){EditorUi.logEvent("SHOULD NOT BE CALLED: embedCssFonts");return this.editor.embedCssFonts(a,b)};EditorUi.prototype.embedExtFonts=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: embedExtFonts");return this.editor.embedExtFonts(a)};EditorUi.prototype.exportToCanvas=function(a,b,d,e,l,k,q,t,u,A,B,D,C,x,F){EditorUi.logEvent("SHOULD NOT BE CALLED: exportToCanvas");
+return this.editor.exportToCanvas(a,b,d,e,l,k,q,t,u,A,B,D,C,x,F)};EditorUi.prototype.createImageUrlConverter=function(){EditorUi.logEvent("SHOULD NOT BE CALLED: createImageUrlConverter");return this.editor.createImageUrlConverter()};EditorUi.prototype.convertImages=function(a,b,d,e){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImages");return this.editor.convertImages(a,b,d,e)};EditorUi.prototype.convertImageToDataUri=function(a,b){EditorUi.logEvent("SHOULD NOT BE CALLED: convertImageToDataUri");
+return this.editor.convertImageToDataUri(a,b)};EditorUi.prototype.base64Encode=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: base64Encode");return Editor.base64Encode(a)};EditorUi.prototype.updateCRC=function(a,b,d,e){EditorUi.logEvent("SHOULD NOT BE CALLED: updateCRC");return Editor.updateCRC(a,b,d,e)};EditorUi.prototype.crc32=function(a){EditorUi.logEvent("SHOULD NOT BE CALLED: crc32");return Editor.crc32(a)};EditorUi.prototype.writeGraphModelToPng=function(a,b,d,e,l){EditorUi.logEvent("SHOULD NOT BE CALLED: writeGraphModelToPng");
+return Editor.writeGraphModelToPng(a,b,d,e,l)};EditorUi.prototype.getLocalStorageFileNames=function(){if("1"==localStorage.getItem(".localStorageMigrated")&&"1"!=urlParams.forceMigration)return null;for(var a=[],b=0;b<localStorage.length;b++){var d=localStorage.key(b),e=localStorage.getItem(d);if(0<d.length&&(".scratchpad"==d||"."!=d.charAt(0))&&0<e.length){var l="<mxfile "===e.substring(0,8)||"<?xml"===e.substring(0,5)||"\x3c!--[if IE]>"===e.substring(0,12),e="<mxlibrary>"===e.substring(0,11);(l||
e)&&a.push(d)}}return a};EditorUi.prototype.getLocalStorageFile=function(a){if("1"==localStorage.getItem(".localStorageMigrated")&&"1"!=urlParams.forceMigration)return null;var b=localStorage.getItem(a);return{title:a,data:b,isLib:"<mxlibrary>"===b.substring(0,11)}};EditorUi.prototype.setMigratedFlag=function(){localStorage.setItem(".localStorageMigrated","1")}})();
-var CommentsWindow=function(a,b,e,d,k,m){function q(){for(var a=D.getElementsByTagName("div"),b=0,c=0;c<a.length;c++)"none"!=a[c].style.display&&a[c].parentNode==D&&b++;C.style.display=0==b?"block":"none"}function c(a,b,c,d){function e(){b.removeChild(k);b.removeChild(m);g.style.display="block";f.style.display="block"}u={div:b,comment:a,saveCallback:c,deleteOnCancel:d};var f=b.querySelector(".geCommentTxt"),g=b.querySelector(".geCommentActionsList"),k=document.createElement("textarea");k.className=
-"geCommentEditTxtArea";k.style.minHeight=f.offsetHeight+"px";k.value=a.content;b.insertBefore(k,f);var m=document.createElement("div");m.className="geCommentEditBtns";var l=mxUtils.button(mxResources.get("cancel"),function(){d?(b.parentNode.removeChild(b),q()):e();u=null});l.className="geCommentEditBtn";m.appendChild(l);var n=mxUtils.button(mxResources.get("save"),function(){f.innerHTML="";a.content=k.value;mxUtils.write(f,a.content);e();c(a);u=null});mxEvent.addListener(k,"keydown",mxUtils.bind(this,
-function(a){mxEvent.isConsumed(a)||((mxEvent.isControlDown(a)||mxClient.IS_MAC&&mxEvent.isMetaDown(a))&&13==a.keyCode?(n.click(),mxEvent.consume(a)):27==a.keyCode&&(l.click(),mxEvent.consume(a)))}));n.focus();n.className="geCommentEditBtn gePrimaryBtn";m.appendChild(n);b.insertBefore(m,f);g.style.display="none";f.style.display="none";k.focus()}function f(b,c){c.innerHTML="";var d=new Date(b.modifiedDate),e=a.timeSince(d);null==e&&(e=mxResources.get("lessThanAMinute"));mxUtils.write(c,mxResources.get("timeAgo",
-[e],"{1} ago"));c.setAttribute("title",d.toLocaleDateString()+" "+d.toLocaleTimeString())}function g(a){var b=document.createElement("img");b.className="geCommentBusyImg";b.src=IMAGE_PATH+"/spin.gif";a.appendChild(b);a.busyImg=b}function p(a){a.style.border="1px solid red";a.removeChild(a.busyImg)}function l(a){a.style.border="";a.removeChild(a.busyImg)}function n(b,d,e,k,m){function z(a,c,d){var e=document.createElement("li");e.className="geCommentAction";var f=document.createElement("a");f.className=
-"geCommentActionLnk";mxUtils.write(f,a);e.appendChild(f);mxEvent.addListener(f,"click",function(a){c(a,b);a.preventDefault();mxEvent.consume(a)});B.appendChild(e);d&&(e.style.display="none")}function x(){function a(b){c.push(d);if(null!=b.replies)for(var e=0;e<b.replies.length;e++)d=d.nextSibling,a(b.replies[e])}var c=[],d=y;a(b);return{pdiv:d,replies:c}}function F(d,e,f,m,q){function u(){g(F);b.addReply(v,function(a){v.id=a;b.replies.push(v);l(F);f&&f()},function(b){t();p(F);a.handleError(b,null,
-null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))},m,q)}function t(){c(v,F,function(a){u()},!0)}var z=x().pdiv,v=a.newComment(d,a.getCurrentUser());v.pCommentId=b.id;null==b.replies&&(b.replies=[]);var F=n(v,b.replies,z,k+1);e?t():u()}if(m||!b.isResolved){C.style.display="none";var y=document.createElement("div");y.className="geCommentContainer";y.setAttribute("data-commentId",b.id);y.style.marginLeft=20*k+5+"px";b.isResolved&&"dark"!=uiTheme&&(y.style.backgroundColor="ghostWhite");
+var CommentsWindow=function(a,b,e,d,k,l){function q(){for(var a=D.getElementsByTagName("div"),b=0,c=0;c<a.length;c++)"none"!=a[c].style.display&&a[c].parentNode==D&&b++;C.style.display=0==b?"block":"none"}function c(a,b,c,d){function e(){b.removeChild(l);b.removeChild(k);g.style.display="block";f.style.display="block"}u={div:b,comment:a,saveCallback:c,deleteOnCancel:d};var f=b.querySelector(".geCommentTxt"),g=b.querySelector(".geCommentActionsList"),l=document.createElement("textarea");l.className=
+"geCommentEditTxtArea";l.style.minHeight=f.offsetHeight+"px";l.value=a.content;b.insertBefore(l,f);var k=document.createElement("div");k.className="geCommentEditBtns";var m=mxUtils.button(mxResources.get("cancel"),function(){d?(b.parentNode.removeChild(b),q()):e();u=null});m.className="geCommentEditBtn";k.appendChild(m);var n=mxUtils.button(mxResources.get("save"),function(){f.innerHTML="";a.content=l.value;mxUtils.write(f,a.content);e();c(a);u=null});mxEvent.addListener(l,"keydown",mxUtils.bind(this,
+function(a){mxEvent.isConsumed(a)||((mxEvent.isControlDown(a)||mxClient.IS_MAC&&mxEvent.isMetaDown(a))&&13==a.keyCode?(n.click(),mxEvent.consume(a)):27==a.keyCode&&(m.click(),mxEvent.consume(a)))}));n.focus();n.className="geCommentEditBtn gePrimaryBtn";k.appendChild(n);b.insertBefore(k,f);g.style.display="none";f.style.display="none";l.focus()}function f(b,c){c.innerHTML="";var d=new Date(b.modifiedDate),e=a.timeSince(d);null==e&&(e=mxResources.get("lessThanAMinute"));mxUtils.write(c,mxResources.get("timeAgo",
+[e],"{1} ago"));c.setAttribute("title",d.toLocaleDateString()+" "+d.toLocaleTimeString())}function g(a){var b=document.createElement("img");b.className="geCommentBusyImg";b.src=IMAGE_PATH+"/spin.gif";a.appendChild(b);a.busyImg=b}function p(a){a.style.border="1px solid red";a.removeChild(a.busyImg)}function m(a){a.style.border="";a.removeChild(a.busyImg)}function n(b,d,e,l,k){function z(a,c,d){var e=document.createElement("li");e.className="geCommentAction";var f=document.createElement("a");f.className=
+"geCommentActionLnk";mxUtils.write(f,a);e.appendChild(f);mxEvent.addListener(f,"click",function(a){c(a,b);a.preventDefault();mxEvent.consume(a)});B.appendChild(e);d&&(e.style.display="none")}function x(){function a(b){c.push(d);if(null!=b.replies)for(var e=0;e<b.replies.length;e++)d=d.nextSibling,a(b.replies[e])}var c=[],d=y;a(b);return{pdiv:d,replies:c}}function F(d,e,f,k,q){function u(){g(F);b.addReply(v,function(a){v.id=a;b.replies.push(v);m(F);f&&f()},function(b){t();p(F);a.handleError(b,null,
+null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))},k,q)}function t(){c(v,F,function(a){u()},!0)}var z=x().pdiv,v=a.newComment(d,a.getCurrentUser());v.pCommentId=b.id;null==b.replies&&(b.replies=[]);var F=n(v,b.replies,z,l+1);e?t():u()}if(k||!b.isResolved){C.style.display="none";var y=document.createElement("div");y.className="geCommentContainer";y.setAttribute("data-commentId",b.id);y.style.marginLeft=20*l+5+"px";b.isResolved&&"dark"!=uiTheme&&(y.style.backgroundColor="ghostWhite");
var A=document.createElement("div");A.className="geCommentHeader";var E=document.createElement("img");E.className="geCommentUserImg";E.src=b.user.pictureUrl||Editor.userImage;A.appendChild(E);E=document.createElement("div");E.className="geCommentHeaderTxt";A.appendChild(E);var L=document.createElement("div");L.className="geCommentUsername";mxUtils.write(L,b.user.displayName||"");E.appendChild(L);L=document.createElement("div");L.className="geCommentDate";L.setAttribute("data-commentId",b.id);f(b,
-L);E.appendChild(L);y.appendChild(A);A=document.createElement("div");A.className="geCommentTxt";mxUtils.write(A,b.content||"");y.appendChild(A);A=document.createElement("div");A.className="geCommentActions";var B=document.createElement("ul");B.className="geCommentActionsList";A.appendChild(B);v||0!=k&&!t||z(mxResources.get("reply"),function(){F("",!0)},b.isResolved);E=a.getCurrentUser();null==E||E.id!=b.user.id||v||(z(mxResources.get("edit"),function(){function d(){c(b,y,function(){g(y);b.editComment(b.content,
-function(){l(y)},function(b){p(y);d();a.handleError(b,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})})}d()},b.isResolved),z(mxResources.get("delete"),function(){a.confirm(mxResources.get("areYouSure"),function(){g(y);b.deleteComment(function(){for(var a=x(b).replies,c=0;c<a.length;c++)D.removeChild(a[c]);for(c=0;c<d.length;c++)if(d[c]==b){d.splice(c,1);break}C.style.display=0==D.getElementsByTagName("div").length?"block":"none"},function(b){p(y);a.handleError(b,null,null,
-null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})})},b.isResolved));v||0!=k||z(b.isResolved?mxResources.get("reopen"):mxResources.get("resolve"),function(a){function c(){var c=a.target;c.innerHTML="";b.isResolved=!b.isResolved;mxUtils.write(c,b.isResolved?mxResources.get("reopen"):mxResources.get("resolve"));for(var d=b.isResolved?"none":"",e=x(b).replies,f="dark"==uiTheme?"transparent":b.isResolved?"ghostWhite":"white",g=0;g<e.length;g++){e[g].style.backgroundColor=f;for(var k=e[g].querySelectorAll(".geCommentAction"),
-m=0;m<k.length;m++)k[m]!=c.parentNode&&(k[m].style.display=d);G||(e[g].style.display="none")}q()}b.isResolved?F(mxResources.get("reOpened")+": ",!0,c,!1,!0):F(mxResources.get("markedAsResolved"),!1,c,!0)});y.appendChild(A);null!=e?D.insertBefore(y,e.nextSibling):D.appendChild(y);for(e=0;null!=b.replies&&e<b.replies.length;e++)A=b.replies[e],A.isResolved=b.isResolved,n(A,b.replies,null,k+1,m);null!=u&&(u.comment.id==b.id?(m=b.content,b.content=u.comment.content,c(b,y,u.saveCallback,u.deleteOnCancel),
-b.content=m):null==u.comment.id&&u.comment.pCommentId==b.id&&(D.appendChild(u.div),c(u.comment,u.div,u.saveCallback,u.deleteOnCancel)));return y}}var v=!a.canComment(),t=a.canReplyToReplies(),u=null,A=document.createElement("div");A.className="geCommentsWin";A.style.background="white"==Dialog.backdropColor?"whiteSmoke":Dialog.backdropColor;var B=EditorUi.compactUi?"26px":"30px",D=document.createElement("div");D.className="geCommentsList";D.style.backgroundColor="white"==Dialog.backdropColor?"whiteSmoke":
+L);E.appendChild(L);y.appendChild(A);A=document.createElement("div");A.className="geCommentTxt";mxUtils.write(A,b.content||"");y.appendChild(A);A=document.createElement("div");A.className="geCommentActions";var B=document.createElement("ul");B.className="geCommentActionsList";A.appendChild(B);v||0!=l&&!t||z(mxResources.get("reply"),function(){F("",!0)},b.isResolved);E=a.getCurrentUser();null==E||E.id!=b.user.id||v||(z(mxResources.get("edit"),function(){function d(){c(b,y,function(){g(y);b.editComment(b.content,
+function(){m(y)},function(b){p(y);d();a.handleError(b,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})})}d()},b.isResolved),z(mxResources.get("delete"),function(){a.confirm(mxResources.get("areYouSure"),function(){g(y);b.deleteComment(function(){for(var a=x(b).replies,c=0;c<a.length;c++)D.removeChild(a[c]);for(c=0;c<d.length;c++)if(d[c]==b){d.splice(c,1);break}C.style.display=0==D.getElementsByTagName("div").length?"block":"none"},function(b){p(y);a.handleError(b,null,null,
+null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})})},b.isResolved));v||0!=l||z(b.isResolved?mxResources.get("reopen"):mxResources.get("resolve"),function(a){function c(){var c=a.target;c.innerHTML="";b.isResolved=!b.isResolved;mxUtils.write(c,b.isResolved?mxResources.get("reopen"):mxResources.get("resolve"));for(var d=b.isResolved?"none":"",e=x(b).replies,f="dark"==uiTheme?"transparent":b.isResolved?"ghostWhite":"white",g=0;g<e.length;g++){e[g].style.backgroundColor=f;for(var l=e[g].querySelectorAll(".geCommentAction"),
+k=0;k<l.length;k++)l[k]!=c.parentNode&&(l[k].style.display=d);G||(e[g].style.display="none")}q()}b.isResolved?F(mxResources.get("reOpened")+": ",!0,c,!1,!0):F(mxResources.get("markedAsResolved"),!1,c,!0)});y.appendChild(A);null!=e?D.insertBefore(y,e.nextSibling):D.appendChild(y);for(e=0;null!=b.replies&&e<b.replies.length;e++)A=b.replies[e],A.isResolved=b.isResolved,n(A,b.replies,null,l+1,k);null!=u&&(u.comment.id==b.id?(k=b.content,b.content=u.comment.content,c(b,y,u.saveCallback,u.deleteOnCancel),
+b.content=k):null==u.comment.id&&u.comment.pCommentId==b.id&&(D.appendChild(u.div),c(u.comment,u.div,u.saveCallback,u.deleteOnCancel)));return y}}var v=!a.canComment(),t=a.canReplyToReplies(),u=null,A=document.createElement("div");A.className="geCommentsWin";A.style.background="white"==Dialog.backdropColor?"whiteSmoke":Dialog.backdropColor;var B=EditorUi.compactUi?"26px":"30px",D=document.createElement("div");D.className="geCommentsList";D.style.backgroundColor="white"==Dialog.backdropColor?"whiteSmoke":
Dialog.backdropColor;D.style.bottom=parseInt(B)+7+"px";A.appendChild(D);var C=document.createElement("span");C.style.cssText="display:none;padding-top:10px;text-align:center;";mxUtils.write(C,mxResources.get("noCommentsFound"));var x=document.createElement("div");x.className="geToolbarContainer geCommentsToolbar";x.style.height=B;x.style.padding=EditorUi.compactUi?"4px 0px 3px 0px":"1px";x.style.backgroundColor="white"==Dialog.backdropColor?"whiteSmoke":Dialog.backdropColor;mxClient.IS_QUIRKS&&(x.style.filter=
-"none");B=document.createElement("a");B.className="geButton";mxClient.IS_QUIRKS&&(B.style.filter="none");if(!v){var F=B.cloneNode();F.innerHTML='<div class="geSprite geSprite-plus" style="display:inline-block;"></div>';F.setAttribute("title",mxResources.get("create")+"...");mxEvent.addListener(F,"click",function(b){function d(){c(e,f,function(b){g(f);a.addComment(b,function(a){b.id=a;E.push(b);l(f)},function(b){p(f);d();a.handleError(b,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})},
+"none");B=document.createElement("a");B.className="geButton";mxClient.IS_QUIRKS&&(B.style.filter="none");if(!v){var F=B.cloneNode();F.innerHTML='<div class="geSprite geSprite-plus" style="display:inline-block;"></div>';F.setAttribute("title",mxResources.get("create")+"...");mxEvent.addListener(F,"click",function(b){function d(){c(e,f,function(b){g(f);a.addComment(b,function(a){b.id=a;E.push(b);m(f)},function(b){p(f);d();a.handleError(b,null,null,null,mxUtils.htmlEntities(mxResources.get("objectNotFound")))})},
!0)}var e=a.newComment("",a.getCurrentUser()),f=n(e,E,null,0);d();b.preventDefault();mxEvent.consume(b)});x.appendChild(F)}F=B.cloneNode();F.innerHTML='<img src="'+IMAGE_PATH+'/check.png" style="width: 16px; padding: 2px;">';F.setAttribute("title",mxResources.get("showResolved"));var G=!1;"dark"==uiTheme&&(F.style.filter="invert(100%)");mxEvent.addListener(F,"click",function(a){this.className=(G=!G)?"geButton geCheckedBtn":"geButton";J();a.preventDefault();mxEvent.consume(a)});x.appendChild(F);a.commentsRefreshNeeded()&&
(F=B.cloneNode(),F.innerHTML='<img src="'+IMAGE_PATH+'/update16.png" style="width: 16px; padding: 2px;">',F.setAttribute("title",mxResources.get("refresh")),"dark"==uiTheme&&(F.style.filter="invert(100%)"),mxEvent.addListener(F,"click",function(a){J();a.preventDefault();mxEvent.consume(a)}),x.appendChild(F));a.commentsSaveNeeded()&&(B=B.cloneNode(),B.innerHTML='<img src="'+IMAGE_PATH+'/save.png" style="width: 20px; padding: 2px;">',B.setAttribute("title",mxResources.get("save")),"dark"==uiTheme&&
-(B.style.filter="invert(100%)"),mxEvent.addListener(B,"click",function(a){m();a.preventDefault();mxEvent.consume(a)}),x.appendChild(B));A.appendChild(x);var E=[],J=mxUtils.bind(this,function(){this.hasError=!1;if(null!=u)try{u.div=u.div.cloneNode(!0);var b=u.div.querySelector(".geCommentEditTxtArea"),d=u.div.querySelector(".geCommentEditBtns");u.comment.content=b.value;b.parentNode.removeChild(b);d.parentNode.removeChild(d)}catch(z){a.handleError(z)}D.innerHTML='<div style="padding-top:10px;text-align:center;"><img src="'+
+(B.style.filter="invert(100%)"),mxEvent.addListener(B,"click",function(a){l();a.preventDefault();mxEvent.consume(a)}),x.appendChild(B));A.appendChild(x);var E=[],J=mxUtils.bind(this,function(){this.hasError=!1;if(null!=u)try{u.div=u.div.cloneNode(!0);var b=u.div.querySelector(".geCommentEditTxtArea"),d=u.div.querySelector(".geCommentEditBtns");u.comment.content=b.value;b.parentNode.removeChild(b);d.parentNode.removeChild(d)}catch(z){a.handleError(z)}D.innerHTML='<div style="padding-top:10px;text-align:center;"><img src="'+
IMAGE_PATH+'/spin.gif" valign="middle"> '+mxUtils.htmlEntities(mxResources.get("loading"))+"...</div>";t=a.canReplyToReplies();a.commentsSupported()?a.getComments(function(a){function b(a){if(null!=a){a.sort(function(a,b){return new Date(a.modifiedDate)-new Date(b.modifiedDate)});for(var c=0;c<a.length;c++)b(a[c].replies)}}a.sort(function(a,b){return new Date(a.modifiedDate)-new Date(b.modifiedDate)});D.innerHTML="";D.appendChild(C);C.style.display="block";E=a;for(a=0;a<E.length;a++)b(E[a].replies),
n(E[a],E,null,0,G);null!=u&&null==u.comment.id&&null==u.comment.pCommentId&&(D.appendChild(u.div),c(u.comment,u.div,u.saveCallback,u.deleteOnCancel))},mxUtils.bind(this,function(a){D.innerHTML=mxUtils.htmlEntities(mxResources.get("error")+(a&&a.message?": "+a.message:""));this.hasError=!0})):D.innerHTML=mxUtils.htmlEntities(mxResources.get("error"))});J();this.refreshComments=J;x=mxUtils.bind(this,function(){function a(b){var d=c[b.id];if(null!=d)for(f(b,d),d=0;null!=b.replies&&d<b.replies.length;d++)a(b.replies[d])}
if(this.window.isVisible()){for(var b=D.querySelectorAll(".geCommentDate"),c={},d=0;d<b.length;d++){var e=b[d];c[e.getAttribute("data-commentId")]=e}for(d=0;d<E.length;d++)a(E[d])}});setInterval(x,6E4);this.refreshCommentsTime=x;this.window=new mxWindow(mxResources.get("comments"),A,b,e,d,k,!0,!0);this.window.minimumSize=new mxRectangle(0,0,300,200);this.window.destroyOnClose=!1;this.window.setMaximizable(!1);this.window.setResizable(!0);this.window.setClosable(!0);this.window.setVisible(!0);this.window.addListener(mxEvent.SHOW,
mxUtils.bind(this,function(){this.window.fit()}));this.window.setLocation=function(a,b){var c=window.innerHeight||document.body.clientHeight||document.documentElement.clientHeight;a=Math.max(0,Math.min(a,(window.innerWidth||document.body.clientWidth||document.documentElement.clientWidth)-this.table.clientWidth));b=Math.max(0,Math.min(b,c-this.table.clientHeight-48));this.getX()==a&&this.getY()==b||mxWindow.prototype.setLocation.apply(this,arguments)};var H=mxUtils.bind(this,function(){var a=this.window.getX(),
-b=this.window.getY();this.window.setLocation(a,b)});mxEvent.addListener(window,"resize",H);this.destroy=function(){mxEvent.removeListener(window,"resize",H);this.window.destroy()}},ConfirmDialog=function(a,b,e,d,k,m,q,c,f,g,p){var l=document.createElement("div");l.style.textAlign="center";p=null!=p?p:44;var n=document.createElement("div");n.style.padding="6px";n.style.overflow="auto";n.style.maxHeight=p+"px";n.style.lineHeight="1.2em";mxClient.IS_QUIRKS&&(n.style.height="60px");mxUtils.write(n,b);
-l.appendChild(n);null!=g&&(n=document.createElement("div"),n.style.padding="6px 0 6px 0",b=document.createElement("img"),b.setAttribute("src",g),n.appendChild(b),l.appendChild(n));g=document.createElement("div");g.style.textAlign="center";g.style.whiteSpace="nowrap";var v=document.createElement("input");v.setAttribute("type","checkbox");m=mxUtils.button(m||mxResources.get("cancel"),function(){a.hideDialog();null!=d&&d(v.checked)});m.className="geBtn";null!=c&&(m.innerHTML=c+"<br>"+m.innerHTML,m.style.paddingBottom=
-"8px",m.style.paddingTop="8px",m.style.height="auto",m.style.width="40%");a.editor.cancelFirst&&g.appendChild(m);var t=mxUtils.button(k||mxResources.get("ok"),function(){a.hideDialog();null!=e&&e(v.checked)});g.appendChild(t);null!=q?(t.innerHTML=q+"<br>"+t.innerHTML+"<br>",t.style.paddingBottom="8px",t.style.paddingTop="8px",t.style.height="auto",t.className="geBtn",t.style.width="40%"):t.className="geBtn gePrimaryBtn";a.editor.cancelFirst||g.appendChild(m);l.appendChild(g);f?(g.style.marginTop=
-"10px",n=document.createElement("p"),n.style.marginTop="20px",n.appendChild(v),k=document.createElement("span"),mxUtils.write(k," "+mxResources.get("rememberThisSetting")),n.appendChild(k),l.appendChild(n),mxEvent.addListener(k,"click",function(a){v.checked=!v.checked;mxEvent.consume(a)})):g.style.marginTop="12px";this.init=function(){t.focus()};this.container=l};function DiagramPage(a,b){this.node=a;null!=b?this.node.setAttribute("id",b):null==this.getId()&&this.node.setAttribute("id",Editor.guid())}DiagramPage.prototype.node=null;DiagramPage.prototype.root=null;DiagramPage.prototype.viewState=null;DiagramPage.prototype.getId=function(){return this.node.getAttribute("id")};DiagramPage.prototype.getName=function(){return this.node.getAttribute("name")};
+b=this.window.getY();this.window.setLocation(a,b)});mxEvent.addListener(window,"resize",H);this.destroy=function(){mxEvent.removeListener(window,"resize",H);this.window.destroy()}},ConfirmDialog=function(a,b,e,d,k,l,q,c,f,g,p){var m=document.createElement("div");m.style.textAlign="center";p=null!=p?p:44;var n=document.createElement("div");n.style.padding="6px";n.style.overflow="auto";n.style.maxHeight=p+"px";n.style.lineHeight="1.2em";mxClient.IS_QUIRKS&&(n.style.height="60px");mxUtils.write(n,b);
+m.appendChild(n);null!=g&&(n=document.createElement("div"),n.style.padding="6px 0 6px 0",b=document.createElement("img"),b.setAttribute("src",g),n.appendChild(b),m.appendChild(n));g=document.createElement("div");g.style.textAlign="center";g.style.whiteSpace="nowrap";var v=document.createElement("input");v.setAttribute("type","checkbox");l=mxUtils.button(l||mxResources.get("cancel"),function(){a.hideDialog();null!=d&&d(v.checked)});l.className="geBtn";null!=c&&(l.innerHTML=c+"<br>"+l.innerHTML,l.style.paddingBottom=
+"8px",l.style.paddingTop="8px",l.style.height="auto",l.style.width="40%");a.editor.cancelFirst&&g.appendChild(l);var t=mxUtils.button(k||mxResources.get("ok"),function(){a.hideDialog();null!=e&&e(v.checked)});g.appendChild(t);null!=q?(t.innerHTML=q+"<br>"+t.innerHTML+"<br>",t.style.paddingBottom="8px",t.style.paddingTop="8px",t.style.height="auto",t.className="geBtn",t.style.width="40%"):t.className="geBtn gePrimaryBtn";a.editor.cancelFirst||g.appendChild(l);m.appendChild(g);f?(g.style.marginTop=
+"10px",n=document.createElement("p"),n.style.marginTop="20px",n.appendChild(v),k=document.createElement("span"),mxUtils.write(k," "+mxResources.get("rememberThisSetting")),n.appendChild(k),m.appendChild(n),mxEvent.addListener(k,"click",function(a){v.checked=!v.checked;mxEvent.consume(a)})):g.style.marginTop="12px";this.init=function(){t.focus()};this.container=m};function DiagramPage(a,b){this.node=a;null!=b?this.node.setAttribute("id",b):null==this.getId()&&this.node.setAttribute("id",Editor.guid())}DiagramPage.prototype.node=null;DiagramPage.prototype.root=null;DiagramPage.prototype.viewState=null;DiagramPage.prototype.getId=function(){return this.node.getAttribute("id")};DiagramPage.prototype.getName=function(){return this.node.getAttribute("name")};
DiagramPage.prototype.setName=function(a){null==a?this.node.removeAttribute("name"):this.node.setAttribute("name",a)};function RenamePage(a,b,e){this.ui=a;this.page=b;this.previous=this.name=e}RenamePage.prototype.execute=function(){var a=this.page.getName();this.page.setName(this.previous);this.name=this.previous;this.previous=a;this.ui.editor.graph.updatePlaceholders();this.ui.editor.fireEvent(new mxEventObject("pageRenamed"))};
function MovePage(a,b,e){this.ui=a;this.oldIndex=b;this.newIndex=e}MovePage.prototype.execute=function(){this.ui.pages.splice(this.newIndex,0,this.ui.pages.splice(this.oldIndex,1)[0]);var a=this.oldIndex;this.oldIndex=this.newIndex;this.newIndex=a;this.ui.editor.graph.updatePlaceholders();this.ui.editor.fireEvent(new mxEventObject("pageMoved"))};
function SelectPage(a,b,e){this.ui=a;this.previousPage=this.page=b;this.neverShown=!0;null!=b&&(this.neverShown=null==b.viewState,this.ui.updatePageRoot(b),null!=e&&(b.viewState=e,this.neverShown=!1))}
@@ -3462,8 +3462,8 @@ this.tabContainer.style.height=null==this.fileNode||null==this.pages||1==this.pa
a.container.scrollTop=0,this.chromelessResize())):(a.container.scrollLeft=a.view.translate.x*a.view.scale+b.viewState.scrollLeft,a.container.scrollTop=a.view.translate.y*a.view.scale+b.viewState.scrollTop),e=b);null!=this.actions.layersWindow&&this.actions.layersWindow.refreshLayers();"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?1!=MathJax.Hub.queue.pending||null==this.editor||this.editor.graph.mathEnabled||MathJax.Hub.Queue(mxUtils.bind(this,function(){null!=this.editor&&this.editor.graph.refresh()})):
"undefined"===typeof Editor.MathJaxClear||null!=this.editor&&this.editor.graph.mathEnabled||Editor.MathJaxClear()});this.editor.graph.model.addListener(mxEvent.CHANGE,mxUtils.bind(this,function(a,b){for(var e=b.getProperty("edit").changes,c=0;c<e.length;c++)if(e[c]instanceof SelectPage||e[c]instanceof RenamePage||e[c]instanceof MovePage||e[c]instanceof mxRootChange){d();break}}));null!=this.toolbar&&this.editor.addListener("pageSelected",this.toolbar.updateZoom)}};
EditorUi.prototype.restoreViewState=function(a,b,e){a=null!=a?this.getPageById(a.getId()):null;var d=this.editor.graph;null!=a&&null!=this.currentPage&&null!=this.pages&&(a!=this.currentPage?this.selectPage(a,!0,b):(d.setViewState(b),this.editor.updateGraphComponents(),d.view.revalidate(),d.sizeDidChange()),d.container.scrollLeft=d.view.translate.x*d.view.scale+b.scrollLeft,d.container.scrollTop=d.view.translate.y*d.view.scale+b.scrollTop,d.restoreSelection(e))};
-Graph.prototype.createViewState=function(a){var b=a.getAttribute("page"),e=parseFloat(a.getAttribute("pageScale")),d=parseFloat(a.getAttribute("pageWidth")),k=parseFloat(a.getAttribute("pageHeight")),m=a.getAttribute("background"),q=a.getAttribute("backgroundImage"),q=null!=q&&0<q.length?JSON.parse(q):null,c=a.getAttribute("extFonts");if(c)try{c=c.split("|").map(function(a){a=a.split("^");return{name:a[0],url:a[1]}})}catch(f){console.log("ExtFonts format error: "+f.message)}return{gridEnabled:"0"!=
-a.getAttribute("grid"),gridSize:parseFloat(a.getAttribute("gridSize"))||mxGraph.prototype.gridSize,guidesEnabled:"0"!=a.getAttribute("guides"),foldingEnabled:"0"!=a.getAttribute("fold"),shadowVisible:"1"==a.getAttribute("shadow"),pageVisible:this.isLightboxView()?!1:null!=b?"0"!=b:this.defaultPageVisible,background:null!=m&&0<m.length?m:null,backgroundImage:null!=q?new mxImage(q.src,q.width,q.height):null,pageScale:isNaN(e)?mxGraph.prototype.pageScale:e,pageFormat:isNaN(d)||isNaN(k)?"undefined"===
+Graph.prototype.createViewState=function(a){var b=a.getAttribute("page"),e=parseFloat(a.getAttribute("pageScale")),d=parseFloat(a.getAttribute("pageWidth")),k=parseFloat(a.getAttribute("pageHeight")),l=a.getAttribute("background"),q=a.getAttribute("backgroundImage"),q=null!=q&&0<q.length?JSON.parse(q):null,c=a.getAttribute("extFonts");if(c)try{c=c.split("|").map(function(a){a=a.split("^");return{name:a[0],url:a[1]}})}catch(f){console.log("ExtFonts format error: "+f.message)}return{gridEnabled:"0"!=
+a.getAttribute("grid"),gridSize:parseFloat(a.getAttribute("gridSize"))||mxGraph.prototype.gridSize,guidesEnabled:"0"!=a.getAttribute("guides"),foldingEnabled:"0"!=a.getAttribute("fold"),shadowVisible:"1"==a.getAttribute("shadow"),pageVisible:this.isLightboxView()?!1:null!=b?"0"!=b:this.defaultPageVisible,background:null!=l&&0<l.length?l:null,backgroundImage:null!=q?new mxImage(q.src,q.width,q.height):null,pageScale:isNaN(e)?mxGraph.prototype.pageScale:e,pageFormat:isNaN(d)||isNaN(k)?"undefined"===
typeof mxSettings?mxGraph.prototype.pageFormat:mxSettings.getPageFormat():new mxRectangle(0,0,d,k),tooltips:"0"!=a.getAttribute("tooltips"),connect:"0"!=a.getAttribute("connect"),arrows:"0"!=a.getAttribute("arrows"),mathEnabled:"1"==a.getAttribute("math"),selectionCells:null,defaultParent:null,scrollbars:this.defaultScrollbars,scale:1,extFonts:c||[]}};
Graph.prototype.saveViewState=function(a,b,e){e||(b.setAttribute("grid",null==a||a.gridEnabled?"1":"0"),b.setAttribute("gridSize",null!=a?a.gridSize:mxGraph.prototype.gridSize),b.setAttribute("guides",null==a||a.guidesEnabled?"1":"0"),b.setAttribute("tooltips",null==a||a.tooltips?"1":"0"),b.setAttribute("connect",null==a||a.connect?"1":"0"),b.setAttribute("arrows",null==a||a.arrows?"1":"0"),b.setAttribute("page",null==a&&this.defaultPageVisible||null!=a&&a.pageVisible?"1":"0"),b.setAttribute("fold",
null==a||a.foldingEnabled?"1":"0"));b.setAttribute("pageScale",null!=a&&null!=a.pageScale?a.pageScale:mxGraph.prototype.pageScale);e=null!=a?a.pageFormat:"undefined"===typeof mxSettings?mxGraph.prototype.pageFormat:mxSettings.getPageFormat();null!=e&&(b.setAttribute("pageWidth",e.width),b.setAttribute("pageHeight",e.height));null!=a&&null!=a.background&&b.setAttribute("background",a.background);null!=a&&null!=a.backgroundImage&&b.setAttribute("backgroundImage",JSON.stringify(a.backgroundImage));b.setAttribute("math",
@@ -3479,17 +3479,17 @@ Graph.prototype.addExtFont=function(a,b,e){if(a&&b){var d="extFont_"+a;if(null==
d=!0;for(k=0;k<e.length;k++)if(e[k].name==a){d=!1;break}d&&this.extFonts.push({name:a,url:b})}}};
EditorUi.prototype.updatePageRoot=function(a,b){if(null==a.root){var e=this.editor.extractGraphModel(a.node,null,b),d=Editor.extractParserError(e);if(d)throw Error(d);null!=e?(a.graphModelNode=e,a.viewState=this.editor.graph.createViewState(e),d=new mxCodec(e.ownerDocument),a.root=d.decode(e).root):a.root=this.editor.graph.model.createRoot()}else if(null==a.viewState){if(null==a.graphModelNode){e=this.editor.extractGraphModel(a.node);if(d=Editor.extractParserError(e))throw Error(d);null!=e&&(a.graphModelNode=
e)}null!=a.graphModelNode&&(a.viewState=this.editor.graph.createViewState(a.graphModelNode))}return a};
-EditorUi.prototype.selectPage=function(a,b,e){try{if(a!=this.currentPage){this.editor.graph.isEditing()&&this.editor.graph.stopEditing(!1);b=null!=b?b:!1;this.editor.graph.isMouseDown=!1;this.editor.graph.reset();var d=this.editor.graph.model.createUndoableEdit();d.ignoreEdit=!0;var k=new SelectPage(this,a,e);k.execute();d.add(k);d.notify();this.editor.graph.tooltipHandler.hide();b||this.editor.graph.model.fireEvent(new mxEventObject(mxEvent.UNDO,"edit",d))}}catch(m){this.handleError(m)}};
+EditorUi.prototype.selectPage=function(a,b,e){try{if(a!=this.currentPage){this.editor.graph.isEditing()&&this.editor.graph.stopEditing(!1);b=null!=b?b:!1;this.editor.graph.isMouseDown=!1;this.editor.graph.reset();var d=this.editor.graph.model.createUndoableEdit();d.ignoreEdit=!0;var k=new SelectPage(this,a,e);k.execute();d.add(k);d.notify();this.editor.graph.tooltipHandler.hide();b||this.editor.graph.model.fireEvent(new mxEventObject(mxEvent.UNDO,"edit",d))}}catch(l){this.handleError(l)}};
EditorUi.prototype.selectNextPage=function(a){var b=this.currentPage;null!=b&&null!=this.pages&&(b=mxUtils.indexOf(this.pages,b),a?this.selectPage(this.pages[mxUtils.mod(b+1,this.pages.length)]):a||this.selectPage(this.pages[mxUtils.mod(b-1,this.pages.length)]))};
EditorUi.prototype.insertPage=function(a,b){if(this.editor.graph.isEnabled()){this.editor.graph.isEditing()&&this.editor.graph.stopEditing(!1);a=null!=a?a:this.createPage(null,this.createPageId());b=null!=b?b:this.pages.length;var e=new ChangePage(this,a,a,b);this.editor.graph.model.execute(e)}return a};EditorUi.prototype.createPageId=function(){var a;do a=Editor.guid();while(null!=this.getPageById(a));return a};
EditorUi.prototype.createPage=function(a,b){var e=new DiagramPage(this.fileNode.ownerDocument.createElement("diagram"),b);e.setName(null!=a?a:this.createPageName());return e};EditorUi.prototype.createPageName=function(){for(var a={},b=0;b<this.pages.length;b++){var e=this.pages[b].getName();null!=e&&0<e.length&&(a[e]=e)}b=this.pages.length;do e=mxResources.get("pageWithNumber",[++b]);while(null!=a[e]);return e};
EditorUi.prototype.removePage=function(a){try{var b=this.editor.graph,e=mxUtils.indexOf(this.pages,a);if(b.isEnabled()&&0<=e){this.editor.graph.isEditing()&&this.editor.graph.stopEditing(!1);b.model.beginUpdate();try{var d=this.currentPage;d==a&&1<this.pages.length?(e==this.pages.length-1?e--:e++,d=this.pages[e]):1>=this.pages.length&&(d=this.insertPage(),b.model.execute(new RenamePage(this,d,mxResources.get("pageWithNumber",[1]))));b.model.execute(new ChangePage(this,a,d))}finally{b.model.endUpdate()}}}catch(k){this.handleError(k)}return a};
-EditorUi.prototype.duplicatePage=function(a,b){var e=null;try{var d=this.editor.graph;if(d.isEnabled()){d.isEditing()&&d.stopEditing();var k=a.node.cloneNode(!1);k.removeAttribute("id");e=new DiagramPage(k);e.root=d.cloneCell(d.model.root);e.viewState=d.getViewState();e.viewState.scale=1;e.viewState.scrollLeft=null;e.viewState.scrollTop=null;e.viewState.currentRoot=null;e.viewState.defaultParent=null;e.setName(b);e=this.insertPage(e,mxUtils.indexOf(this.pages,a)+1)}}catch(m){this.handleError(m)}return e};
+EditorUi.prototype.duplicatePage=function(a,b){var e=null;try{var d=this.editor.graph;if(d.isEnabled()){d.isEditing()&&d.stopEditing();var k=a.node.cloneNode(!1);k.removeAttribute("id");e=new DiagramPage(k);e.root=d.cloneCell(d.model.root);e.viewState=d.getViewState();e.viewState.scale=1;e.viewState.scrollLeft=null;e.viewState.scrollTop=null;e.viewState.currentRoot=null;e.viewState.defaultParent=null;e.setName(b);e=this.insertPage(e,mxUtils.indexOf(this.pages,a)+1)}}catch(l){this.handleError(l)}return e};
EditorUi.prototype.renamePage=function(a){if(this.editor.graph.isEnabled()){var b=new FilenameDialog(this,a.getName(),mxResources.get("rename"),mxUtils.bind(this,function(b){null!=b&&0<b.length&&this.editor.graph.model.execute(new RenamePage(this,a,b))}),mxResources.get("rename"));this.showDialog(b.container,300,80,!0,!0);b.init()}return a};EditorUi.prototype.movePage=function(a,b){this.editor.graph.model.execute(new MovePage(this,a,b))};
EditorUi.prototype.createTabContainer=function(){var a=document.createElement("div");a.className="geTabContainer";a.style.position="absolute";a.style.whiteSpace="nowrap";a.style.overflow="hidden";a.style.height="0px";return a};
EditorUi.prototype.updateTabContainer=function(){if(null!=this.tabContainer&&null!=this.pages){var a=this.editor.graph,b=document.createElement("div");b.style.position="relative";b.style.display=mxClient.IS_QUIRKS?"inline":"inline-block";b.style.verticalAlign="top";b.style.height=this.tabContainer.style.height;b.style.whiteSpace="nowrap";b.style.overflow="hidden";b.style.fontSize="13px";b.style.marginLeft="30px";for(var e=this.editor.isChromelessView()?29:59,d=Math.min(140,Math.max(20,(this.tabContainer.clientWidth-
-e)/this.pages.length)+1),k=null,m=0;m<this.pages.length;m++)mxUtils.bind(this,function(c,d){this.pages[c]==this.currentPage?(d.className="geActivePage",d.style.backgroundColor="dark"==uiTheme?"#2a2a2a":"#fff"):d.className="geInactivePage";d.setAttribute("draggable","true");mxEvent.addListener(d,"dragstart",mxUtils.bind(this,function(b){a.isEnabled()?(mxClient.IS_FF&&b.dataTransfer.setData("Text","<diagram/>"),k=c):mxEvent.consume(b)}));mxEvent.addListener(d,"dragend",mxUtils.bind(this,function(a){k=
-null;a.stopPropagation();a.preventDefault()}));mxEvent.addListener(d,"dragover",mxUtils.bind(this,function(a){null!=k&&(a.dataTransfer.dropEffect="move");a.stopPropagation();a.preventDefault()}));mxEvent.addListener(d,"drop",mxUtils.bind(this,function(a){null!=k&&c!=k&&this.movePage(k,c);a.stopPropagation();a.preventDefault()}));b.appendChild(d)})(m,this.createTabForPage(this.pages[m],d,this.pages[m]!=this.currentPage,m+1));this.tabContainer.innerHTML="";this.tabContainer.appendChild(b);d=this.createPageMenuTab();
+e)/this.pages.length)+1),k=null,l=0;l<this.pages.length;l++)mxUtils.bind(this,function(c,d){this.pages[c]==this.currentPage?(d.className="geActivePage",d.style.backgroundColor="dark"==uiTheme?"#2a2a2a":"#fff"):d.className="geInactivePage";d.setAttribute("draggable","true");mxEvent.addListener(d,"dragstart",mxUtils.bind(this,function(b){a.isEnabled()?(mxClient.IS_FF&&b.dataTransfer.setData("Text","<diagram/>"),k=c):mxEvent.consume(b)}));mxEvent.addListener(d,"dragend",mxUtils.bind(this,function(a){k=
+null;a.stopPropagation();a.preventDefault()}));mxEvent.addListener(d,"dragover",mxUtils.bind(this,function(a){null!=k&&(a.dataTransfer.dropEffect="move");a.stopPropagation();a.preventDefault()}));mxEvent.addListener(d,"drop",mxUtils.bind(this,function(a){null!=k&&c!=k&&this.movePage(k,c);a.stopPropagation();a.preventDefault()}));b.appendChild(d)})(l,this.createTabForPage(this.pages[l],d,this.pages[l]!=this.currentPage,l+1));this.tabContainer.innerHTML="";this.tabContainer.appendChild(b);d=this.createPageMenuTab();
this.tabContainer.appendChild(d);d=null;this.isPageInsertTabVisible()&&(d=this.createPageInsertTab(),this.tabContainer.appendChild(d));if(b.clientWidth>this.tabContainer.clientWidth-e){null!=d&&(d.style.position="absolute",d.style.right="0px",b.style.marginRight="30px");var q=this.createControlTab(4,"&nbsp;&#10094;&nbsp;");q.style.position="absolute";q.style.right=this.editor.chromeless?"29px":"55px";q.style.fontSize="13pt";this.tabContainer.appendChild(q);var c=this.createControlTab(4,"&nbsp;&#10095;");
c.style.position="absolute";c.style.right=this.editor.chromeless?"0px":"29px";c.style.fontSize="13pt";this.tabContainer.appendChild(c);var f=Math.max(0,this.tabContainer.clientWidth-(this.editor.chromeless?86:116));b.style.width=f+"px";mxEvent.addListener(q,"click",mxUtils.bind(this,function(a){b.scrollLeft-=Math.max(20,f-20);mxUtils.setOpacity(q,0<b.scrollLeft?100:50);mxUtils.setOpacity(c,b.scrollLeft<b.scrollWidth-b.clientWidth?100:50);mxEvent.consume(a)}));mxUtils.setOpacity(q,0<b.scrollLeft?100:
50);mxUtils.setOpacity(c,b.scrollLeft<b.scrollWidth-b.clientWidth?100:50);mxEvent.addListener(c,"click",mxUtils.bind(this,function(a){b.scrollLeft+=Math.max(20,f-20);mxUtils.setOpacity(q,0<b.scrollLeft?100:50);mxUtils.setOpacity(c,b.scrollLeft<b.scrollWidth-b.clientWidth?100:50);mxEvent.consume(a)}))}}};EditorUi.prototype.isPageInsertTabVisible=function(){return 1==urlParams.embed||null!=this.getCurrentFile()&&this.getCurrentFile().isEditable()};
@@ -3500,9 +3500,9 @@ EditorUi.prototype.createPageMenuTab=function(){var a=this.createControlTab(3,'<
0;c<this.pages.length;c++)mxUtils.bind(this,function(c){var d=a.addItem(this.pages[c].getName(),null,mxUtils.bind(this,function(){this.selectPage(this.pages[c])}),b);this.pages[c]==this.currentPage&&a.addCheckmark(d,Editor.checkmarkImage)})(c);if(this.editor.graph.isEnabled()){a.addSeparator(b);a.addItem(mxResources.get("insertPage"),null,mxUtils.bind(this,function(){this.insertPage()}),b);var d=this.currentPage;null!=d&&(a.addSeparator(b),a.addItem(mxResources.get("delete"),null,mxUtils.bind(this,
function(){this.removePage(d)}),b),a.addItem(mxResources.get("rename"),null,mxUtils.bind(this,function(){this.renamePage(d,d.getName())}),b),a.addSeparator(b),a.addItem(mxResources.get("duplicate"),null,mxUtils.bind(this,function(){this.duplicatePage(d,mxResources.get("copyOf",[d.getName()]))}),b))}}));b.div.className+=" geMenubarMenu";b.smartSeparators=!0;b.showDisabled=!0;b.autoExpand=!0;b.hideMenu=mxUtils.bind(this,function(){mxPopupMenu.prototype.hideMenu.apply(b,arguments);b.destroy()});var d=
mxEvent.getClientX(a),k=mxEvent.getClientY(a);b.popup(d,k,null,a);this.setCurrentMenu(b);mxEvent.consume(a)}));return a};EditorUi.prototype.createPageInsertTab=function(){var a=this.createControlTab(4,'<div class="geSprite geSprite-plus" style="display:inline-block;width:21px;height:21px;"></div>');a.setAttribute("title",mxResources.get("insertPage"));mxEvent.addListener(a,"click",mxUtils.bind(this,function(a){this.insertPage();mxEvent.consume(a)}));return a};
-EditorUi.prototype.createTabForPage=function(a,b,e,d){e=this.createTab(e);var k=a.getName()||mxResources.get("untitled"),m=a.getId();e.setAttribute("title",k+(null!=m?" ("+m+")":"")+" ["+d+"]");mxUtils.write(e,k);e.style.maxWidth=b+"px";e.style.width=b+"px";this.addTabListeners(a,e);42<b&&(e.style.textOverflow="ellipsis");return e};
-EditorUi.prototype.addTabListeners=function(a,b){mxEvent.disableContextMenu(b);var e=this.editor.graph;mxEvent.addListener(b,"dblclick",mxUtils.bind(this,function(b){this.renamePage(a);mxEvent.consume(b)}));var d=!1,k=!1;mxEvent.addGestureListeners(b,mxUtils.bind(this,function(b){d=null!=this.currentMenu;k=a==this.currentPage;e.isMouseDown||k||this.selectPage(a)}),null,mxUtils.bind(this,function(m){if(e.isEnabled()&&!e.isMouseDown&&(mxEvent.isTouchEvent(m)&&k||mxEvent.isPopupTrigger(m))){e.popupMenuHandler.hideMenu();
-this.hideCurrentMenu();if(!mxEvent.isTouchEvent(m)||!d){var q=new mxPopupMenu(this.createPageMenu(a));q.div.className+=" geMenubarMenu";q.smartSeparators=!0;q.showDisabled=!0;q.autoExpand=!0;q.hideMenu=mxUtils.bind(this,function(){mxPopupMenu.prototype.hideMenu.apply(q,arguments);this.resetCurrentMenu();q.destroy()});var c=mxEvent.getClientX(m),f=mxEvent.getClientY(m);q.popup(c,f,null,m);this.setCurrentMenu(q,b)}mxEvent.consume(m)}}))};
+EditorUi.prototype.createTabForPage=function(a,b,e,d){e=this.createTab(e);var k=a.getName()||mxResources.get("untitled"),l=a.getId();e.setAttribute("title",k+(null!=l?" ("+l+")":"")+" ["+d+"]");mxUtils.write(e,k);e.style.maxWidth=b+"px";e.style.width=b+"px";this.addTabListeners(a,e);42<b&&(e.style.textOverflow="ellipsis");return e};
+EditorUi.prototype.addTabListeners=function(a,b){mxEvent.disableContextMenu(b);var e=this.editor.graph;mxEvent.addListener(b,"dblclick",mxUtils.bind(this,function(b){this.renamePage(a);mxEvent.consume(b)}));var d=!1,k=!1;mxEvent.addGestureListeners(b,mxUtils.bind(this,function(b){d=null!=this.currentMenu;k=a==this.currentPage;e.isMouseDown||k||this.selectPage(a)}),null,mxUtils.bind(this,function(l){if(e.isEnabled()&&!e.isMouseDown&&(mxEvent.isTouchEvent(l)&&k||mxEvent.isPopupTrigger(l))){e.popupMenuHandler.hideMenu();
+this.hideCurrentMenu();if(!mxEvent.isTouchEvent(l)||!d){var q=new mxPopupMenu(this.createPageMenu(a));q.div.className+=" geMenubarMenu";q.smartSeparators=!0;q.showDisabled=!0;q.autoExpand=!0;q.hideMenu=mxUtils.bind(this,function(){mxPopupMenu.prototype.hideMenu.apply(q,arguments);this.resetCurrentMenu();q.destroy()});var c=mxEvent.getClientX(l),f=mxEvent.getClientY(l);q.popup(c,f,null,l);this.setCurrentMenu(q,b)}mxEvent.consume(l)}}))};
EditorUi.prototype.getLinkForPage=function(a){if(!mxClient.IS_CHROMEAPP&&!EditorUi.isElectronApp){var b=this.getCurrentFile();if(null!=b&&b.constructor!=LocalFile&&"draw.io"==this.getServiceName()){var e=this.getSearch("create title mode url drive splash state".split(" ")),e=e+((0==e.length?"?":"&")+"page-id="+a.getId());return window.location.protocol+"//"+window.location.host+"/"+e+"#"+b.getHash()}}return null};
EditorUi.prototype.createPageMenu=function(a,b){return mxUtils.bind(this,function(e,d){e.addItem(mxResources.get("insert"),null,mxUtils.bind(this,function(){this.insertPage(null,mxUtils.indexOf(this.pages,a)+1)}),d);e.addItem(mxResources.get("delete"),null,mxUtils.bind(this,function(){this.removePage(a)}),d);e.addItem(mxResources.get("rename"),null,mxUtils.bind(this,function(){this.renamePage(a,b)}),d);var k=this.getLinkForPage(a);null!=k&&(e.addSeparator(d),e.addItem(mxResources.get("link"),null,
mxUtils.bind(this,function(){var a=new EmbedDialog(this,k);this.showDialog(a.container,440,240,!0,!0);a.init()}),d));e.addSeparator(d);e.addItem(mxResources.get("duplicate"),null,mxUtils.bind(this,function(){this.duplicatePage(a,mxResources.get("copyOf",[a.getName()]))}),d);mxClient.IS_CHROMEAPP||EditorUi.isElectronApp||"draw.io"!=this.getServiceName()||(e.addSeparator(d),e.addItem(mxResources.get("openInNewWindow"),null,mxUtils.bind(this,function(){this.editor.editAsNew(this.getFileData(!0,null,
@@ -3510,31 +3510,31 @@ null,null,!0,!0))}),d))})};(function(){var a=EditorUi.prototype.refresh;EditorUi
(function(){var a=new mxObjectCodec(new RenamePage,["ui","page"]);a.beforeDecode=function(a,e,d){d.ui=a.ui;return e};a.afterDecode=function(a,e,d){a=d.previous;d.previous=d.name;d.name=a;return d};mxCodecRegistry.register(a)})();
(function(){var a=new mxObjectCodec(new ChangePage,"ui relatedPage index neverShown page previousPage".split(" ")),b="defaultParent currentRoot scrollLeft scrollTop scale translate lastPasteXml pasteCounter".split(" ");a.afterEncode=function(a,d,k){k.setAttribute("relatedPage",d.relatedPage.getId());null==d.index&&(k.setAttribute("name",d.relatedPage.getName()),null!=d.relatedPage.viewState&&k.setAttribute("viewState",JSON.stringify(d.relatedPage.viewState,function(a,d){return 0>mxUtils.indexOf(b,
a)?d:void 0})),null!=d.relatedPage.root&&a.encodeCell(d.relatedPage.root,k));return k};a.beforeDecode=function(a,b,k){k.ui=a.ui;k.relatedPage=k.ui.getPageById(b.getAttribute("relatedPage"));if(null==k.relatedPage){var d=b.ownerDocument.createElement("diagram");d.setAttribute("id",b.getAttribute("relatedPage"));d.setAttribute("name",b.getAttribute("name"));k.relatedPage=new DiagramPage(d);d=b.getAttribute("viewState");null!=d&&(k.relatedPage.viewState=JSON.parse(d),b.removeAttribute("viewState"));
-b=b.cloneNode(!0);d=b.firstChild;if(null!=d)for(k.relatedPage.root=a.decodeCell(d,!1),k=d.nextSibling,d.parentNode.removeChild(d),d=k;null!=d;){k=d.nextSibling;if(d.nodeType==mxConstants.NODETYPE_ELEMENT){var e=d.getAttribute("id");null==a.lookup(e)&&a.decodeCell(d)}d.parentNode.removeChild(d);d=k}}return b};a.afterDecode=function(a,b,k){k.index=k.previousIndex;return k};mxCodecRegistry.register(a)})();(function(){EditorUi.prototype.altShiftActions[68]="selectDescendants";var a=Graph.prototype.foldCells;Graph.prototype.foldCells=function(b,e,m,q,c){e=null!=e?e:!1;null==m&&(m=this.getFoldableCells(this.getSelectionCells(),b));this.stopEditing();this.model.beginUpdate();try{for(var d=m.slice(),g=[],k=0;k<m.length;k++){var l=this.getCurrentCellStyle(m[k]);"1"==mxUtils.getValue(l,"treeFolding","0")&&(this.traverse(m[k],!0,mxUtils.bind(this,function(a,b){null!=b&&g.push(b);a!=m[k]&&g.push(a);return a==
-m[k]||!this.model.isCollapsed(a)})),this.model.setCollapsed(m[k],b))}for(k=0;k<g.length;k++)this.model.setVisible(g[k],!b);m=d;m=a.apply(this,arguments)}finally{this.model.endUpdate()}return m};var b=EditorUi.prototype.init;EditorUi.prototype.init=function(){b.apply(this,arguments);this.editor.isChromelessView()&&!this.editor.editable||this.addTrees()};EditorUi.prototype.addTrees=function(){function a(a){return u.isVertex(a)&&e(a)}function b(a){var b=!1;null!=a&&(b="1"==t.getCurrentCellStyle(a).treeMoving);
+b=b.cloneNode(!0);d=b.firstChild;if(null!=d)for(k.relatedPage.root=a.decodeCell(d,!1),k=d.nextSibling,d.parentNode.removeChild(d),d=k;null!=d;){k=d.nextSibling;if(d.nodeType==mxConstants.NODETYPE_ELEMENT){var e=d.getAttribute("id");null==a.lookup(e)&&a.decodeCell(d)}d.parentNode.removeChild(d);d=k}}return b};a.afterDecode=function(a,b,k){k.index=k.previousIndex;return k};mxCodecRegistry.register(a)})();(function(){EditorUi.prototype.altShiftActions[68]="selectDescendants";var a=Graph.prototype.foldCells;Graph.prototype.foldCells=function(b,e,l,q,c){e=null!=e?e:!1;null==l&&(l=this.getFoldableCells(this.getSelectionCells(),b));this.stopEditing();this.model.beginUpdate();try{for(var d=l.slice(),g=[],k=0;k<l.length;k++){var m=this.getCurrentCellStyle(l[k]);"1"==mxUtils.getValue(m,"treeFolding","0")&&(this.traverse(l[k],!0,mxUtils.bind(this,function(a,b){null!=b&&g.push(b);a!=l[k]&&g.push(a);return a==
+l[k]||!this.model.isCollapsed(a)})),this.model.setCollapsed(l[k],b))}for(k=0;k<g.length;k++)this.model.setVisible(g[k],!b);l=d;l=a.apply(this,arguments)}finally{this.model.endUpdate()}return l};var b=EditorUi.prototype.init;EditorUi.prototype.init=function(){b.apply(this,arguments);this.editor.isChromelessView()&&!this.editor.editable||this.addTrees()};EditorUi.prototype.addTrees=function(){function a(a){return u.isVertex(a)&&e(a)}function b(a){var b=!1;null!=a&&(b="1"==t.getCurrentCellStyle(a).treeMoving);
return b}function e(a){var b=!1;null!=a&&(a=u.getParent(a),b=t.view.getState(a),b="tree"==(null!=b?b.style:t.getCellStyle(a)).containerType);return b}function q(a){var b=!1;null!=a&&(a=u.getParent(a),b=t.view.getState(a),t.view.getState(a),b=null!=(null!=b?b.style:t.getCellStyle(a)).childLayout);return b}function c(a){a=t.view.getState(a);if(null!=a){var b=t.getIncomingEdges(a.cell);if(0<b.length&&(b=t.view.getState(b[0]),null!=b&&(b=b.absolutePoints,null!=b&&0<b.length&&(b=b[b.length-1],null!=b)))){if(b.y==
-a.y&&Math.abs(b.x-a.getCenterX())<a.width/2)return mxConstants.DIRECTION_SOUTH;if(b.y==a.y+a.height&&Math.abs(b.x-a.getCenterX())<a.width/2)return mxConstants.DIRECTION_NORTH;if(b.x>a.getCenterX())return mxConstants.DIRECTION_WEST}}return mxConstants.DIRECTION_EAST}function f(a,b){b=null!=b?b:!0;t.model.beginUpdate();try{var d=t.model.getParent(a),e=t.getIncomingEdges(a),f=t.cloneCells([e[0],a]);t.model.setTerminal(f[0],t.model.getTerminal(e[0],!0),!0);var g=c(a),k=d.geometry;g==mxConstants.DIRECTION_SOUTH||
-g==mxConstants.DIRECTION_NORTH?f[1].geometry.x+=b?a.geometry.width+10:-f[1].geometry.width-10:f[1].geometry.y+=b?a.geometry.height+10:-f[1].geometry.height-10;t.view.currentRoot!=d&&(f[1].geometry.x-=k.x,f[1].geometry.y-=k.y);var l=t.view.getState(a),m=t.view.scale;if(null!=l){var n=mxRectangle.fromRectangle(l);g==mxConstants.DIRECTION_SOUTH||g==mxConstants.DIRECTION_NORTH?n.x+=(b?a.geometry.width+10:-f[1].geometry.width-10)*m:n.y+=(b?a.geometry.height+10:-f[1].geometry.height-10)*m;var p=t.getOutgoingEdges(t.model.getTerminal(e[0],
-!0));if(null!=p){for(var q=g==mxConstants.DIRECTION_SOUTH||g==mxConstants.DIRECTION_NORTH,u=k=e=0;u<p.length;u++){var z=t.model.getTerminal(p[u],!1);if(g==c(z)){var x=t.view.getState(z);z!=a&&null!=x&&(q&&b!=x.getCenterX()<l.getCenterX()||!q&&b!=x.getCenterY()<l.getCenterY())&&mxUtils.intersects(n,x)&&(e=10+Math.max(e,(Math.min(n.x+n.width,x.x+x.width)-Math.max(n.x,x.x))/m),k=10+Math.max(k,(Math.min(n.y+n.height,x.y+x.height)-Math.max(n.y,x.y))/m))}}q?k=0:e=0;for(u=0;u<p.length;u++)if(z=t.model.getTerminal(p[u],
-!1),g==c(z)&&(x=t.view.getState(z),z!=a&&null!=x&&(q&&b!=x.getCenterX()<l.getCenterX()||!q&&b!=x.getCenterY()<l.getCenterY()))){var v=[];t.traverse(x.cell,!0,function(a,b){null!=b&&v.push(b);v.push(a);return!0});t.moveCells(v,(b?1:-1)*e,(b?1:-1)*k)}}}return t.addCells(f,d)}finally{t.model.endUpdate()}}function g(a){t.model.beginUpdate();try{var b=c(a),d=t.getIncomingEdges(a),e=t.cloneCells([d[0],a]);t.model.setTerminal(d[0],e[1],!1);t.model.setTerminal(e[0],e[1],!0);t.model.setTerminal(e[0],a,!1);
-var f=t.model.getParent(a),g=f.geometry,k=[];t.view.currentRoot!=f&&(e[1].geometry.x-=g.x,e[1].geometry.y-=g.y);t.traverse(a,!0,function(a,b){null!=b&&k.push(b);k.push(a);return!0});var l=a.geometry.width+40,m=a.geometry.height+40;b==mxConstants.DIRECTION_SOUTH?l=0:b==mxConstants.DIRECTION_NORTH?(l=0,m=-m):b==mxConstants.DIRECTION_WEST?(l=-l,m=0):b==mxConstants.DIRECTION_EAST&&(m=0);t.moveCells(k,l,m);return t.addCells(e,f)}finally{t.model.endUpdate()}}function p(a,b){t.model.beginUpdate();try{var d=
-t.model.getParent(a),e=t.getIncomingEdges(a),f=c(a);0==e.length&&(e=[t.createEdge(d,null,"",null,null,t.createCurrentEdgeStyle())],f=b);var g=t.cloneCells([e[0],a]);t.model.setTerminal(g[0],a,!0);if(null==t.model.getTerminal(g[0],!1)){t.model.setTerminal(g[0],g[1],!1);var k=t.getCellStyle(g[1]).newEdgeStyle;if(null!=k)try{var l=JSON.parse(k),m;for(m in l)t.setCellStyles(m,l[m],[g[0]]),"edgeStyle"==m&&"elbowEdgeStyle"==l[m]&&t.setCellStyles("elbow",f==mxConstants.DIRECTION_SOUTH||f==mxConstants.DIRECTION_NOTH?
-"vertical":"horizontal",[g[0]])}catch(T){}}var e=t.getOutgoingEdges(a),n=d.geometry,k=[];t.view.currentRoot==d&&(n=new mxRectangle);for(l=0;l<e.length;l++){var p=t.model.getTerminal(e[l],!1);null!=p&&k.push(p)}var q=t.view.getBounds(k),u=t.view.translate,x=t.view.scale;f==mxConstants.DIRECTION_SOUTH?(g[1].geometry.x=null==q?a.geometry.x+(a.geometry.width-g[1].geometry.width)/2:(q.x+q.width)/x-u.x-n.x+10,g[1].geometry.y+=g[1].geometry.height-n.y+40):f==mxConstants.DIRECTION_NORTH?(g[1].geometry.x=
-null==q?a.geometry.x+(a.geometry.width-g[1].geometry.width)/2:(q.x+q.width)/x-u.x+-n.x+10,g[1].geometry.y-=g[1].geometry.height+n.y+40):(g[1].geometry.x=f==mxConstants.DIRECTION_WEST?g[1].geometry.x-(g[1].geometry.width+n.x+40):g[1].geometry.x+(g[1].geometry.width-n.x+40),g[1].geometry.y=null==q?a.geometry.y+(a.geometry.height-g[1].geometry.height)/2:(q.y+q.height)/x-u.y+-n.y+10);return t.addCells(g,d)}finally{t.model.endUpdate()}}function l(a,b,c){a=t.getOutgoingEdges(a);c=t.view.getState(c);var d=
+a.y&&Math.abs(b.x-a.getCenterX())<a.width/2)return mxConstants.DIRECTION_SOUTH;if(b.y==a.y+a.height&&Math.abs(b.x-a.getCenterX())<a.width/2)return mxConstants.DIRECTION_NORTH;if(b.x>a.getCenterX())return mxConstants.DIRECTION_WEST}}return mxConstants.DIRECTION_EAST}function f(a,b){b=null!=b?b:!0;t.model.beginUpdate();try{var d=t.model.getParent(a),e=t.getIncomingEdges(a),f=t.cloneCells([e[0],a]);t.model.setTerminal(f[0],t.model.getTerminal(e[0],!0),!0);var g=c(a),l=d.geometry;g==mxConstants.DIRECTION_SOUTH||
+g==mxConstants.DIRECTION_NORTH?f[1].geometry.x+=b?a.geometry.width+10:-f[1].geometry.width-10:f[1].geometry.y+=b?a.geometry.height+10:-f[1].geometry.height-10;t.view.currentRoot!=d&&(f[1].geometry.x-=l.x,f[1].geometry.y-=l.y);var k=t.view.getState(a),m=t.view.scale;if(null!=k){var n=mxRectangle.fromRectangle(k);g==mxConstants.DIRECTION_SOUTH||g==mxConstants.DIRECTION_NORTH?n.x+=(b?a.geometry.width+10:-f[1].geometry.width-10)*m:n.y+=(b?a.geometry.height+10:-f[1].geometry.height-10)*m;var p=t.getOutgoingEdges(t.model.getTerminal(e[0],
+!0));if(null!=p){for(var q=g==mxConstants.DIRECTION_SOUTH||g==mxConstants.DIRECTION_NORTH,u=l=e=0;u<p.length;u++){var z=t.model.getTerminal(p[u],!1);if(g==c(z)){var x=t.view.getState(z);z!=a&&null!=x&&(q&&b!=x.getCenterX()<k.getCenterX()||!q&&b!=x.getCenterY()<k.getCenterY())&&mxUtils.intersects(n,x)&&(e=10+Math.max(e,(Math.min(n.x+n.width,x.x+x.width)-Math.max(n.x,x.x))/m),l=10+Math.max(l,(Math.min(n.y+n.height,x.y+x.height)-Math.max(n.y,x.y))/m))}}q?l=0:e=0;for(u=0;u<p.length;u++)if(z=t.model.getTerminal(p[u],
+!1),g==c(z)&&(x=t.view.getState(z),z!=a&&null!=x&&(q&&b!=x.getCenterX()<k.getCenterX()||!q&&b!=x.getCenterY()<k.getCenterY()))){var v=[];t.traverse(x.cell,!0,function(a,b){null!=b&&v.push(b);v.push(a);return!0});t.moveCells(v,(b?1:-1)*e,(b?1:-1)*l)}}}return t.addCells(f,d)}finally{t.model.endUpdate()}}function g(a){t.model.beginUpdate();try{var b=c(a),d=t.getIncomingEdges(a),e=t.cloneCells([d[0],a]);t.model.setTerminal(d[0],e[1],!1);t.model.setTerminal(e[0],e[1],!0);t.model.setTerminal(e[0],a,!1);
+var f=t.model.getParent(a),g=f.geometry,l=[];t.view.currentRoot!=f&&(e[1].geometry.x-=g.x,e[1].geometry.y-=g.y);t.traverse(a,!0,function(a,b){null!=b&&l.push(b);l.push(a);return!0});var k=a.geometry.width+40,m=a.geometry.height+40;b==mxConstants.DIRECTION_SOUTH?k=0:b==mxConstants.DIRECTION_NORTH?(k=0,m=-m):b==mxConstants.DIRECTION_WEST?(k=-k,m=0):b==mxConstants.DIRECTION_EAST&&(m=0);t.moveCells(l,k,m);return t.addCells(e,f)}finally{t.model.endUpdate()}}function p(a,b){t.model.beginUpdate();try{var d=
+t.model.getParent(a),e=t.getIncomingEdges(a),f=c(a);0==e.length&&(e=[t.createEdge(d,null,"",null,null,t.createCurrentEdgeStyle())],f=b);var g=t.cloneCells([e[0],a]);t.model.setTerminal(g[0],a,!0);if(null==t.model.getTerminal(g[0],!1)){t.model.setTerminal(g[0],g[1],!1);var l=t.getCellStyle(g[1]).newEdgeStyle;if(null!=l)try{var k=JSON.parse(l),m;for(m in k)t.setCellStyles(m,k[m],[g[0]]),"edgeStyle"==m&&"elbowEdgeStyle"==k[m]&&t.setCellStyles("elbow",f==mxConstants.DIRECTION_SOUTH||f==mxConstants.DIRECTION_NOTH?
+"vertical":"horizontal",[g[0]])}catch(T){}}var e=t.getOutgoingEdges(a),n=d.geometry,l=[];t.view.currentRoot==d&&(n=new mxRectangle);for(k=0;k<e.length;k++){var p=t.model.getTerminal(e[k],!1);null!=p&&l.push(p)}var q=t.view.getBounds(l),u=t.view.translate,x=t.view.scale;f==mxConstants.DIRECTION_SOUTH?(g[1].geometry.x=null==q?a.geometry.x+(a.geometry.width-g[1].geometry.width)/2:(q.x+q.width)/x-u.x-n.x+10,g[1].geometry.y+=g[1].geometry.height-n.y+40):f==mxConstants.DIRECTION_NORTH?(g[1].geometry.x=
+null==q?a.geometry.x+(a.geometry.width-g[1].geometry.width)/2:(q.x+q.width)/x-u.x+-n.x+10,g[1].geometry.y-=g[1].geometry.height+n.y+40):(g[1].geometry.x=f==mxConstants.DIRECTION_WEST?g[1].geometry.x-(g[1].geometry.width+n.x+40):g[1].geometry.x+(g[1].geometry.width-n.x+40),g[1].geometry.y=null==q?a.geometry.y+(a.geometry.height-g[1].geometry.height)/2:(q.y+q.height)/x-u.y+-n.y+10);return t.addCells(g,d)}finally{t.model.endUpdate()}}function m(a,b,c){a=t.getOutgoingEdges(a);c=t.view.getState(c);var d=
[];if(null!=c&&null!=a){for(var e=0;e<a.length;e++){var f=t.view.getState(t.model.getTerminal(a[e],!1));null!=f&&(!b&&Math.min(f.x+f.width,c.x+c.width)>=Math.max(f.x,c.x)||b&&Math.min(f.y+f.height,c.y+c.height)>=Math.max(f.y,c.y))&&d.push(f)}d.sort(function(a,c){return b?a.x+a.width-c.x-c.width:a.y+a.height-c.y-c.height})}return d}function n(a,b){var d=c(a),e=b==mxConstants.DIRECTION_EAST||b==mxConstants.DIRECTION_WEST;(d==mxConstants.DIRECTION_EAST||d==mxConstants.DIRECTION_WEST)==e&&d!=b?v.actions.get("selectParent").funct():
-d==b?(e=t.getOutgoingEdges(a),null!=e&&0<e.length&&t.setSelectionCell(t.model.getTerminal(e[0],!1))):(d=t.getIncomingEdges(a),null!=d&&0<d.length&&(e=l(t.model.getTerminal(d[0],!0),e,a),d=t.view.getState(a),null!=d&&(d=mxUtils.indexOf(e,d),0<=d&&(d+=b==mxConstants.DIRECTION_NORTH||b==mxConstants.DIRECTION_WEST?-1:1,0<=d&&d<=e.length-1&&t.setSelectionCell(e[d].cell)))))}var v=this,t=v.editor.graph,u=t.getModel(),A=v.menus.createPopupMenu;v.menus.createPopupMenu=function(b,c,d){A.apply(this,arguments);
+d==b?(e=t.getOutgoingEdges(a),null!=e&&0<e.length&&t.setSelectionCell(t.model.getTerminal(e[0],!1))):(d=t.getIncomingEdges(a),null!=d&&0<d.length&&(e=m(t.model.getTerminal(d[0],!0),e,a),d=t.view.getState(a),null!=d&&(d=mxUtils.indexOf(e,d),0<=d&&(d+=b==mxConstants.DIRECTION_NORTH||b==mxConstants.DIRECTION_WEST?-1:1,0<=d&&d<=e.length-1&&t.setSelectionCell(e[d].cell)))))}var v=this,t=v.editor.graph,u=t.getModel(),A=v.menus.createPopupMenu;v.menus.createPopupMenu=function(b,c,d){A.apply(this,arguments);
if(1==t.getSelectionCount()){c=t.getSelectionCell();var e=t.getOutgoingEdges(c);b.addSeparator();0<e.length&&(a(t.getSelectionCell())&&this.addMenuItems(b,["selectChildren"],null,d),this.addMenuItems(b,["selectDescendants"],null,d));a(t.getSelectionCell())&&(b.addSeparator(),0<t.getIncomingEdges(c).length&&this.addMenuItems(b,["selectSiblings","selectParent"],null,d))}};v.actions.addAction("selectChildren",function(){if(t.isEnabled()&&1==t.getSelectionCount()){var a=t.getSelectionCell(),a=t.getOutgoingEdges(a);
if(null!=a){for(var b=[],c=0;c<a.length;c++)b.push(t.model.getTerminal(a[c],!1));t.setSelectionCells(b)}}},null,null,"Alt+Shift+X");v.actions.addAction("selectSiblings",function(){if(t.isEnabled()&&1==t.getSelectionCount()){var a=t.getSelectionCell(),a=t.getIncomingEdges(a);if(null!=a&&0<a.length&&(a=t.getOutgoingEdges(t.model.getTerminal(a[0],!0)),null!=a)){for(var b=[],c=0;c<a.length;c++)b.push(t.model.getTerminal(a[c],!1));t.setSelectionCells(b)}}},null,null,"Alt+Shift+S");v.actions.addAction("selectParent",
function(){if(t.isEnabled()&&1==t.getSelectionCount()){var a=t.getSelectionCell(),a=t.getIncomingEdges(a);null!=a&&0<a.length&&t.setSelectionCell(t.model.getTerminal(a[0],!0))}},null,null,"Alt+Shift+P");v.actions.addAction("selectDescendants",function(){if(t.isEnabled()&&1==t.getSelectionCount()){var a=t.getSelectionCell(),b=[];t.traverse(a,!0,function(a,c){null!=c&&b.push(c);b.push(a);return!0});t.setSelectionCells(b)}},null,null,"Alt+Shift+D");var B=t.removeCells;t.removeCells=function(b,c){c=null!=
-c?c:!0;null==b&&(b=this.getDeletableCells(this.getSelectionCells()));c&&(b=this.getDeletableCells(this.addAllEdges(b)));for(var d=[],f=0;f<b.length;f++){var g=b[f];u.isEdge(g)&&e(g)&&(d.push(g),g=u.getTerminal(g,!1));if(a(g)){var k=[];t.traverse(g,!0,function(a,b){null!=b&&k.push(b);k.push(a);return!0});0<k.length&&(d=d.concat(k),g=t.getIncomingEdges(b[f]),b=b.concat(g))}else null!=g&&d.push(b[f])}b=d;return B.apply(this,arguments)};v.hoverIcons.getStateAt=function(b,c,d){return a(b.cell)?null:this.graph.view.getState(this.graph.getCellAt(c,
-d))};var D=t.duplicateCells;t.duplicateCells=function(b,c){b=null!=b?b:this.getSelectionCells();for(var d=b.slice(0),e=0;e<d.length;e++){var f=t.view.getState(d[e]);if(null!=f&&a(f.cell))for(var g=t.getIncomingEdges(f.cell),f=0;f<g.length;f++)mxUtils.remove(g[f],b)}this.model.beginUpdate();try{var k=D.call(this,b,c);if(k.length==b.length)for(e=0;e<b.length;e++)if(a(b[e])){var l=t.getIncomingEdges(k[e]),g=t.getIncomingEdges(b[e]);if(0==l.length&&0<g.length){var m=this.cloneCell(g[0]);this.addEdge(m,
-t.getDefaultParent(),this.model.getTerminal(g[0],!0),k[e])}}}finally{this.model.endUpdate()}return k};var C=t.moveCells;t.moveCells=function(b,c,d,e,f,g,k){var l=null;this.model.beginUpdate();try{var m=f,n=this.getCurrentCellStyle(f);if(null!=b&&a(f)&&"1"==mxUtils.getValue(n,"treeFolding","0")){for(var p=0;p<b.length;p++)if(a(b[p])||t.model.isEdge(b[p])&&null==t.model.getTerminal(b[p],!0)){f=t.model.getParent(b[p]);break}if(null!=m&&f!=m&&null!=this.view.getState(b[0])){var q=t.getIncomingEdges(b[0]);
-if(0<q.length){var u=t.view.getState(t.model.getTerminal(q[0],!0));if(null!=u){var x=t.view.getState(m);null!=x&&(c=(x.getCenterX()-u.getCenterX())/t.view.scale,d=(x.getCenterY()-u.getCenterY())/t.view.scale)}}}}l=C.apply(this,arguments);if(null!=l&&null!=b&&l.length==b.length)for(p=0;p<l.length;p++)if(this.model.isEdge(l[p]))a(m)&&0>mxUtils.indexOf(l,this.model.getTerminal(l[p],!0))&&this.model.setTerminal(l[p],m,!0);else if(a(b[p])&&(q=t.getIncomingEdges(b[p]),0<q.length))if(!e)a(m)&&0>mxUtils.indexOf(b,
-this.model.getTerminal(q[0],!0))&&this.model.setTerminal(q[0],m,!0);else if(0==t.getIncomingEdges(l[p]).length){n=m;if(null==n||n==t.model.getParent(b[p]))n=t.model.getTerminal(q[0],!0);e=this.cloneCell(q[0]);this.addEdge(e,t.getDefaultParent(),n,l[p])}}finally{this.model.endUpdate()}return l};if(null!=v.sidebar){var x=v.sidebar.dropAndConnect;v.sidebar.dropAndConnect=function(b,c,d,e){var f=t.model,g=null;f.beginUpdate();try{if(g=x.apply(this,arguments),a(b))for(var k=0;k<g.length;k++)if(f.isEdge(g[k])&&
-null==f.getTerminal(g[k],!0)){f.setTerminal(g[k],b,!0);var l=t.getCellGeometry(g[k]);l.points=null;null!=l.getTerminalPoint(!0)&&l.setTerminalPoint(null,!0)}}finally{f.endUpdate()}return g}}var F={88:v.actions.get("selectChildren"),84:v.actions.get("selectSubtree"),80:v.actions.get("selectParent"),83:v.actions.get("selectSiblings")},G=v.onKeyDown;v.onKeyDown=function(b){try{if(t.isEnabled()&&!t.isEditing()&&a(t.getSelectionCell())&&1==t.getSelectionCount()){var c=null;0<t.getIncomingEdges(t.getSelectionCell()).length&&
+c?c:!0;null==b&&(b=this.getDeletableCells(this.getSelectionCells()));c&&(b=this.getDeletableCells(this.addAllEdges(b)));for(var d=[],f=0;f<b.length;f++){var g=b[f];u.isEdge(g)&&e(g)&&(d.push(g),g=u.getTerminal(g,!1));if(a(g)){var l=[];t.traverse(g,!0,function(a,b){null!=b&&l.push(b);l.push(a);return!0});0<l.length&&(d=d.concat(l),g=t.getIncomingEdges(b[f]),b=b.concat(g))}else null!=g&&d.push(b[f])}b=d;return B.apply(this,arguments)};v.hoverIcons.getStateAt=function(b,c,d){return a(b.cell)?null:this.graph.view.getState(this.graph.getCellAt(c,
+d))};var D=t.duplicateCells;t.duplicateCells=function(b,c){b=null!=b?b:this.getSelectionCells();for(var d=b.slice(0),e=0;e<d.length;e++){var f=t.view.getState(d[e]);if(null!=f&&a(f.cell))for(var g=t.getIncomingEdges(f.cell),f=0;f<g.length;f++)mxUtils.remove(g[f],b)}this.model.beginUpdate();try{var l=D.call(this,b,c);if(l.length==b.length)for(e=0;e<b.length;e++)if(a(b[e])){var k=t.getIncomingEdges(l[e]),g=t.getIncomingEdges(b[e]);if(0==k.length&&0<g.length){var m=this.cloneCell(g[0]);this.addEdge(m,
+t.getDefaultParent(),this.model.getTerminal(g[0],!0),l[e])}}}finally{this.model.endUpdate()}return l};var C=t.moveCells;t.moveCells=function(b,c,d,e,f,g,l){var k=null;this.model.beginUpdate();try{var m=f,n=this.getCurrentCellStyle(f);if(null!=b&&a(f)&&"1"==mxUtils.getValue(n,"treeFolding","0")){for(var p=0;p<b.length;p++)if(a(b[p])||t.model.isEdge(b[p])&&null==t.model.getTerminal(b[p],!0)){f=t.model.getParent(b[p]);break}if(null!=m&&f!=m&&null!=this.view.getState(b[0])){var q=t.getIncomingEdges(b[0]);
+if(0<q.length){var u=t.view.getState(t.model.getTerminal(q[0],!0));if(null!=u){var x=t.view.getState(m);null!=x&&(c=(x.getCenterX()-u.getCenterX())/t.view.scale,d=(x.getCenterY()-u.getCenterY())/t.view.scale)}}}}k=C.apply(this,arguments);if(null!=k&&null!=b&&k.length==b.length)for(p=0;p<k.length;p++)if(this.model.isEdge(k[p]))a(m)&&0>mxUtils.indexOf(k,this.model.getTerminal(k[p],!0))&&this.model.setTerminal(k[p],m,!0);else if(a(b[p])&&(q=t.getIncomingEdges(b[p]),0<q.length))if(!e)a(m)&&0>mxUtils.indexOf(b,
+this.model.getTerminal(q[0],!0))&&this.model.setTerminal(q[0],m,!0);else if(0==t.getIncomingEdges(k[p]).length){n=m;if(null==n||n==t.model.getParent(b[p]))n=t.model.getTerminal(q[0],!0);e=this.cloneCell(q[0]);this.addEdge(e,t.getDefaultParent(),n,k[p])}}finally{this.model.endUpdate()}return k};if(null!=v.sidebar){var x=v.sidebar.dropAndConnect;v.sidebar.dropAndConnect=function(b,c,d,e){var f=t.model,g=null;f.beginUpdate();try{if(g=x.apply(this,arguments),a(b))for(var l=0;l<g.length;l++)if(f.isEdge(g[l])&&
+null==f.getTerminal(g[l],!0)){f.setTerminal(g[l],b,!0);var k=t.getCellGeometry(g[l]);k.points=null;null!=k.getTerminalPoint(!0)&&k.setTerminalPoint(null,!0)}}finally{f.endUpdate()}return g}}var F={88:v.actions.get("selectChildren"),84:v.actions.get("selectSubtree"),80:v.actions.get("selectParent"),83:v.actions.get("selectSiblings")},G=v.onKeyDown;v.onKeyDown=function(b){try{if(t.isEnabled()&&!t.isEditing()&&a(t.getSelectionCell())&&1==t.getSelectionCount()){var c=null;0<t.getIncomingEdges(t.getSelectionCell()).length&&
(9==b.which?c=mxEvent.isShiftDown(b)?g(t.getSelectionCell()):p(t.getSelectionCell()):13==b.which&&(c=f(t.getSelectionCell(),!mxEvent.isShiftDown(b))));if(null!=c&&0<c.length)1==c.length&&t.model.isEdge(c[0])?t.setSelectionCell(t.model.getTerminal(c[0],!1)):t.setSelectionCell(c[c.length-1]),null!=v.hoverIcons&&v.hoverIcons.update(t.view.getState(t.getSelectionCell())),t.startEditingAtCell(t.getSelectionCell()),mxEvent.consume(b);else if(mxEvent.isAltDown(b)&&mxEvent.isShiftDown(b)){var d=F[b.keyCode];
null!=d&&(d.funct(b),mxEvent.consume(b))}else 37==b.keyCode?(n(t.getSelectionCell(),mxConstants.DIRECTION_WEST),mxEvent.consume(b)):38==b.keyCode?(n(t.getSelectionCell(),mxConstants.DIRECTION_NORTH),mxEvent.consume(b)):39==b.keyCode?(n(t.getSelectionCell(),mxConstants.DIRECTION_EAST),mxEvent.consume(b)):40==b.keyCode&&(n(t.getSelectionCell(),mxConstants.DIRECTION_SOUTH),mxEvent.consume(b))}}catch(I){v.handleError(I)}mxEvent.isConsumed(b)||G.apply(this,arguments)};var E=t.connectVertex;t.connectVertex=
-function(b,d,e,k,l,m){var n=t.getIncomingEdges(b);return a(b)?(e=c(b),k=e==mxConstants.DIRECTION_EAST||e==mxConstants.DIRECTION_WEST,l=d==mxConstants.DIRECTION_EAST||d==mxConstants.DIRECTION_WEST,e==d||0==n.length?p(b,d):k==l?g(b):f(b,d!=mxConstants.DIRECTION_NORTH&&d!=mxConstants.DIRECTION_WEST)):E.call(this,b,d,e,k,l,m)};t.getSubtree=function(c){var d=[c];!b(c)&&!a(c)||q(c)||t.traverse(c,!0,function(a,b){null!=b&&0>mxUtils.indexOf(d,b)&&d.push(b);0>mxUtils.indexOf(d,a)&&d.push(a);return!0});return d};
+function(b,d,e,l,k,m){var n=t.getIncomingEdges(b);return a(b)?(e=c(b),l=e==mxConstants.DIRECTION_EAST||e==mxConstants.DIRECTION_WEST,k=d==mxConstants.DIRECTION_EAST||d==mxConstants.DIRECTION_WEST,e==d||0==n.length?p(b,d):l==k?g(b):f(b,d!=mxConstants.DIRECTION_NORTH&&d!=mxConstants.DIRECTION_WEST)):E.call(this,b,d,e,l,k,m)};t.getSubtree=function(c){var d=[c];!b(c)&&!a(c)||q(c)||t.traverse(c,!0,function(a,b){null!=b&&0>mxUtils.indexOf(d,b)&&d.push(b);0>mxUtils.indexOf(d,a)&&d.push(a);return!0});return d};
var J=mxVertexHandler.prototype.init;mxVertexHandler.prototype.init=function(){J.apply(this,arguments);(b(this.state.cell)||a(this.state.cell))&&!q(this.state.cell)&&0<this.graph.getOutgoingEdges(this.state.cell).length&&(this.moveHandle=mxUtils.createImage(Editor.moveImage),this.moveHandle.setAttribute("title","Move Subtree"),this.moveHandle.style.position="absolute",this.moveHandle.style.cursor="pointer",this.moveHandle.style.width="24px",this.moveHandle.style.height="24px",this.graph.container.appendChild(this.moveHandle),
mxEvent.addGestureListeners(this.moveHandle,mxUtils.bind(this,function(a){this.graph.graphHandler.start(this.state.cell,mxEvent.getClientX(a),mxEvent.getClientY(a),this.graph.getSubtree(this.state.cell));this.graph.graphHandler.cellWasClicked=!0;this.graph.isMouseTrigger=mxEvent.isMouseEvent(a);this.graph.isMouseDown=!0;v.hoverIcons.reset();mxEvent.consume(a)})))};var H=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){H.apply(this,arguments);null!=this.moveHandle&&
(this.moveHandle.style.left=this.state.x+this.state.width+(40>this.state.width?10:0)+2+"px",this.moveHandle.style.top=this.state.y+this.state.height+(40>this.state.height?10:0)+2+"px")};var y=mxVertexHandler.prototype.setHandlesVisible;mxVertexHandler.prototype.setHandlesVisible=function(a){y.apply(this,arguments);null!=this.moveHandle&&(this.moveHandle.style.display=a?"":"none")};var K=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=function(a,b){K.apply(this,arguments);null!=
@@ -3543,9 +3543,9 @@ this.moveHandle&&(this.moveHandle.parentNode.removeChild(this.moveHandle),this.m
!0;d.edge=!0;b.insertEdge(d,!0);c.insertEdge(d,!1);a.insert(d);a.insert(b);a.insert(c);return sb.createVertexTemplateFromCells([a],a.geometry.width,a.geometry.height,a.value)}),this.addEntry("tree mindmap mindmaps central idea branch topic",function(){var a=new mxCell("Mindmap",new mxGeometry(0,0,420,126),"swimlane;html=1;startSize=20;horizontal=1;containerType=tree;");a.vertex=!0;var b=new mxCell("Central Idea",new mxGeometry(160,60,100,40),'ellipse;whiteSpace=wrap;html=1;align=center;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');
b.vertex=!0;var c=new mxCell("Topic",new mxGeometry(320,40,80,20),'whiteSpace=wrap;html=1;rounded=1;arcSize=50;align=center;verticalAlign=middle;strokeWidth=1;autosize=1;spacing=4;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');c.vertex=!0;var d=new mxCell("",new mxGeometry(0,0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");d.geometry.relative=!0;d.edge=!0;
b.insertEdge(d,!0);c.insertEdge(d,!1);var e=new mxCell("Branch",new mxGeometry(320,80,72,26),'whiteSpace=wrap;html=1;shape=partialRectangle;top=0;left=0;bottom=1;right=0;points=[[0,1],[1,1]];fillColor=none;align=center;verticalAlign=bottom;routingCenterY=0.5;snapToPoint=1;autosize=1;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');e.vertex=!0;var k=new mxCell("",new mxGeometry(0,0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");
-k.geometry.relative=!0;k.edge=!0;b.insertEdge(k,!0);e.insertEdge(k,!1);var l=new mxCell("Topic",new mxGeometry(20,40,80,20),'whiteSpace=wrap;html=1;rounded=1;arcSize=50;align=center;verticalAlign=middle;strokeWidth=1;autosize=1;spacing=4;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');l.vertex=!0;var n=new mxCell("",new mxGeometry(0,0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");
-n.geometry.relative=!0;n.edge=!0;b.insertEdge(n,!0);l.insertEdge(n,!1);var v=new mxCell("Branch",new mxGeometry(20,80,72,26),'whiteSpace=wrap;html=1;shape=partialRectangle;top=0;left=0;bottom=1;right=0;points=[[0,1],[1,1]];fillColor=none;align=center;verticalAlign=bottom;routingCenterY=0.5;snapToPoint=1;autosize=1;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');v.vertex=!0;var t=new mxCell("",new mxGeometry(0,
-0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");t.geometry.relative=!0;t.edge=!0;b.insertEdge(t,!0);v.insertEdge(t,!1);a.insert(d);a.insert(k);a.insert(n);a.insert(t);a.insert(b);a.insert(c);a.insert(e);a.insert(l);a.insert(v);return sb.createVertexTemplateFromCells([a],a.geometry.width,a.geometry.height,a.value)}),this.addEntry("tree mindmap mindmaps central idea",function(){var a=new mxCell("Central Idea",new mxGeometry(0,0,100,40),'ellipse;whiteSpace=wrap;html=1;align=center;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};treeFolding=1;treeMoving=1;');
+k.geometry.relative=!0;k.edge=!0;b.insertEdge(k,!0);e.insertEdge(k,!1);var m=new mxCell("Topic",new mxGeometry(20,40,80,20),'whiteSpace=wrap;html=1;rounded=1;arcSize=50;align=center;verticalAlign=middle;strokeWidth=1;autosize=1;spacing=4;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');m.vertex=!0;var n=new mxCell("",new mxGeometry(0,0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");
+n.geometry.relative=!0;n.edge=!0;b.insertEdge(n,!0);m.insertEdge(n,!1);var v=new mxCell("Branch",new mxGeometry(20,80,72,26),'whiteSpace=wrap;html=1;shape=partialRectangle;top=0;left=0;bottom=1;right=0;points=[[0,1],[1,1]];fillColor=none;align=center;verticalAlign=bottom;routingCenterY=0.5;snapToPoint=1;autosize=1;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');v.vertex=!0;var t=new mxCell("",new mxGeometry(0,
+0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");t.geometry.relative=!0;t.edge=!0;b.insertEdge(t,!0);v.insertEdge(t,!1);a.insert(d);a.insert(k);a.insert(n);a.insert(t);a.insert(b);a.insert(c);a.insert(e);a.insert(m);a.insert(v);return sb.createVertexTemplateFromCells([a],a.geometry.width,a.geometry.height,a.value)}),this.addEntry("tree mindmap mindmaps central idea",function(){var a=new mxCell("Central Idea",new mxGeometry(0,0,100,40),'ellipse;whiteSpace=wrap;html=1;align=center;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};treeFolding=1;treeMoving=1;');
a.vertex=!0;return sb.createVertexTemplateFromCells([a],a.geometry.width,a.geometry.height,a.value)}),this.addEntry("tree mindmap mindmaps branch",function(){var a=new mxCell("Branch",new mxGeometry(0,0,80,20),'whiteSpace=wrap;html=1;shape=partialRectangle;top=0;left=0;bottom=1;right=0;points=[[0,1],[1,1]];fillColor=none;align=center;verticalAlign=bottom;routingCenterY=0.5;snapToPoint=1;recursiveResize=0;autosize=1;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');
a.vertex=!0;var b=new mxCell("",new mxGeometry(0,0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");b.geometry.setTerminalPoint(new mxPoint(-40,40),!0);b.geometry.relative=!0;b.edge=!0;a.insertEdge(b,!1);return sb.createVertexTemplateFromCells([a,b],a.geometry.width,a.geometry.height,a.value)}),this.addEntry("tree mindmap mindmaps sub topic",function(){var a=new mxCell("Sub Topic",new mxGeometry(0,0,72,26),'whiteSpace=wrap;html=1;rounded=1;arcSize=50;align=center;verticalAlign=middle;strokeWidth=1;autosize=1;spacing=4;treeFolding=1;treeMoving=1;newEdgeStyle={"edgeStyle":"entityRelationEdgeStyle","startArrow":"none","endArrow":"none","segment":10,"curved":1};');
a.vertex=!0;var b=new mxCell("",new mxGeometry(0,0,0,0),"edgeStyle=entityRelationEdgeStyle;startArrow=none;endArrow=none;segment=10;curved=1;");b.geometry.setTerminalPoint(new mxPoint(-40,40),!0);b.geometry.relative=!0;b.edge=!0;a.insertEdge(b,!1);return sb.createVertexTemplateFromCells([a,b],a.geometry.width,a.geometry.height,a.value)}),this.addEntry("tree orgchart organization division",function(){var a=new mxCell("Orgchart",new mxGeometry(0,0,280,220),'swimlane;html=1;startSize=20;horizontal=1;containerType=tree;newEdgeStyle={"edgeStyle":"elbowEdgeStyle","startArrow":"none","endArrow":"none"};');
@@ -3563,13 +3563,13 @@ g.className="geTitle";b.appendChild(g);return g}var d=document.createElement("di
c("newLibrary",mxResources.get("newLibrary")),d.style.boxSizing="border-box",d.style.paddingRight="6px",d.style.paddingLeft="6px",d.style.height="32px",d.style.left="0",d=c("openLibraryFrom",mxResources.get("openLibraryFrom")),d.style.borderLeft="1px solid lightgray",d.style.boxSizing="border-box",d.style.paddingRight="6px",d.style.paddingLeft="6px",d.style.height="32px",d.style.left="50%";b.appendChild(a.sidebar.container);b.style.overflow="hidden";return b});a.sidebarWindow.window.minimumSize=new mxRectangle(0,
0,90,90);a.sidebarWindow.window.setVisible(!0);a.getLocalData("sidebar",function(b){a.sidebar.showEntries(b,null,!0)});a.restoreLibraries()}else a.sidebarWindow.window.setVisible(null!=b?b:!a.sidebarWindow.window.isVisible());a.sidebarWindow.window.isVisible()&&a.sidebarWindow.window.fit()}if("1"==urlParams.lightbox||"0"==urlParams.chrome||"undefined"===typeof window.Format||"undefined"===typeof window.Menus)window.uiTheme=null;else{var e=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;
try{var d=document.createElement("style");d.type="text/css";d.innerHTML="* { -webkit-font-smoothing: antialiased; }html body .mxWindow button.geBtn { font-size:12px !important; margin-left: 0; }html body table.mxWindow td.mxWindowPane div.mxWindowPane *:not(svg *) { font-size:9pt; }table.mxWindow * :not(svg *) { font-size:13px; }html body div.diagramContainer button, html body button.geBtn { font-size:14px; font-weight:700;border-radius: 5px; }html body button.geBtn:active { opacity: 0.6; }html body a.geMenuItem { opacity: 0.75; cursor: pointer; user-select:none; }html body a.geMenuItem[disabled] { opacity: 0.2; }html body a.geMenuItem[disabled]:active { opacity: 0.2; }html body div.geActivePage { opacity: 0.7; }html body a.geMenuItem:active { opacity: 0.2; }html body .geToolbarButton { opacity: 0.3; }html body .geToolbarButton:active { opacity: 0.15; }html body .geStatus:active { opacity: 0.5; }html table.mxPopupMenu tr.mxPopupMenuItemHover:active { opacity:0.7; }html body .geDialog input, html body .geToolbarContainer input, html body .mxWindow input {padding:2px;display:inline-block; }div.geDialog { border-radius: 5px; }html body div.geDialog button.geBigButton { color: #fff !important; border: none !important; }.mxWindow button, .geDialog select, .mxWindow select { display:inline-block; }html body .mxWindow .geColorBtn, html body .geDialog .geColorBtn { background: none; }html body div.diagramContainer button, html body .mxWindow button, html body .geDialog button { min-width: 0px; border-radius: 5px; color: #353535 !important; border-style: solid; border-width: 1px; border-color: rgb(216, 216, 216); }html body div.diagramContainer button:hover, html body .mxWindow button:hover, html body .geDialog button:hover { border-color: rgb(177, 177, 177); }html body div.diagramContainer button:active, html body .mxWindow button:active, html body .geDialog button:active { opacity: 0.6; }div.diagramContainer button.geBtn, .mxWindow button.geBtn, .geDialog button.geBtn { min-width:72px; font-weight: 600; background: none; }div.diagramContainer button.gePrimaryBtn, .mxWindow button.gePrimaryBtn, .geDialog button.gePrimaryBtn, html body .gePrimaryBtn { background: #29b6f2; color: #fff !important; border: none; box-shadow: none; }html body .gePrimaryBtn:hover { background: #29b6f2; border: none; box-shadow: inherit; }html body button.gePrimaryBtn:hover { background: #29b6f2; border: none; }.geBtn button { min-width:72px !important; }div.geToolbarContainer a.geButton { margin:0px; padding: 0 2px 4px 2px; } .geDialog, .mxWindow td.mxWindowPane *, div.geSprite, td.mxWindowTitle, .geDiagramContainer { box-sizing:content-box; }.mxWindow div button.geStyleButton { box-sizing: border-box; }table.mxWindow td.mxWindowPane button.geColorBtn { padding:0px; box-sizing: border-box; }td.mxWindowPane .geSidebarContainer button { padding:2px; box-sizing: border-box; }html body .geMenuItem { font-size:14px; text-decoration: none; font-weight: normal; padding: 6px 10px 6px 10px; border: none; border-radius: 5px; color: #353535; box-shadow: inset 0 0 0 1px rgba(0,0,0,.11), inset 0 -1px 0 0 rgba(0,0,0,.08), 0 1px 2px 0 rgba(0,0,0,.04); }.geToolbarContainer { background:#fff !important; }div.geSidebarContainer { background-color: #ffffff; }div.geSidebarContainer .geTitle { background-color:#fdfdfd; }div.mxWindow td.mxWindowPane button { background-image: none; float: none; }td.mxWindowTitle { height: 22px !important; background: none !important; font-size: 13px !important; text-align:center !important; border-bottom:1px solid lightgray; }div.mxWindow, div.mxWindowTitle { background-image: none !important; background-color:#fff !important; }div.mxWindow { border-radius:5px; box-shadow: 0px 0px 2px #C0C0C0 !important;}div.mxWindow * { font-family: inherit !important; }html div.geVerticalHandle { position:absolute;bottom:0px;left:50%;cursor:row-resize;width:11px;height:11px;background:white;margin-bottom:-6px; margin-left:-6px; border: none; border-radius: 6px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.11), inset 0 -1px 0 0 rgba(0,0,0,.08), 0 1px 2px 0 rgba(0,0,0,.04); }html div.geInactivePage { background: rgb(249, 249, 249) !important; color: #A0A0A0 !important; } html div.geActivePage { background: white !important;color: #353535 !important; } html div.mxRubberband { border:1px solid; border-color: #29b6f2 !important; background:rgba(41,182,242,0.4) !important; } html body div.mxPopupMenu { border-radius:5px; border:1px solid #c0c0c0; padding:5px 0 5px 0; box-shadow: 0px 4px 17px -4px rgba(96,96,96,1); } html table.mxPopupMenu td.mxPopupMenuItem { color: #353535; font-size: 14px; padding-top: 4px; padding-bottom: 4px; }html table.mxPopupMenu tr.mxPopupMenuItemHover { background-color: #29b6f2; }html tr.mxPopupMenuItemHover td.mxPopupMenuItem, html tr.mxPopupMenuItemHover td.mxPopupMenuItem span { color: #fff !important; }html tr.mxPopupMenuItem, html td.mxPopupMenuItem { transition-property: none !important; }html table.mxPopupMenu hr { height: 2px; background-color: rgba(0,0,0,.07); margin: 5px 0; }"+
-(mxClient.IS_IOS?"html input[type=checkbox], html input[type=radio] { height:12px; }":"");document.getElementsByTagName("head")[0].appendChild(d)}catch(u){}var k=function(a,b,c,d,e,f,g){var k=document.createElement("div");k.className="geSidebarContainer";k.style.position="absolute";k.style.width="100%";k.style.height="100%";k.style.border="1px solid whiteSmoke";k.style.overflowX="hidden";k.style.overflowY="auto";g(k);this.window=new mxWindow(b,k,c,d,e,f,!0,!0);this.window.destroyOnClose=!1;this.window.setMaximizable(!1);
+(mxClient.IS_IOS?"html input[type=checkbox], html input[type=radio] { height:12px; }":"");document.getElementsByTagName("head")[0].appendChild(d)}catch(u){}var k=function(a,b,c,d,e,f,g){var l=document.createElement("div");l.className="geSidebarContainer";l.style.position="absolute";l.style.width="100%";l.style.height="100%";l.style.border="1px solid whiteSmoke";l.style.overflowX="hidden";l.style.overflowY="auto";g(l);this.window=new mxWindow(b,l,c,d,e,f,!0,!0);this.window.destroyOnClose=!1;this.window.setMaximizable(!1);
this.window.setResizable(!0);this.window.setClosable(!0);this.window.setVisible(!0);this.window.setLocation=function(a,b){var c=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;a=Math.max(0,Math.min(a,(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)-this.table.clientWidth));b=Math.max(0,Math.min(b,c-this.table.clientHeight-48));this.getX()==a&&this.getY()==b||mxWindow.prototype.setLocation.apply(this,arguments)};mxClient.IS_SF&&
(this.window.div.onselectstart=mxUtils.bind(this,function(b){null==b&&(b=window.event);return null!=b&&a.isSelectionAllowed(b)}))};Editor.checkmarkImage=Graph.createSvgImage(22,18,'<path transform="translate(4 0)" d="M7.181,15.007a1,1,0,0,1-.793-0.391L3.222,10.5A1,1,0,1,1,4.808,9.274L7.132,12.3l6.044-8.86A1,1,0,1,1,14.83,4.569l-6.823,10a1,1,0,0,1-.8.437H7.181Z" fill="#29b6f2"/>').src;mxWindow.prototype.closeImage=Graph.createSvgImage(18,10,'<path d="M 5 1 L 13 9 M 13 1 L 5 9" stroke="#C0C0C0" stroke-width="2"/>').src;
mxWindow.prototype.minimizeImage=Graph.createSvgImage(14,10,'<path d="M 3 7 L 7 3 L 11 7" stroke="#C0C0C0" stroke-width="2" fill="#ffffff"/>').src;mxWindow.prototype.normalizeImage=Graph.createSvgImage(14,10,'<path d="M 3 3 L 7 7 L 11 3" stroke="#C0C0C0" stroke-width="2" fill="#ffffff"/>').src;mxConstraintHandler.prototype.pointImage=Graph.createSvgImage(5,5,'<path d="m 0 0 L 5 5 M 0 5 L 5 0" stroke="#29b6f2"/>');mxOutline.prototype.sizerImage=null;mxConstants.VERTEX_SELECTION_COLOR="#C0C0C0";mxConstants.EDGE_SELECTION_COLOR=
"#C0C0C0";mxConstants.CONNECT_HANDLE_FILLCOLOR="#cee7ff";mxConstants.DEFAULT_VALID_COLOR="#29b6f2";mxConstants.GUIDE_COLOR="#C0C0C0";mxConstants.HIGHLIGHT_STROKEWIDTH=5;mxConstants.HIGHLIGHT_OPACITY=35;mxConstants.OUTLINE_COLOR="#29b6f2";mxConstants.OUTLINE_HANDLE_FILLCOLOR="#29b6f2";mxConstants.OUTLINE_HANDLE_STROKECOLOR="#fff";Graph.prototype.svgShadowColor="#3D4574";Graph.prototype.svgShadowOpacity="0.4";Graph.prototype.svgShadowSize="0.6";Graph.prototype.svgShadowBlur="1.2";Format.prototype.inactiveTabBackgroundColor=
-"#f0f0f0";mxGraphHandler.prototype.previewColor="#C0C0C0";mxRubberband.prototype.defaultOpacity=50;HoverIcons.prototype.inactiveOpacity=25;Format.prototype.showCloseButton=!1;EditorUi.prototype.closableScratchpad=!1;EditorUi.prototype.toolbarHeight=46;EditorUi.prototype.footerHeight=0;Graph.prototype.editAfterInsert=!mxClient.IS_IOS&&!mxClient.IS_ANDROID;Editor.prototype.isChromelessView=function(){return!1};Graph.prototype.isLightboxView=function(){return!1};var m=EditorUi.prototype.updateTabContainer;
-EditorUi.prototype.updateTabContainer=function(){null!=this.tabContainer&&(this.tabContainer.style.right="70px",this.diagramContainer.style.bottom=this.tabContainerHeight+"px");m.apply(this,arguments)};var q=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){q.apply(this,arguments);this.menus.get("save").setEnabled(null!=this.getCurrentFile()||"1"==urlParams.embed)};var c=Menus.prototype.addShortcut;Menus.prototype.addShortcut=function(a,b){null!=b.shortcut&&900>
+"#f0f0f0";mxGraphHandler.prototype.previewColor="#C0C0C0";mxRubberband.prototype.defaultOpacity=50;HoverIcons.prototype.inactiveOpacity=25;Format.prototype.showCloseButton=!1;EditorUi.prototype.closableScratchpad=!1;EditorUi.prototype.toolbarHeight=46;EditorUi.prototype.footerHeight=0;Graph.prototype.editAfterInsert=!mxClient.IS_IOS&&!mxClient.IS_ANDROID;Editor.prototype.isChromelessView=function(){return!1};Graph.prototype.isLightboxView=function(){return!1};var l=EditorUi.prototype.updateTabContainer;
+EditorUi.prototype.updateTabContainer=function(){null!=this.tabContainer&&(this.tabContainer.style.right="70px",this.diagramContainer.style.bottom=this.tabContainerHeight+"px");l.apply(this,arguments)};var q=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){q.apply(this,arguments);this.menus.get("save").setEnabled(null!=this.getCurrentFile()||"1"==urlParams.embed)};var c=Menus.prototype.addShortcut;Menus.prototype.addShortcut=function(a,b){null!=b.shortcut&&900>
e&&!mxClient.IS_IOS?a.firstChild.nextSibling.setAttribute("title",b.shortcut):c.apply(this,arguments)};var f=App.prototype.updateUserElement;App.prototype.updateUserElement=function(){f.apply(this,arguments);if(null!=this.userElement){var a=this.userElement;a.style.cssText="position:relative;margin-right:4px;cursor:pointer;display:"+a.style.display;a.className="geToolbarButton";a.innerHTML="";a.style.backgroundImage="url("+Editor.userImage+")";a.style.backgroundPosition="center center";a.style.backgroundRepeat=
"no-repeat";a.style.backgroundSize="24px 24px";a.style.height="24px";a.style.width="24px";a.style.cssFloat="right";a.setAttribute("title",mxResources.get("changeUser"));"none"!=a.style.display&&(a.style.display="inline-block")}};var g=App.prototype.updateButtonContainer;App.prototype.updateButtonContainer=function(){g.apply(this,arguments);if(null!=this.shareButton){var a=this.shareButton;a.style.cssText="display:inline-block;position:relative;box-sizing:border-box;margin-right:4px;cursor:pointer;";
a.className="geToolbarButton";a.innerHTML="";a.style.backgroundImage="url("+Editor.shareImage+")";a.style.backgroundPosition="center center";a.style.backgroundRepeat="no-repeat";a.style.backgroundSize="24px 24px";a.style.height="24px";a.style.width="24px"}};EditorUi.prototype.addEmbedButtons=function(){if(null!=this.buttonContainer){var a=document.createElement("div");a.style.display="inline-block";a.style.position="relative";a.style.marginTop="8px";a.style.marginRight="4px";var b=document.createElement("a");
@@ -3578,9 +3578,9 @@ a.appendChild(b),"1"==urlParams.saveAndExit&&(b=document.createElement("a"),mxUt
"geMenuItem";b.style.marginLeft="6px";b.style.padding="6px";mxEvent.addListener(b,"click",mxUtils.bind(this,function(){this.actions.get("exit").funct()}));a.appendChild(b);this.buttonContainer.appendChild(a);this.buttonContainer.style.top="6px"}};Sidebar.prototype.getTooltipOffset=function(){var a=mxUtils.getOffset(this.editorUi.sidebarWindow.window.div);a.y+=40;return a};var p=Menus.prototype.createPopupMenu;Menus.prototype.createPopupMenu=function(a,b,c){var d=this.editorUi.editor.graph;a.smartSeparators=
!0;p.apply(this,arguments);mxUtils.bind(this,function(a,b){var c=new FilenameDialog(this.editorUi,a,mxResources.get("apply"),function(a){b(parseFloat(a))},mxResources.get("spacing"));this.editorUi.showDialog(c.container,300,80,!0,!0);c.init()});1==d.getSelectionCount()?(this.addMenuItems(a,["editTooltip","-","editStyle","editGeometry","-"],null,c),d.isCellFoldable(d.getSelectionCell())&&this.addMenuItems(a,d.isCellCollapsed(b)?["expand"]:["collapse"],null,c),this.addMenuItems(a,["collapsible","-",
"lockUnlock","enterGroup"],null,c),a.addSeparator(),this.addSubmenu("layout",a)):d.isSelectionEmpty()&&d.isEnabled()?(a.addSeparator(),this.addMenuItems(a,["editData"],null,c),a.addSeparator(),this.addSubmenu("layout",a),this.addSubmenu("view",a,null,mxResources.get("options")),a.addSeparator(),this.addSubmenu("insert",a),this.addMenuItems(a,["-","exitGroup"],null,c)):d.isEnabled()&&this.addMenuItems(a,["-","lockUnlock"],null,c)};EditorUi.prototype.toggleFormatPanel=function(b){null!=this.formatWindow?
-this.formatWindow.window.setVisible(b?!1:!this.formatWindow.window.isVisible()):a(this)};DiagramFormatPanel.prototype.isMathOptionVisible=function(){return!0};var l=EditorUi.prototype.destroy;EditorUi.prototype.destroy=function(){null!=this.sidebarWindow&&(this.sidebarWindow.window.setVisible(!1),this.sidebarWindow.window.destroy(),this.sidebarWindow=null);null!=this.formatWindow&&(this.formatWindow.window.setVisible(!1),this.formatWindow.window.destroy(),this.formatWindow=null);null!=this.actions.outlineWindow&&
+this.formatWindow.window.setVisible(b?!1:!this.formatWindow.window.isVisible()):a(this)};DiagramFormatPanel.prototype.isMathOptionVisible=function(){return!0};var m=EditorUi.prototype.destroy;EditorUi.prototype.destroy=function(){null!=this.sidebarWindow&&(this.sidebarWindow.window.setVisible(!1),this.sidebarWindow.window.destroy(),this.sidebarWindow=null);null!=this.formatWindow&&(this.formatWindow.window.setVisible(!1),this.formatWindow.window.destroy(),this.formatWindow=null);null!=this.actions.outlineWindow&&
(this.actions.outlineWindow.window.setVisible(!1),this.actions.outlineWindow.window.destroy(),this.actions.outlineWindow=null);null!=this.actions.layersWindow&&(this.actions.layersWindow.window.setVisible(!1),this.actions.layersWindow.window.destroy(),this.actions.layersWindow=null);null!=this.menus.tagsWindow&&(this.menus.tagsWindow.window.setVisible(!1),this.menus.tagsWindow.window.destroy(),this.menus.tagsWindow=null);null!=this.menus.findWindow&&(this.menus.findWindow.window.setVisible(!1),this.menus.findWindow.window.destroy(),
-this.menus.findWindow=null);l.apply(this,arguments)};var n=EditorUi.prototype.setGraphEnabled;EditorUi.prototype.setGraphEnabled=function(a){n.apply(this,arguments);a?1E3<=(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)&&(null!=this.sidebarWindow&&this.sidebarWindow.window.setVisible(!0),null!=this.formatWindow&&this.formatWindow.window.setVisible(!0)):(null!=this.sidebarWindow&&this.sidebarWindow.window.setVisible(!1),null!=this.formatWindow&&this.formatWindow.window.setVisible(!1))};
+this.menus.findWindow=null);m.apply(this,arguments)};var n=EditorUi.prototype.setGraphEnabled;EditorUi.prototype.setGraphEnabled=function(a){n.apply(this,arguments);a?1E3<=(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)&&(null!=this.sidebarWindow&&this.sidebarWindow.window.setVisible(!0),null!=this.formatWindow&&this.formatWindow.window.setVisible(!0)):(null!=this.sidebarWindow&&this.sidebarWindow.window.setVisible(!1),null!=this.formatWindow&&this.formatWindow.window.setVisible(!1))};
EditorUi.prototype.chromelessWindowResize=function(){};var v=Menus.prototype.init;Menus.prototype.init=function(){v.apply(this,arguments);var c=this.editorUi,d=c.editor.graph;c.actions.get("editDiagram").label=mxResources.get("formatXml")+"...";c.actions.get("createShape").label=mxResources.get("shape")+"...";c.actions.get("outline").label=mxResources.get("outline")+"...";c.actions.get("layers").label=mxResources.get("layers")+"...";c.actions.put("importCsv",new Action(mxResources.get("csv")+"...",
function(){d.popupMenuHandler.hideMenu();c.showImportCsvDialog()}));c.actions.put("importText",new Action(mxResources.get("text")+"...",function(){var a=new ParseDialog(c,"Insert from Text");c.showDialog(a.container,620,420,!0,!1);a.init()}));c.actions.put("formatSql",new Action(mxResources.get("formatSql")+"...",function(){var a=new ParseDialog(c,"Insert from Text","formatSql");c.showDialog(a.container,620,420,!0,!1);a.init()}));c.actions.put("toggleShapes",new Action(mxResources.get("shapes")+"...",
function(){b(c)}));c.actions.put("toggleFormat",new Action(mxResources.get("format")+"...",function(){a(c)}));EditorUi.enablePlantUml&&!c.isOffline()&&c.actions.put("plantUml",new Action(mxResources.get("plantUml")+"...",function(){var a=new ParseDialog(c,"Insert from Text","plantUml");c.showDialog(a.container,620,420,!0,!1);a.init()}));this.put("diagram",new Menu(mxUtils.bind(this,function(a,b){var d=c.getCurrentFile();c.menus.addSubmenu("extras",a,b,mxResources.get("preferences"));a.addSeparator(b);
@@ -3590,32 +3590,32 @@ b);c.menus.addMenuItems(a,["-","find","tags"],b);null!=d&&null!=c.fileNode&&(d=n
null!=d&&d.constructor==DriveFile?c.menus.addMenuItems(a,["save","makeCopy","-","rename","moveToFolder"],b):(c.menus.addMenuItems(a,["save","saveAs","-","rename"],b),c.isOfflineApp()?navigator.onLine&&"1"!=urlParams.stealth&&this.addMenuItems(a,["upload"],b):c.menus.addMenuItems(a,["makeCopy"],b));c.menus.addMenuItems(a,["-","autosave"],b);null!=d&&d.isRevisionHistorySupported()&&c.menus.addMenuItems(a,["-","revisionHistory"],b)})));var e=this.get("exportAs");this.put("exportAs",new Menu(mxUtils.bind(this,
function(a,b){e.funct(a,b);mxClient.IS_CHROMEAPP||EditorUi.isElectronApp||c.menus.addMenuItems(a,["publishLink"],b);a.addSeparator(b);c.menus.addSubmenu("embed",a,b)})));var f=this.get("language");this.put("extras",new Menu(mxUtils.bind(this,function(a,b){"1"!=urlParams.embed&&c.menus.addSubmenu("theme",a,b);null!=f&&c.menus.addSubmenu("language",a,b);c.menus.addSubmenu("units",a,b);a.addSeparator(b);c.menus.addMenuItems(a,["scrollbars","tooltips","ruler"],b);"1"!=urlParams.embed&&(isLocalStorage||
mxClient.IS_CHROMEAPP)&&c.menus.addMenuItems(a,["-","search","scratchpad","-","showStartScreen"],b);!c.isOfflineApp()&&isLocalStorage&&c.menus.addMenuItem(a,"plugins",b);a.addSeparator(b);c.menus.addMenuItem(a,"drawConfig",b);a.addSeparator(b)})));this.put("insertAdvanced",new Menu(mxUtils.bind(this,function(a,b){c.menus.addMenuItems(a,"importText plantUml - formatSql importCsv - createShape editDiagram".split(" "),b)})));mxUtils.bind(this,function(){var a=this.get("insert"),b=a.funct;a.funct=function(a,
-d){b.apply(this,arguments);a.addSeparator(d);c.menus.addMenuItems(a,["-","toggleShapes"],d)}})();var g="horizontalFlow verticalFlow - horizontalTree verticalTree radialTree - organic circle".split(" "),k=function(a,b,d,e){a.addItem(d,null,mxUtils.bind(this,function(){var a=new CreateGraphDialog(c,d,e);c.showDialog(a.container,620,420,!0,!1);a.init()}),b)};this.put("insertLayout",new Menu(mxUtils.bind(this,function(a,b){for(var c=0;c<g.length;c++)"-"==g[c]?a.addSeparator(b):k(a,b,mxResources.get(g[c])+
+d){b.apply(this,arguments);a.addSeparator(d);c.menus.addMenuItems(a,["-","toggleShapes"],d)}})();var g="horizontalFlow verticalFlow - horizontalTree verticalTree radialTree - organic circle".split(" "),l=function(a,b,d,e){a.addItem(d,null,mxUtils.bind(this,function(){var a=new CreateGraphDialog(c,d,e);c.showDialog(a.container,620,420,!0,!1);a.init()}),b)};this.put("insertLayout",new Menu(mxUtils.bind(this,function(a,b){for(var c=0;c<g.length;c++)"-"==g[c]?a.addSeparator(b):l(a,b,mxResources.get(g[c])+
"...",g[c])})));this.put("view",new Menu(mxUtils.bind(this,function(a,b){c.menus.addMenuItems(a,"grid guides ruler - connectionArrows connectionPoints -".split(" "),b);if("undefined"!==typeof MathJax){var d=c.menus.addMenuItem(a,"mathematicalTypesetting",b);c.menus.addLinkToItem(d,"https://desk.draw.io/support/solutions/articles/16000032875")}c.menus.addMenuItems(a,["copyConnect","collapseExpand","-","pageScale"],b)})))};var t=EditorUi.prototype.init;EditorUi.prototype.init=function(){function c(a,
-b,c){var d=l.menus.get(a),e=q.addMenu(mxResources.get(a),mxUtils.bind(this,function(){d.funct.apply(this,arguments)}),p);e.className="geMenuItem";e.style.display="inline-block";e.style.boxSizing="border-box";e.style.top="6px";e.style.marginRight="6px";e.style.height="30px";e.style.paddingTop="6px";e.style.paddingBottom="6px";e.style.cursor="pointer";e.setAttribute("title",mxResources.get(a));l.menus.menuCreated(d,e,"geMenuItem");null!=c?(e.style.backgroundImage="url("+c+")",e.style.backgroundPosition=
+b,c){var d=k.menus.get(a),e=q.addMenu(mxResources.get(a),mxUtils.bind(this,function(){d.funct.apply(this,arguments)}),p);e.className="geMenuItem";e.style.display="inline-block";e.style.boxSizing="border-box";e.style.top="6px";e.style.marginRight="6px";e.style.height="30px";e.style.paddingTop="6px";e.style.paddingBottom="6px";e.style.cursor="pointer";e.setAttribute("title",mxResources.get(a));k.menus.menuCreated(d,e,"geMenuItem");null!=c?(e.style.backgroundImage="url("+c+")",e.style.backgroundPosition=
"center center",e.style.backgroundRepeat="no-repeat",e.style.backgroundSize="24px 24px",e.style.width="34px",e.innerHTML=""):b||(e.style.backgroundImage="url("+mxWindow.prototype.normalizeImage+")",e.style.backgroundPosition="right 6px center",e.style.backgroundRepeat="no-repeat",e.style.paddingRight="22px");return e}function d(a,b,c,d,e,f){var g=document.createElement("a");g.className="geMenuItem";g.style.display="inline-block";g.style.boxSizing="border-box";g.style.height="30px";g.style.padding=
-"6px";g.style.position="relative";g.style.verticalAlign="top";g.style.top="0px";null!=l.statusContainer?n.insertBefore(g,l.statusContainer):n.appendChild(g);null!=f?(g.style.backgroundImage="url("+f+")",g.style.backgroundPosition="center center",g.style.backgroundRepeat="no-repeat",g.style.backgroundSize="24px 24px",g.style.width="34px"):mxUtils.write(g,a);mxEvent.addListener(g,mxClient.IS_POINTER?"pointerdown":"mousedown",mxUtils.bind(this,function(a){a.preventDefault()}));mxEvent.addListener(g,
+"6px";g.style.position="relative";g.style.verticalAlign="top";g.style.top="0px";null!=k.statusContainer?n.insertBefore(g,k.statusContainer):n.appendChild(g);null!=f?(g.style.backgroundImage="url("+f+")",g.style.backgroundPosition="center center",g.style.backgroundRepeat="no-repeat",g.style.backgroundSize="24px 24px",g.style.width="34px"):mxUtils.write(g,a);mxEvent.addListener(g,mxClient.IS_POINTER?"pointerdown":"mousedown",mxUtils.bind(this,function(a){a.preventDefault()}));mxEvent.addListener(g,
"click",function(a){"disabled"!=g.getAttribute("disabled")&&b(a);mxEvent.consume(a)});null==c&&(g.style.marginRight="4px");null!=d&&g.setAttribute("title",d);null!=e&&(a=function(){e.isEnabled()?(g.removeAttribute("disabled"),g.style.cursor="pointer"):(g.setAttribute("disabled","disabled"),g.style.cursor="default")},e.addListener("stateChanged",a),a());return g}function f(a,b){var c=document.createElement("div");c.className="geMenuItem";c.style.display="inline-block";c.style.verticalAlign="top";c.style.marginRight=
-"6px";c.style.padding="0 4px 0 4px";c.style.height="30px";c.style.position="relative";c.style.top="0px";for(var d=0;d<a.length;d++)null!=a[d]&&(a[d].style.margin="0px",a[d].style.boxShadow="none",c.appendChild(a[d]));null!=b&&mxUtils.setOpacity(c,b);null!=l.statusContainer?n.insertBefore(c,l.statusContainer):n.appendChild(c);return c}function g(){for(var a=n.firstChild;null!=a;){var b=a.nextSibling;"geMenuItem"!=a.className&&"geItem"!=a.className||a.parentNode.removeChild(a);a=b}p=n.firstChild;e=
-window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;(a=1E3>e)||c("diagram");f([a?c("diagram",null,IMAGE_PATH+"/drawlogo.svg"):null,d(mxResources.get("shapes"),l.actions.get("toggleShapes").funct,null,mxResources.get("shapes"),l.actions.get("image"),a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTMgMTN2OGg4di04aC04ek0zIDIxaDh2LThIM3Y4ek0zIDN2OGg4VjNIM3ptMTMuNjYtMS4zMUwxMSA3LjM0IDE2LjY2IDEzbDUuNjYtNS42Ni01LjY2LTUuNjV6Ii8+PC9zdmc+":
-null),d(mxResources.get("format"),l.actions.get("toggleFormat").funct,null,mxResources.get("format")+" ("+l.actions.get("formatPanel").shortcut+")",l.actions.get("image"),a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTIgM2MtNC45NyAwLTkgNC4wMy05IDlzNC4wMyA5IDkgOWMuODMgMCAxLjUtLjY3IDEuNS0xLjUgMC0uMzktLjE1LS43NC0uMzktMS4wMS0uMjMtLjI2LS4zOC0uNjEtLjM4LS45OSAwLS44My42Ny0xLjUgMS41LTEuNUgxNmMyLjc2IDAgNS0yLjI0IDUtNSAwLTQuNDItNC4wMy04LTktOHptLTUuNSA5Yy0uODMgMC0xLjUtLjY3LTEuNS0xLjVTNS42NyA5IDYuNSA5IDggOS42NyA4IDEwLjUgNy4zMyAxMiA2LjUgMTJ6bTMtNEM4LjY3IDggOCA3LjMzIDggNi41UzguNjcgNSA5LjUgNXMxLjUuNjcgMS41IDEuNVMxMC4zMyA4IDkuNSA4em01IDBjLS44MyAwLTEuNS0uNjctMS41LTEuNVMxMy42NyA1IDE0LjUgNXMxLjUuNjcgMS41IDEuNVMxNS4zMyA4IDE0LjUgOHptMyA0Yy0uODMgMC0xLjUtLjY3LTEuNS0xLjVTMTYuNjcgOSAxNy41IDlzMS41LjY3IDEuNSAxLjUtLjY3IDEuNS0xLjUgMS41eiIvPjwvc3ZnPg==":
-null)],a?60:null);b=c("insert",!0,a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTkgMTNoLTZ2NmgtMnYtNkg1di0yaDZWNWgydjZoNnYyeiIvPjwvc3ZnPg==":null);f([b,d(mxResources.get("delete"),l.actions.get("delete").funct,null,mxResources.get("delete"),l.actions.get("delete"),a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNNiAxOWMwIDEuMS45IDIgMiAyaDhjMS4xIDAgMi0uOSAyLTJWN0g2djEyek0xOSA0aC0zLjVsLTEtMWgtNWwtMSAxSDV2MmgxNFY0eiIvPjwvc3ZnPg==":
-null)],a?60:null);if(411<=e&&(b=l.actions.get("undo"),a=l.actions.get("redo"),b=d("",b.funct,null,mxResources.get("undo")+" ("+b.shortcut+")",b,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTIuNSA4Yy0yLjY1IDAtNS4wNS45OS02LjkgMi42TDIgN3Y5aDlsLTMuNjItMy42MmMxLjM5LTEuMTYgMy4xNi0xLjg4IDUuMTItMS44OCAzLjU0IDAgNi41NSAyLjMxIDcuNiA1LjVsMi4zNy0uNzhDMjEuMDggMTEuMDMgMTcuMTUgOCAxMi41IDh6Ii8+PC9zdmc+"),a=d("",
-a.funct,null,mxResources.get("redo")+" ("+a.shortcut+")",a,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTguNCAxMC42QzE2LjU1IDguOTkgMTQuMTUgOCAxMS41IDhjLTQuNjUgMC04LjU4IDMuMDMtOS45NiA3LjIyTDMuOSAxNmMxLjA1LTMuMTkgNC4wNS01LjUgNy42LTUuNSAxLjk1IDAgMy43My43MiA1LjEyIDEuODhMMTMgMTZoOVY3bC0zLjYgMy42eiIvPjwvc3ZnPg=="),f([b,a],60),480<=e)){var a=l.actions.get("zoomIn"),b=l.actions.get("zoomOut"),g=l.actions.get("resetView");
-f([d("",function(){m.popupMenuHandler.hideMenu();var a=m.view.scale,b=m.view.translate.x,c=m.view.translate.y;l.actions.get("resetView").funct();1E-5>Math.abs(a-m.view.scale)&&b==m.view.translate.x&&c==m.view.translate.y&&l.actions.get(m.pageVisible?"fitPage":"fitWindow").funct()},!0,mxResources.get("fit")+" ("+Editor.ctrlKey+"+H)",g,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMyA1djRoMlY1aDRWM0g1Yy0xLjEgMC0yIC45LTIgMnptMiAxMEgzdjRjMCAxLjEuOSAyIDIgMmg0di0ySDV2LTR6bTE0IDRoLTR2Mmg0YzEuMSAwIDItLjkgMi0ydi00aC0ydjR6bTAtMTZoLTR2Mmg0djRoMlY1YzAtMS4xLS45LTItMi0yeiIvPjwvc3ZnPg=="),
+"6px";c.style.padding="0 4px 0 4px";c.style.height="30px";c.style.position="relative";c.style.top="0px";for(var d=0;d<a.length;d++)null!=a[d]&&(a[d].style.margin="0px",a[d].style.boxShadow="none",c.appendChild(a[d]));null!=b&&mxUtils.setOpacity(c,b);null!=k.statusContainer?n.insertBefore(c,k.statusContainer):n.appendChild(c);return c}function g(){for(var a=n.firstChild;null!=a;){var b=a.nextSibling;"geMenuItem"!=a.className&&"geItem"!=a.className||a.parentNode.removeChild(a);a=b}p=n.firstChild;e=
+window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;(a=1E3>e)||c("diagram");f([a?c("diagram",null,IMAGE_PATH+"/drawlogo.svg"):null,d(mxResources.get("shapes"),k.actions.get("toggleShapes").funct,null,mxResources.get("shapes"),k.actions.get("image"),a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTMgMTN2OGg4di04aC04ek0zIDIxaDh2LThIM3Y4ek0zIDN2OGg4VjNIM3ptMTMuNjYtMS4zMUwxMSA3LjM0IDE2LjY2IDEzbDUuNjYtNS42Ni01LjY2LTUuNjV6Ii8+PC9zdmc+":
+null),d(mxResources.get("format"),k.actions.get("toggleFormat").funct,null,mxResources.get("format")+" ("+k.actions.get("formatPanel").shortcut+")",k.actions.get("image"),a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTIgM2MtNC45NyAwLTkgNC4wMy05IDlzNC4wMyA5IDkgOWMuODMgMCAxLjUtLjY3IDEuNS0xLjUgMC0uMzktLjE1LS43NC0uMzktMS4wMS0uMjMtLjI2LS4zOC0uNjEtLjM4LS45OSAwLS44My42Ny0xLjUgMS41LTEuNUgxNmMyLjc2IDAgNS0yLjI0IDUtNSAwLTQuNDItNC4wMy04LTktOHptLTUuNSA5Yy0uODMgMC0xLjUtLjY3LTEuNS0xLjVTNS42NyA5IDYuNSA5IDggOS42NyA4IDEwLjUgNy4zMyAxMiA2LjUgMTJ6bTMtNEM4LjY3IDggOCA3LjMzIDggNi41UzguNjcgNSA5LjUgNXMxLjUuNjcgMS41IDEuNVMxMC4zMyA4IDkuNSA4em01IDBjLS44MyAwLTEuNS0uNjctMS41LTEuNVMxMy42NyA1IDE0LjUgNXMxLjUuNjcgMS41IDEuNVMxNS4zMyA4IDE0LjUgOHptMyA0Yy0uODMgMC0xLjUtLjY3LTEuNS0xLjVTMTYuNjcgOSAxNy41IDlzMS41LjY3IDEuNSAxLjUtLjY3IDEuNS0xLjUgMS41eiIvPjwvc3ZnPg==":
+null)],a?60:null);b=c("insert",!0,a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTkgMTNoLTZ2NmgtMnYtNkg1di0yaDZWNWgydjZoNnYyeiIvPjwvc3ZnPg==":null);f([b,d(mxResources.get("delete"),k.actions.get("delete").funct,null,mxResources.get("delete"),k.actions.get("delete"),a?"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNNiAxOWMwIDEuMS45IDIgMiAyaDhjMS4xIDAgMi0uOSAyLTJWN0g2djEyek0xOSA0aC0zLjVsLTEtMWgtNWwtMSAxSDV2MmgxNFY0eiIvPjwvc3ZnPg==":
+null)],a?60:null);if(411<=e&&(b=k.actions.get("undo"),a=k.actions.get("redo"),b=d("",b.funct,null,mxResources.get("undo")+" ("+b.shortcut+")",b,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTIuNSA4Yy0yLjY1IDAtNS4wNS45OS02LjkgMi42TDIgN3Y5aDlsLTMuNjItMy42MmMxLjM5LTEuMTYgMy4xNi0xLjg4IDUuMTItMS44OCAzLjU0IDAgNi41NSAyLjMxIDcuNiA1LjVsMi4zNy0uNzhDMjEuMDggMTEuMDMgMTcuMTUgOCAxMi41IDh6Ii8+PC9zdmc+"),a=d("",
+a.funct,null,mxResources.get("redo")+" ("+a.shortcut+")",a,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTguNCAxMC42QzE2LjU1IDguOTkgMTQuMTUgOCAxMS41IDhjLTQuNjUgMC04LjU4IDMuMDMtOS45NiA3LjIyTDMuOSAxNmMxLjA1LTMuMTkgNC4wNS01LjUgNy42LTUuNSAxLjk1IDAgMy43My43MiA1LjEyIDEuODhMMTMgMTZoOVY3bC0zLjYgMy42eiIvPjwvc3ZnPg=="),f([b,a],60),480<=e)){var a=k.actions.get("zoomIn"),b=k.actions.get("zoomOut"),g=k.actions.get("resetView");
+f([d("",function(){m.popupMenuHandler.hideMenu();var a=m.view.scale,b=m.view.translate.x,c=m.view.translate.y;k.actions.get("resetView").funct();1E-5>Math.abs(a-m.view.scale)&&b==m.view.translate.x&&c==m.view.translate.y&&k.actions.get(m.pageVisible?"fitPage":"fitWindow").funct()},!0,mxResources.get("fit")+" ("+Editor.ctrlKey+"+H)",g,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMyA1djRoMlY1aDRWM0g1Yy0xLjEgMC0yIC45LTIgMnptMiAxMEgzdjRjMCAxLjEuOSAyIDIgMmg0di0ySDV2LTR6bTE0IDRoLTR2Mmg0YzEuMSAwIDItLjkgMi0ydi00aC0ydjR6bTAtMTZoLTR2Mmg0djRoMlY1YzAtMS4xLS45LTItMi0yeiIvPjwvc3ZnPg=="),
640<=e?d("",a.funct,!0,mxResources.get("zoomIn")+" ("+Editor.ctrlKey+" +)",a,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTUuNSAxNGgtLjc5bC0uMjgtLjI3QzE1LjQxIDEyLjU5IDE2IDExLjExIDE2IDkuNSAxNiA1LjkxIDEzLjA5IDMgOS41IDNTMyA1LjkxIDMgOS41IDUuOTEgMTYgOS41IDE2YzEuNjEgMCAzLjA5LS41OSA0LjIzLTEuNTdsLjI3LjI4di43OWw1IDQuOTlMMjAuNDkgMTlsLTQuOTktNXptLTYgMEM3LjAxIDE0IDUgMTEuOTkgNSA5LjVTNy4wMSA1IDkuNSA1IDE0IDcuMDEgMTQgOS41IDExLjk5IDE0IDkuNSAxNHptMi41LTRoLTJ2Mkg5di0ySDdWOWgyVjdoMXYyaDJ2MXoiLz48L3N2Zz4="):
null,640<=e?d("",b.funct,!0,mxResources.get("zoomOut")+" ("+Editor.ctrlKey+" -)",b,"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBkPSJNMTUuNSAxNGgtLjc5bC0uMjgtLjI3QzE1LjQxIDEyLjU5IDE2IDExLjExIDE2IDkuNSAxNiA1LjkxIDEzLjA5IDMgOS41IDNTMyA1LjkxIDMgOS41IDUuOTEgMTYgOS41IDE2YzEuNjEgMCAzLjA5LS41OSA0LjIzLTEuNTdsLjI3LjI4di43OWw1IDQuOTlMMjAuNDkgMTlsLTQuOTktNXptLTYgMEM3LjAxIDE0IDUgMTEuOTkgNSA5LjVTNy4wMSA1IDkuNSA1IDE0IDcuMDEgMTQgOS41IDExLjk5IDE0IDkuNSAxNHpNNyA5aDV2MUg3eiIvPjwvc3ZnPg=="):
-null],60)}a=l.menus.get("language");null!=a&&!mxClient.IS_CHROMEAPP&&!EditorUi.isElectronApp&&600<=e?(null==O&&(b=q.addMenu("",a.funct),b.setAttribute("title",mxResources.get("language")),b.className="geToolbarButton",b.style.backgroundImage="url("+Editor.globeImage+")",b.style.backgroundPosition="center center",b.style.backgroundRepeat="no-repeat",b.style.backgroundSize="24px 24px",b.style.position="absolute",b.style.height="24px",b.style.width="24px",b.style.zIndex="1",b.style.right="8px",b.style.cursor=
-"pointer",b.style.top="1"==urlParams.embed?"12px":"11px",n.appendChild(b),O=b),l.buttonContainer.style.paddingRight="34px"):(l.buttonContainer.style.paddingRight="4px",null!=O&&(O.parentNode.removeChild(O),O=null))}t.apply(this,arguments);var k=document.createElement("div");k.style.cssText="position:absolute;left:0px;right:0px;top:0px;overflow-y:auto;overflow-x:hidden;";k.style.bottom="1"!=urlParams.embed||"1"==urlParams.libraries?"63px":"32px";this.sidebar=this.createSidebar(k);(1E3<=e||null!=urlParams.clibs||
-null!=urlParams.libs)&&b(this,!0);1E3<=e&&a(this,!0);var l=this,m=l.editor.graph;l.toolbar=this.createToolbar(l.createDiv("geToolbar"));l.defaultLibraryName=mxResources.get("untitledLibrary");var n=document.createElement("div");n.style.cssText="position:absolute;left:0px;right:0px;top:0px;height:30px;padding:8px;border-bottom:1px solid lightgray;background-color:#ffffff;text-align:left;white-space:nowrap;";var p=null,q=new Menubar(l,n);l.statusContainer=l.createStatusContainer();l.statusContainer.style.position=
-"relative";l.statusContainer.style.maxWidth="";l.statusContainer.style.marginTop="7px";l.statusContainer.style.marginLeft="6px";l.statusContainer.style.color="gray";l.statusContainer.style.cursor="default";l.editor.addListener("statusChanged",mxUtils.bind(this,function(){l.setStatusText(l.editor.getStatus())}));var v=l.descriptorChanged;l.descriptorChanged=function(){v.apply(this,arguments);var a=l.getCurrentFile();if(null!=a&&null!=a.getTitle()){var b=a.getMode();"google"==b?b="googleDrive":"github"==
-b?b="gitHub":"gitlab"==b?b="gitLab":"onedrive"==b&&(b="oneDrive");b=mxResources.get(b);n.setAttribute("title",a.getTitle()+(null!=b?" ("+b+")":""))}else n.removeAttribute("title")};l.setStatusText(l.editor.getStatus());n.appendChild(l.statusContainer);l.buttonContainer=document.createElement("div");l.buttonContainer.style.cssText="position:absolute;right:0px;padding-right:34px;top:10px;white-space:nowrap;padding-top:2px;background-color:inherit;";n.appendChild(l.buttonContainer);l.menubarContainer=
-l.buttonContainer;l.tabContainer=document.createElement("div");l.tabContainer.style.cssText="position:absolute;left:0px;right:0px;bottom:0px;height:30px;white-space:nowrap;border-bottom:1px solid lightgray;background-color:#ffffff;border-top:1px solid lightgray;margin-bottom:-2px;visibility:hidden;";var k=l.diagramContainer.parentNode,y=document.createElement("div");y.style.cssText="position:absolute;top:0px;left:0px;right:0px;bottom:0px;overflow:hidden;";l.diagramContainer.style.top="47px";var K=
-l.menus.get("viewZoom");if(null!=K){this.tabContainer.style.right="70px";var z=q.addMenu("100%",K.funct);z.setAttribute("title",mxResources.get("zoom")+" (Alt+Mousewheel)");z.style.whiteSpace="nowrap";z.style.backgroundImage="url("+mxWindow.prototype.minimizeImage+")";z.style.backgroundPosition="right 6px center";z.style.backgroundRepeat="no-repeat";z.style.backgroundColor="#ffffff";z.style.paddingRight="10px";z.style.display="block";z.style.position="absolute";z.style.textDecoration="none";z.style.textDecoration=
-"none";z.style.right="0px";z.style.bottom="0px";z.style.overflow="hidden";z.style.visibility="hidden";z.style.textAlign="center";z.style.color="#000";z.style.fontSize="12px";z.style.color="#707070";z.style.width="59px";z.style.cursor="pointer";z.style.borderTop="1px solid lightgray";z.style.borderLeft="1px solid lightgray";z.style.height=parseInt(l.tabContainerHeight)-1+"px";z.style.lineHeight=parseInt(l.tabContainerHeight)+1+"px";y.appendChild(z);K=mxUtils.bind(this,function(){z.innerHTML=Math.round(100*
-l.editor.graph.view.scale)+"%"});l.editor.graph.view.addListener(mxEvent.EVENT_SCALE,K);l.editor.addListener("resetGraphView",K);l.editor.addListener("pageSelected",K);var L=l.setGraphEnabled;l.setGraphEnabled=function(){L.apply(this,arguments);null!=this.tabContainer&&(z.style.visibility=this.tabContainer.style.visibility,this.diagramContainer.style.bottom="hidden"!=this.tabContainer.style.visibility?this.tabContainerHeight+"px":"0px")}}y.appendChild(l.tabContainer);y.appendChild(n);y.appendChild(l.diagramContainer);
-k.appendChild(y);l.updateTabContainer();var O=null;g();mxEvent.addListener(window,"resize",function(){g();null!=l.sidebarWindow&&l.sidebarWindow.window.fit();null!=l.formatWindow&&l.formatWindow.window.fit();null!=l.actions.outlineWindow&&l.actions.outlineWindow.window.fit();null!=l.actions.layersWindow&&l.actions.layersWindow.window.fit();null!=l.menus.tagsWindow&&l.menus.tagsWindow.window.fit();null!=l.menus.findWindow&&l.menus.findWindow.window.fit()})}}};
-(function(){var a=!1;"min"!=uiTheme||a||mxClient.IS_CHROMEAPP||(EditorUi.initMinimalTheme(),a=!0);var b=EditorUi.initTheme;EditorUi.initTheme=function(){b.apply(this,arguments);"min"!=uiTheme||a||(this.initMinimalTheme(),a=!0)}})();DrawioComment=function(a,b,e,d,k,m,q){this.file=a;this.id=b;this.content=e;this.modifiedDate=d;this.createdDate=k;this.isResolved=m;this.user=q;this.replies=[]};DrawioComment.prototype.addReplyDirect=function(a){null!=a&&this.replies.push(a)};DrawioComment.prototype.addReply=function(a,b,e,d,k){b()};DrawioComment.prototype.editComment=function(a,b,e){b()};DrawioComment.prototype.deleteComment=function(a,b){a()};DrawioUser=function(a,b,e,d,k){this.id=a;this.email=b;this.displayName=e;this.pictureUrl=d;this.locale=k};mxResources.parse('# *DO NOT DIRECTLY EDIT THIS FILE, IT IS AUTOMATICALLY GENERATED AND IT IS BASED ON:*\n# https://docs.google.com/spreadsheet/ccc?key=0AmQEO36liL4FdDJLWVNMaVV2UmRKSnpXU09MYkdGbEE\nabout=About \naboutDrawio=About draw.io\naccessDenied=Access Denied\naction=Action\nactualSize=Actual Size\nadd=Add\naddAccount=Add account\naddedFile=Added {1}\naddImages=Add Images\naddImageUrl=Add Image URL\naddLayer=Add Layer\naddProperty=Add Property\naddress=Address\naddToExistingDrawing=Add to Existing Drawing\naddWaypoint=Add Waypoint\nadjustTo=Adjust to\nadvanced=Advanced\nalign=Align\nalignment=Alignment\nallChangesLost=All changes will be lost!\nallPages=All Pages\nallProjects=All Projects\nallSpaces=All Spaces\nallTags=All Tags\nanchor=Anchor\nandroid=Android\nangle=Angle\narc=Arc\nareYouSure=Are you sure?\nensureDataSaved=Please ensure your data is saved before closing.\nallChangesSaved=All changes saved\nallChangesSavedInDrive=All changes saved in Drive\nallowPopups=Allow pop-ups to avoid this dialog.\nallowRelativeUrl=Allow relative URL\nalreadyConnected=Nodes already connected\napply=Apply\narchiMate21=ArchiMate 2.1\narrange=Arrange\narrow=Arrow\narrows=Arrows\nasNew=As New\natlas=Atlas\nauthor=Author\nauthorizationRequired=Authorization required\nauthorizeThisAppIn=Authorize this app in {1}:\nauthorize=Authorize\nauthorizing=Authorizing\nautomatic=Automatic\nautosave=Autosave\nautosize=Autosize\nattachments=Attachments\naws=AWS\naws3d=AWS 3D\nazure=Azure\nback=Back\nbackground=Background\nbackgroundColor=Background Color\nbackgroundImage=Background Image\nbasic=Basic\nblankDrawing=Blank Drawing\nblankDiagram=Blank Diagram\nblock=Block\nblockquote=Blockquote\nblog=Blog\nbold=Bold\nbootstrap=Bootstrap\nborder=Border\nborderColor=Border Color\nborderWidth=Border Width\nbottom=Bottom\nbottomAlign=Bottom Align\nbottomLeft=Bottom Left\nbottomRight=Bottom Right\nbpmn=BPMN\nbrowser=Browser\nbulletedList=Bulleted List\nbusiness=Business\nbusy=Operation in progress\ncabinets=Cabinets\ncancel=Cancel\ncenter=Center\ncannotLoad=Load attempts failed. Please try again later.\ncannotLogin=Log in attempts failed. Please try again later.\ncannotOpenFile=Cannot open file\nchange=Change\nchangeOrientation=Change Orientation\nchangeUser=Change user\nchangeStorage=Change storage\nchangesNotSaved=Changes have not been saved\nclassDiagram=Class Diagram\nuserJoined={1} has joined\nuserLeft={1} has left\nchatWindowTitle=Chat\nchooseAnOption=Choose an option\nchromeApp=Chrome App\ncollaborativeEditingNotice=Important Notice for Collaborative Editing\ncompressed=Compressed\ncommitMessage=Commit Message\nconfigLinkWarn=This link configures draw.io. Only click OK if you trust whoever gave you it!\nconfigLinkConfirm=Click OK to configure and restart draw.io.\ncsv=CSV\ndark=Dark\ndiagramXmlDesc=XML File\ndiagramHtmlDesc=HTML File\ndiagramPngDesc=Editable Bitmap Image\ndiagramSvgDesc=Editable Vector Image\ndidYouMeanToExportToPdf=Did you mean to export to PDF?\ndraftFound=A draft for \'{1}\' has been found. Load it into the editor or discard it to continue.\nselectDraft=Select a draft to continue editing:\ndragAndDropNotSupported=Drag and drop not supported for images. Would you like to import instead?\ndropboxCharsNotAllowed=The following characters are not allowed: / : ? * " |\ncheck=Check\nchecksum=Checksum\ncircle=Circle\ncisco=Cisco\nclassic=Classic\nclearDefaultStyle=Clear Default Style\nclearWaypoints=Clear Waypoints\nclipart=Clipart\nclose=Close\nclosingFile=Closing file\ncollaborator=Collaborator\ncollaborators=Collaborators\ncollapse=Collapse\ncollapseExpand=Collapse/Expand\ncollapse-expand=Click to collapse/expand\nShift-click to move neighbors \nAlt-click to protect group size\ncollapsible=Collapsible\ncomic=Comic\ncomment=Comment\ncommentsNotes=Comments/Notes\ncompress=Compress\nconfiguration=Configuration\nconnect=Connect\nconnecting=Connecting\nconnectWithDrive=Connect with Google Drive\nconnection=Connection\nconnectionArrows=Connection Arrows\nconnectionPoints=Connection Points\nconstrainProportions=Constrain Proportions\ncontainsValidationErrors=Contains validation errors\ncopiedToClipboard=Copied to clipboard\ncopy=Copy\ncopyConnect=Copy on connect\ncopyCreated=A copy of the file was created.\ncopyOf=Copy of {1}\ncopyOfDrawing=Copy of Drawing\ncopySize=Copy Size\ncopyStyle=Copy Style\ncreate=Create\ncreateNewDiagram=Create New Diagram\ncreateRevision=Create Revision\ncreateShape=Create Shape\ncrop=Crop\ncurved=Curved\ncustom=Custom\ncurrent=Current\ncurrentPage=Current page\ncut=Cut\ndashed=Dashed\ndecideLater=Decide later\ndefault=Default\ndelete=Delete\ndeleteColumn=Delete Column\ndeleteLibrary401=Insufficient permissions to delete this library\ndeleteLibrary404=Selected library could not be found\ndeleteLibrary500=Error deleting library\ndeleteLibraryConfirm=You are about to permanently delete this library. Are you sure you want to do this?\ndeleteRow=Delete Row\ndescription=Description\ndevice=Device\ndiagram=Diagram\ndiagramContent=Diagram Content\ndiagramLocked=Diagram has been locked to prevent further data loss.\ndiagramLockedBySince=The diagram is locked by {1} since {2} ago\ndiagramName=Diagram Name\ndiagramIsPublic=Diagram is public\ndiagramIsNotPublic=Diagram is not public\ndiamond=Diamond\ndiamondThin=Diamond (thin)\ndidYouKnow=Did you know...\ndirection=Direction\ndiscard=Discard\ndiscardChangesAndReconnect=Discard Changes and Reconnect\ngoogleDriveMissingClickHere=Google Drive missing? Click here!\ndiscardChanges=Discard Changes\ndisconnected=Disconnected\ndistribute=Distribute\ndone=Done\ndoNotShowAgain=Do not show again\ndotted=Dotted\ndoubleClickOrientation=Doubleclick to change orientation\ndoubleClickTooltip=Doubleclick to insert text\ndoubleClickChangeProperty=Doubleclick to change property name\ndownload=Download\ndownloadDesktop=Get Desktop\ndownloadAs=Download as\nclickHereToSave=Click here to save.\ndpi=DPI\ndraftDiscarded=Draft discarded\ndraftSaved=Draft saved\ndragElementsHere=Drag elements here\ndragImagesHere=Drag images or URLs here\ndragUrlsHere=Drag URLs here\ndraw.io=draw.io\ndrawing=Drawing{1}\ndrawingEmpty=Drawing is empty\ndrawingTooLarge=Drawing is too large\ndrawioForWork=Draw.io for GSuite\ndropbox=Dropbox\nduplicate=Duplicate\nduplicateIt=Duplicate {1}\ndivider=Divider\ndx=Dx\ndy=Dy\neast=East\nedit=Edit\neditData=Edit Data\neditDiagram=Edit Diagram\neditGeometry=Edit Geometry\neditImage=Edit Image\neditImageUrl=Edit Image URL\neditLink=Edit Link\neditShape=Edit Shape\neditStyle=Edit Style\neditText=Edit Text\neditTooltip=Edit Tooltip\nglass=Glass\ngoogleImages=Google Images\nimageSearch=Image Search\neip=EIP\nembed=Embed\nembedImages=Embed Images\nmainEmbedNotice=Paste this into the page\nelectrical=Electrical\nellipse=Ellipse\nembedNotice=Paste this once at the end of the page\nenterGroup=Enter Group\nenterName=Enter Name\nenterPropertyName=Enter Property Name\nenterValue=Enter Value\nentityRelation=Entity Relation\nentityRelationshipDiagram=Entity Relationship Diagram\nerror=Error\nerrorDeletingFile=Error deleting file\nerrorLoadingFile=Error loading file\nerrorRenamingFile=Error renaming file\nerrorRenamingFileNotFound=Error renaming file. File was not found.\nerrorRenamingFileForbidden=Error renaming file. Insufficient access rights.\nerrorSavingDraft=Error saving draft\nerrorSavingFile=Error saving file\nerrorSavingFileUnknown=Error authorizing with Google\'s servers. Please refresh the page to re-attempt.\nerrorSavingFileForbidden=Error saving file. Insufficient access rights.\nerrorSavingFileNameConflict=Could not save diagram. Current page already contains file named \'{1}\'.\nerrorSavingFileNotFound=Error saving file. File was not found.\nerrorSavingFileReadOnlyMode=Could not save diagram while read-only mode is active.\nerrorSavingFileSessionTimeout=Your session has ended. Please <a target=\'_blank\' href=\'{1}\'>{2}</a> and return to this tab to try to save again.\nerrorSendingFeedback=Error sending feedback.\nerrorUpdatingPreview=Error updating preview.\nexit=Exit\nexitGroup=Exit Group\nexpand=Expand\nexport=Export\nexporting=Exporting\nexportAs=Export as\nexportOptionsDisabled=Export options disabled\nexportOptionsDisabledDetails=The owner has disabled options to download, print or copy for commenters and viewers on this file.\nexternalChanges=External Changes\nextras=Extras\nfacebook=Facebook\nfailedToSaveTryReconnect=Failed to save, trying to reconnect\nfeatureRequest=Feature Request\nfeedback=Feedback\nfeedbackSent=Feedback successfully sent.\nfloorplans=Floorplans\nfile=File\nfileChangedOverwriteDialog=The file has been modified. Do you want to save the file and overwrite those changes?\nfileChangedSyncDialog=The file has been modified. Do you want to synchronize those changes?\nfileChangedSync=The file has been modified. Click here to synchronize.\noverwrite=Overwrite\nsynchronize=Synchronize\nfilename=Filename\nfileExists=File already exists\nfileMovedToTrash=File was moved to trash\nfileNearlyFullSeeFaq=File nearly full, please see FAQ\nfileNotFound=File not found\nrepositoryNotFound=Repository not found\nfileNotFoundOrDenied=The file was not found. It does not exist or you do not have access.\nfileNotLoaded=File not loaded\nfileNotSaved=File not saved\nfileOpenLocation=How would you like to open these file(s)?\nfiletypeHtml=.html causes file to save as HTML with redirect to cloud URL\nfiletypePng=.png causes file to save as PNG with embedded data\nfiletypeSvg=.svg causes file to save as SVG with embedded data\nfileWillBeSavedInAppFolder={1} will be saved in the app folder.\nfill=Fill\nfillColor=Fill Color\nfilterCards=Filter Cards\nfind=Find\nfit=Fit\nfitContainer=Resize Container\nfitIntoContainer=Fit into Container\nfitPage=Fit Page\nfitPageWidth=Fit Page Width\nfitTo=Fit to\nfitToSheetsAcross=sheet(s) across\nfitToBy=by\nfitToSheetsDown=sheet(s) down\nfitTwoPages=Two Pages\nfitWindow=Fit Window\nflip=Flip\nflipH=Flip Horizontal\nflipV=Flip Vertical\nflowchart=Flowchart\nfolder=Folder\nfont=Font\nfontColor=Font Color\nfontFamily=Font Family\nfontSize=Font Size\nforbidden=You are not authorized to access this file\nformat=Format\nformatPanel=Format Panel\nformatted=Formatted\nformattedText=Formatted Text\nformatPng=PNG\nformatGif=GIF\nformatJpg=JPEG\nformatPdf=PDF\nformatSql=SQL\nformatSvg=SVG\nformatHtmlEmbedded=HTML\nformatSvgEmbedded=SVG (with XML)\nformatVsdx=VSDX\nformatVssx=VSSX\nformatXmlPlain=XML (Plain)\nformatXml=XML\nforum=Discussion/Help Forums\nfreehand=Freehand\nfromTemplate=From Template\nfromTemplateUrl=From Template URL\nfromText=From Text\nfromUrl=From URL\nfromThisPage=From this page\nfullscreen=Fullscreen\ngap=Gap\ngcp=GCP\ngeneral=General\ngithub=GitHub\ngitlab=GitLab\ngliffy=Gliffy\nglobal=Global\ngoogleDocs=Google Docs\ngoogleDrive=Google Drive\ngoogleGadget=Google Gadget\ngooglePlus=Google+\ngoogleSharingNotAvailable=Sharing is only available via Google Drive. Please click Open below and share from the more actions menu:\ngoogleSlides=Google Slides\ngoogleSites=Google Sites\ngoogleSheets=Google Sheets\ngradient=Gradient\ngradientColor=Color\ngrid=Grid\ngridColor=Grid Color\ngridSize=Grid Size\ngroup=Group\nguides=Guides\nhateApp=I hate draw.io\nheading=Heading\nheight=Height\nhelp=Help\nhelpTranslate=Help us translate this application\nhide=Hide\nhideIt=Hide {1}\nhidden=Hidden\nhome=Home\nhorizontal=Horizontal\nhorizontalFlow=Horizontal Flow\nhorizontalTree=Horizontal Tree\nhowTranslate=How good is the translation in your language?\nhtml=HTML\nhtmlText=HTML Text\nid=ID\niframe=IFrame\nignore=Ignore\nimage=Image\nimageUrl=Image URL\nimages=Images\nimagePreviewError=This image couldn\'t be loaded for preview. Please check the URL.\nimageTooBig=Image too big\nimgur=Imgur\nimport=Import\nimportFrom=Import from\nincludeCopyOfMyDiagram=Include a copy of my diagram\nincreaseIndent=Increase Indent\ndecreaseIndent=Decrease Indent\ninsert=Insert\ninsertColumnBefore=Insert Column Left\ninsertColumnAfter=Insert Column Right\ninsertEllipse=Insert Ellipse\ninsertImage=Insert Image\ninsertHorizontalRule=Insert Horizontal Rule\ninsertLink=Insert Link\ninsertPage=Insert Page\ninsertRectangle=Insert Rectangle\ninsertRhombus=Insert Rhombus\ninsertRowBefore=Insert Row Above\ninsertRowAfter=Insert Row After\ninsertText=Insert Text\ninserting=Inserting\ninstallApp=Install App\ninvalidFilename=Diagram names must not contain the following characters: / | : ; { } < > & + ? = "\ninvalidLicenseSeeThisPage=Your license is invalid, please see this <a target="_blank" href="https://support.draw.io/display/DFCS/Licensing+your+draw.io+plugin">page</a>.\ninvalidInput=Invalid input\ninvalidName=Invalid name\ninvalidOrMissingFile=Invalid or missing file\ninvalidPublicUrl=Invalid public URL\nisometric=Isometric\nios=iOS\nitalic=Italic\nkennedy=Kennedy\nkeyboardShortcuts=Keyboard Shortcuts\nlayers=Layers\nlandscape=Landscape\nlanguage=Language\nleanMapping=Lean Mapping\nlastChange=Last change {1} ago\nlessThanAMinute=less than a minute\nlicensingError=Licensing Error\nlicenseHasExpired=The license for {1} has expired on {2}. Click here.\nlicenseWillExpire=The license for {1} will expire on {2}. Click here.\nlineJumps=Line jumps\nlinkAccountRequired=If the diagram is not public a Google account is required to view the link.\nlinkText=Link Text\nlist=List\nminute=minute\nminutes=minutes\nhours=hours\ndays=days\nmonths=months\nyears=years\nrestartForChangeRequired=Changes will take effect after a restart of the application.\nlaneColor=Lanecolor\nlastModified=Last modified\nlayout=Layout\nleft=Left\nleftAlign=Left Align\nleftToRight=Left to right\nlibraryTooltip=Drag and drop shapes here or click + to insert. Double click to edit.\nlightbox=Lightbox\nline=Line\nlineend=Line end\nlineheight=Line Height\nlinestart=Line start\nlinewidth=Linewidth\nlink=Link\nlinks=Links\nloading=Loading\nlockUnlock=Lock/Unlock\nloggedOut=Logged Out\nlogIn=log in\nloveIt=I love {1}\nlucidchart=Lucidchart\nmaps=Maps\nmathematicalTypesetting=Mathematical Typesetting\nmakeCopy=Make a Copy\nmanual=Manual\nmermaid=Mermaid\nmicrosoftOffice=Microsoft Office\nmicrosoftExcel=Microsoft Excel\nmicrosoftPowerPoint=Microsoft PowerPoint\nmicrosoftWord=Microsoft Word\nmiddle=Middle\nminimal=Minimal\nmisc=Misc\nmockups=Mockups\nmodificationDate=Modification date\nmodifiedBy=Modified by\nmore=More\nmoreResults=More Results\nmoreShapes=More Shapes\nmove=Move\nmoveToFolder=Move to Folder\nmoving=Moving\nmoveSelectionTo=Move selection to {1}\nname=Name\nnavigation=Navigation\nnetwork=Network\nnetworking=Networking\nnew=New\nnewLibrary=New Library\nnextPage=Next Page\nno=No\nnoPickFolder=No, pick folder\nnoAttachments=No attachments found\nnoColor=No Color\nnoFiles=No Files\nnoFileSelected=No file selected\nnoLibraries=No libraries found\nnoMoreResults=No more results\nnone=None\nnoOtherViewers=No other viewers\nnoPlugins=No plugins\nnoPreview=No preview\nnoResponse=No response from server\nnoResultsFor=No results for \'{1}\'\nnoRevisions=No revisions\nnoSearchResults=No search results found\nnoPageContentOrNotSaved=No anchors found on this page or it hasn\'t been saved yet\nnormal=Normal\nnorth=North\nnotADiagramFile=Not a diagram file\nnotALibraryFile=Not a library file\nnotAvailable=Not available\nnotAUtf8File=Not a UTF-8 file\nnotConnected=Not connected\nnote=Note\nnotSatisfiedWithImport=Not satisfied with the import?\nnotUsingService=Not using {1}?\nnumberedList=Numbered list\noffline=Offline\nok=OK\noneDrive=OneDrive\nonline=Online\nopacity=Opacity\nopen=Open\nopenArrow=Open Arrow\nopenExistingDiagram=Open Existing Diagram\nopenFile=Open File\nopenFrom=Open from\nopenLibrary=Open Library\nopenLibraryFrom=Open Library from\nopenLink=Open Link\nopenInNewWindow=Open in New Window\nopenInThisWindow=Open in This Window\nopenIt=Open {1}\nopenRecent=Open Recent\nopenSupported=Supported formats are files saved from this software (.xml), .vsdx and .gliffy\noptions=Options\norganic=Organic\norgChart=Org Chart\northogonal=Orthogonal\notherViewer=other viewer\notherViewers=other viewers\noutline=Outline\noval=Oval\npage=Page\npageContent=Page Content\npageNotFound=Page not found\npageWithNumber=Page-{1}\npages=Pages\npageView=Page View\npageSetup=Page Setup\npageScale=Page Scale\npan=Pan\npanTooltip=Space+Drag to pan\npaperSize=Paper Size\npattern=Pattern\npaste=Paste\npasteHere=Paste here\npasteSize=Paste Size\npasteStyle=Paste Style\nperimeter=Perimeter\npermissionAnyone=Anyone can edit\npermissionAuthor=Owner and admins can edit\npickFolder=Pick a folder\npickLibraryDialogTitle=Select Library\npublicDiagramUrl=Public URL of the diagram\nplaceholders=Placeholders\nplantUml=PlantUML\nplugins=Plugins\npluginUrl=Plugin URL\npluginWarning=The page has requested to load the following plugin(s):\n \n {1}\n \n Would you like to load these plugin(s) now?\n \n NOTE : Only allow plugins to run if you fully understand the security implications of doing so.\n\nplusTooltip=Click to connect and clone (ctrl+click to clone, shift+click to connect). Drag to connect (ctrl+drag to clone).\nportrait=Portrait\nposition=Position\nposterPrint=Poster Print\npreferences=Preferences\npreview=Preview\npreviousPage=Previous Page\nprint=Print\nprintAllPages=Print All Pages\nprocEng=Proc. Eng.\nproject=Project\npriority=Priority\nproperties=Properties\npublish=Publish\nquickStart=Quick Start Video\nrack=Rack\nradialTree=Radial Tree\nreadOnly=Read-only\nreconnecting=Reconnecting\nrecentlyUpdated=Recently Updated\nrecentlyViewed=Recently Viewed\nrectangle=Rectangle\nredirectToNewApp=This file was created or modified in a newer version of this app. You will be redirected now.\nrealtimeTimeout=It looks like you\'ve made a few changes while offline. We\'re sorry, these changes cannot be saved.\nredo=Redo\nrefresh=Refresh\nregularExpression=Regular Expression\nrelative=Relative\nrelativeUrlNotAllowed=Relative URL not allowed\nrememberMe=Remember me\nrememberThisSetting=Remember this setting\nremoveFormat=Clear Formatting\nremoveFromGroup=Remove from Group\nremoveIt=Remove {1}\nremoveWaypoint=Remove Waypoint\nrename=Rename\nrenamed=Renamed\nrenameIt=Rename {1}\nrenaming=Renaming\nreplace=Replace\nreplaceIt={1} already exists. Do you want to replace it?\nreplaceExistingDrawing=Replace existing drawing\nrequired=required\nreset=Reset\nresetView=Reset View\nresize=Resize\nresizeLargeImages=Do you want to resize large images to make the application run faster?\nretina=Retina\nresponsive=Responsive\nrestore=Restore\nrestoring=Restoring\nretryingIn=Retrying in {1} second(s)\nretryingLoad=Load failed. Retrying...\nretryingLogin=Login time out. Retrying...\nreverse=Reverse\nrevision=Revision\nrevisionHistory=Revision History\nrhombus=Rhombus\nright=Right\nrightAlign=Right Align\nrightToLeft=Right to left\nrotate=Rotate\nrotateTooltip=Click and drag to rotate, click to turn shape only by 90 degrees\nrotation=Rotation\nrounded=Rounded\nsave=Save\nsaveAndExit=Save & Exit\nsaveAs=Save as\nsaveAsXmlFile=Save as XML file?\nsaved=Saved\nsaveDiagramFirst=Please save the diagram first\nsaveDiagramsTo=Save diagrams to\nsaveLibrary403=Insufficient permissions to edit this library\nsaveLibrary500=There was an error while saving the library\nsaveLibraryReadOnly=Could not save library while read-only mode is active\nsaving=Saving\nscratchpad=Scratchpad\nscrollbars=Scrollbars\nsearch=Search\nsearchShapes=Search Shapes\nselectAll=Select All\nselectionOnly=Selection Only\nselectCard=Select Card\nselectEdges=Select Edges\nselectFile=Select File\nselectFolder=Select Folder\nselectFont=Select Font\nselectNone=Select None\nselectTemplate=Select Template\nselectVertices=Select Vertices\nsendMessage=Send\nsendYourFeedback=Send your feedback\nserviceUnavailableOrBlocked=Service unavailable or blocked\nsessionExpired=Your session has expired. Please refresh the browser window.\nsessionTimeoutOnSave=Your session has timed out and you have been disconnected from the Google Drive. Press OK to login and save. \nsetAsDefaultStyle=Set as Default Style\nshadow=Shadow\nshape=Shape\nshapes=Shapes\nshare=Share\nshareLink=Link for shared editing\nsharp=Sharp\nshow=Show\nshowStartScreen=Show Start Screen\nsidebarTooltip=Click to expand. Drag and drop shapes into the diagram. Shift+click to change selection. Alt+click to insert and connect.\nsigns=Signs\nsignOut=Sign out\nsimple=Simple\nsimpleArrow=Simple Arrow\nsimpleViewer=Simple Viewer\nsize=Size\nsolid=Solid\nsourceSpacing=Source Spacing\nsouth=South\nsoftware=Software\nspace=Space\nspacing=Spacing\nspecialLink=Special Link\nstandard=Standard\nstartDrawing=Start drawing\nstopDrawing=Stop drawing\nstarting=Starting\nstraight=Straight\nstrikethrough=Strikethrough\nstrokeColor=Line Color\nstyle=Style\nsubscript=Subscript\nsummary=Summary\nsuperscript=Superscript\nsupport=Support\nswimlaneDiagram=Swimlane Diagram\nsysml=SysML\ntags=Tags\ntable=Table\ntables=Tables\ntakeOver=Take Over\ntargetSpacing=Target Spacing\ntemplate=Template\ntemplates=Templates\ntext=Text\ntextAlignment=Text Alignment\ntextOpacity=Text Opacity\ntheme=Theme\ntimeout=Timeout\ntitle=Title\nto=to\ntoBack=To Back\ntoFront=To Front\ntoolbar=Toolbar\ntooltips=Tooltips\ntop=Top\ntopAlign=Top Align\ntopLeft=Top Left\ntopRight=Top Right\ntransparent=Transparent\ntransparentBackground=Transparent Background\ntrello=Trello\ntryAgain=Try again\ntryOpeningViaThisPage=Try opening via this page\nturn=Rotate shape only by 90°\ntype=Type\ntwitter=Twitter\numl=UML\nunderline=Underline\nundo=Undo\nungroup=Ungroup\nunsavedChanges=Unsaved changes\nunsavedChangesClickHereToSave=Unsaved changes. Click here to save.\nuntitled=Untitled\nuntitledDiagram=Untitled Diagram\nuntitledLayer=Untitled Layer\nuntitledLibrary=Untitled Library\nunknownError=Unknown error\nupdateFile=Update {1}\nupdatingDocument=Updating Document. Please wait...\nupdatingPreview=Updating Preview. Please wait...\nupdatingSelection=Updating Selection. Please wait...\nupload=Upload\nurl=URL\nuseOffline=Use Offline\nuseRootFolder=Use root folder?\nuserManual=User Manual\nvertical=Vertical\nverticalFlow=Vertical Flow\nverticalTree=Vertical Tree\nview=View\nviewerSettings=Viewer Settings\nviewUrl=Link to view: {1}\nvoiceAssistant=Voice Assistant (beta)\nwarning=Warning\nwaypoints=Waypoints\nwest=West\nwidth=Width\nwiki=Wiki\nwordWrap=Word Wrap\nwritingDirection=Writing Direction\nyes=Yes\nyourEmailAddress=Your email address\nzoom=Zoom\nzoomIn=Zoom In\nzoomOut=Zoom Out\nbasic=Basic\nbusinessprocess=Business Processes\ncharts=Charts\nengineering=Engineering\nflowcharts=Flowcharts\ngmdl=Material Design\nmindmaps=Mindmaps\nmockups=Mockups\nnetworkdiagrams=Network Diagrams\nnothingIsSelected=Nothing is selected\nother=Other\nsoftwaredesign=Software Design\nvenndiagrams=Venn Diagrams\nwebEmailOrOther=Web, email or any other internet address\nwebLink=Web Link\nwireframes=Wireframes\nproperty=Property\nvalue=Value\nshowMore=Show More\nshowLess=Show Less\nmyDiagrams=My Diagrams\nallDiagrams=All Diagrams\nrecentlyUsed=Recently used\nlistView=List view\ngridView=Grid view\nresultsFor=Results for \'{1}\'\noneDriveCharsNotAllowed=The following characters are not allowed: ~ " # % * : < > ? / { | }\noneDriveInvalidDeviceName=The specified device name is invalid\nofficeNotLoggedOD=You are not logged in to OneDrive. Please open draw.io task pane and login first.\nofficeSelectSingleDiag=Please select a single draw.io diagram only without other contents.\nofficeSelectDiag=Please select a draw.io diagram.\nofficeCannotFindDiagram=Cannot find a draw.io diagram in the selection\nnoDiagrams=No diagrams found\nauthFailed=Authentication failed\nofficeFailedAuthMsg=Unable to successfully authenticate user or authorize application.\nconvertingDiagramFailed=Converting diagram failed\nofficeCopyImgErrMsg=Due to some limitations in the host application, the image could not be inserted. Please manually copy the image then paste it to the document.\ninsertingImageFailed=Inserting image failed\nofficeCopyImgInst=Instructions: Right-click the image below. Select "Copy image" from the context menu. Then, in the document, right-click and select "Paste" from the context menu.\nfolderEmpty=Folder is empty\nrecent=Recent\nsharedWithMe=Shared With Me\nsharepointSites=Sharepoint Sites\nerrorFetchingFolder=Error fetching folder items\nerrorAuthOD=Error authenticating to OneDrive\nofficeMainHeader=Adds draw.io diagrams to your document.\nofficeStepsHeader=This add-in performs the following steps:\nofficeStep1=Connects to Microsoft OneDrive, Google Drive or your device.\nofficeStep2=Select a draw.io diagram.\nofficeStep3=Insert the diagram into the document.\nofficeAuthPopupInfo=Please complete the authentication in the pop-up window.\nofficeSelDiag=Select draw.io Diagram:\nfiles=Files\nshared=Shared\nsharepoint=Sharepoint\nofficeManualUpdateInst=Instructions: Copy draw.io diagram from the document. Then, in the box below, right-click and select "Paste" from the context menu.\nofficeClickToEdit=Click icon to start editing:\npasteDiagram=Paste draw.io diagram here\nconnectOD=Connect to OneDrive\nselectChildren=Select Children\nselectSiblings=Select Siblings\nselectParent=Select Parent\nselectDescendants=Select Descendants\nlastSaved=Last saved {1} ago\nresolve=Resolve\nreopen=Re-open\nshowResolved=Show Resolved\nreply=Reply\nobjectNotFound=Object not found\nreOpened=Re-opened\nmarkedAsResolved=Marked as resolved\nnoCommentsFound=No comments found\ncomments=Comments\ntimeAgo={1} ago\nconfluenceCloud=Confluence Cloud\nlibraries=Libraries\nconfAnchor=Confluence Page Anchor\nconfTimeout=The connection has timed out\nconfSrvTakeTooLong=The server at {1} is taking too long to respond.\nconfCannotInsertNew=Cannot insert draw.io diagram to a new Confluence page\nconfSaveTry=Please save the page and try again.\nconfCannotGetID=Unable to determine page ID\nconfContactAdmin=Please contact your Confluence administrator.\nreadErr=Read Error\neditingErr=Editing Error\nconfExtEditNotPossible=This diagram cannot be edited externally. Please try editing it while editing the page\nconfEditedExt=Diagram/Page edited externally\ndiagNotFound=Diagram Not Found\nconfEditedExtRefresh=Diagram/Page is edited externally. Please refresh the page.\nconfCannotEditDraftDelOrExt=Cannot edit diagrams in a draft page, diagram is deleted from the page, or diagram is edited externally. Please check the page.\nretBack=Return back\nconfDiagNotPublished=The diagram does not belong to a published page\ncreatedByDraw=Created by draw.io\nfilenameShort=Filename too short\ninvalidChars=Invalid characters\nalreadyExst={1} already exists\ndraftReadErr=Draft Read Error\ndiagCantLoad=Diagram cannot be loaded\ndraftWriteErr=Draft Write Error\ndraftCantCreate=Draft could not be created\nconfDuplName=Duplicate diagram name detected. Please pick another name.\nconfSessionExpired=Looks like your session expired. Log in again to keep working.\nlogin=Login\ndrawPrev=draw.io preview\ndrawDiag=draw.io diagram\ninvalidCallFnNotFound=Invalid Call: {1} not found\ninvalidCallErrOccured=Invalid Call: An error occurred, {1}\nanonymous=Anonymous\nconfGotoPage=Go to containing page\nshowComments=Show Comments\nconfError=Error: {1}\ngliffyImport=Gliffy Import\ngliffyImportInst1=Click the "Start Import" button to import all Gliffy diagrams to draw.io.\ngliffyImportInst2=Please note that the import procedure will take some time and the browser window must remain open until the import is completed.\nstartImport=Start Import\ndrawConfig=draw.io Configuration\ncustomLib=Custom Libraries\ncustomTemp=Custom Templates\npageIdsExp=Page IDs Export\ndrawReindex=draw.io re-indexing (beta)\nworking=Working\ndrawConfigNotFoundInst=draw.io Configuration Space (DRAWIOCONFIG) does not exist. This space is needed to store draw.io configuration files and custom libraries/templates.\ncreateConfSp=Create Config Space\nunexpErrRefresh=Unexpected error, please refresh the page and try again.\nconfigJSONInst=Write draw.io JSON configuration in the editor below then click save. If you need help, please refer to\nthisPage=this page\ncurCustLib=Current Custom Libraries\nlibName=Library Name\naction=Action\ndrawConfID=draw.io Config ID\naddLibInst=Click the "Add Library" button to upload a new library.\naddLib=Add Library\ncustomTempInst1=Custom templates are draw.io diagrams saved in children pages of\ncustomTempInst2=For more details, please refer to\ntempsPage=Templates page\npageIdsExpInst1=Select export target, then click the "Start Export" button to export all pages IDs.\npageIdsExpInst2=Please note that the export procedure will take some time and the browser window must remain open until the export is completed.\nstartExp=Start Export\nrefreshDrawIndex=Refresh draw.io Diagrams Index\nreindexInst1=Click the "Start Indexing" button to refresh draw.io diagrams index.\nreindexInst2=Please note that the indexing procedure will take some time and the browser window must remain open until the indexing is completed.\nstartIndexing=Start Indexing\nconfAPageFoundFetch=Page "{1}" found. Fetching\nconfAAllDiagDone=All {1} diagrams processed. Process finished.\nconfAStartedProcessing=Started processing page "{1}"\nconfAAllDiagInPageDone=All {1} diagrams in page "{2}" processed successfully.\nconfAPartialDiagDone={1} out of {2} {3} diagrams in page "{4}" processed successfully.\nconfAUpdatePageFailed=Updating page "{1}" failed.\nconfANoDiagFoundInPage=No {1} diagrams found in page "{2}".\nconfAFetchPageFailed=Fetching the page failed.\nconfANoDiagFound=No {1} diagrams found. Process finished.\nconfASearchFailed=Searching for {1} diagrams failed. Please try again later.\nconfAGliffyDiagFound={2} diagram "{1}" found. Importing\nconfAGliffyDiagImported={2} diagram "{1}" imported successfully.\nconfASavingImpGliffyFailed=Saving imported {2} diagram "{1}" failed.\nconfAImportedFromByDraw=Imported from "{1}" by draw.io\nconfAImportGliffyFailed=Importing {2} diagram "{1}" failed.\nconfAFetchGliffyFailed=Fetching {2} diagram "{1}" failed.\nconfACheckBrokenDiagLnk=Checking for broken diagrams links.\nconfADelDiagLinkOf=Deleting diagram link of "{1}"\nconfADupLnk=(duplicate link)\nconfADelDiagLnkFailed=Deleting diagram link of "{1}" failed.\nconfAUnexpErrProcessPage=Unexpected error during processing the page with id: {1}\nconfADiagFoundIndex=Diagram "{1}" found. Indexing\nconfADiagIndexSucc=Diagram "{1}" indexed successfully.\nconfAIndexDiagFailed=Indexing diagram "{1}" failed.\nconfASkipDiagOtherPage=Skipped "{1}" as it belongs to another page!\nconfADiagUptoDate=Diagram "{1}" is up to date.\nconfACheckPagesWDraw=Checking pages having draw.io diagrams.\nconfAErrOccured=An error occurred!\nsavedSucc=Saved successfully\nconfASaveFailedErr=Saving Failed (Unexpected Error)\ncharacter=Character\nconfAConfPageDesc=This page contains draw.io configuration file (configuration.json) as attachment\nconfALibPageDesc=This page contains draw.io custom libraries as attachments\nconfATempPageDesc=This page contains draw.io custom templates as attachments\nworking=Working\nconfAConfSpaceDesc=This space is used to store draw.io configuration files and custom libraries/templates\nconfANoCustLib=No Custom Libraries\ndelFailed=Delete failed!\nshowID=Show ID\nconfAIncorrectLibFileType=Incorrect file type. Libraries should be XML files.\nuploading=Uploading\nconfALibExist=This library already exists\nconfAUploadSucc=Uploaded successfully\nconfAUploadFailErr=Upload Failed (Unexpected Error)\nhiResPreview=High Res Preview\nofficeNotLoggedGD=You are not logged in to Google Drive. Please open draw.io task pane and login first.\nofficePopupInfo=Please complete the process in the pop-up window.\npickODFile=Pick OneDrive File\npickGDriveFile=Pick Google Drive File\npickDeviceFile=Pick Device File\nvsdNoConfig="vsdurl" is not configured\nruler=Ruler\nunits=Units\npoints=Points\ninches=Inches\nmillimeters=Millimeters\nconfEditDraftDelOrExt=This diagram is in a draft page, is deleted from the page, or is edited externally. It will be saved as a new attachment version and may not be reflected in the page.\nconfDiagEditedExt=Diagram is edited in another session. It will be saved as a new attachment version but the page will show other session\'s modifications.\nmacroNotFound=Macro Not Found\nconfAInvalidPageIdsFormat=Incorrect Page IDs file format\nconfACollectingCurPages=Collecting current pages\nconfABuildingPagesMap=Building pages mapping\nconfAProcessDrawDiag=Started processing imported draw.io diagrams\nconfAProcessDrawDiagDone=Finished processing imported draw.io diagrams\nconfAProcessImpPages=Started processing imported pages\nconfAErrPrcsDiagInPage=Error processing draw.io diagrams in page "{1}"\nconfAPrcsDiagInPage=Processing draw.io diagrams in page "{1}"\nconfAImpDiagram=Importing diagram "{1}"\nconfAImpDiagramFailed=Importing diagram "{1}" failed. Cannot find its new page ID. Maybe it points to a page that is not imported. \nconfAImpDiagramError=Error importing diagram "{1}". Cannot fetch or save the diagram. Cannot fix this diagram links.\nconfAUpdateDgrmCCFailed=Updating link to diagram "{1}" failed.\nconfImpDiagramSuccess=Updating diagram "{1}" done successfully.\nconfANoLnksInDrgm=No links to update in: {1}\nconfAUpdateLnkToPg=Updated link to page: "{1}" in diagram: "{2}"\nconfAUpdateLBLnkToPg=Updated lightbox link to page: "{1}" in diagram: "{2}"\nconfAUpdateLnkBase=Updated base URL from: "{1}" to: "{2}" in diagram: "{3}"\nconfAPageIdsImpDone=Page IDs Import finished.\nconfAPrcsMacrosInPage=Processing draw.io macros in page "{1}"\nconfAErrFetchPage=Error fetching page "{1}"\nconfAFixingMacro=Fixing macro of diagram "{1}"\nconfAErrReadingExpFile=Error reading export file\nconfAPrcsDiagInPageDone=Processing draw.io diagrams in page "{1}" finished\nconfAFixingMacroSkipped=Fixing macro of diagram "{1}" failed. Cannot find its new page ID. Maybe it points to a page that is not imported. \npageIdsExpTrg=Export target\nconfALucidDiagImgImported={2} diagram "{1}" image extracted successfully.\nconfASavingLucidDiagImgFailed=Extracting {2} diagram "{1}" image failed.\nconfGetInfoFailed=Fetching file info from {1} failed.\nconfCheckCacheFailed=Cannot get cached file info.\nconfReadFileErr=Cannot read "{1}" file from {2}.\nconfSaveCacheFailed=Unexpected error. Cannot save cached file\norgChartType=Org Chart Type\nlinear=Linear\nhanger2=Hanger 2\nhanger4=Hanger 4\nfishbone1=Fishbone 1\nfishbone2=Fishbone 2\n1ColumnLeft=Single Column Left\n1ColumnRight=Single Column Right\nsmart=Smart\nparentChildSpacing=Parent Child Spacing\nsiblingSpacing=Sibling Spacing\nconfNoPermErr=Sorry, you don\'t have enough permissions to view this embedded diagram from page {1}\ncopyAsImage=Copy as Image\nlucidImport=Lucidchart Import\nlucidImportInst1=Click the "Start Import" button to import all Lucidchart diagrams.\ninstallFirst=Please install {1} first.\ndrawioChromeExt=draw.io Chrome Extension\nloginFirstThen=Please login to {1} first, then {2}\nerrFetchDocList=Error: Couldn\'t fetch documents list.\n');Graph.prototype.defaultThemes["default-style2"]=mxUtils.parseXml('<mxStylesheet><add as="defaultVertex"><add as="shape" value="label"/><add as="perimeter" value="rectanglePerimeter"/><add as="fontSize" value="12"/><add as="fontFamily" value="Helvetica"/><add as="align" value="center"/><add as="verticalAlign" value="middle"/><add as="fillColor" value="#ffffff"/><add as="strokeColor" value="#000000"/><add as="fontColor" value="#000000"/></add><add as="defaultEdge"><add as="shape" value="connector"/><add as="labelBackgroundColor" value="#ffffff"/><add as="endArrow" value="classic"/><add as="fontSize" value="11"/><add as="fontFamily" value="Helvetica"/><add as="align" value="center"/><add as="verticalAlign" value="middle"/><add as="rounded" value="1"/><add as="strokeColor" value="#000000"/><add as="fontColor" value="#000000"/></add><add as="text"><add as="fillColor" value="none"/><add as="gradientColor" value="none"/><add as="strokeColor" value="none"/><add as="align" value="left"/><add as="verticalAlign" value="top"/></add><add as="edgeLabel" extend="text"><add as="labelBackgroundColor" value="#ffffff"/><add as="fontSize" value="11"/></add><add as="label"><add as="fontStyle" value="1"/><add as="align" value="left"/><add as="verticalAlign" value="middle"/><add as="spacing" value="2"/><add as="spacingLeft" value="52"/><add as="imageWidth" value="42"/><add as="imageHeight" value="42"/><add as="rounded" value="1"/></add><add as="icon" extend="label"><add as="align" value="center"/><add as="imageAlign" value="center"/><add as="verticalLabelPosition" value="bottom"/><add as="verticalAlign" value="top"/><add as="spacingTop" value="4"/><add as="labelBackgroundColor" value="#ffffff"/><add as="spacing" value="0"/><add as="spacingLeft" value="0"/><add as="spacingTop" value="6"/><add as="fontStyle" value="0"/><add as="imageWidth" value="48"/><add as="imageHeight" value="48"/></add><add as="swimlane"><add as="shape" value="swimlane"/><add as="fontSize" value="12"/><add as="fontStyle" value="1"/><add as="startSize" value="23"/></add><add as="group"><add as="verticalAlign" value="top"/><add as="fillColor" value="none"/><add as="strokeColor" value="none"/><add as="gradientColor" value="none"/><add as="pointerEvents" value="0"/></add><add as="ellipse"><add as="shape" value="ellipse"/><add as="perimeter" value="ellipsePerimeter"/></add><add as="rhombus"><add as="shape" value="rhombus"/><add as="perimeter" value="rhombusPerimeter"/></add><add as="triangle"><add as="shape" value="triangle"/><add as="perimeter" value="trianglePerimeter"/></add><add as="line"><add as="shape" value="line"/><add as="strokeWidth" value="4"/><add as="labelBackgroundColor" value="#ffffff"/><add as="verticalAlign" value="top"/><add as="spacingTop" value="8"/></add><add as="image"><add as="shape" value="image"/><add as="labelBackgroundColor" value="white"/><add as="verticalAlign" value="top"/><add as="verticalLabelPosition" value="bottom"/></add><add as="roundImage" extend="image"><add as="perimeter" value="ellipsePerimeter"/></add><add as="rhombusImage" extend="image"><add as="perimeter" value="rhombusPerimeter"/></add><add as="arrow"><add as="shape" value="arrow"/><add as="edgeStyle" value="none"/><add as="fillColor" value="#ffffff"/></add><add as="fancy"><add as="shadow" value="1"/><add as="glass" value="1"/></add><add as="gray" extend="fancy"><add as="gradientColor" value="#B3B3B3"/><add as="fillColor" value="#F5F5F5"/><add as="strokeColor" value="#666666"/></add><add as="blue" extend="fancy"><add as="gradientColor" value="#7EA6E0"/><add as="fillColor" value="#DAE8FC"/><add as="strokeColor" value="#6C8EBF"/></add><add as="green" extend="fancy"><add as="gradientColor" value="#97D077"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#82B366"/></add><add as="turquoise" extend="fancy"><add as="gradientColor" value="#67AB9F"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#6A9153"/></add><add as="yellow" extend="fancy"><add as="gradientColor" value="#FFD966"/><add as="fillColor" value="#FFF2CC"/><add as="strokeColor" value="#D6B656"/></add><add as="orange" extend="fancy"><add as="gradientColor" value="#FFA500"/><add as="fillColor" value="#FFCD28"/><add as="strokeColor" value="#D79B00"/></add><add as="red" extend="fancy"><add as="gradientColor" value="#EA6B66"/><add as="fillColor" value="#F8CECC"/><add as="strokeColor" value="#B85450"/></add><add as="pink" extend="fancy"><add as="gradientColor" value="#B5739D"/><add as="fillColor" value="#E6D0DE"/><add as="strokeColor" value="#996185"/></add><add as="purple" extend="fancy"><add as="gradientColor" value="#8C6C9C"/><add as="fillColor" value="#E1D5E7"/><add as="strokeColor" value="#9673A6"/></add><add as="plain-gray"><add as="gradientColor" value="#B3B3B3"/><add as="fillColor" value="#F5F5F5"/><add as="strokeColor" value="#666666"/></add><add as="plain-blue"><add as="gradientColor" value="#7EA6E0"/><add as="fillColor" value="#DAE8FC"/><add as="strokeColor" value="#6C8EBF"/></add><add as="plain-green"><add as="gradientColor" value="#97D077"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#82B366"/></add><add as="plain-turquoise"><add as="gradientColor" value="#67AB9F"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#6A9153"/></add><add as="plain-yellow"><add as="gradientColor" value="#FFD966"/><add as="fillColor" value="#FFF2CC"/><add as="strokeColor" value="#D6B656"/></add><add as="plain-orange"><add as="gradientColor" value="#FFA500"/><add as="fillColor" value="#FFCD28"/><add as="strokeColor" value="#D79B00"/></add><add as="plain-red"><add as="gradientColor" value="#EA6B66"/><add as="fillColor" value="#F8CECC"/><add as="strokeColor" value="#B85450"/></add><add as="plain-pink"><add as="gradientColor" value="#B5739D"/><add as="fillColor" value="#E6D0DE"/><add as="strokeColor" value="#996185"/></add><add as="plain-purple"><add as="gradientColor" value="#8C6C9C"/><add as="fillColor" value="#E1D5E7"/><add as="strokeColor" value="#9673A6"/></add></mxStylesheet>').documentElement;
+null],60)}a=k.menus.get("language");null!=a&&!mxClient.IS_CHROMEAPP&&!EditorUi.isElectronApp&&600<=e?(null==O&&(b=q.addMenu("",a.funct),b.setAttribute("title",mxResources.get("language")),b.className="geToolbarButton",b.style.backgroundImage="url("+Editor.globeImage+")",b.style.backgroundPosition="center center",b.style.backgroundRepeat="no-repeat",b.style.backgroundSize="24px 24px",b.style.position="absolute",b.style.height="24px",b.style.width="24px",b.style.zIndex="1",b.style.right="8px",b.style.cursor=
+"pointer",b.style.top="1"==urlParams.embed?"12px":"11px",n.appendChild(b),O=b),k.buttonContainer.style.paddingRight="34px"):(k.buttonContainer.style.paddingRight="4px",null!=O&&(O.parentNode.removeChild(O),O=null))}t.apply(this,arguments);var l=document.createElement("div");l.style.cssText="position:absolute;left:0px;right:0px;top:0px;overflow-y:auto;overflow-x:hidden;";l.style.bottom="1"!=urlParams.embed||"1"==urlParams.libraries?"63px":"32px";this.sidebar=this.createSidebar(l);(1E3<=e||null!=urlParams.clibs||
+null!=urlParams.libs)&&b(this,!0);1E3<=e&&a(this,!0);var k=this,m=k.editor.graph;k.toolbar=this.createToolbar(k.createDiv("geToolbar"));k.defaultLibraryName=mxResources.get("untitledLibrary");var n=document.createElement("div");n.style.cssText="position:absolute;left:0px;right:0px;top:0px;height:30px;padding:8px;border-bottom:1px solid lightgray;background-color:#ffffff;text-align:left;white-space:nowrap;";var p=null,q=new Menubar(k,n);k.statusContainer=k.createStatusContainer();k.statusContainer.style.position=
+"relative";k.statusContainer.style.maxWidth="";k.statusContainer.style.marginTop="7px";k.statusContainer.style.marginLeft="6px";k.statusContainer.style.color="gray";k.statusContainer.style.cursor="default";k.editor.addListener("statusChanged",mxUtils.bind(this,function(){k.setStatusText(k.editor.getStatus())}));var v=k.descriptorChanged;k.descriptorChanged=function(){v.apply(this,arguments);var a=k.getCurrentFile();if(null!=a&&null!=a.getTitle()){var b=a.getMode();"google"==b?b="googleDrive":"github"==
+b?b="gitHub":"gitlab"==b?b="gitLab":"onedrive"==b&&(b="oneDrive");b=mxResources.get(b);n.setAttribute("title",a.getTitle()+(null!=b?" ("+b+")":""))}else n.removeAttribute("title")};k.setStatusText(k.editor.getStatus());n.appendChild(k.statusContainer);k.buttonContainer=document.createElement("div");k.buttonContainer.style.cssText="position:absolute;right:0px;padding-right:34px;top:10px;white-space:nowrap;padding-top:2px;background-color:inherit;";n.appendChild(k.buttonContainer);k.menubarContainer=
+k.buttonContainer;k.tabContainer=document.createElement("div");k.tabContainer.style.cssText="position:absolute;left:0px;right:0px;bottom:0px;height:30px;white-space:nowrap;border-bottom:1px solid lightgray;background-color:#ffffff;border-top:1px solid lightgray;margin-bottom:-2px;visibility:hidden;";var l=k.diagramContainer.parentNode,y=document.createElement("div");y.style.cssText="position:absolute;top:0px;left:0px;right:0px;bottom:0px;overflow:hidden;";k.diagramContainer.style.top="47px";var K=
+k.menus.get("viewZoom");if(null!=K){this.tabContainer.style.right="70px";var z=q.addMenu("100%",K.funct);z.setAttribute("title",mxResources.get("zoom")+" (Alt+Mousewheel)");z.style.whiteSpace="nowrap";z.style.backgroundImage="url("+mxWindow.prototype.minimizeImage+")";z.style.backgroundPosition="right 6px center";z.style.backgroundRepeat="no-repeat";z.style.backgroundColor="#ffffff";z.style.paddingRight="10px";z.style.display="block";z.style.position="absolute";z.style.textDecoration="none";z.style.textDecoration=
+"none";z.style.right="0px";z.style.bottom="0px";z.style.overflow="hidden";z.style.visibility="hidden";z.style.textAlign="center";z.style.color="#000";z.style.fontSize="12px";z.style.color="#707070";z.style.width="59px";z.style.cursor="pointer";z.style.borderTop="1px solid lightgray";z.style.borderLeft="1px solid lightgray";z.style.height=parseInt(k.tabContainerHeight)-1+"px";z.style.lineHeight=parseInt(k.tabContainerHeight)+1+"px";y.appendChild(z);K=mxUtils.bind(this,function(){z.innerHTML=Math.round(100*
+k.editor.graph.view.scale)+"%"});k.editor.graph.view.addListener(mxEvent.EVENT_SCALE,K);k.editor.addListener("resetGraphView",K);k.editor.addListener("pageSelected",K);var L=k.setGraphEnabled;k.setGraphEnabled=function(){L.apply(this,arguments);null!=this.tabContainer&&(z.style.visibility=this.tabContainer.style.visibility,this.diagramContainer.style.bottom="hidden"!=this.tabContainer.style.visibility?this.tabContainerHeight+"px":"0px")}}y.appendChild(k.tabContainer);y.appendChild(n);y.appendChild(k.diagramContainer);
+l.appendChild(y);k.updateTabContainer();var O=null;g();mxEvent.addListener(window,"resize",function(){g();null!=k.sidebarWindow&&k.sidebarWindow.window.fit();null!=k.formatWindow&&k.formatWindow.window.fit();null!=k.actions.outlineWindow&&k.actions.outlineWindow.window.fit();null!=k.actions.layersWindow&&k.actions.layersWindow.window.fit();null!=k.menus.tagsWindow&&k.menus.tagsWindow.window.fit();null!=k.menus.findWindow&&k.menus.findWindow.window.fit()})}}};
+(function(){var a=!1;"min"!=uiTheme||a||mxClient.IS_CHROMEAPP||(EditorUi.initMinimalTheme(),a=!0);var b=EditorUi.initTheme;EditorUi.initTheme=function(){b.apply(this,arguments);"min"!=uiTheme||a||(this.initMinimalTheme(),a=!0)}})();DrawioComment=function(a,b,e,d,k,l,q){this.file=a;this.id=b;this.content=e;this.modifiedDate=d;this.createdDate=k;this.isResolved=l;this.user=q;this.replies=[]};DrawioComment.prototype.addReplyDirect=function(a){null!=a&&this.replies.push(a)};DrawioComment.prototype.addReply=function(a,b,e,d,k){b()};DrawioComment.prototype.editComment=function(a,b,e){b()};DrawioComment.prototype.deleteComment=function(a,b){a()};DrawioUser=function(a,b,e,d,k){this.id=a;this.email=b;this.displayName=e;this.pictureUrl=d;this.locale=k};mxResources.parse('# *DO NOT DIRECTLY EDIT THIS FILE, IT IS AUTOMATICALLY GENERATED AND IT IS BASED ON:*\n# https://docs.google.com/spreadsheet/ccc?key=0AmQEO36liL4FdDJLWVNMaVV2UmRKSnpXU09MYkdGbEE\nabout=About \naboutDrawio=About draw.io\naccessDenied=Access Denied\naction=Action\nactualSize=Actual Size\nadd=Add\naddAccount=Add account\naddedFile=Added {1}\naddImages=Add Images\naddImageUrl=Add Image URL\naddLayer=Add Layer\naddProperty=Add Property\naddress=Address\naddToExistingDrawing=Add to Existing Drawing\naddWaypoint=Add Waypoint\nadjustTo=Adjust to\nadvanced=Advanced\nalign=Align\nalignment=Alignment\nallChangesLost=All changes will be lost!\nallPages=All Pages\nallProjects=All Projects\nallSpaces=All Spaces\nallTags=All Tags\nanchor=Anchor\nandroid=Android\nangle=Angle\narc=Arc\nareYouSure=Are you sure?\nensureDataSaved=Please ensure your data is saved before closing.\nallChangesSaved=All changes saved\nallChangesSavedInDrive=All changes saved in Drive\nallowPopups=Allow pop-ups to avoid this dialog.\nallowRelativeUrl=Allow relative URL\nalreadyConnected=Nodes already connected\napply=Apply\narchiMate21=ArchiMate 2.1\narrange=Arrange\narrow=Arrow\narrows=Arrows\nasNew=As New\natlas=Atlas\nauthor=Author\nauthorizationRequired=Authorization required\nauthorizeThisAppIn=Authorize this app in {1}:\nauthorize=Authorize\nauthorizing=Authorizing\nautomatic=Automatic\nautosave=Autosave\nautosize=Autosize\nattachments=Attachments\naws=AWS\naws3d=AWS 3D\nazure=Azure\nback=Back\nbackground=Background\nbackgroundColor=Background Color\nbackgroundImage=Background Image\nbasic=Basic\nblankDrawing=Blank Drawing\nblankDiagram=Blank Diagram\nblock=Block\nblockquote=Blockquote\nblog=Blog\nbold=Bold\nbootstrap=Bootstrap\nborder=Border\nborderColor=Border Color\nborderWidth=Border Width\nbottom=Bottom\nbottomAlign=Bottom Align\nbottomLeft=Bottom Left\nbottomRight=Bottom Right\nbpmn=BPMN\nbrowser=Browser\nbulletedList=Bulleted List\nbusiness=Business\nbusy=Operation in progress\ncabinets=Cabinets\ncancel=Cancel\ncenter=Center\ncannotLoad=Load attempts failed. Please try again later.\ncannotLogin=Log in attempts failed. Please try again later.\ncannotOpenFile=Cannot open file\nchange=Change\nchangeOrientation=Change Orientation\nchangeUser=Change user\nchangeStorage=Change storage\nchangesNotSaved=Changes have not been saved\nclassDiagram=Class Diagram\nuserJoined={1} has joined\nuserLeft={1} has left\nchatWindowTitle=Chat\nchooseAnOption=Choose an option\nchromeApp=Chrome App\ncollaborativeEditingNotice=Important Notice for Collaborative Editing\ncompressed=Compressed\ncommitMessage=Commit Message\nconfigLinkWarn=This link configures draw.io. Only click OK if you trust whoever gave you it!\nconfigLinkConfirm=Click OK to configure and restart draw.io.\ncsv=CSV\ndark=Dark\ndiagramXmlDesc=XML File\ndiagramHtmlDesc=HTML File\ndiagramPngDesc=Editable Bitmap Image\ndiagramSvgDesc=Editable Vector Image\ndidYouMeanToExportToPdf=Did you mean to export to PDF?\ndraftFound=A draft for \'{1}\' has been found. Load it into the editor or discard it to continue.\nselectDraft=Select a draft to continue editing:\ndragAndDropNotSupported=Drag and drop not supported for images. Would you like to import instead?\ndropboxCharsNotAllowed=The following characters are not allowed: / : ? * " |\ncheck=Check\nchecksum=Checksum\ncircle=Circle\ncisco=Cisco\nclassic=Classic\nclearDefaultStyle=Clear Default Style\nclearWaypoints=Clear Waypoints\nclipart=Clipart\nclose=Close\nclosingFile=Closing file\ncollaborator=Collaborator\ncollaborators=Collaborators\ncollapse=Collapse\ncollapseExpand=Collapse/Expand\ncollapse-expand=Click to collapse/expand\nShift-click to move neighbors \nAlt-click to protect group size\ncollapsible=Collapsible\ncomic=Comic\ncomment=Comment\ncommentsNotes=Comments/Notes\ncompress=Compress\nconfiguration=Configuration\nconnect=Connect\nconnecting=Connecting\nconnectWithDrive=Connect with Google Drive\nconnection=Connection\nconnectionArrows=Connection Arrows\nconnectionPoints=Connection Points\nconstrainProportions=Constrain Proportions\ncontainsValidationErrors=Contains validation errors\ncopiedToClipboard=Copied to clipboard\ncopy=Copy\ncopyConnect=Copy on connect\ncopyCreated=A copy of the file was created.\ncopyOf=Copy of {1}\ncopyOfDrawing=Copy of Drawing\ncopySize=Copy Size\ncopyStyle=Copy Style\ncreate=Create\ncreateNewDiagram=Create New Diagram\ncreateRevision=Create Revision\ncreateShape=Create Shape\ncrop=Crop\ncurved=Curved\ncustom=Custom\ncurrent=Current\ncurrentPage=Current page\ncut=Cut\ndashed=Dashed\ndecideLater=Decide later\ndefault=Default\ndelete=Delete\ndeleteColumn=Delete Column\ndeleteLibrary401=Insufficient permissions to delete this library\ndeleteLibrary404=Selected library could not be found\ndeleteLibrary500=Error deleting library\ndeleteLibraryConfirm=You are about to permanently delete this library. Are you sure you want to do this?\ndeleteRow=Delete Row\ndescription=Description\ndevice=Device\ndiagram=Diagram\ndiagramContent=Diagram Content\ndiagramLocked=Diagram has been locked to prevent further data loss.\ndiagramLockedBySince=The diagram is locked by {1} since {2} ago\ndiagramName=Diagram Name\ndiagramIsPublic=Diagram is public\ndiagramIsNotPublic=Diagram is not public\ndiamond=Diamond\ndiamondThin=Diamond (thin)\ndidYouKnow=Did you know...\ndirection=Direction\ndiscard=Discard\ndiscardChangesAndReconnect=Discard Changes and Reconnect\ngoogleDriveMissingClickHere=Google Drive missing? Click here!\ndiscardChanges=Discard Changes\ndisconnected=Disconnected\ndistribute=Distribute\ndone=Done\ndoNotShowAgain=Do not show again\ndotted=Dotted\ndoubleClickOrientation=Doubleclick to change orientation\ndoubleClickTooltip=Doubleclick to insert text\ndoubleClickChangeProperty=Doubleclick to change property name\ndownload=Download\ndownloadDesktop=Get Desktop\ndownloadAs=Download as\nclickHereToSave=Click here to save.\ndpi=DPI\ndraftDiscarded=Draft discarded\ndraftSaved=Draft saved\ndragElementsHere=Drag elements here\ndragImagesHere=Drag images or URLs here\ndragUrlsHere=Drag URLs here\ndraw.io=draw.io\ndrawing=Drawing{1}\ndrawingEmpty=Drawing is empty\ndrawingTooLarge=Drawing is too large\ndrawioForWork=Draw.io for GSuite\ndropbox=Dropbox\nduplicate=Duplicate\nduplicateIt=Duplicate {1}\ndivider=Divider\ndx=Dx\ndy=Dy\neast=East\nedit=Edit\neditData=Edit Data\neditDiagram=Edit Diagram\neditGeometry=Edit Geometry\neditImage=Edit Image\neditImageUrl=Edit Image URL\neditLink=Edit Link\neditShape=Edit Shape\neditStyle=Edit Style\neditText=Edit Text\neditTooltip=Edit Tooltip\nglass=Glass\ngoogleImages=Google Images\nimageSearch=Image Search\neip=EIP\nembed=Embed\nembedImages=Embed Images\nmainEmbedNotice=Paste this into the page\nelectrical=Electrical\nellipse=Ellipse\nembedNotice=Paste this once at the end of the page\nenterGroup=Enter Group\nenterName=Enter Name\nenterPropertyName=Enter Property Name\nenterValue=Enter Value\nentityRelation=Entity Relation\nentityRelationshipDiagram=Entity Relationship Diagram\nerror=Error\nerrorDeletingFile=Error deleting file\nerrorLoadingFile=Error loading file\nerrorRenamingFile=Error renaming file\nerrorRenamingFileNotFound=Error renaming file. File was not found.\nerrorRenamingFileForbidden=Error renaming file. Insufficient access rights.\nerrorSavingDraft=Error saving draft\nerrorSavingFile=Error saving file\nerrorSavingFileUnknown=Error authorizing with Google\'s servers. Please refresh the page to re-attempt.\nerrorSavingFileForbidden=Error saving file. Insufficient access rights.\nerrorSavingFileNameConflict=Could not save diagram. Current page already contains file named \'{1}\'.\nerrorSavingFileNotFound=Error saving file. File was not found.\nerrorSavingFileReadOnlyMode=Could not save diagram while read-only mode is active.\nerrorSavingFileSessionTimeout=Your session has ended. Please <a target=\'_blank\' href=\'{1}\'>{2}</a> and return to this tab to try to save again.\nerrorSendingFeedback=Error sending feedback.\nerrorUpdatingPreview=Error updating preview.\nexit=Exit\nexitGroup=Exit Group\nexpand=Expand\nexport=Export\nexporting=Exporting\nexportAs=Export as\nexportOptionsDisabled=Export options disabled\nexportOptionsDisabledDetails=The owner has disabled options to download, print or copy for commenters and viewers on this file.\nexternalChanges=External Changes\nextras=Extras\nfacebook=Facebook\nfailedToSaveTryReconnect=Failed to save, trying to reconnect\nfeatureRequest=Feature Request\nfeedback=Feedback\nfeedbackSent=Feedback successfully sent.\nfloorplans=Floorplans\nfile=File\nfileChangedOverwriteDialog=The file has been modified. Do you want to save the file and overwrite those changes?\nfileChangedSyncDialog=The file has been modified. Do you want to synchronize those changes?\nfileChangedSync=The file has been modified. Click here to synchronize.\noverwrite=Overwrite\nsynchronize=Synchronize\nfilename=Filename\nfileExists=File already exists\nfileMovedToTrash=File was moved to trash\nfileNearlyFullSeeFaq=File nearly full, please see FAQ\nfileNotFound=File not found\nrepositoryNotFound=Repository not found\nfileNotFoundOrDenied=The file was not found. It does not exist or you do not have access.\nfileNotLoaded=File not loaded\nfileNotSaved=File not saved\nfileOpenLocation=How would you like to open these file(s)?\nfiletypeHtml=.html causes file to save as HTML with redirect to cloud URL\nfiletypePng=.png causes file to save as PNG with embedded data\nfiletypeSvg=.svg causes file to save as SVG with embedded data\nfileWillBeSavedInAppFolder={1} will be saved in the app folder.\nfill=Fill\nfillColor=Fill Color\nfilterCards=Filter Cards\nfind=Find\nfit=Fit\nfitContainer=Resize Container\nfitIntoContainer=Fit into Container\nfitPage=Fit Page\nfitPageWidth=Fit Page Width\nfitTo=Fit to\nfitToSheetsAcross=sheet(s) across\nfitToBy=by\nfitToSheetsDown=sheet(s) down\nfitTwoPages=Two Pages\nfitWindow=Fit Window\nflip=Flip\nflipH=Flip Horizontal\nflipV=Flip Vertical\nflowchart=Flowchart\nfolder=Folder\nfont=Font\nfontColor=Font Color\nfontFamily=Font Family\nfontSize=Font Size\nforbidden=You are not authorized to access this file\nformat=Format\nformatPanel=Format Panel\nformatted=Formatted\nformattedText=Formatted Text\nformatPng=PNG\nformatGif=GIF\nformatJpg=JPEG\nformatPdf=PDF\nformatSql=SQL\nformatSvg=SVG\nformatHtmlEmbedded=HTML\nformatSvgEmbedded=SVG (with XML)\nformatVsdx=VSDX\nformatVssx=VSSX\nformatXmlPlain=XML (Plain)\nformatXml=XML\nforum=Discussion/Help Forums\nfreehand=Freehand\nfromTemplate=From Template\nfromTemplateUrl=From Template URL\nfromText=From Text\nfromUrl=From URL\nfromThisPage=From this page\nfullscreen=Fullscreen\ngap=Gap\ngcp=GCP\ngeneral=General\ngithub=GitHub\ngitlab=GitLab\ngliffy=Gliffy\nglobal=Global\ngoogleDocs=Google Docs\ngoogleDrive=Google Drive\ngoogleGadget=Google Gadget\ngooglePlus=Google+\ngoogleSharingNotAvailable=Sharing is only available via Google Drive. Please click Open below and share from the more actions menu:\ngoogleSlides=Google Slides\ngoogleSites=Google Sites\ngoogleSheets=Google Sheets\ngradient=Gradient\ngradientColor=Color\ngrid=Grid\ngridColor=Grid Color\ngridSize=Grid Size\ngroup=Group\nguides=Guides\nhateApp=I hate draw.io\nheading=Heading\nheight=Height\nhelp=Help\nhelpTranslate=Help us translate this application\nhide=Hide\nhideIt=Hide {1}\nhidden=Hidden\nhome=Home\nhorizontal=Horizontal\nhorizontalFlow=Horizontal Flow\nhorizontalTree=Horizontal Tree\nhowTranslate=How good is the translation in your language?\nhtml=HTML\nhtmlText=HTML Text\nid=ID\niframe=IFrame\nignore=Ignore\nimage=Image\nimageUrl=Image URL\nimages=Images\nimagePreviewError=This image couldn\'t be loaded for preview. Please check the URL.\nimageTooBig=Image too big\nimgur=Imgur\nimport=Import\nimportFrom=Import from\nincludeCopyOfMyDiagram=Include a copy of my diagram\nincreaseIndent=Increase Indent\ndecreaseIndent=Decrease Indent\ninsert=Insert\ninsertColumnBefore=Insert Column Left\ninsertColumnAfter=Insert Column Right\ninsertEllipse=Insert Ellipse\ninsertImage=Insert Image\ninsertHorizontalRule=Insert Horizontal Rule\ninsertLink=Insert Link\ninsertPage=Insert Page\ninsertRectangle=Insert Rectangle\ninsertRhombus=Insert Rhombus\ninsertRowBefore=Insert Row Above\ninsertRowAfter=Insert Row After\ninsertText=Insert Text\ninserting=Inserting\ninstallApp=Install App\ninvalidFilename=Diagram names must not contain the following characters: / | : ; { } < > & + ? = "\ninvalidLicenseSeeThisPage=Your license is invalid, please see this <a target="_blank" href="https://support.draw.io/display/DFCS/Licensing+your+draw.io+plugin">page</a>.\ninvalidInput=Invalid input\ninvalidName=Invalid name\ninvalidOrMissingFile=Invalid or missing file\ninvalidPublicUrl=Invalid public URL\nisometric=Isometric\nios=iOS\nitalic=Italic\nkennedy=Kennedy\nkeyboardShortcuts=Keyboard Shortcuts\nlayers=Layers\nlandscape=Landscape\nlanguage=Language\nleanMapping=Lean Mapping\nlastChange=Last change {1} ago\nlessThanAMinute=less than a minute\nlicensingError=Licensing Error\nlicenseHasExpired=The license for {1} has expired on {2}. Click here.\nlicenseWillExpire=The license for {1} will expire on {2}. Click here.\nlineJumps=Line jumps\nlinkAccountRequired=If the diagram is not public a Google account is required to view the link.\nlinkText=Link Text\nlist=List\nminute=minute\nminutes=minutes\nhours=hours\ndays=days\nmonths=months\nyears=years\nrestartForChangeRequired=Changes will take effect after a restart of the application.\nlaneColor=Lanecolor\nlastModified=Last modified\nlayout=Layout\nleft=Left\nleftAlign=Left Align\nleftToRight=Left to right\nlibraryTooltip=Drag and drop shapes here or click + to insert. Double click to edit.\nlightbox=Lightbox\nline=Line\nlineend=Line end\nlineheight=Line Height\nlinestart=Line start\nlinewidth=Linewidth\nlink=Link\nlinks=Links\nloading=Loading\nlockUnlock=Lock/Unlock\nloggedOut=Logged Out\nlogIn=log in\nloveIt=I love {1}\nlucidchart=Lucidchart\nmaps=Maps\nmathematicalTypesetting=Mathematical Typesetting\nmakeCopy=Make a Copy\nmanual=Manual\nmermaid=Mermaid\nmicrosoftOffice=Microsoft Office\nmicrosoftExcel=Microsoft Excel\nmicrosoftPowerPoint=Microsoft PowerPoint\nmicrosoftWord=Microsoft Word\nmiddle=Middle\nminimal=Minimal\nmisc=Misc\nmockups=Mockups\nmodificationDate=Modification date\nmodifiedBy=Modified by\nmore=More\nmoreResults=More Results\nmoreShapes=More Shapes\nmove=Move\nmoveToFolder=Move to Folder\nmoving=Moving\nmoveSelectionTo=Move selection to {1}\nname=Name\nnavigation=Navigation\nnetwork=Network\nnetworking=Networking\nnew=New\nnewLibrary=New Library\nnextPage=Next Page\nno=No\nnoPickFolder=No, pick folder\nnoAttachments=No attachments found\nnoColor=No Color\nnoFiles=No Files\nnoFileSelected=No file selected\nnoLibraries=No libraries found\nnoMoreResults=No more results\nnone=None\nnoOtherViewers=No other viewers\nnoPlugins=No plugins\nnoPreview=No preview\nnoResponse=No response from server\nnoResultsFor=No results for \'{1}\'\nnoRevisions=No revisions\nnoSearchResults=No search results found\nnoPageContentOrNotSaved=No anchors found on this page or it hasn\'t been saved yet\nnormal=Normal\nnorth=North\nnotADiagramFile=Not a diagram file\nnotALibraryFile=Not a library file\nnotAvailable=Not available\nnotAUtf8File=Not a UTF-8 file\nnotConnected=Not connected\nnote=Note\nnotSatisfiedWithImport=Not satisfied with the import?\nnotUsingService=Not using {1}?\nnumberedList=Numbered list\noffline=Offline\nok=OK\noneDrive=OneDrive\nonline=Online\nopacity=Opacity\nopen=Open\nopenArrow=Open Arrow\nopenExistingDiagram=Open Existing Diagram\nopenFile=Open File\nopenFrom=Open from\nopenLibrary=Open Library\nopenLibraryFrom=Open Library from\nopenLink=Open Link\nopenInNewWindow=Open in New Window\nopenInThisWindow=Open in This Window\nopenIt=Open {1}\nopenRecent=Open Recent\nopenSupported=Supported formats are files saved from this software (.xml), .vsdx and .gliffy\noptions=Options\norganic=Organic\norgChart=Org Chart\northogonal=Orthogonal\notherViewer=other viewer\notherViewers=other viewers\noutline=Outline\noval=Oval\npage=Page\npageContent=Page Content\npageNotFound=Page not found\npageWithNumber=Page-{1}\npages=Pages\npageView=Page View\npageSetup=Page Setup\npageScale=Page Scale\npan=Pan\npanTooltip=Space+Drag to pan\npaperSize=Paper Size\npattern=Pattern\npaste=Paste\npasteHere=Paste here\npasteSize=Paste Size\npasteStyle=Paste Style\nperimeter=Perimeter\npermissionAnyone=Anyone can edit\npermissionAuthor=Owner and admins can edit\npickFolder=Pick a folder\npickLibraryDialogTitle=Select Library\npublicDiagramUrl=Public URL of the diagram\nplaceholders=Placeholders\nplantUml=PlantUML\nplugins=Plugins\npluginUrl=Plugin URL\npluginWarning=The page has requested to load the following plugin(s):\n \n {1}\n \n Would you like to load these plugin(s) now?\n \n NOTE : Only allow plugins to run if you fully understand the security implications of doing so.\n\nplusTooltip=Click to connect and clone (ctrl+click to clone, shift+click to connect). Drag to connect (ctrl+drag to clone).\nportrait=Portrait\nposition=Position\nposterPrint=Poster Print\npreferences=Preferences\npreview=Preview\npreviousPage=Previous Page\nprint=Print\nprintAllPages=Print All Pages\nprocEng=Proc. Eng.\nproject=Project\npriority=Priority\nproperties=Properties\npublish=Publish\nquickStart=Quick Start Video\nrack=Rack\nradialTree=Radial Tree\nreadOnly=Read-only\nreconnecting=Reconnecting\nrecentlyUpdated=Recently Updated\nrecentlyViewed=Recently Viewed\nrectangle=Rectangle\nredirectToNewApp=This file was created or modified in a newer version of this app. You will be redirected now.\nrealtimeTimeout=It looks like you\'ve made a few changes while offline. We\'re sorry, these changes cannot be saved.\nredo=Redo\nrefresh=Refresh\nregularExpression=Regular Expression\nrelative=Relative\nrelativeUrlNotAllowed=Relative URL not allowed\nrememberMe=Remember me\nrememberThisSetting=Remember this setting\nremoveFormat=Clear Formatting\nremoveFromGroup=Remove from Group\nremoveIt=Remove {1}\nremoveWaypoint=Remove Waypoint\nrename=Rename\nrenamed=Renamed\nrenameIt=Rename {1}\nrenaming=Renaming\nreplace=Replace\nreplaceIt={1} already exists. Do you want to replace it?\nreplaceExistingDrawing=Replace existing drawing\nrequired=required\nreset=Reset\nresetView=Reset View\nresize=Resize\nresizeLargeImages=Do you want to resize large images to make the application run faster?\nretina=Retina\nresponsive=Responsive\nrestore=Restore\nrestoring=Restoring\nretryingIn=Retrying in {1} second(s)\nretryingLoad=Load failed. Retrying...\nretryingLogin=Login time out. Retrying...\nreverse=Reverse\nrevision=Revision\nrevisionHistory=Revision History\nrhombus=Rhombus\nright=Right\nrightAlign=Right Align\nrightToLeft=Right to left\nrotate=Rotate\nrotateTooltip=Click and drag to rotate, click to turn shape only by 90 degrees\nrotation=Rotation\nrounded=Rounded\nsave=Save\nsaveAndExit=Save & Exit\nsaveAs=Save as\nsaveAsXmlFile=Save as XML file?\nsaved=Saved\nsaveDiagramFirst=Please save the diagram first\nsaveDiagramsTo=Save diagrams to\nsaveLibrary403=Insufficient permissions to edit this library\nsaveLibrary500=There was an error while saving the library\nsaveLibraryReadOnly=Could not save library while read-only mode is active\nsaving=Saving\nscratchpad=Scratchpad\nscrollbars=Scrollbars\nsearch=Search\nsearchShapes=Search Shapes\nselectAll=Select All\nselectionOnly=Selection Only\nselectCard=Select Card\nselectEdges=Select Edges\nselectFile=Select File\nselectFolder=Select Folder\nselectFont=Select Font\nselectNone=Select None\nselectTemplate=Select Template\nselectVertices=Select Vertices\nsendMessage=Send\nsendYourFeedback=Send your feedback\nserviceUnavailableOrBlocked=Service unavailable or blocked\nsessionExpired=Your session has expired. Please refresh the browser window.\nsessionTimeoutOnSave=Your session has timed out and you have been disconnected from the Google Drive. Press OK to login and save. \nsetAsDefaultStyle=Set as Default Style\nshadow=Shadow\nshape=Shape\nshapes=Shapes\nshare=Share\nshareLink=Link for shared editing\nsharp=Sharp\nshow=Show\nshowStartScreen=Show Start Screen\nsidebarTooltip=Click to expand. Drag and drop shapes into the diagram. Shift+click to change selection. Alt+click to insert and connect.\nsigns=Signs\nsignOut=Sign out\nsimple=Simple\nsimpleArrow=Simple Arrow\nsimpleViewer=Simple Viewer\nsize=Size\nsolid=Solid\nsourceSpacing=Source Spacing\nsouth=South\nsoftware=Software\nspace=Space\nspacing=Spacing\nspecialLink=Special Link\nstandard=Standard\nstartDrawing=Start drawing\nstopDrawing=Stop drawing\nstarting=Starting\nstraight=Straight\nstrikethrough=Strikethrough\nstrokeColor=Line Color\nstyle=Style\nsubscript=Subscript\nsummary=Summary\nsuperscript=Superscript\nsupport=Support\nswimlaneDiagram=Swimlane Diagram\nsysml=SysML\ntags=Tags\ntable=Table\ntables=Tables\ntakeOver=Take Over\ntargetSpacing=Target Spacing\ntemplate=Template\ntemplates=Templates\ntext=Text\ntextAlignment=Text Alignment\ntextOpacity=Text Opacity\ntheme=Theme\ntimeout=Timeout\ntitle=Title\nto=to\ntoBack=To Back\ntoFront=To Front\ntoolbar=Toolbar\ntooltips=Tooltips\ntop=Top\ntopAlign=Top Align\ntopLeft=Top Left\ntopRight=Top Right\ntransparent=Transparent\ntransparentBackground=Transparent Background\ntrello=Trello\ntryAgain=Try again\ntryOpeningViaThisPage=Try opening via this page\nturn=Rotate shape only by 90°\ntype=Type\ntwitter=Twitter\numl=UML\nunderline=Underline\nundo=Undo\nungroup=Ungroup\nunsavedChanges=Unsaved changes\nunsavedChangesClickHereToSave=Unsaved changes. Click here to save.\nuntitled=Untitled\nuntitledDiagram=Untitled Diagram\nuntitledLayer=Untitled Layer\nuntitledLibrary=Untitled Library\nunknownError=Unknown error\nupdateFile=Update {1}\nupdatingDocument=Updating Document. Please wait...\nupdatingPreview=Updating Preview. Please wait...\nupdatingSelection=Updating Selection. Please wait...\nupload=Upload\nurl=URL\nuseOffline=Use Offline\nuseRootFolder=Use root folder?\nuserManual=User Manual\nvertical=Vertical\nverticalFlow=Vertical Flow\nverticalTree=Vertical Tree\nview=View\nviewerSettings=Viewer Settings\nviewUrl=Link to view: {1}\nvoiceAssistant=Voice Assistant (beta)\nwarning=Warning\nwaypoints=Waypoints\nwest=West\nwidth=Width\nwiki=Wiki\nwordWrap=Word Wrap\nwritingDirection=Writing Direction\nyes=Yes\nyourEmailAddress=Your email address\nzoom=Zoom\nzoomIn=Zoom In\nzoomOut=Zoom Out\nbasic=Basic\nbusinessprocess=Business Processes\ncharts=Charts\nengineering=Engineering\nflowcharts=Flowcharts\ngmdl=Material Design\nmindmaps=Mindmaps\nmockups=Mockups\nnetworkdiagrams=Network Diagrams\nnothingIsSelected=Nothing is selected\nother=Other\nsoftwaredesign=Software Design\nvenndiagrams=Venn Diagrams\nwebEmailOrOther=Web, email or any other internet address\nwebLink=Web Link\nwireframes=Wireframes\nproperty=Property\nvalue=Value\nshowMore=Show More\nshowLess=Show Less\nmyDiagrams=My Diagrams\nallDiagrams=All Diagrams\nrecentlyUsed=Recently used\nlistView=List view\ngridView=Grid view\nresultsFor=Results for \'{1}\'\noneDriveCharsNotAllowed=The following characters are not allowed: ~ " # % * : < > ? / { | }\noneDriveInvalidDeviceName=The specified device name is invalid\nofficeNotLoggedOD=You are not logged in to OneDrive. Please open draw.io task pane and login first.\nofficeSelectSingleDiag=Please select a single draw.io diagram only without other contents.\nofficeSelectDiag=Please select a draw.io diagram.\nofficeCannotFindDiagram=Cannot find a draw.io diagram in the selection\nnoDiagrams=No diagrams found\nauthFailed=Authentication failed\nofficeFailedAuthMsg=Unable to successfully authenticate user or authorize application.\nconvertingDiagramFailed=Converting diagram failed\nofficeCopyImgErrMsg=Due to some limitations in the host application, the image could not be inserted. Please manually copy the image then paste it to the document.\ninsertingImageFailed=Inserting image failed\nofficeCopyImgInst=Instructions: Right-click the image below. Select "Copy image" from the context menu. Then, in the document, right-click and select "Paste" from the context menu.\nfolderEmpty=Folder is empty\nrecent=Recent\nsharedWithMe=Shared With Me\nsharepointSites=Sharepoint Sites\nerrorFetchingFolder=Error fetching folder items\nerrorAuthOD=Error authenticating to OneDrive\nofficeMainHeader=Adds draw.io diagrams to your document.\nofficeStepsHeader=This add-in performs the following steps:\nofficeStep1=Connects to Microsoft OneDrive, Google Drive or your device.\nofficeStep2=Select a draw.io diagram.\nofficeStep3=Insert the diagram into the document.\nofficeAuthPopupInfo=Please complete the authentication in the pop-up window.\nofficeSelDiag=Select draw.io Diagram:\nfiles=Files\nshared=Shared\nsharepoint=Sharepoint\nofficeManualUpdateInst=Instructions: Copy draw.io diagram from the document. Then, in the box below, right-click and select "Paste" from the context menu.\nofficeClickToEdit=Click icon to start editing:\npasteDiagram=Paste draw.io diagram here\nconnectOD=Connect to OneDrive\nselectChildren=Select Children\nselectSiblings=Select Siblings\nselectParent=Select Parent\nselectDescendants=Select Descendants\nlastSaved=Last saved {1} ago\nresolve=Resolve\nreopen=Re-open\nshowResolved=Show Resolved\nreply=Reply\nobjectNotFound=Object not found\nreOpened=Re-opened\nmarkedAsResolved=Marked as resolved\nnoCommentsFound=No comments found\ncomments=Comments\ntimeAgo={1} ago\nconfluenceCloud=Confluence Cloud\nlibraries=Libraries\nconfAnchor=Confluence Page Anchor\nconfTimeout=The connection has timed out\nconfSrvTakeTooLong=The server at {1} is taking too long to respond.\nconfCannotInsertNew=Cannot insert draw.io diagram to a new Confluence page\nconfSaveTry=Please save the page and try again.\nconfCannotGetID=Unable to determine page ID\nconfContactAdmin=Please contact your Confluence administrator.\nreadErr=Read Error\neditingErr=Editing Error\nconfExtEditNotPossible=This diagram cannot be edited externally. Please try editing it while editing the page\nconfEditedExt=Diagram/Page edited externally\ndiagNotFound=Diagram Not Found\nconfEditedExtRefresh=Diagram/Page is edited externally. Please refresh the page.\nconfCannotEditDraftDelOrExt=Cannot edit diagrams in a draft page, diagram is deleted from the page, or diagram is edited externally. Please check the page.\nretBack=Return back\nconfDiagNotPublished=The diagram does not belong to a published page\ncreatedByDraw=Created by draw.io\nfilenameShort=Filename too short\ninvalidChars=Invalid characters\nalreadyExst={1} already exists\ndraftReadErr=Draft Read Error\ndiagCantLoad=Diagram cannot be loaded\ndraftWriteErr=Draft Write Error\ndraftCantCreate=Draft could not be created\nconfDuplName=Duplicate diagram name detected. Please pick another name.\nconfSessionExpired=Looks like your session expired. Log in again to keep working.\nlogin=Login\ndrawPrev=draw.io preview\ndrawDiag=draw.io diagram\ninvalidCallFnNotFound=Invalid Call: {1} not found\ninvalidCallErrOccured=Invalid Call: An error occurred, {1}\nanonymous=Anonymous\nconfGotoPage=Go to containing page\nshowComments=Show Comments\nconfError=Error: {1}\ngliffyImport=Gliffy Import\ngliffyImportInst1=Click the "Start Import" button to import all Gliffy diagrams to draw.io.\ngliffyImportInst2=Please note that the import procedure will take some time and the browser window must remain open until the import is completed.\nstartImport=Start Import\ndrawConfig=draw.io Configuration\ncustomLib=Custom Libraries\ncustomTemp=Custom Templates\npageIdsExp=Page IDs Export\ndrawReindex=draw.io re-indexing (beta)\nworking=Working\ndrawConfigNotFoundInst=draw.io Configuration Space (DRAWIOCONFIG) does not exist. This space is needed to store draw.io configuration files and custom libraries/templates.\ncreateConfSp=Create Config Space\nunexpErrRefresh=Unexpected error, please refresh the page and try again.\nconfigJSONInst=Write draw.io JSON configuration in the editor below then click save. If you need help, please refer to\nthisPage=this page\ncurCustLib=Current Custom Libraries\nlibName=Library Name\naction=Action\ndrawConfID=draw.io Config ID\naddLibInst=Click the "Add Library" button to upload a new library.\naddLib=Add Library\ncustomTempInst1=Custom templates are draw.io diagrams saved in children pages of\ncustomTempInst2=For more details, please refer to\ntempsPage=Templates page\npageIdsExpInst1=Select export target, then click the "Start Export" button to export all pages IDs.\npageIdsExpInst2=Please note that the export procedure will take some time and the browser window must remain open until the export is completed.\nstartExp=Start Export\nrefreshDrawIndex=Refresh draw.io Diagrams Index\nreindexInst1=Click the "Start Indexing" button to refresh draw.io diagrams index.\nreindexInst2=Please note that the indexing procedure will take some time and the browser window must remain open until the indexing is completed.\nstartIndexing=Start Indexing\nconfAPageFoundFetch=Page "{1}" found. Fetching\nconfAAllDiagDone=All {1} diagrams processed. Process finished.\nconfAStartedProcessing=Started processing page "{1}"\nconfAAllDiagInPageDone=All {1} diagrams in page "{2}" processed successfully.\nconfAPartialDiagDone={1} out of {2} {3} diagrams in page "{4}" processed successfully.\nconfAUpdatePageFailed=Updating page "{1}" failed.\nconfANoDiagFoundInPage=No {1} diagrams found in page "{2}".\nconfAFetchPageFailed=Fetching the page failed.\nconfANoDiagFound=No {1} diagrams found. Process finished.\nconfASearchFailed=Searching for {1} diagrams failed. Please try again later.\nconfAGliffyDiagFound={2} diagram "{1}" found. Importing\nconfAGliffyDiagImported={2} diagram "{1}" imported successfully.\nconfASavingImpGliffyFailed=Saving imported {2} diagram "{1}" failed.\nconfAImportedFromByDraw=Imported from "{1}" by draw.io\nconfAImportGliffyFailed=Importing {2} diagram "{1}" failed.\nconfAFetchGliffyFailed=Fetching {2} diagram "{1}" failed.\nconfACheckBrokenDiagLnk=Checking for broken diagrams links.\nconfADelDiagLinkOf=Deleting diagram link of "{1}"\nconfADupLnk=(duplicate link)\nconfADelDiagLnkFailed=Deleting diagram link of "{1}" failed.\nconfAUnexpErrProcessPage=Unexpected error during processing the page with id: {1}\nconfADiagFoundIndex=Diagram "{1}" found. Indexing\nconfADiagIndexSucc=Diagram "{1}" indexed successfully.\nconfAIndexDiagFailed=Indexing diagram "{1}" failed.\nconfASkipDiagOtherPage=Skipped "{1}" as it belongs to another page!\nconfADiagUptoDate=Diagram "{1}" is up to date.\nconfACheckPagesWDraw=Checking pages having draw.io diagrams.\nconfAErrOccured=An error occurred!\nsavedSucc=Saved successfully\nconfASaveFailedErr=Saving Failed (Unexpected Error)\ncharacter=Character\nconfAConfPageDesc=This page contains draw.io configuration file (configuration.json) as attachment\nconfALibPageDesc=This page contains draw.io custom libraries as attachments\nconfATempPageDesc=This page contains draw.io custom templates as attachments\nworking=Working\nconfAConfSpaceDesc=This space is used to store draw.io configuration files and custom libraries/templates\nconfANoCustLib=No Custom Libraries\ndelFailed=Delete failed!\nshowID=Show ID\nconfAIncorrectLibFileType=Incorrect file type. Libraries should be XML files.\nuploading=Uploading\nconfALibExist=This library already exists\nconfAUploadSucc=Uploaded successfully\nconfAUploadFailErr=Upload Failed (Unexpected Error)\nhiResPreview=High Res Preview\nofficeNotLoggedGD=You are not logged in to Google Drive. Please open draw.io task pane and login first.\nofficePopupInfo=Please complete the process in the pop-up window.\npickODFile=Pick OneDrive File\npickGDriveFile=Pick Google Drive File\npickDeviceFile=Pick Device File\nvsdNoConfig="vsdurl" is not configured\nruler=Ruler\nunits=Units\npoints=Points\ninches=Inches\nmillimeters=Millimeters\nconfEditDraftDelOrExt=This diagram is in a draft page, is deleted from the page, or is edited externally. It will be saved as a new attachment version and may not be reflected in the page.\nconfDiagEditedExt=Diagram is edited in another session. It will be saved as a new attachment version but the page will show other session\'s modifications.\nmacroNotFound=Macro Not Found\nconfAInvalidPageIdsFormat=Incorrect Page IDs file format\nconfACollectingCurPages=Collecting current pages\nconfABuildingPagesMap=Building pages mapping\nconfAProcessDrawDiag=Started processing imported draw.io diagrams\nconfAProcessDrawDiagDone=Finished processing imported draw.io diagrams\nconfAProcessImpPages=Started processing imported pages\nconfAErrPrcsDiagInPage=Error processing draw.io diagrams in page "{1}"\nconfAPrcsDiagInPage=Processing draw.io diagrams in page "{1}"\nconfAImpDiagram=Importing diagram "{1}"\nconfAImpDiagramFailed=Importing diagram "{1}" failed. Cannot find its new page ID. Maybe it points to a page that is not imported. \nconfAImpDiagramError=Error importing diagram "{1}". Cannot fetch or save the diagram. Cannot fix this diagram links.\nconfAUpdateDgrmCCFailed=Updating link to diagram "{1}" failed.\nconfImpDiagramSuccess=Updating diagram "{1}" done successfully.\nconfANoLnksInDrgm=No links to update in: {1}\nconfAUpdateLnkToPg=Updated link to page: "{1}" in diagram: "{2}"\nconfAUpdateLBLnkToPg=Updated lightbox link to page: "{1}" in diagram: "{2}"\nconfAUpdateLnkBase=Updated base URL from: "{1}" to: "{2}" in diagram: "{3}"\nconfAPageIdsImpDone=Page IDs Import finished.\nconfAPrcsMacrosInPage=Processing draw.io macros in page "{1}"\nconfAErrFetchPage=Error fetching page "{1}"\nconfAFixingMacro=Fixing macro of diagram "{1}"\nconfAErrReadingExpFile=Error reading export file\nconfAPrcsDiagInPageDone=Processing draw.io diagrams in page "{1}" finished\nconfAFixingMacroSkipped=Fixing macro of diagram "{1}" failed. Cannot find its new page ID. Maybe it points to a page that is not imported. \npageIdsExpTrg=Export target\nconfALucidDiagImgImported={2} diagram "{1}" image extracted successfully.\nconfASavingLucidDiagImgFailed=Extracting {2} diagram "{1}" image failed.\nconfGetInfoFailed=Fetching file info from {1} failed.\nconfCheckCacheFailed=Cannot get cached file info.\nconfReadFileErr=Cannot read "{1}" file from {2}.\nconfSaveCacheFailed=Unexpected error. Cannot save cached file\norgChartType=Org Chart Type\nlinear=Linear\nhanger2=Hanger 2\nhanger4=Hanger 4\nfishbone1=Fishbone 1\nfishbone2=Fishbone 2\n1ColumnLeft=Single Column Left\n1ColumnRight=Single Column Right\nsmart=Smart\nparentChildSpacing=Parent Child Spacing\nsiblingSpacing=Sibling Spacing\nconfNoPermErr=Sorry, you don\'t have enough permissions to view this embedded diagram from page {1}\ncopyAsImage=Copy as Image\nlucidImport=Lucidchart Import\nlucidImportInst1=Click the "Start Import" button to import all Lucidchart diagrams.\ninstallFirst=Please install {1} first.\ndrawioChromeExt=draw.io Chrome Extension\nloginFirstThen=Please login to {1} first, then {2}\nerrFetchDocList=Error: Couldn\'t fetch documents list.\n');Graph.prototype.defaultThemes["default-style2"]=mxUtils.parseXml('<mxStylesheet><add as="defaultVertex"><add as="shape" value="label"/><add as="perimeter" value="rectanglePerimeter"/><add as="fontSize" value="12"/><add as="fontFamily" value="Helvetica"/><add as="align" value="center"/><add as="verticalAlign" value="middle"/><add as="fillColor" value="#ffffff"/><add as="strokeColor" value="#000000"/><add as="fontColor" value="#000000"/></add><add as="defaultEdge"><add as="shape" value="connector"/><add as="labelBackgroundColor" value="#ffffff"/><add as="endArrow" value="classic"/><add as="fontSize" value="11"/><add as="fontFamily" value="Helvetica"/><add as="align" value="center"/><add as="verticalAlign" value="middle"/><add as="rounded" value="1"/><add as="strokeColor" value="#000000"/><add as="fontColor" value="#000000"/></add><add as="text"><add as="fillColor" value="none"/><add as="gradientColor" value="none"/><add as="strokeColor" value="none"/><add as="align" value="left"/><add as="verticalAlign" value="top"/></add><add as="edgeLabel" extend="text"><add as="labelBackgroundColor" value="#ffffff"/><add as="fontSize" value="11"/></add><add as="label"><add as="fontStyle" value="1"/><add as="align" value="left"/><add as="verticalAlign" value="middle"/><add as="spacing" value="2"/><add as="spacingLeft" value="52"/><add as="imageWidth" value="42"/><add as="imageHeight" value="42"/><add as="rounded" value="1"/></add><add as="icon" extend="label"><add as="align" value="center"/><add as="imageAlign" value="center"/><add as="verticalLabelPosition" value="bottom"/><add as="verticalAlign" value="top"/><add as="spacingTop" value="4"/><add as="labelBackgroundColor" value="#ffffff"/><add as="spacing" value="0"/><add as="spacingLeft" value="0"/><add as="spacingTop" value="6"/><add as="fontStyle" value="0"/><add as="imageWidth" value="48"/><add as="imageHeight" value="48"/></add><add as="swimlane"><add as="shape" value="swimlane"/><add as="fontSize" value="12"/><add as="fontStyle" value="1"/><add as="startSize" value="23"/></add><add as="group"><add as="verticalAlign" value="top"/><add as="fillColor" value="none"/><add as="strokeColor" value="none"/><add as="gradientColor" value="none"/><add as="pointerEvents" value="0"/></add><add as="ellipse"><add as="shape" value="ellipse"/><add as="perimeter" value="ellipsePerimeter"/></add><add as="rhombus"><add as="shape" value="rhombus"/><add as="perimeter" value="rhombusPerimeter"/></add><add as="triangle"><add as="shape" value="triangle"/><add as="perimeter" value="trianglePerimeter"/></add><add as="line"><add as="shape" value="line"/><add as="strokeWidth" value="4"/><add as="labelBackgroundColor" value="#ffffff"/><add as="verticalAlign" value="top"/><add as="spacingTop" value="8"/></add><add as="image"><add as="shape" value="image"/><add as="labelBackgroundColor" value="white"/><add as="verticalAlign" value="top"/><add as="verticalLabelPosition" value="bottom"/></add><add as="roundImage" extend="image"><add as="perimeter" value="ellipsePerimeter"/></add><add as="rhombusImage" extend="image"><add as="perimeter" value="rhombusPerimeter"/></add><add as="arrow"><add as="shape" value="arrow"/><add as="edgeStyle" value="none"/><add as="fillColor" value="#ffffff"/></add><add as="fancy"><add as="shadow" value="1"/><add as="glass" value="1"/></add><add as="gray" extend="fancy"><add as="gradientColor" value="#B3B3B3"/><add as="fillColor" value="#F5F5F5"/><add as="strokeColor" value="#666666"/></add><add as="blue" extend="fancy"><add as="gradientColor" value="#7EA6E0"/><add as="fillColor" value="#DAE8FC"/><add as="strokeColor" value="#6C8EBF"/></add><add as="green" extend="fancy"><add as="gradientColor" value="#97D077"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#82B366"/></add><add as="turquoise" extend="fancy"><add as="gradientColor" value="#67AB9F"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#6A9153"/></add><add as="yellow" extend="fancy"><add as="gradientColor" value="#FFD966"/><add as="fillColor" value="#FFF2CC"/><add as="strokeColor" value="#D6B656"/></add><add as="orange" extend="fancy"><add as="gradientColor" value="#FFA500"/><add as="fillColor" value="#FFCD28"/><add as="strokeColor" value="#D79B00"/></add><add as="red" extend="fancy"><add as="gradientColor" value="#EA6B66"/><add as="fillColor" value="#F8CECC"/><add as="strokeColor" value="#B85450"/></add><add as="pink" extend="fancy"><add as="gradientColor" value="#B5739D"/><add as="fillColor" value="#E6D0DE"/><add as="strokeColor" value="#996185"/></add><add as="purple" extend="fancy"><add as="gradientColor" value="#8C6C9C"/><add as="fillColor" value="#E1D5E7"/><add as="strokeColor" value="#9673A6"/></add><add as="plain-gray"><add as="gradientColor" value="#B3B3B3"/><add as="fillColor" value="#F5F5F5"/><add as="strokeColor" value="#666666"/></add><add as="plain-blue"><add as="gradientColor" value="#7EA6E0"/><add as="fillColor" value="#DAE8FC"/><add as="strokeColor" value="#6C8EBF"/></add><add as="plain-green"><add as="gradientColor" value="#97D077"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#82B366"/></add><add as="plain-turquoise"><add as="gradientColor" value="#67AB9F"/><add as="fillColor" value="#D5E8D4"/><add as="strokeColor" value="#6A9153"/></add><add as="plain-yellow"><add as="gradientColor" value="#FFD966"/><add as="fillColor" value="#FFF2CC"/><add as="strokeColor" value="#D6B656"/></add><add as="plain-orange"><add as="gradientColor" value="#FFA500"/><add as="fillColor" value="#FFCD28"/><add as="strokeColor" value="#D79B00"/></add><add as="plain-red"><add as="gradientColor" value="#EA6B66"/><add as="fillColor" value="#F8CECC"/><add as="strokeColor" value="#B85450"/></add><add as="plain-pink"><add as="gradientColor" value="#B5739D"/><add as="fillColor" value="#E6D0DE"/><add as="strokeColor" value="#996185"/></add><add as="plain-purple"><add as="gradientColor" value="#8C6C9C"/><add as="fillColor" value="#E1D5E7"/><add as="strokeColor" value="#9673A6"/></add></mxStylesheet>').documentElement;
Graph.prototype.defaultThemes.darkTheme=mxUtils.parseXml('<mxStylesheet><add as="defaultVertex"><add as="shape" value="label"/><add as="perimeter" value="rectanglePerimeter"/><add as="fontSize" value="12"/><add as="fontFamily" value="Helvetica"/><add as="align" value="center"/><add as="verticalAlign" value="middle"/><add as="fillColor" value="#2a2a2a"/><add as="strokeColor" value="#f0f0f0"/><add as="fontColor" value="#f0f0f0"/></add><add as="defaultEdge"><add as="shape" value="connector"/><add as="labelBackgroundColor" value="#2a2a2a"/><add as="endArrow" value="classic"/><add as="fontSize" value="11"/><add as="fontFamily" value="Helvetica"/><add as="align" value="center"/><add as="verticalAlign" value="middle"/><add as="rounded" value="1"/><add as="strokeColor" value="#f0f0f0"/><add as="fontColor" value="#f0f0f0"/></add><add as="text"><add as="fillColor" value="none"/><add as="gradientColor" value="none"/><add as="strokeColor" value="none"/><add as="align" value="left"/><add as="verticalAlign" value="top"/></add><add as="edgeLabel" extend="text"><add as="labelBackgroundColor" value="#2a2a2a"/><add as="fontSize" value="11"/></add><add as="label"><add as="fontStyle" value="1"/><add as="align" value="left"/><add as="verticalAlign" value="middle"/><add as="spacing" value="2"/><add as="spacingLeft" value="52"/><add as="imageWidth" value="42"/><add as="imageHeight" value="42"/><add as="rounded" value="1"/></add><add as="icon" extend="label"><add as="align" value="center"/><add as="imageAlign" value="center"/><add as="verticalLabelPosition" value="bottom"/><add as="verticalAlign" value="top"/><add as="spacingTop" value="4"/><add as="labelBackgroundColor" value="#2a2a2a"/><add as="spacing" value="0"/><add as="spacingLeft" value="0"/><add as="spacingTop" value="6"/><add as="fontStyle" value="0"/><add as="imageWidth" value="48"/><add as="imageHeight" value="48"/></add><add as="swimlane"><add as="shape" value="swimlane"/><add as="fontSize" value="12"/><add as="fontStyle" value="1"/><add as="startSize" value="23"/></add><add as="group"><add as="verticalAlign" value="top"/><add as="fillColor" value="none"/><add as="strokeColor" value="none"/><add as="gradientColor" value="none"/><add as="pointerEvents" value="0"/></add><add as="ellipse"><add as="shape" value="ellipse"/><add as="perimeter" value="ellipsePerimeter"/></add><add as="rhombus"><add as="shape" value="rhombus"/><add as="perimeter" value="rhombusPerimeter"/></add><add as="triangle"><add as="shape" value="triangle"/><add as="perimeter" value="trianglePerimeter"/></add><add as="line"><add as="shape" value="line"/><add as="strokeWidth" value="4"/><add as="labelBackgroundColor" value="#2a2a2a"/><add as="verticalAlign" value="top"/><add as="spacingTop" value="8"/></add><add as="image"><add as="shape" value="image"/><add as="labelBackgroundColor" value="#2a2a2a"/><add as="verticalAlign" value="top"/><add as="verticalLabelPosition" value="bottom"/></add><add as="roundImage" extend="image"><add as="perimeter" value="ellipsePerimeter"/></add><add as="rhombusImage" extend="image"><add as="perimeter" value="rhombusPerimeter"/></add><add as="arrow"><add as="shape" value="arrow"/><add as="edgeStyle" value="none"/><add as="fillColor" value="#2a2a2a"/></add></mxStylesheet>').documentElement;GraphViewer=function(a,b,e){this.init(a,b,e)};mxUtils.extend(GraphViewer,mxEventSource);GraphViewer.prototype.editBlankUrl="https://app.diagrams.net/";GraphViewer.prototype.imageBaseUrl="https://app.diagrams.net/";GraphViewer.prototype.toolbarHeight="BackCompat"==document.compatMode?28:30;GraphViewer.prototype.lightboxChrome=!0;GraphViewer.prototype.lightboxZIndex=999;GraphViewer.prototype.toolbarZIndex=999;GraphViewer.prototype.autoFit=!0;GraphViewer.prototype.center=!1;
GraphViewer.prototype.allowZoomIn=!1;GraphViewer.prototype.showTitleAsTooltip=!1;GraphViewer.prototype.checkVisibleState=!0;GraphViewer.prototype.minHeight=28;GraphViewer.prototype.minWidth=100;
GraphViewer.prototype.init=function(a,b,e){this.graphConfig=null!=e?e:{};this.autoFit=null!=this.graphConfig["auto-fit"]?this.graphConfig["auto-fit"]:this.autoFit;this.allowZoomIn=null!=this.graphConfig["allow-zoom-in"]?this.graphConfig["allow-zoom-in"]:this.allowZoomIn;this.center=null!=this.graphConfig.center?this.graphConfig.center:this.center;this.checkVisibleState=null!=this.graphConfig["check-visible-state"]?this.graphConfig["check-visible-state"]:this.checkVisibleState;this.toolbarItems=null!=
@@ -3627,7 +3627,7 @@ mxClient.IS_SVG&&this.graph.addSvgShadow(this.graph.view.canvas.ownerSVGElement,
[];this.xmlNode!=k&&(this.diagrams=this.xmlNode.getElementsByTagName("diagram"),k=this.xmlNode)});this.addListener("xmlNodeChanged",e);e();urlParams.page=d.currentPage;this.graph.getModel().beginUpdate();try{urlParams.nav=0!=this.graphConfig.nav?"1":"0",this.editor.setGraphXml(this.xmlNode),this.graph.border=null!=this.graphConfig.border?this.graphConfig.border:8,this.graph.view.scale=this.graphConfig.zoom||1}finally{this.graph.getModel().endUpdate()}this.graph.panningHandler.useLeftButtonForPanning=
!0;this.graph.panningHandler.isForcePanningEvent=function(a){return!mxEvent.isPopupTrigger(a.getEvent())&&"auto"==this.graph.container.style.overflow};this.graph.panningHandler.usePopupTrigger=!1;this.graph.panningHandler.pinchEnabled=!1;this.graph.panningHandler.ignoreCell=!0;this.graph.setPanning(!1);null!=this.graphConfig.toolbar?this.addToolbar():null!=this.graphConfig.title&&this.showTitleAsTooltip&&a.setAttribute("title",this.graphConfig.title);this.addSizeHandler();this.showLayers(this.graph);
this.addClickHandler(this.graph);this.graph.setTooltips(0!=this.graphConfig.tooltips);this.graph.initialViewState={translate:this.graph.view.translate.clone(),scale:this.graph.view.scale};d=this;this.graph.customLinkClicked=function(a){if("data:page/id,"==a.substring(0,13)){var b=a.indexOf(",");d.selectPageById(a.substring(b+1))||alert(mxResources.get("pageNotFound")||"Page not found")}else this.handleCustomLink(a);return!0};this.fireEvent(new mxEventObject("render"))});e=window.MutationObserver||
-window.WebKitMutationObserver||window.MozMutationObserver;if(this.checkVisibleState&&0==a.offsetWidth&&"undefined"!==typeof e){var k=this.getObservableParent(a),m=new e(mxUtils.bind(this,function(b){0<a.offsetWidth&&(m.disconnect(),d())}));m.observe(k,{attributes:!0})}else d()}};GraphViewer.prototype.getObservableParent=function(a){for(a=a.parentNode;a!=document.body&&null!=a.parentNode&&"none"!==mxUtils.getCurrentStyle(a).display;)a=a.parentNode;return a};
+window.WebKitMutationObserver||window.MozMutationObserver;if(this.checkVisibleState&&0==a.offsetWidth&&"undefined"!==typeof e){var k=this.getObservableParent(a),l=new e(mxUtils.bind(this,function(b){0<a.offsetWidth&&(l.disconnect(),d())}));l.observe(k,{attributes:!0})}else d()}};GraphViewer.prototype.getObservableParent=function(a){for(a=a.parentNode;a!=document.body&&null!=a.parentNode&&"none"!==mxUtils.getCurrentStyle(a).display;)a=a.parentNode;return a};
GraphViewer.prototype.getImageUrl=function(a){null!=a&&"http://"!=a.substring(0,7)&&"https://"!=a.substring(0,8)&&"data:image"!=a.substring(0,10)&&("/"==a.charAt(0)&&(a=a.substring(1,a.length)),a=this.imageBaseUrl+a);return a};GraphViewer.prototype.setXmlNode=function(a){a=this.editor.extractGraphModel(a,!0);this.xmlDocument=a.ownerDocument;this.xml=mxUtils.getXml(a);this.xmlNode=a;this.updateGraphXml(a);this.fireEvent(new mxEventObject("xmlNodeChanged"))};
GraphViewer.prototype.setFileNode=function(a){null==this.xmlNode&&(this.xmlDocument=a.ownerDocument,this.xml=mxUtils.getXml(a),this.xmlNode=a);this.setGraphXml(a)};GraphViewer.prototype.updateGraphXml=function(a){this.setGraphXml(a);this.fireEvent(new mxEventObject("graphChanged"))};
GraphViewer.prototype.setGraphXml=function(a){null!=this.graph&&(this.graph.view.translate=new mxPoint,this.graph.view.scale=1,this.graph.getModel().clear(),this.editor.setGraphXml(a),this.widthIsEmpty?(this.graph.container.style.width="",this.graph.container.style.height=""):this.graph.container.style.width=this.initialWidth,this.positionGraph(),this.graph.initialViewState={translate:this.graph.view.translate.clone(),scale:this.graph.view.scale})};
@@ -3636,27 +3636,27 @@ d="relative"===document.body.style.position?document.body.getBoundingClientRect(
this.toolbar&&(this.toolbar.style.width=Math.max(this.minToolbarWidth,a.offsetWidth)+"px");e=!1}}),k=null;this.handlingResize=!1;this.fitGraph=mxUtils.bind(this,function(b){var c=a.offsetWidth;c==k||this.handlingResize||(this.handlingResize=!0,"auto"==a.style.overflow&&(a.style.overflow="hidden"),this.graph.maxFitScale=null!=b?b:this.graphConfig.zoom||(this.allowZoomIn?null:1),this.graph.fit(null,null,null,null,null,!0),(this.center||0==this.graphConfig.resize&&""!=a.style.height)&&this.graph.center(),
this.graph.maxFitScale=null,0==this.graphConfig.resize&&""!=a.style.height||this.updateContainerHeight(a,Math.max(this.minHeight,this.graph.getGraphBounds().height+2*this.graph.border+1)),this.graph.initialViewState={translate:this.graph.view.translate.clone(),scale:this.graph.view.scale},k=c,window.setTimeout(mxUtils.bind(this,function(){this.handlingResize=!1}),0))});GraphViewer.useResizeSensor&&(mxClient.IS_QUIRKS||9>=document.documentMode?(mxEvent.addListener(window,"resize",d),this.graph.addListener("size",
d)):new ResizeSensor(this.graph.container,d));if(this.graphConfig.resize||(this.zoomEnabled||!this.autoFit)&&0!=this.graphConfig.resize)this.graph.minimumContainerSize=new mxRectangle(0,0,this.minWidth,this.minHeight),this.graph.resizeContainer=!0;else if(!this.widthIsEmpty||""!=a.style.height&&this.autoFit||this.updateContainerWidth(a,b.width+2*this.graph.border),0==this.graphConfig.resize&&""!=a.style.height||this.updateContainerHeight(a,Math.max(this.minHeight,b.height+2*this.graph.border+1)),
-!this.zoomEnabled&&this.autoFit){var m=k=null,d=mxUtils.bind(this,function(){window.clearTimeout(m);this.handlingResize||(m=window.setTimeout(mxUtils.bind(this,this.fitGraph),100))});GraphViewer.useResizeSensor&&(mxClient.IS_QUIRKS||9>=document.documentMode?mxEvent.addListener(window,"resize",d):new ResizeSensor(this.graph.container,d))}else mxClient.IS_QUIRKS||9>=document.documentMode||this.graph.addListener("size",d);var q=mxUtils.bind(this,function(){var c=a.style.minWidth;this.widthIsEmpty&&(a.style.minWidth=
+!this.zoomEnabled&&this.autoFit){var l=k=null,d=mxUtils.bind(this,function(){window.clearTimeout(l);this.handlingResize||(l=window.setTimeout(mxUtils.bind(this,this.fitGraph),100))});GraphViewer.useResizeSensor&&(mxClient.IS_QUIRKS||9>=document.documentMode?mxEvent.addListener(window,"resize",d):new ResizeSensor(this.graph.container,d))}else mxClient.IS_QUIRKS||9>=document.documentMode||this.graph.addListener("size",d);var q=mxUtils.bind(this,function(){var c=a.style.minWidth;this.widthIsEmpty&&(a.style.minWidth=
"100%");var d=null!=this.graphConfig["max-height"]?this.graphConfig["max-height"]:""!=a.style.height&&this.autoFit?a.offsetHeight:void 0;if(0<a.offsetWidth&&(this.allowZoomIn||b.width+2*this.graph.border>a.offsetWidth||b.height+2*this.graph.border>d)){var e=null;null!=d&&b.height+2*this.graph.border>d-2&&(e=(d-2*this.graph.border-2)/b.height);this.fitGraph(e)}else this.widthIsEmpty||0!=this.graphConfig.resize||""==a.style.height?(this.graph.view.setTranslate(Math.floor(this.graph.border-b.x/this.graph.view.scale),
Math.floor(this.graph.border-b.y/this.graph.view.scale)),k=a.offsetWidth):this.graph.center((!this.widthIsEmpty||b.width<this.minWidth)&&1!=this.graphConfig.resize);a.style.minWidth=c});mxClient.IS_QUIRKS||8==document.documentMode?window.setTimeout(q,0):q();this.positionGraph=function(){b=this.graph.getGraphBounds();k=null;q()}};GraphViewer.prototype.updateContainerWidth=function(a,b){a.style.width=b+"px"};
GraphViewer.prototype.updateContainerHeight=function(a,b){if(this.zoomEnabled||!this.autoFit||"BackCompat"==document.compatMode||mxClient.IS_QUIRKS||8==document.documentMode)a.style.height=b+"px"};
-GraphViewer.prototype.showLayers=function(a,b){var e=this.graphConfig.layers,e=null!=e?e.split(" "):[],d=this.graphConfig.layerIds,k=null!=d&&0<d.length;if(0<e.length||k||null!=b){var m=null!=b?b.getModel():null,q=a.getModel();q.beginUpdate();try{for(var c=q.getChildCount(q.root),f=0;f<c;f++)q.setVisible(q.getChildAt(q.root,f),null!=b?m.isVisible(m.getChildAt(m.root,f)):!1);if(null==m)if(k)for(f=0;f<d.length;f++)q.setVisible(q.getCell(d[f]),!0);else for(f=0;f<e.length;f++)q.setVisible(q.getChildAt(q.root,
+GraphViewer.prototype.showLayers=function(a,b){var e=this.graphConfig.layers,e=null!=e?e.split(" "):[],d=this.graphConfig.layerIds,k=null!=d&&0<d.length;if(0<e.length||k||null!=b){var l=null!=b?b.getModel():null,q=a.getModel();q.beginUpdate();try{for(var c=q.getChildCount(q.root),f=0;f<c;f++)q.setVisible(q.getChildAt(q.root,f),null!=b?l.isVisible(l.getChildAt(l.root,f)):!1);if(null==l)if(k)for(f=0;f<d.length;f++)q.setVisible(q.getCell(d[f]),!0);else for(f=0;f<e.length;f++)q.setVisible(q.getChildAt(q.root,
parseInt(e[f])),!0)}finally{q.endUpdate()}}};
GraphViewer.prototype.addToolbar=function(){function a(a,b,c,d){var f=document.createElement("div");f.style.borderRight="1px solid #d0d0d0";f.style.padding="3px 6px 3px 6px";mxEvent.addListener(f,"click",a);null!=c&&f.setAttribute("title",c);f.style.display=mxClient.IS_QUIRKS?"inline":"inline-block";a=document.createElement("img");a.setAttribute("border","0");a.setAttribute("src",b);null==d||d?(mxEvent.addListener(f,"mouseenter",function(){f.style.backgroundColor="#ddd"}),mxEvent.addListener(f,"mouseleave",
function(){f.style.backgroundColor="#eee"}),mxUtils.setOpacity(a,60),f.style.cursor="pointer"):mxUtils.setOpacity(f,30);f.appendChild(a);e.appendChild(f);p++;return f}var b=this.graph.container;"bottom"==this.graphConfig["toolbar-position"]?b.style.marginBottom=this.toolbarHeight+"px":"inline"!=this.graphConfig["toolbar-position"]&&(b.style.marginTop=this.toolbarHeight+"px");var e=b.ownerDocument.createElement("div");e.style.position="absolute";e.style.overflow="hidden";e.style.boxSizing="border-box";
-e.style.whiteSpace="nowrap";e.style.textAlign="left";e.style.zIndex=this.toolbarZIndex;e.style.backgroundColor="#eee";e.style.height=this.toolbarHeight+"px";this.toolbar=e;if("inline"==this.graphConfig["toolbar-position"]){mxUtils.setPrefixedStyle(e.style,"transition","opacity 100ms ease-in-out");mxUtils.setOpacity(e,30);var d=null,k=null,m=mxUtils.bind(this,function(a){null!=d&&(window.clearTimeout(d),fadeThead=null);null!=k&&(window.clearTimeout(k),fadeThead2=null);d=window.setTimeout(mxUtils.bind(this,
-function(){mxUtils.setOpacity(e,0);d=null;k=window.setTimeout(mxUtils.bind(this,function(){e.style.display="none";k=null}),100)}),a||200)}),q=mxUtils.bind(this,function(a){null!=d&&(window.clearTimeout(d),fadeThead=null);null!=k&&(window.clearTimeout(k),fadeThead2=null);e.style.display="";mxUtils.setOpacity(e,a||30)});mxEvent.addListener(this.graph.container,mxClient.IS_POINTER?"pointermove":"mousemove",mxUtils.bind(this,function(a){mxEvent.isTouchEvent(a)||(q(30),m())}));mxEvent.addListener(e,mxClient.IS_POINTER?
+e.style.whiteSpace="nowrap";e.style.textAlign="left";e.style.zIndex=this.toolbarZIndex;e.style.backgroundColor="#eee";e.style.height=this.toolbarHeight+"px";this.toolbar=e;if("inline"==this.graphConfig["toolbar-position"]){mxUtils.setPrefixedStyle(e.style,"transition","opacity 100ms ease-in-out");mxUtils.setOpacity(e,30);var d=null,k=null,l=mxUtils.bind(this,function(a){null!=d&&(window.clearTimeout(d),fadeThead=null);null!=k&&(window.clearTimeout(k),fadeThead2=null);d=window.setTimeout(mxUtils.bind(this,
+function(){mxUtils.setOpacity(e,0);d=null;k=window.setTimeout(mxUtils.bind(this,function(){e.style.display="none";k=null}),100)}),a||200)}),q=mxUtils.bind(this,function(a){null!=d&&(window.clearTimeout(d),fadeThead=null);null!=k&&(window.clearTimeout(k),fadeThead2=null);e.style.display="";mxUtils.setOpacity(e,a||30)});mxEvent.addListener(this.graph.container,mxClient.IS_POINTER?"pointermove":"mousemove",mxUtils.bind(this,function(a){mxEvent.isTouchEvent(a)||(q(30),l())}));mxEvent.addListener(e,mxClient.IS_POINTER?
"pointermove":"mousemove",function(a){mxEvent.consume(a)});mxEvent.addListener(e,"mouseenter",mxUtils.bind(this,function(a){q(100)}));mxEvent.addListener(e,"mousemove",mxUtils.bind(this,function(a){q(100);mxEvent.consume(a)}));mxEvent.addListener(e,"mouseleave",mxUtils.bind(this,function(a){mxEvent.isTouchEvent(a)||q(30)}));var c=this.graph,f=c.getTolerance();c.addMouseListener({startX:0,startY:0,scrollLeft:0,scrollTop:0,mouseDown:function(a,b){this.startX=b.getGraphX();this.startY=b.getGraphY();
-this.scrollLeft=c.container.scrollLeft;this.scrollTop=c.container.scrollTop},mouseMove:function(a,b){},mouseUp:function(a,b){mxEvent.isTouchEvent(b.getEvent())&&Math.abs(this.scrollLeft-c.container.scrollLeft)<f&&Math.abs(this.scrollTop-c.container.scrollTop)<f&&Math.abs(this.startX-b.getGraphX())<f&&Math.abs(this.startY-b.getGraphY())<f&&(0<parseFloat(e.style.opacity||0)?m():q(30))}})}for(var g=this.toolbarItems,p=0,l=null,n=null,v=0;v<g.length;v++){var t=g[v];if("pages"==t){n=b.ownerDocument.createElement("div");
+this.scrollLeft=c.container.scrollLeft;this.scrollTop=c.container.scrollTop},mouseMove:function(a,b){},mouseUp:function(a,b){mxEvent.isTouchEvent(b.getEvent())&&Math.abs(this.scrollLeft-c.container.scrollLeft)<f&&Math.abs(this.scrollTop-c.container.scrollTop)<f&&Math.abs(this.startX-b.getGraphX())<f&&Math.abs(this.startY-b.getGraphY())<f&&(0<parseFloat(e.style.opacity||0)?l():q(30))}})}for(var g=this.toolbarItems,p=0,m=null,n=null,v=0;v<g.length;v++){var t=g[v];if("pages"==t){n=b.ownerDocument.createElement("div");
n.style.cssText="display:inline-block;position:relative;padding:3px 4px 0 4px;vertical-align:top;font-family:Helvetica,Arial;font-size:12px;top:4px;cursor:default;";mxUtils.setOpacity(n,70);var u=a(mxUtils.bind(this,function(){this.selectPage(this.currentPage-1)}),Editor.previousImage,mxResources.get("previousPage")||"Previous Page");u.style.borderRightStyle="none";u.style.paddingLeft="0px";u.style.paddingRight="0px";e.appendChild(n);var A=a(mxUtils.bind(this,function(){this.selectPage(this.currentPage+
1)}),Editor.nextImage,mxResources.get("nextPage")||"Next Page");A.style.paddingLeft="0px";A.style.paddingRight="0px";t=mxUtils.bind(this,function(){n.innerHTML="";mxUtils.write(n,this.currentPage+1+" / "+this.diagrams.length);n.style.display=1<this.diagrams.length?"inline-block":"none";u.style.display=n.style.display;A.style.display=n.style.display});this.addListener("graphChanged",t);t()}else if("zoom"==t)this.zoomEnabled&&(a(mxUtils.bind(this,function(){this.graph.zoomOut()}),Editor.zoomOutImage,
-mxResources.get("zoomOut")||"Zoom Out"),a(mxUtils.bind(this,function(){this.graph.zoomIn()}),Editor.zoomInImage,mxResources.get("zoomIn")||"Zoom In"),a(mxUtils.bind(this,function(){this.graph.view.scaleAndTranslate(this.graph.initialViewState.scale,this.graph.initialViewState.translate.x,this.graph.initialViewState.translate.y)}),Editor.zoomFitImage,mxResources.get("fit")||"Fit"));else if("layers"==t){if(this.layersEnabled){var B=this.graph.getModel(),D=a(mxUtils.bind(this,function(a){if(null!=l)l.parentNode.removeChild(l),
-l=null;else{l=this.graph.createLayersDialog();mxEvent.addListener(l,"mouseleave",function(){l.parentNode.removeChild(l);l=null});a=D.getBoundingClientRect();l.style.width="140px";l.style.padding="2px 0px 2px 0px";l.style.border="1px solid #d0d0d0";l.style.backgroundColor="#eee";l.style.fontFamily="Helvetica Neue,Helvetica,Arial Unicode MS,Arial";l.style.fontSize="11px";l.style.zIndex=this.toolbarZIndex+1;mxUtils.setOpacity(l,80);var b=mxUtils.getDocumentScrollOrigin(document);l.style.left=b.x+a.left+
-"px";l.style.top=b.y+a.bottom+"px";document.body.appendChild(l)}}),Editor.layersImage,mxResources.get("layers")||"Layers");B.addListener(mxEvent.CHANGE,function(){D.style.display=1<B.getChildCount(B.root)?"inline-block":"none"});D.style.display=1<B.getChildCount(B.root)?"inline-block":"none"}}else"lightbox"==t?this.lightboxEnabled&&a(mxUtils.bind(this,function(){this.showLightbox()}),Editor.maximizeImage,mxResources.get("show")||"Show"):null!=this.graphConfig["toolbar-buttons"]&&(t=this.graphConfig["toolbar-buttons"][t],
+mxResources.get("zoomOut")||"Zoom Out"),a(mxUtils.bind(this,function(){this.graph.zoomIn()}),Editor.zoomInImage,mxResources.get("zoomIn")||"Zoom In"),a(mxUtils.bind(this,function(){this.graph.view.scaleAndTranslate(this.graph.initialViewState.scale,this.graph.initialViewState.translate.x,this.graph.initialViewState.translate.y)}),Editor.zoomFitImage,mxResources.get("fit")||"Fit"));else if("layers"==t){if(this.layersEnabled){var B=this.graph.getModel(),D=a(mxUtils.bind(this,function(a){if(null!=m)m.parentNode.removeChild(m),
+m=null;else{m=this.graph.createLayersDialog();mxEvent.addListener(m,"mouseleave",function(){m.parentNode.removeChild(m);m=null});a=D.getBoundingClientRect();m.style.width="140px";m.style.padding="2px 0px 2px 0px";m.style.border="1px solid #d0d0d0";m.style.backgroundColor="#eee";m.style.fontFamily="Helvetica Neue,Helvetica,Arial Unicode MS,Arial";m.style.fontSize="11px";m.style.zIndex=this.toolbarZIndex+1;mxUtils.setOpacity(m,80);var b=mxUtils.getDocumentScrollOrigin(document);m.style.left=b.x+a.left+
+"px";m.style.top=b.y+a.bottom+"px";document.body.appendChild(m)}}),Editor.layersImage,mxResources.get("layers")||"Layers");B.addListener(mxEvent.CHANGE,function(){D.style.display=1<B.getChildCount(B.root)?"inline-block":"none"});D.style.display=1<B.getChildCount(B.root)?"inline-block":"none"}}else"lightbox"==t?this.lightboxEnabled&&a(mxUtils.bind(this,function(){this.showLightbox()}),Editor.maximizeImage,mxResources.get("show")||"Show"):null!=this.graphConfig["toolbar-buttons"]&&(t=this.graphConfig["toolbar-buttons"][t],
null!=t&&a(null==t.enabled||t.enabled?t.handler:function(){},t.image,t.title,t.enabled))}null!=this.graph.minimumContainerSize&&(this.graph.minimumContainerSize.width=34*p);null!=this.graphConfig.title&&(g=b.ownerDocument.createElement("div"),g.style.cssText="display:inline-block;position:relative;padding:3px 6px 0 6px;vertical-align:top;font-family:Helvetica,Arial;font-size:12px;top:4px;cursor:default;",g.setAttribute("title",this.graphConfig.title),mxUtils.write(g,this.graphConfig.title),mxUtils.setOpacity(g,
70),e.appendChild(g),this.filename=g);this.minToolbarWidth=34*p;var C=b.style.border,g=mxUtils.bind(this,function(){e.style.width="inline"==this.graphConfig["toolbar-position"]?"auto":Math.max(this.minToolbarWidth,b.offsetWidth)+"px";e.style.border="1px solid #d0d0d0";if(1!=this.graphConfig["toolbar-nohide"]){var a=b.getBoundingClientRect(),c=mxUtils.getScrollOrigin(document.body),c="relative"===document.body.style.position?document.body.getBoundingClientRect():{left:-c.x,top:-c.y},a={left:a.left-
-c.left,top:a.top-c.top,bottom:a.bottom-c.top,right:a.right-c.left};e.style.left=a.left+"px";"bottom"==this.graphConfig["toolbar-position"]?e.style.top=a.bottom-1+"px":"inline"!=this.graphConfig["toolbar-position"]?(e.style.marginTop=-this.toolbarHeight+"px",e.style.top=a.top+1+"px"):e.style.top=a.top+"px";"1px solid transparent"==C&&(b.style.border="1px solid #d0d0d0");document.body.appendChild(e);var d=mxUtils.bind(this,function(){null!=e.parentNode&&e.parentNode.removeChild(e);null!=l&&(l.parentNode.removeChild(l),
-l=null);b.style.border=C});mxEvent.addListener(document,"mousemove",function(a){for(a=mxEvent.getSource(a);null!=a;){if(a==b||a==e||a==l)return;a=a.parentNode}d()});mxEvent.addListener(document,"mouseleave",function(a){d()})}else e.style.top=-this.toolbarHeight+"px",b.appendChild(e)});1!=this.graphConfig["toolbar-nohide"]?mxEvent.addListener(b,"mouseenter",g):g()};
+c.left,top:a.top-c.top,bottom:a.bottom-c.top,right:a.right-c.left};e.style.left=a.left+"px";"bottom"==this.graphConfig["toolbar-position"]?e.style.top=a.bottom-1+"px":"inline"!=this.graphConfig["toolbar-position"]?(e.style.marginTop=-this.toolbarHeight+"px",e.style.top=a.top+1+"px"):e.style.top=a.top+"px";"1px solid transparent"==C&&(b.style.border="1px solid #d0d0d0");document.body.appendChild(e);var d=mxUtils.bind(this,function(){null!=e.parentNode&&e.parentNode.removeChild(e);null!=m&&(m.parentNode.removeChild(m),
+m=null);b.style.border=C});mxEvent.addListener(document,"mousemove",function(a){for(a=mxEvent.getSource(a);null!=a;){if(a==b||a==e||a==m)return;a=a.parentNode}d()});mxEvent.addListener(document,"mouseleave",function(a){d()})}else e.style.top=-this.toolbarHeight+"px",b.appendChild(e)});1!=this.graphConfig["toolbar-nohide"]?mxEvent.addListener(b,"mouseenter",g):g()};
GraphViewer.prototype.addClickHandler=function(a,b){a.linkPolicy=this.graphConfig.target||a.linkPolicy;a.addClickHandler(this.graphConfig.highlight,mxUtils.bind(this,function(e,d){if(null==d){var k=mxEvent.getSource(e);"a"==k.nodeName.toLowerCase()&&(d=k.getAttribute("href"))}null!=b?null==d||a.isCustomLink(d)?mxEvent.consume(e):a.isExternalProtocol(d)||a.isBlankLink(d)||window.setTimeout(function(){b.destroy()},0):null!=d&&null==b&&a.isCustomLink(d)&&(mxEvent.isTouchEvent(e)||!mxEvent.isPopupTrigger(e))&&
a.customLinkClicked(d)&&mxEvent.consume(e)}),mxUtils.bind(this,function(a){null!=b||!this.lightboxClickEnabled||mxEvent.isTouchEvent(a)&&0!=this.toolbarItems.length||this.showLightbox()}))};
GraphViewer.prototype.showLightbox=function(a,b,e){if("open"==this.graphConfig.lightbox||window.self!==window.top)if(null==this.lightboxWindow||this.lightboxWindow.closed){a=null!=a?a:null!=this.graphConfig.editable?this.graphConfig.editable:!0;e={client:1,lightbox:1,target:null!=e?e:"blank"};a&&(e.edit=this.graphConfig.edit||"_blank");if(null!=b?b:1)e.close=1;this.layersEnabled&&(e.layers=1);null!=this.graphConfig&&0!=this.graphConfig.nav&&(e.nav=1);null!=this.graphConfig&&null!=this.graphConfig.highlight&&
@@ -3665,8 +3665,8 @@ e.drawdev="1",a="test.draw.io");this.lightboxWindow=window.open("https://"+a+"/#
GraphViewer.prototype.showLocalLightbox=function(){var a=mxUtils.getDocumentScrollOrigin(document),b=document.createElement("div");mxClient.IS_QUIRKS?(b.style.position="absolute",b.style.left=a.x+"px",b.style.top=a.y+"px",b.style.width=document.body.offsetWidth+"px",b.style.height=document.body.offsetHeight+"px"):b.style.cssText="position:fixed;top:0;left:0;bottom:0;right:0;";b.style.zIndex=this.lightboxZIndex;b.style.backgroundColor="#000000";mxUtils.setOpacity(b,70);document.body.appendChild(b);
var e=document.createElement("img");e.setAttribute("border","0");e.setAttribute("src",Editor.closeImage);mxClient.IS_QUIRKS?(e.style.position="absolute",e.style.right="32px",e.style.top=a.y+32+"px"):e.style.cssText="position:fixed;top:32px;right:32px;";e.style.cursor="pointer";mxEvent.addListener(e,"click",function(){k.destroy()});urlParams.pages="1";urlParams.page=this.currentPage;urlParams["page-id"]=this.graphConfig.pageId;urlParams["layer-ids"]=null!=this.graphConfig.layerIds&&0<this.graphConfig.layerIds.length?
this.graphConfig.layerIds.join(" "):null;urlParams.nav=0!=this.graphConfig.nav?"1":"0";urlParams.layers=this.layersEnabled?"1":"0";if(null==document.documentMode||10<=document.documentMode)Editor.prototype.editButtonLink=this.graphConfig.edit,Editor.prototype.editButtonFunc=this.graphConfig.editFunc;EditorUi.prototype.updateActionStates=function(){};EditorUi.prototype.addBeforeUnloadListener=function(){};EditorUi.prototype.addChromelessClickHandler=function(){};var d=Graph.prototype.shadowId;Graph.prototype.shadowId=
-"lightboxDropShadow";var k=new EditorUi(new Editor(!0),document.createElement("div"),!0);k.editor.editBlankUrl=this.editBlankUrl;k.editor.graph.shadowId="lightboxDropShadow";Graph.prototype.shadowId=d;k.refresh=function(){};var m=mxUtils.bind(this,function(a){27==a.keyCode&&k.destroy()}),q=k.destroy;k.destroy=function(){mxEvent.removeListener(document.documentElement,"keydown",m);document.body.removeChild(b);document.body.removeChild(e);document.body.style.overflow="auto";GraphViewer.resizeSensorEnabled=
-!0;q.apply(this,arguments)};var c=k.editor.graph,f=c.container;f.style.overflow="hidden";this.lightboxChrome?(f.style.border="1px solid #c0c0c0",f.style.margin="40px",mxEvent.addListener(document.documentElement,"keydown",m)):(b.style.display="none",e.style.display="none");var g=this;c.getImageFromBundles=function(a){return g.getImageUrl(a)};var p=k.createTemporaryGraph;k.createTemporaryGraph=function(){var a=p.apply(this,arguments);a.getImageFromBundles=function(a){return g.getImageUrl(a)};return a};
+"lightboxDropShadow";var k=new EditorUi(new Editor(!0),document.createElement("div"),!0);k.editor.editBlankUrl=this.editBlankUrl;k.editor.graph.shadowId="lightboxDropShadow";Graph.prototype.shadowId=d;k.refresh=function(){};var l=mxUtils.bind(this,function(a){27==a.keyCode&&k.destroy()}),q=k.destroy;k.destroy=function(){mxEvent.removeListener(document.documentElement,"keydown",l);document.body.removeChild(b);document.body.removeChild(e);document.body.style.overflow="auto";GraphViewer.resizeSensorEnabled=
+!0;q.apply(this,arguments)};var c=k.editor.graph,f=c.container;f.style.overflow="hidden";this.lightboxChrome?(f.style.border="1px solid #c0c0c0",f.style.margin="40px",mxEvent.addListener(document.documentElement,"keydown",l)):(b.style.display="none",e.style.display="none");var g=this;c.getImageFromBundles=function(a){return g.getImageUrl(a)};var p=k.createTemporaryGraph;k.createTemporaryGraph=function(){var a=p.apply(this,arguments);a.getImageFromBundles=function(a){return g.getImageUrl(a)};return a};
this.graphConfig.move&&(c.isMoveCellsEvent=function(a){return!0});mxClient.IS_QUIRKS||(mxUtils.setPrefixedStyle(f.style,"border-radius","4px"),f.style.position="fixed");GraphViewer.resizeSensorEnabled=!1;document.body.style.overflow="hidden";mxClient.IS_SF||mxClient.IS_EDGE||(mxUtils.setPrefixedStyle(f.style,"transform","rotateY(90deg)"),mxUtils.setPrefixedStyle(f.style,"transition","all .25s ease-in-out"));this.addClickHandler(c,k);window.setTimeout(mxUtils.bind(this,function(){f.style.outline="none";
f.style.zIndex=this.lightboxZIndex;e.style.zIndex=this.lightboxZIndex;document.body.appendChild(f);document.body.appendChild(e);k.setFileData(this.xml);mxUtils.setPrefixedStyle(f.style,"transform","rotateY(0deg)");k.chromelessToolbar.style.bottom="60px";k.chromelessToolbar.style.zIndex=this.lightboxZIndex;document.body.appendChild(k.chromelessToolbar);k.getEditBlankXml=mxUtils.bind(this,function(){return this.xml});mxClient.IS_QUIRKS&&(f.style.position="absolute",f.style.display="block",f.style.left=
a.x+"px",f.style.top=a.y+"px",f.style.width=document.body.clientWidth-80+"px",f.style.height=document.body.clientHeight-80+"px",f.style.backgroundColor="white",k.chromelessToolbar.style.display="block",k.chromelessToolbar.style.position="absolute",k.chromelessToolbar.style.bottom="",k.chromelessToolbar.style.top=a.y+document.body.clientHeight-100+"px");k.lightboxFit();k.chromelessResize();this.showLayers(c,this.graph);mxEvent.addListener(b,"click",function(){k.destroy()})}),0);return k};
@@ -3676,9 +3676,9 @@ GraphViewer.getElementsByClassName=function(a){if(document.getElementsByClassNam
GraphViewer.createViewerForElement=function(a,b){var e=a.getAttribute("data-mxgraph");if(null!=e){var d=JSON.parse(e),k=function(e){e=mxUtils.parseXml(e);e=new GraphViewer(a,e.documentElement,d);null!=b&&b(e)};null!=d.url?GraphViewer.getUrl(d.url,function(a){k(a)}):k(d.xml)}};
GraphViewer.initCss=function(){try{var a=document.createElement("style");a.type="text/css";a.innerHTML="div.mxTooltip {\n-webkit-box-shadow: 3px 3px 12px #C0C0C0;\n-moz-box-shadow: 3px 3px 12px #C0C0C0;\nbox-shadow: 3px 3px 12px #C0C0C0;\nbackground: #FFFFCC;\nborder-style: solid;\nborder-width: 1px;\nborder-color: black;\nfont-family: Arial;\nfont-size: 8pt;\nposition: absolute;\ncursor: default;\npadding: 4px;\ncolor: black;}\ntd.mxPopupMenuIcon div {\nwidth:16px;\nheight:16px;}\nhtml div.mxPopupMenu {\n-webkit-box-shadow:2px 2px 3px #d5d5d5;\n-moz-box-shadow:2px 2px 3px #d5d5d5;\nbox-shadow:2px 2px 3px #d5d5d5;\n_filter:progid:DXImageTransform.Microsoft.DropShadow(OffX=2, OffY=2, Color='#d0d0d0',Positive='true');\nbackground:white;\nposition:absolute;\nborder:3px solid #e7e7e7;\npadding:3px;}\nhtml table.mxPopupMenu {\nborder-collapse:collapse;\nmargin:0px;}\nhtml td.mxPopupMenuItem {\npadding:7px 30px 7px 30px;\nfont-family:Helvetica Neue,Helvetica,Arial Unicode MS,Arial;\nfont-size:10pt;}\nhtml td.mxPopupMenuIcon {\nbackground-color:white;\npadding:0px;}\ntd.mxPopupMenuIcon .geIcon {\npadding:2px;\npadding-bottom:4px;\nmargin:2px;\nborder:1px solid transparent;\nopacity:0.5;\n_width:26px;\n_height:26px;}\ntd.mxPopupMenuIcon .geIcon:hover {\nborder:1px solid gray;\nborder-radius:2px;\nopacity:1;}\nhtml tr.mxPopupMenuItemHover {\nbackground-color: #eeeeee;\ncolor: black;}\ntable.mxPopupMenu hr {\ncolor:#cccccc;\nbackground-color:#cccccc;\nborder:none;\nheight:1px;}\ntable.mxPopupMenu tr {\tfont-size:4pt;}\n.geDialog { font-family:Helvetica Neue,Helvetica,Arial Unicode MS,Arial;\nfont-size:10pt;\nborder:none;\nmargin:0px;}\n.geDialog {\tposition:absolute;\tbackground:white;\toverflow:hidden;\tpadding:30px;\tborder:1px solid #acacac;\t-webkit-box-shadow:0px 0px 2px 2px #d5d5d5;\t-moz-box-shadow:0px 0px 2px 2px #d5d5d5;\tbox-shadow:0px 0px 2px 2px #d5d5d5;\t_filter:progid:DXImageTransform.Microsoft.DropShadow(OffX=2, OffY=2, Color='#d5d5d5', Positive='true');\tz-index: 2;}.geDialogClose {\tposition:absolute;\twidth:9px;\theight:9px;\topacity:0.5;\tcursor:pointer;\t_filter:alpha(opacity=50);}.geDialogClose:hover {\topacity:1;}.geDialogTitle {\tbox-sizing:border-box;\twhite-space:nowrap;\tbackground:rgb(229, 229, 229);\tborder-bottom:1px solid rgb(192, 192, 192);\tfont-size:15px;\tfont-weight:bold;\ttext-align:center;\tcolor:rgb(35, 86, 149);}.geDialogFooter {\tbackground:whiteSmoke;\twhite-space:nowrap;\ttext-align:right;\tbox-sizing:border-box;\tborder-top:1px solid #e5e5e5;\tcolor:darkGray;}\n.geBtn {\tbackground-color: #f5f5f5;\tborder-radius: 2px;\tborder: 1px solid #d8d8d8;\tcolor: #333;\tcursor: default;\tfont-size: 11px;\tfont-weight: bold;\theight: 29px;\tline-height: 27px;\tmargin: 0 0 0 8px;\tmin-width: 72px;\toutline: 0;\tpadding: 0 8px;\tcursor: pointer;}.geBtn:hover, .geBtn:focus {\t-webkit-box-shadow: 0px 1px 1px rgba(0,0,0,0.1);\t-moz-box-shadow: 0px 1px 1px rgba(0,0,0,0.1);\tbox-shadow: 0px 1px 1px rgba(0,0,0,0.1);\tborder: 1px solid #c6c6c6;\tbackground-color: #f8f8f8;\tbackground-image: linear-gradient(#f8f8f8 0px,#f1f1f1 100%);\tcolor: #111;}.geBtn:disabled {\topacity: .5;}.gePrimaryBtn {\tbackground-color: #4d90fe;\tbackground-image: linear-gradient(#4d90fe 0px,#4787ed 100%);\tborder: 1px solid #3079ed;\tcolor: #fff;}.gePrimaryBtn:hover, .gePrimaryBtn:focus {\tbackground-color: #357ae8;\tbackground-image: linear-gradient(#4d90fe 0px,#357ae8 100%);\tborder: 1px solid #2f5bb7;\tcolor: #fff;}.gePrimaryBtn:disabled {\topacity: .5;}";document.getElementsByTagName("head")[0].appendChild(a)}catch(b){}};
GraphViewer.cachedUrls={};GraphViewer.getUrl=function(a,b,e){if(null!=GraphViewer.cachedUrls[a])b(GraphViewer.cachedUrls[a]);else{var d=null!=navigator.userAgent&&0<navigator.userAgent.indexOf("MSIE 9")?new XDomainRequest:new XMLHttpRequest;d.open("GET",a);d.onload=function(){b(null!=d.getText?d.getText():d.responseText)};d.onerror=e;d.send()}};GraphViewer.resizeSensorEnabled=!0;GraphViewer.useResizeSensor=!0;
-(function(){var a=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||function(a){return window.setTimeout(a,20)},b=function(e,d){function k(){this.q=[];this.add=function(a){this.q.push(a)};var a,b;this.call=function(){a=0;for(b=this.q.length;a<b;a++)this.q[a].call()}}function m(a,b){return a.currentStyle?a.currentStyle[b]:window.getComputedStyle?window.getComputedStyle(a,null).getPropertyValue(b):a.style[b]}function q(b,c){if(!b.resizedAttached)b.resizedAttached=
+(function(){var a=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||function(a){return window.setTimeout(a,20)},b=function(e,d){function k(){this.q=[];this.add=function(a){this.q.push(a)};var a,b;this.call=function(){a=0;for(b=this.q.length;a<b;a++)this.q[a].call()}}function l(a,b){return a.currentStyle?a.currentStyle[b]:window.getComputedStyle?window.getComputedStyle(a,null).getPropertyValue(b):a.style[b]}function q(b,c){if(!b.resizedAttached)b.resizedAttached=
new k,b.resizedAttached.add(c);else if(b.resizedAttached){b.resizedAttached.add(c);return}b.resizeSensor=document.createElement("div");b.resizeSensor.className="resize-sensor";b.resizeSensor.style.cssText="position: absolute; left: 0; top: 0; right: 0; bottom: 0; overflow: hidden; z-index: -1; visibility: hidden;";b.resizeSensor.innerHTML='<div class="resize-sensor-expand" style="position: absolute; left: 0; top: 0; right: 0; bottom: 0; overflow: hidden; z-index: -1; visibility: hidden;"><div style="position: absolute; left: 0; top: 0; transition: 0s;"></div></div><div class="resize-sensor-shrink" style="position: absolute; left: 0; top: 0; right: 0; bottom: 0; overflow: hidden; z-index: -1; visibility: hidden;"><div style="position: absolute; left: 0; top: 0; transition: 0s; width: 200%; height: 200%"></div></div>';
-b.appendChild(b.resizeSensor);"static"==m(b,"position")&&(b.style.position="relative");var d=b.resizeSensor.childNodes[0],e=d.childNodes[0],f=b.resizeSensor.childNodes[1],g=function(){e.style.width="100000px";e.style.height="100000px";d.scrollLeft=1E5;d.scrollTop=1E5;f.scrollLeft=1E5;f.scrollTop=1E5};g();var l=!1,n=function(){b.resizedAttached&&(l&&(b.resizedAttached.call(),l=!1),a(n))};a(n);var p,q,F,G,E=function(){if((F=b.offsetWidth)!=p||(G=b.offsetHeight)!=q)l=!0,p=F,q=G;g()},J=function(a,b,c){a.attachEvent?
+b.appendChild(b.resizeSensor);"static"==l(b,"position")&&(b.style.position="relative");var d=b.resizeSensor.childNodes[0],e=d.childNodes[0],f=b.resizeSensor.childNodes[1],g=function(){e.style.width="100000px";e.style.height="100000px";d.scrollLeft=1E5;d.scrollTop=1E5;f.scrollLeft=1E5;f.scrollTop=1E5};g();var m=!1,n=function(){b.resizedAttached&&(m&&(b.resizedAttached.call(),m=!1),a(n))};a(n);var p,q,F,G,E=function(){if((F=b.offsetWidth)!=p||(G=b.offsetHeight)!=q)m=!0,p=F,q=G;g()},J=function(a,b,c){a.attachEvent?
a.attachEvent("on"+b,c):a.addEventListener(b,c)};J(d,"scroll",E);J(f,"scroll",E)}var c=function(){GraphViewer.resizeSensorEnabled&&d()},f=Object.prototype.toString.call(e),g="[object Array]"===f||"[object NodeList]"===f||"[object HTMLCollection]"===f||"undefined"!==typeof jQuery&&e instanceof jQuery||"undefined"!==typeof Elements&&e instanceof Elements;if(g)for(var f=0,p=e.length;f<p;f++)q(e[f],c);else q(e,c);this.detach=function(){if(g)for(var a=0,c=e.length;a<c;a++)b.detach(e[a]);else b.detach(e)}};
b.detach=function(a){a.resizeSensor&&(a.removeChild(a.resizeSensor),delete a.resizeSensor,delete a.resizedAttached)};window.ResizeSensor=b})();
(function(){Editor.initMath();GraphViewer.initCss();if(null!=window.onDrawioViewerLoad)window.onDrawioViewerLoad();else GraphViewer.processElements()})();
diff --git a/src/main/webapp/service-worker.js b/src/main/webapp/service-worker.js
index 94c61de8..6c001d0a 100644
--- a/src/main/webapp/service-worker.js
+++ b/src/main/webapp/service-worker.js
@@ -6,7 +6,7 @@ if (workbox)
workbox.precaching.precacheAndRoute([
{
"url": "js/app.min.js",
- "revision": "31ef97ea7228e3d7ceb877ee7fe69503"
+ "revision": "8f905199962cb01eba11ac54b40cd630"
},
{
"url": "js/extensions.min.js",