diff --git a/ChangeLog b/ChangeLog
index 8d528a0b6adfbc4e1d436fab7e13168a1c51a650..e98a57f58fa2c011dee1c08153985e3147bccf25 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+12-JUN-2017: 6.7.9
+
+- Adds css, default styles, libraries to Editor.configure
+- Moves persistent settings to EditorUi.init
+- Fixes image export for (var)phi in ASCIIMathML
+
 08-JUN-2017: 6.7.8
 
 - Fixes saving local files in MS Edge
diff --git a/VERSION b/VERSION
index d3b88f2f36a7c2da53850507a3465617407995af..fbc4904f56abc9b3345ee4e9a7d8fead221acd7c 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-6.7.8
\ No newline at end of file
+6.7.9
\ No newline at end of file
diff --git a/src/com/mxgraph/io/gliffy/model/GliffyObject.java b/src/com/mxgraph/io/gliffy/model/GliffyObject.java
index 1343be841e722b007564719eae878e7a5fdc1b90..66252d4af21dda0ad174d744ba80c4b412ed8d39 100644
--- a/src/com/mxgraph/io/gliffy/model/GliffyObject.java
+++ b/src/com/mxgraph/io/gliffy/model/GliffyObject.java
@@ -1,63 +1,39 @@
 package com.mxgraph.io.gliffy.model;
 
+import java.util.Comparator;
 import java.util.HashSet;
 import java.util.List;
 import java.util.Set;
 
+import com.mxgraph.io.gliffy.importer.PostDeserializer.PostDeserializable;
 import com.mxgraph.model.mxCell;
 
 /**
  * Class representing Gliffy diagram object
  * 
  */
-public class GliffyObject
+public class GliffyObject implements PostDeserializable
 {
-	public static String SWIMLANE = "com.gliffy.shape.swimlanes.swimlanes_v1.default";
-
-	public static String V_SWIMLANE = "com.gliffy.shape.swimlanes.swimlanes_v1.default.vertical";
-
-	public static String H_SWIMLANE = "com.gliffy.shape.swimlanes.swimlanes_v1.default.horizontal";
-
-	public static String H_SINGLE_SWIMLANE = "com.gliffy.shape.swimlanes.swimlanes_v1.default.horizontal_single_lane_pool";
-
-	public static String V_SINGLE_SWIMLANE = "com.gliffy.shape.swimlanes.swimlanes_v1.default.vertical_single_lane_pool";
-
 	private static Set<String> GRAPHICLESS_SHAPES = new HashSet<String>();
-
 	private static Set<String> GROUP_SHAPES = new HashSet<String>();
-	
 	private static Set<String> MINDMAP_SHAPES = new HashSet<>();
 
 	public float x;
-
 	public float y;
-
 	public int id;
-
 	public float width;
-
 	public float height;
-
 	public float rotation;
-
 	public String uid;
-	
 	public String tid;
-
 	public String order;
-
 	public boolean lockshape;
-
 	public Graphic graphic;
-
 	public List<GliffyObject> children;
-
 	public Constraints constraints;
-	
 	public List<LinkMap> linkMap;
 
 	public mxCell mxObject;// the mxCell this gliffy object got converted into
-
 	public GliffyObject parent = null;
 
 	static
@@ -242,7 +218,7 @@ public class GliffyObject
 
 	public boolean isSwimlane()
 	{
-		return uid != null && uid.startsWith(SWIMLANE);
+		return uid != null && uid.contains("com.gliffy.shape.swimlanes");
 	}
 
 	public boolean isText()
@@ -325,4 +301,59 @@ public class GliffyObject
 	{
 		return uid != null ? uid : tid;
 	}
+
+	@Override
+	public void postDeserialize() {
+		if(isGroup())
+			normalizeChildrenCoordinates();
+	}
+	
+	/**
+	 * Some Gliffy diagrams have groups whose children have negative coordinates.
+	 * This is a problem in draw.io as they get set to 0.
+	 * This method expands the groups left and up and adjusts children's coordinates so that they are never less than zero.
+	 */
+	private void normalizeChildrenCoordinates() {
+		//sorts the list to find the leftmost child and it's X
+		Comparator<GliffyObject> cx = new Comparator<GliffyObject>() {
+			@Override
+			public int compare(GliffyObject o1, GliffyObject o2) {
+				return (int)(o1.x - o2.x);
+			}
+		};
+		 
+		children.sort(cx);
+		float xMin = children.get(0).x;
+		
+		if(xMin < 0) 
+		{
+			width += -xMin; //increase width
+			x += xMin;
+			
+			for(GliffyObject child : children) //increase x 
+				child.x += -xMin;  
+		}
+		
+		//sorts the list to find the leftmost child and it's Y
+		Comparator<GliffyObject> cy = new Comparator<GliffyObject>() {
+			@Override
+			public int compare(GliffyObject o1, GliffyObject o2) {
+				return (int)(o1.y - o2.y);
+			}
+		};
+		 
+		children.sort(cy);
+		float yMin = children.get(0).y;
+		
+		if(yMin < 0) 
+		{
+			height += -yMin; //increase height
+			y += yMin;
+			
+			for(GliffyObject child : children) //increase y 
+				child.y += -yMin;  
+		}
+	}
+	
+	
 }
diff --git a/war/WEB-INF/lib/mxgraph-core.jar b/war/WEB-INF/lib/mxgraph-core.jar
index 67a3d698b86e52f36e0df7cc9309e59099f83748..2f5967882c7fe31622acf9355650b9b6179074a7 100644
Binary files a/war/WEB-INF/lib/mxgraph-core.jar and b/war/WEB-INF/lib/mxgraph-core.jar differ
diff --git a/war/cache.manifest b/war/cache.manifest
index f8521ed3f8759a497a271c7068de3cb366c057f3..1806f4f715486d04f3c1569a48e7b9d7bcd0696b 100644
--- a/war/cache.manifest
+++ b/war/cache.manifest
@@ -1,7 +1,7 @@
 CACHE MANIFEST
 
 # THIS FILE WAS GENERATED. DO NOT MODIFY!
-# 06/08/2017 03:21 PM
+# 06/12/2017 03:01 PM
 
 app.html
 index.html?offline=1
diff --git a/war/export2.html b/war/export2.html
index 830eb9cbb55ed3bc3984a29542ddd32450b0077e..8b8237bc32d9d46f5b627634fe563a105207ea23 100644
--- a/war/export2.html
+++ b/war/export2.html
@@ -24,6 +24,35 @@
 		// NOTE: SVG Output fixes missing symbols in AsciiMath
 		// but produces larger output with clipping problems
 		Editor.initMath();
+	
+		// Workaround for varphi vs. phi export in MathJax on Phantom
+		// see https://github.com/mathjax/MathJax/issues/353
+		(function()
+		{
+			var authInit = MathJax.AuthorInit;
+	
+			MathJax.AuthorInit = function()
+			{
+				authInit();
+				
+				MathJax.Hub.Register.StartupHook('AsciiMath Jax Config', function()
+				{
+					var symbols = MathJax.InputJax.AsciiMath.AM.symbols;
+					
+					for (var i = 0, m = symbols.length; i < m; i++)
+					{
+				    	if (symbols[i].input === 'phi')
+				    	{
+				    		symbols[i].output = '\u03C6'
+				    	}
+				    	else if (symbols[i].input === 'varphi')
+				    	{
+				    		symbols[i].output = '\u03D5'; i = m
+				    	}
+				  	}
+				});
+			};
+		})();
 
 		function render(data)
 		{
diff --git a/war/js/app.min.js b/war/js/app.min.js
index 6e8d455e518e88fbb3903c377e2c6abab73e0bdc..061ef1cdd409e80f8bd19c293536fa602c20ff1a 100644
--- a/war/js/app.min.js
+++ b/war/js/app.min.js
@@ -2347,26 +2347,26 @@ d.width,d.y),!1)):f==mxConstants.DIRECTION_SOUTH?(d.height=e,d.y=k.y+k.height,d.
 d.width/2+e:f==mxConstants.DIRECTION_SOUTH?d.y=d.y+k.height/2+d.height/2+e:f==mxConstants.DIRECTION_WEST&&(d.x=d.x-k.width/2-d.width/2-e),b.model.isEdge(c)&&null!=d.getTerminalPoint(!0)&&null!=c.getTerminal(!1)&&(k=b.getCellGeometry(c.getTerminal(!1)),null!=k&&(f==mxConstants.DIRECTION_NORTH?(d.x-=k.getCenterX(),d.y-=k.getCenterY()+k.height/2):f==mxConstants.DIRECTION_EAST?(d.x-=k.getCenterX()-k.width/2,d.y-=k.getCenterY()):f==mxConstants.DIRECTION_SOUTH?(d.x-=k.getCenterX(),d.y-=k.getCenterY()-k.height/
 2):f==mxConstants.DIRECTION_WEST&&(d.x-=k.getCenterX()+k.width/2,d.y-=k.getCenterY()))))));return d};
 Sidebar.prototype.createDragSource=function(a,c,f,d,b){function e(b,a){var d;mxClient.IS_IE&&!mxClient.IS_SVG?(mxClient.IS_IE6&&"CSS1Compat"!=document.compatMode?(d=document.createElement(mxClient.VML_PREFIX+":image"),d.setAttribute("src",b.src),d.style.borderStyle="none"):(d=document.createElement("div"),d.style.backgroundImage="url("+b.src+")",d.style.backgroundPosition="center",d.style.backgroundRepeat="no-repeat"),d.style.width=b.width+4+"px",d.style.height=b.height+4+"px",d.style.display=mxClient.IS_QUIRKS?
-"inline":"inline-block"):(d=mxUtils.createImage(b.src),d.style.width=b.width+"px",d.style.height=b.height+"px");null!=a&&d.setAttribute("title",a);mxUtils.setOpacity(d,b==this.refreshTarget?30:20);d.style.position="absolute";d.style.cursor="crosshair";return d}function g(b,a,d,c){null!=c.parentNode&&(mxUtils.contains(d,b,a)?(mxUtils.setOpacity(c,100),I=c):mxUtils.setOpacity(c,c==F?30:20));return d}for(var k=this.editorUi,l=k.editor.graph,m=null,n=null,p=this,q=0;q<d.length&&(null==n&&this.editorUi.editor.graph.model.isVertex(d[q])?
+"inline":"inline-block"):(d=mxUtils.createImage(b.src),d.style.width=b.width+"px",d.style.height=b.height+"px");null!=a&&d.setAttribute("title",a);mxUtils.setOpacity(d,b==this.refreshTarget?30:20);d.style.position="absolute";d.style.cursor="crosshair";return d}function g(b,a,d,e){null!=e.parentNode&&(mxUtils.contains(d,b,a)?(mxUtils.setOpacity(e,100),I=e):mxUtils.setOpacity(e,e==F?30:20));return d}for(var k=this.editorUi,l=k.editor.graph,m=null,n=null,p=this,q=0;q<d.length&&(null==n&&this.editorUi.editor.graph.model.isVertex(d[q])?
 n=q:null==m&&this.editorUi.editor.graph.model.isEdge(d[q])&&null==this.editorUi.editor.graph.model.getTerminal(d[q],!0)&&(m=q),null==n||null==m);q++);var t=mxUtils.makeDraggable(a,this.editorUi.editor.graph,mxUtils.bind(this,function(b,a,e,f,g){null!=this.updateThread&&window.clearTimeout(this.updateThread);if(null!=d&&null!=z&&I==F){var k=b.isCellSelected(z.cell)?b.getSelectionCells():[z.cell],k=this.updateShapes(b.model.isEdge(z.cell)?d[0]:d[n],k);b.setSelectionCells(k)}else null!=d&&null!=I&&null!=
 v&&I!=F?(k=b.model.isEdge(v.cell)||null==m?n:m,b.setSelectionCells(this.dropAndConnect(v.cell,d,J,k))):c.apply(this,arguments);null!=this.editorUi.hoverIcons&&this.editorUi.hoverIcons.update(b.view.getState(b.getSelectionCell()))}),f,0,0,this.editorUi.editor.graph.autoscroll,!0,!0);this.editorUi.editor.graph.addListener(mxEvent.ESCAPE,function(b,a){t.isActive()&&t.reset()});var u=t.mouseDown;t.mouseDown=function(b){mxEvent.isPopupTrigger(b)||mxEvent.isMultiTouchEvent(b)||(l.stopEditing(),u.apply(this,
 arguments))};var v=null,x=null,z=null,A=!1,B=e(this.triangleUp,mxResources.get("connect")),y=e(this.triangleRight,mxResources.get("connect")),E=e(this.triangleDown,mxResources.get("connect")),D=e(this.triangleLeft,mxResources.get("connect")),F=e(this.refreshTarget,mxResources.get("replace")),C=null,K=e(this.roundDrop),G=e(this.roundDrop),J=mxConstants.DIRECTION_NORTH,I=null,L=t.createPreviewElement;t.createPreviewElement=function(b){var a=L.apply(this,arguments);mxClient.IS_SVG&&(a.style.pointerEvents=
-"none");this.previewElementWidth=a.style.width;this.previewElementHeight=a.style.height;return a};var M=t.dragEnter;t.dragEnter=function(b,a){null!=k.hoverIcons&&k.hoverIcons.setDisplay("none");M.apply(this,arguments)};var Q=t.dragExit;t.dragExit=function(b,a){null!=k.hoverIcons&&k.hoverIcons.setDisplay("");Q.apply(this,arguments)};t.dragOver=function(a,c){mxDragSource.prototype.dragOver.apply(this,arguments);null!=this.currentGuide&&null!=I&&this.currentGuide.hide();if(null!=this.previewElement){var e=
-a.view;if(null!=z&&I==F)this.previewElement.style.display=a.model.isEdge(z.cell)?"none":"",this.previewElement.style.left=z.x+"px",this.previewElement.style.top=z.y+"px",this.previewElement.style.width=z.width+"px",this.previewElement.style.height=z.height+"px";else if(null!=v&&null!=I){var f=a.model.isEdge(v.cell)||null==m?n:m,g=p.getDropAndConnectGeometry(v.cell,d[f],J,d),k=a.model.isEdge(v.cell)?null:a.getCellGeometry(v.cell),l=a.getCellGeometry(d[f]),q=a.model.getParent(v.cell),u=e.translate.x*
-e.scale,x=e.translate.y*e.scale;null!=k&&!k.relative&&a.model.isVertex(q)&&(x=e.getState(q),u=x.x,x=x.y);k=l.x;l=l.y;a.model.isEdge(d[f])&&(l=k=0);this.previewElement.style.left=(g.x-k)*e.scale+u+"px";this.previewElement.style.top=(g.y-l)*e.scale+x+"px";1==d.length&&(this.previewElement.style.width=g.width*e.scale+"px",this.previewElement.style.height=g.height*e.scale+"px");this.previewElement.style.display=""}else null!=t.currentHighlight.state&&a.model.isEdge(t.currentHighlight.state.cell)?(this.previewElement.style.left=
-Math.round(parseInt(this.previewElement.style.left)-b.width*e.scale/2)+"px",this.previewElement.style.top=Math.round(parseInt(this.previewElement.style.top)-b.height*e.scale/2)+"px"):(this.previewElement.style.width=this.previewElementWidth,this.previewElement.style.height=this.previewElementHeight,this.previewElement.style.display="")}};var W=(new Date).getTime(),N=0,H=null,V=this.editorUi.editor.graph.getCellStyle(d[0]);t.getDropTarget=mxUtils.bind(this,function(b,a,c,e){var f=mxEvent.isAltDown(e)||
-null==d?null:b.getCellAt(a,c);if(null!=f&&!this.graph.isCellConnectable(f)){var k=this.graph.getModel().getParent(f);this.graph.getModel().isVertex(k)&&this.graph.isCellConnectable(k)&&(f=k)}b.isCellLocked(f)&&(f=null);var l=b.view.getState(f),k=I=null;H!=l?(H=l,W=(new Date).getTime(),N=0,null!=this.updateThread&&window.clearTimeout(this.updateThread),null!=l&&(this.updateThread=window.setTimeout(function(){null==I&&(H=l,t.getDropTarget(b,a,c,e))},this.dropTargetDelay+10))):N=(new Date).getTime()-
-W;if(2500>N&&null!=l&&!mxEvent.isShiftDown(e)&&(mxUtils.getValue(l.style,mxConstants.STYLE_SHAPE)!=mxUtils.getValue(V,mxConstants.STYLE_SHAPE)&&mxUtils.getValue(l.style,mxConstants.STYLE_STROKECOLOR,mxConstants.NONE)!=mxConstants.NONE||"image"==mxUtils.getValue(V,mxConstants.STYLE_SHAPE)||1500<N||b.model.isEdge(l.cell))&&N>this.dropTargetDelay&&(b.model.isVertex(l.cell)&&null!=n||b.model.isEdge(l.cell)&&b.model.isEdge(d[0]))){z=l;var m=b.model.isEdge(l.cell)?b.view.getPoint(l):new mxPoint(l.getCenterX(),
-l.getCenterY()),m=new mxRectangle(m.x-this.refreshTarget.width/2,m.y-this.refreshTarget.height/2,this.refreshTarget.width,this.refreshTarget.height);F.style.left=Math.floor(m.x)+"px";F.style.top=Math.floor(m.y)+"px";null==C&&(b.container.appendChild(F),C=F.parentNode);g(a,c,m,F)}else null==z||!mxUtils.contains(z,a,c)||1500<N&&!mxEvent.isShiftDown(e)?(z=null,null!=C&&(F.parentNode.removeChild(F),C=null)):null!=z&&null!=C&&(m=b.model.isEdge(z.cell)?b.view.getPoint(z):new mxPoint(z.getCenterX(),z.getCenterY()),
-m=new mxRectangle(m.x-this.refreshTarget.width/2,m.y-this.refreshTarget.height/2,this.refreshTarget.width,this.refreshTarget.height),g(a,c,m,F));if(A&&null!=v&&!mxEvent.isAltDown(e)&&null==I){k=mxRectangle.fromRectangle(v);if(b.model.isEdge(v.cell)){var p=v.absolutePoints;null!=K.parentNode&&(m=p[0],k.add(g(a,c,new mxRectangle(m.x-this.roundDrop.width/2,m.y-this.roundDrop.height/2,this.roundDrop.width,this.roundDrop.height),K)));null!=G.parentNode&&(p=p[p.length-1],k.add(g(a,c,new mxRectangle(p.x-
+"none");this.previewElementWidth=a.style.width;this.previewElementHeight=a.style.height;return a};var M=t.dragEnter;t.dragEnter=function(b,a){null!=k.hoverIcons&&k.hoverIcons.setDisplay("none");M.apply(this,arguments)};var Q=t.dragExit;t.dragExit=function(b,a){null!=k.hoverIcons&&k.hoverIcons.setDisplay("");Q.apply(this,arguments)};t.dragOver=function(a,e){mxDragSource.prototype.dragOver.apply(this,arguments);null!=this.currentGuide&&null!=I&&this.currentGuide.hide();if(null!=this.previewElement){var c=
+a.view;if(null!=z&&I==F)this.previewElement.style.display=a.model.isEdge(z.cell)?"none":"",this.previewElement.style.left=z.x+"px",this.previewElement.style.top=z.y+"px",this.previewElement.style.width=z.width+"px",this.previewElement.style.height=z.height+"px";else if(null!=v&&null!=I){var f=a.model.isEdge(v.cell)||null==m?n:m,g=p.getDropAndConnectGeometry(v.cell,d[f],J,d),k=a.model.isEdge(v.cell)?null:a.getCellGeometry(v.cell),l=a.getCellGeometry(d[f]),q=a.model.getParent(v.cell),u=c.translate.x*
+c.scale,x=c.translate.y*c.scale;null!=k&&!k.relative&&a.model.isVertex(q)&&(x=c.getState(q),u=x.x,x=x.y);k=l.x;l=l.y;a.model.isEdge(d[f])&&(l=k=0);this.previewElement.style.left=(g.x-k)*c.scale+u+"px";this.previewElement.style.top=(g.y-l)*c.scale+x+"px";1==d.length&&(this.previewElement.style.width=g.width*c.scale+"px",this.previewElement.style.height=g.height*c.scale+"px");this.previewElement.style.display=""}else null!=t.currentHighlight.state&&a.model.isEdge(t.currentHighlight.state.cell)?(this.previewElement.style.left=
+Math.round(parseInt(this.previewElement.style.left)-b.width*c.scale/2)+"px",this.previewElement.style.top=Math.round(parseInt(this.previewElement.style.top)-b.height*c.scale/2)+"px"):(this.previewElement.style.width=this.previewElementWidth,this.previewElement.style.height=this.previewElementHeight,this.previewElement.style.display="")}};var W=(new Date).getTime(),N=0,H=null,V=this.editorUi.editor.graph.getCellStyle(d[0]);t.getDropTarget=mxUtils.bind(this,function(b,a,e,c){var f=mxEvent.isAltDown(c)||
+null==d?null:b.getCellAt(a,e);if(null!=f&&!this.graph.isCellConnectable(f)){var k=this.graph.getModel().getParent(f);this.graph.getModel().isVertex(k)&&this.graph.isCellConnectable(k)&&(f=k)}b.isCellLocked(f)&&(f=null);var l=b.view.getState(f),k=I=null;H!=l?(H=l,W=(new Date).getTime(),N=0,null!=this.updateThread&&window.clearTimeout(this.updateThread),null!=l&&(this.updateThread=window.setTimeout(function(){null==I&&(H=l,t.getDropTarget(b,a,e,c))},this.dropTargetDelay+10))):N=(new Date).getTime()-
+W;if(2500>N&&null!=l&&!mxEvent.isShiftDown(c)&&(mxUtils.getValue(l.style,mxConstants.STYLE_SHAPE)!=mxUtils.getValue(V,mxConstants.STYLE_SHAPE)&&mxUtils.getValue(l.style,mxConstants.STYLE_STROKECOLOR,mxConstants.NONE)!=mxConstants.NONE||"image"==mxUtils.getValue(V,mxConstants.STYLE_SHAPE)||1500<N||b.model.isEdge(l.cell))&&N>this.dropTargetDelay&&(b.model.isVertex(l.cell)&&null!=n||b.model.isEdge(l.cell)&&b.model.isEdge(d[0]))){z=l;var m=b.model.isEdge(l.cell)?b.view.getPoint(l):new mxPoint(l.getCenterX(),
+l.getCenterY()),m=new mxRectangle(m.x-this.refreshTarget.width/2,m.y-this.refreshTarget.height/2,this.refreshTarget.width,this.refreshTarget.height);F.style.left=Math.floor(m.x)+"px";F.style.top=Math.floor(m.y)+"px";null==C&&(b.container.appendChild(F),C=F.parentNode);g(a,e,m,F)}else null==z||!mxUtils.contains(z,a,e)||1500<N&&!mxEvent.isShiftDown(c)?(z=null,null!=C&&(F.parentNode.removeChild(F),C=null)):null!=z&&null!=C&&(m=b.model.isEdge(z.cell)?b.view.getPoint(z):new mxPoint(z.getCenterX(),z.getCenterY()),
+m=new mxRectangle(m.x-this.refreshTarget.width/2,m.y-this.refreshTarget.height/2,this.refreshTarget.width,this.refreshTarget.height),g(a,e,m,F));if(A&&null!=v&&!mxEvent.isAltDown(c)&&null==I){k=mxRectangle.fromRectangle(v);if(b.model.isEdge(v.cell)){var p=v.absolutePoints;null!=K.parentNode&&(m=p[0],k.add(g(a,e,new mxRectangle(m.x-this.roundDrop.width/2,m.y-this.roundDrop.height/2,this.roundDrop.width,this.roundDrop.height),K)));null!=G.parentNode&&(p=p[p.length-1],k.add(g(a,e,new mxRectangle(p.x-
 this.roundDrop.width/2,p.y-this.roundDrop.height/2,this.roundDrop.width,this.roundDrop.height),G)))}else m=mxRectangle.fromRectangle(v),null!=v.shape&&null!=v.shape.boundingBox&&(m=mxRectangle.fromRectangle(v.shape.boundingBox)),m.grow(this.graph.tolerance),m.grow(HoverIcons.prototype.arrowSpacing),p=this.graph.selectionCellsHandler.getHandler(v.cell),null!=p&&(m.x-=p.horizontalOffset/2,m.y-=p.verticalOffset/2,m.width+=p.horizontalOffset,m.height+=p.verticalOffset,null!=p.rotationShape&&null!=p.rotationShape.node&&
-"hidden"!=p.rotationShape.node.style.visibility&&"none"!=p.rotationShape.node.style.display&&null!=p.rotationShape.boundingBox&&m.add(p.rotationShape.boundingBox)),k.add(g(a,c,new mxRectangle(v.getCenterX()-this.triangleUp.width/2,m.y-this.triangleUp.height,this.triangleUp.width,this.triangleUp.height),B)),k.add(g(a,c,new mxRectangle(m.x+m.width,v.getCenterY()-this.triangleRight.height/2,this.triangleRight.width,this.triangleRight.height),y)),k.add(g(a,c,new mxRectangle(v.getCenterX()-this.triangleDown.width/
-2,m.y+m.height,this.triangleDown.width,this.triangleDown.height),E)),k.add(g(a,c,new mxRectangle(m.x-this.triangleLeft.width,v.getCenterY()-this.triangleLeft.height/2,this.triangleLeft.width,this.triangleLeft.height),D));null!=k&&k.grow(10)}J=mxConstants.DIRECTION_NORTH;I==y?J=mxConstants.DIRECTION_EAST:I==E||I==G?J=mxConstants.DIRECTION_SOUTH:I==D&&(J=mxConstants.DIRECTION_WEST);null!=z&&I==F&&(l=z);m=(null==n||b.isCellConnectable(d[n]))&&(b.model.isEdge(f)&&null!=n||b.model.isVertex(f)&&b.isCellConnectable(f));
-if(null!=v&&5E3<=N||v!=l&&(null==k||!mxUtils.contains(k,a,c)||500<N&&null==I&&m))if(A=!1,v=5E3>N&&N>this.dropTargetDelay||b.model.isEdge(f)?l:null,null!=v&&m){k=[K,G,B,y,E,D];for(m=0;m<k.length;m++)null!=k[m].parentNode&&k[m].parentNode.removeChild(k[m]);b.model.isEdge(f)?(p=l.absolutePoints,null!=p&&(m=p[0],p=p[p.length-1],k=b.tolerance,new mxRectangle(a-k,c-k,2*k,2*k),K.style.left=Math.floor(m.x-this.roundDrop.width/2)+"px",K.style.top=Math.floor(m.y-this.roundDrop.height/2)+"px",G.style.left=Math.floor(p.x-
+"hidden"!=p.rotationShape.node.style.visibility&&"none"!=p.rotationShape.node.style.display&&null!=p.rotationShape.boundingBox&&m.add(p.rotationShape.boundingBox)),k.add(g(a,e,new mxRectangle(v.getCenterX()-this.triangleUp.width/2,m.y-this.triangleUp.height,this.triangleUp.width,this.triangleUp.height),B)),k.add(g(a,e,new mxRectangle(m.x+m.width,v.getCenterY()-this.triangleRight.height/2,this.triangleRight.width,this.triangleRight.height),y)),k.add(g(a,e,new mxRectangle(v.getCenterX()-this.triangleDown.width/
+2,m.y+m.height,this.triangleDown.width,this.triangleDown.height),E)),k.add(g(a,e,new mxRectangle(m.x-this.triangleLeft.width,v.getCenterY()-this.triangleLeft.height/2,this.triangleLeft.width,this.triangleLeft.height),D));null!=k&&k.grow(10)}J=mxConstants.DIRECTION_NORTH;I==y?J=mxConstants.DIRECTION_EAST:I==E||I==G?J=mxConstants.DIRECTION_SOUTH:I==D&&(J=mxConstants.DIRECTION_WEST);null!=z&&I==F&&(l=z);m=(null==n||b.isCellConnectable(d[n]))&&(b.model.isEdge(f)&&null!=n||b.model.isVertex(f)&&b.isCellConnectable(f));
+if(null!=v&&5E3<=N||v!=l&&(null==k||!mxUtils.contains(k,a,e)||500<N&&null==I&&m))if(A=!1,v=5E3>N&&N>this.dropTargetDelay||b.model.isEdge(f)?l:null,null!=v&&m){k=[K,G,B,y,E,D];for(m=0;m<k.length;m++)null!=k[m].parentNode&&k[m].parentNode.removeChild(k[m]);b.model.isEdge(f)?(p=l.absolutePoints,null!=p&&(m=p[0],p=p[p.length-1],k=b.tolerance,new mxRectangle(a-k,e-k,2*k,2*k),K.style.left=Math.floor(m.x-this.roundDrop.width/2)+"px",K.style.top=Math.floor(m.y-this.roundDrop.height/2)+"px",G.style.left=Math.floor(p.x-
 this.roundDrop.width/2)+"px",G.style.top=Math.floor(p.y-this.roundDrop.height/2)+"px",null==b.model.getTerminal(f,!0)&&b.container.appendChild(K),null==b.model.getTerminal(f,!1)&&b.container.appendChild(G))):(m=mxRectangle.fromRectangle(l),null!=l.shape&&null!=l.shape.boundingBox&&(m=mxRectangle.fromRectangle(l.shape.boundingBox)),m.grow(this.graph.tolerance),m.grow(HoverIcons.prototype.arrowSpacing),p=this.graph.selectionCellsHandler.getHandler(l.cell),null!=p&&(m.x-=p.horizontalOffset/2,m.y-=p.verticalOffset/
 2,m.width+=p.horizontalOffset,m.height+=p.verticalOffset,null!=p.rotationShape&&null!=p.rotationShape.node&&"hidden"!=p.rotationShape.node.style.visibility&&"none"!=p.rotationShape.node.style.display&&null!=p.rotationShape.boundingBox&&m.add(p.rotationShape.boundingBox)),B.style.left=Math.floor(l.getCenterX()-this.triangleUp.width/2)+"px",B.style.top=Math.floor(m.y-this.triangleUp.height)+"px",y.style.left=Math.floor(m.x+m.width)+"px",y.style.top=Math.floor(l.getCenterY()-this.triangleRight.height/
 2)+"px",E.style.left=B.style.left,E.style.top=Math.floor(m.y+m.height)+"px",D.style.left=Math.floor(m.x-this.triangleLeft.width)+"px",D.style.top=y.style.top,"eastwest"!=l.style.portConstraint&&(b.container.appendChild(B),b.container.appendChild(E)),b.container.appendChild(y),b.container.appendChild(D));null!=l&&(x=b.selectionCellsHandler.getHandler(l.cell),null!=x&&null!=x.setHandlesVisible&&x.setHandlesVisible(!1));A=!0}else for(k=[K,G,B,y,E,D],m=0;m<k.length;m++)null!=k[m].parentNode&&k[m].parentNode.removeChild(k[m]);
-A||null==x||x.setHandlesVisible(!0);f=mxEvent.isAltDown(e)&&!mxEvent.isShiftDown(e)||null!=z&&I==F?null:mxDragSource.prototype.getDropTarget.apply(this,arguments);k=b.getModel();if(null!=f&&(null!=I||!b.isSplitTarget(f,d,e))){for(;null!=f&&!b.isValidDropTarget(f,d,e)&&k.isVertex(k.getParent(f));)f=k.getParent(f);if(b.view.currentRoot==f||!b.isValidRoot(f)&&0==b.getModel().getChildCount(f)||b.isCellLocked(f)||k.isEdge(f))f=null}return f});t.stopDrag=function(){mxDragSource.prototype.stopDrag.apply(this,
+A||null==x||x.setHandlesVisible(!0);f=mxEvent.isAltDown(c)&&!mxEvent.isShiftDown(c)||null!=z&&I==F?null:mxDragSource.prototype.getDropTarget.apply(this,arguments);k=b.getModel();if(null!=f&&(null!=I||!b.isSplitTarget(f,d,c))){for(;null!=f&&!b.isValidDropTarget(f,d,c)&&k.isVertex(k.getParent(f));)f=k.getParent(f);if(b.view.currentRoot==f||!b.isValidRoot(f)&&0==b.getModel().getChildCount(f)||b.isCellLocked(f)||k.isEdge(f))f=null}return f});t.stopDrag=function(){mxDragSource.prototype.stopDrag.apply(this,
 arguments);for(var b=[K,G,F,B,y,E,D],a=0;a<b.length;a++)null!=b[a].parentNode&&b[a].parentNode.removeChild(b[a]);null!=v&&null!=x&&x.reset();I=C=z=v=x=null};return t};
 Sidebar.prototype.itemClicked=function(a,c,f,d){d=this.editorUi.editor.graph;if(mxEvent.isAltDown(f)){if(1==d.getSelectionCount()&&d.model.isVertex(d.getSelectionCell())){c=null;for(var b=0;b<a.length&&null==c;b++)d.model.isVertex(a[b])&&(c=b);null!=c&&(d.setSelectionCells(this.dropAndConnect(d.getSelectionCell(),a,mxEvent.isMetaDown(f)||mxEvent.isControlDown(f)?mxEvent.isShiftDown(f)?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH:mxEvent.isShiftDown(f)?mxConstants.DIRECTION_EAST:mxConstants.DIRECTION_SOUTH,
 c)),d.scrollCellToVisible(d.getSelectionCell()))}}else mxEvent.isShiftDown(f)?d.isSelectionEmpty()||(this.updateShapes(a[0],d.getSelectionCells()),d.scrollCellToVisible(d.getSelectionCell())):(a=d.getFreeInsertPoint(),c.drop(d,f,null,a.x,a.y),null!=this.editorUi.hoverIcons&&mxEvent.isTouchEvent(f)&&this.editorUi.hoverIcons.update(d.view.getState(d.getSelectionCell())))};
@@ -2380,10 +2380,10 @@ this.container.appendChild(f);null!=a&&(this.palettes[a]=[c,f]);return b};
 Sidebar.prototype.addFoldingHandler=function(a,c,f){var d=!1;if(!mxClient.IS_IE||8<=document.documentMode)a.style.backgroundImage="none"==c.style.display?"url('"+this.collapsedImage+"')":"url('"+this.expandedImage+"')";a.style.backgroundRepeat="no-repeat";a.style.backgroundPosition="0% 50%";mxEvent.addListener(a,"click",mxUtils.bind(this,function(b){if("none"==c.style.display){if(d)c.style.display="block";else if(d=!0,null!=f){a.style.cursor="wait";var e=a.innerHTML;a.innerHTML=mxResources.get("loading")+
 "...";window.setTimeout(function(){var b=mxClient.NO_FO;mxClient.NO_FO=Editor.prototype.originalNoForeignObject;f(c);mxClient.NO_FO=b;c.style.display="block";a.style.cursor="";a.innerHTML=e},0)}else c.style.display="block";a.style.backgroundImage="url('"+this.expandedImage+"')"}else a.style.backgroundImage="url('"+this.collapsedImage+"')",c.style.display="none";mxEvent.consume(b)}))};
 Sidebar.prototype.removePalette=function(a){var c=this.palettes[a];if(null!=c){this.palettes[a]=null;for(a=0;a<c.length;a++)this.container.removeChild(c[a]);return!0}return!1};
-Sidebar.prototype.addImagePalette=function(a,c,f,d,b,e,g){for(var k=[],l=0;l<b.length;l++)mxUtils.bind(this,function(b,a,c){if(null==c){c=b.lastIndexOf("/");var e=b.lastIndexOf(".");c=b.substring(0<=c?c+1:0,0<=e?e:b.length).replace(/[-_]/g," ")}k.push(this.createVertexTemplateEntry("image;html=1;labelBackgroundColor=#ffffff;image="+f+b+d,this.defaultImageWidth,this.defaultImageHeight,"",a,null!=a,null,this.filterTags(c)))})(b[l],null!=e?e[l]:null,null!=g?g[b[l]]:null);this.addPaletteFunctions(a,c,
+Sidebar.prototype.addImagePalette=function(a,c,f,d,b,e,g){for(var k=[],l=0;l<b.length;l++)mxUtils.bind(this,function(b,a,e){if(null==e){e=b.lastIndexOf("/");var c=b.lastIndexOf(".");e=b.substring(0<=e?e+1:0,0<=c?c:b.length).replace(/[-_]/g," ")}k.push(this.createVertexTemplateEntry("image;html=1;labelBackgroundColor=#ffffff;image="+f+b+d,this.defaultImageWidth,this.defaultImageHeight,"",a,null!=a,null,this.filterTags(e)))})(b[l],null!=e?e[l]:null,null!=g?g[b[l]]:null);this.addPaletteFunctions(a,c,
 !1,k)};Sidebar.prototype.getTagsForStencil=function(a,c,f){a=a.split(".");for(var d=1;d<a.length;d++)a[d]=a[d].replace(/_/g," ");a.push(c.replace(/_/g," "));null!=f&&a.push(f);return a.slice(1,a.length)};
-Sidebar.prototype.addStencilPalette=function(a,c,f,d,b,e,g,k,l){g=null!=g?g:1;if(this.addStencilsToIndex){var m=[];if(null!=l)for(var n=0;n<l.length;n++)m.push(l[n]);mxStencilRegistry.loadStencilSet(f,mxUtils.bind(this,function(a,c,e,f,l){if(null==b||0>mxUtils.indexOf(b,c)){e=this.getTagsForStencil(a,c);var n=null!=k?k[c]:null;null!=n&&e.push(n);m.push(this.createVertexTemplateEntry("shape="+a+c.toLowerCase()+d,Math.round(f*g),Math.round(l*g),"",c.replace(/_/g," "),null,null,this.filterTags(e.join(" "))))}}),
-!0,!0);this.addPaletteFunctions(a,c,!1,m)}else this.addPalette(a,c,!1,mxUtils.bind(this,function(a){null==d&&(d="");null!=e&&e.call(this,a);if(null!=l)for(var c=0;c<l.length;c++)l[c](a);mxStencilRegistry.loadStencilSet(f,mxUtils.bind(this,function(c,e,f,k,l){(null==b||0>mxUtils.indexOf(b,e))&&a.appendChild(this.createVertexTemplate("shape="+c+e.toLowerCase()+d,Math.round(k*g),Math.round(l*g),"",e.replace(/_/g," "),!0))}),!0)}))};
+Sidebar.prototype.addStencilPalette=function(a,c,f,d,b,e,g,k,l){g=null!=g?g:1;if(this.addStencilsToIndex){var m=[];if(null!=l)for(var n=0;n<l.length;n++)m.push(l[n]);mxStencilRegistry.loadStencilSet(f,mxUtils.bind(this,function(a,e,c,f,l){if(null==b||0>mxUtils.indexOf(b,e)){c=this.getTagsForStencil(a,e);var n=null!=k?k[e]:null;null!=n&&c.push(n);m.push(this.createVertexTemplateEntry("shape="+a+e.toLowerCase()+d,Math.round(f*g),Math.round(l*g),"",e.replace(/_/g," "),null,null,this.filterTags(c.join(" "))))}}),
+!0,!0);this.addPaletteFunctions(a,c,!1,m)}else this.addPalette(a,c,!1,mxUtils.bind(this,function(a){null==d&&(d="");null!=e&&e.call(this,a);if(null!=l)for(var c=0;c<l.length;c++)l[c](a);mxStencilRegistry.loadStencilSet(f,mxUtils.bind(this,function(e,c,f,k,l){(null==b||0>mxUtils.indexOf(b,c))&&a.appendChild(this.createVertexTemplate("shape="+e+c.toLowerCase()+d,Math.round(k*g),Math.round(l*g),"",c.replace(/_/g," "),!0))}),!0)}))};
 Sidebar.prototype.destroy=function(){null!=this.graph&&(null!=this.graph.container&&null!=this.graph.container.parentNode&&this.graph.container.parentNode.removeChild(this.graph.container),this.graph.destroy(),this.graph=null);null!=this.pointerUpHandler&&(mxEvent.removeListener(document,mxClient.IS_POINTER?"pointerup":"mouseup",this.pointerUpHandler),this.pointerUpHandler=null);null!=this.pointerDownHandler&&(mxEvent.removeListener(document,mxClient.IS_POINTER?"pointerdown":"mousedown",this.pointerDownHandler),
 this.pointerDownHandler=null);null!=this.pointerMoveHandler&&(mxEvent.removeListener(document,mxClient.IS_POINTER?"pointermove":"mousemove",this.pointerMoveHandler),this.pointerMoveHandler=null);null!=this.pointerOutHandler&&(mxEvent.removeListener(document,mxClient.IS_POINTER?"pointerout":"mouseout",this.pointerOutHandler),this.pointerOutHandler=null)};"undefined"!==typeof html4&&(html4.ATTRIBS["a::target"]=0,html4.ATTRIBS["source::src"]=0,html4.ATTRIBS["video::src"]=0);
 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(c){}})();mxText.prototype.baseSpacingTop=5;
@@ -2505,12 +2505,12 @@ k=d.getAttribute("h"),g=null==g?80:parseInt(g,10),k=null==k?80:parseInt(k,10);c(
 "#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=8;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGuide.prototype.isEnabledForEvent=function(b){return!mxEvent.isAltDown(b)};var c=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(b){return mxEvent.isControlDown(b)||c.apply(this,
 arguments)};mxConstraintHandler.prototype.createHighlightShape=function(){var b=new mxEllipse(null,this.highlightColor,this.highlightColor,0);b.opacity=mxConstants.HIGHLIGHT_OPACITY;return b};mxConnectionHandler.prototype.livePreview=!0;mxConnectionHandler.prototype.cursor="crosshair";mxConnectionHandler.prototype.createEdgeState=function(b){b=this.graph.createCurrentEdgeStyle();b=this.graph.createEdge(null,null,null,null,null,b);b=new mxCellState(this.graph.view,b,this.graph.getCellStyle(b));for(var a in this.graph.currentEdgeStyle)b.style[a]=
 this.graph.currentEdgeStyle[a];return b};var f=mxConnectionHandler.prototype.createShape;mxConnectionHandler.prototype.createShape=function(){var b=f.apply(this,arguments);b.isDashed="1"==this.graph.currentEdgeStyle[mxConstants.STYLE_DASHED];return b};mxConnectionHandler.prototype.updatePreview=function(b){};var d=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var b=d.apply(this,arguments),a=b.getCell;b.getCell=mxUtils.bind(this,function(b){var d=
-a.apply(this,arguments);this.error=null;return d});return b};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",html:"1",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var b="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(b+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(b+="curved="+this.currentEdgeStyle.curved+";");
-null!=this.currentEdgeStyle.rounded&&(b+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(b+="comic="+this.currentEdgeStyle.comic+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(b+="elbow="+this.currentEdgeStyle.elbow+";");return null!=this.currentEdgeStyle.html?b+("html="+this.currentEdgeStyle.html+";"):b+"html=1;"};Graph.prototype.getPagePadding=function(){return new mxPoint(0,0)};Graph.prototype.loadStylesheet=function(){var b=
-null!=this.themes?this.themes[this.defaultThemeName]:mxStyleRegistry.dynamicLoading?mxUtils.load(STYLE_PATH+"/default.xml").getDocumentElement():null;null!=b&&(new mxCodec(b.ownerDocument)).decode(b,this.getStylesheet())};Graph.prototype.getAllConnectionConstraints=function(b,a){if(null!=b){var d=mxUtils.getValue(b.style,"points",null);if(null!=d){var c=[];try{for(var e=JSON.parse(d),d=0;d<e.length;d++){var f=e[d];c.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(P){}return c}if(null!=
-b.shape)if(null!=b.shape.stencil){if(null!=b.shape.stencil)return b.shape.stencil.constraints}else if(null!=b.shape.constraints)return b.shape.constraints}return null};Graph.prototype.flipEdge=function(b){if(null!=b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);null!=a&&(a=mxUtils.getValue(a,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,a,[b]))}};
-Graph.prototype.isValidRoot=function(b){for(var a=this.model.getChildCount(b),d=0,c=0;c<a;c++){var e=this.model.getChildAt(b,c);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||d++)}return 0<d||this.isContainer(b)};Graph.prototype.isValidDropTarget=function(b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);return"1"!=mxUtils.getValue(a,"part","0")&&(this.isContainer(b)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(a,"dropTarget",
-"1"))};Graph.prototype.createGroupCell=function(){var b=mxGraph.prototype.createGroupCell.apply(this,arguments);b.setStyle("group");return b};Graph.prototype.isExtendParentsOnAdd=function(b){var a=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(a&&null!=b&&null!=this.layoutManager){var d=this.model.getParent(b);null!=d&&(d=this.layoutManager.getLayout(d),null!=d&&d.constructor==mxStackLayout&&(a=!1))}return a};Graph.prototype.getPreferredSizeForCell=function(b){var a=mxGraph.prototype.getPreferredSizeForCell.apply(this,
+a.apply(this,arguments);this.error=null;return d});return b};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var b="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(b+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(b+="curved="+this.currentEdgeStyle.curved+";");null!=this.currentEdgeStyle.rounded&&
+(b+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(b+="comic="+this.currentEdgeStyle.comic+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(b+="elbow="+this.currentEdgeStyle.elbow+";");return null!=this.currentEdgeStyle.html?b+("html="+this.currentEdgeStyle.html+";"):b+"html=1;"};Graph.prototype.getPagePadding=function(){return new mxPoint(0,0)};Graph.prototype.loadStylesheet=function(){var b=null!=this.themes?this.themes[this.defaultThemeName]:
+mxStyleRegistry.dynamicLoading?mxUtils.load(STYLE_PATH+"/default.xml").getDocumentElement():null;null!=b&&(new mxCodec(b.ownerDocument)).decode(b,this.getStylesheet())};Graph.prototype.getAllConnectionConstraints=function(b,a){if(null!=b){var d=mxUtils.getValue(b.style,"points",null);if(null!=d){var c=[];try{for(var e=JSON.parse(d),d=0;d<e.length;d++){var f=e[d];c.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(P){}return c}if(null!=b.shape)if(null!=b.shape.stencil){if(null!=
+b.shape.stencil)return b.shape.stencil.constraints}else if(null!=b.shape.constraints)return b.shape.constraints}return null};Graph.prototype.flipEdge=function(b){if(null!=b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);null!=a&&(a=mxUtils.getValue(a,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,a,[b]))}};Graph.prototype.isValidRoot=function(b){for(var a=
+this.model.getChildCount(b),d=0,c=0;c<a;c++){var e=this.model.getChildAt(b,c);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||d++)}return 0<d||this.isContainer(b)};Graph.prototype.isValidDropTarget=function(b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);return"1"!=mxUtils.getValue(a,"part","0")&&(this.isContainer(b)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(a,"dropTarget","1"))};Graph.prototype.createGroupCell=
+function(){var b=mxGraph.prototype.createGroupCell.apply(this,arguments);b.setStyle("group");return b};Graph.prototype.isExtendParentsOnAdd=function(b){var a=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(a&&null!=b&&null!=this.layoutManager){var d=this.model.getParent(b);null!=d&&(d=this.layoutManager.getLayout(d),null!=d&&d.constructor==mxStackLayout&&(a=!1))}return a};Graph.prototype.getPreferredSizeForCell=function(b){var a=mxGraph.prototype.getPreferredSizeForCell.apply(this,
 arguments);null!=a&&(a.width+=10,a.height+=4,this.gridEnabled&&(a.width=this.snap(a.width),a.height=this.snap(a.height)));return a};Graph.prototype.turnShapes=function(b){var a=this.getModel(),d=[];a.beginUpdate();try{for(var c=0;c<b.length;c++){var e=b[c];if(a.isEdge(e)){var f=a.getTerminal(e,!0),g=a.getTerminal(e,!1);a.setTerminal(e,g,!0);a.setTerminal(e,f,!1);var k=a.getGeometry(e);if(null!=k){k=k.clone();null!=k.points&&k.points.reverse();var l=k.getTerminalPoint(!0),m=k.getTerminalPoint(!1);
 k.setTerminalPoint(l,!1);k.setTerminalPoint(m,!0);a.setGeometry(e,k);var n=this.view.getState(e),p=this.view.getState(f),t=this.view.getState(g);if(null!=n){var v=null!=p?this.getConnectionConstraint(n,p,!0):null,q=null!=t?this.getConnectionConstraint(n,t,!1):null;this.setConnectionConstraint(e,f,!0,q);this.setConnectionConstraint(e,g,!1,v)}d.push(e)}}else if(a.isVertex(e)&&(k=this.getCellGeometry(e),null!=k)){k=k.clone();k.x+=k.width/2-k.height/2;k.y+=k.height/2-k.width/2;var u=k.width;k.width=k.height;
 k.height=u;a.setGeometry(e,k);var x=this.view.getState(e);if(null!=x){var z=x.style[mxConstants.STYLE_DIRECTION]||"east";"east"==z?z="south":"south"==z?z="west":"west"==z?z="north":"north"==z&&(z="east");this.setCellStyles(mxConstants.STYLE_DIRECTION,z,[e])}d.push(e)}}}finally{a.endUpdate()}return d};Graph.prototype.processChange=function(b){mxGraph.prototype.processChange.apply(this,arguments);if(b instanceof mxValueChange&&null!=b.cell.value&&"object"==typeof b.cell.value){var a=this.model.getDescendants(b.cell);
@@ -7797,31 +7797,32 @@ IMAGE_PATH+"/delete.png";Editor.plusImage=mxClient.IS_SVG?"data:image/png;base64
 IMAGE_PATH+"/plus.png";Editor.spinImage=mxClient.IS_SVG?"data:image/gif;base64,R0lGODlhDAAMAPUxAEVriVp7lmCAmmGBm2OCnGmHn3OPpneSqYKbr4OcsIScsI2kto6kt46lt5KnuZmtvpquvpuvv56ywaCzwqK1xKu7yay9yq+/zLHAzbfF0bjG0bzJ1LzK1MDN18jT28nT3M3X3tHa4dTc49Xd5Njf5dng5t3k6d/l6uDm6uru8e7x8/Dz9fT29/b4+Pj5+fj5+vr6+v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkKADEAIf8LTkVUU0NBUEUyLjADAQAAACwAAAAADAAMAAAGR8CYcEgsOgYAIax4CCQuQldrCBEsiK8VS2hoFGOrlJDA+cZQwkLnqyoJFZKviSS0ICrE0ec0jDAwIiUeGyBFGhMPFBkhZo1BACH5BAkKAC4ALAAAAAAMAAwAhVB0kFR3k1V4k2CAmmWEnW6Lo3KOpXeSqH2XrIOcsISdsImhtIqhtJCmuJGnuZuwv52wwJ+ywZ+ywqm6yLHBzbLCzrXEz7fF0LnH0rrI0r7L1b/M1sXR2cfT28rV3czW3s/Z4Nfe5Nvi6ODm6uLn6+Ln7OLo7OXq7efs7+zw8u/y9PDy9PX3+Pr7+////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAZDQJdwSCxGDAIAoVFkFBwYSyIwGE4OkCJxIdG6WkJEx8sSKj7elfBB0a5SQg1EQ0SVVMPKhDM6iUIkRR4ZFxsgJl6JQQAh+QQJCgAxACwAAAAADAAMAIVGa4lcfZdjgpxkg51nhp5ui6N3kqh5lKqFnbGHn7KIoLOQp7iRp7mSqLmTqbqarr6br7+fssGitcOitcSuvsuuv8uwwMyzw861xNC5x9K6x9K/zNbDztjE0NnG0drJ1NzQ2eDS2+LT2+LV3ePZ4Oba4ebb4ufc4+jm6+7t8PLt8PPt8fPx8/Xx9PX09vf19/j3+Pn///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CYcEgsUhQFggFSjCQmnE1jcBhqGBXiIuAQSi7FGEIgfIzCFoCXFCZiPO0hKBMiwl7ET6eUYqlWLkUnISImKC1xbUEAIfkECQoAMgAsAAAAAAwADACFTnKPT3KPVHaTYoKcb4yjcY6leZSpf5mtgZuvh5+yiqG0i6K1jqW3kae5nrHBnrLBn7LCoLPCobTDqbrIqrvIs8LOtMPPtcPPtcTPuMbRucfSvcrUvsvVwMzWxdHaydTcytXdzNbezdff0drh2ODl2+Ln3eTp4Obq4ujs5Ont5uvu6O3w6u7w6u7x7/L09vj5+vr7+vv7////AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABkdAmXBILHIcicOCUqxELKKPxKAYgiYd4oMAEWo8RVmjIMScwhmBcJMKXwLCECmMGAhPI1QRwBiaSixCMDFhLSorLi8wYYxCQQAh+QQJCgAxACwAAAAADAAMAIVZepVggJphgZtnhp5vjKN2kah3kqmBmq+KobSLorWNpLaRp7mWq7ybr7+gs8KitcSktsWnuManucexwM2ywc63xtG6yNO9ytS+ytW/zNbDz9jH0tvL1d3N197S2+LU3OPU3ePV3eTX3+Xa4efb4ufd5Onl6u7r7vHs7/Lt8PLw8/Xy9Pby9fb09ff2+Pn3+Pn6+vr///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGSMCYcEgseiwSR+RS7GA4JFGF8RiWNiEiJTERgkjFGAQh/KTCGoJwpApnBkITKrwoCFWnFlEhaAxXLC9CBwAGRS4wQgELYY1CQQAh+QQJCgAzACwAAAAADAAMAIVMcI5SdZFhgZtti6JwjaR4k6mAma6Cm6+KobSLorWLo7WNo7aPpredsMCescGitMOitcSmuMaqu8ixwc2zws63xdC4xtG5x9K9ytXAzdfCztjF0NnF0drK1d3M1t7P2N/P2eDT2+LX3+Xe5Onh5+vi5+vj6Ozk6e3n7O/o7O/q7vHs7/Lt8PPu8fPx8/X3+Pn6+vv7+/v8/Pz///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRcCZcEgsmkIbTOZTLIlGqZNnchm2SCgiJ6IRqljFmQUiXIVnoITQde4chC9Y+LEQxmTFRkFSNFAqDAMIRQoCAAEEDmeLQQAh+QQJCgAwACwAAAAADAAMAIVXeZRefplff5lhgZtph59yjqV2kaeAmq6FnbGFnrGLorWNpLaQp7mRqLmYrb2essGgs8Klt8apusitvcquv8u2xNC7yNO8ydS8ytTAzdfBzdfM1t7N197Q2eDU3OPX3+XZ4ObZ4ebc4+jf5erg5erg5uvp7fDu8fPv8vTz9fb09vf19/j3+Pn4+fn5+vr6+/v///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRUCYcEgspkwjEKhUVJ1QsBNp0xm2VixiSOMRvlxFGAcTJook5eEHIhQcwpWIkAFQECkNy9AQWFwyEAkPRQ4FAwQIE2llQQAh+QQJCgAvACwAAAAADAAMAIVNcY5SdZFigptph6BvjKN0kKd8lquAmq+EnbGGn7KHn7ONpLaOpbearr+csMCdscCescGhtMOnuMauvsuzws60w862xdC9ytW/y9a/zNbCztjG0drH0tvK1N3M1t7N19/U3ePb4uff5urj6Ozk6e3l6u7m6u7o7PDq7vDt8PPv8vTw8vTw8/X19vf6+vv///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CXcEgsvlytVUplJLJIpSEDUESFTELBwSgCCQEV42kjDFiMo4uQsDB2MkLHoEHUTD7DRAHC8VAiZ0QSCgYIDxhNiUEAOw==":
 IMAGE_PATH+"/spin.gif";Editor.tweetImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAARlJREFUeNpi/P//PwM1ABMDlQDVDGKAeo0biMXwKOMD4ilA/AiInwDxfCBWBeIgINYDmwE1yB2Ir0Alsbl6JchONPwNiC8CsTPIDJjXuIBYG4gPAnE8EDMjGaQCxGFYLOAEYlYg/o3sNSkgfo1k2ykgLgRiIyAOwOIaGE6CmwE1SA6IZ0BNR1f8GY9BXugG2UMN+YtHEzr+Aw0OFINYgHgdCYaA8HUgZkM3CASEoYb9ItKgapQkhGQQKC0dJdKQx1CLsRoEArpAvAuI3+Ix5B8Q+2AkaiyZVgGId+MwBBQhKVhzB9QgKyDuAOJ90BSLzZBzQOyCK5uxQNnXoGlJHogfIOU7UCI9C8SbgHgjEP/ElRkZB115BBBgAPbkvQ/azcC0AAAAAElFTkSuQmCC":
 IMAGE_PATH+"/tweet.png";Editor.facebookImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAARVBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADc6ur3AAAAFnRSTlMAYmRg2KVCC/oPq0uAcVQtHtvZuoYh/a7JUAAAAGJJREFUGNOlzkkOgCAMQNEvagvigBP3P6pRNoCJG/+myVu0RdsqxcQqQ/NFVkKQgqwDzoJ2WKajoB66atcAa0GjX0D8lJHwNGfknYJzY77LDtDZ+L74j0z26pZI2yYlMN9TL17xEd+fl1D+AAAAAElFTkSuQmCC":IMAGE_PATH+"/facebook.png";Editor.blankImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACklEQVR4nGMAAQAABQABDQottAAAAABJRU5ErkJggg==";
-Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
-Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;var b=Graph.prototype.loadStylesheet;Graph.prototype.loadStylesheet=function(){b.apply(this,arguments);
-null!=a.defaultVertexStyle&&this.getStylesheet().putDefaultVertexStyle(a.defaultVertexStyle);null!=a.defaultEdgeStyle&&this.getStylesheet().putDefaultEdgeStyle(a.defaultEdgeStyle)}}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):
-null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,
-this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);
-mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};};var c=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var b=c.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&b.setAttribute("style",this.graph.currentStyle);
-null!=this.graph.backgroundImage&&b.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));b.setAttribute("math",this.graph.mathEnabled?"1":"0");b.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return b};Editor.prototype.isDataSvg=function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),
-null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),
-a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};
-null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var f=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=
-null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;f.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";
-Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX","input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});
-MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,
-b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;
-var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var b=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,c){b.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()};
-var e=ColorDialog.resetRecentColors;ColorDialog.resetRecentColors=function(){e.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):
-this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),
-a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",
-stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=
-function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom=
-"2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=
-mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,
-"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin="0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+
-" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";
-e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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=);";
+Editor.defaultCustomLibraries=[];Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
+Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;if(null!=a.css){var b=document.createElement("style");b.setAttribute("type","text/css");b.appendChild(document.createTextNode(a.css));
+var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}null!=a.defaultLibraries&&(Sidebar.prototype.defaultEntries=a.defaultLibraries);null!=a.defaultCustomLibraries&&(Editor.defaultCustomLibraries=a.defaultCustomLibraries);null!=a.defaultVertexStyle&&(Graph.prototype.defaultVertexStyle=a.defaultVertexStyle);null!=a.defaultEdgeStyle&&(Graph.prototype.defaultEdgeStyle=a.defaultEdgeStyle)}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):
+null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||
+"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=
+c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};
+};var c=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var b=c.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&b.setAttribute("style",this.graph.currentStyle);null!=this.graph.backgroundImage&&b.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));b.setAttribute("math",this.graph.mathEnabled?"1":"0");b.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return b};Editor.prototype.isDataSvg=
+function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),
+d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=
+c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<
+c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var f=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;f.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=
+function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX",
+"input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?
+Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};
+Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,
+'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var b=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,c){b.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()};var e=ColorDialog.resetRecentColors;ColorDialog.resetRecentColors=function(){e.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&
+(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",
+stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,
+{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;
+StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));
+b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,
+f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin=
+"0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=
+0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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(k,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme-1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));var g=document.createElement("div");g.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(k),a.appendChild(g));mxEvent.addListener(g,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme+1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));c(k);c(g);b(this.defaultColorSchemes[this.editorUi.currentScheme]);return a};StyleFormatPanel.prototype.addEditOps=function(a){var b=this.format.getSelectionState(),c=null;1==this.editorUi.editor.graph.getSelectionCount()&&
 (c=mxUtils.button(mxResources.get("editStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("editStyle").funct()})),c.setAttribute("title",mxResources.get("editStyle")+" ("+this.editorUi.actions.get("editStyle").shortcut+")"),c.style.width="202px",c.style.marginBottom="2px",a.appendChild(c));var d=this.editorUi.editor.graph,e=d.view.getState(d.getSelectionCell());1==d.getSelectionCount()&&null!=e&&null!=e.shape&&null!=e.shape.stencil?(b=mxUtils.button(mxResources.get("editShape"),mxUtils.bind(this,
@@ -7857,17 +7858,17 @@ N=document.createElement("tr"),H=N.cloneNode(!0),V=document.createElement("td"),
 mxResources.get("fitToSheetsAcross"));ba.appendChild(k);mxUtils.write(Y,mxResources.get("fitToBy"));var X=R.cloneNode(!0);S.appendChild(X);mxEvent.addListener(R,"focus",function(){Q.checked=!0});mxEvent.addListener(X,"focus",function(){Q.checked=!0});k=document.createElement("span");mxUtils.write(k,mxResources.get("fitToSheetsDown"));P.appendChild(k);N.appendChild(V);N.appendChild(O);N.appendChild(ba);H.appendChild(Y);H.appendChild(S);H.appendChild(P);W.appendChild(N);W.appendChild(H);v.appendChild(W);
 m.appendChild(v);f.appendChild(m);m=document.createElement("div");k=document.createElement("div");k.style.fontWeight="bold";k.style.marginBottom="12px";mxUtils.write(k,mxResources.get("paperSize"));m.appendChild(k);k=document.createElement("div");k.style.marginBottom="12px";var da=PageSetupDialog.addPageFormatPanel(k,"printdialog",a.editor.graph.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT);m.appendChild(k);k=document.createElement("span");mxUtils.write(k,mxResources.get("pageScale"));m.appendChild(k);
 var aa=document.createElement("input");aa.style.cssText="margin:0 8px 0 8px;";aa.setAttribute("value","100 %");aa.style.width="60px";m.appendChild(aa);f.appendChild(m);k=document.createElement("div");k.style.cssText="text-align:right;margin:62px 0 0 0;";m=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});m.className="geBtn";a.editor.cancelFirst&&k.appendChild(m);a.isOffline()||(v=mxUtils.button(mxResources.get("help"),function(){window.open("https://desk.draw.io/support/solutions/articles/16000048947")}),
-v.className="geBtn",k.appendChild(v));PrintDialog.previewEnabled&&(v=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();d(!1)}),v.className="geBtn",k.appendChild(v));v=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?"print":"ok"),function(){a.hideDialog();d(!0)});v.className="geBtn gePrimaryBtn";k.appendChild(v);a.editor.cancelFirst||k.appendChild(m);f.appendChild(k);this.container=f}})();(function(){EditorUi.VERSION="6.7.8";EditorUi.compactUi="atlas"!=uiTheme;EditorUi.enableLogging=/.*\.draw\.io$/.test(window.location.hostname);EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;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.sidebarFooterHeight=
+v.className="geBtn",k.appendChild(v));PrintDialog.previewEnabled&&(v=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();d(!1)}),v.className="geBtn",k.appendChild(v));v=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?"print":"ok"),function(){a.hideDialog();d(!0)});v.className="geBtn gePrimaryBtn";k.appendChild(v);a.editor.cancelFirst||k.appendChild(m);f.appendChild(k);this.container=f}})();(function(){EditorUi.VERSION="6.7.9";EditorUi.compactUi="atlas"!=uiTheme;EditorUi.enableLogging=/.*\.draw\.io$/.test(window.location.hostname);EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;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.sidebarFooterHeight=
 36;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.resampleThreshold=
-1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();EditorUi.prototype.getLocalData=
-function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=
-function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,length:c,width:Math.round(c/
-3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=2E9,k.style.left=
-Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+"px")),this.pause=
-mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<
-16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};var a=
-EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
+1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;EditorUi.prototype.formatEnabled="0"!=urlParams.format;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=
+null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();
+EditorUi.prototype.getLocalData=function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,
+length:c,width:Math.round(c/3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=
+2E9,k.style.left=Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+
+"px")),this.pause=mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<
+8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};
+var a=EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
 function(a){if(null!=a&&0<a.length){var b=a.indexOf('<meta charset="utf-8">');0<=b&&(a=a.slice(0,b)+'<meta charset="utf-8"/>'+a.slice(b+23-1,a.length))}return a};EditorUi.prototype.replaceFileData=function(a){a=this.validateFileData(a);a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var b=null!=a?this.editor.extractGraphModel(a,!0):null;null!=b&&(a=b);if(null!=a){b=this.editor.graph;b.model.beginUpdate();try{var c=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 f=this.updatePageRoot(new DiagramPage(d[e]));null==f.getName()&&f.setName(mxResources.get("pageWithNumber",[e+1]));b.model.execute(new ChangePage(this,f,0==e?f: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])),b.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!=c)for(e=0;e<c.length;e++)b.model.execute(new ChangePage(this,c[e],null))}finally{b.model.endUpdate()}}};EditorUi.prototype.createFileData=function(a,b,c,d,e,f,g,u,v,x){b=null!=b?b:this.editor.graph;e=null!=e?e:!1;v=null!=v?v:!0;var k,l=null;null==c||
@@ -7976,17 +7977,17 @@ EditorUi.prototype.createEmbedSvg=function(a,b,c,d,e,f,g){var k=this.editor.grap
 " "+mxResources.get("months");b=Math.floor(a/86400);if(1<b)return b+" "+mxResources.get("days");b=Math.floor(a/3600);if(1<b)return b+" "+mxResources.get("hours");b=Math.floor(a/60);return 1<b?b+" "+mxResources.get("minutes"):1==b?b+" "+mxResources.get("minute"):null};EditorUi.prototype.convertMath=function(a,b,c,d){d()};EditorUi.prototype.getEmbeddedSvg=function(a,b,c,d,e,f,g){g=b.background;g==mxConstants.NONE&&(g=null);b=b.getSvg(g,null,null,null,null,f);null!=a&&b.setAttribute("content",a);null!=
 c&&b.setAttribute("resource",c);if(null!=e)this.convertImages(b,mxUtils.bind(this,function(a){e((d?"":'<?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(d?"":'<?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(b)};EditorUi.prototype.exportImage=function(a,b,c,d,e,f,g,
 u,v){v=null!=v?v:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var k=this.editor.graph.isSelectionEmpty();c=null!=c?c:k;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.exportToCanvas(mxUtils.bind(this,function(a){this.spinner.stop();try{this.saveCanvas(a,e?this.getFileData(!0,null,null,null,c,u):null,v)}catch(A){"Invalid image"==A.message?this.downloadFile(v):this.handleError(A)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();
-this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,u,v,x,z,A,B,y){f=null!=f?f:!0;A=null!=A?A:this.editor.graph;B=null!=B?B:0;var k=v?null:A.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==v&&(k="#ffffff");this.convertImages(A.getSvg(k,null,null,y,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){var e=document.createElement("canvas"),
-g=parseInt(c.getAttribute("width")),l=parseInt(c.getAttribute("height"));u=null!=u?u:1;null!=b&&(u=f?Math.min(1,Math.min(3*b/(4*l),b/g)):b/g);g=Math.ceil(u*g)+2*B;l=Math.ceil(u*l)+2*B;e.setAttribute("width",g);e.setAttribute("height",l);var m=e.getContext("2d");null!=k&&(m.beginPath(),m.rect(0,0,g,l),m.fillStyle=k,m.fill());m.scale(u,u);m.drawImage(d,B/u,B/u);a(e)});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(A,c,!0,mxUtils.bind(this,function(){d.src=
-this.createSvgDataUri(mxUtils.getXml(c))}))}catch(C){null!=e&&e(C)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=function(a,b,
-c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,k){for(var g=a.getElementsByTagName(c),l=0;l<g.length;l++)mxUtils.bind(this,function(c){var g=d.convert(c.getAttribute(k));if(null!=g&&"data:"!=g.substring(0,5)){var l=f[g];null==l?(e++,this.convertImageToDataUri(g,function(d){null!=d&&(f[g]=d,c.setAttribute(k,d));e--;0==e&&b(a)})):c.setAttribute(k,l)}})(g[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=function(a){return"https?://raw.githubusercontent.com/"===
-a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=
-function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var k=this.editor.graph;if(null!=a&&0<a.length){var g=mxUtils.parseXml(a),l=this.editor.extractGraphModel(g.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(k.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){k.model.beginUpdate();try{for(var n=0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),
-B=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[B+1]));k.model.execute(new ChangePage(this,p,p,B))}}finally{k.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var y=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,y);var E=y.getChildCount(y.getRoot());k.model.getChildCount(k.model.getRoot());k.model.beginUpdate();try{a={};for(n=0;n<E;n++){var D=y.getChildAt(y.getRoot(),n);if(1!=E||k.isCellLocked(k.getDefaultParent()))D=k.importCells([D],0,0,k.model.getRoot(),
-null,a)[0],F=k.model.getChildren(D),k.moveCells(F,b,c),f=f.concat(F);else var F=y.getChildren(D),f=f.concat(k.importCells(F,b,c,k.getDefaultParent(),null,a))}if(d){k.isGridEnabled()&&(b=k.snap(b),c=k.snap(c));var C=k.getBoundingBoxFromGeometry(f,!0);null!=C&&k.moveCells(f,b-C.x,c-C.y)}}finally{k.model.endUpdate()}}}}catch(K){throw e||this.handleError(K,mxResources.get("invalidOrMissingFile")),K;}return f};EditorUi.prototype.insertLucidChart=function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,
-b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var k=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var g=this.extractGraphModelFromPng(a),l=this.importXml(g,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,19))try{if(g=null,"data:image/svg+xml;base64,"==a.substring(0,
-26)?(g=a.substring(a.indexOf(",")+1),g=window.atob&&!mxClient.IS_SF?atob(g):Base64.decode(g,!0)):g=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(g,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){k.setSelectionCell(k.insertVertex(null,null,"",k.snap(b),k.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
+this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,u,v,x,z,A,B,y){f=null!=f?f:!0;A=null!=A?A:this.editor.graph;B=null!=B?B:0;var k=v?null:A.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==v&&(k="#ffffff");this.convertImages(A.getSvg(k,null,null,y,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){try{var g=document.createElement("canvas"),
+l=parseInt(c.getAttribute("width")),m=parseInt(c.getAttribute("height"));u=null!=u?u:1;null!=b&&(u=f?Math.min(1,Math.min(3*b/(4*m),b/l)):b/l);l=Math.ceil(u*l)+2*B;m=Math.ceil(u*m)+2*B;g.setAttribute("width",l);g.setAttribute("height",m);var n=g.getContext("2d");null!=k&&(n.beginPath(),n.rect(0,0,l,m),n.fillStyle=k,n.fill());n.scale(u,u);n.drawImage(d,B/u,B/u);a(g)}catch(I){null!=e&&e(I)}});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(A,c,!0,mxUtils.bind(this,
+function(){d.src=this.createSvgDataUri(mxUtils.getXml(c))}))}catch(C){null!=e&&e(C)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=
+function(a,b,c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,k){for(var g=a.getElementsByTagName(c),l=0;l<g.length;l++)mxUtils.bind(this,function(c){var g=d.convert(c.getAttribute(k));if(null!=g&&"data:"!=g.substring(0,5)){var l=f[g];null==l?(e++,this.convertImageToDataUri(g,function(d){null!=d&&(f[g]=d,c.setAttribute(k,d));e--;0==e&&b(a)})):c.setAttribute(k,l)}})(g[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=
+function(a){return"https?://raw.githubusercontent.com/"===a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};
+c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var k=this.editor.graph;if(null!=a&&0<a.length){var g=mxUtils.parseXml(a),l=this.editor.extractGraphModel(g.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(k.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){k.model.beginUpdate();try{for(var n=
+0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),B=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[B+1]));k.model.execute(new ChangePage(this,p,p,B))}}finally{k.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var y=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,y);var E=y.getChildCount(y.getRoot());k.model.getChildCount(k.model.getRoot());k.model.beginUpdate();try{a={};for(n=0;n<E;n++){var D=y.getChildAt(y.getRoot(),n);if(1!=
+E||k.isCellLocked(k.getDefaultParent()))D=k.importCells([D],0,0,k.model.getRoot(),null,a)[0],F=k.model.getChildren(D),k.moveCells(F,b,c),f=f.concat(F);else var F=y.getChildren(D),f=f.concat(k.importCells(F,b,c,k.getDefaultParent(),null,a))}if(d){k.isGridEnabled()&&(b=k.snap(b),c=k.snap(c));var C=k.getBoundingBoxFromGeometry(f,!0);null!=C&&k.moveCells(f,b-C.x,c-C.y)}}finally{k.model.endUpdate()}}}}catch(K){throw e||this.handleError(K,mxResources.get("invalidOrMissingFile")),K;}return f};EditorUi.prototype.insertLucidChart=
+function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var k=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var g=this.extractGraphModelFromPng(a),l=this.importXml(g,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,
+19))try{if(g=null,"data:image/svg+xml;base64,"==a.substring(0,26)?(g=a.substring(a.indexOf(",")+1),g=window.atob&&!mxClient.IS_SF?atob(g):Base64.decode(g,!0)):g=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(g,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){k.setSelectionCell(k.insertVertex(null,null,"",k.snap(b),k.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
 this.convertDataUri(a)+";"))}),!0,this.maxImageSize);else{var e=Math.min(1,Math.min(this.maxImageSize/d.width,this.maxImageSize/d.height)),f=Math.round(d.width*e);d=Math.round(d.height*e);k.setSelectionCell(k.insertVertex(null,null,"",k.snap(b),k.snap(c),f,d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";"))}}),mxUtils.bind(this,function(){var e=null;k.getModel().beginUpdate();try{e=k.insertVertex(k.getDefaultParent(),
 null,a,k.snap(b),k.snap(c),1,1,"text;"+(d?"html=1;":"")),k.updateCellSize(e),k.fireEvent(new mxEventObject("textInserted","cells",[e]))}finally{k.getModel().endUpdate()}k.setSelectionCell(e)}))}else{a=this.editor.graph.zapGremlins(mxUtils.trim(a));if(this.isCompatibleString(a))return this.importXml(a,b,c,f);if(0<a.length)if('{"state":"{\\"Properties\\":'==a.substring(0,26)){e=JSON.parse(JSON.parse(a).state);var g=null,m;for(m in e.Pages)if(l=e.Pages[m],null!=l&&"0"==l.Properties.Order){g=l;break}null!=
 g&&this.insertLucidChart(g,b,c,f)}else{k=this.editor.graph;f=null;k.getModel().beginUpdate();try{f=k.insertVertex(k.getDefaultParent(),null,"",k.snap(b),k.snap(c),1,1,"text;"+(d?"html=1;":"")),k.fireEvent(new mxEventObject("textInserted","cells",[f])),f.value=a,k.updateCellSize(f),/\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/i.test(f.value)&&
@@ -8008,11 +8009,11 @@ for(var c=0;256>c;c++)for(var f=c,d=0;8>d;d++)f=1==(f&1)?3988292384^f>>>1:f>>>1,
 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 l=0;if(f(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=e&&e();else if(f(a,4),"IHDR"!=f(a,4))null!=e&&e();else{f(a,17);e=a.substring(0,l);do{var m=k(a);if("IDAT"==f(a,4)){e=a.substring(0,l-8);c=c+String.fromCharCode(0)+("zTXt"==b?String.fromCharCode(0):"")+d;d=4294967295;d=this.updateCRC(d,b,0,4);d=this.updateCRC(d,c,0,c.length);e+=g(c.length)+b+c+g(d^4294967295);
 e+=a.substring(l-8,a.length);break}e+=a.substring(l-8,l-4+m);d=f(a,m);f(a,4)}while(m);return"data:image/png;base64,"+(window.btoa?btoa(e):Base64.encode(e,!0))}};EditorUi.prototype.extractGraphModelFromPng=function(a){var b=null;try{var c=a.substring(a.indexOf(",")+1),d=window.atob&&!mxClient.IS_SF?atob(c):Base64.decode(c,!0);EditorUi.parsePng(d,mxUtils.bind(this,function(a,c,e){a=d.substring(a+8,a+8+e);"zTXt"==c?(e=a.indexOf(String.fromCharCode(0)),"mxGraphModel"==a.substring(0,e)&&(a=this.editor.graph.bytesToString(pako.inflateRaw(a.substring(e+
 2))).replace(/\+/g," "),null!=a&&0<a.length&&(b=a))):"tEXt"==c&&(a=a.split(String.fromCharCode(0)),1<a.length&&"mxGraphModel"==a[0]&&(b=a[1]));if(null!=b||"IDAT"==c)return!0}))}catch(p){}null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));return b};EditorUi.prototype.loadImage=function(a,b,c){var d=new Image;d.onload=function(){b(d)};null!=c&&(d.onerror=c);d.src=a};var b=EditorUi.prototype.init;EditorUi.prototype.init=function(){function a(a){var b=
-a.indexOf(",");0<b&&(a=c.getPageById(a.substring(b+1)))&&c.selectPage(a)}var c=this,d=this.editor.graph,e=d.addClickHandler;d.addClickHandler=function(b,c,f){var k=c;c=function(b,c){if(null==c){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(c=e.getAttribute("href"))}null!=c&&d.isPageLink(c)&&(a(c),mxEvent.consume(b));null!=k&&k(b)};e.call(this,b,c,f)};b.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(d.view.canvas.ownerSVGElement,null,!0);c.actions.get("print").funct=
-function(){c.showDialog((new PrintDialog(c)).container,360,null!=c.pages&&1<c.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=d.getGlobalVariable;d.getGlobalVariable=function(a){return"page"==a&&null!=c.currentPage?c.currentPage.getName():"pagenumber"==a?null!=c.currentPage&&null!=c.pages?mxUtils.indexOf(c.pages,c.currentPage)+1:1:f.apply(this,arguments)};var g=d.createLinkForHint;d.createLinkForHint=function(b,e){var f=d.isPageLink(b);if(f){var k=b.indexOf(",");
-0<k&&(k=c.getPageById(b.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(c){a(b);mxEvent.consume(c)});return k};var t=d.labelLinkClicked;d.labelLinkClicked=function(b,c,e){var f=c.getAttribute("href");d.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=c.defaultFilename,b=c.getCurrentFile();null!=b&&(a=null!=b.getTitle()?b.getTitle():a);return a};
-var u=this.actions.get("print");u.setEnabled(!mxClient.IS_IOS||!navigator.standalone);u.visible=u.isEnabled();if(!this.editor.chromeless){var v=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||d.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var k=f[index];if("file"===k.kind){if(b.isEditing())this.importFiles([k.getAsFile()],
+a.indexOf(",");0<b&&(a=c.getPageById(a.substring(b+1)))&&c.selectPage(a)}"undefined"!==typeof window.mxSettings&&(this.formatWidth=mxSettings.getFormatWidth());var c=this,d=this.editor.graph,e=d.addClickHandler;d.addClickHandler=function(b,c,f){var k=c;c=function(b,c){if(null==c){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(c=e.getAttribute("href"))}null!=c&&d.isPageLink(c)&&(a(c),mxEvent.consume(b));null!=k&&k(b)};e.call(this,b,c,f)};b.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(d.view.canvas.ownerSVGElement,
+null,!0);c.actions.get("print").funct=function(){c.showDialog((new PrintDialog(c)).container,360,null!=c.pages&&1<c.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=d.getGlobalVariable;d.getGlobalVariable=function(a){return"page"==a&&null!=c.currentPage?c.currentPage.getName():"pagenumber"==a?null!=c.currentPage&&null!=c.pages?mxUtils.indexOf(c.pages,c.currentPage)+1:1:f.apply(this,arguments)};var g=d.createLinkForHint;d.createLinkForHint=function(b,e){var f=
+d.isPageLink(b);if(f){var k=b.indexOf(",");0<k&&(k=c.getPageById(b.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(c){a(b);mxEvent.consume(c)});return k};var t=d.labelLinkClicked;d.labelLinkClicked=function(b,c,e){var f=c.getAttribute("href");d.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=c.defaultFilename,b=c.getCurrentFile();null!=b&&(a=
+null!=b.getTitle()?b.getTitle():a);return a};var u=this.actions.get("print");u.setEnabled(!mxClient.IS_IOS||!navigator.standalone);u.visible=u.isEnabled();if(!this.editor.chromeless){var v=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||d.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var k=f[index];if("file"===k.kind){if(b.isEditing())this.importFiles([k.getAsFile()],
 0,0,this.maxImageSize,function(a,c,d,e,f,k){b.insertImage(a,f,k)},function(){},function(a){return"image/"==a.type.substring(0,6)},function(a){for(var b=0;b<a.length;b++)a[b]()});else{var g=this.editor.graph.getInsertPoint();this.importFiles([k.getAsFile()],g.x,g.y,this.maxImageSize);mxEvent.consume(a)}break}}}}catch(L){}}),!1);var x=document.createElement("div");x.style.position="absolute";x.style.whiteSpace="nowrap";x.style.overflow="hidden";x.style.display="block";x.contentEditable=!0;mxUtils.setOpacity(x,
 0);x.style.width="1px";x.style.height="1px";x.innerHTML="&nbsp;";var z=!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 b=mxEvent.getSource(a);null==d.container||!d.isEnabled()||d.isMouseDown||d.isEditing()||null!=this.dialog||"INPUT"==b.nodeName||"TEXTAREA"==b.nodeName||!(224==a.keyCode||!mxClient.IS_MAC&&17==a.keyCode||mxClient.IS_MAC&&91==a.keyCode)||
 z||(x.style.left=d.container.scrollLeft+10+"px",x.style.top=d.container.scrollTop+10+"px",d.container.appendChild(x),z=!0,mxClient.IS_QUIRKS?window.setTimeout(function(){x.focus();document.execCommand("selectAll",!1,null)},0):(x.focus(),document.execCommand("selectAll",!1,null)))}));mxEvent.addListener(document,"keyup",mxUtils.bind(this,function(a){var b=a.keyCode;window.setTimeout(mxUtils.bind(this,function(){!z||224!=b&&17!=b&&91!=b||(z=!1,d.isEditing()||null!=this.dialog||null==d.container||d.container.focus(),
@@ -8027,53 +8028,57 @@ null;mxEvent.addListener(d.container,"dragleave",function(a){d.isEnabled()&&(nul
 y=null);if(d.isEnabled()){var b=mxUtils.convertPoint(d.container,mxEvent.getClientX(a),mxEvent.getClientY(a)),c=d.view.translate,e=d.view.scale,f=b.x/e-c.x,k=b.y/e-c.y;mxEvent.isAltDown(a)&&(k=f=0);if(0<a.dataTransfer.files.length)this.importFiles(a.dataTransfer.files,f,k,this.maxImageSize,null,null,null,null,!mxEvent.isControlDown(a),null,null,mxEvent.isShiftDown(a));else{var g=0<=mxUtils.indexOf(a.dataTransfer.types,"text/uri-list")?a.dataTransfer.getData("text/uri-list"):null,b=this.extractGraphModelFromEvent(a,
 null!=this.pages);if(null!=b)d.setSelectionCells(this.importXml(b,f,k,!0));else if(0<=mxUtils.indexOf(a.dataTransfer.types,"text/html")){b=a.dataTransfer.getData("text/html");e=document.createElement("div");e.innerHTML=b;var c=null,l=e.getElementsByTagName("img");null!=l&&1==l.length?(b=l[0].getAttribute("src"),/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(b)||(c=!0)):(e=e.getElementsByTagName("a"),null!=e&&1==e.length&&(b=e[0].getAttribute("href")));d.setSelectionCells(this.insertTextAt(b,f,k,!0,c))}else null!=
 g&&/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(g)?this.loadImage(decodeURIComponent(g),mxUtils.bind(this,function(a){var b=Math.max(1,a.width);a=Math.max(1,a.height);var c=this.maxImageSize,c=Math.min(1,Math.min(c/Math.max(1,b)),c/Math.max(1,a));d.setSelectionCell(d.insertVertex(null,null,"",f,k,b*c,a*c,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+g+";"))}),mxUtils.bind(this,function(a){d.setSelectionCells(this.insertTextAt(g,
-f,k,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&d.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,k,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode()};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,
-encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=
-this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var k=e.lastIndexOf("%3E");0<=k&&k<e.length-3&&(e=e.substring(0,k+3))}catch(v){}try{var c=b.getElementsByTagName("span"),g=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(g)&&(f=!0,e=g)}catch(v){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=
-e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(v){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=
-null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,
-function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;
-var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?
-this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=
-0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?
-this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(u){this.handleError(u,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,
-d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,
-a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),
-this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),
-c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=
-null!=c?c:!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 b=
-this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,
-f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function g(a){if(null!=a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(J){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(G){l=null}if(null==l)return;
-if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&k.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?
-mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):g(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",
-result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(G){k.postMessage(JSON.stringify({event:"draft",error:G.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?
-k.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=
-l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,
-t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;k.postMessage(JSON.stringify(b),"*")}),u=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=
-this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),F=q.getGlobalVariable,C=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?C.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(C.root)}this.exportToCanvas(mxUtils.bind(this,function(a){u(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){u(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+
-("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):u(null)}),mxUtils.bind(this,function(){u(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=
-this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),
-"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);k.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));k.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),
-this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=this.createSvgDataUri(m)}k.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight=
-"12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight="38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{k.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=g(l);c=!0;try{a(l,f)}catch(G){this.handleError(G)}c=!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==b&&(b=mxUtils.bind(this,function(a,b){var d=K();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",
-b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||k.postMessage(JSON.stringify(this.createLoadMessage("load")),
-"*")}));var k=window.opener||window.parent,f="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";k.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",
-mxResources.get("save")+" (Ctrl+S)");b.className="geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor=
-"pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=
-a.split("\n"),c=[];if(0<b.length){var d={},e=null,f=null,g="auto",k="auto",v=40,x=40,z=0,A=this.editor.graph;A.getGraphBounds();for(var B=function(){A.setSelectionCells(R);A.scrollCellToVisible(A.getSelectionCell())},y=A.getFreeInsertPoint(),E=y.x,D=y.y,y=D,F=null,C="auto",K=[],G=null,J=null,I=0;I<b.length&&"#"==b[I].charAt(0);){a=b[I];for(I++;I<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[I].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[I].substring(1)),I++;if("#"!=a.charAt(1)){var L=a.indexOf(":");
-if(0<L){var M=mxUtils.trim(a.substring(1,L)),Q=mxUtils.trim(a.substring(L+1));"label"==M?F=A.sanitizeHtml(Q):"style"==M?e=Q:"identity"==M&&0<Q.length&&"-"!=Q?f=Q:"width"==M?g=Q:"height"==M?k=Q:"ignore"==M?J=Q.split(","):"connect"==M?K.push(JSON.parse(Q)):"link"==M?G=Q:"padding"==M?z=parseFloat(Q):"edgespacing"==M?v=parseFloat(Q):"nodespacing"==M?x=parseFloat(Q):"layout"==M&&(C=Q)}}}var W=this.editor.csvToArray(b[I]);a=null;if(null!=f)for(var N=0;N<W.length;N++)if(f==W[N]){a=N;break}null==F&&(F="%"+
-W[0]+"%");if(null!=K)for(var H=0;H<K.length;H++)null==d[K[H].to]&&(d[K[H].to]={});A.model.beginUpdate();try{for(N=I+1;N<b.length;N++){var V=this.editor.csvToArray(b[N]);if(V.length==W.length){var O=null,ba=null!=a?V[a]:null;null!=ba&&(O=A.model.getCell(ba));null==O&&(O=new mxCell(F,new mxGeometry(E,y,0,0),e||"whiteSpace=wrap;html=1;"),O.vertex=!0,O.id=ba);for(var Y=0;Y<V.length;Y++)A.setAttributeForCell(O,W[Y],V[Y]);A.setAttributeForCell(O,"placeholders","1");O.style=A.replacePlaceholders(O,O.style);
-for(H=0;H<K.length;H++)d[K[H].to][O.getAttribute(K[H].to)]=O;null!=G&&"link"!=G&&(A.setLinkForCell(O,O.getAttribute(G)),A.setAttributeForCell(O,G,null));var S=this.editor.graph.getPreferredSizeForCell(O);O.geometry.width="auto"==g?S.width+z:parseFloat(g);O.geometry.height="auto"==k?S.height+z:parseFloat(k);y+=O.geometry.height+x;c.push(A.addCell(O))}}null==e&&A.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var P=c.slice(),R=c.slice(),H=0;H<K.length;H++)for(var X=K[H],N=0;N<c.length;N++){var O=
-c[N],da=O.getAttribute(X.from);if(null!=da){A.setAttributeForCell(O,X.from,null);for(var aa=da.split(","),Y=0;Y<aa.length;Y++){var T=d[X.to][aa[Y]];null!=T&&(R.push(A.insertEdge(null,null,X.label||"",X.invert?T:O,X.invert?O:T,X.style||A.createCurrentEdgeStyle())),mxUtils.remove(X.invert?O:T,P))}}}if(null!=J)for(N=0;N<c.length;N++)for(O=c[N],Y=0;Y<J.length;Y++)A.setAttributeForCell(O,mxUtils.trim(J[Y]),null);var ca=new mxParallelEdgeLayout(A);ca.spacing=v;var ea=function(){ca.execute(A.getDefaultParent());
-for(var a=0;a<c.length;a++){var b=A.getCellGeometry(c[a]);b.x=Math.round(A.snap(b.x));b.y=Math.round(A.snap(b.y));"auto"==g&&(b.width=Math.round(A.snap(b.width)));"auto"==k&&(b.height=Math.round(A.snap(b.height)))}};if("circle"==C){var U=new mxCircleLayout(A);U.resetEdges=!1;var Z=U.isVertexIgnored;U.isVertexIgnored=function(a){return Z.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){U.execute(A.getDefaultParent());ea()},!0,B);B=null}else if("horizontaltree"==C||"verticaltree"==
-C||"auto"==C&&R.length==2*c.length-1&&1==P.length){A.view.validate();var ga=new mxCompactTreeLayout(A,"horizontaltree"==C);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(A.getDefaultParent(),0<P.length?P[0]:null)},!0,B);B=null}else if("horizontalflow"==C||"verticalflow"==C||"auto"==C&&1==P.length){A.view.validate();var fa=new mxHierarchicalLayout(A,"horizontalflow"==C?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);fa.intraCellSpacing=x;fa.disableEdgeStyle=
-!1;this.executeLayout(function(){fa.execute(A.getDefaultParent(),R);A.moveCells(R,E,D)},!0,B);B=null}else if("organic"==C||"auto"==C&&R.length>c.length){A.view.validate();var ka=new mxFastOrganicLayout(A);ka.forceConstant=3*x;ka.resetEdges=!1;var ja=ka.isVertexIgnored;ka.isVertexIgnored=function(a){return ja.apply(this,arguments)||0>mxUtils.indexOf(c,a)};ca=new mxParallelEdgeLayout(A);ca.spacing=v;this.executeLayout(function(){ka.execute(A.getDefaultParent());ea()},!0,B);B=null}this.hideDialog()}finally{A.model.endUpdate()}null!=
-B&&B()}}catch(la){this.handleError(la)}};EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
+f,k,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&d.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,k,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode();"undefined"!==typeof window.mxSettings&&this.installSettings()};EditorUi.prototype.installSettings=function(){if(isLocalStorage||mxClient.IS_CHROMEAPP)ColorDialog.recentColors=mxSettings.getRecentColors(),this.editor.graph.currentEdgeStyle=
+mxSettings.getCurrentEdgeStyle(),this.editor.graph.currentVertexStyle=mxSettings.getCurrentVertexStyle(),this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[])),this.addListener("styleChanged",mxUtils.bind(this,function(a,b){mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);mxSettings.save()})),this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget()),this.fireEvent(new mxEventObject("copyConnectChanged")),
+this.addListener("copyConnectChanged",mxUtils.bind(this,function(a,b){mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());mxSettings.save()})),this.editor.graph.pageFormat=mxSettings.getPageFormat(),this.addListener("pageFormatChanged",mxUtils.bind(this,function(a,b){mxSettings.setPageFormat(this.editor.graph.pageFormat);mxSettings.save()})),this.editor.graph.view.gridColor=mxSettings.getGridColor(),this.addListener("gridColorChanged",mxUtils.bind(this,function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor);
+mxSettings.save()})),mxClient.IS_CHROMEAPP&&(this.editor.addListener("autosaveChanged",mxUtils.bind(this,function(a,b){mxSettings.setAutosave(this.editor.autosave);mxSettings.save()})),this.editor.autosave=mxSettings.getAutosave()),null!=this.sidebar&&this.sidebar.showPalette("search",mxSettings.settings.search),!this.editor.chromeless&&null!=this.sidebar&&(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))&&(this.toggleScratchpad(),mxSettings.save()),this.addListener("formatWidthChanged",
+function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=
+function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var k=e.lastIndexOf("%3E");0<=k&&k<e.length-3&&(e=e.substring(0,
+k+3))}catch(v){}try{var c=b.getElementsByTagName("span"),g=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(g)&&(f=!0,e=g)}catch(v){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),
+d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(v){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],
+"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&
+(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&
+(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-
+3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=
+function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,
+d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},
+mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(u){this.handleError(u,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,
+5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?
+(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),
+a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),
+f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=null!=c?c:!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 b=this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,
+scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function k(a){if(null!=
+a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(J){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(G){l=null}if(null==l)return;if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,
+null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&g.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();
+return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):k(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):
+null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(G){g.postMessage(JSON.stringify({event:"draft",error:G.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?g.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,
+name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=
+null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();
+var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;g.postMessage(JSON.stringify(b),"*")}),u=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),
+F=q.getGlobalVariable,C=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?C.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(C.root)}this.exportToCanvas(mxUtils.bind(this,function(a){u(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){u(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,
+function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):u(null)}),mxUtils.bind(this,function(){u(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),
+n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,
+function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);g.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));g.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=
+this.createSvgDataUri(m)}g.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight="12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight=
+"38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{g.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=k(l);c=!0;try{a(l,f)}catch(G){this.handleError(G)}c=!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==b&&(b=mxUtils.bind(this,function(a,b){var d=K();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",
+b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||g.postMessage(JSON.stringify(this.createLoadMessage("load")),"*")}));var g=window.opener||window.parent,f="json"==
+urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";g.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",mxResources.get("save")+" (Ctrl+S)");b.className=
+"geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor="pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=a.split("\n"),c=[];if(0<b.length){var d={},e=
+null,f=null,g="auto",k="auto",v=40,x=40,z=0,A=this.editor.graph;A.getGraphBounds();for(var B=function(){A.setSelectionCells(R);A.scrollCellToVisible(A.getSelectionCell())},y=A.getFreeInsertPoint(),E=y.x,D=y.y,y=D,F=null,C="auto",K=[],G=null,J=null,I=0;I<b.length&&"#"==b[I].charAt(0);){a=b[I];for(I++;I<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[I].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[I].substring(1)),I++;if("#"!=a.charAt(1)){var L=a.indexOf(":");if(0<L){var M=mxUtils.trim(a.substring(1,
+L)),Q=mxUtils.trim(a.substring(L+1));"label"==M?F=A.sanitizeHtml(Q):"style"==M?e=Q:"identity"==M&&0<Q.length&&"-"!=Q?f=Q:"width"==M?g=Q:"height"==M?k=Q:"ignore"==M?J=Q.split(","):"connect"==M?K.push(JSON.parse(Q)):"link"==M?G=Q:"padding"==M?z=parseFloat(Q):"edgespacing"==M?v=parseFloat(Q):"nodespacing"==M?x=parseFloat(Q):"layout"==M&&(C=Q)}}}var W=this.editor.csvToArray(b[I]);a=null;if(null!=f)for(var N=0;N<W.length;N++)if(f==W[N]){a=N;break}null==F&&(F="%"+W[0]+"%");if(null!=K)for(var H=0;H<K.length;H++)null==
+d[K[H].to]&&(d[K[H].to]={});A.model.beginUpdate();try{for(N=I+1;N<b.length;N++){var V=this.editor.csvToArray(b[N]);if(V.length==W.length){var O=null,ba=null!=a?V[a]:null;null!=ba&&(O=A.model.getCell(ba));null==O&&(O=new mxCell(F,new mxGeometry(E,y,0,0),e||"whiteSpace=wrap;html=1;"),O.vertex=!0,O.id=ba);for(var Y=0;Y<V.length;Y++)A.setAttributeForCell(O,W[Y],V[Y]);A.setAttributeForCell(O,"placeholders","1");O.style=A.replacePlaceholders(O,O.style);for(H=0;H<K.length;H++)d[K[H].to][O.getAttribute(K[H].to)]=
+O;null!=G&&"link"!=G&&(A.setLinkForCell(O,O.getAttribute(G)),A.setAttributeForCell(O,G,null));var S=this.editor.graph.getPreferredSizeForCell(O);O.geometry.width="auto"==g?S.width+z:parseFloat(g);O.geometry.height="auto"==k?S.height+z:parseFloat(k);y+=O.geometry.height+x;c.push(A.addCell(O))}}null==e&&A.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var P=c.slice(),R=c.slice(),H=0;H<K.length;H++)for(var X=K[H],N=0;N<c.length;N++){var O=c[N],da=O.getAttribute(X.from);if(null!=da){A.setAttributeForCell(O,
+X.from,null);for(var aa=da.split(","),Y=0;Y<aa.length;Y++){var T=d[X.to][aa[Y]];null!=T&&(R.push(A.insertEdge(null,null,X.label||"",X.invert?T:O,X.invert?O:T,X.style||A.createCurrentEdgeStyle())),mxUtils.remove(X.invert?O:T,P))}}}if(null!=J)for(N=0;N<c.length;N++)for(O=c[N],Y=0;Y<J.length;Y++)A.setAttributeForCell(O,mxUtils.trim(J[Y]),null);var ca=new mxParallelEdgeLayout(A);ca.spacing=v;var ea=function(){ca.execute(A.getDefaultParent());for(var a=0;a<c.length;a++){var b=A.getCellGeometry(c[a]);b.x=
+Math.round(A.snap(b.x));b.y=Math.round(A.snap(b.y));"auto"==g&&(b.width=Math.round(A.snap(b.width)));"auto"==k&&(b.height=Math.round(A.snap(b.height)))}};if("circle"==C){var U=new mxCircleLayout(A);U.resetEdges=!1;var Z=U.isVertexIgnored;U.isVertexIgnored=function(a){return Z.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){U.execute(A.getDefaultParent());ea()},!0,B);B=null}else if("horizontaltree"==C||"verticaltree"==C||"auto"==C&&R.length==2*c.length-1&&1==P.length){A.view.validate();
+var ga=new mxCompactTreeLayout(A,"horizontaltree"==C);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(A.getDefaultParent(),0<P.length?P[0]:null)},!0,B);B=null}else if("horizontalflow"==C||"verticalflow"==C||"auto"==C&&1==P.length){A.view.validate();var fa=new mxHierarchicalLayout(A,"horizontalflow"==C?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);fa.intraCellSpacing=x;fa.disableEdgeStyle=!1;this.executeLayout(function(){fa.execute(A.getDefaultParent(),
+R);A.moveCells(R,E,D)},!0,B);B=null}else if("organic"==C||"auto"==C&&R.length>c.length){A.view.validate();var ka=new mxFastOrganicLayout(A);ka.forceConstant=3*x;ka.resetEdges=!1;var ja=ka.isVertexIgnored;ka.isVertexIgnored=function(a){return ja.apply(this,arguments)||0>mxUtils.indexOf(c,a)};ca=new mxParallelEdgeLayout(A);ca.spacing=v;this.executeLayout(function(){ka.execute(A.getDefaultParent());ea()},!0,B);B=null}this.hideDialog()}finally{A.model.endUpdate()}null!=B&&B()}}catch(la){this.handleError(la)}};
+EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
 d;for(d in urlParams)0>mxUtils.indexOf(c,d)&&(a=0==b?a+"?":a+"&",null!=urlParams[d]&&(a+=d+"="+urlParams[d],b++))}return a};EditorUi.prototype.showLinkDialog=function(a,b,c){a=new LinkDialog(this,a,b,c,!0);this.showDialog(a.container,420,120,!0,!0);a.init()};var e=EditorUi.prototype.createOutline;EditorUi.prototype.createOutline=function(a){var b=e.apply(this,arguments),c=this.editor.graph,d=b.getSourceGraphBounds;b.getSourceGraphBounds=function(){if(mxUtils.hasScrollbars(c.container)&&c.pageVisible&&
 null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width-2*a.x/b),Math.ceil(this.source.minimumGraphSize.height-2*a.y/b))}return d.apply(this,arguments)};var f=b.getSourceContainerSize;b.getSourceContainerSize=function(){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width*
 b-2*a.x),Math.ceil(this.source.minimumGraphSize.height*b-2*a.y))}return f.apply(this,arguments)};b.getOutlineOffset=function(a){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var d=this.source.getPagePadding();return new mxPoint(Math.round(Math.max(0,(b.outline.container.clientWidth/a-(this.source.minimumGraphSize.width-2*d.x))/2)-d.x),Math.round(Math.max(0,(b.outline.container.clientHeight/a-(this.source.minimumGraphSize.height-2*d.y))/2)-d.y-5/a))}return new mxPoint(8/
@@ -8084,20 +8089,22 @@ var c=("1"!=urlParams.embed||!this.editor.graph.isEnabled())&&(null==a||a.isRest
 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.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));
 if(this.isOfflineApp()){var d=applicationCache;if(null!=d&&null==this.offlineStatus){this.offlineStatus=document.createElement("div");this.offlineStatus.className="geItem";this.offlineStatus.style.position="absolute";this.offlineStatus.style.fontSize="8pt";this.offlineStatus.style.top="2px";this.offlineStatus.style.right="12px";this.offlineStatus.style.color="#666";this.offlineStatus.style.margin="4px";this.offlineStatus.style.padding="2px";this.offlineStatus.style.verticalAlign="middle";this.offlineStatus.innerHTML=
 "";this.menubarContainer.appendChild(this.offlineStatus);mxEvent.addListener(this.offlineStatus,"click",mxUtils.bind(this,function(){var a=this.offlineStatus.getElementsByTagName("img");null!=a&&0<a.length&&this.alert(a[0].getAttribute("title"))}));var d=window.applicationCache,e=null,b=mxUtils.bind(this,function(){var a=d.status,b;a==d.CHECKING&&(a=d.DOWNLOADING);switch(a){case d.UNCACHED:b="";break;case d.IDLE:b='<img title="draw.io is up to date." border="0" src="'+IMAGE_PATH+'/checkmark.gif"/>';
-break;case d.DOWNLOADING:b='<img title="Downloading new version" border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
+break;case d.DOWNLOADING:b='<img title="Downloading new version..." border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
 "checking",b);mxEvent.addListener(d,"noupdate",b);mxEvent.addListener(d,"downloading",b);mxEvent.addListener(d,"progress",b);mxEvent.addListener(d,"cached",b);mxEvent.addListener(d,"updateready",b);mxEvent.addListener(d,"obsolete",b);mxEvent.addListener(d,"error",b);b()}}else this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};var g=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){g.apply(this,
 arguments);var a=this.editor.graph,b=this.getCurrentFile(),c=null!=b&&b.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled();this.actions.get("pageSetup").setEnabled(c);this.actions.get("autosave").setEnabled(null!=b&&b.isEditable()&&b.isAutosaveOptional());this.actions.get("guides").setEnabled(c);this.actions.get("shadowVisible").setEnabled(c);this.actions.get("connectionArrows").setEnabled(c);this.actions.get("connectionPoints").setEnabled(c);this.actions.get("copyStyle").setEnabled(c&&
 !a.isSelectionEmpty());this.actions.get("pasteStyle").setEnabled(c&&!a.isSelectionEmpty());this.actions.get("editGeometry").setEnabled(a.getModel().isVertex(a.getSelectionCell()));this.actions.get("createShape").setEnabled(c);this.actions.get("createRevision").setEnabled(c);this.actions.get("moveToFolder").setEnabled(null!=b);this.actions.get("makeCopy").setEnabled(null!=b&&!b.isRestricted());this.actions.get("editDiagram").setEnabled("1"==urlParams.embed&&this.editor.graph.isEnabled()||null!=b&&
 !b.isRestricted());this.actions.get("publishLink").setEnabled(null!=b&&!b.isRestricted());this.menus.get("publish").setEnabled(null!=b&&!b.isRestricted());a=a.view.getState(a.getSelectionCell());this.actions.get("editShape").setEnabled(c&&null!=a&&null!=a.shape&&null!=a.shape.stencil)};null!=window.ExportDialog&&(ExportDialog.showXmlOption=!1,ExportDialog.showGifOption=!1,ExportDialog.exportFile=function(a,b,c,d,e,f){var g=a.editor.graph;if("xml"==c)a.hideDialog(),a.saveData(b,"xml",mxUtils.getXml(a.editor.getGraphXml()),
 "text/xml");else if("svg"==c)a.hideDialog(),a.saveData(b,"svg",mxUtils.getXml(g.getSvg(d,e,f)),"image/svg+xml");else{var k=a.getFileData(!0,null,null,null,null,!0),l=g.getGraphBounds(),m=Math.floor(l.width*e/g.view.scale),n=Math.floor(l.height*e/g.view.scale);k.length<=MAX_REQUEST_SIZE&&m*n<MAX_AREA?(a.hideDialog(),a.saveRequest(b,c,function(a,b){return new mxXmlRequest(EXPORT_URL,"format="+c+"&base64="+(b||"0")+(null!=a?"&filename="+encodeURIComponent(a):"")+"&bg="+(null!=d?d:"none")+"&w="+m+"&h="+
-n+"&border="+f+"&xml="+encodeURIComponent(k))})):mxUtils.alert(mxResources.get("drawingTooLarge"))}})})();var mxSettings={key:".drawio-config",settings:{language:"",libraries:Sidebar.prototype.defaultEntries,customLibraries:[],plugins:[],recentColors:[],formatWidth:"240",currentEdgeStyle:Graph.prototype.defaultEdgeStyle,currentVertexStyle:Graph.prototype.defaultVertexStyle,createTarget:!1,pageFormat:mxGraph.prototype.pageFormat,search:!0,showStartScreen:!0,gridColor:mxGraphView.prototype.gridColor,autosave:!0,version:13,isNew:!0},getLanguage:function(){return this.settings.language},setLanguage:function(a){this.settings.language=
-a},getUi:function(){return this.settings.ui},setUi:function(a){this.settings.ui=a},getShowStartScreen:function(){return this.settings.showStartScreen},setShowStartScreen:function(a){this.settings.showStartScreen=a},getGridColor:function(){return this.settings.gridColor},setGridColor:function(a){this.settings.gridColor=a},getAutosave:function(){return this.settings.autosave},setAutosave:function(a){this.settings.autosave=a},getLibraries:function(){return this.settings.libraries},setLibraries:function(a){this.settings.libraries=
-a},addCustomLibrary:function(a){mxSettings.load();0>mxUtils.indexOf(this.settings.customLibraries,a)&&this.settings.customLibraries.push(a);mxSettings.save()},removeCustomLibrary:function(a){mxSettings.load();mxUtils.remove(a,this.settings.customLibraries);mxSettings.save()},getCustomLibraries:function(){return this.settings.customLibraries},getPlugins:function(){return this.settings.plugins},setPlugins:function(a){this.settings.plugins=a},getRecentColors:function(){return this.settings.recentColors},
-setRecentColors:function(a){this.settings.recentColors=a},getFormatWidth:function(){return parseInt(this.settings.formatWidth)},setFormatWidth:function(a){this.settings.formatWidth=a},getCurrentEdgeStyle:function(){return this.settings.currentEdgeStyle},setCurrentEdgeStyle:function(a){this.settings.currentEdgeStyle=a},getCurrentVertexStyle:function(){return this.settings.currentVertexStyle},setCurrentVertexStyle:function(a){this.settings.currentVertexStyle=a},isCreateTarget:function(){return this.settings.createTarget},
-setCreateTarget:function(a){this.settings.createTarget=a},getPageFormat:function(){return this.settings.pageFormat},setPageFormat:function(a){this.settings.pageFormat=a},save:function(){if(isLocalStorage&&"undefined"!==typeof JSON)try{delete this.settings.isNew,this.settings.version=12,localStorage.setItem(mxSettings.key,JSON.stringify(this.settings))}catch(a){}},load:function(){isLocalStorage&&"undefined"!==typeof JSON&&mxSettings.parse(localStorage.getItem(mxSettings.key))},parse:function(a){null!=
-a&&(this.settings=JSON.parse(a),null==this.settings.plugins&&(this.settings.plugins=[]),null==this.settings.recentColors&&(this.settings.recentColors=[]),null==this.settings.libraries&&(this.settings.libraries=Sidebar.prototype.defaultEntries),null==this.settings.customLibraries&&(this.settings.customLibraries=[]),null==this.settings.ui&&(this.settings.ui=""),null==this.settings.formatWidth&&(this.settings.formatWidth="240"),null!=this.settings.lastAlert&&delete this.settings.lastAlert,null==this.settings.currentEdgeStyle?
-this.settings.currentEdgeStyle=Graph.prototype.defaultEdgeStyle:10>=this.settings.version&&(this.settings.currentEdgeStyle.orthogonalLoop=1,this.settings.currentEdgeStyle.jettySize="auto"),null==this.settings.currentVertexStyle&&(this.settings.currentVertexStyle=Graph.prototype.defaultEdgeStyle),null==this.settings.createTarget&&(this.settings.createTarget=!1),null==this.settings.pageFormat&&(this.settings.pageFormat=mxGraph.prototype.pageFormat),null==this.settings.search&&(this.settings.search=
-!0),null==this.settings.showStartScreen&&(this.settings.showStartScreen=!0),null==this.settings.gridColor&&(this.settings.gridColor=mxGraphView.prototype.gridColor),null==this.settings.autosave&&(this.settings.autosave=!0),null!=this.settings.scratchpadSeen&&delete this.settings.scratchpadSeen)},clear:function(){isLocalStorage&&localStorage.removeItem(mxSettings.key)}};("undefined"==typeof mxLoadSettings||mxLoadSettings)&&mxSettings.load();Graph.prototype.defaultThemes[Graph.prototype.defaultThemeName]=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="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><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="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></mxStylesheet>').documentElement;function mxAsyncCanvas(a){mxAbstractCanvas2D.call(this);this.htmlCanvas=a;a.images=a.images||[];a.subCanvas=a.subCanvas||[]}mxUtils.extend(mxAsyncCanvas,mxAbstractCanvas2D);mxAsyncCanvas.prototype.htmlCanvas=null;mxAsyncCanvas.prototype.canvasIndex=0;mxAsyncCanvas.prototype.waitCounter=0;mxAsyncCanvas.prototype.onComplete=null;mxAsyncCanvas.prototype.incWaitCounter=function(){this.waitCounter++};
+n+"&border="+f+"&xml="+encodeURIComponent(k))})):mxUtils.alert(mxResources.get("drawingTooLarge"))}})})();var mxSettings={currentVersion:14,defaultFormatWidth:600>screen.width?"0":"240",key:".drawio-config",getLanguage:function(){return mxSettings.settings.language},setLanguage:function(a){mxSettings.settings.language=a},getUi:function(){return mxSettings.settings.ui},setUi:function(a){mxSettings.settings.ui=a},getShowStartScreen:function(){return mxSettings.settings.showStartScreen},setShowStartScreen:function(a){mxSettings.settings.showStartScreen=a},getGridColor:function(){return mxSettings.settings.gridColor},
+setGridColor:function(a){mxSettings.settings.gridColor=a},getAutosave:function(){return mxSettings.settings.autosave},setAutosave:function(a){mxSettings.settings.autosave=a},getLibraries:function(){return mxSettings.settings.libraries},setLibraries:function(a){mxSettings.settings.libraries=a},addCustomLibrary:function(a){mxSettings.load();0>mxUtils.indexOf(mxSettings.settings.customLibraries,a)&&("L.scratchpad"===a?mxSettings.settings.customLibraries.splice(0,0,a):mxSettings.settings.customLibraries.push(a));
+mxSettings.save()},removeCustomLibrary:function(a){mxSettings.load();mxUtils.remove(a,mxSettings.settings.customLibraries);mxSettings.save()},getCustomLibraries:function(){return mxSettings.settings.customLibraries},getPlugins:function(){return mxSettings.settings.plugins},setPlugins:function(a){mxSettings.settings.plugins=a},getRecentColors:function(){return mxSettings.settings.recentColors},setRecentColors:function(a){mxSettings.settings.recentColors=a},getFormatWidth:function(){return parseInt(mxSettings.settings.formatWidth)},
+setFormatWidth:function(a){mxSettings.settings.formatWidth=a},getCurrentEdgeStyle:function(){return mxSettings.settings.currentEdgeStyle},setCurrentEdgeStyle:function(a){mxSettings.settings.currentEdgeStyle=a},getCurrentVertexStyle:function(){return mxSettings.settings.currentVertexStyle},setCurrentVertexStyle:function(a){mxSettings.settings.currentVertexStyle=a},isCreateTarget:function(){return mxSettings.settings.createTarget},setCreateTarget:function(a){mxSettings.settings.createTarget=a},getPageFormat:function(){return mxSettings.settings.pageFormat},
+setPageFormat:function(a){mxSettings.settings.pageFormat=a},init:function(){mxSettings.settings={language:"",libraries:Sidebar.prototype.defaultEntries,customLibraries:Editor.defaultCustomLibraries,plugins:[],recentColors:[],formatWidth:mxSettings.defaultFormatWidth,currentEdgeStyle:Graph.prototype.defaultEdgeStyle,currentVertexStyle:Graph.prototype.defaultVertexStyle,createTarget:!1,pageFormat:mxGraph.prototype.pageFormat,search:!0,showStartScreen:!0,gridColor:mxGraphView.prototype.gridColor,autosave:!0,
+version:mxSettings.currentVersion,isNew:!0}},save:function(){if(isLocalStorage&&"undefined"!==typeof JSON)try{delete mxSettings.settings.isNew,mxSettings.settings.version=mxSettings.currentVersion,localStorage.setItem(mxSettings.key,JSON.stringify(mxSettings.settings))}catch(a){}},load:function(){isLocalStorage&&"undefined"!==typeof JSON&&mxSettings.parse(localStorage.getItem(mxSettings.key));null==mxSettings.settings&&mxSettings.init()},parse:function(a){null!=a&&(mxSettings.settings=JSON.parse(a),
+null==mxSettings.settings.plugins&&(mxSettings.settings.plugins=[]),null==mxSettings.settings.recentColors&&(mxSettings.settings.recentColors=[]),null==mxSettings.settings.libraries&&(mxSettings.settings.libraries=Sidebar.prototype.defaultEntries),null==mxSettings.settings.customLibraries&&(mxSettings.settings.customLibraries=Editor.defaultCustomLibraries),null==mxSettings.settings.ui&&(mxSettings.settings.ui=""),null==mxSettings.settings.formatWidth&&(mxSettings.settings.formatWidth=mxSettings.defaultFormatWidth),
+null!=mxSettings.settings.lastAlert&&delete mxSettings.settings.lastAlert,null==mxSettings.settings.currentEdgeStyle?mxSettings.settings.currentEdgeStyle=Graph.prototype.defaultEdgeStyle:10>=mxSettings.settings.version&&(mxSettings.settings.currentEdgeStyle.orthogonalLoop=1,mxSettings.settings.currentEdgeStyle.jettySize="auto"),null==mxSettings.settings.currentVertexStyle&&(mxSettings.settings.currentVertexStyle=Graph.prototype.defaultVertexStyle),null==mxSettings.settings.createTarget&&(mxSettings.settings.createTarget=
+!1),null==mxSettings.settings.pageFormat&&(mxSettings.settings.pageFormat=mxGraph.prototype.pageFormat),null==mxSettings.settings.search&&(mxSettings.settings.search=!0),null==mxSettings.settings.showStartScreen&&(mxSettings.settings.showStartScreen=!0),null==mxSettings.settings.gridColor&&(mxSettings.settings.gridColor=mxGraphView.prototype.gridColor),null==mxSettings.settings.autosave&&(mxSettings.settings.autosave=!0),null!=mxSettings.settings.scratchpadSeen&&delete mxSettings.settings.scratchpadSeen)},
+clear:function(){isLocalStorage&&localStorage.removeItem(mxSettings.key)}};("undefined"==typeof mxLoadSettings||mxLoadSettings)&&mxSettings.load();Graph.prototype.defaultThemes[Graph.prototype.defaultThemeName]=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="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><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="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></mxStylesheet>').documentElement;function mxAsyncCanvas(a){mxAbstractCanvas2D.call(this);this.htmlCanvas=a;a.images=a.images||[];a.subCanvas=a.subCanvas||[]}mxUtils.extend(mxAsyncCanvas,mxAbstractCanvas2D);mxAsyncCanvas.prototype.htmlCanvas=null;mxAsyncCanvas.prototype.canvasIndex=0;mxAsyncCanvas.prototype.waitCounter=0;mxAsyncCanvas.prototype.onComplete=null;mxAsyncCanvas.prototype.incWaitCounter=function(){this.waitCounter++};
 mxAsyncCanvas.prototype.decWaitCounter=function(){this.waitCounter--;0==this.waitCounter&&null!=this.onComplete&&(this.onComplete(),this.onComplete=null)};mxAsyncCanvas.prototype.updateFont=function(){var a="";(this.state.fontStyle&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD&&(a+="bold ");(this.state.fontStyle&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC&&(a+="italic ");this.ctx.font=a+this.state.fontSize+"px "+this.state.fontFamily};mxAsyncCanvas.prototype.rotate=function(a,c,f,d,b){};
 mxAsyncCanvas.prototype.setAlpha=function(a){this.state.alpha=a};mxAsyncCanvas.prototype.setFontColor=function(a){this.state.fontColor=a};mxAsyncCanvas.prototype.setFontBackgroundColor=function(a){a==mxConstants.NONE&&(a=null);this.state.fontBackgroundColor=a};mxAsyncCanvas.prototype.setFontBorderColor=function(a){a==mxConstants.NONE&&(a=null);this.state.fontBorderColor=a};mxAsyncCanvas.prototype.setFontSize=function(a){this.state.fontSize=a};
 mxAsyncCanvas.prototype.setFontFamily=function(a){this.state.fontFamily=a};mxAsyncCanvas.prototype.setFontStyle=function(a){this.state.fontStyle=a};mxAsyncCanvas.prototype.rect=function(a,c,f,d){};mxAsyncCanvas.prototype.roundrect=function(a,c,f,d,b,e){};mxAsyncCanvas.prototype.ellipse=function(a,c,f,d){};mxAsyncCanvas.prototype.rewriteImageSource=function(a){if("http://"==a.substring(0,7)||"https://"==a.substring(0,8))a="/proxy?url="+encodeURIComponent(a);return a};
@@ -8386,24 +8393,25 @@ ChatWindow.prototype.handleResize=function(){var a=this.window.getElement(),c=th
 ChatWindow.prototype.collaboratorListener=function(a){if(!a.collaborator.isMe){if(a.type==gapi.drive.realtime.EventType.COLLABORATOR_JOINED)a='<span style="color : '+a.collaborator.color+';">&#x25B2</span><i>'+mxResources.get("chatJoined",[a.collaborator.displayName])+"</i>";else if(a.type==gapi.drive.realtime.EventType.COLLABORATOR_LEFT)a='<span style="color : '+a.collaborator.color+';">&#x25BC</span><i>'+mxResources.get("chatLeft",[a.collaborator.displayName])+"</i>";else return;this.chatArea.innerHTML=
 this.chatArea.innerHTML+a+"<br>";this.chatArea.scrollTop=this.chatArea.scrollHeight}};ChatWindow.prototype.configCollabInfo=function(){for(var a=this.doc.getCollaborators(),c=0;c<a.length;c++){var f=a[c];f.isMe&&(this.collabColor=f.color,this.displayName=f.displayName)}};ChatWindow.prototype.destroy=function(){this.window.destroy()};ChatWindow.prototype.htmlEscape=function(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")};App=function(a,c,f){EditorUi.call(this,a,c,null!=f?f:"1"==urlParams.lightbox);mxClient.IS_SVG?mxGraph.prototype.warningImage.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAE7SURBVHjaYvz//z8DJQAggBjwGXDuHMP/tWuD/uPTCxBAOA0AaQRK/f/+XeJ/cbHlf1wGAAQQTgPu3QNLgfHSpZo4DQAIIKwGwGyH4e/fFbG6AiQJEEAs2Ew2NFzH8OOHBMO6dT/A/KCg7wxGRh+wuhQggDBcALMdFIAcHBxgDGJjcwVIIUAAYbhAUXEdVos4OO4DXcGBIQ4QQCguQPY7sgtgAYruCpAgQACx4LJdU1OCwctLEcyWlLwPJF+AXQE0EMUBAAEEdwF6yMOiD4RRY0QT7gqQAEAAseDzu6XldYYPH9DD4joQa8L5AAEENgWb7SBcXa0JDQMBrK4AcQACiAlfyOMCEFdAnAYQQEz4FLa0XGf4/v0H0IIPONUABBAjyBmMjIwMS5cK/L927QORbtBkaG29DtYLEGAAH6f7oq3Zc+kAAAAASUVORK5CYII=":
 (new Image).src=mxGraph.prototype.warningImage.src;window.openWindow=mxUtils.bind(this,function(a,b,c){var d=null;try{d=window.open(a)}catch(k){}null==d||void 0===d?this.showDialog((new PopupDialog(this,a,b,c)).container,320,140,!0,!0):null!=b&&b()});this.updateDocumentTitle();this.updateUi();a=document.createElement("canvas");this.canvasSupported=!(!a.getContext||!a.getContext("2d"));window.showOpenAlert=mxUtils.bind(this,function(a){null!=window.openFile&&window.openFile.cancel(!0);this.handleError(a)});
-this.isOffline()||(EditDataDialog.placeholderHelpLink="https://desk.draw.io/support/solutions/articles/16000051979");ColorDialog.recentColors=mxSettings.getRecentColors(ColorDialog.recentColors);this.addFileDropHandler([document]);if(null!=App.DrawPlugins){for(a=0;a<App.DrawPlugins.length;a++)try{App.DrawPlugins[a](this)}catch(d){null!=window.console&&console.log("Plugin Error:",d,App.DrawPlugins[a])}window.Draw.loadPlugin=function(a){a(this)}}this.load()};App.ERROR_TIMEOUT="timeout";
-App.ERROR_BUSY="busy";App.ERROR_UNKNOWN="unknown";App.MODE_GOOGLE="google";App.MODE_DROPBOX="dropbox";App.MODE_ONEDRIVE="onedrive";App.MODE_GITHUB="github";App.MODE_DEVICE="device";App.MODE_BROWSER="browser";App.DROPBOX_APPKEY="libwls2fa9szdji";App.DROPBOX_URL="https://unpkg.com/dropbox/dist/Dropbox-sdk.min.js";App.DROPINS_URL="https://www.dropbox.com/static/api/2/dropins.js";App.ONEDRIVE_URL="https://js.live.net/v7.0/OneDrive.js";
+this.isOffline()||(EditDataDialog.placeholderHelpLink="https://desk.draw.io/support/solutions/articles/16000051979");this.addFileDropHandler([document]);if(null!=App.DrawPlugins){for(a=0;a<App.DrawPlugins.length;a++)try{App.DrawPlugins[a](this)}catch(d){null!=window.console&&console.log("Plugin Error:",d,App.DrawPlugins[a])}window.Draw.loadPlugin=mxUtils.bind(this,function(a){a(this)})}this.load()};App.ERROR_TIMEOUT="timeout";App.ERROR_BUSY="busy";App.ERROR_UNKNOWN="unknown";App.MODE_GOOGLE="google";
+App.MODE_DROPBOX="dropbox";App.MODE_ONEDRIVE="onedrive";App.MODE_GITHUB="github";App.MODE_DEVICE="device";App.MODE_BROWSER="browser";App.DROPBOX_APPKEY="libwls2fa9szdji";App.DROPBOX_URL="https://unpkg.com/dropbox/dist/Dropbox-sdk.min.js";App.DROPINS_URL="https://www.dropbox.com/static/api/2/dropins.js";App.ONEDRIVE_URL="https://js.live.net/v7.0/OneDrive.js";
 App.pluginRegistry={"4xAKTrabTpTzahoLthkwPNUn":"/plugins/explore.js",ex:"/plugins/explore.js",p1:"/plugins/p1.js",ac:"/plugins/connect.js",acj:"/plugins/connectJira.js",voice:"/plugins/voice.js",tips:"/plugins/tooltips.js",svgdata:"/plugins/svgdata.js",doors:"/plugins/doors.js",electron:"plugins/electron.js",number:"/plugins/number.js",sql:"/plugins/sql.js",props:"/plugins/props.js",text:"/plugins/text.js",anim:"/plugins/animation.js",update:"/plugins/update.js",trees:"/plugins/trees/trees.js","import":"/plugins/import.js",
 replay:"/plugins/replay.js"};App.getStoredMode=function(){var a=null;null==a&&isLocalStorage&&(a=localStorage.getItem(".mode"));if(null==a&&"undefined"!=typeof Storage){for(var c=document.cookie.split(";"),f=0;f<c.length;f++){var d=mxUtils.trim(c[f]);if("MODE="==d.substring(0,5)){a=d.substring(5);break}}null!=a&&isLocalStorage&&(c=new Date,c.setYear(c.getFullYear()-1),document.cookie="MODE=; expires="+c.toUTCString(),localStorage.setItem(".mode",a))}return a};
-(function(){if(!mxClient.IS_CHROMEAPP&&("1"!=urlParams.offline&&("db.draw.io"==window.location.hostname&&null==urlParams.mode&&(urlParams.mode="dropbox"),App.mode=urlParams.mode,null==App.mode&&(App.mode=App.getStoredMode())),null!=window.mxscript&&("1"!=urlParams.embed&&("function"===typeof window.DriveClient&&("0"!=urlParams.gapi&&isSvgBrowser&&(null==document.documentMode||10<=document.documentMode)?App.mode==App.MODE_GOOGLE||null!=urlParams.state&&""==window.location.hash||null!=window.location.hash&&
+(function(){mxClient.IS_CHROMEAPP||("1"!=urlParams.offline&&("db.draw.io"==window.location.hostname&&null==urlParams.mode&&(urlParams.mode="dropbox"),App.mode=urlParams.mode,null==App.mode&&(App.mode=App.getStoredMode())),null!=window.mxscript&&("1"!=urlParams.embed&&("function"===typeof window.DriveClient&&("0"!=urlParams.gapi&&isSvgBrowser&&(null==document.documentMode||10<=document.documentMode)?App.mode==App.MODE_GOOGLE||null!=urlParams.state&&""==window.location.hash||null!=window.location.hash&&
 "#G"==window.location.hash.substring(0,2)?mxscript("https://apis.google.com/js/api.js"):"0"!=urlParams.chrome||null!=window.location.hash&&"#Uhttps%3A%2F%2Fdrive.google.com%2Fuc%3Fid%3D"===window.location.hash.substring(0,45)||(window.DriveClient=null):window.DriveClient=null),"function"===typeof window.DropboxClient&&("0"!=urlParams.db&&isSvgBrowser&&(null==document.documentMode||9<document.documentMode)?App.mode==App.MODE_DROPBOX||null!=window.location.hash&&"#D"==window.location.hash.substring(0,
 2)?(mxscript(App.DROPBOX_URL),mxscript(App.DROPINS_URL,null,"dropboxjs",App.DROPBOX_APPKEY)):"0"==urlParams.chrome&&(window.DropboxClient=null):window.DropboxClient=null),"function"===typeof window.OneDriveClient&&("0"!=urlParams.od&&(0>navigator.userAgent.indexOf("MSIE")||10<=document.documentMode)?App.mode==App.MODE_ONEDRIVE||null!=window.location.hash&&"#W"==window.location.hash.substring(0,2)?mxscript(App.ONEDRIVE_URL):"0"==urlParams.chrome&&(window.OneDriveClient=null):window.OneDriveClient=
-null)),"undefined"==typeof JSON&&mxscript("js/json/json2.min.js")),"0"!=urlParams.plugins&&"1"!=urlParams.offline)){var a=mxSettings.getPlugins(),c=urlParams.p;if(null!=c||null!=a&&0<a.length)App.DrawPlugins=[],window.Draw={},window.Draw.loadPlugin=function(a){App.DrawPlugins.push(a)};if(null!=c)for(var f=c.split(";"),c=0;c<f.length;c++){var d=App.pluginRegistry[f[c]];null!=d?mxscript(d):null!=window.console&&console.log("Unknown plugin:",f[c])}if(null!=a&&0<a.length&&"0"!=urlParams.plugins){f=window.location.protocol+
-"//"+window.location.host;d=!0;for(c=0;c<a.length&&d;c++)"/"!=a[c].charAt(0)&&a[c].substring(0,f.length)!=f&&(d=!1);if(d||mxUtils.confirm(mxResources.replacePlaceholders("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",[a.join("\n")]).replace(/\\n/g,"\n")))for(c=0;c<a.length;c++)try{mxscript(a[c])}catch(b){}}}})();
-App.main=function(a){var c=null;EditorUi.enableLogging&&(window.onerror=function(a,b,e,f,k){try{if(a!=c&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&null!=a&&0>a.indexOf("DocumentClosedError")){c=a;var d=new Image,g=0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";d.src=(null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"")+"/log?severity="+g+"&v="+encodeURIComponent(EditorUi.VERSION)+
-"&msg=clientError:"+encodeURIComponent(a)+":url:"+encodeURIComponent(window.location.href)+":lnum:"+encodeURIComponent(e)+(null!=f?":colno:"+encodeURIComponent(f):"")+(null!=k&&null!=k.stack?"&stack="+encodeURIComponent(k.stack):"")}}catch(n){}});"atlas"==uiTheme&&mxClient.link("stylesheet","styles/atlas.css");if(null!=window.mxscript){"0"!=urlParams.chrome&&mxscript("js/jscolor/jscolor.js");if("1"==urlParams.offline){mxscript("js/shapes.min.js");var f=document.createElement("iframe");f.setAttribute("width",
+null)),"undefined"==typeof JSON&&mxscript("js/json/json2.min.js")))})();
+App.main=function(a){var c=null;EditorUi.enableLogging&&(window.onerror=function(a,b,d,e,f){try{if(a!=c&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&null!=a&&0>a.indexOf("DocumentClosedError")){c=a;var g=new Image,k=0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";g.src=(null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"")+"/log?severity="+k+"&v="+encodeURIComponent(EditorUi.VERSION)+
+"&msg=clientError:"+encodeURIComponent(a)+":url:"+encodeURIComponent(window.location.href)+":lnum:"+encodeURIComponent(d)+(null!=e?":colno:"+encodeURIComponent(e):"")+(null!=f&&null!=f.stack?"&stack="+encodeURIComponent(f.stack):"")}}catch(t){}});"atlas"==uiTheme&&mxClient.link("stylesheet","styles/atlas.css");if(null!=window.mxscript){"0"!=urlParams.chrome&&mxscript("js/jscolor/jscolor.js");if("1"==urlParams.offline){mxscript("js/shapes.min.js");var f=document.createElement("iframe");f.setAttribute("width",
 "0");f.setAttribute("height","0");f.setAttribute("src","offline.html");document.body.appendChild(f);mxStencilRegistry.stencilSet={};mxStencilRegistry.getStencil=function(a){return mxStencilRegistry.stencils[a]};mxStencilRegistry.loadStencilSet=function(a,b,c){a=a.substring(a.indexOf("/")+1);a="mxgraph."+a.substring(0,a.length-4).replace(/\//g,".");a=mxStencilRegistry.stencilSet[a];null!=a&&mxStencilRegistry.parseStencilSet(a,b,!1)};for(f=mxUtils.load("stencils.xml").getXml().documentElement.firstChild;null!=
-f;)"shapes"==f.nodeName&&null!=f.getAttribute("name")&&(mxStencilRegistry.stencilSet[f.getAttribute("name").toLowerCase()]=f,mxStencilRegistry.parseStencilSet(f)),f=f.nextSibling}"0"==urlParams.picker||mxClient.IS_QUIRKS||8==document.documentMode||mxscript(document.location.protocol+"//www.google.com/jsapi?autoload=%7B%22modules%22%3A%5B%7B%22name%22%3A%22picker%22%2C%22version%22%3A%221%22%2C%22language%22%3A%22"+mxClient.language+"%22%7D%5D%7D");"function"===typeof window.DriveClient&&"undefined"===
-typeof gapi&&("1"!=urlParams.embed&&"0"!=urlParams.gapi||"1"==urlParams.embed&&"1"==urlParams.gapi)&&isSvgBrowser&&isLocalStorage&&(null==document.documentMode||10<=document.documentMode)?mxscript("https://apis.google.com/js/api.js?onload=DrawGapiClientCallback"):"undefined"===typeof window.gapi&&(window.DriveClient=null)}"0"!=urlParams.math&&Editor.initMath();mxResources.loadDefaultBundle=!1;f=mxResources.getDefaultBundle(RESOURCE_BASE,mxLanguage)||mxResources.getSpecialBundle(RESOURCE_BASE,mxLanguage);
-mxUtils.getAll("1"!=urlParams.dev?[f]:[f,STYLE_PATH+"/default.xml"],function(c){mxResources.parse(c[0].getText());1<c.length&&(Graph.prototype.defaultThemes[Graph.prototype.defaultThemeName]=c[1].getDocumentElement());c=new App(new Editor("0"==urlParams.chrome));if(null!=window.mxscript){if("function"===typeof window.DropboxClient&&null==window.Dropbox&&null!=window.DrawDropboxClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.db||"1"==urlParams.embed&&"1"==urlParams.db)&&isSvgBrowser&&(null==
-document.documentMode||9<document.documentMode))mxscript(App.DROPBOX_URL,function(){mxscript(App.DROPINS_URL,function(){DrawDropboxClientCallback()},"dropboxjs",App.DROPBOX_APPKEY)});else if("undefined"===typeof window.Dropbox||"undefined"===typeof window.Dropbox.choose)window.DropboxClient=null;"function"===typeof window.OneDriveClient&&"undefined"===typeof OneDrive&&null!=window.DrawOneDriveClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.od||"1"==urlParams.embed&&"1"==urlParams.od)&&(0>navigator.userAgent.indexOf("MSIE")||
-10<=document.documentMode)?mxscript(App.ONEDRIVE_URL,window.DrawOneDriveClientCallback):"undefined"===typeof window.OneDrive&&(window.OneDriveClient=null)}null!=a&&a(c);"0"!=urlParams.chrome&&"1"==urlParams.test&&(mxLog.show(),mxLog.debug("Started in "+((new Date).getTime()-t0.getTime())+"ms"),mxLog.debug("Export:",EXPORT_URL),mxLog.debug("Development mode:","1"==urlParams.dev?"active":"inactive"),mxLog.debug("Test mode:","1"==urlParams.test?"active":"inactive"))},function(){document.getElementById("geStatus").innerHTML=
-'Error loading page. <a href="javascript:void(0);" onclick="location.reload();">Please try refreshing.</a>'})};mxUtils.extend(App,EditorUi);App.prototype.defaultUserPicture="https://lh3.googleusercontent.com/-HIzvXUy6QUY/AAAAAAAAAAI/AAAAAAAAAAA/giuR7PQyjEk/photo.jpg?sz=30";App.prototype.shareImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA2RpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDowOTgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoxMjU2NzdEMTcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoxMjU2NzdEMDcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ1M1IFdpbmRvd3MiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowNjgwMTE3NDA3MjA2ODExODcxRkM4MUY1OTFDMjQ5OCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowNzgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PrM/fs0AAADgSURBVHjaYmDAA/7//88MwgzkAKDGFiD+BsQ/QWxSNaf9RwN37twpI8WAS+gGfP78+RpQSoRYA36iG/D379+vQClNdLVMOMz4gi7w79+/n0CKg1gD9qELvH379hzIHGK9oA508ieY8//8+fO5rq4uFCilRKwL1JmYmNhhHEZGRiZ+fn6Q2meEbDYG4u3/cYCfP38uA7kOm0ZOIJ7zn0jw48ePPiDFhmzArv8kgi9fvuwB+w5qwH9ykjswbFSZyM4sEMDPBDTlL5BxkFSd7969OwZ2BZKYGhDzkmjOJ4AAAwBhpRqGnEFb8QAAAABJRU5ErkJggg==";
+f;)"shapes"==f.nodeName&&null!=f.getAttribute("name")&&(mxStencilRegistry.stencilSet[f.getAttribute("name").toLowerCase()]=f,mxStencilRegistry.parseStencilSet(f)),f=f.nextSibling}"0"==urlParams.picker||mxClient.IS_QUIRKS||8==document.documentMode||mxscript(document.location.protocol+"//www.google.com/jsapi?autoload=%7B%22modules%22%3A%5B%7B%22name%22%3A%22picker%22%2C%22version%22%3A%221%22%2C%22language%22%3A%22"+mxClient.language+"%22%7D%5D%7D");if("0"!=urlParams.plugins&&"1"!=urlParams.offline){var f=
+mxSettings.getPlugins(),d=urlParams.p;if(null!=d||null!=f&&0<f.length)App.DrawPlugins=[],window.Draw={},window.Draw.loadPlugin=function(a){App.DrawPlugins.push(a)};if(null!=d)for(var b=d.split(";"),d=0;d<b.length;d++){var e=App.pluginRegistry[b[d]];null!=e?mxscript(e):null!=window.console&&console.log("Unknown plugin:",b[d])}if(null!=f&&0<f.length&&"0"!=urlParams.plugins){b=window.location.protocol+"//"+window.location.host;e=!0;for(d=0;d<f.length&&e;d++)"/"!=f[d].charAt(0)&&f[d].substring(0,b.length)!=
+b&&(e=!1);if(e||mxUtils.confirm(mxResources.replacePlaceholders("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",[f.join("\n")]).replace(/\\n/g,"\n")))for(d=0;d<f.length;d++)try{mxscript(f[d])}catch(g){}}}"function"===typeof window.DriveClient&&"undefined"===typeof gapi&&("1"!=urlParams.embed&&"0"!=urlParams.gapi||"1"==urlParams.embed&&
+"1"==urlParams.gapi)&&isSvgBrowser&&isLocalStorage&&(null==document.documentMode||10<=document.documentMode)?mxscript("https://apis.google.com/js/api.js?onload=DrawGapiClientCallback"):"undefined"===typeof window.gapi&&(window.DriveClient=null)}"0"!=urlParams.math&&Editor.initMath();mxResources.loadDefaultBundle=!1;f=mxResources.getDefaultBundle(RESOURCE_BASE,mxLanguage)||mxResources.getSpecialBundle(RESOURCE_BASE,mxLanguage);mxUtils.getAll("1"!=urlParams.dev?[f]:[f,STYLE_PATH+"/default.xml"],function(b){mxResources.parse(b[0].getText());
+1<b.length&&(Graph.prototype.defaultThemes[Graph.prototype.defaultThemeName]=b[1].getDocumentElement());b=new App(new Editor("0"==urlParams.chrome));if(null!=window.mxscript){if("function"===typeof window.DropboxClient&&null==window.Dropbox&&null!=window.DrawDropboxClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.db||"1"==urlParams.embed&&"1"==urlParams.db)&&isSvgBrowser&&(null==document.documentMode||9<document.documentMode))mxscript(App.DROPBOX_URL,function(){mxscript(App.DROPINS_URL,function(){DrawDropboxClientCallback()},
+"dropboxjs",App.DROPBOX_APPKEY)});else if("undefined"===typeof window.Dropbox||"undefined"===typeof window.Dropbox.choose)window.DropboxClient=null;"function"===typeof window.OneDriveClient&&"undefined"===typeof OneDrive&&null!=window.DrawOneDriveClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.od||"1"==urlParams.embed&&"1"==urlParams.od)&&(0>navigator.userAgent.indexOf("MSIE")||10<=document.documentMode)?mxscript(App.ONEDRIVE_URL,window.DrawOneDriveClientCallback):"undefined"===typeof window.OneDrive&&
+(window.OneDriveClient=null)}null!=a&&a(b);"0"!=urlParams.chrome&&"1"==urlParams.test&&(mxLog.show(),mxLog.debug("Started in "+((new Date).getTime()-t0.getTime())+"ms"),mxLog.debug("Export:",EXPORT_URL),mxLog.debug("Development mode:","1"==urlParams.dev?"active":"inactive"),mxLog.debug("Test mode:","1"==urlParams.test?"active":"inactive"))},function(){document.getElementById("geStatus").innerHTML='Error loading page. <a href="javascript:void(0);" onclick="location.reload();">Please try refreshing.</a>'})};
+mxUtils.extend(App,EditorUi);App.prototype.defaultUserPicture="https://lh3.googleusercontent.com/-HIzvXUy6QUY/AAAAAAAAAAI/AAAAAAAAAAA/giuR7PQyjEk/photo.jpg?sz=30";App.prototype.shareImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA2RpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDowOTgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoxMjU2NzdEMTcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoxMjU2NzdEMDcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ1M1IFdpbmRvd3MiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowNjgwMTE3NDA3MjA2ODExODcxRkM4MUY1OTFDMjQ5OCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowNzgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PrM/fs0AAADgSURBVHjaYmDAA/7//88MwgzkAKDGFiD+BsQ/QWxSNaf9RwN37twpI8WAS+gGfP78+RpQSoRYA36iG/D379+vQClNdLVMOMz4gi7w79+/n0CKg1gD9qELvH379hzIHGK9oA508ieY8//8+fO5rq4uFCilRKwL1JmYmNhhHEZGRiZ+fn6Q2meEbDYG4u3/cYCfP38uA7kOm0ZOIJ7zn0jw48ePPiDFhmzArv8kgi9fvuwB+w5qwH9ykjswbFSZyM4sEMDPBDTlL5BxkFSd7969OwZ2BZKYGhDzkmjOJ4AAAwBhpRqGnEFb8QAAAABJRU5ErkJggg==";
 App.prototype.chevronUpImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NDg2NEE3NUY1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6NDg2NEE3NjA1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo0ODY0QTc1RDUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo0ODY0QTc1RTUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pg+qUokAAAAMUExURQAAANnZ2b+/v////5bgre4AAAAEdFJOU////wBAKqn0AAAAL0lEQVR42mJgRgMMRAswMKAKMDDARBjg8lARBoR6KImkH0wTbygT6YaS4DmAAAMAYPkClOEDDD0AAAAASUVORK5CYII=":
 IMAGE_PATH+"/chevron-up.png";
 App.prototype.chevronDownImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NDg2NEE3NUI1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6NDg2NEE3NUM1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo0ODY0QTc1OTUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo0ODY0QTc1QTUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PsCtve8AAAAMUExURQAAANnZ2b+/v////5bgre4AAAAEdFJOU////wBAKqn0AAAALUlEQVR42mJgRgMMRAkwQEXBNAOcBSPhclB1cNVwfcxI+vEZykSpoSR6DiDAAF23ApT99bZ+AAAAAElFTkSuQmCC":IMAGE_PATH+
@@ -8411,7 +8419,7 @@ App.prototype.chevronDownImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGg
 App.prototype.formatShowImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6ODdCREY5REY1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6ODdCREY5RTA1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo4N0JERjlERDU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo4N0JERjlERTU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PlnMQ/8AAAAJUExURQAAAP///3FxcTfTiAsAAAACdFJOU/8A5bcwSgAAACFJREFUeNpiYEQDDEQJMMABTAAixcQ00ALoDiPRcwABBgB6DADly9Yx8wAAAABJRU5ErkJggg==":IMAGE_PATH+
 "/format-show.png";
 App.prototype.formatHideImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6ODdCREY5REI1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6ODdCREY5REM1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo4N0JERjlEOTU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo4N0JERjlEQTU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PqjT9SMAAAAGUExURQAAAP///6XZn90AAAACdFJOU/8A5bcwSgAAAB9JREFUeNpiYEQDDEQJMMABTAAmNdAC6A4j0XMAAQYAcbwA1Xvj1CgAAAAASUVORK5CYII=":IMAGE_PATH+
-"/format-hide.png";App.prototype.fullscreenImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAAAAAClZ7nPAAAAAXRSTlMAQObYZgAAABpJREFUCNdjgAAbGxAy4AEh5gNwBBGByoIBAIueBd12TUjqAAAAAElFTkSuQmCC":IMAGE_PATH+"/fullscreen.png";App.prototype.timeout=25E3;App.prototype.formatEnabled="0"!=urlParams.format;App.prototype.formatWidth=600>screen.width?0:mxSettings.getFormatWidth();"1"!=urlParams.embed&&(App.prototype.menubarHeight=60);
+"/format-hide.png";App.prototype.fullscreenImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAAAAAClZ7nPAAAAAXRSTlMAQObYZgAAABpJREFUCNdjgAAbGxAy4AEh5gNwBBGByoIBAIueBd12TUjqAAAAAElFTkSuQmCC":IMAGE_PATH+"/fullscreen.png";App.prototype.timeout=25E3;"1"!=urlParams.embed&&(App.prototype.menubarHeight=60);
 App.prototype.init=function(){EditorUi.prototype.init.apply(this,arguments);this.defaultLibraryName=mxResources.get("untitledLibrary");this.descriptorChangedListener=mxUtils.bind(this,this.descriptorChanged);this.gitHub=mxClient.IS_IE&&10!=document.documentMode&&!mxClient.IS_IE11&&!mxClient.IS_EDGE||"0"==urlParams.gh||"1"==urlParams.embed&&"1"!=urlParams.gh?null:new GitHubClient(this);null!=this.gitHub&&this.gitHub.addListener("userChanged",mxUtils.bind(this,function(){this.updateUserElement();this.restoreLibraries()}));
 if("1"!=urlParams.embed||"1"==urlParams.od){var a=mxUtils.bind(this,function(){"undefined"!==typeof OneDrive?(this.oneDrive=new OneDriveClient(this),this.oneDrive.addListener("userChanged",mxUtils.bind(this,function(){this.updateUserElement();this.restoreLibraries()})),this.fireEvent(new mxEventObject("clientLoaded","client",this.oneDrive))):null==window.DrawOneDriveClientCallback&&(window.DrawOneDriveClientCallback=a)});a()}if("1"!=urlParams.embed||"1"==urlParams.gapi){var c=mxUtils.bind(this,function(){if("undefined"!==
 typeof gapi){var a=mxUtils.bind(this,function(){this.drive=new DriveClient(this);"420247213240"==this.drive.appId&&this.editor.addListener("fileLoaded",mxUtils.bind(this,function(){var a=this.getCurrentFile();null!=a&&a.constructor==DriveFile&&(a=document.getElementById("geFooterItem2"),null!=a&&(a.innerHTML='<a href="https://support.draw.io/display/DO/2014/11/27/Switching+application+in+Google+Drive" target="_blank" title="IMPORTANT NOTICE" >IMPORTANT NOTICE</a>'))}));this.drive.addListener("userChanged",
@@ -8423,10 +8431,7 @@ window.DrawGapiClientCallback=null):a()}else null==window.DrawGapiClientCallback
 (this.menubar.container.style.paddingTop="0px");this.updateHeader();var d=document.getElementById("geFooterItem2");if(null!=d){this.adsHtml=['<a title="Quick start video" href="https://www.youtube.com/watch?v=8OaMWa4R1SE&t=1" target="_blank"><img border="0" align="absmiddle" style="margin-top:-4px;" src="images/glyphicons_star.png"/>&nbsp;&nbsp;Quick start video</a>'];this.adsHtml.push(d.innerHTML);mxUtils.setPrefixedStyle(d.style,"transition","all 1s ease");var b=this.adsHtml.length-1;this.updateAd=
 function(a){a==b&&(a=this.adsHtml.length-1);a!=b&&(mxUtils.setPrefixedStyle(d.style,"transform","scale(0)"),d.style.opacity="0",b=a,window.setTimeout(mxUtils.bind(this,function(){d.innerHTML=this.adsHtml[a];mxUtils.setPrefixedStyle(d.style,"transform","scale(1)");d.style.opacity="1"}),1E3))};window.setInterval(mxUtils.bind(this,function(){3==this.adsHtml.length?this.updateAd(mxUtils.mod(b+1,3)):this.updateAd(Math.round(Math.random()*(this.adsHtml.length-1)))}),3E5)}null!=this.menubar&&(this.buttonContainer=
 document.createElement("div"),this.buttonContainer.style.display="inline-block",this.buttonContainer.style.paddingRight="48px",this.buttonContainer.style.position="absolute",this.buttonContainer.style.right="0px",this.menubar.container.appendChild(this.buttonContainer));"atlas"==uiTheme&&null!=this.menubar&&(null!=this.toggleElement&&(this.toggleElement.click(),this.toggleElement.style.display="none"),this.icon=document.createElement("img"),this.icon.setAttribute("src",IMAGE_PATH+"/logo-flat-small.png"),
-this.icon.setAttribute("title",mxResources.get("draw.io")),this.icon.style.paddingTop="11px",this.icon.style.marginLeft="4px",this.icon.style.marginRight="6px",mxClient.IS_QUIRKS&&(this.icon.style.marginTop="12px"),this.menubar.container.insertBefore(this.icon,this.menubar.container.firstChild));if(isLocalStorage||mxClient.IS_CHROMEAPP)this.editor.graph.currentEdgeStyle=mxSettings.getCurrentEdgeStyle(),this.editor.graph.currentVertexStyle=mxSettings.getCurrentVertexStyle(),this.fireEvent(new mxEventObject("styleChanged",
-"keys",[],"values",[],"cells",[])),this.addListener("styleChanged",mxUtils.bind(this,function(a,b){mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);mxSettings.save()})),this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget()),this.fireEvent(new mxEventObject("copyConnectChanged")),this.addListener("copyConnectChanged",mxUtils.bind(this,function(a,b){mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());
-mxSettings.save()})),this.editor.graph.pageFormat=mxSettings.getPageFormat(),this.addListener("pageFormatChanged",mxUtils.bind(this,function(a,b){mxSettings.setPageFormat(this.editor.graph.pageFormat);mxSettings.save()})),this.editor.graph.view.gridColor=mxSettings.getGridColor(),this.addListener("gridColorChanged",mxUtils.bind(this,function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor);mxSettings.save()})),mxClient.IS_CHROMEAPP&&(this.editor.addListener("autosaveChanged",mxUtils.bind(this,
-function(a,b){mxSettings.setAutosave(this.editor.autosave);mxSettings.save()})),this.editor.autosave=mxSettings.getAutosave()),null!=this.sidebar&&this.sidebar.showPalette("search",mxSettings.settings.search),!this.editor.chromeless&&null!=this.sidebar&&(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))&&(this.toggleScratchpad(),mxSettings.save()),this.addListener("formatWidthChanged",function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})};
+this.icon.setAttribute("title",mxResources.get("draw.io")),this.icon.style.paddingTop="11px",this.icon.style.marginLeft="4px",this.icon.style.marginRight="6px",mxClient.IS_QUIRKS&&(this.icon.style.marginTop="12px"),this.menubar.container.insertBefore(this.icon,this.menubar.container.firstChild))};
 App.prototype.isDriveDomain=function(){return"0"!=urlParams.drive&&("test.draw.io"==window.location.hostname||"cdn.draw.io"==window.location.hostname||"www.draw.io"==window.location.hostname||"drive.draw.io"==window.location.hostname||"jgraph.github.io"==window.location.hostname)};App.prototype.isLegacyDriveDomain=function(){return 0==urlParams.drive||"legacy.draw.io"==window.location.hostname};
 App.prototype.checkLicense=function(){var a=this.drive.getUser(),c=("1"==urlParams.dev?urlParams.lic:null)||(null!=a?a.email:null);if(!this.isOffline()&&!this.editor.chromeless&&null!=c){var f=c.lastIndexOf("@"),d=c;0<=f&&(d=c.substring(f+1));mxUtils.post("/license","domain="+encodeURIComponent(d)+"&email="+encodeURIComponent(c)+"&ds="+encodeURIComponent(a.displayName)+"&lc="+encodeURIComponent(a.locale)+"&ts="+(new Date).getTime(),mxUtils.bind(this,function(a){try{if(200<=a.getStatus()&&299>=a.getStatus()){var b=
 a.getText();if(0<b.length){var c=JSON.parse(b);null!=c&&this.handleLicense(c,d)}}}catch(k){}}))}};
diff --git a/war/js/atlas-viewer.min.js b/war/js/atlas-viewer.min.js
index 3ac6e07ec06dc32458625ead7ad292aa5c1e916c..7e225ecc7cc7530d328e1e20c7f0cd36e246a1c6 100644
--- a/war/js/atlas-viewer.min.js
+++ b/war/js/atlas-viewer.min.js
@@ -44,8 +44,8 @@ function(){return null!==this.k};f.prototype.V=function(){return this.h&&decodeU
 this.l};f.prototype.ba=function(a){if("object"===typeof a&&!(a instanceof Array)&&(a instanceof Object||"[object Array]"!==Object.prototype.toString.call(a))){var b=[],c=-1,d;for(d in a){var e=a[d];"string"===typeof e&&(b[++c]=d,b[++c]=e)}a=b}for(var b=[],c="",f=0;f<a.length;)d=a[f++],e=a[f++],b.push(c,encodeURIComponent(d.toString())),c="&",e&&b.push("=",encodeURIComponent(e.toString()));this.l=b.join("")};f.prototype.fa=function(a){this.o=a?a:null};f.prototype.Z=function(){return null!==this.o};
 var m=/^(?:([^:/?#]+):)?(?:\/\/(?:([^/?#]*)@)?([^/?#:@]*)(?::([0-9]+))?)?([^?#]+)?(?:\?([^#]*))?(?:#(.*))?$/,n=/[#\/\?@]/g,p=/[\#\?]/g;f.parse=a;f.create=function(a,d,e,k,g,l,m){a=new f(b(a,n),b(d,n),"string"==typeof e?encodeURIComponent(e):null,0<k?k.toString():null,b(g,p),null,"string"==typeof m?encodeURIComponent(m):null);l&&("string"===typeof l?a.O(l.replace(/[^?&=0-9A-Za-z_\-~.%]/g,c)):a.ba(l));return a};f.N=e;f.ma=d;f.ha={ua:function(b){return/\.html$/.test(a(b).U())?"text/html":"application/javascript"},
 N:function(b,c){return b?e(a(b),a(c)).toString():""+c}};return f}();"undefined"!==typeof window&&(window.URI=f);var g=void 0,k=void 0,l=void 0,m=void 0;(function(){function a(a){return"string"===typeof a?'url("'+a.replace(y,c)+'")':'url("about:blank")'}function c(a){return A[a]}function d(a,b){return a?f.ha.N(a,b):b}function p(a,b,c){if(!c)return null;var d=(""+a).match(v);return!d||d[1]&&!B.test(d[1])?null:c(a,b)}function z(a){return a.replace(/^-(?:apple|css|epub|khtml|moz|mso?|o|rim|wap|webkit|xv)-(?=[a-z])/,
-"")}var y=/[\n\f\r\"\'()*<>]/g,A={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},v=/^(?:([^:/?# ]+):)?/,B=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function E(f,k,g,l,m){f=z(f);var n=b[f];if(n&&"object"===typeof n){for(var q=n.cssPropBits,t=q&80,r=q&1536,u=NaN,x=0,C=0;x<k.length;++x){var v=k[x].toLowerCase(),y=v.charCodeAt(0),B,A,I,F,G,N;if(32===y)v="";else if(34===y)v=16===t?g?a(p(d(l,e(k[x].substring(1,v.length-1))),f,g)):"":
-q&8&&!(t&t-1)?v:"";else if("inherit"!==v){if(G=n.cssLitGroup){var L;if(!(L=n.cssLitMap)){L={};for(var P=G.length;0<=--P;)for(var W=G[P],ga=W.length;0<=--ga;)L[W[ga]]=c;L=n.cssLitMap=L}G=L}else G=c;if(N=G,N[z(v)]!==c)if(35===y&&/^#(?:[0-9a-f]{3}){1,2}$/.test(v))v=q&2?v:"";else if(48<=y&&57>=y)v=q&1?v:"";else if(B=v.charCodeAt(1),A=v.charCodeAt(2),I=48<=B&&57>=B,F=48<=A&&57>=A,43===y&&(I||46===B&&F))v=q&1?(I?"":"0")+v.substring(1):"";else if(45===y&&(I||46===B&&F))v=q&4?(I?"-":"-0")+v.substring(1):
+"")}var y=/[\n\f\r\"\'()*<>]/g,A={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},v=/^(?:([^:/?# ]+):)?/,B=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function E(f,k,g,l,m){f=z(f);var n=b[f];if(n&&"object"===typeof n){for(var q=n.cssPropBits,t=q&80,r=q&1536,u=NaN,x=0,C=0;x<k.length;++x){var v=k[x].toLowerCase(),y=v.charCodeAt(0),B,A,I,F,G,M;if(32===y)v="";else if(34===y)v=16===t?g?a(p(d(l,e(k[x].substring(1,v.length-1))),f,g)):"":
+q&8&&!(t&t-1)?v:"";else if("inherit"!==v){if(G=n.cssLitGroup){var L;if(!(L=n.cssLitMap)){L={};for(var P=G.length;0<=--P;)for(var W=G[P],ga=W.length;0<=--ga;)L[W[ga]]=c;L=n.cssLitMap=L}G=L}else G=c;if(M=G,M[z(v)]!==c)if(35===y&&/^#(?:[0-9a-f]{3}){1,2}$/.test(v))v=q&2?v:"";else if(48<=y&&57>=y)v=q&1?v:"";else if(B=v.charCodeAt(1),A=v.charCodeAt(2),I=48<=B&&57>=B,F=48<=A&&57>=A,43===y&&(I||46===B&&F))v=q&1?(I?"":"0")+v.substring(1):"";else if(45===y&&(I||46===B&&F))v=q&4?(I?"-":"-0")+v.substring(1):
 q&1?"0":"";else if(46===y&&I)v=q&1?"0"+v:"";else if('url("'===v.substring(0,5))v=g&&q&16?a(p(d(l,k[x].substring(5,v.length-2)),f,g)):"";else if("("===v.charAt(v.length-1))a:{G=k;L=x;v=1;P=L+1;for(y=G.length;P<y&&v;)W=G[P++],v+=")"===W?-1:/^[^"']*\($/.test(W);if(!v)for(v=G[L].toLowerCase(),y=z(v),G=G.splice(L,P-L,""),L=n.cssFns,P=0,W=L.length;P<W;++P)if(L[P].substring(0,y.length)==y){G[0]=G[G.length-1]="";E(L[P],G,g,l);v=v+G.join(" ")+")";break a}v=""}else v=r&&/^-?[a-z_][\w\-]*$/.test(v)&&!/__$/.test(v)?
 m&&512===r?k[x]+m:1024===r&&b[v]&&"number"===typeof b[v].oa?v:"":/^\w+$/.test(v)&&64===t&&q&8?u+1===C?(k[u]=k[u].substring(0,k[u].length-1)+" "+v+'"',""):(u=C,'"'+v+'"'):""}v&&(k[C++]=v)}1===C&&'url("about:blank")'===k[0]&&(C=0);k.length=C}else k.length=0}}();var G=/^(active|after|before|blank|checked|default|disabled|drop|empty|enabled|first|first-child|first-letter|first-line|first-of-type|fullscreen|focus|hover|in-range|indeterminate|invalid|last-child|last-of-type|left|link|only-child|only-of-type|optional|out-of-range|placeholder-shown|read-only|read-write|required|right|root|scope|user-error|valid|visited)$/,
 F={};F[">"]=F["+"]=F["~"]=F;k=function(a,b,c){function d(d,l){function m(c,d,e){var g,l,m,p,t,r=!0;g="";c<d&&((t=a[c],"*"===t)?(++c,g=t):/^[a-zA-Z]/.test(t)&&(l=k(t.toLowerCase(),[]))&&("tagName"in l&&(t=l.tagName),++c,g=t));for(p=m=l="";r&&c<d;++c)if(t=a[c],"#"===t.charAt(0))/^#_|__$|[^\w#:\-]/.test(t)?r=!1:l+=t+f;else if("."===t)++c<d&&/^[0-9A-Za-z:_\-]+$/.test(t=a[c])&&!/^_|__$/.test(t)?l+="."+t:r=!1;else if(c+1<d&&"["===a[c]){++c;var E=a[c++].toLowerCase();t=q.m[g+"::"+E];t!==+t&&(t=q.m["*::"+
@@ -80,7 +80,7 @@ li:"HTMLLIElement",link:"HTMLLinkElement",map:"HTMLMapElement",mark:"HTMLElement
 s:"HTMLElement",samp:"HTMLElement",script:"HTMLScriptElement",section:"HTMLElement",select:"HTMLSelectElement",small:"HTMLElement",source:"HTMLSourceElement",span:"HTMLSpanElement",strike:"HTMLElement",strong:"HTMLElement",style:"HTMLStyleElement",sub:"HTMLElement",summary:"HTMLElement",sup:"HTMLElement",table:"HTMLTableElement",tbody:"HTMLTableSectionElement",td:"HTMLTableDataCellElement",textarea:"HTMLTextAreaElement",tfoot:"HTMLTableSectionElement",th:"HTMLTableHeaderCellElement",thead:"HTMLTableSectionElement",
 time:"HTMLTimeElement",title:"HTMLTitleElement",tr:"HTMLTableRowElement",track:"HTMLTrackElement",tt:"HTMLElement",u:"HTMLElement",ul:"HTMLUListElement","var":"HTMLElement",video:"HTMLVideoElement",wbr:"HTMLElement"};q.ELEMENT_DOM_INTERFACES=q.Q;q.P={NOT_LOADED:0,SAME_DOCUMENT:1,NEW_DOCUMENT:2};q.ueffects=q.P;q.J={"a::href":2,"area::href":2,"audio::src":1,"blockquote::cite":0,"command::icon":1,"del::cite":0,"form::action":2,"img::src":1,"input::src":1,"ins::cite":0,"q::cite":0,"video::poster":1,"video::src":1};
 q.URIEFFECTS=q.J;q.M={UNSANDBOXED:2,SANDBOXED:1,DATA:0};q.ltypes=q.M;q.I={"a::href":2,"area::href":2,"audio::src":2,"blockquote::cite":2,"command::icon":1,"del::cite":2,"form::action":2,"img::src":1,"input::src":1,"ins::cite":2,"q::cite":2,"video::poster":1,"video::src":2};q.LOADERTYPES=q.I;"undefined"!==typeof window&&(window.html4=q);a=function(a){function b(a,b){var c;if(ba.hasOwnProperty(b))c=ba[b];else{var d=b.match(T);c=d?String.fromCharCode(parseInt(d[1],10)):(d=b.match(D))?String.fromCharCode(parseInt(d[1],
-16)):Q&&X.test(b)?(Q.innerHTML="&"+b+";",d=Q.textContent,ba[b]=d):"&"+b+";"}return c}function c(a){return a.replace(Y,b)}function d(a){return(""+a).replace(K,"&amp;").replace(U,"&lt;").replace(ca,"&gt;").replace(Z,"&#34;")}function e(a){return a.replace(M,"&amp;$1").replace(U,"&lt;").replace(ca,"&gt;")}function k(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
+16)):Q&&X.test(b)?(Q.innerHTML="&"+b+";",d=Q.textContent,ba[b]=d):"&"+b+";"}return c}function c(a){return a.replace(Y,b)}function d(a){return(""+a).replace(K,"&amp;").replace(U,"&lt;").replace(ca,"&gt;").replace(Z,"&#34;")}function e(a){return a.replace(N,"&amp;$1").replace(U,"&lt;").replace(ca,"&gt;")}function k(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
 d=a+"";if(aa)d=d.split(e);else{for(var f=[],k=0,g;null!==(g=e.exec(d));)f.push(d.substring(k,g.index)),f.push(g[0]),k=g.index+g[0].length;f.push(d.substring(k));d=f}l(b,d,0,{r:!1,C:!1},c)}}function g(a,b,c,d,e){return function(){l(a,b,c,d,e)}}function l(b,c,d,e,f){try{b.H&&0==d&&b.H(f);for(var k,l,p,q=c.length;d<q;){var t=c[d++],r=c[d];switch(t){case "&":O.test(r)?(b.e&&b.e("&"+r,f,S,g(b,c,d,e,f)),d++):b.e&&b.e("&amp;",f,S,g(b,c,d,e,f));break;case "</":if(k=/^([-\w:]+)[^\'\"]*/.exec(r))if(k[0].length===
 r.length&&">"===c[d+1])d+=2,p=k[1].toLowerCase(),b.t&&b.t(p,f,S,g(b,c,d,e,f));else{var u=c,E=d,x=b,D=f,C=S,v=e,z=n(u,E);z?(x.t&&x.t(z.name,D,C,g(x,u,E,v,D)),d=z.next):d=u.length}else b.e&&b.e("&lt;/",f,S,g(b,c,d,e,f));break;case "<":if(k=/^([-\w:]+)\s*\/?/.exec(r))if(k[0].length===r.length&&">"===c[d+1]){d+=2;p=k[1].toLowerCase();b.w&&b.w(p,[],f,S,g(b,c,d,e,f));var W=a.f[p];W&da&&(d=m(c,{name:p,next:d,c:W},b,f,S,e))}else{var u=c,E=b,x=f,D=S,C=e,ha=n(u,d);ha?(E.w&&E.w(ha.name,ha.R,x,D,g(E,u,ha.next,
 C,x)),d=ha.c&da?m(u,ha,E,x,D,C):ha.next):d=u.length}else b.e&&b.e("&lt;",f,S,g(b,c,d,e,f));break;case "\x3c!--":if(!e.C){for(l=d+1;l<q&&(">"!==c[l]||!/--$/.test(c[l-1]));l++);if(l<q){if(b.A){var y=c.slice(d,l).join("");b.A(y.substr(0,y.length-2),f,S,g(b,c,l+1,e,f))}d=l+1}else e.C=!0}e.C&&b.e&&b.e("&lt;!--",f,S,g(b,c,d,e,f));break;case "<!":if(/^\w/.test(r)){if(!e.r){for(l=d+1;l<q&&">"!==c[l];l++);l<q?d=l+1:e.r=!0}e.r&&b.e&&b.e("&lt;!",f,S,g(b,c,d,e,f))}else b.e&&b.e("&lt;!",f,S,g(b,c,d,e,f));break;
@@ -91,9 +91,9 @@ if("attribs"in m)k=m.attribs;else throw Error("tagPolicy gave no attribs");var n
 a.f[b];if(!(d&(a.c.EMPTY|a.c.FOLDABLE))){if(d&a.c.OPTIONAL_ENDTAG)for(d=e.length;0<=--d;){var k=e[d].D;if(k===b)break;if(!(a.f[k]&a.c.OPTIONAL_ENDTAG))return}else for(d=e.length;0<=--d&&e[d].D!==b;);if(!(0>d)){for(k=e.length;--k>d;){var g=e[k].v;a.f[g]&a.c.OPTIONAL_ENDTAG||c.push("</",g,">")}d<e.length&&(b=e[d].v);e.length=d;c.push("</",b,">")}}}},pcdata:c,rcdata:c,cdata:c,endDoc:function(a){for(;e.length;e.length--)a.push("</",e[e.length-1].v,">")}})}function q(a,b,c,d,e){if(!e)return null;try{var k=
 f.parse(""+a);if(k&&(!k.K()||ga.test(k.W()))){var g=e(k,b,c,d);return g?g.toString():null}}catch(ja){}return null}function t(a,b,c,d,e){c||a(b+" removed",{S:"removed",tagName:b});if(d!==e){var f="changed";d&&!e?f="removed":!d&&e&&(f="added");a(b+"."+c+" "+f,{S:f,tagName:b,la:c,oldValue:d,newValue:e})}}function E(a,b,c){b=b+"::"+c;if(a.hasOwnProperty(b))return a[b];b="*::"+c;if(a.hasOwnProperty(b))return a[b]}function I(b,c,d,e,f){for(var k=0;k<c.length;k+=2){var g=c[k],l=c[k+1],m=l,n=null,p;if((p=
 b+"::"+g,a.m.hasOwnProperty(p))||(p="*::"+g,a.m.hasOwnProperty(p)))n=a.m[p];if(null!==n)switch(n){case a.d.NONE:break;case a.d.SCRIPT:l=null;f&&t(f,b,g,m,l);break;case a.d.STYLE:if("undefined"===typeof V){l=null;f&&t(f,b,g,m,l);break}var r=[];V(l,{declaration:function(b,c){var e=b.toLowerCase();P(e,c,d?function(b){return q(b,a.P.ja,a.M.ka,{TYPE:"CSS",CSS_PROP:e},d)}:null);c.length&&r.push(e+": "+c.join(" "))}});l=0<r.length?r.join(" ; "):null;f&&t(f,b,g,m,l);break;case a.d.ID:case a.d.IDREF:case a.d.IDREFS:case a.d.GLOBAL_NAME:case a.d.LOCAL_NAME:case a.d.CLASSES:l=
-e?e(l):l;f&&t(f,b,g,m,l);break;case a.d.URI:l=q(l,E(a.J,b,g),E(a.I,b,g),{TYPE:"MARKUP",XML_ATTR:g,XML_TAG:b},d);f&&t(f,b,g,m,l);break;case a.d.URI_FRAGMENT:l&&"#"===l.charAt(0)?(l=l.substring(1),l=e?e(l):l,null!==l&&void 0!==l&&(l="#"+l)):l=null;f&&t(f,b,g,m,l);break;default:l=null,f&&t(f,b,g,m,l)}else l=null,f&&t(f,b,g,m,l);c[k+1]=l}return c}function N(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&t(d,e,void 0,void 0,void 0);else return{attribs:I(e,f,b,c,d)}}}function L(a,b){var c=[];p(b)(a,
-c);return c.join("")}var V,P;"undefined"!==typeof window&&(V=window.parseCssDeclarations,P=window.sanitizeCssProperty);var ba={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},T=/^#(\d+)$/,D=/^#x([0-9A-Fa-f]+)$/,X=/^[A-Za-z][A-za-z0-9]+$/,Q="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,J=/\0/g,Y=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,O=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,K=/&/g,M=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,U=
-/[<]/g,ca=/>/g,Z=/\"/g,R=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,aa=3==="a,b".split(/(,)/).length,da=a.c.CDATA|a.c.RCDATA,S={},W={},ga=/^(?:https?|mailto|data)$/i,ea={};ea.pa=ea.escapeAttrib=d;ea.ra=ea.makeHtmlSanitizer=p;ea.sa=ea.makeSaxParser=k;ea.ta=ea.makeTagPolicy=N;ea.wa=ea.normalizeRCData=e;ea.xa=ea.sanitize=function(a,b,c,d){return L(a,N(b,c,d))};ea.ya=ea.sanitizeAttribs=I;ea.za=ea.sanitizeWithPolicy=L;ea.Ba=ea.unescapeEntities=c;return ea}(q);
+e?e(l):l;f&&t(f,b,g,m,l);break;case a.d.URI:l=q(l,E(a.J,b,g),E(a.I,b,g),{TYPE:"MARKUP",XML_ATTR:g,XML_TAG:b},d);f&&t(f,b,g,m,l);break;case a.d.URI_FRAGMENT:l&&"#"===l.charAt(0)?(l=l.substring(1),l=e?e(l):l,null!==l&&void 0!==l&&(l="#"+l)):l=null;f&&t(f,b,g,m,l);break;default:l=null,f&&t(f,b,g,m,l)}else l=null,f&&t(f,b,g,m,l);c[k+1]=l}return c}function M(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&t(d,e,void 0,void 0,void 0);else return{attribs:I(e,f,b,c,d)}}}function L(a,b){var c=[];p(b)(a,
+c);return c.join("")}var V,P;"undefined"!==typeof window&&(V=window.parseCssDeclarations,P=window.sanitizeCssProperty);var ba={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},T=/^#(\d+)$/,D=/^#x([0-9A-Fa-f]+)$/,X=/^[A-Za-z][A-za-z0-9]+$/,Q="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,J=/\0/g,Y=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,O=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,K=/&/g,N=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,U=
+/[<]/g,ca=/>/g,Z=/\"/g,R=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,aa=3==="a,b".split(/(,)/).length,da=a.c.CDATA|a.c.RCDATA,S={},W={},ga=/^(?:https?|mailto|data)$/i,ea={};ea.pa=ea.escapeAttrib=d;ea.ra=ea.makeHtmlSanitizer=p;ea.sa=ea.makeSaxParser=k;ea.ta=ea.makeTagPolicy=M;ea.wa=ea.normalizeRCData=e;ea.xa=ea.sanitize=function(a,b,c,d){return L(a,M(b,c,d))};ea.ya=ea.sanitizeAttribs=I;ea.za=ea.sanitizeWithPolicy=L;ea.Ba=ea.unescapeEntities=c;return ea}(q);
 c=a.sanitize;"undefined"!==typeof window&&(window.html=a,window.html_sanitize=c)})();var Base64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(a,b){var c="",d,e,f,g,k,l,m=0;for(null!=b&&b||(a=Base64._utf8_encode(a));m<a.length;)d=a.charCodeAt(m++),e=a.charCodeAt(m++),f=a.charCodeAt(m++),g=d>>2,d=(d&3)<<4|e>>4,k=(e&15)<<2|f>>6,l=f&63,isNaN(e)?k=l=64:isNaN(f)&&(l=64),c=c+this._keyStr.charAt(g)+this._keyStr.charAt(d)+this._keyStr.charAt(k)+this._keyStr.charAt(l);return c},decode:function(a,b){b=null!=b?b:!1;var c="",d,e,f,g,k,l=0;for(a=a.replace(/[^A-Za-z0-9\+\/\=]/g,
 "");l<a.length;)d=this._keyStr.indexOf(a.charAt(l++)),e=this._keyStr.indexOf(a.charAt(l++)),g=this._keyStr.indexOf(a.charAt(l++)),k=this._keyStr.indexOf(a.charAt(l++)),d=d<<2|e>>4,e=(e&15)<<4|g>>2,f=(g&3)<<6|k,c+=String.fromCharCode(d),64!=g&&(c+=String.fromCharCode(e)),64!=k&&(c+=String.fromCharCode(f));b||(c=Base64._utf8_decode(c));return c},_utf8_encode:function(a){a=a.replace(/\r\n/g,"\n");for(var b="",c=0;c<a.length;c++){var d=a.charCodeAt(c);128>d?b+=String.fromCharCode(d):(127<d&&2048>d?b+=
 String.fromCharCode(d>>6|192):(b+=String.fromCharCode(d>>12|224),b+=String.fromCharCode(d>>6&63|128)),b+=String.fromCharCode(d&63|128))}return b},_utf8_decode:function(a){var b="",c=0,d;for(c1=c2=0;c<a.length;)d=a.charCodeAt(c),128>d?(b+=String.fromCharCode(d),c++):191<d&&224>d?(c2=a.charCodeAt(c+1),b+=String.fromCharCode((d&31)<<6|c2&63),c+=2):(c2=a.charCodeAt(c+1),c3=a.charCodeAt(c+2),b+=String.fromCharCode((d&15)<<12|(c2&63)<<6|c3&63),c+=3);return b}};!function(a){"object"==typeof exports&&"undefined"!=typeof module?module.exports=a():"function"==typeof define&&define.amd?define([],a):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).pako=a()}(function(){return function b(c,d,e){function f(k,m){if(!d[k]){if(!c[k]){var l="function"==typeof require&&require;if(!m&&l)return l(k,!0);if(g)return g(k,!0);l=Error("Cannot find module '"+k+"'");throw l.code="MODULE_NOT_FOUND",l;}l=d[k]={exports:{}};
@@ -115,8 +115,8 @@ d?(c[g++]=192|d>>>6,c[g++]=128|63&d):65536>d?(c[g++]=224|d>>>12,c[g++]=128|d>>>6
 2===g?31:3===g?15:7;1<g&&d<m;)k=k<<6|63&b[d++],g--;1<g?n[f++]=65533:65536>k?n[f++]=k:(k-=65536,n[f++]=55296|k>>10&1023,n[f++]=56320|1023&k)}return e(n,f)};d.utf8border=function(b,c){var d;c=c||b.length;c>b.length&&(c=b.length);for(d=c-1;0<=d&&128===(192&b[d]);)d--;return 0>d?c:0===d?c:d+l[b[d]]>c?d:c}},{"./common":3}],5:[function(b,c,d){c.exports=function(b,c,d,k){var e=65535&b|0;b=b>>>16&65535|0;for(var f;0!==d;){f=2E3<d?2E3:d;d-=f;do e=e+c[k++]|0,b=b+e|0;while(--f);e%=65521;b%=65521}return e|b<<
 16|0}},{}],6:[function(b,c,d){c.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],7:[function(b,c,d){var e=function(){for(var b,c=[],d=0;256>d;d++){b=d;for(var e=
 0;8>e;e++)b=1&b?3988292384^b>>>1:b>>>1;c[d]=b}return c}();c.exports=function(b,c,d,l){d=l+d;for(b^=-1;l<d;l++)b=b>>>8^e[255&(b^c[l])];return b^-1}},{}],8:[function(b,c,d){function e(b,c){return b.msg=C[c],c}function f(b){for(var c=b.length;0<=--c;)b[c]=0}function g(b){var c=b.state,d=c.pending;d>b.avail_out&&(d=b.avail_out);0!==d&&(v.arraySet(b.output,c.pending_buf,c.pending_out,d,b.next_out),b.next_out+=d,c.pending_out+=d,b.total_out+=d,b.avail_out-=d,c.pending-=d,0===c.pending&&(c.pending_out=0))}
-function k(b,c){B._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function l(b,c){b.pending_buf[b.pending++]=c}function m(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function n(b,c){var d,e,f=b.max_chain_length,k=b.strstart,g=b.prev_length,l=b.nice_match,m=b.strstart>b.w_size-U?b.strstart-(b.w_size-U):0,n=b.window,p=b.w_mask,q=b.prev,t=b.strstart+M,r=n[k+g-1],E=n[k+g];b.prev_length>=b.good_match&&(f>>=
-2);l>b.lookahead&&(l=b.lookahead);do if(d=c,n[d+g]===E&&n[d+g-1]===r&&n[d]===n[k]&&n[++d]===n[k+1]){k+=2;for(d++;n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&k<t;);if(e=M-(t-k),k=t-M,e>g){if(b.match_start=c,g=e,e>=l)break;r=n[k+g-1];E=n[k+g]}}while((c=q[c&p])>m&&0!==--f);return g<=b.lookahead?g:b.lookahead}function p(b){var c,d,e,f,k=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=k+(k-U)){v.arraySet(b.window,
+function k(b,c){B._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function l(b,c){b.pending_buf[b.pending++]=c}function m(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function n(b,c){var d,e,f=b.max_chain_length,k=b.strstart,g=b.prev_length,l=b.nice_match,m=b.strstart>b.w_size-U?b.strstart-(b.w_size-U):0,n=b.window,p=b.w_mask,q=b.prev,r=b.strstart+N,t=n[k+g-1],E=n[k+g];b.prev_length>=b.good_match&&(f>>=
+2);l>b.lookahead&&(l=b.lookahead);do if(d=c,n[d+g]===E&&n[d+g-1]===t&&n[d]===n[k]&&n[++d]===n[k+1]){k+=2;for(d++;n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&k<r;);if(e=N-(r-k),k=r-N,e>g){if(b.match_start=c,g=e,e>=l)break;t=n[k+g-1];E=n[k+g]}}while((c=q[c&p])>m&&0!==--f);return g<=b.lookahead?g:b.lookahead}function p(b){var c,d,e,f,k=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=k+(k-U)){v.arraySet(b.window,
 b.window,k,k,0);b.match_start-=k;b.strstart-=k;b.block_start-=k;c=d=b.hash_size;do e=b.head[--c],b.head[c]=e>=k?e-k:0;while(--d);c=d=k;do e=b.prev[--c],b.prev[c]=e>=k?e-k:0;while(--d);f+=k}if(0===b.strm.avail_in)break;c=b.strm;e=b.window;var g=b.strstart+b.lookahead,l=c.avail_in;if(d=(l>f&&(l=f),0===l?0:(c.avail_in-=l,v.arraySet(e,c.input,c.next_in,l,g),1===c.state.wrap?c.adler=G(c.adler,e,l,g):2===c.state.wrap&&(c.adler=F(c.adler,e,l,g)),c.next_in+=l,c.total_in+=l,l)),b.lookahead+=d,b.lookahead+
 b.insert>=K)for(f=b.strstart-b.insert,b.ins_h=b.window[f],b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+1])&b.hash_mask;b.insert&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+K-1])&b.hash_mask,b.prev[f&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=f,f++,b.insert--,!(b.lookahead+b.insert<K)););}while(b.lookahead<U&&0!==b.strm.avail_in)}function q(b,c){for(var d,e;;){if(b.lookahead<U){if(p(b),b.lookahead<U&&c===H)return R;if(0===b.lookahead)break}if(d=0,b.lookahead>=K&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+
 K-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),0!==d&&b.strstart-d<=b.w_size-U&&(b.match_length=n(b,d)),b.match_length>=K)if(e=B._tr_tally(b,b.strstart-b.match_start,b.match_length-K),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=K){b.match_length--;do b.strstart++,b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+K-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(0!==--b.match_length);
@@ -126,65 +126,65 @@ b.strstart+b.lookahead-K;e=B._tr_tally(b,b.strstart-1-b.prev_match,b.prev_length
 b.strstart++,b.lookahead--,0===b.strm.avail_out)return R}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(B._tr_tally(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<K-1?b.strstart:K-1,c===E?(k(b,!0),0===b.strm.avail_out?da:S):b.last_lit&&(k(b,!1),0===b.strm.avail_out)?R:aa}function r(b,c,d,e,f){this.good_length=b;this.max_lazy=c;this.nice_length=d;this.max_chain=e;this.func=f}function u(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=
 this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=T;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=
 this.ins_h=0;this.dyn_ltree=new v.Buf16(2*Y);this.dyn_dtree=new v.Buf16(2*(2*Q+1));this.bl_tree=new v.Buf16(2*(2*J+1));f(this.dyn_ltree);f(this.dyn_dtree);f(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new v.Buf16(O+1);this.heap=new v.Buf16(2*X+1);f(this.heap);this.heap_max=this.heap_len=0;this.depth=new v.Buf16(2*X+1);f(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function x(b){var c;
-return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ba,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ca:Z,b.adler=2===c.wrap?0:1,c.last_flush=H,B._tr_init(c),I):e(b,N)}function z(b){var c=x(b);c===I&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=A[b.level].max_lazy,b.good_match=A[b.level].good_length,b.nice_match=A[b.level].nice_length,b.max_chain_length=A[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
-b.prev_length=K-1,b.match_available=0,b.ins_h=0);return c}function y(b,c,d,f,k,g){if(!b)return N;var l=1;if(c===L&&(c=6),0>f?(l=0,f=-f):15<f&&(l=2,f-=16),1>k||k>D||d!==T||8>f||15<f||0>c||9<c||0>g||g>P)return e(b,N);8===f&&(f=9);var m=new u;return b.state=m,m.strm=b,m.wrap=l,m.gzhead=null,m.w_bits=f,m.w_size=1<<m.w_bits,m.w_mask=m.w_size-1,m.hash_bits=k+7,m.hash_size=1<<m.hash_bits,m.hash_mask=m.hash_size-1,m.hash_shift=~~((m.hash_bits+K-1)/K),m.window=new v.Buf8(2*m.w_size),m.head=new v.Buf16(m.hash_size),
-m.prev=new v.Buf16(m.w_size),m.lit_bufsize=1<<k+6,m.pending_buf_size=4*m.lit_bufsize,m.pending_buf=new v.Buf8(m.pending_buf_size),m.d_buf=1*m.lit_bufsize,m.l_buf=3*m.lit_bufsize,m.level=c,m.strategy=g,m.method=d,z(b)}var A,v=b("../utils/common"),B=b("./trees"),G=b("./adler32"),F=b("./crc32"),C=b("./messages"),H=0,E=4,I=0,N=-2,L=-1,V=1,P=4,ba=2,T=8,D=9,X=286,Q=30,J=19,Y=2*X+1,O=15,K=3,M=258,U=M+K+1,ca=42,Z=113,R=1,aa=2,da=3,S=4;A=[new r(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
+return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ba,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ca:Z,b.adler=2===c.wrap?0:1,c.last_flush=H,B._tr_init(c),I):e(b,M)}function z(b){var c=x(b);c===I&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=A[b.level].max_lazy,b.good_match=A[b.level].good_length,b.nice_match=A[b.level].nice_length,b.max_chain_length=A[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
+b.prev_length=K-1,b.match_available=0,b.ins_h=0);return c}function y(b,c,d,f,k,g){if(!b)return M;var l=1;if(c===L&&(c=6),0>f?(l=0,f=-f):15<f&&(l=2,f-=16),1>k||k>D||d!==T||8>f||15<f||0>c||9<c||0>g||g>P)return e(b,M);8===f&&(f=9);var m=new u;return b.state=m,m.strm=b,m.wrap=l,m.gzhead=null,m.w_bits=f,m.w_size=1<<m.w_bits,m.w_mask=m.w_size-1,m.hash_bits=k+7,m.hash_size=1<<m.hash_bits,m.hash_mask=m.hash_size-1,m.hash_shift=~~((m.hash_bits+K-1)/K),m.window=new v.Buf8(2*m.w_size),m.head=new v.Buf16(m.hash_size),
+m.prev=new v.Buf16(m.w_size),m.lit_bufsize=1<<k+6,m.pending_buf_size=4*m.lit_bufsize,m.pending_buf=new v.Buf8(m.pending_buf_size),m.d_buf=1*m.lit_bufsize,m.l_buf=3*m.lit_bufsize,m.level=c,m.strategy=g,m.method=d,z(b)}var A,v=b("../utils/common"),B=b("./trees"),G=b("./adler32"),F=b("./crc32"),C=b("./messages"),H=0,E=4,I=0,M=-2,L=-1,V=1,P=4,ba=2,T=8,D=9,X=286,Q=30,J=19,Y=2*X+1,O=15,K=3,N=258,U=N+K+1,ca=42,Z=113,R=1,aa=2,da=3,S=4;A=[new r(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
 (d=b.pending_buf_size-5);;){if(1>=b.lookahead){if(p(b),0===b.lookahead&&c===H)return R;if(0===b.lookahead)break}b.strstart+=b.lookahead;b.lookahead=0;var e=b.block_start+d;if((0===b.strstart||b.strstart>=e)&&(b.lookahead=b.strstart-e,b.strstart=e,k(b,!1),0===b.strm.avail_out)||b.strstart-b.block_start>=b.w_size-U&&(k(b,!1),0===b.strm.avail_out))return R}return b.insert=0,c===E?(k(b,!0),0===b.strm.avail_out?da:S):(b.strstart>b.block_start&&k(b,!1),R)}),new r(4,4,8,4,q),new r(4,5,16,8,q),new r(4,6,
-32,32,q),new r(4,4,16,16,t),new r(8,16,32,32,t),new r(8,16,128,128,t),new r(8,32,128,256,t),new r(32,128,258,1024,t),new r(32,258,258,4096,t)];d.deflateInit=function(b,c){return y(b,c,T,15,8,0)};d.deflateInit2=y;d.deflateReset=z;d.deflateResetKeep=x;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?N:(b.state.gzhead=c,I):N};d.deflate=function(b,c){var d,n,q,t;if(!b||!b.state||5<c||0>c)return b?e(b,N):N;if(n=b.state,!b.output||!b.input&&0!==b.avail_in||666===n.status&&c!==E)return e(b,
-0===b.avail_out?-5:N);if(n.strm=b,d=n.last_flush,n.last_flush=c,n.status===ca)2===n.wrap?(b.adler=0,l(n,31),l(n,139),l(n,8),n.gzhead?(l(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),l(n,255&n.gzhead.time),l(n,n.gzhead.time>>8&255),l(n,n.gzhead.time>>16&255),l(n,n.gzhead.time>>24&255),l(n,9===n.level?2:2<=n.strategy||2>n.level?4:0),l(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(l(n,255&n.gzhead.extra.length),l(n,n.gzhead.extra.length>>
+32,32,q),new r(4,4,16,16,t),new r(8,16,32,32,t),new r(8,16,128,128,t),new r(8,32,128,256,t),new r(32,128,258,1024,t),new r(32,258,258,4096,t)];d.deflateInit=function(b,c){return y(b,c,T,15,8,0)};d.deflateInit2=y;d.deflateReset=z;d.deflateResetKeep=x;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?M:(b.state.gzhead=c,I):M};d.deflate=function(b,c){var d,n,q,r;if(!b||!b.state||5<c||0>c)return b?e(b,M):M;if(n=b.state,!b.output||!b.input&&0!==b.avail_in||666===n.status&&c!==E)return e(b,
+0===b.avail_out?-5:M);if(n.strm=b,d=n.last_flush,n.last_flush=c,n.status===ca)2===n.wrap?(b.adler=0,l(n,31),l(n,139),l(n,8),n.gzhead?(l(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),l(n,255&n.gzhead.time),l(n,n.gzhead.time>>8&255),l(n,n.gzhead.time>>16&255),l(n,n.gzhead.time>>24&255),l(n,9===n.level?2:2<=n.strategy||2>n.level?4:0),l(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(l(n,255&n.gzhead.extra.length),l(n,n.gzhead.extra.length>>
 8&255)),n.gzhead.hcrc&&(b.adler=F(b.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=69):(l(n,0),l(n,0),l(n,0),l(n,0),l(n,0),l(n,9===n.level?2:2<=n.strategy||2>n.level?4:0),l(n,3),n.status=Z)):(q=T+(n.w_bits-8<<4)<<8,q|=(2<=n.strategy||2>n.level?0:6>n.level?1:6===n.level?2:3)<<6,0!==n.strstart&&(q|=32),n.status=Z,m(n,q+(31-q%31)),0!==n.strstart&&(m(n,b.adler>>>16),m(n,65535&b.adler)),b.adler=1);if(69===n.status)if(n.gzhead.extra){for(q=n.pending;n.gzindex<(65535&n.gzhead.extra.length)&&(n.pending!==
 n.pending_buf_size||(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q)),g(b),q=n.pending,n.pending!==n.pending_buf_size));)l(n,255&n.gzhead.extra[n.gzindex]),n.gzindex++;n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=73)}else n.status=73;if(73===n.status)if(n.gzhead.name){q=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-
-q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){t=1;break}t=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0;l(n,t)}while(0!==t);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===t&&(n.gzindex=0,n.status=91)}else n.status=91;if(91===n.status)if(n.gzhead.comment){q=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){t=
-1;break}t=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0;l(n,t)}while(0!==t);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===t&&(n.status=103)}else n.status=103;if(103===n.status&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&g(b),n.pending+2<=n.pending_buf_size&&(l(n,255&b.adler),l(n,b.adler>>8&255),b.adler=0,n.status=Z)):n.status=Z),0!==n.pending){if(g(b),0===b.avail_out)return n.last_flush=-1,I}else if(0===b.avail_in&&(c<<1)-
-(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==E)return e(b,-5);if(666===n.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==n.lookahead||c!==H&&666!==n.status){var r;if(2===n.strategy)a:{for(var u;;){if(0===n.lookahead&&(p(n),0===n.lookahead)){if(c===H){r=R;break a}break}if(n.match_length=0,u=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++,u&&(k(n,!1),0===n.strm.avail_out)){r=R;break a}}r=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?
-R:aa)}else if(3===n.strategy)a:{var x,D;for(u=n.window;;){if(n.lookahead<=M){if(p(n),n.lookahead<=M&&c===H){r=R;break a}if(0===n.lookahead)break}if(n.match_length=0,n.lookahead>=K&&0<n.strstart&&(D=n.strstart-1,x=u[D],x===u[++D]&&x===u[++D]&&x===u[++D])){for(d=n.strstart+M;x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&D<d;);n.match_length=M-(d-D);n.match_length>n.lookahead&&(n.match_length=n.lookahead)}if(n.match_length>=K?(r=B._tr_tally(n,1,n.match_length-
-K),n.lookahead-=n.match_length,n.strstart+=n.match_length,n.match_length=0):(r=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++),r&&(k(n,!1),0===n.strm.avail_out)){r=R;break a}}r=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?R:aa)}else r=A[n.level].func(n,c);if(r!==da&&r!==S||(n.status=666),r===R||r===da)return 0===b.avail_out&&(n.last_flush=-1),I;if(r===aa&&(1===c?B._tr_align(n):5!==c&&(B._tr_stored_block(n,0,0,!1),3===c&&(f(n.head),
+q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){r=1;break}r=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0;l(n,r)}while(0!==r);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===r&&(n.gzindex=0,n.status=91)}else n.status=91;if(91===n.status)if(n.gzhead.comment){q=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){r=
+1;break}r=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0;l(n,r)}while(0!==r);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===r&&(n.status=103)}else n.status=103;if(103===n.status&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&g(b),n.pending+2<=n.pending_buf_size&&(l(n,255&b.adler),l(n,b.adler>>8&255),b.adler=0,n.status=Z)):n.status=Z),0!==n.pending){if(g(b),0===b.avail_out)return n.last_flush=-1,I}else if(0===b.avail_in&&(c<<1)-
+(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==E)return e(b,-5);if(666===n.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==n.lookahead||c!==H&&666!==n.status){var t;if(2===n.strategy)a:{for(var u;;){if(0===n.lookahead&&(p(n),0===n.lookahead)){if(c===H){t=R;break a}break}if(n.match_length=0,u=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++,u&&(k(n,!1),0===n.strm.avail_out)){t=R;break a}}t=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?
+R:aa)}else if(3===n.strategy)a:{var x,D;for(u=n.window;;){if(n.lookahead<=N){if(p(n),n.lookahead<=N&&c===H){t=R;break a}if(0===n.lookahead)break}if(n.match_length=0,n.lookahead>=K&&0<n.strstart&&(D=n.strstart-1,x=u[D],x===u[++D]&&x===u[++D]&&x===u[++D])){for(d=n.strstart+N;x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&D<d;);n.match_length=N-(d-D);n.match_length>n.lookahead&&(n.match_length=n.lookahead)}if(n.match_length>=K?(t=B._tr_tally(n,1,n.match_length-
+K),n.lookahead-=n.match_length,n.strstart+=n.match_length,n.match_length=0):(t=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++),t&&(k(n,!1),0===n.strm.avail_out)){t=R;break a}}t=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?R:aa)}else t=A[n.level].func(n,c);if(t!==da&&t!==S||(n.status=666),t===R||t===da)return 0===b.avail_out&&(n.last_flush=-1),I;if(t===aa&&(1===c?B._tr_align(n):5!==c&&(B._tr_stored_block(n,0,0,!1),3===c&&(f(n.head),
 0===n.lookahead&&(n.strstart=0,n.block_start=0,n.insert=0))),g(b),0===b.avail_out))return n.last_flush=-1,I}return c!==E?I:0>=n.wrap?1:(2===n.wrap?(l(n,255&b.adler),l(n,b.adler>>8&255),l(n,b.adler>>16&255),l(n,b.adler>>24&255),l(n,255&b.total_in),l(n,b.total_in>>8&255),l(n,b.total_in>>16&255),l(n,b.total_in>>24&255)):(m(n,b.adler>>>16),m(n,65535&b.adler)),g(b),0<n.wrap&&(n.wrap=-n.wrap),0!==n.pending?I:1)};d.deflateEnd=function(b){var c;return b&&b.state?(c=b.state.status,c!==ca&&69!==c&&73!==c&&
-91!==c&&103!==c&&c!==Z&&666!==c?e(b,N):(b.state=null,c===Z?e(b,-3):I)):N};d.deflateSetDictionary=function(b,c){var d,e,k,g,l,m,n;e=c.length;if(!b||!b.state||(d=b.state,g=d.wrap,2===g||1===g&&d.status!==ca||d.lookahead))return N;1===g&&(b.adler=G(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===g&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),l=new v.Buf8(d.w_size),v.arraySet(l,c,e-d.w_size,d.w_size,0),c=l,e=d.w_size);l=b.avail_in;m=b.next_in;n=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(p(d);d.lookahead>=
+91!==c&&103!==c&&c!==Z&&666!==c?e(b,M):(b.state=null,c===Z?e(b,-3):I)):M};d.deflateSetDictionary=function(b,c){var d,e,k,g,l,m,n;e=c.length;if(!b||!b.state||(d=b.state,g=d.wrap,2===g||1===g&&d.status!==ca||d.lookahead))return M;1===g&&(b.adler=G(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===g&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),l=new v.Buf8(d.w_size),v.arraySet(l,c,e-d.w_size,d.w_size,0),c=l,e=d.w_size);l=b.avail_in;m=b.next_in;n=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(p(d);d.lookahead>=
 K;){e=d.strstart;k=d.lookahead-(K-1);do d.ins_h=(d.ins_h<<d.hash_shift^d.window[e+K-1])&d.hash_mask,d.prev[e&d.w_mask]=d.head[d.ins_h],d.head[d.ins_h]=e,e++;while(--k);d.strstart=e;d.lookahead=K-1;p(d)}return d.strstart+=d.lookahead,d.block_start=d.strstart,d.insert=d.lookahead,d.lookahead=0,d.match_length=d.prev_length=K-1,d.match_available=0,b.next_in=m,b.input=n,b.avail_in=l,d.wrap=g,I};d.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":3,"./adler32":5,"./crc32":7,"./messages":13,
-"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,m,n,p,q,t,r,u,x,z,y,A,v,B,G,F,C,H,E,I,N,L;d=b.state;e=b.next_in;N=b.input;f=e+(b.avail_in-5);m=b.next_out;L=b.output;n=m-(c-b.avail_out);p=m+(b.avail_out-257);q=d.dmax;t=d.wsize;r=d.whave;u=d.wnext;x=d.window;z=d.hold;y=d.bits;A=d.lencode;v=d.distcode;B=(1<<d.lenbits)-
-1;G=(1<<d.distbits)-1;a:do b:for(15>y&&(z+=N[e++]<<y,y+=8,z+=N[e++]<<y,y+=8),F=A[z&B];;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,0===C)L[m++]=65535&F;else{if(!(16&C)){if(0===(64&C)){F=A[(65535&F)+(z&(1<<C)-1)];continue b}if(32&C){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}H=65535&F;(C&=15)&&(y<C&&(z+=N[e++]<<y,y+=8),H+=z&(1<<C)-1,z>>>=C,y-=C);15>y&&(z+=N[e++]<<y,y+=8,z+=N[e++]<<y,y+=8);F=v[z&G];c:for(;;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,!(16&C)){if(0===(64&C)){F=v[(65535&
-F)+(z&(1<<C)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(E=65535&F,C&=15,y<C&&(z+=N[e++]<<y,y+=8,y<C&&(z+=N[e++]<<y,y+=8)),E+=z&(1<<C)-1,E>q){b.msg="invalid distance too far back";d.mode=30;break a}if(z>>>=C,y-=C,C=m-n,E>C){if(C=E-C,C>r&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(F=0,I=x,0===u){if(F+=t-C,C<H){H-=C;do L[m++]=x[F++];while(--C);F=m-E;I=L}}else if(u<C){if(F+=t+u-C,C-=u,C<H){H-=C;do L[m++]=x[F++];while(--C);if(F=0,u<H){C=u;H-=C;do L[m++]=x[F++];
+"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,m,n,p,q,t,r,u,x,z,y,A,v,B,G,F,C,H,E,I,M,L;d=b.state;e=b.next_in;M=b.input;f=e+(b.avail_in-5);m=b.next_out;L=b.output;n=m-(c-b.avail_out);p=m+(b.avail_out-257);q=d.dmax;t=d.wsize;r=d.whave;u=d.wnext;x=d.window;z=d.hold;y=d.bits;A=d.lencode;v=d.distcode;B=(1<<d.lenbits)-
+1;G=(1<<d.distbits)-1;a:do b:for(15>y&&(z+=M[e++]<<y,y+=8,z+=M[e++]<<y,y+=8),F=A[z&B];;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,0===C)L[m++]=65535&F;else{if(!(16&C)){if(0===(64&C)){F=A[(65535&F)+(z&(1<<C)-1)];continue b}if(32&C){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}H=65535&F;(C&=15)&&(y<C&&(z+=M[e++]<<y,y+=8),H+=z&(1<<C)-1,z>>>=C,y-=C);15>y&&(z+=M[e++]<<y,y+=8,z+=M[e++]<<y,y+=8);F=v[z&G];c:for(;;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,!(16&C)){if(0===(64&C)){F=v[(65535&
+F)+(z&(1<<C)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(E=65535&F,C&=15,y<C&&(z+=M[e++]<<y,y+=8,y<C&&(z+=M[e++]<<y,y+=8)),E+=z&(1<<C)-1,E>q){b.msg="invalid distance too far back";d.mode=30;break a}if(z>>>=C,y-=C,C=m-n,E>C){if(C=E-C,C>r&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(F=0,I=x,0===u){if(F+=t-C,C<H){H-=C;do L[m++]=x[F++];while(--C);F=m-E;I=L}}else if(u<C){if(F+=t+u-C,C-=u,C<H){H-=C;do L[m++]=x[F++];while(--C);if(F=0,u<H){C=u;H-=C;do L[m++]=x[F++];
 while(--C);F=m-E;I=L}}}else if(F+=u-C,C<H){H-=C;do L[m++]=x[F++];while(--C);F=m-E;I=L}for(;2<H;)L[m++]=I[F++],L[m++]=I[F++],L[m++]=I[F++],H-=3;H&&(L[m++]=I[F++],1<H&&(L[m++]=I[F++]))}else{F=m-E;do L[m++]=L[F++],L[m++]=L[F++],L[m++]=L[F++],H-=3;while(2<H);H&&(L[m++]=L[F++],1<H&&(L[m++]=L[F++]))}break}}break}while(e<f&&m<p);H=y>>3;e-=H;y-=H<<3;b.next_in=e;b.next_out=m;b.avail_in=e<f?5+(f-e):5-(e-f);b.avail_out=m<p?257+(p-m):257-(m-p);d.hold=z&(1<<y)-1;d.bits=y}},{}],11:[function(b,c,d){function e(b){return(b>>>
 24&255)+(b>>>8&65280)+((65280&b)<<8)+((255&b)<<24)}function f(){this.mode=0;this.last=!1;this.wrap=0;this.havedict=!1;this.total=this.check=this.dmax=this.flags=0;this.head=null;this.wnext=this.whave=this.wsize=this.wbits=0;this.window=null;this.extra=this.offset=this.length=this.bits=this.hold=0;this.distcode=this.lencode=null;this.have=this.ndist=this.nlen=this.ncode=this.distbits=this.lenbits=0;this.next=null;this.lens=new t.Buf16(320);this.work=new t.Buf16(288);this.distdyn=this.lendyn=null;this.was=
 this.back=this.sane=0}function g(b){var c;return b&&b.state?(c=b.state,b.total_in=b.total_out=c.total=0,b.msg="",c.wrap&&(b.adler=1&c.wrap),c.mode=v,c.last=0,c.havedict=0,c.dmax=32768,c.head=null,c.hold=0,c.bits=0,c.lencode=c.lendyn=new t.Buf32(B),c.distcode=c.distdyn=new t.Buf32(G),c.sane=1,c.back=-1,y):A}function k(b){var c;return b&&b.state?(c=b.state,c.wsize=0,c.whave=0,c.wnext=0,g(b)):A}function l(b,c){var d,e;return b&&b.state?(e=b.state,0>c?(d=0,c=-c):(d=(c>>4)+1,48>c&&(c&=15)),c&&(8>c||15<
 c)?A:(null!==e.window&&e.wbits!==c&&(e.window=null),e.wrap=d,e.wbits=c,k(b))):A}function m(b,c){var d,e;return b?(e=new f,b.state=e,e.window=null,d=l(b,c),d!==y&&(b.state=null),d):A}function n(b,c,d,e){var f;b=b.state;return null===b.window&&(b.wsize=1<<b.wbits,b.wnext=0,b.whave=0,b.window=new t.Buf8(b.wsize)),e>=b.wsize?(t.arraySet(b.window,c,d-b.wsize,b.wsize,0),b.wnext=0,b.whave=b.wsize):(f=b.wsize-b.wnext,f>e&&(f=e),t.arraySet(b.window,c,d-e,f,b.wnext),e-=f,e?(t.arraySet(b.window,c,d-e,e,0),b.wnext=
-e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var p,q,t=b("../utils/common"),r=b("./adler32"),u=b("./crc32"),x=b("./inffast"),z=b("./inftrees"),y=0,A=-2,v=1,B=852,G=592,F=!0;d.inflateReset=k;d.inflateReset2=l;d.inflateResetKeep=g;d.inflateInit=function(b){return m(b,15)};d.inflateInit2=m;d.inflate=function(b,c){var d,f,k,g,l,m,C,B,D,X,H,J,G,O,K,M,U,ca,Z,R,aa,da,S=0,W=new t.Buf8(4),ga=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
+e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var p,q,t=b("../utils/common"),r=b("./adler32"),u=b("./crc32"),x=b("./inffast"),z=b("./inftrees"),y=0,A=-2,v=1,B=852,G=592,F=!0;d.inflateReset=k;d.inflateReset2=l;d.inflateResetKeep=g;d.inflateInit=function(b){return m(b,15)};d.inflateInit2=m;d.inflate=function(b,c){var d,f,k,g,l,m,C,B,D,X,H,J,G,O,K,N,U,ca,Z,R,aa,da,S=0,W=new t.Buf8(4),ga=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
 !b.output||!b.input&&0!==b.avail_in)return A;d=b.state;12===d.mode&&(d.mode=13);l=b.next_out;k=b.output;C=b.avail_out;g=b.next_in;f=b.input;m=b.avail_in;B=d.hold;D=d.bits;X=m;H=C;aa=y;a:for(;;)switch(d.mode){case v:if(0===d.wrap){d.mode=13;break}for(;16>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(2&d.wrap&&35615===B){d.check=0;W[0]=255&B;W[1]=B>>>8&255;d.check=u(d.check,W,2,0);D=B=0;d.mode=2;break}if(d.flags=0,d.head&&(d.head.done=!1),!(1&d.wrap)||(((255&B)<<8)+(B>>8))%31){b.msg="incorrect header check";
 d.mode=30;break}if(8!==(15&B)){b.msg="unknown compression method";d.mode=30;break}if(B>>>=4,D-=4,R=(15&B)+8,0===d.wbits)d.wbits=R;else if(R>d.wbits){b.msg="invalid window size";d.mode=30;break}d.dmax=1<<R;b.adler=d.check=1;d.mode=512&B?10:12;D=B=0;break;case 2:for(;16>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(d.flags=B,8!==(255&d.flags)){b.msg="unknown compression method";d.mode=30;break}if(57344&d.flags){b.msg="unknown header flags set";d.mode=30;break}d.head&&(d.head.text=B>>8&1);512&d.flags&&
 (W[0]=255&B,W[1]=B>>>8&255,d.check=u(d.check,W,2,0));D=B=0;d.mode=3;case 3:for(;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.head&&(d.head.time=B);512&d.flags&&(W[0]=255&B,W[1]=B>>>8&255,W[2]=B>>>16&255,W[3]=B>>>24&255,d.check=u(d.check,W,4,0));D=B=0;d.mode=4;case 4:for(;16>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.head&&(d.head.xflags=255&B,d.head.os=B>>8);512&d.flags&&(W[0]=255&B,W[1]=B>>>8&255,d.check=u(d.check,W,2,0));D=B=0;d.mode=5;case 5:if(1024&d.flags){for(;16>D;){if(0===m)break a;m--;
 B+=f[g++]<<D;D+=8}d.length=B;d.head&&(d.head.extra_len=B);512&d.flags&&(W[0]=255&B,W[1]=B>>>8&255,d.check=u(d.check,W,2,0));D=B=0}else d.head&&(d.head.extra=null);d.mode=6;case 6:if(1024&d.flags&&(J=d.length,J>m&&(J=m),J&&(d.head&&(R=d.head.extra_len-d.length,d.head.extra||(d.head.extra=Array(d.head.extra_len)),t.arraySet(d.head.extra,f,g,J,R)),512&d.flags&&(d.check=u(d.check,f,J,g)),m-=J,g+=J,d.length-=J),d.length))break a;d.length=0;d.mode=7;case 7:if(2048&d.flags){if(0===m)break a;J=0;do R=f[g+
 J++],d.head&&R&&65536>d.length&&(d.head.name+=String.fromCharCode(R));while(R&&J<m);if(512&d.flags&&(d.check=u(d.check,f,J,g)),m-=J,g+=J,R)break a}else d.head&&(d.head.name=null);d.length=0;d.mode=8;case 8:if(4096&d.flags){if(0===m)break a;J=0;do R=f[g+J++],d.head&&R&&65536>d.length&&(d.head.comment+=String.fromCharCode(R));while(R&&J<m);if(512&d.flags&&(d.check=u(d.check,f,J,g)),m-=J,g+=J,R)break a}else d.head&&(d.head.comment=null);d.mode=9;case 9:if(512&d.flags){for(;16>D;){if(0===m)break a;m--;
 B+=f[g++]<<D;D+=8}if(B!==(65535&d.check)){b.msg="header crc mismatch";d.mode=30;break}D=B=0}d.head&&(d.head.hcrc=d.flags>>9&1,d.head.done=!0);b.adler=d.check=0;d.mode=12;break;case 10:for(;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}b.adler=d.check=e(B);D=B=0;d.mode=11;case 11:if(0===d.havedict)return b.next_out=l,b.avail_out=C,b.next_in=g,b.avail_in=m,d.hold=B,d.bits=D,2;b.adler=d.check=1;d.mode=12;case 12:if(5===c||6===c)break a;case 13:if(d.last){B>>>=7&D;D-=7&D;d.mode=27;break}for(;3>D;){if(0===
-m)break a;m--;B+=f[g++]<<D;D+=8}switch(d.last=1&B,B>>>=1,--D,3&B){case 0:d.mode=14;break;case 1:M=d;if(F){p=new t.Buf32(512);q=new t.Buf32(32);for(O=0;144>O;)M.lens[O++]=8;for(;256>O;)M.lens[O++]=9;for(;280>O;)M.lens[O++]=7;for(;288>O;)M.lens[O++]=8;z(1,M.lens,0,288,p,0,M.work,{bits:9});for(O=0;32>O;)M.lens[O++]=5;z(2,M.lens,0,32,q,0,M.work,{bits:5});F=!1}M.lencode=p;M.lenbits=9;M.distcode=q;M.distbits=5;if(d.mode=20,6===c){B>>>=2;D-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
+m)break a;m--;B+=f[g++]<<D;D+=8}switch(d.last=1&B,B>>>=1,--D,3&B){case 0:d.mode=14;break;case 1:N=d;if(F){p=new t.Buf32(512);q=new t.Buf32(32);for(O=0;144>O;)N.lens[O++]=8;for(;256>O;)N.lens[O++]=9;for(;280>O;)N.lens[O++]=7;for(;288>O;)N.lens[O++]=8;z(1,N.lens,0,288,p,0,N.work,{bits:9});for(O=0;32>O;)N.lens[O++]=5;z(2,N.lens,0,32,q,0,N.work,{bits:5});F=!1}N.lencode=p;N.lenbits=9;N.distcode=q;N.distbits=5;if(d.mode=20,6===c){B>>>=2;D-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
 d.mode=30}B>>>=2;D-=2;break;case 14:B>>>=7&D;for(D-=7&D;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if((65535&B)!==(B>>>16^65535)){b.msg="invalid stored block lengths";d.mode=30;break}if(d.length=65535&B,B=0,D=0,d.mode=15,6===c)break a;case 15:d.mode=16;case 16:if(J=d.length){if(J>m&&(J=m),J>C&&(J=C),0===J)break a;t.arraySet(k,f,g,J,l);m-=J;g+=J;C-=J;l+=J;d.length-=J;break}d.mode=12;break;case 17:for(;14>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(d.nlen=(31&B)+257,B>>>=5,D-=5,d.ndist=(31&B)+
 1,B>>>=5,D-=5,d.ncode=(15&B)+4,B>>>=4,D-=4,286<d.nlen||30<d.ndist){b.msg="too many length or distance symbols";d.mode=30;break}d.have=0;d.mode=18;case 18:for(;d.have<d.ncode;){for(;3>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.lens[ga[d.have++]]=7&B;B>>>=3;D-=3}for(;19>d.have;)d.lens[ga[d.have++]]=0;if(d.lencode=d.lendyn,d.lenbits=7,da={bits:d.lenbits},aa=z(0,d.lens,0,19,d.lencode,0,d.work,da),d.lenbits=da.bits,aa){b.msg="invalid code lengths set";d.mode=30;break}d.have=0;d.mode=19;case 19:for(;d.have<
-d.nlen+d.ndist;){for(;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,M=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(16>M)B>>>=K,D-=K,d.lens[d.have++]=M;else{if(16===M){for(O=K+2;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(B>>>=K,D-=K,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}R=d.lens[d.have-1];J=3+(3&B);B>>>=2;D-=2}else if(17===M){for(O=K+3;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=K;D-=K;R=0;J=3+(7&B);B>>>=3;D-=3}else{for(O=K+7;D<O;){if(0===m)break a;m--;
+d.nlen+d.ndist;){for(;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,N=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(16>N)B>>>=K,D-=K,d.lens[d.have++]=N;else{if(16===N){for(O=K+2;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(B>>>=K,D-=K,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}R=d.lens[d.have-1];J=3+(3&B);B>>>=2;D-=2}else if(17===N){for(O=K+3;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=K;D-=K;R=0;J=3+(7&B);B>>>=3;D-=3}else{for(O=K+7;D<O;){if(0===m)break a;m--;
 B+=f[g++]<<D;D+=8}B>>>=K;D-=K;R=0;J=11+(127&B);B>>>=7;D-=7}if(d.have+J>d.nlen+d.ndist){b.msg="invalid bit length repeat";d.mode=30;break}for(;J--;)d.lens[d.have++]=R}}if(30===d.mode)break;if(0===d.lens[256]){b.msg="invalid code -- missing end-of-block";d.mode=30;break}if(d.lenbits=9,da={bits:d.lenbits},aa=z(1,d.lens,0,d.nlen,d.lencode,0,d.work,da),d.lenbits=da.bits,aa){b.msg="invalid literal/lengths set";d.mode=30;break}if(d.distbits=6,d.distcode=d.distdyn,da={bits:d.distbits},aa=z(2,d.lens,d.nlen,
-d.ndist,d.distcode,0,d.work,da),d.distbits=da.bits,aa){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=m&&258<=C){b.next_out=l;b.avail_out=C;b.next_in=g;b.avail_in=m;d.hold=B;d.bits=D;x(b,H);l=b.next_out;k=b.output;C=b.avail_out;g=b.next_in;f=b.input;m=b.avail_in;B=d.hold;D=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,O=S>>>16&255,M=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(O&&
-0===(240&O)){U=K;ca=O;for(Z=M;S=d.lencode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,M=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,d.length=M,0===O){d.mode=26;break}if(32&O){d.back=-1;d.mode=12;break}if(64&O){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&O;d.mode=22;case 22:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.length+=B&(1<<d.extra)-1;B>>>=d.extra;D-=d.extra;d.back+=d.extra}d.was=
-d.length;d.mode=23;case 23:for(;S=d.distcode[B&(1<<d.distbits)-1],K=S>>>24,O=S>>>16&255,M=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(0===(240&O)){U=K;ca=O;for(Z=M;S=d.distcode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,M=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,64&O){b.msg="invalid distance code";d.mode=30;break}d.offset=M;d.extra=15&O;d.mode=24;case 24:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<
+d.ndist,d.distcode,0,d.work,da),d.distbits=da.bits,aa){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=m&&258<=C){b.next_out=l;b.avail_out=C;b.next_in=g;b.avail_in=m;d.hold=B;d.bits=D;x(b,H);l=b.next_out;k=b.output;C=b.avail_out;g=b.next_in;f=b.input;m=b.avail_in;B=d.hold;D=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,O=S>>>16&255,N=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(O&&
+0===(240&O)){U=K;ca=O;for(Z=N;S=d.lencode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,N=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,d.length=N,0===O){d.mode=26;break}if(32&O){d.back=-1;d.mode=12;break}if(64&O){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&O;d.mode=22;case 22:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.length+=B&(1<<d.extra)-1;B>>>=d.extra;D-=d.extra;d.back+=d.extra}d.was=
+d.length;d.mode=23;case 23:for(;S=d.distcode[B&(1<<d.distbits)-1],K=S>>>24,O=S>>>16&255,N=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(0===(240&O)){U=K;ca=O;for(Z=N;S=d.distcode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,N=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,64&O){b.msg="invalid distance code";d.mode=30;break}d.offset=N;d.extra=15&O;d.mode=24;case 24:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<
 D;D+=8}d.offset+=B&(1<<d.extra)-1;B>>>=d.extra;D-=d.extra;d.back+=d.extra}if(d.offset>d.dmax){b.msg="invalid distance too far back";d.mode=30;break}d.mode=25;case 25:if(0===C)break a;if(J=H-C,d.offset>J){if(J=d.offset-J,J>d.whave&&d.sane){b.msg="invalid distance too far back";d.mode=30;break}J>d.wnext?(J-=d.wnext,G=d.wsize-J):G=d.wnext-J;J>d.length&&(J=d.length);O=d.window}else O=k,G=l-d.offset,J=d.length;J>C&&(J=C);C-=J;d.length-=J;do k[l++]=O[G++];while(--J);0===d.length&&(d.mode=21);break;case 26:if(0===
 C)break a;k[l++]=d.length;C--;d.mode=21;break;case 27:if(d.wrap){for(;32>D;){if(0===m)break a;m--;B|=f[g++]<<D;D+=8}if(H-=C,b.total_out+=H,d.total+=H,H&&(b.adler=d.check=d.flags?u(d.check,k,H,l-H):r(d.check,k,H,l-H)),H=C,(d.flags?B:e(B))!==d.check){b.msg="incorrect data check";d.mode=30;break}D=B=0}d.mode=28;case 28:if(d.wrap&&d.flags){for(;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(B!==(4294967295&d.total)){b.msg="incorrect length check";d.mode=30;break}D=B=0}d.mode=29;case 29:aa=1;break a;
 case 30:aa=-3;break a;case 31:return-4;default:return A}return b.next_out=l,b.avail_out=C,b.next_in=g,b.avail_in=m,d.hold=B,d.bits=D,(d.wsize||H!==b.avail_out&&30>d.mode&&(27>d.mode||4!==c))&&n(b,b.output,b.next_out,H-b.avail_out)?(d.mode=31,-4):(X-=b.avail_in,H-=b.avail_out,b.total_in+=X,b.total_out+=H,d.total+=H,d.wrap&&H&&(b.adler=d.check=d.flags?u(d.check,k,H,b.next_out-H):r(d.check,k,H,b.next_out-H)),b.data_type=d.bits+(d.last?64:0)+(12===d.mode?128:0)+(20===d.mode||15===d.mode?256:0),(0===X&&
 0===H||4===c)&&aa===y&&(aa=-5),aa)};d.inflateEnd=function(b){if(!b||!b.state)return A;var c=b.state;return c.window&&(c.window=null),b.state=null,y};d.inflateGetHeader=function(b,c){var d;return b&&b.state?(d=b.state,0===(2&d.wrap)?A:(d.head=c,c.done=!1,y)):A};d.inflateSetDictionary=function(b,c){var d,e,f=c.length;return b&&b.state?(d=b.state,0!==d.wrap&&11!==d.mode?A:11===d.mode&&(e=1,e=r(e,c,f,0),e!==d.check)?-3:n(b,c,f,f)?(d.mode=31,-4):(d.havedict=1,y)):A};d.inflateInfo="pako inflate (from Nodeca project)"},
 {"../utils/common":3,"./adler32":5,"./crc32":7,"./inffast":10,"./inftrees":12}],12:[function(b,c,d){var e=b("../utils/common"),f=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],k=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],l=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,
-25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,q,t,r,u,x){var m,n,p,v,B,G,F,C,H=x.bits,E,I,N,L,V,P,ba=0,T,D=null,X=0,Q=new e.Buf16(16);v=new e.Buf16(16);var J=null,Y=0;for(E=0;15>=E;E++)Q[E]=0;for(I=0;I<q;I++)Q[c[d+I]]++;L=H;for(N=15;1<=N&&0===Q[N];N--);if(L>N&&(L=N),0===N)return t[r++]=20971520,t[r++]=20971520,x.bits=1,0;for(H=1;H<N&&0===Q[H];H++);L<H&&(L=H);for(E=m=1;15>=E;E++)if(m<<=1,m-=Q[E],0>m)return-1;if(0<m&&(0===b||1!==N))return-1;v[1]=0;for(E=1;15>E;E++)v[E+1]=v[E]+Q[E];for(I=
-0;I<q;I++)0!==c[d+I]&&(u[v[c[d+I]]++]=I);if(0===b?(D=J=u,B=19):1===b?(D=f,X-=257,J=g,Y-=257,B=256):(D=k,J=l,B=-1),T=0,I=0,E=H,v=r,V=L,P=0,p=-1,ba=1<<L,q=ba-1,1===b&&852<ba||2===b&&592<ba)return 1;for(var O=0;;){O++;G=E-P;u[I]<B?(F=0,C=u[I]):u[I]>B?(F=J[Y+u[I]],C=D[X+u[I]]):(F=96,C=0);m=1<<E-P;H=n=1<<V;do n-=m,t[v+(T>>P)+n]=G<<24|F<<16|C|0;while(0!==n);for(m=1<<E-1;T&m;)m>>=1;if(0!==m?(T&=m-1,T+=m):T=0,I++,0===--Q[E]){if(E===N)break;E=c[d+u[I]]}if(E>L&&(T&q)!==p){0===P&&(P=L);v+=H;V=E-P;for(m=1<<V;V+
-P<N&&(m-=Q[V+P],!(0>=m));)V++,m<<=1;if(ba+=1<<V,1===b&&852<ba||2===b&&592<ba)return 1;p=T&q;t[p]=L<<24|V<<16|v-r|0}}return 0!==T&&(t[v+T]=E-P<<24|4194304),x.bits=L,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
+25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,q,t,r,u,x){var m,n,p,v,B,G,F,C,H=x.bits,E,I,M,L,V,P,ba=0,T,D=null,X=0,Q=new e.Buf16(16);v=new e.Buf16(16);var J=null,Y=0;for(E=0;15>=E;E++)Q[E]=0;for(I=0;I<q;I++)Q[c[d+I]]++;L=H;for(M=15;1<=M&&0===Q[M];M--);if(L>M&&(L=M),0===M)return t[r++]=20971520,t[r++]=20971520,x.bits=1,0;for(H=1;H<M&&0===Q[H];H++);L<H&&(L=H);for(E=m=1;15>=E;E++)if(m<<=1,m-=Q[E],0>m)return-1;if(0<m&&(0===b||1!==M))return-1;v[1]=0;for(E=1;15>E;E++)v[E+1]=v[E]+Q[E];for(I=
+0;I<q;I++)0!==c[d+I]&&(u[v[c[d+I]]++]=I);if(0===b?(D=J=u,B=19):1===b?(D=f,X-=257,J=g,Y-=257,B=256):(D=k,J=l,B=-1),T=0,I=0,E=H,v=r,V=L,P=0,p=-1,ba=1<<L,q=ba-1,1===b&&852<ba||2===b&&592<ba)return 1;for(var O=0;;){O++;G=E-P;u[I]<B?(F=0,C=u[I]):u[I]>B?(F=J[Y+u[I]],C=D[X+u[I]]):(F=96,C=0);m=1<<E-P;H=n=1<<V;do n-=m,t[v+(T>>P)+n]=G<<24|F<<16|C|0;while(0!==n);for(m=1<<E-1;T&m;)m>>=1;if(0!==m?(T&=m-1,T+=m):T=0,I++,0===--Q[E]){if(E===M)break;E=c[d+u[I]]}if(E>L&&(T&q)!==p){0===P&&(P=L);v+=H;V=E-P;for(m=1<<V;V+
+P<M&&(m-=Q[V+P],!(0>=m));)V++,m<<=1;if(ba+=1<<V,1===b&&852<ba||2===b&&592<ba)return 1;p=T&q;t[p]=L<<24|V<<16|v-r|0}}return 0!==T&&(t[v+T]=E-P<<24|4194304),x.bits=L,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
 b;this.extra_bits=c;this.extra_base=d;this.elems=e;this.max_length=f;this.has_stree=b&&b.length}function g(b,c){this.dyn_tree=b;this.max_code=0;this.stat_desc=c}function k(b,c){b.pending_buf[b.pending++]=255&c;b.pending_buf[b.pending++]=c>>>8&255}function l(b,c,d){b.bi_valid>ba-d?(b.bi_buf|=c<<b.bi_valid&65535,k(b,b.bi_buf),b.bi_buf=c>>ba-b.bi_valid,b.bi_valid+=d-ba):(b.bi_buf|=c<<b.bi_valid&65535,b.bi_valid+=d)}function m(b,c,d){l(b,d[2*c],d[2*c+1])}function n(b,c){var d=0;do d|=1&b,b>>>=1,d<<=1;
-while(0<--c);return d>>>1}function p(b,c,d){var e,f=Array(P+1),k=0;for(e=1;e<=P;e++)f[e]=k=k+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=n(f[e]++,e))}function q(b){var c;for(c=0;c<I;c++)b.dyn_ltree[2*c]=0;for(c=0;c<N;c++)b.dyn_dtree[2*c]=0;for(c=0;c<L;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*T]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function t(b){8<b.bi_valid?k(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function r(b,c,d,e){var f=2*c,k=2*d;
+while(0<--c);return d>>>1}function p(b,c,d){var e,f=Array(P+1),k=0;for(e=1;e<=P;e++)f[e]=k=k+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=n(f[e]++,e))}function q(b){var c;for(c=0;c<I;c++)b.dyn_ltree[2*c]=0;for(c=0;c<M;c++)b.dyn_dtree[2*c]=0;for(c=0;c<L;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*T]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function t(b){8<b.bi_valid?k(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function r(b,c,d,e){var f=2*c,k=2*d;
 return b[f]<b[k]||b[f]===b[k]&&e[c]<=e[d]}function u(b,c,d){for(var e=b.heap[d],f=d<<1;f<=b.heap_len&&(f<b.heap_len&&r(c,b.heap[f+1],b.heap[f],b.depth)&&f++,!r(c,e,b.heap[f],b.depth));)b.heap[d]=b.heap[f],d=f,f<<=1;b.heap[d]=e}function x(b,c,d){var e,f,k,g,n=0;if(0!==b.last_lit){do e=b.pending_buf[b.d_buf+2*n]<<8|b.pending_buf[b.d_buf+2*n+1],f=b.pending_buf[b.l_buf+n],n++,0===e?m(b,f,c):(k=Z[f],m(b,k+E+1,c),g=J[k],0!==g&&(f-=R[k],l(b,f,g)),e--,k=256>e?ca[e]:ca[256+(e>>>7)],m(b,k,d),g=Y[k],0!==g&&
 (e-=aa[k],l(b,e,g)));while(n<b.last_lit)}m(b,T,c)}function z(b,c){var d,e,f,k=c.dyn_tree;e=c.stat_desc.static_tree;var g=c.stat_desc.has_stree,l=c.stat_desc.elems,m=-1;b.heap_len=0;b.heap_max=V;for(d=0;d<l;d++)0!==k[2*d]?(b.heap[++b.heap_len]=m=d,b.depth[d]=0):k[2*d+1]=0;for(;2>b.heap_len;)f=b.heap[++b.heap_len]=2>m?++m:0,k[2*f]=1,b.depth[f]=0,b.opt_len--,g&&(b.static_len-=e[2*f+1]);c.max_code=m;for(d=b.heap_len>>1;1<=d;d--)u(b,k,d);f=l;do d=b.heap[1],b.heap[1]=b.heap[b.heap_len--],u(b,k,1),e=b.heap[1],
-b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,k[2*f]=k[2*d]+k[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,k[2*d+1]=k[2*e+1]=f,b.heap[1]=f++,u(b,k,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var n,q,g=c.dyn_tree,l=c.max_code,r=c.stat_desc.static_tree,t=c.stat_desc.has_stree,x=c.stat_desc.extra_bits,D=c.stat_desc.extra_base,v=c.stat_desc.max_length,z=0;for(e=0;e<=P;e++)b.bl_count[e]=0;g[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=g[2*g[2*f+1]+1]+
-1,e>v&&(e=v,z++),g[2*f+1]=e,f>l||(b.bl_count[e]++,n=0,f>=D&&(n=x[f-D]),q=g[2*f],b.opt_len+=q*(e+n),t&&(b.static_len+=q*(r[2*f+1]+n)));if(0!==z){do{for(e=v-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[v]--;z-=2}while(0<z);for(e=v;0!==e;e--)for(f=b.bl_count[e];0!==f;)n=b.heap[--d],n>l||(g[2*n+1]!==e&&(b.opt_len+=(e-g[2*n+1])*g[2*n],g[2*n+1]=e),f--)}p(k,m,b.bl_count)}function y(b,c,d){var e,f,k=-1,g=c[1],l=0,m=7,n=4;0===g&&(m=138,n=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=g,
+b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,k[2*f]=k[2*d]+k[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,k[2*d+1]=k[2*e+1]=f,b.heap[1]=f++,u(b,k,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var n,q,g=c.dyn_tree,l=c.max_code,t=c.stat_desc.static_tree,r=c.stat_desc.has_stree,x=c.stat_desc.extra_bits,D=c.stat_desc.extra_base,v=c.stat_desc.max_length,z=0;for(e=0;e<=P;e++)b.bl_count[e]=0;g[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=g[2*g[2*f+1]+1]+
+1,e>v&&(e=v,z++),g[2*f+1]=e,f>l||(b.bl_count[e]++,n=0,f>=D&&(n=x[f-D]),q=g[2*f],b.opt_len+=q*(e+n),r&&(b.static_len+=q*(t[2*f+1]+n)));if(0!==z){do{for(e=v-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[v]--;z-=2}while(0<z);for(e=v;0!==e;e--)for(f=b.bl_count[e];0!==f;)n=b.heap[--d],n>l||(g[2*n+1]!==e&&(b.opt_len+=(e-g[2*n+1])*g[2*n],g[2*n+1]=e),f--)}p(k,m,b.bl_count)}function y(b,c,d){var e,f,k=-1,g=c[1],l=0,m=7,n=4;0===g&&(m=138,n=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=g,
 g=c[2*(e+1)+1],++l<m&&f===g||(l<n?b.bl_tree[2*f]+=l:0!==f?(f!==k&&b.bl_tree[2*f]++,b.bl_tree[2*D]++):10>=l?b.bl_tree[2*X]++:b.bl_tree[2*Q]++,l=0,k=f,0===g?(m=138,n=3):f===g?(m=6,n=3):(m=7,n=4))}function A(b,c,d){var e,f,k=-1,g=c[1],n=0,p=7,q=4;0===g&&(p=138,q=3);for(e=0;e<=d;e++)if(f=g,g=c[2*(e+1)+1],!(++n<p&&f===g)){if(n<q){do m(b,f,b.bl_tree);while(0!==--n)}else 0!==f?(f!==k&&(m(b,f,b.bl_tree),n--),m(b,D,b.bl_tree),l(b,n-3,2)):10>=n?(m(b,X,b.bl_tree),l(b,n-3,3)):(m(b,Q,b.bl_tree),l(b,n-11,7));n=
-0;k=f;0===g?(p=138,q=3):f===g?(p=6,q=3):(p=7,q=4)}}function v(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return F;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return C;for(c=32;c<E;c++)if(0!==b.dyn_ltree[2*c])return C;return F}function B(b,c,d,e){l(b,(H<<1)+(e?1:0),3);t(b);k(b,d);k(b,~d);G.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var G=b("../utils/common"),F=0,C=1,H=0,E=256,I=E+1+29,N=30,L=19,V=2*I+1,P=15,ba=16,T=256,D=16,X=17,
-Q=18,J=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Y=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],O=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],K=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],M=Array(2*(I+2));e(M);var U=Array(2*N);e(U);var ca=Array(512);e(ca);var Z=Array(256);e(Z);var R=Array(29);e(R);var aa=Array(N);e(aa);var da,S,W,ga=!1;d._tr_init=function(b){if(!ga){var c,d,e,k=Array(P+1);for(e=d=0;28>e;e++)for(R[e]=d,c=0;c<1<<J[e];c++)Z[d++]=e;Z[d-1]=e;
-for(e=d=0;16>e;e++)for(aa[e]=d,c=0;c<1<<Y[e];c++)ca[d++]=e;for(d>>=7;e<N;e++)for(aa[e]=d<<7,c=0;c<1<<Y[e]-7;c++)ca[256+d++]=e;for(c=0;c<=P;c++)k[c]=0;for(c=0;143>=c;)M[2*c+1]=8,c++,k[8]++;for(;255>=c;)M[2*c+1]=9,c++,k[9]++;for(;279>=c;)M[2*c+1]=7,c++,k[7]++;for(;287>=c;)M[2*c+1]=8,c++,k[8]++;p(M,I+1,k);for(c=0;c<N;c++)U[2*c+1]=5,U[2*c]=n(c,5);da=new f(M,J,E+1,I,P);S=new f(U,Y,0,N,P);W=new f([],O,0,L,7);ga=!0}b.l_desc=new g(b.dyn_ltree,da);b.d_desc=new g(b.dyn_dtree,S);b.bl_desc=new g(b.bl_tree,W);
-b.bi_buf=0;b.bi_valid=0;q(b)};d._tr_stored_block=B;d._tr_flush_block=function(b,c,d,e){var f,k,g=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=v(b));z(b,b.l_desc);z(b,b.d_desc);y(b,b.dyn_ltree,b.l_desc.max_code);y(b,b.dyn_dtree,b.d_desc.max_code);z(b,b.bl_desc);for(g=L-1;3<=g&&0===b.bl_tree[2*K[g]+1];g--);g=(b.opt_len+=3*(g+1)+14,g);f=b.opt_len+3+7>>>3;k=b.static_len+3+7>>>3;k<=f&&(f=k)}else f=k=d+5;if(d+4<=f&&-1!==c)B(b,c,d,e);else if(4===b.strategy||k===f)l(b,2+(e?1:0),3),x(b,M,U);else{l(b,
+0;k=f;0===g?(p=138,q=3):f===g?(p=6,q=3):(p=7,q=4)}}function v(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return F;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return C;for(c=32;c<E;c++)if(0!==b.dyn_ltree[2*c])return C;return F}function B(b,c,d,e){l(b,(H<<1)+(e?1:0),3);t(b);k(b,d);k(b,~d);G.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var G=b("../utils/common"),F=0,C=1,H=0,E=256,I=E+1+29,M=30,L=19,V=2*I+1,P=15,ba=16,T=256,D=16,X=17,
+Q=18,J=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Y=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],O=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],K=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],N=Array(2*(I+2));e(N);var U=Array(2*M);e(U);var ca=Array(512);e(ca);var Z=Array(256);e(Z);var R=Array(29);e(R);var aa=Array(M);e(aa);var da,S,W,ga=!1;d._tr_init=function(b){if(!ga){var c,d,e,k=Array(P+1);for(e=d=0;28>e;e++)for(R[e]=d,c=0;c<1<<J[e];c++)Z[d++]=e;Z[d-1]=e;
+for(e=d=0;16>e;e++)for(aa[e]=d,c=0;c<1<<Y[e];c++)ca[d++]=e;for(d>>=7;e<M;e++)for(aa[e]=d<<7,c=0;c<1<<Y[e]-7;c++)ca[256+d++]=e;for(c=0;c<=P;c++)k[c]=0;for(c=0;143>=c;)N[2*c+1]=8,c++,k[8]++;for(;255>=c;)N[2*c+1]=9,c++,k[9]++;for(;279>=c;)N[2*c+1]=7,c++,k[7]++;for(;287>=c;)N[2*c+1]=8,c++,k[8]++;p(N,I+1,k);for(c=0;c<M;c++)U[2*c+1]=5,U[2*c]=n(c,5);da=new f(N,J,E+1,I,P);S=new f(U,Y,0,M,P);W=new f([],O,0,L,7);ga=!0}b.l_desc=new g(b.dyn_ltree,da);b.d_desc=new g(b.dyn_dtree,S);b.bl_desc=new g(b.bl_tree,W);
+b.bi_buf=0;b.bi_valid=0;q(b)};d._tr_stored_block=B;d._tr_flush_block=function(b,c,d,e){var f,k,g=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=v(b));z(b,b.l_desc);z(b,b.d_desc);y(b,b.dyn_ltree,b.l_desc.max_code);y(b,b.dyn_dtree,b.d_desc.max_code);z(b,b.bl_desc);for(g=L-1;3<=g&&0===b.bl_tree[2*K[g]+1];g--);g=(b.opt_len+=3*(g+1)+14,g);f=b.opt_len+3+7>>>3;k=b.static_len+3+7>>>3;k<=f&&(f=k)}else f=k=d+5;if(d+4<=f&&-1!==c)B(b,c,d,e);else if(4===b.strategy||k===f)l(b,2+(e?1:0),3),x(b,N,U);else{l(b,
 4+(e?1:0),3);c=b.l_desc.max_code+1;d=b.d_desc.max_code+1;g+=1;l(b,c-257,5);l(b,d-1,5);l(b,g-4,4);for(f=0;f<g;f++)l(b,b.bl_tree[2*K[f]+1],3);A(b,b.dyn_ltree,c-1);A(b,b.dyn_dtree,d-1);x(b,b.dyn_ltree,b.dyn_dtree)}q(b);e&&t(b)};d._tr_tally=function(b,c,d){return b.pending_buf[b.d_buf+2*b.last_lit]=c>>>8&255,b.pending_buf[b.d_buf+2*b.last_lit+1]=255&c,b.pending_buf[b.l_buf+b.last_lit]=255&d,b.last_lit++,0===c?b.dyn_ltree[2*d]++:(b.matches++,c--,b.dyn_ltree[2*(Z[d]+E+1)]++,b.dyn_dtree[2*(256>c?ca[c]:ca[256+
-(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){l(b,2,3);m(b,T,M);16===b.bi_valid?(k(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,c,d){d=
+(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){l(b,2,3);m(b,T,N);16===b.bi_valid?(k(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,c,d){d=
 b("./lib/utils/common").assign;var e=b("./lib/deflate"),f=b("./lib/inflate");b=b("./lib/zlib/constants");var g={};d(g,e,f,b);c.exports=g},{"./lib/deflate":1,"./lib/inflate":2,"./lib/utils/common":3,"./lib/zlib/constants":6}]},{},[])("/")});window.urlParams=window.urlParams||{};window.isLocalStorage=window.isLocalStorage||!1;window.isSvgBrowser=window.isSvgBrowser||0>navigator.userAgent.indexOf("MSIE")||9<=document.documentMode;window.EXPORT_URL=window.EXPORT_URL||"https://exp.draw.io/ImageExport4/export";window.SAVE_URL=window.SAVE_URL||"save";window.OPEN_URL=window.OPEN_URL||"open";window.PROXY_URL=window.PROXY_URL||"proxy";window.SHAPES_PATH=window.SHAPES_PATH||"shapes";window.GRAPH_IMAGE_PATH=window.GRAPH_IMAGE_PATH||"img";
 window.ICONSEARCH_PATH=window.ICONSEARCH_PATH||0<=navigator.userAgent.indexOf("MSIE")||urlParams.dev?"iconSearch":"https://www.draw.io/iconSearch";window.TEMPLATE_PATH=window.TEMPLATE_PATH||"/templates";window.RESOURCES_PATH=window.RESOURCES_PATH||"resources";window.RESOURCE_BASE=window.RESOURCE_BASE||RESOURCES_PATH+"/dia";window.DRAWIO_LOG_URL=window.DRAWIO_LOG_URL||"";window.mxLoadResources=window.mxLoadResources||!1;
 window.mxLanguage=window.mxLanguage||function(){var a="1"==urlParams.offline?"en":urlParams.lang;if(null==a&&"undefined"!=typeof JSON&&isLocalStorage)try{var b=localStorage.getItem(".drawio-config");null!=b&&(a=JSON.parse(b).language||null)}catch(c){isLocalStorage=!1}return a}();
@@ -659,8 +659,8 @@ mxArrowConnector.prototype.resetStyles=function(){mxShape.prototype.resetStyles.
 mxArrowConnector.prototype.augmentBoundingBox=function(a){mxShape.prototype.augmentBoundingBox.apply(this,arguments);var b=this.getEdgeWidth();this.isMarkerStart()&&(b=Math.max(b,this.getStartArrowWidth()));this.isMarkerEnd()&&(b=Math.max(b,this.getEndArrowWidth()));a.grow((b/2+this.strokewidth)*this.scale)};
 mxArrowConnector.prototype.paintEdgeShape=function(a,b){var c=this.strokewidth;this.outline&&(c=Math.max(1,mxUtils.getNumber(this.style,mxConstants.STYLE_STROKEWIDTH,this.strokewidth)));for(var d=this.getStartArrowWidth()+c,e=this.getEndArrowWidth()+c,f=this.outline?this.getEdgeWidth()+c:this.getEdgeWidth(),g=this.isOpenEnded(),k=this.isMarkerStart(),l=this.isMarkerEnd(),m=g?0:this.arrowSpacing+c/2,n=this.startSize+c,c=this.endSize+c,p=this.isArrowRounded(),q=b[b.length-1],t=1;t<b.length-1&&b[t].x==
 b[0].x&&b[t].y==b[0].y;)t++;var r=b[t].x-b[0].x,t=b[t].y-b[0].y,u=Math.sqrt(r*r+t*t);if(0!=u){var x=r/u,z,y=x,A=t/u,v,B=A,u=f*A,G=-f*x,F=[];p?a.setLineJoin("round"):2<b.length&&a.setMiterLimit(1.42);a.begin();r=x;t=A;if(k&&!g)this.paintMarker(a,b[0].x,b[0].y,x,A,n,d,f,m,!0);else{z=b[0].x+u/2+m*x;v=b[0].y+G/2+m*A;var C=b[0].x-u/2+m*x,H=b[0].y-G/2+m*A;g?(a.moveTo(z,v),F.push(function(){a.lineTo(C,H)})):(a.moveTo(C,H),a.lineTo(z,v))}for(var E=v=z=0,u=0;u<b.length-2;u++)if(G=mxUtils.relativeCcw(b[u].x,
-b[u].y,b[u+1].x,b[u+1].y,b[u+2].x,b[u+2].y),z=b[u+2].x-b[u+1].x,v=b[u+2].y-b[u+1].y,E=Math.sqrt(z*z+v*v),0!=E&&(y=z/E,B=v/E,tmp=Math.max(Math.sqrt((x*y+A*B+1)/2),.04),z=x+y,v=A+B,E=Math.sqrt(z*z+v*v),0!=E)){z/=E;v/=E;var E=Math.max(tmp,Math.min(this.strokewidth/200+.04,.35)),E=0!=G&&p?Math.max(.1,E):Math.max(tmp,.06),I=b[u+1].x+v*f/2/E,N=b[u+1].y-z*f/2/E;v=b[u+1].x-v*f/2/E;z=b[u+1].y+z*f/2/E;0!=G&&p?-1==G?(G=v+B*f,E=z-y*f,a.lineTo(v+A*f,z-x*f),a.quadTo(I,N,G,E),function(b,c){F.push(function(){a.lineTo(b,
-c)})}(v,z)):(a.lineTo(I,N),function(b,c){var d=I-A*f,e=N+x*f,k=I-B*f,g=N+y*f;F.push(function(){a.quadTo(b,c,d,e)});F.push(function(){a.lineTo(k,g)})}(v,z)):(a.lineTo(I,N),function(b,c){F.push(function(){a.lineTo(b,c)})}(v,z));x=y;A=B}u=f*B;G=-f*y;if(l&&!g)this.paintMarker(a,q.x,q.y,-x,-A,c,e,f,m,!1);else{a.lineTo(q.x-m*y+u/2,q.y-m*B+G/2);var L=q.x-m*y-u/2,V=q.y-m*B-G/2;g?(a.moveTo(L,V),F.splice(0,0,function(){a.moveTo(L,V)})):a.lineTo(L,V)}for(u=F.length-1;0<=u;u--)F[u]();g?(a.end(),a.stroke()):(a.close(),
+b[u].y,b[u+1].x,b[u+1].y,b[u+2].x,b[u+2].y),z=b[u+2].x-b[u+1].x,v=b[u+2].y-b[u+1].y,E=Math.sqrt(z*z+v*v),0!=E&&(y=z/E,B=v/E,tmp=Math.max(Math.sqrt((x*y+A*B+1)/2),.04),z=x+y,v=A+B,E=Math.sqrt(z*z+v*v),0!=E)){z/=E;v/=E;var E=Math.max(tmp,Math.min(this.strokewidth/200+.04,.35)),E=0!=G&&p?Math.max(.1,E):Math.max(tmp,.06),I=b[u+1].x+v*f/2/E,M=b[u+1].y-z*f/2/E;v=b[u+1].x-v*f/2/E;z=b[u+1].y+z*f/2/E;0!=G&&p?-1==G?(G=v+B*f,E=z-y*f,a.lineTo(v+A*f,z-x*f),a.quadTo(I,M,G,E),function(b,c){F.push(function(){a.lineTo(b,
+c)})}(v,z)):(a.lineTo(I,M),function(b,c){var d=I-A*f,e=M+x*f,k=I-B*f,g=M+y*f;F.push(function(){a.quadTo(b,c,d,e)});F.push(function(){a.lineTo(k,g)})}(v,z)):(a.lineTo(I,M),function(b,c){F.push(function(){a.lineTo(b,c)})}(v,z));x=y;A=B}u=f*B;G=-f*y;if(l&&!g)this.paintMarker(a,q.x,q.y,-x,-A,c,e,f,m,!1);else{a.lineTo(q.x-m*y+u/2,q.y-m*B+G/2);var L=q.x-m*y-u/2,V=q.y-m*B-G/2;g?(a.moveTo(L,V),F.splice(0,0,function(){a.moveTo(L,V)})):a.lineTo(L,V)}for(u=F.length-1;0<=u;u--)F[u]();g?(a.end(),a.stroke()):(a.close(),
 a.fillAndStroke());a.setShadow(!1);a.setMiterLimit(4);p&&a.setLineJoin("flat");2<b.length&&(a.setMiterLimit(4),k&&!g&&(a.begin(),this.paintMarker(a,b[0].x,b[0].y,r,t,n,d,f,m,!0),a.stroke(),a.end()),l&&!g&&(a.begin(),this.paintMarker(a,q.x,q.y,-x,-A,c,e,f,m,!0),a.stroke(),a.end()))}};
 mxArrowConnector.prototype.paintMarker=function(a,b,c,d,e,f,g,k,l,m){g=k/g;var n=k*e/2;k=-k*d/2;var p=(l+f)*d;f=(l+f)*e;m?a.moveTo(b-n+p,c-k+f):a.lineTo(b-n+p,c-k+f);a.lineTo(b-n/g+p,c-k/g+f);a.lineTo(b+l*d,c+l*e);a.lineTo(b+n/g+p,c+k/g+f);a.lineTo(b+n+p,c+k+f)};mxArrowConnector.prototype.isArrowRounded=function(){return this.isRounded};mxArrowConnector.prototype.getStartArrowWidth=function(){return mxConstants.ARROW_WIDTH};mxArrowConnector.prototype.getEndArrowWidth=function(){return mxConstants.ARROW_WIDTH};
 mxArrowConnector.prototype.getEdgeWidth=function(){return mxConstants.ARROW_WIDTH/3};mxArrowConnector.prototype.isOpenEnded=function(){return!1};mxArrowConnector.prototype.isMarkerStart=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE};mxArrowConnector.prototype.isMarkerEnd=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE};
@@ -2315,12 +2315,12 @@ k=d.getAttribute("h"),g=null==g?80:parseInt(g,10),k=null==k?80:parseInt(k,10);b(
 "#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=8;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGuide.prototype.isEnabledForEvent=function(a){return!mxEvent.isAltDown(a)};var b=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(a){return mxEvent.isControlDown(a)||b.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=!0;mxConnectionHandler.prototype.cursor="crosshair";mxConnectionHandler.prototype.createEdgeState=function(a){a=this.graph.createCurrentEdgeStyle();a=this.graph.createEdge(null,null,null,null,null,a);a=new mxCellState(this.graph.view,a,this.graph.getCellStyle(a));for(var b in this.graph.currentEdgeStyle)a.style[b]=
 this.graph.currentEdgeStyle[b];return a};var c=mxConnectionHandler.prototype.createShape;mxConnectionHandler.prototype.createShape=function(){var a=c.apply(this,arguments);a.isDashed="1"==this.graph.currentEdgeStyle[mxConstants.STYLE_DASHED];return a};mxConnectionHandler.prototype.updatePreview=function(a){};var d=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var a=d.apply(this,arguments),b=a.getCell;a.getCell=mxUtils.bind(this,function(a){var c=
-b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",html:"1",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");
-null!=this.currentEdgeStyle.rounded&&(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(K){}return d}if(null!=
-a.shape)if(null!=a.shape.stencil){if(null!=a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};
-Graph.prototype.isValidRoot=function(a){for(var b=this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget",
-"1"))};Graph.prototype.createGroupCell=function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
+b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");null!=this.currentEdgeStyle.rounded&&
+(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(K){}return d}if(null!=a.shape)if(null!=a.shape.stencil){if(null!=
+a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};Graph.prototype.isValidRoot=function(a){for(var b=
+this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget","1"))};Graph.prototype.createGroupCell=
+function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
 arguments);null!=b&&(b.width+=10,b.height+=4,this.gridEnabled&&(b.width=this.snap(b.width),b.height=this.snap(b.height)));return b};Graph.prototype.turnShapes=function(a){var b=this.getModel(),c=[];b.beginUpdate();try{for(var d=0;d<a.length;d++){var e=a[d];if(b.isEdge(e)){var f=b.getTerminal(e,!0),k=b.getTerminal(e,!1);b.setTerminal(e,k,!0);b.setTerminal(e,f,!1);var g=b.getGeometry(e);if(null!=g){g=g.clone();null!=g.points&&g.points.reverse();var l=g.getTerminalPoint(!0),m=g.getTerminalPoint(!1);
 g.setTerminalPoint(l,!1);g.setTerminalPoint(m,!0);b.setGeometry(e,g);var n=this.view.getState(e),p=this.view.getState(f),q=this.view.getState(k);if(null!=n){var t=null!=p?this.getConnectionConstraint(n,p,!0):null,r=null!=q?this.getConnectionConstraint(n,q,!1):null;this.setConnectionConstraint(e,f,!0,r);this.setConnectionConstraint(e,k,!1,t)}c.push(e)}}else if(b.isVertex(e)&&(g=this.getCellGeometry(e),null!=g)){g=g.clone();g.x+=g.width/2-g.height/2;g.y+=g.height/2-g.width/2;var u=g.width;g.width=g.height;
 g.height=u;b.setGeometry(e,g);var x=this.view.getState(e);if(null!=x){var v=x.style[mxConstants.STYLE_DIRECTION]||"east";"east"==v?v="south":"south"==v?v="west":"west"==v?v="north":"north"==v&&(v="east");this.setCellStyles(mxConstants.STYLE_DIRECTION,v,[e])}c.push(e)}}}finally{b.endUpdate()}return c};Graph.prototype.processChange=function(a){mxGraph.prototype.processChange.apply(this,arguments);if(a instanceof mxValueChange&&null!=a.cell.value&&"object"==typeof a.cell.value){var b=this.model.getDescendants(a.cell);
@@ -2415,7 +2415,7 @@ this.editingHandler);var c=this.graph.getLinkForCell(this.state.cell);this.updat
 "",this.updateLinkHint(b),this.graph.container.appendChild(this.linkHint)),b=this.graph.createLinkForHint(b,b),this.linkHint.innerHTML="",this.linkHint.appendChild(b),this.graph.isEnabled()&&"function"===typeof this.graph.editLink&&(b=document.createElement("img"),b.setAttribute("src",IMAGE_PATH+"/edit.gif"),b.setAttribute("title",mxResources.get("editLink")),b.setAttribute("width","11"),b.setAttribute("height","11"),b.style.marginLeft="10px",b.style.marginBottom="-1px",b.style.cursor="pointer",this.linkHint.appendChild(b),
 mxEvent.addListener(b,"click",mxUtils.bind(this,function(a){this.graph.setSelectionCell(this.state.cell);this.graph.editLink();mxEvent.consume(a)}))))};mxEdgeHandler.prototype.updateLinkHint=mxVertexHandler.prototype.updateLinkHint;var E=mxEdgeHandler.prototype.init;mxEdgeHandler.prototype.init=function(){E.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.state.view.graph.connectionHandler.isEnabled()});var a=mxUtils.bind(this,function(){null!=this.linkHint&&
 (this.linkHint.style.display=1==this.graph.getSelectionCount()?"":"none");null!=this.labelShape&&(this.labelShape.node.style.display=this.graph.isEnabled()&&this.graph.getSelectionCount()<this.graph.graphHandler.maxCells?"":"none")});this.selectionHandler=mxUtils.bind(this,function(b,c){a()});this.graph.getSelectionModel().addListener(mxEvent.CHANGE,this.selectionHandler);this.changeHandler=mxUtils.bind(this,function(b,c){this.updateLinkHint(this.graph.getLinkForCell(this.state.cell));a();this.redrawHandles()});
-this.graph.getModel().addListener(mxEvent.CHANGE,this.changeHandler);var b=this.graph.getLinkForCell(this.state.cell);null!=b&&(this.updateLinkHint(b),this.redrawHandles())};var I=mxConnectionHandler.prototype.init;mxConnectionHandler.prototype.init=function(){I.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.graph.connectionHandler.isEnabled()})};var N=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){N.apply(this);
+this.graph.getModel().addListener(mxEvent.CHANGE,this.changeHandler);var b=this.graph.getLinkForCell(this.state.cell);null!=b&&(this.updateLinkHint(b),this.redrawHandles())};var I=mxConnectionHandler.prototype.init;mxConnectionHandler.prototype.init=function(){I.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.graph.connectionHandler.isEnabled()})};var M=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){M.apply(this);
 if(null!=this.state&&null!=this.linkHint){var a=new mxPoint(this.state.getCenterX(),this.state.getCenterY()),b=new mxRectangle(this.state.x,this.state.y-22,this.state.width+24,this.state.height+22),a=mxUtils.getBoundingBox(b,this.state.style[mxConstants.STYLE_ROTATION]||"0",a),b=null!=a?mxUtils.getBoundingBox(this.state,this.state.style[mxConstants.STYLE_ROTATION]||"0"):this.state;null==a&&(a=this.state);this.linkHint.style.left=Math.round(b.x+(b.width-this.linkHint.clientWidth)/2)+"px";this.linkHint.style.top=
 Math.round(a.y+a.height+this.verticalOffset/2+6+this.state.view.graph.tolerance)+"px"}};var L=mxVertexHandler.prototype.reset;mxVertexHandler.prototype.reset=function(){L.apply(this,arguments);null!=this.rotationShape&&null!=this.rotationShape.node&&(this.rotationShape.node.style.display=1==this.graph.getSelectionCount()?"":"none")};var V=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=function(){V.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),
 this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var P=mxEdgeHandler.prototype.redrawHandles;mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(P.apply(this),null!=this.state&&
@@ -2423,8 +2423,8 @@ null!=this.linkHint)){var a=this.state;null!=this.state.text&&null!=this.state.t
 var T=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){T.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null)}}();(function(){function a(){mxCylinder.call(this)}function b(){mxActor.call(this)}function c(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function e(){mxCylinder.call(this)}function f(){mxActor.call(this)}function g(){mxCylinder.call(this)}function k(){mxActor.call(this)}function l(){mxActor.call(this)}function m(){mxActor.call(this)}function n(){mxActor.call(this)}function p(){mxActor.call(this)}function q(){mxActor.call(this)}function t(){mxActor.call(this)}function r(a,b){this.canvas=
 a;this.canvas.setLineJoin("round");this.canvas.setLineCap("round");this.defaultVariation=b;this.originalLineTo=this.canvas.lineTo;this.canvas.lineTo=mxUtils.bind(this,r.prototype.lineTo);this.originalMoveTo=this.canvas.moveTo;this.canvas.moveTo=mxUtils.bind(this,r.prototype.moveTo);this.originalClose=this.canvas.close;this.canvas.close=mxUtils.bind(this,r.prototype.close);this.originalQuadTo=this.canvas.quadTo;this.canvas.quadTo=mxUtils.bind(this,r.prototype.quadTo);this.originalCurveTo=this.canvas.curveTo;
 this.canvas.curveTo=mxUtils.bind(this,r.prototype.curveTo);this.originalArcTo=this.canvas.arcTo;this.canvas.arcTo=mxUtils.bind(this,r.prototype.arcTo)}function u(){mxRectangleShape.call(this)}function x(){mxActor.call(this)}function z(){mxActor.call(this)}function y(){mxRectangleShape.call(this)}function A(){mxRectangleShape.call(this)}function v(){mxCylinder.call(this)}function B(){mxShape.call(this)}function G(){mxShape.call(this)}function F(){mxEllipse.call(this)}function C(){mxShape.call(this)}
-function H(){mxShape.call(this)}function E(){mxRectangleShape.call(this)}function I(){mxShape.call(this)}function N(){mxShape.call(this)}function L(){mxShape.call(this)}function V(){mxCylinder.call(this)}function P(){mxDoubleEllipse.call(this)}function ba(){mxDoubleEllipse.call(this)}function T(){mxArrowConnector.call(this);this.spacing=0}function D(){mxArrowConnector.call(this);this.spacing=0}function X(){mxActor.call(this)}function Q(){mxRectangleShape.call(this)}function J(){mxActor.call(this)}
-function Y(){mxActor.call(this)}function O(){mxActor.call(this)}function K(){mxActor.call(this)}function M(){mxActor.call(this)}function U(){mxActor.call(this)}function ca(){mxActor.call(this)}function Z(){mxActor.call(this)}function R(){mxActor.call(this)}function aa(){mxEllipse.call(this)}function da(){mxEllipse.call(this)}function S(){mxEllipse.call(this)}function W(){mxRhombus.call(this)}function ga(){mxEllipse.call(this)}function ea(){mxEllipse.call(this)}function ha(){mxEllipse.call(this)}function la(){mxEllipse.call(this)}
+function H(){mxShape.call(this)}function E(){mxRectangleShape.call(this)}function I(){mxShape.call(this)}function M(){mxShape.call(this)}function L(){mxShape.call(this)}function V(){mxCylinder.call(this)}function P(){mxDoubleEllipse.call(this)}function ba(){mxDoubleEllipse.call(this)}function T(){mxArrowConnector.call(this);this.spacing=0}function D(){mxArrowConnector.call(this);this.spacing=0}function X(){mxActor.call(this)}function Q(){mxRectangleShape.call(this)}function J(){mxActor.call(this)}
+function Y(){mxActor.call(this)}function O(){mxActor.call(this)}function K(){mxActor.call(this)}function N(){mxActor.call(this)}function U(){mxActor.call(this)}function ca(){mxActor.call(this)}function Z(){mxActor.call(this)}function R(){mxActor.call(this)}function aa(){mxEllipse.call(this)}function da(){mxEllipse.call(this)}function S(){mxEllipse.call(this)}function W(){mxRhombus.call(this)}function ga(){mxEllipse.call(this)}function ea(){mxEllipse.call(this)}function ha(){mxEllipse.call(this)}function la(){mxEllipse.call(this)}
 function ma(){mxActor.call(this)}function na(){mxActor.call(this)}function oa(){mxActor.call(this)}function xa(a,b,c,d,e,f,k,g,l,m){k+=l;var n=d.clone();d.x-=e*(2*k+l);d.y-=f*(2*k+l);e*=k+l;f*=k+l;return function(){a.ellipse(n.x-e-k,n.y-f-k,2*k,2*k);m?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,mxCylinder);a.prototype.size=20;a.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(b,e),a.lineTo(b,b),
 a.lineTo(0,0),a.moveTo(b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(b,e),a.lineTo(0,e-b),a.lineTo(0,0),a.close());a.end()};mxCellRenderer.prototype.defaultShapes.cube=a;var ua=Math.tan(mxUtils.toRadians(30)),ja=(.5-ua)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/ua);a.translate((d-b)/2,(e-b)/2+b/4);a.moveTo(0,.25*b);a.lineTo(.5*b,b*ja);a.lineTo(b,.25*b);a.lineTo(.5*b,(.5-ja)*b);a.lineTo(0,.25*
 b);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.isoRectangle=b;mxUtils.extend(c,mxCylinder);c.prototype.size=20;c.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(d,e/(.5+ua));f?(a.moveTo(0,.25*b),a.lineTo(.5*b,(.5-ja)*b),a.lineTo(b,.25*b),a.moveTo(.5*b,(.5-ja)*b),a.lineTo(.5*b,(1-ja)*b)):(a.translate((d-b)/2,(e-b)/2),a.moveTo(0,.25*b),a.lineTo(.5*b,b*ja),a.lineTo(b,.25*b),a.lineTo(b,.75*b),a.lineTo(.5*b,(1-ja)*b),a.lineTo(0,.75*b),a.close());a.end()};mxCellRenderer.prototype.defaultShapes.isoCube=
@@ -2464,7 +2464,7 @@ a,b,c,d,Math.min(e,f))};mxCellRenderer.prototype.defaultShapes.umlLifeline=E;mxU
 e){var f=this.corner,k=Math.min(d,Math.max(f,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),g=Math.min(e,Math.max(1.5*f,parseFloat(mxUtils.getValue(this.style,"height",this.height))));a.begin();a.moveTo(b,c);a.lineTo(b+k,c);a.lineTo(b+k,c+Math.max(0,g-1.5*f));a.lineTo(b+Math.max(0,k-f),c+g);a.lineTo(b,c+g);a.close();a.fillAndStroke();a.begin();a.moveTo(b+k,c);a.lineTo(b+d,c);a.lineTo(b+d,c+e);a.lineTo(b,c+e);a.lineTo(b,c+g);a.stroke()};mxCellRenderer.prototype.defaultShapes.umlFrame=
 I;mxPerimeter.LifelinePerimeter=function(a,b,c,d){d=E.prototype.size;null!=b&&(d=mxUtils.getValue(b.style,"size",d)*b.view.scale);b=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;c.x<a.getCenterX()&&(b=-1*(b+1));return new mxPoint(a.getCenterX()+b,Math.min(a.y+a.height,Math.max(a.y+d,c.y)))};mxStyleRegistry.putValue("lifelinePerimeter",mxPerimeter.LifelinePerimeter);mxPerimeter.OrthogonalPerimeter=function(a,b,c,d){d=!0;return mxPerimeter.RectanglePerimeter.apply(this,arguments)};
 mxStyleRegistry.putValue("orthogonalPerimeter",mxPerimeter.OrthogonalPerimeter);mxPerimeter.BackbonePerimeter=function(a,b,c,d){d=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;null!=b.style.backboneSize&&(d+=parseFloat(b.style.backboneSize)*b.view.scale/2-1);if("south"==b.style[mxConstants.STYLE_DIRECTION]||"north"==b.style[mxConstants.STYLE_DIRECTION])return c.x<a.getCenterX()&&(d=-1*(d+1)),new mxPoint(a.getCenterX()+d,Math.min(a.y+a.height,Math.max(a.y,c.y)));c.y<a.getCenterY()&&
-(d=-1*(d+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,c.x)),a.getCenterY()+d)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxUtils.extend(N,mxShape);N.prototype.size=10;N.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.lollipop=N;mxUtils.extend(L,
+(d=-1*(d+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,c.x)),a.getCenterY()+d)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxUtils.extend(M,mxShape);M.prototype.size=10;M.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.lollipop=M;mxUtils.extend(L,
 mxShape);L.prototype.size=10;L.prototype.inset=2;L.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size)),k=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,c);a.begin();a.moveTo(d/2,f+k);a.lineTo(d/2,e);a.end();a.stroke();a.begin();a.moveTo((d-f)/2-k,f/2);a.quadTo((d-f)/2-k,f+k,d/2,f+k);a.quadTo((d+f)/2+k,f+k,(d+f)/2+k,f/2);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.requires=L;mxUtils.extend(V,
 mxCylinder);V.prototype.jettyWidth=32;V.prototype.jettyHeight=12;V.prototype.redrawPath=function(a,b,c,d,e,f){var k=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));b=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));c=k/2;var k=c+k/2,g=.3*e-b/2,l=.7*e-b/2;f?(a.moveTo(c,g),a.lineTo(k,g),a.lineTo(k,g+b),a.lineTo(c,g+b),a.moveTo(c,l),a.lineTo(k,l),a.lineTo(k,l+b),a.lineTo(c,l+b)):(a.moveTo(c,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(c,e),a.lineTo(c,l+b),a.lineTo(0,
 l+b),a.lineTo(0,l),a.lineTo(c,l),a.lineTo(c,g+b),a.lineTo(0,g+b),a.lineTo(0,g),a.lineTo(c,g),a.close());a.end()};mxCellRenderer.prototype.defaultShapes.component=V;mxUtils.extend(P,mxDoubleEllipse);P.prototype.outerStroke=!0;P.prototype.paintVertexShape=function(a,b,c,d,e){var f=Math.min(4,Math.min(d/5,e/5));0<d&&0<e&&(a.ellipse(b+f,c+f,d-2*f,e-2*f),a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(b,c,d,e),a.stroke())};mxCellRenderer.prototype.defaultShapes.endState=P;mxUtils.extend(ba,
@@ -2477,7 +2477,7 @@ c+e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.internalStorage=
 var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint((d+b)/2,c),new mxPoint((d+b)/2,e),new mxPoint((d-b)/2,e),new mxPoint((d-b)/2,c),new mxPoint(0,c)],this.isRounded,f,!0);a.end()};mxCellRenderer.prototype.defaultShapes.tee=Y;mxUtils.extend(O,mxActor);O.prototype.arrowWidth=.3;O.prototype.arrowSize=.2;O.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,
 "arrowWidth",this.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));c=(e-f)/2;var f=c+f,k=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(0,f)],this.isRounded,k,!0);a.end()};mxCellRenderer.prototype.defaultShapes.singleArrow=O;mxUtils.extend(K,mxActor);K.prototype.redrawPath=
 function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",O.prototype.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",O.prototype.arrowSize))));c=(e-f)/2;var f=c+f,k=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e/2),new mxPoint(b,0),new mxPoint(b,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),
-new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,k,!0);a.end()};mxCellRenderer.prototype.defaultShapes.doubleArrow=K;mxUtils.extend(M,mxActor);M.prototype.size=.1;M.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.dataStorage=M;mxUtils.extend(U,mxActor);U.prototype.redrawPath=
+new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,k,!0);a.end()};mxCellRenderer.prototype.defaultShapes.doubleArrow=K;mxUtils.extend(N,mxActor);N.prototype.size=.1;N.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.dataStorage=N;mxUtils.extend(U,mxActor);U.prototype.redrawPath=
 function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.or=U;mxUtils.extend(ca,mxActor);ca.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.quadTo(d/2,e/2,0,0);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.xor=ca;mxUtils.extend(Z,mxActor);Z.prototype.size=20;Z.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d/2,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",
 this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.8*b),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,.8*b)],this.isRounded,c,!0);a.end()};mxCellRenderer.prototype.defaultShapes.loopLimit=Z;mxUtils.extend(R,mxActor);R.prototype.size=.375;R.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,
 mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-b),new mxPoint(d/2,e),new mxPoint(0,e-b)],this.isRounded,c,!0);a.end()};mxCellRenderer.prototype.defaultShapes.offPageConnector=R;mxUtils.extend(aa,mxEllipse);aa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/2,c+e);a.lineTo(b+d,c+e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.tapeData=
@@ -2513,7 +2513,7 @@ parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFA
 !1)];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},process:function(a){var b=[fa(a,["size"],function(a){var b=Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.state.style,"size",u.prototype.size))));return new mxPoint(a.x+a.width*b,a.y+a.height/4)},function(a,b){this.state.style.size=Math.max(0,Math.min(.5,(b.x-a.x)/a.width))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},cross:function(a){return[fa(a,["size"],function(a){var b=
 Math.min(a.width,a.height),b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"size",na.prototype.size)))*b/2;return new mxPoint(a.getCenterX()-b,a.getCenterY()-b)},function(a,b){var c=Math.min(a.width,a.height);this.state.style.size=Math.max(0,Math.min(1,Math.min(Math.max(0,a.getCenterY()-b.y)/c*2,Math.max(0,a.getCenterX()-b.x)/c*2)))})]},note:function(a){return[fa(a,["size"],function(a){var b=Math.max(0,Math.min(a.width,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",
 e.prototype.size)))));return new mxPoint(a.x+a.width-b,a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(a.width,a.x+a.width-b.x),Math.min(a.height,b.y-a.y))))})]},manualInput:function(a){var b=[fa(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",X.prototype.size)));return new mxPoint(a.x+a.width/4,a.y+3*b/4)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,4*(b.y-a.y)/3)))})];mxUtils.getValue(a.style,
-mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},dataStorage:function(a){return[fa(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",M.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-b.x)/a.width))})]},internalStorage:function(a){var b=[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",Q.prototype.dx))),
+mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},dataStorage:function(a){return[fa(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",N.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-b.x)/a.width))})]},internalStorage:function(a){var b=[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",Q.prototype.dx))),
 c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",Q.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},corner:function(a){return[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",J.prototype.dx))),
 c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",J.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},tee:function(a){return[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",Y.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",Y.prototype.dy)));
 return new mxPoint(a.x+(a.width+b)/2,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,b.x-a.x-a.width/2)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},singleArrow:ka(1),doubleArrow:ka(.5),folder:function(a){return[fa(a,["tabWidth","tabHeight"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"tabWidth",g.prototype.tabWidth))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"tabHeight",
@@ -2527,7 +2527,7 @@ k&&null!=g){a=function(a,b,c){a-=t.x;var d=b-t.y;b=(p*a-n*d)/(l*p-m*n);a=(m*a-l*
 function(a,b){if(b==mxEdgeStyle.IsometricConnector){var c=new mxElbowEdgeHandler(a);c.snapToTerminals=!1;return c}return Fa.apply(this,arguments)};b.prototype.constraints=[];c.prototype.constraints=[];mxRectangleShape.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),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxEllipse.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!0),new mxConnectionConstraint(new mxPoint(1,0),!0),new mxConnectionConstraint(new mxPoint(0,1),!0),new mxConnectionConstraint(new mxPoint(1,
 1),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,.5))];mxLabel.prototype.constraints=mxRectangleShape.prototype.constraints;mxImageShape.prototype.constraints=mxRectangleShape.prototype.constraints;mxSwimlane.prototype.constraints=mxRectangleShape.prototype.constraints;y.prototype.constraints=mxRectangleShape.prototype.constraints;e.prototype.constraints=
-mxRectangleShape.prototype.constraints;k.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;Q.prototype.constraints=mxRectangleShape.prototype.constraints;M.prototype.constraints=mxRectangleShape.prototype.constraints;aa.prototype.constraints=mxEllipse.prototype.constraints;da.prototype.constraints=mxEllipse.prototype.constraints;S.prototype.constraints=mxEllipse.prototype.constraints;
+mxRectangleShape.prototype.constraints;k.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;Q.prototype.constraints=mxRectangleShape.prototype.constraints;N.prototype.constraints=mxRectangleShape.prototype.constraints;aa.prototype.constraints=mxEllipse.prototype.constraints;da.prototype.constraints=mxEllipse.prototype.constraints;S.prototype.constraints=mxEllipse.prototype.constraints;
 la.prototype.constraints=mxEllipse.prototype.constraints;X.prototype.constraints=mxRectangleShape.prototype.constraints;ma.prototype.constraints=mxRectangleShape.prototype.constraints;oa.prototype.constraints=mxRectangleShape.prototype.constraints;Z.prototype.constraints=mxRectangleShape.prototype.constraints;R.prototype.constraints=mxRectangleShape.prototype.constraints;mxCylinder.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.15,.05),!1),new mxConnectionConstraint(new mxPoint(.5,
 0),!0),new mxConnectionConstraint(new mxPoint(.85,.05),!1),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.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)];B.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)];V.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),
@@ -2536,7 +2536,7 @@ new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new
 f.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)];l.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)];x.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(.1,.25),!1),new mxConnectionConstraint(new mxPoint(.2,.5),!1),new mxConnectionConstraint(new mxPoint(.1,.75),!1),new mxConnectionConstraint(new mxPoint(.9,.25),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.9,.75),!1)];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)];N.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,
+.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];M.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(.125,.25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(.125,.75),!1),new mxConnectionConstraint(new mxPoint(.875,
 .25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(.875,.75),!1),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)];n.prototype.constraints=mxRectangleShape.prototype.constraints;p.prototype.constraints=
@@ -2611,31 +2611,32 @@ IMAGE_PATH+"/delete.png";Editor.plusImage=mxClient.IS_SVG?"data:image/png;base64
 IMAGE_PATH+"/plus.png";Editor.spinImage=mxClient.IS_SVG?"data:image/gif;base64,R0lGODlhDAAMAPUxAEVriVp7lmCAmmGBm2OCnGmHn3OPpneSqYKbr4OcsIScsI2kto6kt46lt5KnuZmtvpquvpuvv56ywaCzwqK1xKu7yay9yq+/zLHAzbfF0bjG0bzJ1LzK1MDN18jT28nT3M3X3tHa4dTc49Xd5Njf5dng5t3k6d/l6uDm6uru8e7x8/Dz9fT29/b4+Pj5+fj5+vr6+v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkKADEAIf8LTkVUU0NBUEUyLjADAQAAACwAAAAADAAMAAAGR8CYcEgsOgYAIax4CCQuQldrCBEsiK8VS2hoFGOrlJDA+cZQwkLnqyoJFZKviSS0ICrE0ec0jDAwIiUeGyBFGhMPFBkhZo1BACH5BAkKAC4ALAAAAAAMAAwAhVB0kFR3k1V4k2CAmmWEnW6Lo3KOpXeSqH2XrIOcsISdsImhtIqhtJCmuJGnuZuwv52wwJ+ywZ+ywqm6yLHBzbLCzrXEz7fF0LnH0rrI0r7L1b/M1sXR2cfT28rV3czW3s/Z4Nfe5Nvi6ODm6uLn6+Ln7OLo7OXq7efs7+zw8u/y9PDy9PX3+Pr7+////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAZDQJdwSCxGDAIAoVFkFBwYSyIwGE4OkCJxIdG6WkJEx8sSKj7elfBB0a5SQg1EQ0SVVMPKhDM6iUIkRR4ZFxsgJl6JQQAh+QQJCgAxACwAAAAADAAMAIVGa4lcfZdjgpxkg51nhp5ui6N3kqh5lKqFnbGHn7KIoLOQp7iRp7mSqLmTqbqarr6br7+fssGitcOitcSuvsuuv8uwwMyzw861xNC5x9K6x9K/zNbDztjE0NnG0drJ1NzQ2eDS2+LT2+LV3ePZ4Oba4ebb4ufc4+jm6+7t8PLt8PPt8fPx8/Xx9PX09vf19/j3+Pn///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CYcEgsUhQFggFSjCQmnE1jcBhqGBXiIuAQSi7FGEIgfIzCFoCXFCZiPO0hKBMiwl7ET6eUYqlWLkUnISImKC1xbUEAIfkECQoAMgAsAAAAAAwADACFTnKPT3KPVHaTYoKcb4yjcY6leZSpf5mtgZuvh5+yiqG0i6K1jqW3kae5nrHBnrLBn7LCoLPCobTDqbrIqrvIs8LOtMPPtcPPtcTPuMbRucfSvcrUvsvVwMzWxdHaydTcytXdzNbezdff0drh2ODl2+Ln3eTp4Obq4ujs5Ont5uvu6O3w6u7w6u7x7/L09vj5+vr7+vv7////AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABkdAmXBILHIcicOCUqxELKKPxKAYgiYd4oMAEWo8RVmjIMScwhmBcJMKXwLCECmMGAhPI1QRwBiaSixCMDFhLSorLi8wYYxCQQAh+QQJCgAxACwAAAAADAAMAIVZepVggJphgZtnhp5vjKN2kah3kqmBmq+KobSLorWNpLaRp7mWq7ybr7+gs8KitcSktsWnuManucexwM2ywc63xtG6yNO9ytS+ytW/zNbDz9jH0tvL1d3N197S2+LU3OPU3ePV3eTX3+Xa4efb4ufd5Onl6u7r7vHs7/Lt8PLw8/Xy9Pby9fb09ff2+Pn3+Pn6+vr///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGSMCYcEgseiwSR+RS7GA4JFGF8RiWNiEiJTERgkjFGAQh/KTCGoJwpApnBkITKrwoCFWnFlEhaAxXLC9CBwAGRS4wQgELYY1CQQAh+QQJCgAzACwAAAAADAAMAIVMcI5SdZFhgZtti6JwjaR4k6mAma6Cm6+KobSLorWLo7WNo7aPpredsMCescGitMOitcSmuMaqu8ixwc2zws63xdC4xtG5x9K9ytXAzdfCztjF0NnF0drK1d3M1t7P2N/P2eDT2+LX3+Xe5Onh5+vi5+vj6Ozk6e3n7O/o7O/q7vHs7/Lt8PPu8fPx8/X3+Pn6+vv7+/v8/Pz///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRcCZcEgsmkIbTOZTLIlGqZNnchm2SCgiJ6IRqljFmQUiXIVnoITQde4chC9Y+LEQxmTFRkFSNFAqDAMIRQoCAAEEDmeLQQAh+QQJCgAwACwAAAAADAAMAIVXeZRefplff5lhgZtph59yjqV2kaeAmq6FnbGFnrGLorWNpLaQp7mRqLmYrb2essGgs8Klt8apusitvcquv8u2xNC7yNO8ydS8ytTAzdfBzdfM1t7N197Q2eDU3OPX3+XZ4ObZ4ebc4+jf5erg5erg5uvp7fDu8fPv8vTz9fb09vf19/j3+Pn4+fn5+vr6+/v///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRUCYcEgspkwjEKhUVJ1QsBNp0xm2VixiSOMRvlxFGAcTJook5eEHIhQcwpWIkAFQECkNy9AQWFwyEAkPRQ4FAwQIE2llQQAh+QQJCgAvACwAAAAADAAMAIVNcY5SdZFigptph6BvjKN0kKd8lquAmq+EnbGGn7KHn7ONpLaOpbearr+csMCdscCescGhtMOnuMauvsuzws60w862xdC9ytW/y9a/zNbCztjG0drH0tvK1N3M1t7N19/U3ePb4uff5urj6Ozk6e3l6u7m6u7o7PDq7vDt8PPv8vTw8vTw8/X19vf6+vv///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CXcEgsvlytVUplJLJIpSEDUESFTELBwSgCCQEV42kjDFiMo4uQsDB2MkLHoEHUTD7DRAHC8VAiZ0QSCgYIDxhNiUEAOw==":
 IMAGE_PATH+"/spin.gif";Editor.tweetImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAARlJREFUeNpi/P//PwM1ABMDlQDVDGKAeo0biMXwKOMD4ilA/AiInwDxfCBWBeIgINYDmwE1yB2Ir0Alsbl6JchONPwNiC8CsTPIDJjXuIBYG4gPAnE8EDMjGaQCxGFYLOAEYlYg/o3sNSkgfo1k2ykgLgRiIyAOwOIaGE6CmwE1SA6IZ0BNR1f8GY9BXugG2UMN+YtHEzr+Aw0OFINYgHgdCYaA8HUgZkM3CASEoYb9ItKgapQkhGQQKC0dJdKQx1CLsRoEArpAvAuI3+Ix5B8Q+2AkaiyZVgGId+MwBBQhKVhzB9QgKyDuAOJ90BSLzZBzQOyCK5uxQNnXoGlJHogfIOU7UCI9C8SbgHgjEP/ElRkZB115BBBgAPbkvQ/azcC0AAAAAElFTkSuQmCC":
 IMAGE_PATH+"/tweet.png";Editor.facebookImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAARVBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADc6ur3AAAAFnRSTlMAYmRg2KVCC/oPq0uAcVQtHtvZuoYh/a7JUAAAAGJJREFUGNOlzkkOgCAMQNEvagvigBP3P6pRNoCJG/+myVu0RdsqxcQqQ/NFVkKQgqwDzoJ2WKajoB66atcAa0GjX0D8lJHwNGfknYJzY77LDtDZ+L74j0z26pZI2yYlMN9TL17xEd+fl1D+AAAAAElFTkSuQmCC":IMAGE_PATH+"/facebook.png";Editor.blankImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACklEQVR4nGMAAQAABQABDQottAAAAABJRU5ErkJggg==";
-Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
-Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;var b=Graph.prototype.loadStylesheet;Graph.prototype.loadStylesheet=function(){b.apply(this,arguments);
-null!=a.defaultVertexStyle&&this.getStylesheet().putDefaultVertexStyle(a.defaultVertexStyle);null!=a.defaultEdgeStyle&&this.getStylesheet().putDefaultEdgeStyle(a.defaultEdgeStyle)}}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):
-null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,
-this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);
-mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};};var b=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var c=b.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&c.setAttribute("style",this.graph.currentStyle);
-null!=this.graph.backgroundImage&&c.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));c.setAttribute("math",this.graph.mathEnabled?"1":"0");c.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return c};Editor.prototype.isDataSvg=function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),
-null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),
-a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};
-null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var c=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=
-null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;c.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";
-Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX","input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});
-MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,
-b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;
-var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var e=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,b){e.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()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):
-this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),
-a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",
-stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=
-function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom=
-"2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=
-mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,
-"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin="0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+
-" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";
-e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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=);";
+Editor.defaultCustomLibraries=[];Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
+Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;if(null!=a.css){var b=document.createElement("style");b.setAttribute("type","text/css");b.appendChild(document.createTextNode(a.css));
+var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}null!=a.defaultLibraries&&(Sidebar.prototype.defaultEntries=a.defaultLibraries);null!=a.defaultCustomLibraries&&(Editor.defaultCustomLibraries=a.defaultCustomLibraries);null!=a.defaultVertexStyle&&(Graph.prototype.defaultVertexStyle=a.defaultVertexStyle);null!=a.defaultEdgeStyle&&(Graph.prototype.defaultEdgeStyle=a.defaultEdgeStyle)}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):
+null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||
+"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=
+c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};
+};var b=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var c=b.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&c.setAttribute("style",this.graph.currentStyle);null!=this.graph.backgroundImage&&c.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));c.setAttribute("math",this.graph.mathEnabled?"1":"0");c.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return c};Editor.prototype.isDataSvg=
+function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),
+d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=
+c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<
+c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var c=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;c.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=
+function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX",
+"input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?
+Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};
+Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,
+'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var e=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,b){e.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()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&
+(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",
+stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,
+{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;
+StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));
+b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,
+f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin=
+"0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=
+0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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(k,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme-1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));var g=document.createElement("div");g.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(k),a.appendChild(g));mxEvent.addListener(g,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme+1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));c(k);c(g);b(this.defaultColorSchemes[this.editorUi.currentScheme]);return a};StyleFormatPanel.prototype.addEditOps=function(a){var b=this.format.getSelectionState(),c=null;1==this.editorUi.editor.graph.getSelectionCount()&&
 (c=mxUtils.button(mxResources.get("editStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("editStyle").funct()})),c.setAttribute("title",mxResources.get("editStyle")+" ("+this.editorUi.actions.get("editStyle").shortcut+")"),c.style.width="202px",c.style.marginBottom="2px",a.appendChild(c));var d=this.editorUi.editor.graph,e=d.view.getState(d.getSelectionCell());1==d.getSelectionCount()&&null!=e&&null!=e.shape&&null!=e.shape.stencil?(b=mxUtils.button(mxResources.get("editShape"),mxUtils.bind(this,
@@ -2656,7 +2657,7 @@ mxStencilRegistry.libraries.er=[SHAPES_PATH+"/er/mxER.js"];mxStencilRegistry.lib
 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.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 b=null;null!=a&&0<a.length&&("ER"==a.substring(0,2)?b="mxgraph.er":"sysML"==a.substring(0,5)&&(b="mxgraph.sysml"));return b};
 var t=mxMarker.createMarker;mxMarker.createMarker=function(a,b,c,d,e,f,k,g,l,m){if(null!=c&&null==mxMarker.markers[c]){var n=this.getPackageForType(c);null!=n&&mxStencilRegistry.getStencil(n)}return t.apply(this,arguments)};PrintDialog.prototype.create=function(a,b){function c(){t.value=Math.max(1,Math.min(g,Math.max(parseInt(t.value),parseInt(q.value))));q.value=Math.max(1,Math.min(g,Math.min(parseInt(t.value),parseInt(q.value))))}function d(b){function c(a,b,c){var e=a.getGraphBounds(),f=0,k=0,
-g=ca.get(),l=1/a.pageScale,m=P.checked;if(m)var l=parseInt(M.value),n=parseInt(U.value),l=Math.min(g.height*n/(e.height/a.view.scale),g.width*l/(e.width/a.view.scale));else l=parseInt(V.value)/(100*a.pageScale),isNaN(l)&&(d=1/a.pageScale,V.value="100 %");g=mxRectangle.fromRectangle(g);g.width=Math.ceil(g.width*d);g.height=Math.ceil(g.height*d);l*=d;!m&&a.pageVisible?(e=a.getPageLayout(),f-=e.x*g.width,k-=e.y*g.height):m=!0;if(null==b){b=PrintDialog.createPrintPreview(a,l,g,0,f,k,m);b.pageSelector=
+g=ca.get(),l=1/a.pageScale,m=P.checked;if(m)var l=parseInt(N.value),n=parseInt(U.value),l=Math.min(g.height*n/(e.height/a.view.scale),g.width*l/(e.width/a.view.scale));else l=parseInt(V.value)/(100*a.pageScale),isNaN(l)&&(d=1/a.pageScale,V.value="100 %");g=mxRectangle.fromRectangle(g);g.width=Math.ceil(g.width*d);g.height=Math.ceil(g.height*d);l*=d;!m&&a.pageVisible?(e=a.getPageLayout(),f-=e.x*g.width,k-=e.y*g.height):m=!0;if(null==b){b=PrintDialog.createPrintPreview(a,l,g,0,f,k,m);b.pageSelector=
 !1;b.mathEnabled=!1;if("undefined"!==typeof MathJax){var p=b.renderPage;b.renderPage=function(a,b,c,d,e,f){var k=p.apply(this,arguments);this.graph.mathEnabled?this.mathEnabled=!0:k.className="geDisableMathJax";return k}}b.open(null,null,c,!0)}else{g=a.background;if(null==g||""==g||g==mxConstants.NONE)g="#ffffff";b.backgroundColor=g;b.autoOrigin=m;b.appendGraph(a,l,f,k,c,!0)}return b}var d=parseInt(Z.value)/100;isNaN(d)&&(d=1,Z.value="100 %");var d=.75*d,f=q.value,k=t.value,g=!n.checked,m=null;g&&
 (g=f==l&&k==l);if(!g&&null!=a.pages&&a.pages.length){var p=0,g=a.pages.length-1;n.checked||(p=parseInt(f)-1,g=parseInt(k)-1);for(var r=p;r<=g;r++){var u=a.pages[r],f=u==a.currentPage?e:null;if(null==f){var f=a.createTemporaryGraph(e.getStylesheet()),k=!0,p=!1,x=null,v=null;null==u.viewState&&null==u.mapping&&null==u.root&&a.updatePageRoot(u);null!=u.viewState?(k=u.viewState.pageVisible,p=u.viewState.mathEnabled,x=u.viewState.background,v=u.viewState.backgroundImage):null!=u.mapping&&null!=u.mapping.diagramMap&&
 (p="0"!=u.mapping.diagramMap.get("mathEnabled"),x=u.mapping.diagramMap.get("background"),v=u.mapping.diagramMap.get("backgroundImage"),v=null!=v&&0<v.length?JSON.parse(v):null);f.background=x;f.backgroundImage=null!=v?new mxImage(v.src,v.width,v.height):null;f.pageVisible=k;f.mathEnabled=p;var y=f.getGlobalVariable;f.getGlobalVariable=function(a){return"page"==a?u.getName():"pagenumber"==a?r+1:y.apply(this,arguments)};document.body.appendChild(f.container);a.updatePageRoot(u);f.model.setRoot(u.root)}m=
@@ -2667,21 +2668,21 @@ n.setAttribute("name","pages-printdialog");m.appendChild(n);k=document.createEle
 "number");q.setAttribute("min","1");q.style.width="50px";m.appendChild(q);k=document.createElement("span");mxUtils.write(k,mxResources.get("to"));m.appendChild(k);var t=q.cloneNode(!0);m.appendChild(t);mxEvent.addListener(q,"focus",function(){p.checked=!0});mxEvent.addListener(t,"focus",function(){p.checked=!0});mxEvent.addListener(q,"change",c);mxEvent.addListener(t,"change",c);if(null!=a.pages&&(g=a.pages.length,null!=a.currentPage))for(k=0;k<a.pages.length;k++)if(a.currentPage==a.pages[k]){l=k+
 1;q.value=l;t.value=l;break}q.setAttribute("max",g);t.setAttribute("max",g);1<g&&f.appendChild(m);var r=document.createElement("div");r.style.marginBottom="10px";var u=document.createElement("input");u.style.marginRight="8px";u.setAttribute("value","adjust");u.setAttribute("type","radio");u.setAttribute("name","printZoom");r.appendChild(u);k=document.createElement("span");mxUtils.write(k,mxResources.get("adjustTo"));r.appendChild(k);var V=document.createElement("input");V.style.cssText="margin:0 8px 0 8px;";
 V.setAttribute("value","100 %");V.style.width="50px";r.appendChild(V);mxEvent.addListener(V,"focus",function(){u.checked=!0});f.appendChild(r);var m=m.cloneNode(!1),P=u.cloneNode(!0);P.setAttribute("value","fit");u.setAttribute("checked","checked");k=document.createElement("div");k.style.cssText="display:inline-block;height:100%;vertical-align:top;padding-top:2px;";k.appendChild(P);m.appendChild(k);r=document.createElement("table");r.style.display="inline-block";var ba=document.createElement("tbody"),
-T=document.createElement("tr"),D=T.cloneNode(!0),X=document.createElement("td"),Q=X.cloneNode(!0),J=X.cloneNode(!0),Y=X.cloneNode(!0),O=X.cloneNode(!0),K=X.cloneNode(!0);X.style.textAlign="right";Y.style.textAlign="right";mxUtils.write(X,mxResources.get("fitTo"));var M=document.createElement("input");M.style.cssText="margin:0 8px 0 8px;";M.setAttribute("value","1");M.setAttribute("min","1");M.setAttribute("type","number");M.style.width="40px";Q.appendChild(M);k=document.createElement("span");mxUtils.write(k,
-mxResources.get("fitToSheetsAcross"));J.appendChild(k);mxUtils.write(Y,mxResources.get("fitToBy"));var U=M.cloneNode(!0);O.appendChild(U);mxEvent.addListener(M,"focus",function(){P.checked=!0});mxEvent.addListener(U,"focus",function(){P.checked=!0});k=document.createElement("span");mxUtils.write(k,mxResources.get("fitToSheetsDown"));K.appendChild(k);T.appendChild(X);T.appendChild(Q);T.appendChild(J);D.appendChild(Y);D.appendChild(O);D.appendChild(K);ba.appendChild(T);ba.appendChild(D);r.appendChild(ba);
+T=document.createElement("tr"),D=T.cloneNode(!0),X=document.createElement("td"),Q=X.cloneNode(!0),J=X.cloneNode(!0),Y=X.cloneNode(!0),O=X.cloneNode(!0),K=X.cloneNode(!0);X.style.textAlign="right";Y.style.textAlign="right";mxUtils.write(X,mxResources.get("fitTo"));var N=document.createElement("input");N.style.cssText="margin:0 8px 0 8px;";N.setAttribute("value","1");N.setAttribute("min","1");N.setAttribute("type","number");N.style.width="40px";Q.appendChild(N);k=document.createElement("span");mxUtils.write(k,
+mxResources.get("fitToSheetsAcross"));J.appendChild(k);mxUtils.write(Y,mxResources.get("fitToBy"));var U=N.cloneNode(!0);O.appendChild(U);mxEvent.addListener(N,"focus",function(){P.checked=!0});mxEvent.addListener(U,"focus",function(){P.checked=!0});k=document.createElement("span");mxUtils.write(k,mxResources.get("fitToSheetsDown"));K.appendChild(k);T.appendChild(X);T.appendChild(Q);T.appendChild(J);D.appendChild(Y);D.appendChild(O);D.appendChild(K);ba.appendChild(T);ba.appendChild(D);r.appendChild(ba);
 m.appendChild(r);f.appendChild(m);m=document.createElement("div");k=document.createElement("div");k.style.fontWeight="bold";k.style.marginBottom="12px";mxUtils.write(k,mxResources.get("paperSize"));m.appendChild(k);k=document.createElement("div");k.style.marginBottom="12px";var ca=PageSetupDialog.addPageFormatPanel(k,"printdialog",a.editor.graph.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT);m.appendChild(k);k=document.createElement("span");mxUtils.write(k,mxResources.get("pageScale"));m.appendChild(k);
 var Z=document.createElement("input");Z.style.cssText="margin:0 8px 0 8px;";Z.setAttribute("value","100 %");Z.style.width="60px";m.appendChild(Z);f.appendChild(m);k=document.createElement("div");k.style.cssText="text-align:right;margin:62px 0 0 0;";m=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});m.className="geBtn";a.editor.cancelFirst&&k.appendChild(m);a.isOffline()||(r=mxUtils.button(mxResources.get("help"),function(){window.open("https://desk.draw.io/support/solutions/articles/16000048947")}),
 r.className="geBtn",k.appendChild(r));PrintDialog.previewEnabled&&(r=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();d(!1)}),r.className="geBtn",k.appendChild(r));r=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?"print":"ok"),function(){a.hideDialog();d(!0)});r.className="geBtn gePrimaryBtn";k.appendChild(r);a.editor.cancelFirst||k.appendChild(m);f.appendChild(k);this.container=f}})();(function(){EditorUi.VERSION="@DRAWIO-VERSION@";EditorUi.compactUi="atlas"!=uiTheme;EditorUi.enableLogging=/.*\.draw\.io$/.test(window.location.hostname);EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;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.sidebarFooterHeight=
 36;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.resampleThreshold=
-1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();EditorUi.prototype.getLocalData=
-function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=
-function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,length:c,width:Math.round(c/
-3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=2E9,k.style.left=
-Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+"px")),this.pause=
-mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<
-16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};var a=
-EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
+1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;EditorUi.prototype.formatEnabled="0"!=urlParams.format;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=
+null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();
+EditorUi.prototype.getLocalData=function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,
+length:c,width:Math.round(c/3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=
+2E9,k.style.left=Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+
+"px")),this.pause=mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<
+8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};
+var a=EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
 function(a){if(null!=a&&0<a.length){var b=a.indexOf('<meta charset="utf-8">');0<=b&&(a=a.slice(0,b)+'<meta charset="utf-8"/>'+a.slice(b+23-1,a.length))}return a};EditorUi.prototype.replaceFileData=function(a){a=this.validateFileData(a);a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var b=null!=a?this.editor.extractGraphModel(a,!0):null;null!=b&&(a=b);if(null!=a){b=this.editor.graph;b.model.beginUpdate();try{var c=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 f=this.updatePageRoot(new DiagramPage(d[e]));null==f.getName()&&f.setName(mxResources.get("pageWithNumber",[e+1]));b.model.execute(new ChangePage(this,f,0==e?f: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])),b.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!=c)for(e=0;e<c.length;e++)b.model.execute(new ChangePage(this,c[e],null))}finally{b.model.endUpdate()}}};EditorUi.prototype.createFileData=function(a,b,c,d,e,f,g,r,u,x){b=null!=b?b:this.editor.graph;e=null!=e?e:!1;u=null!=u?u:!0;var k,l=null;null==c||
@@ -2790,17 +2791,17 @@ EditorUi.prototype.createEmbedSvg=function(a,b,c,d,e,f,g){var k=this.editor.grap
 " "+mxResources.get("months");b=Math.floor(a/86400);if(1<b)return b+" "+mxResources.get("days");b=Math.floor(a/3600);if(1<b)return b+" "+mxResources.get("hours");b=Math.floor(a/60);return 1<b?b+" "+mxResources.get("minutes"):1==b?b+" "+mxResources.get("minute"):null};EditorUi.prototype.convertMath=function(a,b,c,d){d()};EditorUi.prototype.getEmbeddedSvg=function(a,b,c,d,e,f,g){g=b.background;g==mxConstants.NONE&&(g=null);b=b.getSvg(g,null,null,null,null,f);null!=a&&b.setAttribute("content",a);null!=
 c&&b.setAttribute("resource",c);if(null!=e)this.convertImages(b,mxUtils.bind(this,function(a){e((d?"":'<?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(d?"":'<?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(b)};EditorUi.prototype.exportImage=function(a,b,c,d,e,f,g,
 r,u){u=null!=u?u:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var k=this.editor.graph.isSelectionEmpty();c=null!=c?c:k;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.exportToCanvas(mxUtils.bind(this,function(a){this.spinner.stop();try{this.saveCanvas(a,e?this.getFileData(!0,null,null,null,c,r):null,u)}catch(y){"Invalid image"==y.message?this.downloadFile(u):this.handleError(y)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();
-this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,r,u,x,z,y,A,v){f=null!=f?f:!0;y=null!=y?y:this.editor.graph;A=null!=A?A:0;var k=u?null:y.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==u&&(k="#ffffff");this.convertImages(y.getSvg(k,null,null,v,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){var e=document.createElement("canvas"),
-g=parseInt(c.getAttribute("width")),l=parseInt(c.getAttribute("height"));r=null!=r?r:1;null!=b&&(r=f?Math.min(1,Math.min(3*b/(4*l),b/g)):b/g);g=Math.ceil(r*g)+2*A;l=Math.ceil(r*l)+2*A;e.setAttribute("width",g);e.setAttribute("height",l);var m=e.getContext("2d");null!=k&&(m.beginPath(),m.rect(0,0,g,l),m.fillStyle=k,m.fill());m.scale(r,r);m.drawImage(d,A/r,A/r);a(e)});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(y,c,!0,mxUtils.bind(this,function(){d.src=
-this.createSvgDataUri(mxUtils.getXml(c))}))}catch(C){null!=e&&e(C)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=function(a,b,
-c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,g){for(var k=a.getElementsByTagName(c),l=0;l<k.length;l++)mxUtils.bind(this,function(c){var k=d.convert(c.getAttribute(g));if(null!=k&&"data:"!=k.substring(0,5)){var l=f[k];null==l?(e++,this.convertImageToDataUri(k,function(d){null!=d&&(f[k]=d,c.setAttribute(g,d));e--;0==e&&b(a)})):c.setAttribute(g,l)}})(k[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=function(a){return"https?://raw.githubusercontent.com/"===
-a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=
-function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var g=this.editor.graph;if(null!=a&&0<a.length){var k=mxUtils.parseXml(a),l=this.editor.extractGraphModel(k.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(g.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){g.model.beginUpdate();try{for(var n=0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),
-A=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[A+1]));g.model.execute(new ChangePage(this,p,p,A))}}finally{g.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var v=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,v);var B=v.getChildCount(v.getRoot());g.model.getChildCount(g.model.getRoot());g.model.beginUpdate();try{a={};for(n=0;n<B;n++){var G=v.getChildAt(v.getRoot(),n);if(1!=B||g.isCellLocked(g.getDefaultParent()))G=g.importCells([G],0,0,g.model.getRoot(),
-null,a)[0],F=g.model.getChildren(G),g.moveCells(F,b,c),f=f.concat(F);else var F=v.getChildren(G),f=f.concat(g.importCells(F,b,c,g.getDefaultParent(),null,a))}if(d){g.isGridEnabled()&&(b=g.snap(b),c=g.snap(c));var C=g.getBoundingBoxFromGeometry(f,!0);null!=C&&g.moveCells(f,b-C.x,c-C.y)}}finally{g.model.endUpdate()}}}}catch(H){throw e||this.handleError(H,mxResources.get("invalidOrMissingFile")),H;}return f};EditorUi.prototype.insertLucidChart=function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,
-b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var g=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var k=this.extractGraphModelFromPng(a),l=this.importXml(k,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,19))try{if(k=null,"data:image/svg+xml;base64,"==a.substring(0,
-26)?(k=a.substring(a.indexOf(",")+1),k=window.atob&&!mxClient.IS_SF?atob(k):Base64.decode(k,!0)):k=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(k,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){g.setSelectionCell(g.insertVertex(null,null,"",g.snap(b),g.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
+this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,r,u,x,z,y,A,v){f=null!=f?f:!0;y=null!=y?y:this.editor.graph;A=null!=A?A:0;var k=u?null:y.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==u&&(k="#ffffff");this.convertImages(y.getSvg(k,null,null,v,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){try{var g=document.createElement("canvas"),
+l=parseInt(c.getAttribute("width")),m=parseInt(c.getAttribute("height"));r=null!=r?r:1;null!=b&&(r=f?Math.min(1,Math.min(3*b/(4*m),b/l)):b/l);l=Math.ceil(r*l)+2*A;m=Math.ceil(r*m)+2*A;g.setAttribute("width",l);g.setAttribute("height",m);var n=g.getContext("2d");null!=k&&(n.beginPath(),n.rect(0,0,l,m),n.fillStyle=k,n.fill());n.scale(r,r);n.drawImage(d,A/r,A/r);a(g)}catch(M){null!=e&&e(M)}});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(y,c,!0,mxUtils.bind(this,
+function(){d.src=this.createSvgDataUri(mxUtils.getXml(c))}))}catch(C){null!=e&&e(C)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=
+function(a,b,c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,g){for(var k=a.getElementsByTagName(c),l=0;l<k.length;l++)mxUtils.bind(this,function(c){var k=d.convert(c.getAttribute(g));if(null!=k&&"data:"!=k.substring(0,5)){var l=f[k];null==l?(e++,this.convertImageToDataUri(k,function(d){null!=d&&(f[k]=d,c.setAttribute(g,d));e--;0==e&&b(a)})):c.setAttribute(g,l)}})(k[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=
+function(a){return"https?://raw.githubusercontent.com/"===a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};
+c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var g=this.editor.graph;if(null!=a&&0<a.length){var k=mxUtils.parseXml(a),l=this.editor.extractGraphModel(k.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(g.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){g.model.beginUpdate();try{for(var n=
+0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),A=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[A+1]));g.model.execute(new ChangePage(this,p,p,A))}}finally{g.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var v=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,v);var B=v.getChildCount(v.getRoot());g.model.getChildCount(g.model.getRoot());g.model.beginUpdate();try{a={};for(n=0;n<B;n++){var G=v.getChildAt(v.getRoot(),n);if(1!=
+B||g.isCellLocked(g.getDefaultParent()))G=g.importCells([G],0,0,g.model.getRoot(),null,a)[0],F=g.model.getChildren(G),g.moveCells(F,b,c),f=f.concat(F);else var F=v.getChildren(G),f=f.concat(g.importCells(F,b,c,g.getDefaultParent(),null,a))}if(d){g.isGridEnabled()&&(b=g.snap(b),c=g.snap(c));var C=g.getBoundingBoxFromGeometry(f,!0);null!=C&&g.moveCells(f,b-C.x,c-C.y)}}finally{g.model.endUpdate()}}}}catch(H){throw e||this.handleError(H,mxResources.get("invalidOrMissingFile")),H;}return f};EditorUi.prototype.insertLucidChart=
+function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var g=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var k=this.extractGraphModelFromPng(a),l=this.importXml(k,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,
+19))try{if(k=null,"data:image/svg+xml;base64,"==a.substring(0,26)?(k=a.substring(a.indexOf(",")+1),k=window.atob&&!mxClient.IS_SF?atob(k):Base64.decode(k,!0)):k=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(k,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){g.setSelectionCell(g.insertVertex(null,null,"",g.snap(b),g.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
 this.convertDataUri(a)+";"))}),!0,this.maxImageSize);else{var e=Math.min(1,Math.min(this.maxImageSize/d.width,this.maxImageSize/d.height)),f=Math.round(d.width*e);d=Math.round(d.height*e);g.setSelectionCell(g.insertVertex(null,null,"",g.snap(b),g.snap(c),f,d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";"))}}),mxUtils.bind(this,function(){var e=null;g.getModel().beginUpdate();try{e=g.insertVertex(g.getDefaultParent(),
 null,a,g.snap(b),g.snap(c),1,1,"text;"+(d?"html=1;":"")),g.updateCellSize(e),g.fireEvent(new mxEventObject("textInserted","cells",[e]))}finally{g.getModel().endUpdate()}g.setSelectionCell(e)}))}else{a=this.editor.graph.zapGremlins(mxUtils.trim(a));if(this.isCompatibleString(a))return this.importXml(a,b,c,f);if(0<a.length)if('{"state":"{\\"Properties\\":'==a.substring(0,26)){e=JSON.parse(JSON.parse(a).state);var k=null,m;for(m in e.Pages)if(l=e.Pages[m],null!=l&&"0"==l.Properties.Order){k=l;break}null!=
 k&&this.insertLucidChart(k,b,c,f)}else{g=this.editor.graph;f=null;g.getModel().beginUpdate();try{f=g.insertVertex(g.getDefaultParent(),null,"",g.snap(b),g.snap(c),1,1,"text;"+(d?"html=1;":"")),g.fireEvent(new mxEventObject("textInserted","cells",[f])),f.value=a,g.updateCellSize(f),/\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/i.test(f.value)&&
@@ -2822,11 +2823,11 @@ for(var b=0;256>b;b++)for(var c=b,d=0;8>d;d++)c=1==(c&1)?3988292384^c>>>1:c>>>1,
 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 l=0;if(f(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=e&&e();else if(f(a,4),"IHDR"!=f(a,4))null!=e&&e();else{f(a,17);e=a.substring(0,l);do{var m=g(a);if("IDAT"==f(a,4)){e=a.substring(0,l-8);c=c+String.fromCharCode(0)+("zTXt"==b?String.fromCharCode(0):"")+d;d=4294967295;d=this.updateCRC(d,b,0,4);d=this.updateCRC(d,c,0,c.length);e+=k(c.length)+b+c+k(d^4294967295);
 e+=a.substring(l-8,a.length);break}e+=a.substring(l-8,l-4+m);d=f(a,m);f(a,4)}while(m);return"data:image/png;base64,"+(window.btoa?btoa(e):Base64.encode(e,!0))}};EditorUi.prototype.extractGraphModelFromPng=function(a){var b=null;try{var c=a.substring(a.indexOf(",")+1),d=window.atob&&!mxClient.IS_SF?atob(c):Base64.decode(c,!0);EditorUi.parsePng(d,mxUtils.bind(this,function(a,c,e){a=d.substring(a+8,a+8+e);"zTXt"==c?(e=a.indexOf(String.fromCharCode(0)),"mxGraphModel"==a.substring(0,e)&&(a=this.editor.graph.bytesToString(pako.inflateRaw(a.substring(e+
 2))).replace(/\+/g," "),null!=a&&0<a.length&&(b=a))):"tEXt"==c&&(a=a.split(String.fromCharCode(0)),1<a.length&&"mxGraphModel"==a[0]&&(b=a[1]));if(null!=b||"IDAT"==c)return!0}))}catch(p){}null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));return b};EditorUi.prototype.loadImage=function(a,b,c){var d=new Image;d.onload=function(){b(d)};null!=c&&(d.onerror=c);d.src=a};var e=EditorUi.prototype.init;EditorUi.prototype.init=function(){function a(a){var c=
-a.indexOf(",");0<c&&(a=b.getPageById(a.substring(c+1)))&&b.selectPage(a)}var b=this,c=this.editor.graph,d=c.addClickHandler;c.addClickHandler=function(b,e,f){var g=e;e=function(b,d){if(null==d){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(d=e.getAttribute("href"))}null!=d&&c.isPageLink(d)&&(a(d),mxEvent.consume(b));null!=g&&g(b)};d.call(this,b,e,f)};e.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(c.view.canvas.ownerSVGElement,null,!0);b.actions.get("print").funct=
-function(){b.showDialog((new PrintDialog(b)).container,360,null!=b.pages&&1<b.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=c.getGlobalVariable;c.getGlobalVariable=function(a){return"page"==a&&null!=b.currentPage?b.currentPage.getName():"pagenumber"==a?null!=b.currentPage&&null!=b.pages?mxUtils.indexOf(b.pages,b.currentPage)+1:1:f.apply(this,arguments)};var g=c.createLinkForHint;c.createLinkForHint=function(d,e){var f=c.isPageLink(d);if(f){var k=d.indexOf(",");
-0<k&&(k=b.getPageById(d.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(b){a(d);mxEvent.consume(b)});return k};var t=c.labelLinkClicked;c.labelLinkClicked=function(b,d,e){var f=d.getAttribute("href");c.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=b.defaultFilename,c=b.getCurrentFile();null!=c&&(a=null!=c.getTitle()?c.getTitle():a);return a};
-var r=this.actions.get("print");r.setEnabled(!mxClient.IS_IOS||!navigator.standalone);r.visible=r.isEnabled();if(!this.editor.chromeless){var u=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||c.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var g=f[index];if("file"===g.kind){if(b.isEditing())this.importFiles([g.getAsFile()],
+a.indexOf(",");0<c&&(a=b.getPageById(a.substring(c+1)))&&b.selectPage(a)}"undefined"!==typeof window.mxSettings&&(this.formatWidth=mxSettings.getFormatWidth());var b=this,c=this.editor.graph,d=c.addClickHandler;c.addClickHandler=function(b,e,f){var g=e;e=function(b,d){if(null==d){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(d=e.getAttribute("href"))}null!=d&&c.isPageLink(d)&&(a(d),mxEvent.consume(b));null!=g&&g(b)};d.call(this,b,e,f)};e.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(c.view.canvas.ownerSVGElement,
+null,!0);b.actions.get("print").funct=function(){b.showDialog((new PrintDialog(b)).container,360,null!=b.pages&&1<b.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=c.getGlobalVariable;c.getGlobalVariable=function(a){return"page"==a&&null!=b.currentPage?b.currentPage.getName():"pagenumber"==a?null!=b.currentPage&&null!=b.pages?mxUtils.indexOf(b.pages,b.currentPage)+1:1:f.apply(this,arguments)};var g=c.createLinkForHint;c.createLinkForHint=function(d,e){var f=
+c.isPageLink(d);if(f){var k=d.indexOf(",");0<k&&(k=b.getPageById(d.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(b){a(d);mxEvent.consume(b)});return k};var t=c.labelLinkClicked;c.labelLinkClicked=function(b,d,e){var f=d.getAttribute("href");c.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=b.defaultFilename,c=b.getCurrentFile();null!=c&&(a=
+null!=c.getTitle()?c.getTitle():a);return a};var r=this.actions.get("print");r.setEnabled(!mxClient.IS_IOS||!navigator.standalone);r.visible=r.isEnabled();if(!this.editor.chromeless){var u=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||c.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var g=f[index];if("file"===g.kind){if(b.isEditing())this.importFiles([g.getAsFile()],
 0,0,this.maxImageSize,function(a,c,d,e,f,g){b.insertImage(a,f,g)},function(){},function(a){return"image/"==a.type.substring(0,6)},function(a){for(var b=0;b<a.length;b++)a[b]()});else{var k=this.editor.graph.getInsertPoint();this.importFiles([g.getAsFile()],k.x,k.y,this.maxImageSize);mxEvent.consume(a)}break}}}}catch(L){}}),!1);var x=document.createElement("div");x.style.position="absolute";x.style.whiteSpace="nowrap";x.style.overflow="hidden";x.style.display="block";x.contentEditable=!0;mxUtils.setOpacity(x,
 0);x.style.width="1px";x.style.height="1px";x.innerHTML="&nbsp;";var z=!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 b=mxEvent.getSource(a);null==c.container||!c.isEnabled()||c.isMouseDown||c.isEditing()||null!=this.dialog||"INPUT"==b.nodeName||"TEXTAREA"==b.nodeName||!(224==a.keyCode||!mxClient.IS_MAC&&17==a.keyCode||mxClient.IS_MAC&&91==a.keyCode)||
 z||(x.style.left=c.container.scrollLeft+10+"px",x.style.top=c.container.scrollTop+10+"px",c.container.appendChild(x),z=!0,mxClient.IS_QUIRKS?window.setTimeout(function(){x.focus();document.execCommand("selectAll",!1,null)},0):(x.focus(),document.execCommand("selectAll",!1,null)))}));mxEvent.addListener(document,"keyup",mxUtils.bind(this,function(a){var b=a.keyCode;window.setTimeout(mxUtils.bind(this,function(){!z||224!=b&&17!=b&&91!=b||(z=!1,c.isEditing()||null!=this.dialog||null==c.container||c.container.focus(),
@@ -2841,53 +2842,57 @@ null;mxEvent.addListener(c.container,"dragleave",function(a){c.isEnabled()&&(nul
 v=null);if(c.isEnabled()){var b=mxUtils.convertPoint(c.container,mxEvent.getClientX(a),mxEvent.getClientY(a)),d=c.view.translate,e=c.view.scale,f=b.x/e-d.x,g=b.y/e-d.y;mxEvent.isAltDown(a)&&(g=f=0);if(0<a.dataTransfer.files.length)this.importFiles(a.dataTransfer.files,f,g,this.maxImageSize,null,null,null,null,!mxEvent.isControlDown(a),null,null,mxEvent.isShiftDown(a));else{var k=0<=mxUtils.indexOf(a.dataTransfer.types,"text/uri-list")?a.dataTransfer.getData("text/uri-list"):null,b=this.extractGraphModelFromEvent(a,
 null!=this.pages);if(null!=b)c.setSelectionCells(this.importXml(b,f,g,!0));else if(0<=mxUtils.indexOf(a.dataTransfer.types,"text/html")){b=a.dataTransfer.getData("text/html");e=document.createElement("div");e.innerHTML=b;var d=null,l=e.getElementsByTagName("img");null!=l&&1==l.length?(b=l[0].getAttribute("src"),/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(b)||(d=!0)):(e=e.getElementsByTagName("a"),null!=e&&1==e.length&&(b=e[0].getAttribute("href")));c.setSelectionCells(this.insertTextAt(b,f,g,!0,d))}else null!=
 k&&/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(k)?this.loadImage(decodeURIComponent(k),mxUtils.bind(this,function(a){var b=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,b)),d/Math.max(1,a));c.setSelectionCell(c.insertVertex(null,null,"",f,g,b*d,a*d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+k+";"))}),mxUtils.bind(this,function(a){c.setSelectionCells(this.insertTextAt(k,
-f,g,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&c.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,g,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode()};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,
-encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=
-this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var g=e.lastIndexOf("%3E");0<=g&&g<e.length-3&&(e=e.substring(0,g+3))}catch(u){}try{var c=b.getElementsByTagName("span"),k=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(k)&&(f=!0,e=k)}catch(u){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=
-e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(u){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=
-null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,
-function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;
-var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?
-this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=
-0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?
-this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(r){this.handleError(r,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,
-d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,
-a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),
-this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),
-c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=
-null!=c?c:!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 b=
-this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,
-f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function k(a){if(null!=a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(I){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(E){l=null}if(null==l)return;
-if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&g.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?
-mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):k(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",
-result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(E){g.postMessage(JSON.stringify({event:"draft",error:E.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?
-g.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=
-l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,
-t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;g.postMessage(JSON.stringify(b),"*")}),r=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=
-this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),F=q.getGlobalVariable,C=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?C.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(C.root)}this.exportToCanvas(mxUtils.bind(this,function(a){r(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){r(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+
-("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):r(null)}),mxUtils.bind(this,function(){r(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=
-this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),
-"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);g.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));g.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),
-this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=this.createSvgDataUri(m)}g.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight=
-"12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight="38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{g.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=k(l);c=!0;try{a(l,f)}catch(E){this.handleError(E)}c=!1;null!=
-urlParams.modified&&this.editor.setStatus("");var H=mxUtils.bind(this,function(){return"0"!=urlParams.pages||null!=this.pages&&1<this.pages.length?this.getFileData(!0):mxUtils.getXml(this.editor.getGraphXml())});e=H();d&&null==b&&(b=mxUtils.bind(this,function(a,b){var d=H();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",
-b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||g.postMessage(JSON.stringify(this.createLoadMessage("load")),
-"*")}));var g=window.opener||window.parent,f="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";g.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",
-mxResources.get("save")+" (Ctrl+S)");b.className="geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor=
-"pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=
-a.split("\n"),c=[];if(0<b.length){var d={},e=null,f=null,g="auto",k="auto",u=40,x=40,z=0,y=this.editor.graph;y.getGraphBounds();for(var A=function(){y.setSelectionCells(M);y.scrollCellToVisible(y.getSelectionCell())},v=y.getFreeInsertPoint(),B=v.x,G=v.y,v=G,F=null,C="auto",H=[],E=null,I=null,N=0;N<b.length&&"#"==b[N].charAt(0);){a=b[N];for(N++;N<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[N].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[N].substring(1)),N++;if("#"!=a.charAt(1)){var L=a.indexOf(":");
-if(0<L){var V=mxUtils.trim(a.substring(1,L)),P=mxUtils.trim(a.substring(L+1));"label"==V?F=y.sanitizeHtml(P):"style"==V?e=P:"identity"==V&&0<P.length&&"-"!=P?f=P:"width"==V?g=P:"height"==V?k=P:"ignore"==V?I=P.split(","):"connect"==V?H.push(JSON.parse(P)):"link"==V?E=P:"padding"==V?z=parseFloat(P):"edgespacing"==V?u=parseFloat(P):"nodespacing"==V?x=parseFloat(P):"layout"==V&&(C=P)}}}var ba=this.editor.csvToArray(b[N]);a=null;if(null!=f)for(var T=0;T<ba.length;T++)if(f==ba[T]){a=T;break}null==F&&(F=
-"%"+ba[0]+"%");if(null!=H)for(var D=0;D<H.length;D++)null==d[H[D].to]&&(d[H[D].to]={});y.model.beginUpdate();try{for(T=N+1;T<b.length;T++){var X=this.editor.csvToArray(b[T]);if(X.length==ba.length){var Q=null,J=null!=a?X[a]:null;null!=J&&(Q=y.model.getCell(J));null==Q&&(Q=new mxCell(F,new mxGeometry(B,v,0,0),e||"whiteSpace=wrap;html=1;"),Q.vertex=!0,Q.id=J);for(var Y=0;Y<X.length;Y++)y.setAttributeForCell(Q,ba[Y],X[Y]);y.setAttributeForCell(Q,"placeholders","1");Q.style=y.replacePlaceholders(Q,Q.style);
-for(D=0;D<H.length;D++)d[H[D].to][Q.getAttribute(H[D].to)]=Q;null!=E&&"link"!=E&&(y.setLinkForCell(Q,Q.getAttribute(E)),y.setAttributeForCell(Q,E,null));var O=this.editor.graph.getPreferredSizeForCell(Q);Q.geometry.width="auto"==g?O.width+z:parseFloat(g);Q.geometry.height="auto"==k?O.height+z:parseFloat(k);v+=Q.geometry.height+x;c.push(y.addCell(Q))}}null==e&&y.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var K=c.slice(),M=c.slice(),D=0;D<H.length;D++)for(var U=H[D],T=0;T<c.length;T++){var Q=
-c[T],ca=Q.getAttribute(U.from);if(null!=ca){y.setAttributeForCell(Q,U.from,null);for(var Z=ca.split(","),Y=0;Y<Z.length;Y++){var R=d[U.to][Z[Y]];null!=R&&(M.push(y.insertEdge(null,null,U.label||"",U.invert?R:Q,U.invert?Q:R,U.style||y.createCurrentEdgeStyle())),mxUtils.remove(U.invert?Q:R,K))}}}if(null!=I)for(T=0;T<c.length;T++)for(Q=c[T],Y=0;Y<I.length;Y++)y.setAttributeForCell(Q,mxUtils.trim(I[Y]),null);var aa=new mxParallelEdgeLayout(y);aa.spacing=u;var da=function(){aa.execute(y.getDefaultParent());
-for(var a=0;a<c.length;a++){var b=y.getCellGeometry(c[a]);b.x=Math.round(y.snap(b.x));b.y=Math.round(y.snap(b.y));"auto"==g&&(b.width=Math.round(y.snap(b.width)));"auto"==k&&(b.height=Math.round(y.snap(b.height)))}};if("circle"==C){var S=new mxCircleLayout(y);S.resetEdges=!1;var W=S.isVertexIgnored;S.isVertexIgnored=function(a){return W.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){S.execute(y.getDefaultParent());da()},!0,A);A=null}else if("horizontaltree"==C||"verticaltree"==
-C||"auto"==C&&M.length==2*c.length-1&&1==K.length){y.view.validate();var ga=new mxCompactTreeLayout(y,"horizontaltree"==C);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(y.getDefaultParent(),0<K.length?K[0]:null)},!0,A);A=null}else if("horizontalflow"==C||"verticalflow"==C||"auto"==C&&1==K.length){y.view.validate();var ea=new mxHierarchicalLayout(y,"horizontalflow"==C?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);ea.intraCellSpacing=x;ea.disableEdgeStyle=
-!1;this.executeLayout(function(){ea.execute(y.getDefaultParent(),M);y.moveCells(M,B,G)},!0,A);A=null}else if("organic"==C||"auto"==C&&M.length>c.length){y.view.validate();var ha=new mxFastOrganicLayout(y);ha.forceConstant=3*x;ha.resetEdges=!1;var la=ha.isVertexIgnored;ha.isVertexIgnored=function(a){return la.apply(this,arguments)||0>mxUtils.indexOf(c,a)};aa=new mxParallelEdgeLayout(y);aa.spacing=u;this.executeLayout(function(){ha.execute(y.getDefaultParent());da()},!0,A);A=null}this.hideDialog()}finally{y.model.endUpdate()}null!=
-A&&A()}}catch(ma){this.handleError(ma)}};EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
+f,g,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&c.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,g,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode();"undefined"!==typeof window.mxSettings&&this.installSettings()};EditorUi.prototype.installSettings=function(){if(isLocalStorage||mxClient.IS_CHROMEAPP)ColorDialog.recentColors=mxSettings.getRecentColors(),this.editor.graph.currentEdgeStyle=
+mxSettings.getCurrentEdgeStyle(),this.editor.graph.currentVertexStyle=mxSettings.getCurrentVertexStyle(),this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[])),this.addListener("styleChanged",mxUtils.bind(this,function(a,b){mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);mxSettings.save()})),this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget()),this.fireEvent(new mxEventObject("copyConnectChanged")),
+this.addListener("copyConnectChanged",mxUtils.bind(this,function(a,b){mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());mxSettings.save()})),this.editor.graph.pageFormat=mxSettings.getPageFormat(),this.addListener("pageFormatChanged",mxUtils.bind(this,function(a,b){mxSettings.setPageFormat(this.editor.graph.pageFormat);mxSettings.save()})),this.editor.graph.view.gridColor=mxSettings.getGridColor(),this.addListener("gridColorChanged",mxUtils.bind(this,function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor);
+mxSettings.save()})),mxClient.IS_CHROMEAPP&&(this.editor.addListener("autosaveChanged",mxUtils.bind(this,function(a,b){mxSettings.setAutosave(this.editor.autosave);mxSettings.save()})),this.editor.autosave=mxSettings.getAutosave()),null!=this.sidebar&&this.sidebar.showPalette("search",mxSettings.settings.search),!this.editor.chromeless&&null!=this.sidebar&&(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))&&(this.toggleScratchpad(),mxSettings.save()),this.addListener("formatWidthChanged",
+function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=
+function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var g=e.lastIndexOf("%3E");0<=g&&g<e.length-3&&(e=e.substring(0,
+g+3))}catch(u){}try{var c=b.getElementsByTagName("span"),k=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(k)&&(f=!0,e=k)}catch(u){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),
+d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(u){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],
+"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&
+(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&
+(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-
+3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=
+function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,
+d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},
+mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(r){this.handleError(r,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,
+5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?
+(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),
+a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),
+f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=null!=c?c:!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 b=this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,
+scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function k(a){if(null!=
+a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(I){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(E){l=null}if(null==l)return;if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,
+null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&g.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();
+return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):k(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):
+null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(E){g.postMessage(JSON.stringify({event:"draft",error:E.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?g.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,
+name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=
+null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();
+var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;g.postMessage(JSON.stringify(b),"*")}),r=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),
+F=q.getGlobalVariable,C=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?C.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(C.root)}this.exportToCanvas(mxUtils.bind(this,function(a){r(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){r(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,
+function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):r(null)}),mxUtils.bind(this,function(){r(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),
+n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,
+function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);g.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));g.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=
+this.createSvgDataUri(m)}g.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight="12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight=
+"38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{g.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=k(l);c=!0;try{a(l,f)}catch(E){this.handleError(E)}c=!1;null!=urlParams.modified&&this.editor.setStatus("");var H=mxUtils.bind(this,function(){return"0"!=
+urlParams.pages||null!=this.pages&&1<this.pages.length?this.getFileData(!0):mxUtils.getXml(this.editor.getGraphXml())});e=H();d&&null==b&&(b=mxUtils.bind(this,function(a,b){var d=H();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",
+b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||g.postMessage(JSON.stringify(this.createLoadMessage("load")),"*")}));var g=window.opener||window.parent,f="json"==
+urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";g.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",mxResources.get("save")+" (Ctrl+S)");b.className=
+"geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor="pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=a.split("\n"),c=[];if(0<b.length){var d={},e=
+null,f=null,g="auto",k="auto",u=40,x=40,z=0,y=this.editor.graph;y.getGraphBounds();for(var A=function(){y.setSelectionCells(N);y.scrollCellToVisible(y.getSelectionCell())},v=y.getFreeInsertPoint(),B=v.x,G=v.y,v=G,F=null,C="auto",H=[],E=null,I=null,M=0;M<b.length&&"#"==b[M].charAt(0);){a=b[M];for(M++;M<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[M].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[M].substring(1)),M++;if("#"!=a.charAt(1)){var L=a.indexOf(":");if(0<L){var V=mxUtils.trim(a.substring(1,
+L)),P=mxUtils.trim(a.substring(L+1));"label"==V?F=y.sanitizeHtml(P):"style"==V?e=P:"identity"==V&&0<P.length&&"-"!=P?f=P:"width"==V?g=P:"height"==V?k=P:"ignore"==V?I=P.split(","):"connect"==V?H.push(JSON.parse(P)):"link"==V?E=P:"padding"==V?z=parseFloat(P):"edgespacing"==V?u=parseFloat(P):"nodespacing"==V?x=parseFloat(P):"layout"==V&&(C=P)}}}var ba=this.editor.csvToArray(b[M]);a=null;if(null!=f)for(var T=0;T<ba.length;T++)if(f==ba[T]){a=T;break}null==F&&(F="%"+ba[0]+"%");if(null!=H)for(var D=0;D<
+H.length;D++)null==d[H[D].to]&&(d[H[D].to]={});y.model.beginUpdate();try{for(T=M+1;T<b.length;T++){var X=this.editor.csvToArray(b[T]);if(X.length==ba.length){var Q=null,J=null!=a?X[a]:null;null!=J&&(Q=y.model.getCell(J));null==Q&&(Q=new mxCell(F,new mxGeometry(B,v,0,0),e||"whiteSpace=wrap;html=1;"),Q.vertex=!0,Q.id=J);for(var Y=0;Y<X.length;Y++)y.setAttributeForCell(Q,ba[Y],X[Y]);y.setAttributeForCell(Q,"placeholders","1");Q.style=y.replacePlaceholders(Q,Q.style);for(D=0;D<H.length;D++)d[H[D].to][Q.getAttribute(H[D].to)]=
+Q;null!=E&&"link"!=E&&(y.setLinkForCell(Q,Q.getAttribute(E)),y.setAttributeForCell(Q,E,null));var O=this.editor.graph.getPreferredSizeForCell(Q);Q.geometry.width="auto"==g?O.width+z:parseFloat(g);Q.geometry.height="auto"==k?O.height+z:parseFloat(k);v+=Q.geometry.height+x;c.push(y.addCell(Q))}}null==e&&y.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var K=c.slice(),N=c.slice(),D=0;D<H.length;D++)for(var U=H[D],T=0;T<c.length;T++){var Q=c[T],ca=Q.getAttribute(U.from);if(null!=ca){y.setAttributeForCell(Q,
+U.from,null);for(var Z=ca.split(","),Y=0;Y<Z.length;Y++){var R=d[U.to][Z[Y]];null!=R&&(N.push(y.insertEdge(null,null,U.label||"",U.invert?R:Q,U.invert?Q:R,U.style||y.createCurrentEdgeStyle())),mxUtils.remove(U.invert?Q:R,K))}}}if(null!=I)for(T=0;T<c.length;T++)for(Q=c[T],Y=0;Y<I.length;Y++)y.setAttributeForCell(Q,mxUtils.trim(I[Y]),null);var aa=new mxParallelEdgeLayout(y);aa.spacing=u;var da=function(){aa.execute(y.getDefaultParent());for(var a=0;a<c.length;a++){var b=y.getCellGeometry(c[a]);b.x=
+Math.round(y.snap(b.x));b.y=Math.round(y.snap(b.y));"auto"==g&&(b.width=Math.round(y.snap(b.width)));"auto"==k&&(b.height=Math.round(y.snap(b.height)))}};if("circle"==C){var S=new mxCircleLayout(y);S.resetEdges=!1;var W=S.isVertexIgnored;S.isVertexIgnored=function(a){return W.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){S.execute(y.getDefaultParent());da()},!0,A);A=null}else if("horizontaltree"==C||"verticaltree"==C||"auto"==C&&N.length==2*c.length-1&&1==K.length){y.view.validate();
+var ga=new mxCompactTreeLayout(y,"horizontaltree"==C);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(y.getDefaultParent(),0<K.length?K[0]:null)},!0,A);A=null}else if("horizontalflow"==C||"verticalflow"==C||"auto"==C&&1==K.length){y.view.validate();var ea=new mxHierarchicalLayout(y,"horizontalflow"==C?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);ea.intraCellSpacing=x;ea.disableEdgeStyle=!1;this.executeLayout(function(){ea.execute(y.getDefaultParent(),
+N);y.moveCells(N,B,G)},!0,A);A=null}else if("organic"==C||"auto"==C&&N.length>c.length){y.view.validate();var ha=new mxFastOrganicLayout(y);ha.forceConstant=3*x;ha.resetEdges=!1;var la=ha.isVertexIgnored;ha.isVertexIgnored=function(a){return la.apply(this,arguments)||0>mxUtils.indexOf(c,a)};aa=new mxParallelEdgeLayout(y);aa.spacing=u;this.executeLayout(function(){ha.execute(y.getDefaultParent());da()},!0,A);A=null}this.hideDialog()}finally{y.model.endUpdate()}null!=A&&A()}}catch(ma){this.handleError(ma)}};
+EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
 d;for(d in urlParams)0>mxUtils.indexOf(c,d)&&(a=0==b?a+"?":a+"&",null!=urlParams[d]&&(a+=d+"="+urlParams[d],b++))}return a};EditorUi.prototype.showLinkDialog=function(a,b,c){a=new LinkDialog(this,a,b,c,!0);this.showDialog(a.container,420,120,!0,!0);a.init()};var f=EditorUi.prototype.createOutline;EditorUi.prototype.createOutline=function(a){var b=f.apply(this,arguments),c=this.editor.graph,d=b.getSourceGraphBounds;b.getSourceGraphBounds=function(){if(mxUtils.hasScrollbars(c.container)&&c.pageVisible&&
 null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width-2*a.x/b),Math.ceil(this.source.minimumGraphSize.height-2*a.y/b))}return d.apply(this,arguments)};var e=b.getSourceContainerSize;b.getSourceContainerSize=function(){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width*
 b-2*a.x),Math.ceil(this.source.minimumGraphSize.height*b-2*a.y))}return e.apply(this,arguments)};b.getOutlineOffset=function(a){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var d=this.source.getPagePadding();return new mxPoint(Math.round(Math.max(0,(b.outline.container.clientWidth/a-(this.source.minimumGraphSize.width-2*d.x))/2)-d.x),Math.round(Math.max(0,(b.outline.container.clientHeight/a-(this.source.minimumGraphSize.height-2*d.y))/2)-d.y-5/a))}return new mxPoint(8/
@@ -2898,7 +2903,7 @@ var c=("1"!=urlParams.embed||!this.editor.graph.isEnabled())&&(null==a||a.isRest
 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.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));
 if(this.isOfflineApp()){var d=applicationCache;if(null!=d&&null==this.offlineStatus){this.offlineStatus=document.createElement("div");this.offlineStatus.className="geItem";this.offlineStatus.style.position="absolute";this.offlineStatus.style.fontSize="8pt";this.offlineStatus.style.top="2px";this.offlineStatus.style.right="12px";this.offlineStatus.style.color="#666";this.offlineStatus.style.margin="4px";this.offlineStatus.style.padding="2px";this.offlineStatus.style.verticalAlign="middle";this.offlineStatus.innerHTML=
 "";this.menubarContainer.appendChild(this.offlineStatus);mxEvent.addListener(this.offlineStatus,"click",mxUtils.bind(this,function(){var a=this.offlineStatus.getElementsByTagName("img");null!=a&&0<a.length&&this.alert(a[0].getAttribute("title"))}));var d=window.applicationCache,e=null,b=mxUtils.bind(this,function(){var a=d.status,b;a==d.CHECKING&&(a=d.DOWNLOADING);switch(a){case d.UNCACHED:b="";break;case d.IDLE:b='<img title="draw.io is up to date." border="0" src="'+IMAGE_PATH+'/checkmark.gif"/>';
-break;case d.DOWNLOADING:b='<img title="Downloading new version" border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
+break;case d.DOWNLOADING:b='<img title="Downloading new version..." border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
 "checking",b);mxEvent.addListener(d,"noupdate",b);mxEvent.addListener(d,"downloading",b);mxEvent.addListener(d,"progress",b);mxEvent.addListener(d,"cached",b);mxEvent.addListener(d,"updateready",b);mxEvent.addListener(d,"obsolete",b);mxEvent.addListener(d,"error",b);b()}}else this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};var g=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){g.apply(this,
 arguments);var a=this.editor.graph,b=this.getCurrentFile(),c=null!=b&&b.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled();this.actions.get("pageSetup").setEnabled(c);this.actions.get("autosave").setEnabled(null!=b&&b.isEditable()&&b.isAutosaveOptional());this.actions.get("guides").setEnabled(c);this.actions.get("shadowVisible").setEnabled(c);this.actions.get("connectionArrows").setEnabled(c);this.actions.get("connectionPoints").setEnabled(c);this.actions.get("copyStyle").setEnabled(c&&
 !a.isSelectionEmpty());this.actions.get("pasteStyle").setEnabled(c&&!a.isSelectionEmpty());this.actions.get("editGeometry").setEnabled(a.getModel().isVertex(a.getSelectionCell()));this.actions.get("createShape").setEnabled(c);this.actions.get("createRevision").setEnabled(c);this.actions.get("moveToFolder").setEnabled(null!=b);this.actions.get("makeCopy").setEnabled(null!=b&&!b.isRestricted());this.actions.get("editDiagram").setEnabled("1"==urlParams.embed&&this.editor.graph.isEnabled()||null!=b&&
diff --git a/war/js/atlas.min.js b/war/js/atlas.min.js
index afaa98d1b644204bebab59ca727828b1800f4d2b..d87cdd339205ec173ade9e4c8ed845746099cdfc 100644
--- a/war/js/atlas.min.js
+++ b/war/js/atlas.min.js
@@ -2510,12 +2510,12 @@ k=d.getAttribute("h"),g=null==g?80:parseInt(g,10),k=null==k?80:parseInt(k,10);c(
 "#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=8;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGuide.prototype.isEnabledForEvent=function(b){return!mxEvent.isAltDown(b)};var c=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(b){return mxEvent.isControlDown(b)||c.apply(this,
 arguments)};mxConstraintHandler.prototype.createHighlightShape=function(){var b=new mxEllipse(null,this.highlightColor,this.highlightColor,0);b.opacity=mxConstants.HIGHLIGHT_OPACITY;return b};mxConnectionHandler.prototype.livePreview=!0;mxConnectionHandler.prototype.cursor="crosshair";mxConnectionHandler.prototype.createEdgeState=function(b){b=this.graph.createCurrentEdgeStyle();b=this.graph.createEdge(null,null,null,null,null,b);b=new mxCellState(this.graph.view,b,this.graph.getCellStyle(b));for(var a in this.graph.currentEdgeStyle)b.style[a]=
 this.graph.currentEdgeStyle[a];return b};var f=mxConnectionHandler.prototype.createShape;mxConnectionHandler.prototype.createShape=function(){var b=f.apply(this,arguments);b.isDashed="1"==this.graph.currentEdgeStyle[mxConstants.STYLE_DASHED];return b};mxConnectionHandler.prototype.updatePreview=function(b){};var d=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var b=d.apply(this,arguments),a=b.getCell;b.getCell=mxUtils.bind(this,function(b){var d=
-a.apply(this,arguments);this.error=null;return d});return b};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",html:"1",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var b="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(b+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(b+="curved="+this.currentEdgeStyle.curved+";");
-null!=this.currentEdgeStyle.rounded&&(b+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(b+="comic="+this.currentEdgeStyle.comic+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(b+="elbow="+this.currentEdgeStyle.elbow+";");return null!=this.currentEdgeStyle.html?b+("html="+this.currentEdgeStyle.html+";"):b+"html=1;"};Graph.prototype.getPagePadding=function(){return new mxPoint(0,0)};Graph.prototype.loadStylesheet=function(){var b=
-null!=this.themes?this.themes[this.defaultThemeName]:mxStyleRegistry.dynamicLoading?mxUtils.load(STYLE_PATH+"/default.xml").getDocumentElement():null;null!=b&&(new mxCodec(b.ownerDocument)).decode(b,this.getStylesheet())};Graph.prototype.getAllConnectionConstraints=function(b,a){if(null!=b){var d=mxUtils.getValue(b.style,"points",null);if(null!=d){var e=[];try{for(var c=JSON.parse(d),d=0;d<c.length;d++){var f=c[d];e.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(P){}return e}if(null!=
-b.shape)if(null!=b.shape.stencil){if(null!=b.shape.stencil)return b.shape.stencil.constraints}else if(null!=b.shape.constraints)return b.shape.constraints}return null};Graph.prototype.flipEdge=function(b){if(null!=b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);null!=a&&(a=mxUtils.getValue(a,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,a,[b]))}};
-Graph.prototype.isValidRoot=function(b){for(var a=this.model.getChildCount(b),d=0,e=0;e<a;e++){var c=this.model.getChildAt(b,e);this.model.isVertex(c)&&(c=this.getCellGeometry(c),null==c||c.relative||d++)}return 0<d||this.isContainer(b)};Graph.prototype.isValidDropTarget=function(b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);return"1"!=mxUtils.getValue(a,"part","0")&&(this.isContainer(b)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(a,"dropTarget",
-"1"))};Graph.prototype.createGroupCell=function(){var b=mxGraph.prototype.createGroupCell.apply(this,arguments);b.setStyle("group");return b};Graph.prototype.isExtendParentsOnAdd=function(b){var a=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(a&&null!=b&&null!=this.layoutManager){var d=this.model.getParent(b);null!=d&&(d=this.layoutManager.getLayout(d),null!=d&&d.constructor==mxStackLayout&&(a=!1))}return a};Graph.prototype.getPreferredSizeForCell=function(b){var a=mxGraph.prototype.getPreferredSizeForCell.apply(this,
+a.apply(this,arguments);this.error=null;return d});return b};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var b="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(b+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(b+="curved="+this.currentEdgeStyle.curved+";");null!=this.currentEdgeStyle.rounded&&
+(b+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(b+="comic="+this.currentEdgeStyle.comic+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(b+="elbow="+this.currentEdgeStyle.elbow+";");return null!=this.currentEdgeStyle.html?b+("html="+this.currentEdgeStyle.html+";"):b+"html=1;"};Graph.prototype.getPagePadding=function(){return new mxPoint(0,0)};Graph.prototype.loadStylesheet=function(){var b=null!=this.themes?this.themes[this.defaultThemeName]:
+mxStyleRegistry.dynamicLoading?mxUtils.load(STYLE_PATH+"/default.xml").getDocumentElement():null;null!=b&&(new mxCodec(b.ownerDocument)).decode(b,this.getStylesheet())};Graph.prototype.getAllConnectionConstraints=function(b,a){if(null!=b){var d=mxUtils.getValue(b.style,"points",null);if(null!=d){var e=[];try{for(var c=JSON.parse(d),d=0;d<c.length;d++){var f=c[d];e.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(P){}return e}if(null!=b.shape)if(null!=b.shape.stencil){if(null!=
+b.shape.stencil)return b.shape.stencil.constraints}else if(null!=b.shape.constraints)return b.shape.constraints}return null};Graph.prototype.flipEdge=function(b){if(null!=b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);null!=a&&(a=mxUtils.getValue(a,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,a,[b]))}};Graph.prototype.isValidRoot=function(b){for(var a=
+this.model.getChildCount(b),d=0,e=0;e<a;e++){var c=this.model.getChildAt(b,e);this.model.isVertex(c)&&(c=this.getCellGeometry(c),null==c||c.relative||d++)}return 0<d||this.isContainer(b)};Graph.prototype.isValidDropTarget=function(b){var a=this.view.getState(b),a=null!=a?a.style:this.getCellStyle(b);return"1"!=mxUtils.getValue(a,"part","0")&&(this.isContainer(b)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(a,"dropTarget","1"))};Graph.prototype.createGroupCell=
+function(){var b=mxGraph.prototype.createGroupCell.apply(this,arguments);b.setStyle("group");return b};Graph.prototype.isExtendParentsOnAdd=function(b){var a=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(a&&null!=b&&null!=this.layoutManager){var d=this.model.getParent(b);null!=d&&(d=this.layoutManager.getLayout(d),null!=d&&d.constructor==mxStackLayout&&(a=!1))}return a};Graph.prototype.getPreferredSizeForCell=function(b){var a=mxGraph.prototype.getPreferredSizeForCell.apply(this,
 arguments);null!=a&&(a.width+=10,a.height+=4,this.gridEnabled&&(a.width=this.snap(a.width),a.height=this.snap(a.height)));return a};Graph.prototype.turnShapes=function(b){var a=this.getModel(),d=[];a.beginUpdate();try{for(var e=0;e<b.length;e++){var c=b[e];if(a.isEdge(c)){var f=a.getTerminal(c,!0),g=a.getTerminal(c,!1);a.setTerminal(c,g,!0);a.setTerminal(c,f,!1);var k=a.getGeometry(c);if(null!=k){k=k.clone();null!=k.points&&k.points.reverse();var l=k.getTerminalPoint(!0),m=k.getTerminalPoint(!1);
 k.setTerminalPoint(l,!1);k.setTerminalPoint(m,!0);a.setGeometry(c,k);var n=this.view.getState(c),p=this.view.getState(f),t=this.view.getState(g);if(null!=n){var v=null!=p?this.getConnectionConstraint(n,p,!0):null,q=null!=t?this.getConnectionConstraint(n,t,!1):null;this.setConnectionConstraint(c,f,!0,q);this.setConnectionConstraint(c,g,!1,v)}d.push(c)}}else if(a.isVertex(c)&&(k=this.getCellGeometry(c),null!=k)){k=k.clone();k.x+=k.width/2-k.height/2;k.y+=k.height/2-k.width/2;var u=k.width;k.width=k.height;
 k.height=u;a.setGeometry(c,k);var x=this.view.getState(c);if(null!=x){var z=x.style[mxConstants.STYLE_DIRECTION]||"east";"east"==z?z="south":"south"==z?z="west":"west"==z?z="north":"north"==z&&(z="east");this.setCellStyles(mxConstants.STYLE_DIRECTION,z,[c])}d.push(c)}}}finally{a.endUpdate()}return d};Graph.prototype.processChange=function(b){mxGraph.prototype.processChange.apply(this,arguments);if(b instanceof mxValueChange&&null!=b.cell.value&&"object"==typeof b.cell.value){var a=this.model.getDescendants(b.cell);
@@ -7809,31 +7809,32 @@ function(){a.hideDialog();null!=f&&f()});c.appendChild(b);b.className="geBtn geP
 IMAGE_PATH+"/plus.png";Editor.spinImage=mxClient.IS_SVG?"data:image/gif;base64,R0lGODlhDAAMAPUxAEVriVp7lmCAmmGBm2OCnGmHn3OPpneSqYKbr4OcsIScsI2kto6kt46lt5KnuZmtvpquvpuvv56ywaCzwqK1xKu7yay9yq+/zLHAzbfF0bjG0bzJ1LzK1MDN18jT28nT3M3X3tHa4dTc49Xd5Njf5dng5t3k6d/l6uDm6uru8e7x8/Dz9fT29/b4+Pj5+fj5+vr6+v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkKADEAIf8LTkVUU0NBUEUyLjADAQAAACwAAAAADAAMAAAGR8CYcEgsOgYAIax4CCQuQldrCBEsiK8VS2hoFGOrlJDA+cZQwkLnqyoJFZKviSS0ICrE0ec0jDAwIiUeGyBFGhMPFBkhZo1BACH5BAkKAC4ALAAAAAAMAAwAhVB0kFR3k1V4k2CAmmWEnW6Lo3KOpXeSqH2XrIOcsISdsImhtIqhtJCmuJGnuZuwv52wwJ+ywZ+ywqm6yLHBzbLCzrXEz7fF0LnH0rrI0r7L1b/M1sXR2cfT28rV3czW3s/Z4Nfe5Nvi6ODm6uLn6+Ln7OLo7OXq7efs7+zw8u/y9PDy9PX3+Pr7+////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAZDQJdwSCxGDAIAoVFkFBwYSyIwGE4OkCJxIdG6WkJEx8sSKj7elfBB0a5SQg1EQ0SVVMPKhDM6iUIkRR4ZFxsgJl6JQQAh+QQJCgAxACwAAAAADAAMAIVGa4lcfZdjgpxkg51nhp5ui6N3kqh5lKqFnbGHn7KIoLOQp7iRp7mSqLmTqbqarr6br7+fssGitcOitcSuvsuuv8uwwMyzw861xNC5x9K6x9K/zNbDztjE0NnG0drJ1NzQ2eDS2+LT2+LV3ePZ4Oba4ebb4ufc4+jm6+7t8PLt8PPt8fPx8/Xx9PX09vf19/j3+Pn///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CYcEgsUhQFggFSjCQmnE1jcBhqGBXiIuAQSi7FGEIgfIzCFoCXFCZiPO0hKBMiwl7ET6eUYqlWLkUnISImKC1xbUEAIfkECQoAMgAsAAAAAAwADACFTnKPT3KPVHaTYoKcb4yjcY6leZSpf5mtgZuvh5+yiqG0i6K1jqW3kae5nrHBnrLBn7LCoLPCobTDqbrIqrvIs8LOtMPPtcPPtcTPuMbRucfSvcrUvsvVwMzWxdHaydTcytXdzNbezdff0drh2ODl2+Ln3eTp4Obq4ujs5Ont5uvu6O3w6u7w6u7x7/L09vj5+vr7+vv7////AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABkdAmXBILHIcicOCUqxELKKPxKAYgiYd4oMAEWo8RVmjIMScwhmBcJMKXwLCECmMGAhPI1QRwBiaSixCMDFhLSorLi8wYYxCQQAh+QQJCgAxACwAAAAADAAMAIVZepVggJphgZtnhp5vjKN2kah3kqmBmq+KobSLorWNpLaRp7mWq7ybr7+gs8KitcSktsWnuManucexwM2ywc63xtG6yNO9ytS+ytW/zNbDz9jH0tvL1d3N197S2+LU3OPU3ePV3eTX3+Xa4efb4ufd5Onl6u7r7vHs7/Lt8PLw8/Xy9Pby9fb09ff2+Pn3+Pn6+vr///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGSMCYcEgseiwSR+RS7GA4JFGF8RiWNiEiJTERgkjFGAQh/KTCGoJwpApnBkITKrwoCFWnFlEhaAxXLC9CBwAGRS4wQgELYY1CQQAh+QQJCgAzACwAAAAADAAMAIVMcI5SdZFhgZtti6JwjaR4k6mAma6Cm6+KobSLorWLo7WNo7aPpredsMCescGitMOitcSmuMaqu8ixwc2zws63xdC4xtG5x9K9ytXAzdfCztjF0NnF0drK1d3M1t7P2N/P2eDT2+LX3+Xe5Onh5+vi5+vj6Ozk6e3n7O/o7O/q7vHs7/Lt8PPu8fPx8/X3+Pn6+vv7+/v8/Pz///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRcCZcEgsmkIbTOZTLIlGqZNnchm2SCgiJ6IRqljFmQUiXIVnoITQde4chC9Y+LEQxmTFRkFSNFAqDAMIRQoCAAEEDmeLQQAh+QQJCgAwACwAAAAADAAMAIVXeZRefplff5lhgZtph59yjqV2kaeAmq6FnbGFnrGLorWNpLaQp7mRqLmYrb2essGgs8Klt8apusitvcquv8u2xNC7yNO8ydS8ytTAzdfBzdfM1t7N197Q2eDU3OPX3+XZ4ObZ4ebc4+jf5erg5erg5uvp7fDu8fPv8vTz9fb09vf19/j3+Pn4+fn5+vr6+/v///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRUCYcEgspkwjEKhUVJ1QsBNp0xm2VixiSOMRvlxFGAcTJook5eEHIhQcwpWIkAFQECkNy9AQWFwyEAkPRQ4FAwQIE2llQQAh+QQJCgAvACwAAAAADAAMAIVNcY5SdZFigptph6BvjKN0kKd8lquAmq+EnbGGn7KHn7ONpLaOpbearr+csMCdscCescGhtMOnuMauvsuzws60w862xdC9ytW/y9a/zNbCztjG0drH0tvK1N3M1t7N19/U3ePb4uff5urj6Ozk6e3l6u7m6u7o7PDq7vDt8PPv8vTw8vTw8/X19vf6+vv///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CXcEgsvlytVUplJLJIpSEDUESFTELBwSgCCQEV42kjDFiMo4uQsDB2MkLHoEHUTD7DRAHC8VAiZ0QSCgYIDxhNiUEAOw==":
 IMAGE_PATH+"/spin.gif";Editor.tweetImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAARlJREFUeNpi/P//PwM1ABMDlQDVDGKAeo0biMXwKOMD4ilA/AiInwDxfCBWBeIgINYDmwE1yB2Ir0Alsbl6JchONPwNiC8CsTPIDJjXuIBYG4gPAnE8EDMjGaQCxGFYLOAEYlYg/o3sNSkgfo1k2ykgLgRiIyAOwOIaGE6CmwE1SA6IZ0BNR1f8GY9BXugG2UMN+YtHEzr+Aw0OFINYgHgdCYaA8HUgZkM3CASEoYb9ItKgapQkhGQQKC0dJdKQx1CLsRoEArpAvAuI3+Ix5B8Q+2AkaiyZVgGId+MwBBQhKVhzB9QgKyDuAOJ90BSLzZBzQOyCK5uxQNnXoGlJHogfIOU7UCI9C8SbgHgjEP/ElRkZB115BBBgAPbkvQ/azcC0AAAAAElFTkSuQmCC":
 IMAGE_PATH+"/tweet.png";Editor.facebookImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAARVBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADc6ur3AAAAFnRSTlMAYmRg2KVCC/oPq0uAcVQtHtvZuoYh/a7JUAAAAGJJREFUGNOlzkkOgCAMQNEvagvigBP3P6pRNoCJG/+myVu0RdsqxcQqQ/NFVkKQgqwDzoJ2WKajoB66atcAa0GjX0D8lJHwNGfknYJzY77LDtDZ+L74j0z26pZI2yYlMN9TL17xEd+fl1D+AAAAAElFTkSuQmCC":IMAGE_PATH+"/facebook.png";Editor.blankImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACklEQVR4nGMAAQAABQABDQottAAAAABJRU5ErkJggg==";
-Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
-Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;var b=Graph.prototype.loadStylesheet;Graph.prototype.loadStylesheet=function(){b.apply(this,arguments);
-null!=a.defaultVertexStyle&&this.getStylesheet().putDefaultVertexStyle(a.defaultVertexStyle);null!=a.defaultEdgeStyle&&this.getStylesheet().putDefaultEdgeStyle(a.defaultEdgeStyle)}}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):
-null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,
-this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);
-mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};};var c=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var b=c.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&b.setAttribute("style",this.graph.currentStyle);
-null!=this.graph.backgroundImage&&b.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));b.setAttribute("math",this.graph.mathEnabled?"1":"0");b.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return b};Editor.prototype.isDataSvg=function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),
-null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),
-a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};
-null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var f=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=
-null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;f.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";
-Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX","input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});
-MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,
-b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;
-var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var b=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,c){b.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()};
-var e=ColorDialog.resetRecentColors;ColorDialog.resetRecentColors=function(){e.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):
-this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),
-a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",
-stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=
-function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom=
-"2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=
-mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,
-"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin="0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+
-" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";
-e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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=);";
+Editor.defaultCustomLibraries=[];Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
+Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;if(null!=a.css){var b=document.createElement("style");b.setAttribute("type","text/css");b.appendChild(document.createTextNode(a.css));
+var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}null!=a.defaultLibraries&&(Sidebar.prototype.defaultEntries=a.defaultLibraries);null!=a.defaultCustomLibraries&&(Editor.defaultCustomLibraries=a.defaultCustomLibraries);null!=a.defaultVertexStyle&&(Graph.prototype.defaultVertexStyle=a.defaultVertexStyle);null!=a.defaultEdgeStyle&&(Graph.prototype.defaultEdgeStyle=a.defaultEdgeStyle)}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):
+null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||
+"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=
+c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};
+};var c=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var b=c.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&b.setAttribute("style",this.graph.currentStyle);null!=this.graph.backgroundImage&&b.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));b.setAttribute("math",this.graph.mathEnabled?"1":"0");b.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return b};Editor.prototype.isDataSvg=
+function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),
+d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=
+c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<
+c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var f=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;f.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=
+function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX",
+"input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?
+Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};
+Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,
+'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var b=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,c){b.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()};var e=ColorDialog.resetRecentColors;ColorDialog.resetRecentColors=function(){e.apply(this,arguments);mxSettings.setRecentColors(ColorDialog.recentColors);mxSettings.save()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&
+(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",
+stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,
+{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;
+StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));
+b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,
+f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin=
+"0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=
+0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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(k,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme-1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));var g=document.createElement("div");g.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(k),a.appendChild(g));mxEvent.addListener(g,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme+1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));c(k);c(g);b(this.defaultColorSchemes[this.editorUi.currentScheme]);return a};StyleFormatPanel.prototype.addEditOps=function(a){var b=this.format.getSelectionState(),c=null;1==this.editorUi.editor.graph.getSelectionCount()&&
 (c=mxUtils.button(mxResources.get("editStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("editStyle").funct()})),c.setAttribute("title",mxResources.get("editStyle")+" ("+this.editorUi.actions.get("editStyle").shortcut+")"),c.style.width="202px",c.style.marginBottom="2px",a.appendChild(c));var d=this.editorUi.editor.graph,e=d.view.getState(d.getSelectionCell());1==d.getSelectionCount()&&null!=e&&null!=e.shape&&null!=e.shape.stencil?(b=mxUtils.button(mxResources.get("editShape"),mxUtils.bind(this,
@@ -7870,17 +7871,17 @@ mxResources.get("fitToSheetsAcross"));ba.appendChild(k);mxUtils.write(Y,mxResour
 m.appendChild(v);f.appendChild(m);m=document.createElement("div");k=document.createElement("div");k.style.fontWeight="bold";k.style.marginBottom="12px";mxUtils.write(k,mxResources.get("paperSize"));m.appendChild(k);k=document.createElement("div");k.style.marginBottom="12px";var da=PageSetupDialog.addPageFormatPanel(k,"printdialog",a.editor.graph.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT);m.appendChild(k);k=document.createElement("span");mxUtils.write(k,mxResources.get("pageScale"));m.appendChild(k);
 var aa=document.createElement("input");aa.style.cssText="margin:0 8px 0 8px;";aa.setAttribute("value","100 %");aa.style.width="60px";m.appendChild(aa);f.appendChild(m);k=document.createElement("div");k.style.cssText="text-align:right;margin:62px 0 0 0;";m=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});m.className="geBtn";a.editor.cancelFirst&&k.appendChild(m);a.isOffline()||(v=mxUtils.button(mxResources.get("help"),function(){window.open("https://desk.draw.io/support/solutions/articles/16000048947")}),
 v.className="geBtn",k.appendChild(v));PrintDialog.previewEnabled&&(v=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();d(!1)}),v.className="geBtn",k.appendChild(v));v=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?"print":"ok"),function(){a.hideDialog();d(!0)});v.className="geBtn gePrimaryBtn";k.appendChild(v);a.editor.cancelFirst||k.appendChild(m);f.appendChild(k);this.container=f}})();
-(function(){EditorUi.VERSION="6.7.8";EditorUi.compactUi="atlas"!=uiTheme;EditorUi.enableLogging=/.*\.draw\.io$/.test(window.location.hostname);EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;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.sidebarFooterHeight=
+(function(){EditorUi.VERSION="6.7.9";EditorUi.compactUi="atlas"!=uiTheme;EditorUi.enableLogging=/.*\.draw\.io$/.test(window.location.hostname);EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;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.sidebarFooterHeight=
 36;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.resampleThreshold=
-1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();EditorUi.prototype.getLocalData=
-function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=
-function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,length:c,width:Math.round(c/
-3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=2E9,k.style.left=
-Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+"px")),this.pause=
-mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<
-16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};var a=
-EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
+1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;EditorUi.prototype.formatEnabled="0"!=urlParams.format;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=
+null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();
+EditorUi.prototype.getLocalData=function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,
+length:c,width:Math.round(c/3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=
+2E9,k.style.left=Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+
+"px")),this.pause=mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<
+8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};
+var a=EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
 function(a){if(null!=a&&0<a.length){var b=a.indexOf('<meta charset="utf-8">');0<=b&&(a=a.slice(0,b)+'<meta charset="utf-8"/>'+a.slice(b+23-1,a.length))}return a};EditorUi.prototype.replaceFileData=function(a){a=this.validateFileData(a);a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var b=null!=a?this.editor.extractGraphModel(a,!0):null;null!=b&&(a=b);if(null!=a){b=this.editor.graph;b.model.beginUpdate();try{var c=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 f=this.updatePageRoot(new DiagramPage(d[e]));null==f.getName()&&f.setName(mxResources.get("pageWithNumber",[e+1]));b.model.execute(new ChangePage(this,f,0==e?f: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])),b.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!=c)for(e=0;e<c.length;e++)b.model.execute(new ChangePage(this,c[e],null))}finally{b.model.endUpdate()}}};EditorUi.prototype.createFileData=function(a,b,c,d,e,f,g,u,v,x){b=null!=b?b:this.editor.graph;e=null!=e?e:!1;v=null!=v?v:!0;var k,l=null;null==c||
@@ -7989,17 +7990,17 @@ EditorUi.prototype.createEmbedSvg=function(a,b,c,d,e,f,g){var k=this.editor.grap
 " "+mxResources.get("months");b=Math.floor(a/86400);if(1<b)return b+" "+mxResources.get("days");b=Math.floor(a/3600);if(1<b)return b+" "+mxResources.get("hours");b=Math.floor(a/60);return 1<b?b+" "+mxResources.get("minutes"):1==b?b+" "+mxResources.get("minute"):null};EditorUi.prototype.convertMath=function(a,b,c,d){d()};EditorUi.prototype.getEmbeddedSvg=function(a,b,c,d,e,f,g){g=b.background;g==mxConstants.NONE&&(g=null);b=b.getSvg(g,null,null,null,null,f);null!=a&&b.setAttribute("content",a);null!=
 c&&b.setAttribute("resource",c);if(null!=e)this.convertImages(b,mxUtils.bind(this,function(a){e((d?"":'<?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(d?"":'<?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(b)};EditorUi.prototype.exportImage=function(a,b,c,d,e,f,g,
 u,v){v=null!=v?v:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var k=this.editor.graph.isSelectionEmpty();c=null!=c?c:k;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.exportToCanvas(mxUtils.bind(this,function(a){this.spinner.stop();try{this.saveCanvas(a,e?this.getFileData(!0,null,null,null,c,u):null,v)}catch(A){"Invalid image"==A.message?this.downloadFile(v):this.handleError(A)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();
-this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,u,v,x,z,A,B,y){f=null!=f?f:!0;A=null!=A?A:this.editor.graph;B=null!=B?B:0;var k=v?null:A.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==v&&(k="#ffffff");this.convertImages(A.getSvg(k,null,null,y,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){var e=document.createElement("canvas"),
-g=parseInt(c.getAttribute("width")),l=parseInt(c.getAttribute("height"));u=null!=u?u:1;null!=b&&(u=f?Math.min(1,Math.min(3*b/(4*l),b/g)):b/g);g=Math.ceil(u*g)+2*B;l=Math.ceil(u*l)+2*B;e.setAttribute("width",g);e.setAttribute("height",l);var m=e.getContext("2d");null!=k&&(m.beginPath(),m.rect(0,0,g,l),m.fillStyle=k,m.fill());m.scale(u,u);m.drawImage(d,B/u,B/u);a(e)});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(A,c,!0,mxUtils.bind(this,function(){d.src=
-this.createSvgDataUri(mxUtils.getXml(c))}))}catch(D){null!=e&&e(D)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=function(a,b,
-c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,k){for(var g=a.getElementsByTagName(c),l=0;l<g.length;l++)mxUtils.bind(this,function(c){var g=d.convert(c.getAttribute(k));if(null!=g&&"data:"!=g.substring(0,5)){var l=f[g];null==l?(e++,this.convertImageToDataUri(g,function(d){null!=d&&(f[g]=d,c.setAttribute(k,d));e--;0==e&&b(a)})):c.setAttribute(k,l)}})(g[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=function(a){return"https?://raw.githubusercontent.com/"===
-a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=
-function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var k=this.editor.graph;if(null!=a&&0<a.length){var g=mxUtils.parseXml(a),l=this.editor.extractGraphModel(g.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(k.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){k.model.beginUpdate();try{for(var n=0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),
-B=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[B+1]));k.model.execute(new ChangePage(this,p,p,B))}}finally{k.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var y=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,y);var C=y.getChildCount(y.getRoot());k.model.getChildCount(k.model.getRoot());k.model.beginUpdate();try{a={};for(n=0;n<C;n++){var E=y.getChildAt(y.getRoot(),n);if(1!=C||k.isCellLocked(k.getDefaultParent()))E=k.importCells([E],0,0,k.model.getRoot(),
-null,a)[0],F=k.model.getChildren(E),k.moveCells(F,b,c),f=f.concat(F);else var F=y.getChildren(E),f=f.concat(k.importCells(F,b,c,k.getDefaultParent(),null,a))}if(d){k.isGridEnabled()&&(b=k.snap(b),c=k.snap(c));var D=k.getBoundingBoxFromGeometry(f,!0);null!=D&&k.moveCells(f,b-D.x,c-D.y)}}finally{k.model.endUpdate()}}}}catch(K){throw e||this.handleError(K,mxResources.get("invalidOrMissingFile")),K;}return f};EditorUi.prototype.insertLucidChart=function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,
-b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var k=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var g=this.extractGraphModelFromPng(a),l=this.importXml(g,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,19))try{if(g=null,"data:image/svg+xml;base64,"==a.substring(0,
-26)?(g=a.substring(a.indexOf(",")+1),g=window.atob&&!mxClient.IS_SF?atob(g):Base64.decode(g,!0)):g=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(g,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){k.setSelectionCell(k.insertVertex(null,null,"",k.snap(b),k.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
+this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,u,v,x,z,A,B,y){f=null!=f?f:!0;A=null!=A?A:this.editor.graph;B=null!=B?B:0;var k=v?null:A.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==v&&(k="#ffffff");this.convertImages(A.getSvg(k,null,null,y,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){try{var g=document.createElement("canvas"),
+l=parseInt(c.getAttribute("width")),m=parseInt(c.getAttribute("height"));u=null!=u?u:1;null!=b&&(u=f?Math.min(1,Math.min(3*b/(4*m),b/l)):b/l);l=Math.ceil(u*l)+2*B;m=Math.ceil(u*m)+2*B;g.setAttribute("width",l);g.setAttribute("height",m);var n=g.getContext("2d");null!=k&&(n.beginPath(),n.rect(0,0,l,m),n.fillStyle=k,n.fill());n.scale(u,u);n.drawImage(d,B/u,B/u);a(g)}catch(I){null!=e&&e(I)}});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(A,c,!0,mxUtils.bind(this,
+function(){d.src=this.createSvgDataUri(mxUtils.getXml(c))}))}catch(D){null!=e&&e(D)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=
+function(a,b,c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,k){for(var g=a.getElementsByTagName(c),l=0;l<g.length;l++)mxUtils.bind(this,function(c){var g=d.convert(c.getAttribute(k));if(null!=g&&"data:"!=g.substring(0,5)){var l=f[g];null==l?(e++,this.convertImageToDataUri(g,function(d){null!=d&&(f[g]=d,c.setAttribute(k,d));e--;0==e&&b(a)})):c.setAttribute(k,l)}})(g[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=
+function(a){return"https?://raw.githubusercontent.com/"===a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};
+c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var k=this.editor.graph;if(null!=a&&0<a.length){var g=mxUtils.parseXml(a),l=this.editor.extractGraphModel(g.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(k.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){k.model.beginUpdate();try{for(var n=
+0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),B=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[B+1]));k.model.execute(new ChangePage(this,p,p,B))}}finally{k.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var y=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,y);var C=y.getChildCount(y.getRoot());k.model.getChildCount(k.model.getRoot());k.model.beginUpdate();try{a={};for(n=0;n<C;n++){var E=y.getChildAt(y.getRoot(),n);if(1!=
+C||k.isCellLocked(k.getDefaultParent()))E=k.importCells([E],0,0,k.model.getRoot(),null,a)[0],F=k.model.getChildren(E),k.moveCells(F,b,c),f=f.concat(F);else var F=y.getChildren(E),f=f.concat(k.importCells(F,b,c,k.getDefaultParent(),null,a))}if(d){k.isGridEnabled()&&(b=k.snap(b),c=k.snap(c));var D=k.getBoundingBoxFromGeometry(f,!0);null!=D&&k.moveCells(f,b-D.x,c-D.y)}}finally{k.model.endUpdate()}}}}catch(K){throw e||this.handleError(K,mxResources.get("invalidOrMissingFile")),K;}return f};EditorUi.prototype.insertLucidChart=
+function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var k=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var g=this.extractGraphModelFromPng(a),l=this.importXml(g,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,
+19))try{if(g=null,"data:image/svg+xml;base64,"==a.substring(0,26)?(g=a.substring(a.indexOf(",")+1),g=window.atob&&!mxClient.IS_SF?atob(g):Base64.decode(g,!0)):g=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(g,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){k.setSelectionCell(k.insertVertex(null,null,"",k.snap(b),k.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
 this.convertDataUri(a)+";"))}),!0,this.maxImageSize);else{var e=Math.min(1,Math.min(this.maxImageSize/d.width,this.maxImageSize/d.height)),f=Math.round(d.width*e);d=Math.round(d.height*e);k.setSelectionCell(k.insertVertex(null,null,"",k.snap(b),k.snap(c),f,d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";"))}}),mxUtils.bind(this,function(){var e=null;k.getModel().beginUpdate();try{e=k.insertVertex(k.getDefaultParent(),
 null,a,k.snap(b),k.snap(c),1,1,"text;"+(d?"html=1;":"")),k.updateCellSize(e),k.fireEvent(new mxEventObject("textInserted","cells",[e]))}finally{k.getModel().endUpdate()}k.setSelectionCell(e)}))}else{a=this.editor.graph.zapGremlins(mxUtils.trim(a));if(this.isCompatibleString(a))return this.importXml(a,b,c,f);if(0<a.length)if('{"state":"{\\"Properties\\":'==a.substring(0,26)){e=JSON.parse(JSON.parse(a).state);var g=null,m;for(m in e.Pages)if(l=e.Pages[m],null!=l&&"0"==l.Properties.Order){g=l;break}null!=
 g&&this.insertLucidChart(g,b,c,f)}else{k=this.editor.graph;f=null;k.getModel().beginUpdate();try{f=k.insertVertex(k.getDefaultParent(),null,"",k.snap(b),k.snap(c),1,1,"text;"+(d?"html=1;":"")),k.fireEvent(new mxEventObject("textInserted","cells",[f])),f.value=a,k.updateCellSize(f),/\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/i.test(f.value)&&
@@ -8021,11 +8022,11 @@ for(var c=0;256>c;c++)for(var f=c,d=0;8>d;d++)f=1==(f&1)?3988292384^f>>>1:f>>>1,
 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 l=0;if(f(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=e&&e();else if(f(a,4),"IHDR"!=f(a,4))null!=e&&e();else{f(a,17);e=a.substring(0,l);do{var m=k(a);if("IDAT"==f(a,4)){e=a.substring(0,l-8);c=c+String.fromCharCode(0)+("zTXt"==b?String.fromCharCode(0):"")+d;d=4294967295;d=this.updateCRC(d,b,0,4);d=this.updateCRC(d,c,0,c.length);e+=g(c.length)+b+c+g(d^4294967295);
 e+=a.substring(l-8,a.length);break}e+=a.substring(l-8,l-4+m);d=f(a,m);f(a,4)}while(m);return"data:image/png;base64,"+(window.btoa?btoa(e):Base64.encode(e,!0))}};EditorUi.prototype.extractGraphModelFromPng=function(a){var b=null;try{var c=a.substring(a.indexOf(",")+1),d=window.atob&&!mxClient.IS_SF?atob(c):Base64.decode(c,!0);EditorUi.parsePng(d,mxUtils.bind(this,function(a,c,e){a=d.substring(a+8,a+8+e);"zTXt"==c?(e=a.indexOf(String.fromCharCode(0)),"mxGraphModel"==a.substring(0,e)&&(a=this.editor.graph.bytesToString(pako.inflateRaw(a.substring(e+
 2))).replace(/\+/g," "),null!=a&&0<a.length&&(b=a))):"tEXt"==c&&(a=a.split(String.fromCharCode(0)),1<a.length&&"mxGraphModel"==a[0]&&(b=a[1]));if(null!=b||"IDAT"==c)return!0}))}catch(p){}null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));return b};EditorUi.prototype.loadImage=function(a,b,c){var d=new Image;d.onload=function(){b(d)};null!=c&&(d.onerror=c);d.src=a};var b=EditorUi.prototype.init;EditorUi.prototype.init=function(){function a(a){var b=
-a.indexOf(",");0<b&&(a=c.getPageById(a.substring(b+1)))&&c.selectPage(a)}var c=this,d=this.editor.graph,e=d.addClickHandler;d.addClickHandler=function(b,c,f){var k=c;c=function(b,c){if(null==c){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(c=e.getAttribute("href"))}null!=c&&d.isPageLink(c)&&(a(c),mxEvent.consume(b));null!=k&&k(b)};e.call(this,b,c,f)};b.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(d.view.canvas.ownerSVGElement,null,!0);c.actions.get("print").funct=
-function(){c.showDialog((new PrintDialog(c)).container,360,null!=c.pages&&1<c.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=d.getGlobalVariable;d.getGlobalVariable=function(a){return"page"==a&&null!=c.currentPage?c.currentPage.getName():"pagenumber"==a?null!=c.currentPage&&null!=c.pages?mxUtils.indexOf(c.pages,c.currentPage)+1:1:f.apply(this,arguments)};var g=d.createLinkForHint;d.createLinkForHint=function(b,e){var f=d.isPageLink(b);if(f){var k=b.indexOf(",");
-0<k&&(k=c.getPageById(b.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(c){a(b);mxEvent.consume(c)});return k};var t=d.labelLinkClicked;d.labelLinkClicked=function(b,c,e){var f=c.getAttribute("href");d.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=c.defaultFilename,b=c.getCurrentFile();null!=b&&(a=null!=b.getTitle()?b.getTitle():a);return a};
-var u=this.actions.get("print");u.setEnabled(!mxClient.IS_IOS||!navigator.standalone);u.visible=u.isEnabled();if(!this.editor.chromeless){var v=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||d.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var k=f[index];if("file"===k.kind){if(b.isEditing())this.importFiles([k.getAsFile()],
+a.indexOf(",");0<b&&(a=c.getPageById(a.substring(b+1)))&&c.selectPage(a)}"undefined"!==typeof window.mxSettings&&(this.formatWidth=mxSettings.getFormatWidth());var c=this,d=this.editor.graph,e=d.addClickHandler;d.addClickHandler=function(b,c,f){var k=c;c=function(b,c){if(null==c){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(c=e.getAttribute("href"))}null!=c&&d.isPageLink(c)&&(a(c),mxEvent.consume(b));null!=k&&k(b)};e.call(this,b,c,f)};b.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(d.view.canvas.ownerSVGElement,
+null,!0);c.actions.get("print").funct=function(){c.showDialog((new PrintDialog(c)).container,360,null!=c.pages&&1<c.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=d.getGlobalVariable;d.getGlobalVariable=function(a){return"page"==a&&null!=c.currentPage?c.currentPage.getName():"pagenumber"==a?null!=c.currentPage&&null!=c.pages?mxUtils.indexOf(c.pages,c.currentPage)+1:1:f.apply(this,arguments)};var g=d.createLinkForHint;d.createLinkForHint=function(b,e){var f=
+d.isPageLink(b);if(f){var k=b.indexOf(",");0<k&&(k=c.getPageById(b.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(c){a(b);mxEvent.consume(c)});return k};var t=d.labelLinkClicked;d.labelLinkClicked=function(b,c,e){var f=c.getAttribute("href");d.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=c.defaultFilename,b=c.getCurrentFile();null!=b&&(a=
+null!=b.getTitle()?b.getTitle():a);return a};var u=this.actions.get("print");u.setEnabled(!mxClient.IS_IOS||!navigator.standalone);u.visible=u.isEnabled();if(!this.editor.chromeless){var v=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||d.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var k=f[index];if("file"===k.kind){if(b.isEditing())this.importFiles([k.getAsFile()],
 0,0,this.maxImageSize,function(a,c,d,e,f,k){b.insertImage(a,f,k)},function(){},function(a){return"image/"==a.type.substring(0,6)},function(a){for(var b=0;b<a.length;b++)a[b]()});else{var g=this.editor.graph.getInsertPoint();this.importFiles([k.getAsFile()],g.x,g.y,this.maxImageSize);mxEvent.consume(a)}break}}}}catch(L){}}),!1);var x=document.createElement("div");x.style.position="absolute";x.style.whiteSpace="nowrap";x.style.overflow="hidden";x.style.display="block";x.contentEditable=!0;mxUtils.setOpacity(x,
 0);x.style.width="1px";x.style.height="1px";x.innerHTML="&nbsp;";var z=!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 b=mxEvent.getSource(a);null==d.container||!d.isEnabled()||d.isMouseDown||d.isEditing()||null!=this.dialog||"INPUT"==b.nodeName||"TEXTAREA"==b.nodeName||!(224==a.keyCode||!mxClient.IS_MAC&&17==a.keyCode||mxClient.IS_MAC&&91==a.keyCode)||
 z||(x.style.left=d.container.scrollLeft+10+"px",x.style.top=d.container.scrollTop+10+"px",d.container.appendChild(x),z=!0,mxClient.IS_QUIRKS?window.setTimeout(function(){x.focus();document.execCommand("selectAll",!1,null)},0):(x.focus(),document.execCommand("selectAll",!1,null)))}));mxEvent.addListener(document,"keyup",mxUtils.bind(this,function(a){var b=a.keyCode;window.setTimeout(mxUtils.bind(this,function(){!z||224!=b&&17!=b&&91!=b||(z=!1,d.isEditing()||null!=this.dialog||null==d.container||d.container.focus(),
@@ -8040,98 +8041,105 @@ null;mxEvent.addListener(d.container,"dragleave",function(a){d.isEnabled()&&(nul
 y=null);if(d.isEnabled()){var b=mxUtils.convertPoint(d.container,mxEvent.getClientX(a),mxEvent.getClientY(a)),c=d.view.translate,e=d.view.scale,f=b.x/e-c.x,k=b.y/e-c.y;mxEvent.isAltDown(a)&&(k=f=0);if(0<a.dataTransfer.files.length)this.importFiles(a.dataTransfer.files,f,k,this.maxImageSize,null,null,null,null,!mxEvent.isControlDown(a),null,null,mxEvent.isShiftDown(a));else{var g=0<=mxUtils.indexOf(a.dataTransfer.types,"text/uri-list")?a.dataTransfer.getData("text/uri-list"):null,b=this.extractGraphModelFromEvent(a,
 null!=this.pages);if(null!=b)d.setSelectionCells(this.importXml(b,f,k,!0));else if(0<=mxUtils.indexOf(a.dataTransfer.types,"text/html")){b=a.dataTransfer.getData("text/html");e=document.createElement("div");e.innerHTML=b;var c=null,l=e.getElementsByTagName("img");null!=l&&1==l.length?(b=l[0].getAttribute("src"),/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(b)||(c=!0)):(e=e.getElementsByTagName("a"),null!=e&&1==e.length&&(b=e[0].getAttribute("href")));d.setSelectionCells(this.insertTextAt(b,f,k,!0,c))}else null!=
 g&&/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(g)?this.loadImage(decodeURIComponent(g),mxUtils.bind(this,function(a){var b=Math.max(1,a.width);a=Math.max(1,a.height);var c=this.maxImageSize,c=Math.min(1,Math.min(c/Math.max(1,b)),c/Math.max(1,a));d.setSelectionCell(d.insertVertex(null,null,"",f,k,b*c,a*c,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+g+";"))}),mxUtils.bind(this,function(a){d.setSelectionCells(this.insertTextAt(g,
-f,k,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&d.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,k,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode()};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,
-encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=
-this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var k=e.lastIndexOf("%3E");0<=k&&k<e.length-3&&(e=e.substring(0,k+3))}catch(v){}try{var c=b.getElementsByTagName("span"),g=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(g)&&(f=!0,e=g)}catch(v){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=
-e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(v){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=
-null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,
-function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;
-var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?
-this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=
-0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?
-this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(u){this.handleError(u,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,
-d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,
-a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),
-this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),
-c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=
-null!=c?c:!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 b=
-this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,
-f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function g(a){if(null!=a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(J){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(H){l=null}if(null==l)return;
-if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&k.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?
-mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):g(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",
-result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(H){k.postMessage(JSON.stringify({event:"draft",error:H.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?
-k.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=
-l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,
-t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;k.postMessage(JSON.stringify(b),"*")}),u=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=
-this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),F=q.getGlobalVariable,D=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?D.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(D.root)}this.exportToCanvas(mxUtils.bind(this,function(a){u(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){u(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+
-("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):u(null)}),mxUtils.bind(this,function(){u(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=
-this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),
-"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);k.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));k.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),
-this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=this.createSvgDataUri(m)}k.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight=
-"12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight="38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{k.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=g(l);c=!0;try{a(l,f)}catch(H){this.handleError(H)}c=!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==b&&(b=mxUtils.bind(this,function(a,b){var d=K();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",
-b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||k.postMessage(JSON.stringify(this.createLoadMessage("load")),
-"*")}));var k=window.opener||window.parent,f="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";k.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",
-mxResources.get("save")+" (Ctrl+S)");b.className="geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor=
-"pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=
-a.split("\n"),c=[];if(0<b.length){var d={},e=null,f=null,k="auto",g="auto",v=40,x=40,z=0,A=this.editor.graph;A.getGraphBounds();for(var B=function(){A.setSelectionCells(R);A.scrollCellToVisible(A.getSelectionCell())},y=A.getFreeInsertPoint(),C=y.x,E=y.y,y=E,F=null,D="auto",K=[],H=null,J=null,I=0;I<b.length&&"#"==b[I].charAt(0);){a=b[I];for(I++;I<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[I].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[I].substring(1)),I++;if("#"!=a.charAt(1)){var L=a.indexOf(":");
-if(0<L){var M=mxUtils.trim(a.substring(1,L)),Q=mxUtils.trim(a.substring(L+1));"label"==M?F=A.sanitizeHtml(Q):"style"==M?e=Q:"identity"==M&&0<Q.length&&"-"!=Q?f=Q:"width"==M?k=Q:"height"==M?g=Q:"ignore"==M?J=Q.split(","):"connect"==M?K.push(JSON.parse(Q)):"link"==M?H=Q:"padding"==M?z=parseFloat(Q):"edgespacing"==M?v=parseFloat(Q):"nodespacing"==M?x=parseFloat(Q):"layout"==M&&(D=Q)}}}var W=this.editor.csvToArray(b[I]);a=null;if(null!=f)for(var N=0;N<W.length;N++)if(f==W[N]){a=N;break}null==F&&(F="%"+
-W[0]+"%");if(null!=K)for(var G=0;G<K.length;G++)null==d[K[G].to]&&(d[K[G].to]={});A.model.beginUpdate();try{for(N=I+1;N<b.length;N++){var V=this.editor.csvToArray(b[N]);if(V.length==W.length){var O=null,ba=null!=a?V[a]:null;null!=ba&&(O=A.model.getCell(ba));null==O&&(O=new mxCell(F,new mxGeometry(C,y,0,0),e||"whiteSpace=wrap;html=1;"),O.vertex=!0,O.id=ba);for(var Y=0;Y<V.length;Y++)A.setAttributeForCell(O,W[Y],V[Y]);A.setAttributeForCell(O,"placeholders","1");O.style=A.replacePlaceholders(O,O.style);
-for(G=0;G<K.length;G++)d[K[G].to][O.getAttribute(K[G].to)]=O;null!=H&&"link"!=H&&(A.setLinkForCell(O,O.getAttribute(H)),A.setAttributeForCell(O,H,null));var S=this.editor.graph.getPreferredSizeForCell(O);O.geometry.width="auto"==k?S.width+z:parseFloat(k);O.geometry.height="auto"==g?S.height+z:parseFloat(g);y+=O.geometry.height+x;c.push(A.addCell(O))}}null==e&&A.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var P=c.slice(),R=c.slice(),G=0;G<K.length;G++)for(var X=K[G],N=0;N<c.length;N++){var O=
-c[N],da=O.getAttribute(X.from);if(null!=da){A.setAttributeForCell(O,X.from,null);for(var aa=da.split(","),Y=0;Y<aa.length;Y++){var T=d[X.to][aa[Y]];null!=T&&(R.push(A.insertEdge(null,null,X.label||"",X.invert?T:O,X.invert?O:T,X.style||A.createCurrentEdgeStyle())),mxUtils.remove(X.invert?O:T,P))}}}if(null!=J)for(N=0;N<c.length;N++)for(O=c[N],Y=0;Y<J.length;Y++)A.setAttributeForCell(O,mxUtils.trim(J[Y]),null);var ca=new mxParallelEdgeLayout(A);ca.spacing=v;var ea=function(){ca.execute(A.getDefaultParent());
-for(var a=0;a<c.length;a++){var b=A.getCellGeometry(c[a]);b.x=Math.round(A.snap(b.x));b.y=Math.round(A.snap(b.y));"auto"==k&&(b.width=Math.round(A.snap(b.width)));"auto"==g&&(b.height=Math.round(A.snap(b.height)))}};if("circle"==D){var U=new mxCircleLayout(A);U.resetEdges=!1;var Z=U.isVertexIgnored;U.isVertexIgnored=function(a){return Z.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){U.execute(A.getDefaultParent());ea()},!0,B);B=null}else if("horizontaltree"==D||"verticaltree"==
-D||"auto"==D&&R.length==2*c.length-1&&1==P.length){A.view.validate();var ga=new mxCompactTreeLayout(A,"horizontaltree"==D);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(A.getDefaultParent(),0<P.length?P[0]:null)},!0,B);B=null}else if("horizontalflow"==D||"verticalflow"==D||"auto"==D&&1==P.length){A.view.validate();var fa=new mxHierarchicalLayout(A,"horizontalflow"==D?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);fa.intraCellSpacing=x;fa.disableEdgeStyle=
-!1;this.executeLayout(function(){fa.execute(A.getDefaultParent(),R);A.moveCells(R,C,E)},!0,B);B=null}else if("organic"==D||"auto"==D&&R.length>c.length){A.view.validate();var ka=new mxFastOrganicLayout(A);ka.forceConstant=3*x;ka.resetEdges=!1;var ja=ka.isVertexIgnored;ka.isVertexIgnored=function(a){return ja.apply(this,arguments)||0>mxUtils.indexOf(c,a)};ca=new mxParallelEdgeLayout(A);ca.spacing=v;this.executeLayout(function(){ka.execute(A.getDefaultParent());ea()},!0,B);B=null}this.hideDialog()}finally{A.model.endUpdate()}null!=
-B&&B()}}catch(la){this.handleError(la)}};EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
+f,k,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&d.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,k,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode();"undefined"!==typeof window.mxSettings&&this.installSettings()};EditorUi.prototype.installSettings=function(){if(isLocalStorage||mxClient.IS_CHROMEAPP)ColorDialog.recentColors=mxSettings.getRecentColors(),this.editor.graph.currentEdgeStyle=
+mxSettings.getCurrentEdgeStyle(),this.editor.graph.currentVertexStyle=mxSettings.getCurrentVertexStyle(),this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[])),this.addListener("styleChanged",mxUtils.bind(this,function(a,b){mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);mxSettings.save()})),this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget()),this.fireEvent(new mxEventObject("copyConnectChanged")),
+this.addListener("copyConnectChanged",mxUtils.bind(this,function(a,b){mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());mxSettings.save()})),this.editor.graph.pageFormat=mxSettings.getPageFormat(),this.addListener("pageFormatChanged",mxUtils.bind(this,function(a,b){mxSettings.setPageFormat(this.editor.graph.pageFormat);mxSettings.save()})),this.editor.graph.view.gridColor=mxSettings.getGridColor(),this.addListener("gridColorChanged",mxUtils.bind(this,function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor);
+mxSettings.save()})),mxClient.IS_CHROMEAPP&&(this.editor.addListener("autosaveChanged",mxUtils.bind(this,function(a,b){mxSettings.setAutosave(this.editor.autosave);mxSettings.save()})),this.editor.autosave=mxSettings.getAutosave()),null!=this.sidebar&&this.sidebar.showPalette("search",mxSettings.settings.search),!this.editor.chromeless&&null!=this.sidebar&&(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))&&(this.toggleScratchpad(),mxSettings.save()),this.addListener("formatWidthChanged",
+function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=
+function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var k=e.lastIndexOf("%3E");0<=k&&k<e.length-3&&(e=e.substring(0,
+k+3))}catch(v){}try{var c=b.getElementsByTagName("span"),g=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(g)&&(f=!0,e=g)}catch(v){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),
+d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(v){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],
+"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&
+(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&
+(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-
+3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=
+function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,
+d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},
+mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(u){this.handleError(u,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,
+5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?
+(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),
+a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),
+f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=null!=c?c:!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 b=this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,
+scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function g(a){if(null!=
+a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(J){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(H){l=null}if(null==l)return;if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,
+null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&k.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();
+return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):g(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();k.postMessage(JSON.stringify({event:"draft",result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):
+null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(H){k.postMessage(JSON.stringify({event:"draft",error:H.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?k.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,
+name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=
+null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();
+var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;k.postMessage(JSON.stringify(b),"*")}),u=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),
+F=q.getGlobalVariable,D=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?D.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(D.root)}this.exportToCanvas(mxUtils.bind(this,function(a){u(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){u(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,
+function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):u(null)}),mxUtils.bind(this,function(){u(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),
+n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,
+function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);k.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));k.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=
+this.createSvgDataUri(m)}k.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight="12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight=
+"38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{k.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=g(l);c=!0;try{a(l,f)}catch(H){this.handleError(H)}c=!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==b&&(b=mxUtils.bind(this,function(a,b){var d=K();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",
+b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||k.postMessage(JSON.stringify(this.createLoadMessage("load")),"*")}));var k=window.opener||window.parent,f="json"==
+urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";k.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",mxResources.get("save")+" (Ctrl+S)");b.className=
+"geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor="pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=a.split("\n"),c=[];if(0<b.length){var d={},e=
+null,f=null,k="auto",g="auto",v=40,x=40,z=0,A=this.editor.graph;A.getGraphBounds();for(var B=function(){A.setSelectionCells(R);A.scrollCellToVisible(A.getSelectionCell())},y=A.getFreeInsertPoint(),C=y.x,E=y.y,y=E,F=null,D="auto",K=[],H=null,J=null,I=0;I<b.length&&"#"==b[I].charAt(0);){a=b[I];for(I++;I<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[I].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[I].substring(1)),I++;if("#"!=a.charAt(1)){var L=a.indexOf(":");if(0<L){var M=mxUtils.trim(a.substring(1,
+L)),Q=mxUtils.trim(a.substring(L+1));"label"==M?F=A.sanitizeHtml(Q):"style"==M?e=Q:"identity"==M&&0<Q.length&&"-"!=Q?f=Q:"width"==M?k=Q:"height"==M?g=Q:"ignore"==M?J=Q.split(","):"connect"==M?K.push(JSON.parse(Q)):"link"==M?H=Q:"padding"==M?z=parseFloat(Q):"edgespacing"==M?v=parseFloat(Q):"nodespacing"==M?x=parseFloat(Q):"layout"==M&&(D=Q)}}}var W=this.editor.csvToArray(b[I]);a=null;if(null!=f)for(var N=0;N<W.length;N++)if(f==W[N]){a=N;break}null==F&&(F="%"+W[0]+"%");if(null!=K)for(var G=0;G<K.length;G++)null==
+d[K[G].to]&&(d[K[G].to]={});A.model.beginUpdate();try{for(N=I+1;N<b.length;N++){var V=this.editor.csvToArray(b[N]);if(V.length==W.length){var O=null,ba=null!=a?V[a]:null;null!=ba&&(O=A.model.getCell(ba));null==O&&(O=new mxCell(F,new mxGeometry(C,y,0,0),e||"whiteSpace=wrap;html=1;"),O.vertex=!0,O.id=ba);for(var Y=0;Y<V.length;Y++)A.setAttributeForCell(O,W[Y],V[Y]);A.setAttributeForCell(O,"placeholders","1");O.style=A.replacePlaceholders(O,O.style);for(G=0;G<K.length;G++)d[K[G].to][O.getAttribute(K[G].to)]=
+O;null!=H&&"link"!=H&&(A.setLinkForCell(O,O.getAttribute(H)),A.setAttributeForCell(O,H,null));var S=this.editor.graph.getPreferredSizeForCell(O);O.geometry.width="auto"==k?S.width+z:parseFloat(k);O.geometry.height="auto"==g?S.height+z:parseFloat(g);y+=O.geometry.height+x;c.push(A.addCell(O))}}null==e&&A.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var P=c.slice(),R=c.slice(),G=0;G<K.length;G++)for(var X=K[G],N=0;N<c.length;N++){var O=c[N],da=O.getAttribute(X.from);if(null!=da){A.setAttributeForCell(O,
+X.from,null);for(var aa=da.split(","),Y=0;Y<aa.length;Y++){var T=d[X.to][aa[Y]];null!=T&&(R.push(A.insertEdge(null,null,X.label||"",X.invert?T:O,X.invert?O:T,X.style||A.createCurrentEdgeStyle())),mxUtils.remove(X.invert?O:T,P))}}}if(null!=J)for(N=0;N<c.length;N++)for(O=c[N],Y=0;Y<J.length;Y++)A.setAttributeForCell(O,mxUtils.trim(J[Y]),null);var ca=new mxParallelEdgeLayout(A);ca.spacing=v;var ea=function(){ca.execute(A.getDefaultParent());for(var a=0;a<c.length;a++){var b=A.getCellGeometry(c[a]);b.x=
+Math.round(A.snap(b.x));b.y=Math.round(A.snap(b.y));"auto"==k&&(b.width=Math.round(A.snap(b.width)));"auto"==g&&(b.height=Math.round(A.snap(b.height)))}};if("circle"==D){var U=new mxCircleLayout(A);U.resetEdges=!1;var Z=U.isVertexIgnored;U.isVertexIgnored=function(a){return Z.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){U.execute(A.getDefaultParent());ea()},!0,B);B=null}else if("horizontaltree"==D||"verticaltree"==D||"auto"==D&&R.length==2*c.length-1&&1==P.length){A.view.validate();
+var ga=new mxCompactTreeLayout(A,"horizontaltree"==D);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(A.getDefaultParent(),0<P.length?P[0]:null)},!0,B);B=null}else if("horizontalflow"==D||"verticalflow"==D||"auto"==D&&1==P.length){A.view.validate();var fa=new mxHierarchicalLayout(A,"horizontalflow"==D?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);fa.intraCellSpacing=x;fa.disableEdgeStyle=!1;this.executeLayout(function(){fa.execute(A.getDefaultParent(),
+R);A.moveCells(R,C,E)},!0,B);B=null}else if("organic"==D||"auto"==D&&R.length>c.length){A.view.validate();var ka=new mxFastOrganicLayout(A);ka.forceConstant=3*x;ka.resetEdges=!1;var ja=ka.isVertexIgnored;ka.isVertexIgnored=function(a){return ja.apply(this,arguments)||0>mxUtils.indexOf(c,a)};ca=new mxParallelEdgeLayout(A);ca.spacing=v;this.executeLayout(function(){ka.execute(A.getDefaultParent());ea()},!0,B);B=null}this.hideDialog()}finally{A.model.endUpdate()}null!=B&&B()}}catch(la){this.handleError(la)}};
+EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
 d;for(d in urlParams)0>mxUtils.indexOf(c,d)&&(a=0==b?a+"?":a+"&",null!=urlParams[d]&&(a+=d+"="+urlParams[d],b++))}return a};EditorUi.prototype.showLinkDialog=function(a,b,c){a=new LinkDialog(this,a,b,c,!0);this.showDialog(a.container,420,120,!0,!0);a.init()};var e=EditorUi.prototype.createOutline;EditorUi.prototype.createOutline=function(a){var b=e.apply(this,arguments),c=this.editor.graph,d=b.getSourceGraphBounds;b.getSourceGraphBounds=function(){if(mxUtils.hasScrollbars(c.container)&&c.pageVisible&&
 null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width-2*a.x/b),Math.ceil(this.source.minimumGraphSize.height-2*a.y/b))}return d.apply(this,arguments)};var f=b.getSourceContainerSize;b.getSourceContainerSize=function(){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width*
 b-2*a.x),Math.ceil(this.source.minimumGraphSize.height*b-2*a.y))}return f.apply(this,arguments)};b.getOutlineOffset=function(a){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var d=this.source.getPagePadding();return new mxPoint(Math.round(Math.max(0,(b.outline.container.clientWidth/a-(this.source.minimumGraphSize.width-2*d.x))/2)-d.x),Math.round(Math.max(0,(b.outline.container.clientHeight/a-(this.source.minimumGraphSize.height-2*d.y))/2)-d.y-5/a))}return new mxPoint(8/
-a,8/a)};var k=b.init;b.init=function(){k.apply(this,arguments);b.outline.view.getBackgroundPageBounds=function(){var a=c.getPageLayout(),b=c.getPageSize();return new mxRectangle(this.scale*(this.translate.x+a.x*b.width),this.scale*(this.translate.y+a.y*b.height),this.scale*a.width*b.width,this.scale*a.height*b.height)};b.outline.view.validateBackgroundPage()};this.editor.addListener("pageSelected",function(a,c){var d=c.getProperty("change"),e=b.source,f=b.outline;f.pageScale=e.pageScale;f.pageFormat=
-e.pageFormat;f.background=e.background;f.pageVisible=e.pageVisible;f.background=e.background;var k=mxUtils.getCurrentStyle(e.container);f.container.style.backgroundColor=k.backgroundColor;null!=e.view.backgroundPageShape&&null!=f.view.backgroundPageShape&&(f.view.backgroundPageShape.fill=e.view.backgroundPageShape.fill);b.outline.view.clear(d.previousPage.root,!0);b.outline.view.validate()});return b};EditorUi.prototype.getServiceCount=function(a){var b=0;null==this.drive&&"function"!==typeof window.DriveClient||
+a,8/a)};var g=b.init;b.init=function(){g.apply(this,arguments);b.outline.view.getBackgroundPageBounds=function(){var a=c.getPageLayout(),b=c.getPageSize();return new mxRectangle(this.scale*(this.translate.x+a.x*b.width),this.scale*(this.translate.y+a.y*b.height),this.scale*a.width*b.width,this.scale*a.height*b.height)};b.outline.view.validateBackgroundPage()};this.editor.addListener("pageSelected",function(a,c){var d=c.getProperty("change"),e=b.source,f=b.outline;f.pageScale=e.pageScale;f.pageFormat=
+e.pageFormat;f.background=e.background;f.pageVisible=e.pageVisible;f.background=e.background;var g=mxUtils.getCurrentStyle(e.container);f.container.style.backgroundColor=g.backgroundColor;null!=e.view.backgroundPageShape&&null!=f.view.backgroundPageShape&&(f.view.backgroundPageShape.fill=e.view.backgroundPageShape.fill);b.outline.view.clear(d.previousPage.root,!0);b.outline.view.validate()});return b};EditorUi.prototype.getServiceCount=function(a){var b=0;null==this.drive&&"function"!==typeof window.DriveClient||
 b++;null==this.dropbox&&"function"!==typeof window.DropboxClient||b++;null==this.oneDrive&&"function"!==typeof window.OneDriveClient||b++;null!=this.gitHub&&b++;a&&isLocalStorage&&("1"==urlParams.browser||mxClient.IS_IOS)&&b++;mxClient.IS_IOS||b++;return b};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 c=("1"!=urlParams.embed||!this.editor.graph.isEnabled())&&(null==a||a.isRestricted());this.actions.get("makeCopy").setEnabled(!c);this.actions.get("print").setEnabled(!c);this.menus.get("exportAs").setEnabled(!c);this.menus.get("embed").setEnabled(!c);c="1"!=urlParams.embed||this.editor.graph.isEnabled();this.menus.get("openLibraryFrom").setEnabled(c);this.menus.get("newLibrary").setEnabled(c);this.menus.get("extras").setEnabled(c);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.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));
 if(this.isOfflineApp()){var d=applicationCache;if(null!=d&&null==this.offlineStatus){this.offlineStatus=document.createElement("div");this.offlineStatus.className="geItem";this.offlineStatus.style.position="absolute";this.offlineStatus.style.fontSize="8pt";this.offlineStatus.style.top="2px";this.offlineStatus.style.right="12px";this.offlineStatus.style.color="#666";this.offlineStatus.style.margin="4px";this.offlineStatus.style.padding="2px";this.offlineStatus.style.verticalAlign="middle";this.offlineStatus.innerHTML=
 "";this.menubarContainer.appendChild(this.offlineStatus);mxEvent.addListener(this.offlineStatus,"click",mxUtils.bind(this,function(){var a=this.offlineStatus.getElementsByTagName("img");null!=a&&0<a.length&&this.alert(a[0].getAttribute("title"))}));var d=window.applicationCache,e=null,b=mxUtils.bind(this,function(){var a=d.status,b;a==d.CHECKING&&(a=d.DOWNLOADING);switch(a){case d.UNCACHED:b="";break;case d.IDLE:b='<img title="draw.io is up to date." border="0" src="'+IMAGE_PATH+'/checkmark.gif"/>';
-break;case d.DOWNLOADING:b='<img title="Downloading new version" border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
+break;case d.DOWNLOADING:b='<img title="Downloading new version..." border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
 "checking",b);mxEvent.addListener(d,"noupdate",b);mxEvent.addListener(d,"downloading",b);mxEvent.addListener(d,"progress",b);mxEvent.addListener(d,"cached",b);mxEvent.addListener(d,"updateready",b);mxEvent.addListener(d,"obsolete",b);mxEvent.addListener(d,"error",b);b()}}else this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};var g=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){g.apply(this,
 arguments);var a=this.editor.graph,b=this.getCurrentFile(),c=null!=b&&b.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled();this.actions.get("pageSetup").setEnabled(c);this.actions.get("autosave").setEnabled(null!=b&&b.isEditable()&&b.isAutosaveOptional());this.actions.get("guides").setEnabled(c);this.actions.get("shadowVisible").setEnabled(c);this.actions.get("connectionArrows").setEnabled(c);this.actions.get("connectionPoints").setEnabled(c);this.actions.get("copyStyle").setEnabled(c&&
 !a.isSelectionEmpty());this.actions.get("pasteStyle").setEnabled(c&&!a.isSelectionEmpty());this.actions.get("editGeometry").setEnabled(a.getModel().isVertex(a.getSelectionCell()));this.actions.get("createShape").setEnabled(c);this.actions.get("createRevision").setEnabled(c);this.actions.get("moveToFolder").setEnabled(null!=b);this.actions.get("makeCopy").setEnabled(null!=b&&!b.isRestricted());this.actions.get("editDiagram").setEnabled("1"==urlParams.embed&&this.editor.graph.isEnabled()||null!=b&&
 !b.isRestricted());this.actions.get("publishLink").setEnabled(null!=b&&!b.isRestricted());this.menus.get("publish").setEnabled(null!=b&&!b.isRestricted());a=a.view.getState(a.getSelectionCell());this.actions.get("editShape").setEnabled(c&&null!=a&&null!=a.shape&&null!=a.shape.stencil)};null!=window.ExportDialog&&(ExportDialog.showXmlOption=!1,ExportDialog.showGifOption=!1,ExportDialog.exportFile=function(a,b,c,d,e,f){var g=a.editor.graph;if("xml"==c)a.hideDialog(),a.saveData(b,"xml",mxUtils.getXml(a.editor.getGraphXml()),
 "text/xml");else if("svg"==c)a.hideDialog(),a.saveData(b,"svg",mxUtils.getXml(g.getSvg(d,e,f)),"image/svg+xml");else{var k=a.getFileData(!0,null,null,null,null,!0),l=g.getGraphBounds(),m=Math.floor(l.width*e/g.view.scale),n=Math.floor(l.height*e/g.view.scale);k.length<=MAX_REQUEST_SIZE&&m*n<MAX_AREA?(a.hideDialog(),a.saveRequest(b,c,function(a,b){return new mxXmlRequest(EXPORT_URL,"format="+c+"&base64="+(b||"0")+(null!=a?"&filename="+encodeURIComponent(a):"")+"&bg="+(null!=d?d:"none")+"&w="+m+"&h="+
 n+"&border="+f+"&xml="+encodeURIComponent(k))})):mxUtils.alert(mxResources.get("drawingTooLarge"))}})})();
-var mxSettings={key:".drawio-config",settings:{language:"",libraries:Sidebar.prototype.defaultEntries,customLibraries:[],plugins:[],recentColors:[],formatWidth:"240",currentEdgeStyle:Graph.prototype.defaultEdgeStyle,currentVertexStyle:Graph.prototype.defaultVertexStyle,createTarget:!1,pageFormat:mxGraph.prototype.pageFormat,search:!0,showStartScreen:!0,gridColor:mxGraphView.prototype.gridColor,autosave:!0,version:13,isNew:!0},getLanguage:function(){return this.settings.language},setLanguage:function(a){this.settings.language=
-a},getUi:function(){return this.settings.ui},setUi:function(a){this.settings.ui=a},getShowStartScreen:function(){return this.settings.showStartScreen},setShowStartScreen:function(a){this.settings.showStartScreen=a},getGridColor:function(){return this.settings.gridColor},setGridColor:function(a){this.settings.gridColor=a},getAutosave:function(){return this.settings.autosave},setAutosave:function(a){this.settings.autosave=a},getLibraries:function(){return this.settings.libraries},setLibraries:function(a){this.settings.libraries=
-a},addCustomLibrary:function(a){mxSettings.load();0>mxUtils.indexOf(this.settings.customLibraries,a)&&this.settings.customLibraries.push(a);mxSettings.save()},removeCustomLibrary:function(a){mxSettings.load();mxUtils.remove(a,this.settings.customLibraries);mxSettings.save()},getCustomLibraries:function(){return this.settings.customLibraries},getPlugins:function(){return this.settings.plugins},setPlugins:function(a){this.settings.plugins=a},getRecentColors:function(){return this.settings.recentColors},
-setRecentColors:function(a){this.settings.recentColors=a},getFormatWidth:function(){return parseInt(this.settings.formatWidth)},setFormatWidth:function(a){this.settings.formatWidth=a},getCurrentEdgeStyle:function(){return this.settings.currentEdgeStyle},setCurrentEdgeStyle:function(a){this.settings.currentEdgeStyle=a},getCurrentVertexStyle:function(){return this.settings.currentVertexStyle},setCurrentVertexStyle:function(a){this.settings.currentVertexStyle=a},isCreateTarget:function(){return this.settings.createTarget},
-setCreateTarget:function(a){this.settings.createTarget=a},getPageFormat:function(){return this.settings.pageFormat},setPageFormat:function(a){this.settings.pageFormat=a},save:function(){if(isLocalStorage&&"undefined"!==typeof JSON)try{delete this.settings.isNew,this.settings.version=12,localStorage.setItem(mxSettings.key,JSON.stringify(this.settings))}catch(a){}},load:function(){isLocalStorage&&"undefined"!==typeof JSON&&mxSettings.parse(localStorage.getItem(mxSettings.key))},parse:function(a){null!=
-a&&(this.settings=JSON.parse(a),null==this.settings.plugins&&(this.settings.plugins=[]),null==this.settings.recentColors&&(this.settings.recentColors=[]),null==this.settings.libraries&&(this.settings.libraries=Sidebar.prototype.defaultEntries),null==this.settings.customLibraries&&(this.settings.customLibraries=[]),null==this.settings.ui&&(this.settings.ui=""),null==this.settings.formatWidth&&(this.settings.formatWidth="240"),null!=this.settings.lastAlert&&delete this.settings.lastAlert,null==this.settings.currentEdgeStyle?
-this.settings.currentEdgeStyle=Graph.prototype.defaultEdgeStyle:10>=this.settings.version&&(this.settings.currentEdgeStyle.orthogonalLoop=1,this.settings.currentEdgeStyle.jettySize="auto"),null==this.settings.currentVertexStyle&&(this.settings.currentVertexStyle=Graph.prototype.defaultEdgeStyle),null==this.settings.createTarget&&(this.settings.createTarget=!1),null==this.settings.pageFormat&&(this.settings.pageFormat=mxGraph.prototype.pageFormat),null==this.settings.search&&(this.settings.search=
-!0),null==this.settings.showStartScreen&&(this.settings.showStartScreen=!0),null==this.settings.gridColor&&(this.settings.gridColor=mxGraphView.prototype.gridColor),null==this.settings.autosave&&(this.settings.autosave=!0),null!=this.settings.scratchpadSeen&&delete this.settings.scratchpadSeen)},clear:function(){isLocalStorage&&localStorage.removeItem(mxSettings.key)}};("undefined"==typeof mxLoadSettings||mxLoadSettings)&&mxSettings.load();
-App=function(a,c,f){EditorUi.call(this,a,c,null!=f?f:"1"==urlParams.lightbox);mxClient.IS_SVG?mxGraph.prototype.warningImage.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAE7SURBVHjaYvz//z8DJQAggBjwGXDuHMP/tWuD/uPTCxBAOA0AaQRK/f/+XeJ/cbHlf1wGAAQQTgPu3QNLgfHSpZo4DQAIIKwGwGyH4e/fFbG6AiQJEEAs2Ew2NFzH8OOHBMO6dT/A/KCg7wxGRh+wuhQggDBcALMdFIAcHBxgDGJjcwVIIUAAYbhAUXEdVos4OO4DXcGBIQ4QQCguQPY7sgtgAYruCpAgQACx4LJdU1OCwctLEcyWlLwPJF+AXQE0EMUBAAEEdwF6yMOiD4RRY0QT7gqQAEAAseDzu6XldYYPH9DD4joQa8L5AAEENgWb7SBcXa0JDQMBrK4AcQACiAlfyOMCEFdAnAYQQEz4FLa0XGf4/v0H0IIPONUABBAjyBmMjIwMS5cK/L927QORbtBkaG29DtYLEGAAH6f7oq3Zc+kAAAAASUVORK5CYII=":
-(new Image).src=mxGraph.prototype.warningImage.src;window.openWindow=mxUtils.bind(this,function(a,b,c){var d=null;try{d=window.open(a)}catch(k){}null==d||void 0===d?this.showDialog((new PopupDialog(this,a,b,c)).container,320,140,!0,!0):null!=b&&b()});this.updateDocumentTitle();this.updateUi();a=document.createElement("canvas");this.canvasSupported=!(!a.getContext||!a.getContext("2d"));window.showOpenAlert=mxUtils.bind(this,function(a){null!=window.openFile&&window.openFile.cancel(!0);this.handleError(a)});
-this.isOffline()||(EditDataDialog.placeholderHelpLink="https://desk.draw.io/support/solutions/articles/16000051979");ColorDialog.recentColors=mxSettings.getRecentColors(ColorDialog.recentColors);this.addFileDropHandler([document]);if(null!=App.DrawPlugins){for(a=0;a<App.DrawPlugins.length;a++)try{App.DrawPlugins[a](this)}catch(d){null!=window.console&&console.log("Plugin Error:",d,App.DrawPlugins[a])}window.Draw.loadPlugin=function(a){a(this)}}this.load()};App.ERROR_TIMEOUT="timeout";
-App.ERROR_BUSY="busy";App.ERROR_UNKNOWN="unknown";App.MODE_GOOGLE="google";App.MODE_DROPBOX="dropbox";App.MODE_ONEDRIVE="onedrive";App.MODE_GITHUB="github";App.MODE_DEVICE="device";App.MODE_BROWSER="browser";App.DROPBOX_APPKEY="libwls2fa9szdji";App.DROPBOX_URL="https://unpkg.com/dropbox/dist/Dropbox-sdk.min.js";App.DROPINS_URL="https://www.dropbox.com/static/api/2/dropins.js";App.ONEDRIVE_URL="https://js.live.net/v7.0/OneDrive.js";
+var mxSettings={currentVersion:14,defaultFormatWidth:600>screen.width?"0":"240",key:".drawio-config",getLanguage:function(){return mxSettings.settings.language},setLanguage:function(a){mxSettings.settings.language=a},getUi:function(){return mxSettings.settings.ui},setUi:function(a){mxSettings.settings.ui=a},getShowStartScreen:function(){return mxSettings.settings.showStartScreen},setShowStartScreen:function(a){mxSettings.settings.showStartScreen=a},getGridColor:function(){return mxSettings.settings.gridColor},
+setGridColor:function(a){mxSettings.settings.gridColor=a},getAutosave:function(){return mxSettings.settings.autosave},setAutosave:function(a){mxSettings.settings.autosave=a},getLibraries:function(){return mxSettings.settings.libraries},setLibraries:function(a){mxSettings.settings.libraries=a},addCustomLibrary:function(a){mxSettings.load();0>mxUtils.indexOf(mxSettings.settings.customLibraries,a)&&("L.scratchpad"===a?mxSettings.settings.customLibraries.splice(0,0,a):mxSettings.settings.customLibraries.push(a));
+mxSettings.save()},removeCustomLibrary:function(a){mxSettings.load();mxUtils.remove(a,mxSettings.settings.customLibraries);mxSettings.save()},getCustomLibraries:function(){return mxSettings.settings.customLibraries},getPlugins:function(){return mxSettings.settings.plugins},setPlugins:function(a){mxSettings.settings.plugins=a},getRecentColors:function(){return mxSettings.settings.recentColors},setRecentColors:function(a){mxSettings.settings.recentColors=a},getFormatWidth:function(){return parseInt(mxSettings.settings.formatWidth)},
+setFormatWidth:function(a){mxSettings.settings.formatWidth=a},getCurrentEdgeStyle:function(){return mxSettings.settings.currentEdgeStyle},setCurrentEdgeStyle:function(a){mxSettings.settings.currentEdgeStyle=a},getCurrentVertexStyle:function(){return mxSettings.settings.currentVertexStyle},setCurrentVertexStyle:function(a){mxSettings.settings.currentVertexStyle=a},isCreateTarget:function(){return mxSettings.settings.createTarget},setCreateTarget:function(a){mxSettings.settings.createTarget=a},getPageFormat:function(){return mxSettings.settings.pageFormat},
+setPageFormat:function(a){mxSettings.settings.pageFormat=a},init:function(){mxSettings.settings={language:"",libraries:Sidebar.prototype.defaultEntries,customLibraries:Editor.defaultCustomLibraries,plugins:[],recentColors:[],formatWidth:mxSettings.defaultFormatWidth,currentEdgeStyle:Graph.prototype.defaultEdgeStyle,currentVertexStyle:Graph.prototype.defaultVertexStyle,createTarget:!1,pageFormat:mxGraph.prototype.pageFormat,search:!0,showStartScreen:!0,gridColor:mxGraphView.prototype.gridColor,autosave:!0,
+version:mxSettings.currentVersion,isNew:!0}},save:function(){if(isLocalStorage&&"undefined"!==typeof JSON)try{delete mxSettings.settings.isNew,mxSettings.settings.version=mxSettings.currentVersion,localStorage.setItem(mxSettings.key,JSON.stringify(mxSettings.settings))}catch(a){}},load:function(){isLocalStorage&&"undefined"!==typeof JSON&&mxSettings.parse(localStorage.getItem(mxSettings.key));null==mxSettings.settings&&mxSettings.init()},parse:function(a){null!=a&&(mxSettings.settings=JSON.parse(a),
+null==mxSettings.settings.plugins&&(mxSettings.settings.plugins=[]),null==mxSettings.settings.recentColors&&(mxSettings.settings.recentColors=[]),null==mxSettings.settings.libraries&&(mxSettings.settings.libraries=Sidebar.prototype.defaultEntries),null==mxSettings.settings.customLibraries&&(mxSettings.settings.customLibraries=Editor.defaultCustomLibraries),null==mxSettings.settings.ui&&(mxSettings.settings.ui=""),null==mxSettings.settings.formatWidth&&(mxSettings.settings.formatWidth=mxSettings.defaultFormatWidth),
+null!=mxSettings.settings.lastAlert&&delete mxSettings.settings.lastAlert,null==mxSettings.settings.currentEdgeStyle?mxSettings.settings.currentEdgeStyle=Graph.prototype.defaultEdgeStyle:10>=mxSettings.settings.version&&(mxSettings.settings.currentEdgeStyle.orthogonalLoop=1,mxSettings.settings.currentEdgeStyle.jettySize="auto"),null==mxSettings.settings.currentVertexStyle&&(mxSettings.settings.currentVertexStyle=Graph.prototype.defaultVertexStyle),null==mxSettings.settings.createTarget&&(mxSettings.settings.createTarget=
+!1),null==mxSettings.settings.pageFormat&&(mxSettings.settings.pageFormat=mxGraph.prototype.pageFormat),null==mxSettings.settings.search&&(mxSettings.settings.search=!0),null==mxSettings.settings.showStartScreen&&(mxSettings.settings.showStartScreen=!0),null==mxSettings.settings.gridColor&&(mxSettings.settings.gridColor=mxGraphView.prototype.gridColor),null==mxSettings.settings.autosave&&(mxSettings.settings.autosave=!0),null!=mxSettings.settings.scratchpadSeen&&delete mxSettings.settings.scratchpadSeen)},
+clear:function(){isLocalStorage&&localStorage.removeItem(mxSettings.key)}};("undefined"==typeof mxLoadSettings||mxLoadSettings)&&mxSettings.load();
+App=function(a,c,f){EditorUi.call(this,a,c,null!=f?f:"1"==urlParams.lightbox);mxClient.IS_SVG?mxGraph.prototype.warningImage.src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAE7SURBVHjaYvz//z8DJQAggBjwGXDuHMP/tWuD/uPTCxBAOA0AaQRK/f/+XeJ/cbHlf1wGAAQQTgPu3QNLgfHSpZo4DQAIIKwGwGyH4e/fFbG6AiQJEEAs2Ew2NFzH8OOHBMO6dT/A/KCg7wxGRh+wuhQggDBcALMdFIAcHBxgDGJjcwVIIUAAYbhAUXEdVos4OO4DXcGBIQ4QQCguQPY7sgtgAYruCpAgQACx4LJdU1OCwctLEcyWlLwPJF+AXQE0EMUBAAEEdwF6yMOiD4RRY0QT7gqQAEAAseDzu6XldYYPH9DD4joQa8L5AAEENgWb7SBcXa0JDQMBrK4AcQACiAlfyOMCEFdAnAYQQEz4FLa0XGf4/v0H0IIPONUABBAjyBmMjIwMS5cK/L927QORbtBkaG29DtYLEGAAH6f7oq3Zc+kAAAAASUVORK5CYII=":(new Image).src=
+mxGraph.prototype.warningImage.src;window.openWindow=mxUtils.bind(this,function(a,b,c){var d=null;try{d=window.open(a)}catch(k){}null==d||void 0===d?this.showDialog((new PopupDialog(this,a,b,c)).container,320,140,!0,!0):null!=b&&b()});this.updateDocumentTitle();this.updateUi();a=document.createElement("canvas");this.canvasSupported=!(!a.getContext||!a.getContext("2d"));window.showOpenAlert=mxUtils.bind(this,function(a){null!=window.openFile&&window.openFile.cancel(!0);this.handleError(a)});this.isOffline()||
+(EditDataDialog.placeholderHelpLink="https://desk.draw.io/support/solutions/articles/16000051979");this.addFileDropHandler([document]);if(null!=App.DrawPlugins){for(a=0;a<App.DrawPlugins.length;a++)try{App.DrawPlugins[a](this)}catch(d){null!=window.console&&console.log("Plugin Error:",d,App.DrawPlugins[a])}window.Draw.loadPlugin=mxUtils.bind(this,function(a){a(this)})}this.load()};App.ERROR_TIMEOUT="timeout";App.ERROR_BUSY="busy";App.ERROR_UNKNOWN="unknown";App.MODE_GOOGLE="google";
+App.MODE_DROPBOX="dropbox";App.MODE_ONEDRIVE="onedrive";App.MODE_GITHUB="github";App.MODE_DEVICE="device";App.MODE_BROWSER="browser";App.DROPBOX_APPKEY="libwls2fa9szdji";App.DROPBOX_URL="https://unpkg.com/dropbox/dist/Dropbox-sdk.min.js";App.DROPINS_URL="https://www.dropbox.com/static/api/2/dropins.js";App.ONEDRIVE_URL="https://js.live.net/v7.0/OneDrive.js";
 App.pluginRegistry={"4xAKTrabTpTzahoLthkwPNUn":"/plugins/explore.js",ex:"/plugins/explore.js",p1:"/plugins/p1.js",ac:"/plugins/connect.js",acj:"/plugins/connectJira.js",voice:"/plugins/voice.js",tips:"/plugins/tooltips.js",svgdata:"/plugins/svgdata.js",doors:"/plugins/doors.js",electron:"plugins/electron.js",number:"/plugins/number.js",sql:"/plugins/sql.js",props:"/plugins/props.js",text:"/plugins/text.js",anim:"/plugins/animation.js",update:"/plugins/update.js",trees:"/plugins/trees/trees.js","import":"/plugins/import.js",
 replay:"/plugins/replay.js"};App.getStoredMode=function(){var a=null;null==a&&isLocalStorage&&(a=localStorage.getItem(".mode"));if(null==a&&"undefined"!=typeof Storage){for(var c=document.cookie.split(";"),f=0;f<c.length;f++){var d=mxUtils.trim(c[f]);if("MODE="==d.substring(0,5)){a=d.substring(5);break}}null!=a&&isLocalStorage&&(c=new Date,c.setYear(c.getFullYear()-1),document.cookie="MODE=; expires="+c.toUTCString(),localStorage.setItem(".mode",a))}return a};
-(function(){if(!mxClient.IS_CHROMEAPP&&("1"!=urlParams.offline&&("db.draw.io"==window.location.hostname&&null==urlParams.mode&&(urlParams.mode="dropbox"),App.mode=urlParams.mode,null==App.mode&&(App.mode=App.getStoredMode())),null!=window.mxscript&&("1"!=urlParams.embed&&("function"===typeof window.DriveClient&&("0"!=urlParams.gapi&&isSvgBrowser&&(null==document.documentMode||10<=document.documentMode)?App.mode==App.MODE_GOOGLE||null!=urlParams.state&&""==window.location.hash||null!=window.location.hash&&
+(function(){mxClient.IS_CHROMEAPP||("1"!=urlParams.offline&&("db.draw.io"==window.location.hostname&&null==urlParams.mode&&(urlParams.mode="dropbox"),App.mode=urlParams.mode,null==App.mode&&(App.mode=App.getStoredMode())),null!=window.mxscript&&("1"!=urlParams.embed&&("function"===typeof window.DriveClient&&("0"!=urlParams.gapi&&isSvgBrowser&&(null==document.documentMode||10<=document.documentMode)?App.mode==App.MODE_GOOGLE||null!=urlParams.state&&""==window.location.hash||null!=window.location.hash&&
 "#G"==window.location.hash.substring(0,2)?mxscript("https://apis.google.com/js/api.js"):"0"!=urlParams.chrome||null!=window.location.hash&&"#Uhttps%3A%2F%2Fdrive.google.com%2Fuc%3Fid%3D"===window.location.hash.substring(0,45)||(window.DriveClient=null):window.DriveClient=null),"function"===typeof window.DropboxClient&&("0"!=urlParams.db&&isSvgBrowser&&(null==document.documentMode||9<document.documentMode)?App.mode==App.MODE_DROPBOX||null!=window.location.hash&&"#D"==window.location.hash.substring(0,
 2)?(mxscript(App.DROPBOX_URL),mxscript(App.DROPINS_URL,null,"dropboxjs",App.DROPBOX_APPKEY)):"0"==urlParams.chrome&&(window.DropboxClient=null):window.DropboxClient=null),"function"===typeof window.OneDriveClient&&("0"!=urlParams.od&&(0>navigator.userAgent.indexOf("MSIE")||10<=document.documentMode)?App.mode==App.MODE_ONEDRIVE||null!=window.location.hash&&"#W"==window.location.hash.substring(0,2)?mxscript(App.ONEDRIVE_URL):"0"==urlParams.chrome&&(window.OneDriveClient=null):window.OneDriveClient=
-null)),"undefined"==typeof JSON&&mxscript("js/json/json2.min.js")),"0"!=urlParams.plugins&&"1"!=urlParams.offline)){var a=mxSettings.getPlugins(),c=urlParams.p;if(null!=c||null!=a&&0<a.length)App.DrawPlugins=[],window.Draw={},window.Draw.loadPlugin=function(a){App.DrawPlugins.push(a)};if(null!=c)for(var f=c.split(";"),c=0;c<f.length;c++){var d=App.pluginRegistry[f[c]];null!=d?mxscript(d):null!=window.console&&console.log("Unknown plugin:",f[c])}if(null!=a&&0<a.length&&"0"!=urlParams.plugins){f=window.location.protocol+
-"//"+window.location.host;d=!0;for(c=0;c<a.length&&d;c++)"/"!=a[c].charAt(0)&&a[c].substring(0,f.length)!=f&&(d=!1);if(d||mxUtils.confirm(mxResources.replacePlaceholders("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",[a.join("\n")]).replace(/\\n/g,"\n")))for(c=0;c<a.length;c++)try{mxscript(a[c])}catch(b){}}}})();
-App.main=function(a){var c=null;EditorUi.enableLogging&&(window.onerror=function(a,b,e,f,k){try{if(a!=c&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&null!=a&&0>a.indexOf("DocumentClosedError")){c=a;var d=new Image,g=0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";d.src=(null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"")+"/log?severity="+g+"&v="+encodeURIComponent(EditorUi.VERSION)+
-"&msg=clientError:"+encodeURIComponent(a)+":url:"+encodeURIComponent(window.location.href)+":lnum:"+encodeURIComponent(e)+(null!=f?":colno:"+encodeURIComponent(f):"")+(null!=k&&null!=k.stack?"&stack="+encodeURIComponent(k.stack):"")}}catch(n){}});"atlas"==uiTheme&&mxClient.link("stylesheet","styles/atlas.css");if(null!=window.mxscript){"0"!=urlParams.chrome&&mxscript("js/jscolor/jscolor.js");if("1"==urlParams.offline){mxscript("js/shapes.min.js");var f=document.createElement("iframe");f.setAttribute("width",
+null)),"undefined"==typeof JSON&&mxscript("js/json/json2.min.js")))})();
+App.main=function(a){var c=null;EditorUi.enableLogging&&(window.onerror=function(a,b,d,e,f){try{if(a!=c&&(null==a||null==b||-1==a.indexOf("Script error")&&-1==a.indexOf("extension"))&&null!=a&&0>a.indexOf("DocumentClosedError")){c=a;var g=new Image,k=0<=a.indexOf("NetworkError")||0<=a.indexOf("SecurityError")||0<=a.indexOf("NS_ERROR_FAILURE")||0<=a.indexOf("out of memory")?"CONFIG":"SEVERE";g.src=(null!=window.DRAWIO_LOG_URL?window.DRAWIO_LOG_URL:"")+"/log?severity="+k+"&v="+encodeURIComponent(EditorUi.VERSION)+
+"&msg=clientError:"+encodeURIComponent(a)+":url:"+encodeURIComponent(window.location.href)+":lnum:"+encodeURIComponent(d)+(null!=e?":colno:"+encodeURIComponent(e):"")+(null!=f&&null!=f.stack?"&stack="+encodeURIComponent(f.stack):"")}}catch(t){}});"atlas"==uiTheme&&mxClient.link("stylesheet","styles/atlas.css");if(null!=window.mxscript){"0"!=urlParams.chrome&&mxscript("js/jscolor/jscolor.js");if("1"==urlParams.offline){mxscript("js/shapes.min.js");var f=document.createElement("iframe");f.setAttribute("width",
 "0");f.setAttribute("height","0");f.setAttribute("src","offline.html");document.body.appendChild(f);mxStencilRegistry.stencilSet={};mxStencilRegistry.getStencil=function(a){return mxStencilRegistry.stencils[a]};mxStencilRegistry.loadStencilSet=function(a,b,c){a=a.substring(a.indexOf("/")+1);a="mxgraph."+a.substring(0,a.length-4).replace(/\//g,".");a=mxStencilRegistry.stencilSet[a];null!=a&&mxStencilRegistry.parseStencilSet(a,b,!1)};for(f=mxUtils.load("stencils.xml").getXml().documentElement.firstChild;null!=
-f;)"shapes"==f.nodeName&&null!=f.getAttribute("name")&&(mxStencilRegistry.stencilSet[f.getAttribute("name").toLowerCase()]=f,mxStencilRegistry.parseStencilSet(f)),f=f.nextSibling}"0"==urlParams.picker||mxClient.IS_QUIRKS||8==document.documentMode||mxscript(document.location.protocol+"//www.google.com/jsapi?autoload=%7B%22modules%22%3A%5B%7B%22name%22%3A%22picker%22%2C%22version%22%3A%221%22%2C%22language%22%3A%22"+mxClient.language+"%22%7D%5D%7D");"function"===typeof window.DriveClient&&"undefined"===
-typeof gapi&&("1"!=urlParams.embed&&"0"!=urlParams.gapi||"1"==urlParams.embed&&"1"==urlParams.gapi)&&isSvgBrowser&&isLocalStorage&&(null==document.documentMode||10<=document.documentMode)?mxscript("https://apis.google.com/js/api.js?onload=DrawGapiClientCallback"):"undefined"===typeof window.gapi&&(window.DriveClient=null)}"0"!=urlParams.math&&Editor.initMath();mxResources.loadDefaultBundle=!1;f=mxResources.getDefaultBundle(RESOURCE_BASE,mxLanguage)||mxResources.getSpecialBundle(RESOURCE_BASE,mxLanguage);
-mxUtils.getAll("1"!=urlParams.dev?[f]:[f,STYLE_PATH+"/default.xml"],function(c){mxResources.parse(c[0].getText());1<c.length&&(Graph.prototype.defaultThemes[Graph.prototype.defaultThemeName]=c[1].getDocumentElement());c=new App(new Editor("0"==urlParams.chrome));if(null!=window.mxscript){if("function"===typeof window.DropboxClient&&null==window.Dropbox&&null!=window.DrawDropboxClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.db||"1"==urlParams.embed&&"1"==urlParams.db)&&isSvgBrowser&&(null==
-document.documentMode||9<document.documentMode))mxscript(App.DROPBOX_URL,function(){mxscript(App.DROPINS_URL,function(){DrawDropboxClientCallback()},"dropboxjs",App.DROPBOX_APPKEY)});else if("undefined"===typeof window.Dropbox||"undefined"===typeof window.Dropbox.choose)window.DropboxClient=null;"function"===typeof window.OneDriveClient&&"undefined"===typeof OneDrive&&null!=window.DrawOneDriveClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.od||"1"==urlParams.embed&&"1"==urlParams.od)&&(0>navigator.userAgent.indexOf("MSIE")||
-10<=document.documentMode)?mxscript(App.ONEDRIVE_URL,window.DrawOneDriveClientCallback):"undefined"===typeof window.OneDrive&&(window.OneDriveClient=null)}null!=a&&a(c);"0"!=urlParams.chrome&&"1"==urlParams.test&&(mxLog.show(),mxLog.debug("Started in "+((new Date).getTime()-t0.getTime())+"ms"),mxLog.debug("Export:",EXPORT_URL),mxLog.debug("Development mode:","1"==urlParams.dev?"active":"inactive"),mxLog.debug("Test mode:","1"==urlParams.test?"active":"inactive"))},function(){document.getElementById("geStatus").innerHTML=
-'Error loading page. <a href="javascript:void(0);" onclick="location.reload();">Please try refreshing.</a>'})};mxUtils.extend(App,EditorUi);App.prototype.defaultUserPicture="https://lh3.googleusercontent.com/-HIzvXUy6QUY/AAAAAAAAAAI/AAAAAAAAAAA/giuR7PQyjEk/photo.jpg?sz=30";App.prototype.shareImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA2RpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDowOTgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoxMjU2NzdEMTcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoxMjU2NzdEMDcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ1M1IFdpbmRvd3MiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowNjgwMTE3NDA3MjA2ODExODcxRkM4MUY1OTFDMjQ5OCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowNzgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PrM/fs0AAADgSURBVHjaYmDAA/7//88MwgzkAKDGFiD+BsQ/QWxSNaf9RwN37twpI8WAS+gGfP78+RpQSoRYA36iG/D379+vQClNdLVMOMz4gi7w79+/n0CKg1gD9qELvH379hzIHGK9oA508ieY8//8+fO5rq4uFCilRKwL1JmYmNhhHEZGRiZ+fn6Q2meEbDYG4u3/cYCfP38uA7kOm0ZOIJ7zn0jw48ePPiDFhmzArv8kgi9fvuwB+w5qwH9ykjswbFSZyM4sEMDPBDTlL5BxkFSd7969OwZ2BZKYGhDzkmjOJ4AAAwBhpRqGnEFb8QAAAABJRU5ErkJggg==";
+f;)"shapes"==f.nodeName&&null!=f.getAttribute("name")&&(mxStencilRegistry.stencilSet[f.getAttribute("name").toLowerCase()]=f,mxStencilRegistry.parseStencilSet(f)),f=f.nextSibling}"0"==urlParams.picker||mxClient.IS_QUIRKS||8==document.documentMode||mxscript(document.location.protocol+"//www.google.com/jsapi?autoload=%7B%22modules%22%3A%5B%7B%22name%22%3A%22picker%22%2C%22version%22%3A%221%22%2C%22language%22%3A%22"+mxClient.language+"%22%7D%5D%7D");if("0"!=urlParams.plugins&&"1"!=urlParams.offline){var f=
+mxSettings.getPlugins(),d=urlParams.p;if(null!=d||null!=f&&0<f.length)App.DrawPlugins=[],window.Draw={},window.Draw.loadPlugin=function(a){App.DrawPlugins.push(a)};if(null!=d)for(var b=d.split(";"),d=0;d<b.length;d++){var e=App.pluginRegistry[b[d]];null!=e?mxscript(e):null!=window.console&&console.log("Unknown plugin:",b[d])}if(null!=f&&0<f.length&&"0"!=urlParams.plugins){b=window.location.protocol+"//"+window.location.host;e=!0;for(d=0;d<f.length&&e;d++)"/"!=f[d].charAt(0)&&f[d].substring(0,b.length)!=
+b&&(e=!1);if(e||mxUtils.confirm(mxResources.replacePlaceholders("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",[f.join("\n")]).replace(/\\n/g,"\n")))for(d=0;d<f.length;d++)try{mxscript(f[d])}catch(g){}}}"function"===typeof window.DriveClient&&"undefined"===typeof gapi&&("1"!=urlParams.embed&&"0"!=urlParams.gapi||"1"==urlParams.embed&&
+"1"==urlParams.gapi)&&isSvgBrowser&&isLocalStorage&&(null==document.documentMode||10<=document.documentMode)?mxscript("https://apis.google.com/js/api.js?onload=DrawGapiClientCallback"):"undefined"===typeof window.gapi&&(window.DriveClient=null)}"0"!=urlParams.math&&Editor.initMath();mxResources.loadDefaultBundle=!1;f=mxResources.getDefaultBundle(RESOURCE_BASE,mxLanguage)||mxResources.getSpecialBundle(RESOURCE_BASE,mxLanguage);mxUtils.getAll("1"!=urlParams.dev?[f]:[f,STYLE_PATH+"/default.xml"],function(b){mxResources.parse(b[0].getText());
+1<b.length&&(Graph.prototype.defaultThemes[Graph.prototype.defaultThemeName]=b[1].getDocumentElement());b=new App(new Editor("0"==urlParams.chrome));if(null!=window.mxscript){if("function"===typeof window.DropboxClient&&null==window.Dropbox&&null!=window.DrawDropboxClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.db||"1"==urlParams.embed&&"1"==urlParams.db)&&isSvgBrowser&&(null==document.documentMode||9<document.documentMode))mxscript(App.DROPBOX_URL,function(){mxscript(App.DROPINS_URL,function(){DrawDropboxClientCallback()},
+"dropboxjs",App.DROPBOX_APPKEY)});else if("undefined"===typeof window.Dropbox||"undefined"===typeof window.Dropbox.choose)window.DropboxClient=null;"function"===typeof window.OneDriveClient&&"undefined"===typeof OneDrive&&null!=window.DrawOneDriveClientCallback&&("1"!=urlParams.embed&&"0"!=urlParams.od||"1"==urlParams.embed&&"1"==urlParams.od)&&(0>navigator.userAgent.indexOf("MSIE")||10<=document.documentMode)?mxscript(App.ONEDRIVE_URL,window.DrawOneDriveClientCallback):"undefined"===typeof window.OneDrive&&
+(window.OneDriveClient=null)}null!=a&&a(b);"0"!=urlParams.chrome&&"1"==urlParams.test&&(mxLog.show(),mxLog.debug("Started in "+((new Date).getTime()-t0.getTime())+"ms"),mxLog.debug("Export:",EXPORT_URL),mxLog.debug("Development mode:","1"==urlParams.dev?"active":"inactive"),mxLog.debug("Test mode:","1"==urlParams.test?"active":"inactive"))},function(){document.getElementById("geStatus").innerHTML='Error loading page. <a href="javascript:void(0);" onclick="location.reload();">Please try refreshing.</a>'})};
+mxUtils.extend(App,EditorUi);App.prototype.defaultUserPicture="https://lh3.googleusercontent.com/-HIzvXUy6QUY/AAAAAAAAAAI/AAAAAAAAAAA/giuR7PQyjEk/photo.jpg?sz=30";App.prototype.shareImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA2RpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDowOTgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoxMjU2NzdEMTcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoxMjU2NzdEMDcwRDIxMUUxQjc0MDkxRDhCNUQzOEFGRCIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ1M1IFdpbmRvd3MiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowNjgwMTE3NDA3MjA2ODExODcxRkM4MUY1OTFDMjQ5OCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowNzgwMTE3NDA3MjA2ODExODhDNkFGMDBEQkQ0RTgwOSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PrM/fs0AAADgSURBVHjaYmDAA/7//88MwgzkAKDGFiD+BsQ/QWxSNaf9RwN37twpI8WAS+gGfP78+RpQSoRYA36iG/D379+vQClNdLVMOMz4gi7w79+/n0CKg1gD9qELvH379hzIHGK9oA508ieY8//8+fO5rq4uFCilRKwL1JmYmNhhHEZGRiZ+fn6Q2meEbDYG4u3/cYCfP38uA7kOm0ZOIJ7zn0jw48ePPiDFhmzArv8kgi9fvuwB+w5qwH9ykjswbFSZyM4sEMDPBDTlL5BxkFSd7969OwZ2BZKYGhDzkmjOJ4AAAwBhpRqGnEFb8QAAAABJRU5ErkJggg==";
 App.prototype.chevronUpImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NDg2NEE3NUY1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6NDg2NEE3NjA1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo0ODY0QTc1RDUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo0ODY0QTc1RTUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pg+qUokAAAAMUExURQAAANnZ2b+/v////5bgre4AAAAEdFJOU////wBAKqn0AAAAL0lEQVR42mJgRgMMRAswMKAKMDDARBjg8lARBoR6KImkH0wTbygT6YaS4DmAAAMAYPkClOEDDD0AAAAASUVORK5CYII=":
 IMAGE_PATH+"/chevron-up.png";
 App.prototype.chevronDownImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NDg2NEE3NUI1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6NDg2NEE3NUM1MUVBMTFFM0I3MUVEMTc0N0YyOUI4QzEiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo0ODY0QTc1OTUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo0ODY0QTc1QTUxRUExMUUzQjcxRUQxNzQ3RjI5QjhDMSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PsCtve8AAAAMUExURQAAANnZ2b+/v////5bgre4AAAAEdFJOU////wBAKqn0AAAALUlEQVR42mJgRgMMRAkwQEXBNAOcBSPhclB1cNVwfcxI+vEZykSpoSR6DiDAAF23ApT99bZ+AAAAAElFTkSuQmCC":IMAGE_PATH+
@@ -8139,7 +8147,7 @@ App.prototype.chevronDownImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGg
 App.prototype.formatShowImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6ODdCREY5REY1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6ODdCREY5RTA1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo4N0JERjlERDU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo4N0JERjlERTU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PlnMQ/8AAAAJUExURQAAAP///3FxcTfTiAsAAAACdFJOU/8A5bcwSgAAACFJREFUeNpiYEQDDEQJMMABTAAixcQ00ALoDiPRcwABBgB6DADly9Yx8wAAAABJRU5ErkJggg==":IMAGE_PATH+
 "/format-show.png";
 App.prototype.formatHideImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6ODdCREY5REI1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6ODdCREY5REM1NkQ3MTFFNTkyNjNEMTA5NjgwODUyRTgiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo4N0JERjlEOTU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo4N0JERjlEQTU2RDcxMUU1OTI2M0QxMDk2ODA4NTJFOCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PqjT9SMAAAAGUExURQAAAP///6XZn90AAAACdFJOU/8A5bcwSgAAAB9JREFUeNpiYEQDDEQJMMABTAAmNdAC6A4j0XMAAQYAcbwA1Xvj1CgAAAAASUVORK5CYII=":IMAGE_PATH+
-"/format-hide.png";App.prototype.fullscreenImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAAAAAClZ7nPAAAAAXRSTlMAQObYZgAAABpJREFUCNdjgAAbGxAy4AEh5gNwBBGByoIBAIueBd12TUjqAAAAAElFTkSuQmCC":IMAGE_PATH+"/fullscreen.png";App.prototype.timeout=25E3;App.prototype.formatEnabled="0"!=urlParams.format;App.prototype.formatWidth=600>screen.width?0:mxSettings.getFormatWidth();"1"!=urlParams.embed&&(App.prototype.menubarHeight=60);
+"/format-hide.png";App.prototype.fullscreenImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAAAAAClZ7nPAAAAAXRSTlMAQObYZgAAABpJREFUCNdjgAAbGxAy4AEh5gNwBBGByoIBAIueBd12TUjqAAAAAElFTkSuQmCC":IMAGE_PATH+"/fullscreen.png";App.prototype.timeout=25E3;"1"!=urlParams.embed&&(App.prototype.menubarHeight=60);
 App.prototype.init=function(){EditorUi.prototype.init.apply(this,arguments);this.defaultLibraryName=mxResources.get("untitledLibrary");this.descriptorChangedListener=mxUtils.bind(this,this.descriptorChanged);this.gitHub=mxClient.IS_IE&&10!=document.documentMode&&!mxClient.IS_IE11&&!mxClient.IS_EDGE||"0"==urlParams.gh||"1"==urlParams.embed&&"1"!=urlParams.gh?null:new GitHubClient(this);null!=this.gitHub&&this.gitHub.addListener("userChanged",mxUtils.bind(this,function(){this.updateUserElement();this.restoreLibraries()}));
 if("1"!=urlParams.embed||"1"==urlParams.od){var a=mxUtils.bind(this,function(){"undefined"!==typeof OneDrive?(this.oneDrive=new OneDriveClient(this),this.oneDrive.addListener("userChanged",mxUtils.bind(this,function(){this.updateUserElement();this.restoreLibraries()})),this.fireEvent(new mxEventObject("clientLoaded","client",this.oneDrive))):null==window.DrawOneDriveClientCallback&&(window.DrawOneDriveClientCallback=a)});a()}if("1"!=urlParams.embed||"1"==urlParams.gapi){var c=mxUtils.bind(this,function(){if("undefined"!==
 typeof gapi){var a=mxUtils.bind(this,function(){this.drive=new DriveClient(this);"420247213240"==this.drive.appId&&this.editor.addListener("fileLoaded",mxUtils.bind(this,function(){var a=this.getCurrentFile();null!=a&&a.constructor==DriveFile&&(a=document.getElementById("geFooterItem2"),null!=a&&(a.innerHTML='<a href="https://support.draw.io/display/DO/2014/11/27/Switching+application+in+Google+Drive" target="_blank" title="IMPORTANT NOTICE" >IMPORTANT NOTICE</a>'))}));this.drive.addListener("userChanged",
@@ -8151,10 +8159,7 @@ window.DrawGapiClientCallback=null):a()}else null==window.DrawGapiClientCallback
 (this.menubar.container.style.paddingTop="0px");this.updateHeader();var d=document.getElementById("geFooterItem2");if(null!=d){this.adsHtml=['<a title="Quick start video" href="https://www.youtube.com/watch?v=8OaMWa4R1SE&t=1" target="_blank"><img border="0" align="absmiddle" style="margin-top:-4px;" src="images/glyphicons_star.png"/>&nbsp;&nbsp;Quick start video</a>'];this.adsHtml.push(d.innerHTML);mxUtils.setPrefixedStyle(d.style,"transition","all 1s ease");var b=this.adsHtml.length-1;this.updateAd=
 function(a){a==b&&(a=this.adsHtml.length-1);a!=b&&(mxUtils.setPrefixedStyle(d.style,"transform","scale(0)"),d.style.opacity="0",b=a,window.setTimeout(mxUtils.bind(this,function(){d.innerHTML=this.adsHtml[a];mxUtils.setPrefixedStyle(d.style,"transform","scale(1)");d.style.opacity="1"}),1E3))};window.setInterval(mxUtils.bind(this,function(){3==this.adsHtml.length?this.updateAd(mxUtils.mod(b+1,3)):this.updateAd(Math.round(Math.random()*(this.adsHtml.length-1)))}),3E5)}null!=this.menubar&&(this.buttonContainer=
 document.createElement("div"),this.buttonContainer.style.display="inline-block",this.buttonContainer.style.paddingRight="48px",this.buttonContainer.style.position="absolute",this.buttonContainer.style.right="0px",this.menubar.container.appendChild(this.buttonContainer));"atlas"==uiTheme&&null!=this.menubar&&(null!=this.toggleElement&&(this.toggleElement.click(),this.toggleElement.style.display="none"),this.icon=document.createElement("img"),this.icon.setAttribute("src",IMAGE_PATH+"/logo-flat-small.png"),
-this.icon.setAttribute("title",mxResources.get("draw.io")),this.icon.style.paddingTop="11px",this.icon.style.marginLeft="4px",this.icon.style.marginRight="6px",mxClient.IS_QUIRKS&&(this.icon.style.marginTop="12px"),this.menubar.container.insertBefore(this.icon,this.menubar.container.firstChild));if(isLocalStorage||mxClient.IS_CHROMEAPP)this.editor.graph.currentEdgeStyle=mxSettings.getCurrentEdgeStyle(),this.editor.graph.currentVertexStyle=mxSettings.getCurrentVertexStyle(),this.fireEvent(new mxEventObject("styleChanged",
-"keys",[],"values",[],"cells",[])),this.addListener("styleChanged",mxUtils.bind(this,function(a,b){mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);mxSettings.save()})),this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget()),this.fireEvent(new mxEventObject("copyConnectChanged")),this.addListener("copyConnectChanged",mxUtils.bind(this,function(a,b){mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());
-mxSettings.save()})),this.editor.graph.pageFormat=mxSettings.getPageFormat(),this.addListener("pageFormatChanged",mxUtils.bind(this,function(a,b){mxSettings.setPageFormat(this.editor.graph.pageFormat);mxSettings.save()})),this.editor.graph.view.gridColor=mxSettings.getGridColor(),this.addListener("gridColorChanged",mxUtils.bind(this,function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor);mxSettings.save()})),mxClient.IS_CHROMEAPP&&(this.editor.addListener("autosaveChanged",mxUtils.bind(this,
-function(a,b){mxSettings.setAutosave(this.editor.autosave);mxSettings.save()})),this.editor.autosave=mxSettings.getAutosave()),null!=this.sidebar&&this.sidebar.showPalette("search",mxSettings.settings.search),!this.editor.chromeless&&null!=this.sidebar&&(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))&&(this.toggleScratchpad(),mxSettings.save()),this.addListener("formatWidthChanged",function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})};
+this.icon.setAttribute("title",mxResources.get("draw.io")),this.icon.style.paddingTop="11px",this.icon.style.marginLeft="4px",this.icon.style.marginRight="6px",mxClient.IS_QUIRKS&&(this.icon.style.marginTop="12px"),this.menubar.container.insertBefore(this.icon,this.menubar.container.firstChild))};
 App.prototype.isDriveDomain=function(){return"0"!=urlParams.drive&&("test.draw.io"==window.location.hostname||"cdn.draw.io"==window.location.hostname||"www.draw.io"==window.location.hostname||"drive.draw.io"==window.location.hostname||"jgraph.github.io"==window.location.hostname)};App.prototype.isLegacyDriveDomain=function(){return 0==urlParams.drive||"legacy.draw.io"==window.location.hostname};
 App.prototype.checkLicense=function(){var a=this.drive.getUser(),c=("1"==urlParams.dev?urlParams.lic:null)||(null!=a?a.email:null);if(!this.isOffline()&&!this.editor.chromeless&&null!=c){var f=c.lastIndexOf("@"),d=c;0<=f&&(d=c.substring(f+1));mxUtils.post("/license","domain="+encodeURIComponent(d)+"&email="+encodeURIComponent(c)+"&ds="+encodeURIComponent(a.displayName)+"&lc="+encodeURIComponent(a.locale)+"&ts="+(new Date).getTime(),mxUtils.bind(this,function(a){try{if(200<=a.getStatus()&&299>=a.getStatus()){var b=
 a.getText();if(0<b.length){var c=JSON.parse(b);null!=c&&this.handleLicense(c,d)}}}catch(k){}}))}};
diff --git a/war/js/diagramly/App.js b/war/js/diagramly/App.js
index 5fc5ab73cea857995c2d2c19832a295f4b03fd4e..bd178d396c43e9420a930aa4be897dd8bbeb9070 100644
--- a/war/js/diagramly/App.js
+++ b/war/js/diagramly/App.js
@@ -75,9 +75,6 @@ App = function(editor, container, lightbox)
 		EditDataDialog.placeholderHelpLink = 'https://desk.draw.io/support/solutions/articles/16000051979';
 	}
 
-	// Gets recent colors from settings
-	ColorDialog.recentColors = mxSettings.getRecentColors(ColorDialog.recentColors);
-
 	// Handles opening files via drag and drop
 	this.addFileDropHandler([document]);
 	
@@ -99,10 +96,11 @@ App = function(editor, container, lightbox)
 			}
 		}
 		
-		window.Draw.loadPlugin = function(callback)
+		// Installs global callback for plugins
+		window.Draw.loadPlugin = mxUtils.bind(this, function(callback)
 		{
 			callback(this);
-		};
+		});
 	}
 
 	this.load();
@@ -348,81 +346,6 @@ App.getStoredMode = function()
 				mxscript('js/json/json2.min.js');
 			}
 		}
-
-		/**
-		 * Loading plugins.
-		 */
-		if (urlParams['plugins'] != '0' && urlParams['offline'] != '1')
-		{
-			var plugins = mxSettings.getPlugins();
-			var temp = urlParams['p'];
-			
-			if ((temp != null) || (plugins != null && plugins.length > 0))
-			{
-				// Workaround for need to load plugins now but wait for UI instance
-				App.DrawPlugins = [];
-				
-				// Global entry point for plugins is Draw.loadPlugin. This is the only
-				// long-term supported solution for access to the EditorUi instance.
-				window.Draw = new Object();
-				window.Draw.loadPlugin = function(callback)
-				{
-					App.DrawPlugins.push(callback);
-				};
-			}
-			
-			if (temp != null)
-			{
-				// Mapping from key to URL in App.plugins
-				var t = temp.split(';');
-				
-				for (var i = 0; i < t.length; i++)
-				{
-					var url = App.pluginRegistry[t[i]];
-					
-					if (url != null)
-					{
-						mxscript(url);
-					}
-					else if (window.console != null)
-					{
-						console.log('Unknown plugin:', t[i]);
-					}
-				}
-			}
-			
-			if (plugins != null && plugins.length > 0 && urlParams['plugins'] != '0')
-			{
-				// Loading plugins inside the asynchronous block below stops the page from loading so a 
-				// hardcoded message for the warning dialog is used since the resources are loadd below
-				var warning = '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';
-				var tmp = window.location.protocol + '//' + window.location.host;
-				var local = true;
-				
-				for (var i = 0; i < plugins.length && local; i++)
-				{
-					if (plugins[i].charAt(0) != '/' && plugins[i].substring(0, tmp.length) != tmp)
-					{
-						local = false;
-					}
-				}
-				
-				if (local || mxUtils.confirm(mxResources.replacePlaceholders(warning, [plugins.join('\n')]).replace(/\\n/g, '\n')))
-				{
-					for (var i = 0; i < plugins.length; i++)
-					{
-						try
-						{
-							mxscript(plugins[i]);
-						}
-						catch (e)
-						{
-							// ignore
-						}
-					}
-				}
-			}
-		}
 	}
 })();
 
@@ -553,6 +476,81 @@ App.main = function(callback)
 		{
 			mxscript(document.location.protocol + '//www.google.com/jsapi?autoload=%7B%22modules%22%3A%5B%7B%22name%22%3A%22picker%22%2C%22version%22%3A%221%22%2C%22language%22%3A%22' + mxClient.language + '%22%7D%5D%7D');
 		}
+
+		/**
+		 * Loading plugins.
+		 */
+		if (urlParams['plugins'] != '0' && urlParams['offline'] != '1')
+		{
+			var plugins = mxSettings.getPlugins();
+			var temp = urlParams['p'];
+			
+			if ((temp != null) || (plugins != null && plugins.length > 0))
+			{
+				// Workaround for need to load plugins now but wait for UI instance
+				App.DrawPlugins = [];
+				
+				// Global entry point for plugins is Draw.loadPlugin. This is the only
+				// long-term supported solution for access to the EditorUi instance.
+				window.Draw = new Object();
+				window.Draw.loadPlugin = function(callback)
+				{
+					App.DrawPlugins.push(callback);
+				};
+			}
+			
+			if (temp != null)
+			{
+				// Mapping from key to URL in App.plugins
+				var t = temp.split(';');
+				
+				for (var i = 0; i < t.length; i++)
+				{
+					var url = App.pluginRegistry[t[i]];
+					
+					if (url != null)
+					{
+						mxscript(url);
+					}
+					else if (window.console != null)
+					{
+						console.log('Unknown plugin:', t[i]);
+					}
+				}
+			}
+			
+			if (plugins != null && plugins.length > 0 && urlParams['plugins'] != '0')
+			{
+				// Loading plugins inside the asynchronous block below stops the page from loading so a 
+				// hardcoded message for the warning dialog is used since the resources are loadd below
+				var warning = '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';
+				var tmp = window.location.protocol + '//' + window.location.host;
+				var local = true;
+				
+				for (var i = 0; i < plugins.length && local; i++)
+				{
+					if (plugins[i].charAt(0) != '/' && plugins[i].substring(0, tmp.length) != tmp)
+					{
+						local = false;
+					}
+				}
+				
+				if (local || mxUtils.confirm(mxResources.replacePlaceholders(warning, [plugins.join('\n')]).replace(/\\n/g, '\n')))
+				{
+					for (var i = 0; i < plugins.length; i++)
+					{
+						try
+						{
+							mxscript(plugins[i]);
+						}
+						catch (e)
+						{
+							// ignore
+						}
+					}
+				}
+			}
+		}
 		
 		// Loads gapi for all browsers but IE8 and below if not disabled or if enabled and in embed mode
 		// Special case: Cannot load in asynchronous code below
@@ -706,10 +704,6 @@ App.prototype.fullscreenImage = (!mxClient.IS_SVG) ? IMAGE_PATH + '/fullscreen.p
  */
 App.prototype.timeout = 25000;
 
-// Restores app defaults for UI
-App.prototype.formatEnabled = urlParams['format'] != '0';
-App.prototype.formatWidth = (screen.width < 600) ? 0 : mxSettings.getFormatWidth();
-
 /**
  * Overriden UI settings depending on mode.
  */
@@ -1047,97 +1041,6 @@ App.prototype.init = function()
 		this.menubar.container.insertBefore(this.icon, this.menubar.container.firstChild);
 	}
 
-	if (isLocalStorage || mxClient.IS_CHROMEAPP)
-	{
-		/**
-		 * Persists current edge style.
-		 */
-		this.editor.graph.currentEdgeStyle = mxSettings.getCurrentEdgeStyle();
-		this.editor.graph.currentVertexStyle = mxSettings.getCurrentVertexStyle();
-		
-		// Updates UI to reflect current edge style
-		this.fireEvent(new mxEventObject('styleChanged', 'keys', [], 'values', [], 'cells', []));
-		
-		this.addListener('styleChanged', mxUtils.bind(this, function(sender, evt)
-		{
-			mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);
-			mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);
-			mxSettings.save();
-		}));
-
-		/**
-		 * Persists copy on connect switch.
-		 */
-		this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget());
-		this.fireEvent(new mxEventObject('copyConnectChanged'));
-		
-		this.addListener('copyConnectChanged', mxUtils.bind(this, function(sender, evt)
-		{
-			mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());
-			mxSettings.save();
-		}));
-		
-		/**
-		 * Persists default page format.
-		 */
-		this.editor.graph.pageFormat = mxSettings.getPageFormat();
-		
-		this.addListener('pageFormatChanged', mxUtils.bind(this, function(sender, evt)
-		{
-			mxSettings.setPageFormat(this.editor.graph.pageFormat);
-			mxSettings.save();
-		}));
-		
-		/**
-		 * Persists default grid color.
-		 */
-		this.editor.graph.view.gridColor = mxSettings.getGridColor();
-		
-		this.addListener('gridColorChanged', mxUtils.bind(this, function(sender, evt)
-		{
-			mxSettings.setGridColor(this.editor.graph.view.gridColor);
-			mxSettings.save();
-		}));
-
-		/**
-		 * Persists autosave switch in Chrome app.
-		 */
-		if (mxClient.IS_CHROMEAPP)
-		{
-			this.editor.addListener('autosaveChanged', mxUtils.bind(this, function(sender, evt)
-			{
-				mxSettings.setAutosave(this.editor.autosave);
-				mxSettings.save();
-			}));
-			
-			this.editor.autosave = mxSettings.getAutosave();
-		}
-		
-		/**
-		 * 
-		 */
-		if (this.sidebar != null)
-		{
-			this.sidebar.showPalette('search', mxSettings.settings.search);
-		}
-		
-		/**
-		 * Shows scratchpad if never shown.
-		 */
-		if (!this.editor.chromeless && this.sidebar != null && (mxSettings.settings.isNew ||
-			parseInt(mxSettings.settings.version || 0) <= 8))
-		{
-			this.toggleScratchpad();
-			mxSettings.save();
-		}
-
-		// Saves app defaults for UI
-		this.addListener('formatWidthChanged', function()
-		{
-			mxSettings.setFormatWidth(this.formatWidth);
-			mxSettings.save();
-		});
-	}
 };
 
 /**
diff --git a/war/js/diagramly/Editor.js b/war/js/diagramly/Editor.js
index ede5b9d39ee4d3d6f10ebb64056b18d35d319ebf..99113f5b1116b198e27128beddc4b30f30e45b80 100644
--- a/war/js/diagramly/Editor.js
+++ b/war/js/diagramly/Editor.js
@@ -38,7 +38,12 @@
 	 * Blank 1x1 pixel transparent PNG image.
 	 */
 	Editor.blankImage = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACklEQVR4nGMAAQAABQABDQottAAAAABJRU5ErkJggg==';
-	
+
+	/**
+	 * Default value for custom libraries in mxSettings.
+	 */
+	Editor.defaultCustomLibraries = [];
+
 	/**
 	 * Contains the default XML for an empty diagram.
 	 */
@@ -116,6 +121,9 @@
 	/**
 	 * Global configuration of the Editor
 	 * see https://desk.draw.io/solution/articles/16000058316
+	 * 
+	 * For defaultVertexStyle, defaultEdgeStyle and defaultLibraries, this must be called before
+	 * mxSettings.load via global config variable window.mxLoadSettings = false.
 	 */
 	Editor.configure = function(config)
 	{
@@ -126,23 +134,40 @@
 			ColorDialog.prototype.defaultColors = config.defaultColors || ColorDialog.prototype.defaultColors;
 			StyleFormatPanel.prototype.defaultColorSchemes = config.defaultColorSchemes || StyleFormatPanel.prototype.defaultColorSchemes;
 
-			// Overrides themes for default edge and vertex styles
-			var graphLoadStylesheet = Graph.prototype.loadStylesheet;
-			
-			Graph.prototype.loadStylesheet = function()
+			// Custom CSS injected directly into the page
+			if (config.css != null)
 			{
-				graphLoadStylesheet.apply(this, arguments);
+				var s = document.createElement('style');
+				s.setAttribute('type', 'text/css');
+				s.appendChild(document.createTextNode(config.css));
 				
-				if (config.defaultVertexStyle != null)
-				{
-					this.getStylesheet().putDefaultVertexStyle(config.defaultVertexStyle);
-				}
-				
-				if (config.defaultEdgeStyle != null)
-				{
-					this.getStylesheet().putDefaultEdgeStyle(config.defaultEdgeStyle);
-				}
-			};
+				var t = document.getElementsByTagName('script')[0];
+			  	t.parentNode.insertBefore(s, t);
+			}
+			
+			// Overrides default libraries
+			if (config.defaultLibraries != null)
+			{
+				Sidebar.prototype.defaultEntries = config.defaultLibraries;
+			}
+			
+			// Overrides default custom libraries
+			if (config.defaultCustomLibraries != null)
+			{
+				Editor.defaultCustomLibraries = config.defaultCustomLibraries;
+			}
+			
+			// Overrides default vertex style
+			if (config.defaultVertexStyle != null)
+			{
+				Graph.prototype.defaultVertexStyle = config.defaultVertexStyle;
+			}
+
+			// Overrides default edge style
+			if (config.defaultEdgeStyle != null)
+			{
+				Graph.prototype.defaultEdgeStyle = config.defaultEdgeStyle;
+			}
 		}
 	};
 
diff --git a/war/js/diagramly/EditorUi.js b/war/js/diagramly/EditorUi.js
index 2cdef6d0622b0240b153b5076dbd7a79e8463b51..95c4d91ed9238f9d4e5a01f502146db0c0110db4 100644
--- a/war/js/diagramly/EditorUi.js
+++ b/war/js/diagramly/EditorUi.js
@@ -90,7 +90,12 @@
 	 * Specifies if PDF export with pages is enabled.
 	 */
 	EditorUi.prototype.pdfPageExport = true;
-	
+
+	/**
+	 * Restores app defaults for UI
+	 */
+	EditorUi.prototype.formatEnabled = urlParams['format'] != '0';
+
 	/**
 	 * Capability check for canvas export
 	 */
@@ -4293,34 +4298,44 @@
 			
 			img.onload = mxUtils.bind(this, function()
 			{
-				var canvas = document.createElement('canvas');
-				var w = parseInt(svgRoot.getAttribute('width'));
-				var h = parseInt(svgRoot.getAttribute('height'));
-				scale = (scale != null) ? scale : 1;
-				
-				if (width != null)
-				{
-					scale = (!limitHeight) ? width / w : Math.min(1, Math.min((width * 3) / (h * 4), width / w));
-				}
-				
-				w = Math.ceil(scale * w) + 2 * border;
-				h = Math.ceil(scale * h) + 2 * border;
-				
-				canvas.setAttribute('width', w);
-		   		canvas.setAttribute('height', h);
-		   		var ctx = canvas.getContext('2d');
-		   		
-		   		if (bg != null)
+		   		try
 		   		{
-		   			ctx.beginPath();
-					ctx.rect(0, 0, w, h);
-					ctx.fillStyle = bg;
-					ctx.fill();
+		   			var canvas = document.createElement('canvas');
+					var w = parseInt(svgRoot.getAttribute('width'));
+					var h = parseInt(svgRoot.getAttribute('height'));
+					scale = (scale != null) ? scale : 1;
+					
+					if (width != null)
+					{
+						scale = (!limitHeight) ? width / w : Math.min(1, Math.min((width * 3) / (h * 4), width / w));
+					}
+					
+					w = Math.ceil(scale * w) + 2 * border;
+					h = Math.ceil(scale * h) + 2 * border;
+					
+					canvas.setAttribute('width', w);
+			   		canvas.setAttribute('height', h);
+			   		var ctx = canvas.getContext('2d');
+			   		
+			   		if (bg != null)
+			   		{
+			   			ctx.beginPath();
+						ctx.rect(0, 0, w, h);
+						ctx.fillStyle = bg;
+						ctx.fill();
+			   		}
+
+			   		ctx.scale(scale, scale);
+					ctx.drawImage(img, border / scale, border / scale);
+					callback(canvas);
+		   		}
+		   		catch (e)
+		   		{
+		   			if (error != null)
+					{
+						error(e);
+					}
 		   		}
-				
-		   		ctx.scale(scale, scale);
-				ctx.drawImage(img, border / scale, border / scale);
-				callback(canvas);
 			});
 			
 			img.onerror = function(e)
@@ -5684,6 +5699,12 @@
 	var editorUiInit = EditorUi.prototype.init;
 	EditorUi.prototype.init = function()
 	{
+		// Must be set before UI is created in superclass
+		if (typeof window.mxSettings !== 'undefined')
+		{
+			this.formatWidth = mxSettings.getFormatWidth();
+		}
+		
 		var ui = this;
 		var graph = this.editor.graph;
 		
@@ -6412,8 +6433,114 @@
 		{
 			this.initializeEmbedMode();
 		}
+		
+		if (typeof window.mxSettings !== 'undefined')
+		{
+			this.installSettings();
+		}
 	};
 
+	/**
+	 * Creates the format panel and adds overrides.
+	 */
+	EditorUi.prototype.installSettings = function()
+	{
+		if (isLocalStorage || mxClient.IS_CHROMEAPP)
+		{
+			// Gets recent colors from settings
+			ColorDialog.recentColors = mxSettings.getRecentColors();
+
+			/**
+			 * Persists current edge style.
+			 */
+			this.editor.graph.currentEdgeStyle = mxSettings.getCurrentEdgeStyle();
+			this.editor.graph.currentVertexStyle = mxSettings.getCurrentVertexStyle();
+			
+			// Updates UI to reflect current edge style
+			this.fireEvent(new mxEventObject('styleChanged', 'keys', [], 'values', [], 'cells', []));
+			
+			this.addListener('styleChanged', mxUtils.bind(this, function(sender, evt)
+			{
+				mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);
+				mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);
+				mxSettings.save();
+			}));
+
+			/**
+			 * Persists copy on connect switch.
+			 */
+			this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget());
+			this.fireEvent(new mxEventObject('copyConnectChanged'));
+			
+			this.addListener('copyConnectChanged', mxUtils.bind(this, function(sender, evt)
+			{
+				mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());
+				mxSettings.save();
+			}));
+			
+			/**
+			 * Persists default page format.
+			 */
+			this.editor.graph.pageFormat = mxSettings.getPageFormat();
+			
+			this.addListener('pageFormatChanged', mxUtils.bind(this, function(sender, evt)
+			{
+				mxSettings.setPageFormat(this.editor.graph.pageFormat);
+				mxSettings.save();
+			}));
+			
+			/**
+			 * Persists default grid color.
+			 */
+			this.editor.graph.view.gridColor = mxSettings.getGridColor();
+			
+			this.addListener('gridColorChanged', mxUtils.bind(this, function(sender, evt)
+			{
+				mxSettings.setGridColor(this.editor.graph.view.gridColor);
+				mxSettings.save();
+			}));
+
+			/**
+			 * Persists autosave switch in Chrome app.
+			 */
+			if (mxClient.IS_CHROMEAPP)
+			{
+				this.editor.addListener('autosaveChanged', mxUtils.bind(this, function(sender, evt)
+				{
+					mxSettings.setAutosave(this.editor.autosave);
+					mxSettings.save();
+				}));
+				
+				this.editor.autosave = mxSettings.getAutosave();
+			}
+			
+			/**
+			 * 
+			 */
+			if (this.sidebar != null)
+			{
+				this.sidebar.showPalette('search', mxSettings.settings.search);
+			}
+			
+			/**
+			 * Shows scratchpad if never shown.
+			 */
+			if (!this.editor.chromeless && this.sidebar != null && (mxSettings.settings.isNew ||
+				parseInt(mxSettings.settings.version || 0) <= 8))
+			{
+				this.toggleScratchpad();
+				mxSettings.save();
+			}
+
+			// Saves app defaults for UI
+			this.addListener('formatWidthChanged', function()
+			{
+				mxSettings.setFormatWidth(this.formatWidth);
+				mxSettings.save();
+			});
+		}
+	};
+	
 	/**
 	 * Creates the format panel and adds overrides.
 	 */
@@ -8543,7 +8670,7 @@
 							html = '<img title="draw.io is up to date." border="0" src="' + IMAGE_PATH + '/checkmark.gif"/>';
 							break;
 						case appCache.DOWNLOADING: // DOWNLOADING == 3
-							html = '<img title="Downloading new version" border="0" src="' + IMAGE_PATH + '/spin.gif"/>';
+							html = '<img title="Downloading new version..." border="0" src="' + IMAGE_PATH + '/spin.gif"/>';
 							break;
 						case appCache.UPDATEREADY:  // UPDATEREADY == 4
 							html = '<img title="' + mxUtils.htmlEntities(mxResources.get('restartForChangeRequired')) +
diff --git a/war/js/diagramly/Settings.js b/war/js/diagramly/Settings.js
index 4d30ac8c69051fb8198278adb5a5e7d7c33c2ecd..1c075679a44f01bb7d59956ba1233144796a920d 100644
--- a/war/js/diagramly/Settings.js
+++ b/war/js/diagramly/Settings.js
@@ -3,89 +3,84 @@
  * Copyright (c) 2006-2017, Gaudenz Alder
  */
 /**
- * Utility class for working with persisted application settings
+ * Contains current settings.
  */
 var mxSettings =
 {
+	/**
+	 * Defines current version of settings.
+	 */
+	currentVersion: 14,
+	
+	defaultFormatWidth: (screen.width < 600) ? '0' : '240',
+	
 	// NOTE: Hardcoded in index.html due to timing of JS loading
 	key: '.drawio-config',
 
-	settings:
-	{
-		language: '',
-		libraries: Sidebar.prototype.defaultEntries,
-		customLibraries: [],
-		plugins: [],
-		recentColors: [],
-		formatWidth: '240',
-		currentEdgeStyle: Graph.prototype.defaultEdgeStyle,
-		currentVertexStyle: Graph.prototype.defaultVertexStyle,
-		createTarget: false,
-		pageFormat: mxGraph.prototype.pageFormat,
-		search: true,
-		showStartScreen: true,
-		gridColor: mxGraphView.prototype.gridColor,
-		autosave: true,
-		version: 13,
-		// Only defined and true for new settings which haven't been saved
-		isNew: true
-	},
 	getLanguage: function()
 	{
-		return this.settings.language;
+		return mxSettings.settings.language;
 	},
 	setLanguage: function(lang)
 	{
-		this.settings.language = lang;
+		mxSettings.settings.language = lang;
 	},
 	getUi: function()
 	{
-		return this.settings.ui;
+		return mxSettings.settings.ui;
 	},
 	setUi: function(ui)
 	{
-		this.settings.ui = ui;
+		mxSettings.settings.ui = ui;
 	},
 	getShowStartScreen: function()
 	{
-		return this.settings.showStartScreen;
+		return mxSettings.settings.showStartScreen;
 	},
 	setShowStartScreen: function(showStartScreen)
 	{
-		this.settings.showStartScreen = showStartScreen;
+		mxSettings.settings.showStartScreen = showStartScreen;
 	},
 	getGridColor: function()
 	{
-		return this.settings.gridColor;
+		return mxSettings.settings.gridColor;
 	},
 	setGridColor: function(gridColor)
 	{
-		this.settings.gridColor = gridColor;
+		mxSettings.settings.gridColor = gridColor;
 	},
 	getAutosave: function()
 	{
-		return this.settings.autosave;
+		return mxSettings.settings.autosave;
 	},
 	setAutosave: function(autosave)
 	{
-		this.settings.autosave = autosave;
+		mxSettings.settings.autosave = autosave;
 	},
 	getLibraries: function()
 	{
-		return this.settings.libraries;
+		return mxSettings.settings.libraries;
 	},
 	setLibraries: function(libs)
 	{
-		this.settings.libraries = libs;
+		mxSettings.settings.libraries = libs;
 	},
 	addCustomLibrary: function(id)
 	{
 		// Makes sure to update the latest data from the localStorage
 		mxSettings.load();
 		
-		if (mxUtils.indexOf(this.settings.customLibraries, id) < 0)
+		if (mxUtils.indexOf(mxSettings.settings.customLibraries, id) < 0)
 		{
-			this.settings.customLibraries.push(id);
+			// Makes sure scratchpad is below search in sidebar
+			if (id === 'L.scratchpad')
+			{
+				mxSettings.settings.customLibraries.splice(0, 0, id);
+			}
+			else
+			{
+				mxSettings.settings.customLibraries.push(id);
+			}
 		}
 		
 		mxSettings.save();
@@ -94,68 +89,91 @@ var mxSettings =
 	{
 		// Makes sure to update the latest data from the localStorage
 		mxSettings.load();
-		mxUtils.remove(id, this.settings.customLibraries);
+		mxUtils.remove(id, mxSettings.settings.customLibraries);
 		mxSettings.save();
 	},
 	getCustomLibraries: function()
 	{
-		return this.settings.customLibraries;
+		return mxSettings.settings.customLibraries;
 	},
 	getPlugins: function()
 	{
-		return this.settings.plugins;
+		return mxSettings.settings.plugins;
 	},
 	setPlugins: function(plugins)
 	{
-		this.settings.plugins = plugins;
+		mxSettings.settings.plugins = plugins;
 	},
 	getRecentColors: function()
 	{
-		return this.settings.recentColors;
+		return mxSettings.settings.recentColors;
 	},
 	setRecentColors: function(recentColors)
 	{
-		this.settings.recentColors = recentColors;
+		mxSettings.settings.recentColors = recentColors;
 	},
 	getFormatWidth: function()
 	{
-		return parseInt(this.settings.formatWidth);
+		return parseInt(mxSettings.settings.formatWidth);
 	},
 	setFormatWidth: function(formatWidth)
 	{
-		this.settings.formatWidth = formatWidth;
+		mxSettings.settings.formatWidth = formatWidth;
 	},
 	getCurrentEdgeStyle: function()
 	{
-		return this.settings.currentEdgeStyle;
+		return mxSettings.settings.currentEdgeStyle;
 	},
 	setCurrentEdgeStyle: function(value)
 	{
-		this.settings.currentEdgeStyle = value;
+		mxSettings.settings.currentEdgeStyle = value;
 	},
 	getCurrentVertexStyle: function()
 	{
-		return this.settings.currentVertexStyle;
+		return mxSettings.settings.currentVertexStyle;
 	},
 	setCurrentVertexStyle: function(value)
 	{
-		this.settings.currentVertexStyle = value;
+		mxSettings.settings.currentVertexStyle = value;
 	},
 	isCreateTarget: function()
 	{
-		return this.settings.createTarget;
+		return mxSettings.settings.createTarget;
 	},
 	setCreateTarget: function(value)
 	{
-		this.settings.createTarget = value;
+		mxSettings.settings.createTarget = value;
 	},
 	getPageFormat: function()
 	{
-		return this.settings.pageFormat;
+		return mxSettings.settings.pageFormat;
 	},
 	setPageFormat: function(value)
 	{
-		this.settings.pageFormat = value;
+		mxSettings.settings.pageFormat = value;
+	},
+	init: function()
+	{
+		mxSettings.settings = 
+		{
+			language: '',
+			libraries: Sidebar.prototype.defaultEntries,
+			customLibraries: Editor.defaultCustomLibraries,
+			plugins: [],
+			recentColors: [],
+			formatWidth: mxSettings.defaultFormatWidth,
+			currentEdgeStyle: Graph.prototype.defaultEdgeStyle,
+			currentVertexStyle: Graph.prototype.defaultVertexStyle,
+			createTarget: false,
+			pageFormat: mxGraph.prototype.pageFormat,
+			search: true,
+			showStartScreen: true,
+			gridColor: mxGraphView.prototype.gridColor,
+			autosave: true,
+			version: mxSettings.currentVersion,
+			// Only defined and true for new settings which haven't been saved
+			isNew: true
+		};
 	},
 	save: function()
 	{
@@ -163,9 +181,9 @@ var mxSettings =
 		{
 			try
 			{
-				delete this.settings.isNew;
-				this.settings.version = 12;
-				localStorage.setItem(mxSettings.key, JSON.stringify(this.settings));
+				delete mxSettings.settings.isNew;
+				mxSettings.settings.version = mxSettings.currentVersion;
+				localStorage.setItem(mxSettings.key, JSON.stringify(mxSettings.settings));
 			}
 			catch (e)
 			{
@@ -179,97 +197,102 @@ var mxSettings =
 		{
 			mxSettings.parse(localStorage.getItem(mxSettings.key));
 		}
+
+		if (mxSettings.settings == null)
+		{
+			mxSettings.init();
+		}
 	},
 	parse: function(value)
 	{
 		if (value != null)
 		{
-			this.settings = JSON.parse(value);
+			mxSettings.settings = JSON.parse(value);
 
-			if (this.settings.plugins == null)
+			if (mxSettings.settings.plugins == null)
 			{
-				this.settings.plugins = [];
+				mxSettings.settings.plugins = [];
 			}
 			
-			if (this.settings.recentColors == null)
+			if (mxSettings.settings.recentColors == null)
 			{
-				this.settings.recentColors = [];
+				mxSettings.settings.recentColors = [];
 			}
 			
-			if (this.settings.libraries == null)
+			if (mxSettings.settings.libraries == null)
 			{
-				this.settings.libraries = Sidebar.prototype.defaultEntries;
+				mxSettings.settings.libraries = Sidebar.prototype.defaultEntries;
 			}
 			
-			if (this.settings.customLibraries == null)
+			if (mxSettings.settings.customLibraries == null)
 			{
-				this.settings.customLibraries = [];
+				mxSettings.settings.customLibraries = Editor.defaultCustomLibraries;
 			}
 			
-			if (this.settings.ui == null)
+			if (mxSettings.settings.ui == null)
 			{
-				this.settings.ui = '';
+				mxSettings.settings.ui = '';
 			}
 			
-			if (this.settings.formatWidth == null)
+			if (mxSettings.settings.formatWidth == null)
 			{
-				this.settings.formatWidth = '240';
+				mxSettings.settings.formatWidth = mxSettings.defaultFormatWidth;
 			}
 			
-			if (this.settings.lastAlert != null)
+			if (mxSettings.settings.lastAlert != null)
 			{
-				delete this.settings.lastAlert;
+				delete mxSettings.settings.lastAlert;
 			}
 			
-			if (this.settings.currentEdgeStyle == null)
+			if (mxSettings.settings.currentEdgeStyle == null)
 			{
-				this.settings.currentEdgeStyle = Graph.prototype.defaultEdgeStyle;
+				mxSettings.settings.currentEdgeStyle = Graph.prototype.defaultEdgeStyle;
 			}
-			else if (this.settings.version <= 10)
+			else if (mxSettings.settings.version <= 10)
 			{
 				// Adds new defaults for jetty size and loop routing
-				this.settings.currentEdgeStyle['orthogonalLoop'] = 1;
-				this.settings.currentEdgeStyle['jettySize'] = 'auto';
+				mxSettings.settings.currentEdgeStyle['orthogonalLoop'] = 1;
+				mxSettings.settings.currentEdgeStyle['jettySize'] = 'auto';
 			}
 			
-			if (this.settings.currentVertexStyle == null)
+			if (mxSettings.settings.currentVertexStyle == null)
 			{
-				this.settings.currentVertexStyle = Graph.prototype.defaultEdgeStyle;
+				mxSettings.settings.currentVertexStyle = Graph.prototype.defaultVertexStyle;
 			}
 			
-			if (this.settings.createTarget == null)
+			if (mxSettings.settings.createTarget == null)
 			{
-				this.settings.createTarget = false;
+				mxSettings.settings.createTarget = false;
 			}
 			
-			if (this.settings.pageFormat == null)
+			if (mxSettings.settings.pageFormat == null)
 			{
-				this.settings.pageFormat = mxGraph.prototype.pageFormat;
+				mxSettings.settings.pageFormat = mxGraph.prototype.pageFormat;
 			}
 			
-			if (this.settings.search == null)
+			if (mxSettings.settings.search == null)
 			{
-				this.settings.search = true;
+				mxSettings.settings.search = true;
 			}
 			
-			if (this.settings.showStartScreen == null)
+			if (mxSettings.settings.showStartScreen == null)
 			{
-				this.settings.showStartScreen = true;
+				mxSettings.settings.showStartScreen = true;
 			}		
 			
-			if (this.settings.gridColor == null)
+			if (mxSettings.settings.gridColor == null)
 			{
-				this.settings.gridColor = mxGraphView.prototype.gridColor;
+				mxSettings.settings.gridColor = mxGraphView.prototype.gridColor;
 			}
 			
-			if (this.settings.autosave == null)
+			if (mxSettings.settings.autosave == null)
 			{
-				this.settings.autosave = true;
+				mxSettings.settings.autosave = true;
 			}
 			
-			if (this.settings.scratchpadSeen != null)
+			if (mxSettings.settings.scratchpadSeen != null)
 			{
-				delete this.settings.scratchpadSeen;
+				delete mxSettings.settings.scratchpadSeen;
 			}
 		}
 	},
diff --git a/war/js/diagramly/vsdx/VsdxExport.js b/war/js/diagramly/vsdx/VsdxExport.js
index 7c44b31195de1d7e4844b66a4f42d92f020a9a1b..1cd1db02881b52e1283bd9366363d9ea78b34f35 100644
--- a/war/js/diagramly/vsdx/VsdxExport.js
+++ b/war/js/diagramly/vsdx/VsdxExport.js
@@ -372,6 +372,7 @@ function VsdxExport(editorUi, resDir)
 		shape.setAttribute("FillStyle", "0");
 		shape.setAttribute("TextStyle", "0");
 		
+		var s = vsdxCanvas.state;
 		var points = state.absolutePoints;
 		var bounds = state.cellBounds;
 		
@@ -384,13 +385,13 @@ function VsdxExport(editorUi, resDir)
 		shape.appendChild(createCellElemScaled("LocPinX", hw, xmlDoc));
 		shape.appendChild(createCellElemScaled("LocPinY", hh, xmlDoc));
 
-		var s = vsdxCanvas.state;
+		vsdxCanvas.newEdge(shape, state, xmlDoc);
 		
 		var calcVsdxPoint = function(p, noHeight) 
 		{
 			var x = p.x, y = p.y;
-			x = (x - bounds.x + s.dx) * s.scale;
-			y = ((noHeight? 0 : bounds.height) - y + bounds.y - s.dy) * s.scale;
+			x = (x * s.scale - bounds.x + s.dx) ;
+			y = ((noHeight? 0 : bounds.height) - y * s.scale + bounds.y - s.dy) ;
 			return {x: x, y: y};
 		};
 
@@ -832,8 +833,8 @@ VsdxExport.prototype.PART_NAME = "PartName";
 VsdxExport.prototype.CONTENT_TYPES_XML = "[Content_Types].xml";
 VsdxExport.prototype.VISIO_PAGES_RELS = "visio/pages/_rels/";
 VsdxExport.prototype.ARROWS_MAP = {
-	"none|1": 0, "none|0": 0, "open|1": 1, "open|0": 1, "block|0": 4, "block|1": 14, "classic|1": 5, "classic|0": 17,
-	"oval|1": 10, "oval|0": 20, "diamond|1": 11, "diamond|0": 22, "blockThin|1": 2, "blockThin|0": 2, "dash|1": 23, "dash|0": 23,
+	"none|1": 0, "none|0": 0, "open|1": 1, "open|0": 1, "block|1": 4, "block|0": 14, "classic|1": 5, "classic|0": 17,
+	"oval|1": 10, "oval|0": 20, "diamond|1": 11, "diamond|0": 22, "blockThin|1": 2, "blockThin|0": 15, "dash|1": 23, "dash|0": 23,
 	"ERone|1": 24, "ERone|0": 24, "ERmandOne|1": 25, "ERmandOne|0": 25, "ERmany|1": 27, "ERmany|0": 27, "ERoneToMany|1": 28, "ERoneToMany|0": 28,
 	"ERzeroToMany|1": 29, "ERzeroToMany|0": 29, "ERzeroToOne|1": 30, "ERzeroToOne|0": 30, "openAsync|1": 9, "openAsync|0": 9
 };
diff --git a/war/js/diagramly/vsdx/mxVsdxCanvas2D.js b/war/js/diagramly/vsdx/mxVsdxCanvas2D.js
index 5f0825b13b1e64b46e79409142fe1838866f9cdc..e0ff06c320a3afc31eb3516e7aedd457df202948 100644
--- a/war/js/diagramly/vsdx/mxVsdxCanvas2D.js
+++ b/war/js/diagramly/vsdx/mxVsdxCanvas2D.js
@@ -82,6 +82,21 @@ mxVsdxCanvas2D.prototype.newShape = function (shape, cellState, xmlDoc)
 	this.createGeoSec();
 };
 
+
+/**
+ * Function: newEdge
+ *  
+ * Create a new edge.
+ */
+mxVsdxCanvas2D.prototype.newEdge = function (shape, cellState, xmlDoc)
+{
+	this.shape = shape;
+	this.cellState = cellState;
+	this.xmGeo = cellState.cellBounds;
+	var s = this.state;
+	this.xmlDoc = xmlDoc;
+};
+
 /**
  * Function: endShape
  *  
@@ -256,6 +271,9 @@ mxVsdxCanvas2D.prototype.ellipse = function(x, y, w, h)
  */
 mxVsdxCanvas2D.prototype.moveTo = function(x, y)
 {
+	//MoveTo inside a geo usually produce incorrect fill
+	if (this.geoStepIndex > 1)	this.createGeoSec();
+	
 	this.lastMoveToX = x;
 	this.lastMoveToY = y;
 	this.lastX = x;
@@ -578,16 +596,19 @@ mxVsdxCanvas2D.prototype.text = function(x, y, w, h, str, align, valign, wrap, f
 		var s = this.state;
 		var geo = this.xmGeo;
 
-		var strRect = mxUtils.getSizeForString(str, null, null, w > 0? w : null);
+		var fontSize = this.cellState.style["fontSize"];
+		var fontFamily = this.cellState.style["fontFamily"];
+
+		var strRect = mxUtils.getSizeForString(str, fontSize, fontFamily);
 
 		var wShift = 0;
 		var hShift = 0;
 		
 		switch(align) 
 		{
-			case "right": wShift = strRect.width/4; break;
+			case "right": wShift = strRect.width/2; break;
 			//case "center": wShift = 0; break;
-			case "left": wShift = -strRect.width/4; break;
+			case "left": wShift = -strRect.width/2; break;
 		}
 		
 		switch(valign) 
@@ -597,14 +618,12 @@ mxVsdxCanvas2D.prototype.text = function(x, y, w, h, str, align, valign, wrap, f
 			case "bottom": hShift = -strRect.height/2; break;
 		}
 
-		h = h > 0 ? h : strRect.height; 
-		w = w > 0 ? w : strRect.width;
-			
-//		h = h > 0 ? h : geo.height; 
-//		w = w > 0 ? w : geo.width;
 		w = w * s.scale;
 		h = h * s.scale;
-		
+
+		h = Math.max(h, strRect.height); 
+		w = Math.max(w, strRect.width);
+			
 		x = (x - geo.x + s.dx) * s.scale;
 		y = (geo.height - y + geo.y - s.dy) * s.scale;
 
@@ -618,28 +637,29 @@ mxVsdxCanvas2D.prototype.text = function(x, y, w, h, str, align, valign, wrap, f
 
 		if (rotation != 0)
 			this.shape.appendChild(this.createCellElemScaled("TxtAngle", (360 - rotation) * Math.PI / 180));
+		//TODO Currently, we support a single text block formatting. Later, HTML label should be analysed and split into parts
+		var charSect = this.xmlDoc.createElement("Section");
+		charSect.setAttribute('N', 'Character');
+		var charRow = this.xmlDoc.createElement("Row");
+		charRow.setAttribute('IX', 0);
+		
+		var fontColor = this.cellState.style["fontColor"];
+		if (fontColor)	charRow.appendChild(this.createCellElem("Color", fontColor));
+		
+		if (fontSize)	charRow.appendChild(this.createCellElemScaled("Size", fontSize * 0.97)); //the magic number 0.97 is needed such that text do not overflow
+		
+		if (fontFamily)	charRow.appendChild(this.createCellElem("Font", fontFamily));
+		
+		charSect.appendChild(charRow);
+		this.shape.appendChild(charSect);
 		
 		var text = this.xmlDoc.createElement("Text");
+		var cp = this.xmlDoc.createElement("cp");
+		cp.setAttribute('IX', 0);
+		text.appendChild(cp);
 		text.textContent = str;
 		this.shape.appendChild(text);
-//		
-//		var elem = this.createElement('text');
-//		elem.setAttribute('x', this.format(x));
-//		elem.setAttribute('y', this.format(y));
-//		elem.setAttribute('w', this.format(w));
-//		elem.setAttribute('h', this.format(h));
-//		elem.setAttribute('str', str);
-//		
-//		if (align != null)
-//		{
-//			elem.setAttribute('align', align);
-//		}
-//		
-//		if (valign != null)
-//		{
-//			elem.setAttribute('valign', valign);
-//		}
-//		
+		
 //		elem.setAttribute('wrap', (wrap) ? '1' : '0');
 //		
 //		if (format == null)
@@ -659,17 +679,10 @@ mxVsdxCanvas2D.prototype.text = function(x, y, w, h, str, align, valign, wrap, f
 //			elem.setAttribute('clip', (clip) ? '1' : '0');
 //		}
 //		
-//		if (rotation != null)
-//		{
-//			elem.setAttribute('rotation', rotation);
-//		}
-//		
 //		if (dir != null)
 //		{
 //			elem.setAttribute('dir', dir);
 //		}
-//		
-//		this.root.appendChild(elem);
 	}
 };
 
diff --git a/war/js/embed-static.min.js b/war/js/embed-static.min.js
index 964c5c30834a93c05d24b9d5f20638dfe9a68be2..a84614f2877ab6e7f10f112e5095c2ac3be4861c 100644
--- a/war/js/embed-static.min.js
+++ b/war/js/embed-static.min.js
@@ -184,7 +184,7 @@ f)+"\n"+t+"}":"{"+x.join(",")+"}";f=t;return l}}"function"!==typeof Date.prototy
 e=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,f,g,h={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},k;"function"!==typeof JSON.stringify&&(JSON.stringify=function(a,b,d){var e;g=f="";if("number"===typeof d)for(e=0;e<d;e+=1)g+=" ";else"string"===typeof d&&(g=d);if((k=b)&&"function"!==typeof b&&("object"!==typeof b||"number"!==typeof b.length))throw Error("JSON.stringify");return c("",{"":a})});
 "function"!==typeof JSON.parse&&(JSON.parse=function(a,b){function c(a,d){var e,f,g=a[d];if(g&&"object"===typeof g)for(e in g)Object.prototype.hasOwnProperty.call(g,e)&&(f=c(g,e),void 0!==f?g[e]=f:delete g[e]);return b.call(a,d,g)}var e;a=""+a;d.lastIndex=0;d.test(a)&&(a=a.replace(d,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)}));if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,
 "]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return e=eval("("+a+")"),"function"===typeof b?c({"":e},""):e;throw new SyntaxError("JSON.parse");})})();var mxBasePath="https://www.draw.io/mxgraph/",mxLoadStylesheets=mxLoadResources=!1,mxLanguage="en";window.urlParams=window.urlParams||{};window.MAX_REQUEST_SIZE=window.MAX_REQUEST_SIZE||10485760;window.MAX_AREA=window.MAX_AREA||225E6;window.EXPORT_URL=window.EXPORT_URL||"/export";window.SAVE_URL=window.SAVE_URL||"/save";window.OPEN_URL=window.OPEN_URL||"/open";window.RESOURCES_PATH=window.RESOURCES_PATH||"resources";window.RESOURCE_BASE=window.RESOURCE_BASE||window.RESOURCES_PATH+"/grapheditor";window.STENCIL_PATH=window.STENCIL_PATH||"stencils";window.IMAGE_PATH=window.IMAGE_PATH||"images";
-window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"6.7.8",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
+window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"6.7.9",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
 0>navigator.userAgent.indexOf("Edge/"),IS_OP:0<=navigator.userAgent.indexOf("Opera/")||0<=navigator.userAgent.indexOf("OPR/"),IS_OT:0<=navigator.userAgent.indexOf("Presto/")&&0>navigator.userAgent.indexOf("Presto/2.4.")&&0>navigator.userAgent.indexOf("Presto/2.3.")&&0>navigator.userAgent.indexOf("Presto/2.2.")&&0>navigator.userAgent.indexOf("Presto/2.1.")&&0>navigator.userAgent.indexOf("Presto/2.0.")&&0>navigator.userAgent.indexOf("Presto/1."),IS_SF:0<=navigator.userAgent.indexOf("AppleWebKit/")&&
 0>navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_IOS:navigator.userAgent.match(/(iPad|iPhone|iPod)/g)?!0:!1,IS_GC:0<=navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_CHROMEAPP:null!=window.chrome&&null!=chrome.app&&null!=chrome.app.runtime,IS_FF:0<=navigator.userAgent.indexOf("Firefox/"),IS_MT:0<=navigator.userAgent.indexOf("Firefox/")&&0>navigator.userAgent.indexOf("Firefox/1.")&&0>navigator.userAgent.indexOf("Firefox/2.")||0<=navigator.userAgent.indexOf("Iceweasel/")&&
 0>navigator.userAgent.indexOf("Iceweasel/1.")&&0>navigator.userAgent.indexOf("Iceweasel/2.")||0<=navigator.userAgent.indexOf("SeaMonkey/")&&0>navigator.userAgent.indexOf("SeaMonkey/1.")||0<=navigator.userAgent.indexOf("Iceape/")&&0>navigator.userAgent.indexOf("Iceape/1."),IS_SVG:0<=navigator.userAgent.indexOf("Firefox/")||0<=navigator.userAgent.indexOf("Iceweasel/")||0<=navigator.userAgent.indexOf("Seamonkey/")||0<=navigator.userAgent.indexOf("Iceape/")||0<=navigator.userAgent.indexOf("Galeon/")||
@@ -1629,12 +1629,12 @@ h=d.getAttribute("h"),g=null==g?80:parseInt(g,10),h=null==h?80:parseInt(h,10);b(
 "#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=8;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGuide.prototype.isEnabledForEvent=function(a){return!mxEvent.isAltDown(a)};var b=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(a){return mxEvent.isControlDown(a)||b.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=!0;mxConnectionHandler.prototype.cursor="crosshair";mxConnectionHandler.prototype.createEdgeState=function(a){a=this.graph.createCurrentEdgeStyle();a=this.graph.createEdge(null,null,null,null,null,a);a=new mxCellState(this.graph.view,a,this.graph.getCellStyle(a));for(var b in this.graph.currentEdgeStyle)a.style[b]=
 this.graph.currentEdgeStyle[b];return a};var c=mxConnectionHandler.prototype.createShape;mxConnectionHandler.prototype.createShape=function(){var a=c.apply(this,arguments);a.isDashed="1"==this.graph.currentEdgeStyle[mxConstants.STYLE_DASHED];return a};mxConnectionHandler.prototype.updatePreview=function(a){};var d=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var a=d.apply(this,arguments),b=a.getCell;a.getCell=mxUtils.bind(this,function(a){var c=
-b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",html:"1",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");
-null!=this.currentEdgeStyle.rounded&&(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(H){}return d}if(null!=
-a.shape)if(null!=a.shape.stencil){if(null!=a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};
-Graph.prototype.isValidRoot=function(a){for(var b=this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget",
-"1"))};Graph.prototype.createGroupCell=function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
+b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");null!=this.currentEdgeStyle.rounded&&
+(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(H){}return d}if(null!=a.shape)if(null!=a.shape.stencil){if(null!=
+a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};Graph.prototype.isValidRoot=function(a){for(var b=
+this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget","1"))};Graph.prototype.createGroupCell=
+function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
 arguments);null!=b&&(b.width+=10,b.height+=4,this.gridEnabled&&(b.width=this.snap(b.width),b.height=this.snap(b.height)));return b};Graph.prototype.turnShapes=function(a){var b=this.getModel(),c=[];b.beginUpdate();try{for(var d=0;d<a.length;d++){var e=a[d];if(b.isEdge(e)){var f=b.getTerminal(e,!0),g=b.getTerminal(e,!1);b.setTerminal(e,g,!0);b.setTerminal(e,f,!1);var h=b.getGeometry(e);if(null!=h){h=h.clone();null!=h.points&&h.points.reverse();var k=h.getTerminalPoint(!0),l=h.getTerminalPoint(!1);
 h.setTerminalPoint(k,!1);h.setTerminalPoint(l,!0);b.setGeometry(e,h);var m=this.view.getState(e),v=this.view.getState(f),n=this.view.getState(g);if(null!=m){var p=null!=v?this.getConnectionConstraint(m,v,!0):null,q=null!=n?this.getConnectionConstraint(m,n,!1):null;this.setConnectionConstraint(e,f,!0,q);this.setConnectionConstraint(e,g,!1,p)}c.push(e)}}else if(b.isVertex(e)&&(h=this.getCellGeometry(e),null!=h)){h=h.clone();h.x+=h.width/2-h.height/2;h.y+=h.height/2-h.width/2;var r=h.width;h.width=h.height;
 h.height=r;b.setGeometry(e,h);var t=this.view.getState(e);if(null!=t){var u=t.style[mxConstants.STYLE_DIRECTION]||"east";"east"==u?u="south":"south"==u?u="west":"west"==u?u="north":"north"==u&&(u="east");this.setCellStyles(mxConstants.STYLE_DIRECTION,u,[e])}c.push(e)}}}finally{b.endUpdate()}return c};Graph.prototype.processChange=function(a){mxGraph.prototype.processChange.apply(this,arguments);if(a instanceof mxValueChange&&null!=a.cell.value&&"object"==typeof a.cell.value){var b=this.model.getDescendants(a.cell);
diff --git a/war/js/mxgraph/Graph.js b/war/js/mxgraph/Graph.js
index 80b74ff357ef284aec91ad31e1bb5c04aea3c66c..86eb9d38b4f5acba36f59d8e7e3354d6a7d274b3 100644
--- a/war/js/mxgraph/Graph.js
+++ b/war/js/mxgraph/Graph.js
@@ -3717,7 +3717,7 @@ if (typeof mxVertexHandler != 'undefined')
 		/**
 		 * Contains the default style for edges.
 		 */
-		Graph.prototype.defaultEdgeStyle = {'edgeStyle': 'orthogonalEdgeStyle', 'rounded': '0', 'html': '1',
+		Graph.prototype.defaultEdgeStyle = {'edgeStyle': 'orthogonalEdgeStyle', 'rounded': '0',
 			'jettySize': 'auto', 'orthogonalLoop': '1'};
 
 		/**
diff --git a/war/js/reader.min.js b/war/js/reader.min.js
index e80338f96ce26374058122d75cb7969656f3b36f..57141f15c11776101ece217cc6d5f90878afc1da 100644
--- a/war/js/reader.min.js
+++ b/war/js/reader.min.js
@@ -184,7 +184,7 @@ f)+"\n"+t+"}":"{"+x.join(",")+"}";f=t;return l}}"function"!==typeof Date.prototy
 e=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,f,g,h={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},k;"function"!==typeof JSON.stringify&&(JSON.stringify=function(a,b,d){var e;g=f="";if("number"===typeof d)for(e=0;e<d;e+=1)g+=" ";else"string"===typeof d&&(g=d);if((k=b)&&"function"!==typeof b&&("object"!==typeof b||"number"!==typeof b.length))throw Error("JSON.stringify");return c("",{"":a})});
 "function"!==typeof JSON.parse&&(JSON.parse=function(a,b){function c(a,d){var e,f,g=a[d];if(g&&"object"===typeof g)for(e in g)Object.prototype.hasOwnProperty.call(g,e)&&(f=c(g,e),void 0!==f?g[e]=f:delete g[e]);return b.call(a,d,g)}var e;a=""+a;d.lastIndex=0;d.test(a)&&(a=a.replace(d,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)}));if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,
 "]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return e=eval("("+a+")"),"function"===typeof b?c({"":e},""):e;throw new SyntaxError("JSON.parse");})})();var mxBasePath="https://www.draw.io/mxgraph/",mxLoadStylesheets=mxLoadResources=!1,mxLanguage="en";window.urlParams=window.urlParams||{};window.MAX_REQUEST_SIZE=window.MAX_REQUEST_SIZE||10485760;window.MAX_AREA=window.MAX_AREA||225E6;window.EXPORT_URL=window.EXPORT_URL||"/export";window.SAVE_URL=window.SAVE_URL||"/save";window.OPEN_URL=window.OPEN_URL||"/open";window.RESOURCES_PATH=window.RESOURCES_PATH||"resources";window.RESOURCE_BASE=window.RESOURCE_BASE||window.RESOURCES_PATH+"/grapheditor";window.STENCIL_PATH=window.STENCIL_PATH||"stencils";window.IMAGE_PATH=window.IMAGE_PATH||"images";
-window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"6.7.8",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
+window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"6.7.9",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
 0>navigator.userAgent.indexOf("Edge/"),IS_OP:0<=navigator.userAgent.indexOf("Opera/")||0<=navigator.userAgent.indexOf("OPR/"),IS_OT:0<=navigator.userAgent.indexOf("Presto/")&&0>navigator.userAgent.indexOf("Presto/2.4.")&&0>navigator.userAgent.indexOf("Presto/2.3.")&&0>navigator.userAgent.indexOf("Presto/2.2.")&&0>navigator.userAgent.indexOf("Presto/2.1.")&&0>navigator.userAgent.indexOf("Presto/2.0.")&&0>navigator.userAgent.indexOf("Presto/1."),IS_SF:0<=navigator.userAgent.indexOf("AppleWebKit/")&&
 0>navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_IOS:navigator.userAgent.match(/(iPad|iPhone|iPod)/g)?!0:!1,IS_GC:0<=navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_CHROMEAPP:null!=window.chrome&&null!=chrome.app&&null!=chrome.app.runtime,IS_FF:0<=navigator.userAgent.indexOf("Firefox/"),IS_MT:0<=navigator.userAgent.indexOf("Firefox/")&&0>navigator.userAgent.indexOf("Firefox/1.")&&0>navigator.userAgent.indexOf("Firefox/2.")||0<=navigator.userAgent.indexOf("Iceweasel/")&&
 0>navigator.userAgent.indexOf("Iceweasel/1.")&&0>navigator.userAgent.indexOf("Iceweasel/2.")||0<=navigator.userAgent.indexOf("SeaMonkey/")&&0>navigator.userAgent.indexOf("SeaMonkey/1.")||0<=navigator.userAgent.indexOf("Iceape/")&&0>navigator.userAgent.indexOf("Iceape/1."),IS_SVG:0<=navigator.userAgent.indexOf("Firefox/")||0<=navigator.userAgent.indexOf("Iceweasel/")||0<=navigator.userAgent.indexOf("Seamonkey/")||0<=navigator.userAgent.indexOf("Iceape/")||0<=navigator.userAgent.indexOf("Galeon/")||
@@ -1629,12 +1629,12 @@ h=d.getAttribute("h"),g=null==g?80:parseInt(g,10),h=null==h?80:parseInt(h,10);b(
 "#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=8;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGuide.prototype.isEnabledForEvent=function(a){return!mxEvent.isAltDown(a)};var b=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(a){return mxEvent.isControlDown(a)||b.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=!0;mxConnectionHandler.prototype.cursor="crosshair";mxConnectionHandler.prototype.createEdgeState=function(a){a=this.graph.createCurrentEdgeStyle();a=this.graph.createEdge(null,null,null,null,null,a);a=new mxCellState(this.graph.view,a,this.graph.getCellStyle(a));for(var b in this.graph.currentEdgeStyle)a.style[b]=
 this.graph.currentEdgeStyle[b];return a};var c=mxConnectionHandler.prototype.createShape;mxConnectionHandler.prototype.createShape=function(){var a=c.apply(this,arguments);a.isDashed="1"==this.graph.currentEdgeStyle[mxConstants.STYLE_DASHED];return a};mxConnectionHandler.prototype.updatePreview=function(a){};var d=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var a=d.apply(this,arguments),b=a.getCell;a.getCell=mxUtils.bind(this,function(a){var c=
-b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",html:"1",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");
-null!=this.currentEdgeStyle.rounded&&(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(H){}return d}if(null!=
-a.shape)if(null!=a.shape.stencil){if(null!=a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};
-Graph.prototype.isValidRoot=function(a){for(var b=this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget",
-"1"))};Graph.prototype.createGroupCell=function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
+b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");null!=this.currentEdgeStyle.rounded&&
+(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(H){}return d}if(null!=a.shape)if(null!=a.shape.stencil){if(null!=
+a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};Graph.prototype.isValidRoot=function(a){for(var b=
+this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget","1"))};Graph.prototype.createGroupCell=
+function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
 arguments);null!=b&&(b.width+=10,b.height+=4,this.gridEnabled&&(b.width=this.snap(b.width),b.height=this.snap(b.height)));return b};Graph.prototype.turnShapes=function(a){var b=this.getModel(),c=[];b.beginUpdate();try{for(var d=0;d<a.length;d++){var e=a[d];if(b.isEdge(e)){var f=b.getTerminal(e,!0),g=b.getTerminal(e,!1);b.setTerminal(e,g,!0);b.setTerminal(e,f,!1);var h=b.getGeometry(e);if(null!=h){h=h.clone();null!=h.points&&h.points.reverse();var k=h.getTerminalPoint(!0),l=h.getTerminalPoint(!1);
 h.setTerminalPoint(k,!1);h.setTerminalPoint(l,!0);b.setGeometry(e,h);var m=this.view.getState(e),v=this.view.getState(f),n=this.view.getState(g);if(null!=m){var p=null!=v?this.getConnectionConstraint(m,v,!0):null,q=null!=n?this.getConnectionConstraint(m,n,!1):null;this.setConnectionConstraint(e,f,!0,q);this.setConnectionConstraint(e,g,!1,p)}c.push(e)}}else if(b.isVertex(e)&&(h=this.getCellGeometry(e),null!=h)){h=h.clone();h.x+=h.width/2-h.height/2;h.y+=h.height/2-h.width/2;var r=h.width;h.width=h.height;
 h.height=r;b.setGeometry(e,h);var t=this.view.getState(e);if(null!=t){var u=t.style[mxConstants.STYLE_DIRECTION]||"east";"east"==u?u="south":"south"==u?u="west":"west"==u?u="north":"north"==u&&(u="east");this.setCellStyles(mxConstants.STYLE_DIRECTION,u,[e])}c.push(e)}}}finally{b.endUpdate()}return c};Graph.prototype.processChange=function(a){mxGraph.prototype.processChange.apply(this,arguments);if(a instanceof mxValueChange&&null!=a.cell.value&&"object"==typeof a.cell.value){var b=this.model.getDescendants(a.cell);
diff --git a/war/js/viewer.min.js b/war/js/viewer.min.js
index 4f4bbd6eb3c39b6f09e05e9e4623c5aac61a9611..4407eee409ee6a44af2628358721e4dd0a0018ed 100644
--- a/war/js/viewer.min.js
+++ b/war/js/viewer.min.js
@@ -45,8 +45,8 @@ function(){return null!==this.k};f.prototype.V=function(){return this.h&&decodeU
 this.l};f.prototype.ba=function(a){if("object"===typeof a&&!(a instanceof Array)&&(a instanceof Object||"[object Array]"!==Object.prototype.toString.call(a))){var b=[],c=-1,d;for(d in a){var e=a[d];"string"===typeof e&&(b[++c]=d,b[++c]=e)}a=b}for(var b=[],c="",f=0;f<a.length;)d=a[f++],e=a[f++],b.push(c,encodeURIComponent(d.toString())),c="&",e&&b.push("=",encodeURIComponent(e.toString()));this.l=b.join("")};f.prototype.fa=function(a){this.o=a?a:null};f.prototype.Z=function(){return null!==this.o};
 var m=/^(?:([^:/?#]+):)?(?:\/\/(?:([^/?#]*)@)?([^/?#:@]*)(?::([0-9]+))?)?([^?#]+)?(?:\?([^#]*))?(?:#(.*))?$/,n=/[#\/\?@]/g,p=/[\#\?]/g;f.parse=a;f.create=function(a,d,e,k,g,l,m){a=new f(b(a,n),b(d,n),"string"==typeof e?encodeURIComponent(e):null,0<k?k.toString():null,b(g,p),null,"string"==typeof m?encodeURIComponent(m):null);l&&("string"===typeof l?a.O(l.replace(/[^?&=0-9A-Za-z_\-~.%]/g,c)):a.ba(l));return a};f.N=e;f.ma=d;f.ha={ua:function(b){return/\.html$/.test(a(b).U())?"text/html":"application/javascript"},
 N:function(b,c){return b?e(a(b),a(c)).toString():""+c}};return f}();"undefined"!==typeof window&&(window.URI=f);var g=void 0,k=void 0,l=void 0,m=void 0;(function(){function a(a){return"string"===typeof a?'url("'+a.replace(y,c)+'")':'url("about:blank")'}function c(a){return A[a]}function d(a,b){return a?f.ha.N(a,b):b}function p(a,b,c){if(!c)return null;var d=(""+a).match(v);return!d||d[1]&&!B.test(d[1])?null:c(a,b)}function z(a){return a.replace(/^-(?:apple|css|epub|khtml|moz|mso?|o|rim|wap|webkit|xv)-(?=[a-z])/,
-"")}var y=/[\n\f\r\"\'()*<>]/g,A={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},v=/^(?:([^:/?# ]+):)?/,B=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function E(f,k,g,l,m){f=z(f);var n=b[f];if(n&&"object"===typeof n){for(var q=n.cssPropBits,t=q&80,r=q&1536,u=NaN,x=0,C=0;x<k.length;++x){var v=k[x].toLowerCase(),y=v.charCodeAt(0),B,A,I,F,G,N;if(32===y)v="";else if(34===y)v=16===t?g?a(p(d(l,e(k[x].substring(1,v.length-1))),f,g)):"":
-q&8&&!(t&t-1)?v:"";else if("inherit"!==v){if(G=n.cssLitGroup){var L;if(!(L=n.cssLitMap)){L={};for(var P=G.length;0<=--P;)for(var W=G[P],ga=W.length;0<=--ga;)L[W[ga]]=c;L=n.cssLitMap=L}G=L}else G=c;if(N=G,N[z(v)]!==c)if(35===y&&/^#(?:[0-9a-f]{3}){1,2}$/.test(v))v=q&2?v:"";else if(48<=y&&57>=y)v=q&1?v:"";else if(B=v.charCodeAt(1),A=v.charCodeAt(2),I=48<=B&&57>=B,F=48<=A&&57>=A,43===y&&(I||46===B&&F))v=q&1?(I?"":"0")+v.substring(1):"";else if(45===y&&(I||46===B&&F))v=q&4?(I?"-":"-0")+v.substring(1):
+"")}var y=/[\n\f\r\"\'()*<>]/g,A={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},v=/^(?:([^:/?# ]+):)?/,B=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function E(f,k,g,l,m){f=z(f);var n=b[f];if(n&&"object"===typeof n){for(var q=n.cssPropBits,t=q&80,r=q&1536,u=NaN,x=0,C=0;x<k.length;++x){var v=k[x].toLowerCase(),y=v.charCodeAt(0),B,A,I,F,G,M;if(32===y)v="";else if(34===y)v=16===t?g?a(p(d(l,e(k[x].substring(1,v.length-1))),f,g)):"":
+q&8&&!(t&t-1)?v:"";else if("inherit"!==v){if(G=n.cssLitGroup){var L;if(!(L=n.cssLitMap)){L={};for(var P=G.length;0<=--P;)for(var W=G[P],ga=W.length;0<=--ga;)L[W[ga]]=c;L=n.cssLitMap=L}G=L}else G=c;if(M=G,M[z(v)]!==c)if(35===y&&/^#(?:[0-9a-f]{3}){1,2}$/.test(v))v=q&2?v:"";else if(48<=y&&57>=y)v=q&1?v:"";else if(B=v.charCodeAt(1),A=v.charCodeAt(2),I=48<=B&&57>=B,F=48<=A&&57>=A,43===y&&(I||46===B&&F))v=q&1?(I?"":"0")+v.substring(1):"";else if(45===y&&(I||46===B&&F))v=q&4?(I?"-":"-0")+v.substring(1):
 q&1?"0":"";else if(46===y&&I)v=q&1?"0"+v:"";else if('url("'===v.substring(0,5))v=g&&q&16?a(p(d(l,k[x].substring(5,v.length-2)),f,g)):"";else if("("===v.charAt(v.length-1))a:{G=k;L=x;v=1;P=L+1;for(y=G.length;P<y&&v;)W=G[P++],v+=")"===W?-1:/^[^"']*\($/.test(W);if(!v)for(v=G[L].toLowerCase(),y=z(v),G=G.splice(L,P-L,""),L=n.cssFns,P=0,W=L.length;P<W;++P)if(L[P].substring(0,y.length)==y){G[0]=G[G.length-1]="";E(L[P],G,g,l);v=v+G.join(" ")+")";break a}v=""}else v=r&&/^-?[a-z_][\w\-]*$/.test(v)&&!/__$/.test(v)?
 m&&512===r?k[x]+m:1024===r&&b[v]&&"number"===typeof b[v].oa?v:"":/^\w+$/.test(v)&&64===t&&q&8?u+1===C?(k[u]=k[u].substring(0,k[u].length-1)+" "+v+'"',""):(u=C,'"'+v+'"'):""}v&&(k[C++]=v)}1===C&&'url("about:blank")'===k[0]&&(C=0);k.length=C}else k.length=0}}();var G=/^(active|after|before|blank|checked|default|disabled|drop|empty|enabled|first|first-child|first-letter|first-line|first-of-type|fullscreen|focus|hover|in-range|indeterminate|invalid|last-child|last-of-type|left|link|only-child|only-of-type|optional|out-of-range|placeholder-shown|read-only|read-write|required|right|root|scope|user-error|valid|visited)$/,
 F={};F[">"]=F["+"]=F["~"]=F;k=function(a,b,c){function d(d,l){function m(c,d,e){var g,l,m,p,t,r=!0;g="";c<d&&((t=a[c],"*"===t)?(++c,g=t):/^[a-zA-Z]/.test(t)&&(l=k(t.toLowerCase(),[]))&&("tagName"in l&&(t=l.tagName),++c,g=t));for(p=m=l="";r&&c<d;++c)if(t=a[c],"#"===t.charAt(0))/^#_|__$|[^\w#:\-]/.test(t)?r=!1:l+=t+f;else if("."===t)++c<d&&/^[0-9A-Za-z:_\-]+$/.test(t=a[c])&&!/^_|__$/.test(t)?l+="."+t:r=!1;else if(c+1<d&&"["===a[c]){++c;var E=a[c++].toLowerCase();t=q.m[g+"::"+E];t!==+t&&(t=q.m["*::"+
@@ -81,7 +81,7 @@ li:"HTMLLIElement",link:"HTMLLinkElement",map:"HTMLMapElement",mark:"HTMLElement
 s:"HTMLElement",samp:"HTMLElement",script:"HTMLScriptElement",section:"HTMLElement",select:"HTMLSelectElement",small:"HTMLElement",source:"HTMLSourceElement",span:"HTMLSpanElement",strike:"HTMLElement",strong:"HTMLElement",style:"HTMLStyleElement",sub:"HTMLElement",summary:"HTMLElement",sup:"HTMLElement",table:"HTMLTableElement",tbody:"HTMLTableSectionElement",td:"HTMLTableDataCellElement",textarea:"HTMLTextAreaElement",tfoot:"HTMLTableSectionElement",th:"HTMLTableHeaderCellElement",thead:"HTMLTableSectionElement",
 time:"HTMLTimeElement",title:"HTMLTitleElement",tr:"HTMLTableRowElement",track:"HTMLTrackElement",tt:"HTMLElement",u:"HTMLElement",ul:"HTMLUListElement","var":"HTMLElement",video:"HTMLVideoElement",wbr:"HTMLElement"};q.ELEMENT_DOM_INTERFACES=q.Q;q.P={NOT_LOADED:0,SAME_DOCUMENT:1,NEW_DOCUMENT:2};q.ueffects=q.P;q.J={"a::href":2,"area::href":2,"audio::src":1,"blockquote::cite":0,"command::icon":1,"del::cite":0,"form::action":2,"img::src":1,"input::src":1,"ins::cite":0,"q::cite":0,"video::poster":1,"video::src":1};
 q.URIEFFECTS=q.J;q.M={UNSANDBOXED:2,SANDBOXED:1,DATA:0};q.ltypes=q.M;q.I={"a::href":2,"area::href":2,"audio::src":2,"blockquote::cite":2,"command::icon":1,"del::cite":2,"form::action":2,"img::src":1,"input::src":1,"ins::cite":2,"q::cite":2,"video::poster":1,"video::src":2};q.LOADERTYPES=q.I;"undefined"!==typeof window&&(window.html4=q);a=function(a){function b(a,b){var c;if(ba.hasOwnProperty(b))c=ba[b];else{var d=b.match(T);c=d?String.fromCharCode(parseInt(d[1],10)):(d=b.match(D))?String.fromCharCode(parseInt(d[1],
-16)):Q&&X.test(b)?(Q.innerHTML="&"+b+";",d=Q.textContent,ba[b]=d):"&"+b+";"}return c}function c(a){return a.replace(Y,b)}function d(a){return(""+a).replace(K,"&amp;").replace(U,"&lt;").replace(ca,"&gt;").replace(Z,"&#34;")}function e(a){return a.replace(M,"&amp;$1").replace(U,"&lt;").replace(ca,"&gt;")}function k(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
+16)):Q&&X.test(b)?(Q.innerHTML="&"+b+";",d=Q.textContent,ba[b]=d):"&"+b+";"}return c}function c(a){return a.replace(Y,b)}function d(a){return(""+a).replace(K,"&amp;").replace(U,"&lt;").replace(ca,"&gt;").replace(Z,"&#34;")}function e(a){return a.replace(N,"&amp;$1").replace(U,"&lt;").replace(ca,"&gt;")}function k(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
 d=a+"";if(aa)d=d.split(e);else{for(var f=[],k=0,g;null!==(g=e.exec(d));)f.push(d.substring(k,g.index)),f.push(g[0]),k=g.index+g[0].length;f.push(d.substring(k));d=f}l(b,d,0,{r:!1,C:!1},c)}}function g(a,b,c,d,e){return function(){l(a,b,c,d,e)}}function l(b,c,d,e,f){try{b.H&&0==d&&b.H(f);for(var k,l,p,q=c.length;d<q;){var t=c[d++],r=c[d];switch(t){case "&":O.test(r)?(b.e&&b.e("&"+r,f,S,g(b,c,d,e,f)),d++):b.e&&b.e("&amp;",f,S,g(b,c,d,e,f));break;case "</":if(k=/^([-\w:]+)[^\'\"]*/.exec(r))if(k[0].length===
 r.length&&">"===c[d+1])d+=2,p=k[1].toLowerCase(),b.t&&b.t(p,f,S,g(b,c,d,e,f));else{var u=c,E=d,x=b,D=f,C=S,v=e,z=n(u,E);z?(x.t&&x.t(z.name,D,C,g(x,u,E,v,D)),d=z.next):d=u.length}else b.e&&b.e("&lt;/",f,S,g(b,c,d,e,f));break;case "<":if(k=/^([-\w:]+)\s*\/?/.exec(r))if(k[0].length===r.length&&">"===c[d+1]){d+=2;p=k[1].toLowerCase();b.w&&b.w(p,[],f,S,g(b,c,d,e,f));var W=a.f[p];W&da&&(d=m(c,{name:p,next:d,c:W},b,f,S,e))}else{var u=c,E=b,x=f,D=S,C=e,ha=n(u,d);ha?(E.w&&E.w(ha.name,ha.R,x,D,g(E,u,ha.next,
 C,x)),d=ha.c&da?m(u,ha,E,x,D,C):ha.next):d=u.length}else b.e&&b.e("&lt;",f,S,g(b,c,d,e,f));break;case "\x3c!--":if(!e.C){for(l=d+1;l<q&&(">"!==c[l]||!/--$/.test(c[l-1]));l++);if(l<q){if(b.A){var y=c.slice(d,l).join("");b.A(y.substr(0,y.length-2),f,S,g(b,c,l+1,e,f))}d=l+1}else e.C=!0}e.C&&b.e&&b.e("&lt;!--",f,S,g(b,c,d,e,f));break;case "<!":if(/^\w/.test(r)){if(!e.r){for(l=d+1;l<q&&">"!==c[l];l++);l<q?d=l+1:e.r=!0}e.r&&b.e&&b.e("&lt;!",f,S,g(b,c,d,e,f))}else b.e&&b.e("&lt;!",f,S,g(b,c,d,e,f));break;
@@ -92,9 +92,9 @@ if("attribs"in m)k=m.attribs;else throw Error("tagPolicy gave no attribs");var n
 a.f[b];if(!(d&(a.c.EMPTY|a.c.FOLDABLE))){if(d&a.c.OPTIONAL_ENDTAG)for(d=e.length;0<=--d;){var k=e[d].D;if(k===b)break;if(!(a.f[k]&a.c.OPTIONAL_ENDTAG))return}else for(d=e.length;0<=--d&&e[d].D!==b;);if(!(0>d)){for(k=e.length;--k>d;){var g=e[k].v;a.f[g]&a.c.OPTIONAL_ENDTAG||c.push("</",g,">")}d<e.length&&(b=e[d].v);e.length=d;c.push("</",b,">")}}}},pcdata:c,rcdata:c,cdata:c,endDoc:function(a){for(;e.length;e.length--)a.push("</",e[e.length-1].v,">")}})}function q(a,b,c,d,e){if(!e)return null;try{var k=
 f.parse(""+a);if(k&&(!k.K()||ga.test(k.W()))){var g=e(k,b,c,d);return g?g.toString():null}}catch(ja){}return null}function t(a,b,c,d,e){c||a(b+" removed",{S:"removed",tagName:b});if(d!==e){var f="changed";d&&!e?f="removed":!d&&e&&(f="added");a(b+"."+c+" "+f,{S:f,tagName:b,la:c,oldValue:d,newValue:e})}}function E(a,b,c){b=b+"::"+c;if(a.hasOwnProperty(b))return a[b];b="*::"+c;if(a.hasOwnProperty(b))return a[b]}function I(b,c,d,e,f){for(var k=0;k<c.length;k+=2){var g=c[k],l=c[k+1],m=l,n=null,p;if((p=
 b+"::"+g,a.m.hasOwnProperty(p))||(p="*::"+g,a.m.hasOwnProperty(p)))n=a.m[p];if(null!==n)switch(n){case a.d.NONE:break;case a.d.SCRIPT:l=null;f&&t(f,b,g,m,l);break;case a.d.STYLE:if("undefined"===typeof V){l=null;f&&t(f,b,g,m,l);break}var r=[];V(l,{declaration:function(b,c){var e=b.toLowerCase();P(e,c,d?function(b){return q(b,a.P.ja,a.M.ka,{TYPE:"CSS",CSS_PROP:e},d)}:null);c.length&&r.push(e+": "+c.join(" "))}});l=0<r.length?r.join(" ; "):null;f&&t(f,b,g,m,l);break;case a.d.ID:case a.d.IDREF:case a.d.IDREFS:case a.d.GLOBAL_NAME:case a.d.LOCAL_NAME:case a.d.CLASSES:l=
-e?e(l):l;f&&t(f,b,g,m,l);break;case a.d.URI:l=q(l,E(a.J,b,g),E(a.I,b,g),{TYPE:"MARKUP",XML_ATTR:g,XML_TAG:b},d);f&&t(f,b,g,m,l);break;case a.d.URI_FRAGMENT:l&&"#"===l.charAt(0)?(l=l.substring(1),l=e?e(l):l,null!==l&&void 0!==l&&(l="#"+l)):l=null;f&&t(f,b,g,m,l);break;default:l=null,f&&t(f,b,g,m,l)}else l=null,f&&t(f,b,g,m,l);c[k+1]=l}return c}function N(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&t(d,e,void 0,void 0,void 0);else return{attribs:I(e,f,b,c,d)}}}function L(a,b){var c=[];p(b)(a,
-c);return c.join("")}var V,P;"undefined"!==typeof window&&(V=window.parseCssDeclarations,P=window.sanitizeCssProperty);var ba={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},T=/^#(\d+)$/,D=/^#x([0-9A-Fa-f]+)$/,X=/^[A-Za-z][A-za-z0-9]+$/,Q="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,J=/\0/g,Y=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,O=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,K=/&/g,M=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,U=
-/[<]/g,ca=/>/g,Z=/\"/g,R=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,aa=3==="a,b".split(/(,)/).length,da=a.c.CDATA|a.c.RCDATA,S={},W={},ga=/^(?:https?|mailto|data)$/i,ea={};ea.pa=ea.escapeAttrib=d;ea.ra=ea.makeHtmlSanitizer=p;ea.sa=ea.makeSaxParser=k;ea.ta=ea.makeTagPolicy=N;ea.wa=ea.normalizeRCData=e;ea.xa=ea.sanitize=function(a,b,c,d){return L(a,N(b,c,d))};ea.ya=ea.sanitizeAttribs=I;ea.za=ea.sanitizeWithPolicy=L;ea.Ba=ea.unescapeEntities=c;return ea}(q);
+e?e(l):l;f&&t(f,b,g,m,l);break;case a.d.URI:l=q(l,E(a.J,b,g),E(a.I,b,g),{TYPE:"MARKUP",XML_ATTR:g,XML_TAG:b},d);f&&t(f,b,g,m,l);break;case a.d.URI_FRAGMENT:l&&"#"===l.charAt(0)?(l=l.substring(1),l=e?e(l):l,null!==l&&void 0!==l&&(l="#"+l)):l=null;f&&t(f,b,g,m,l);break;default:l=null,f&&t(f,b,g,m,l)}else l=null,f&&t(f,b,g,m,l);c[k+1]=l}return c}function M(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&t(d,e,void 0,void 0,void 0);else return{attribs:I(e,f,b,c,d)}}}function L(a,b){var c=[];p(b)(a,
+c);return c.join("")}var V,P;"undefined"!==typeof window&&(V=window.parseCssDeclarations,P=window.sanitizeCssProperty);var ba={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},T=/^#(\d+)$/,D=/^#x([0-9A-Fa-f]+)$/,X=/^[A-Za-z][A-za-z0-9]+$/,Q="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,J=/\0/g,Y=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,O=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,K=/&/g,N=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,U=
+/[<]/g,ca=/>/g,Z=/\"/g,R=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,aa=3==="a,b".split(/(,)/).length,da=a.c.CDATA|a.c.RCDATA,S={},W={},ga=/^(?:https?|mailto|data)$/i,ea={};ea.pa=ea.escapeAttrib=d;ea.ra=ea.makeHtmlSanitizer=p;ea.sa=ea.makeSaxParser=k;ea.ta=ea.makeTagPolicy=M;ea.wa=ea.normalizeRCData=e;ea.xa=ea.sanitize=function(a,b,c,d){return L(a,M(b,c,d))};ea.ya=ea.sanitizeAttribs=I;ea.za=ea.sanitizeWithPolicy=L;ea.Ba=ea.unescapeEntities=c;return ea}(q);
 c=a.sanitize;"undefined"!==typeof window&&(window.html=a,window.html_sanitize=c)})();
 var Base64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(a,b){var c="",d,e,f,g,k,l,m=0;for(null!=b&&b||(a=Base64._utf8_encode(a));m<a.length;)d=a.charCodeAt(m++),e=a.charCodeAt(m++),f=a.charCodeAt(m++),g=d>>2,d=(d&3)<<4|e>>4,k=(e&15)<<2|f>>6,l=f&63,isNaN(e)?k=l=64:isNaN(f)&&(l=64),c=c+this._keyStr.charAt(g)+this._keyStr.charAt(d)+this._keyStr.charAt(k)+this._keyStr.charAt(l);return c},decode:function(a,b){b=null!=b?b:!1;var c="",d,e,f,g,k,l=0;for(a=a.replace(/[^A-Za-z0-9\+\/\=]/g,
 "");l<a.length;)d=this._keyStr.indexOf(a.charAt(l++)),e=this._keyStr.indexOf(a.charAt(l++)),g=this._keyStr.indexOf(a.charAt(l++)),k=this._keyStr.indexOf(a.charAt(l++)),d=d<<2|e>>4,e=(e&15)<<4|g>>2,f=(g&3)<<6|k,c+=String.fromCharCode(d),64!=g&&(c+=String.fromCharCode(e)),64!=k&&(c+=String.fromCharCode(f));b||(c=Base64._utf8_decode(c));return c},_utf8_encode:function(a){a=a.replace(/\r\n/g,"\n");for(var b="",c=0;c<a.length;c++){var d=a.charCodeAt(c);128>d?b+=String.fromCharCode(d):(127<d&&2048>d?b+=
@@ -118,8 +118,8 @@ d?(c[g++]=192|d>>>6,c[g++]=128|63&d):65536>d?(c[g++]=224|d>>>12,c[g++]=128|d>>>6
 2===g?31:3===g?15:7;1<g&&d<m;)k=k<<6|63&b[d++],g--;1<g?n[f++]=65533:65536>k?n[f++]=k:(k-=65536,n[f++]=55296|k>>10&1023,n[f++]=56320|1023&k)}return e(n,f)};d.utf8border=function(b,c){var d;c=c||b.length;c>b.length&&(c=b.length);for(d=c-1;0<=d&&128===(192&b[d]);)d--;return 0>d?c:0===d?c:d+l[b[d]]>c?d:c}},{"./common":3}],5:[function(b,c,d){c.exports=function(b,c,d,k){var e=65535&b|0;b=b>>>16&65535|0;for(var f;0!==d;){f=2E3<d?2E3:d;d-=f;do e=e+c[k++]|0,b=b+e|0;while(--f);e%=65521;b%=65521}return e|b<<
 16|0}},{}],6:[function(b,c,d){c.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],7:[function(b,c,d){var e=function(){for(var b,c=[],d=0;256>d;d++){b=d;for(var e=
 0;8>e;e++)b=1&b?3988292384^b>>>1:b>>>1;c[d]=b}return c}();c.exports=function(b,c,d,l){d=l+d;for(b^=-1;l<d;l++)b=b>>>8^e[255&(b^c[l])];return b^-1}},{}],8:[function(b,c,d){function e(b,c){return b.msg=C[c],c}function f(b){for(var c=b.length;0<=--c;)b[c]=0}function g(b){var c=b.state,d=c.pending;d>b.avail_out&&(d=b.avail_out);0!==d&&(v.arraySet(b.output,c.pending_buf,c.pending_out,d,b.next_out),b.next_out+=d,c.pending_out+=d,b.total_out+=d,b.avail_out-=d,c.pending-=d,0===c.pending&&(c.pending_out=0))}
-function k(b,c){B._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function l(b,c){b.pending_buf[b.pending++]=c}function m(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function n(b,c){var d,e,f=b.max_chain_length,k=b.strstart,g=b.prev_length,l=b.nice_match,m=b.strstart>b.w_size-U?b.strstart-(b.w_size-U):0,n=b.window,p=b.w_mask,q=b.prev,t=b.strstart+M,r=n[k+g-1],E=n[k+g];b.prev_length>=b.good_match&&(f>>=
-2);l>b.lookahead&&(l=b.lookahead);do if(d=c,n[d+g]===E&&n[d+g-1]===r&&n[d]===n[k]&&n[++d]===n[k+1]){k+=2;for(d++;n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&k<t;);if(e=M-(t-k),k=t-M,e>g){if(b.match_start=c,g=e,e>=l)break;r=n[k+g-1];E=n[k+g]}}while((c=q[c&p])>m&&0!==--f);return g<=b.lookahead?g:b.lookahead}function p(b){var c,d,e,f,k=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=k+(k-U)){v.arraySet(b.window,
+function k(b,c){B._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function l(b,c){b.pending_buf[b.pending++]=c}function m(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function n(b,c){var d,e,f=b.max_chain_length,k=b.strstart,g=b.prev_length,l=b.nice_match,m=b.strstart>b.w_size-U?b.strstart-(b.w_size-U):0,n=b.window,p=b.w_mask,q=b.prev,r=b.strstart+N,t=n[k+g-1],E=n[k+g];b.prev_length>=b.good_match&&(f>>=
+2);l>b.lookahead&&(l=b.lookahead);do if(d=c,n[d+g]===E&&n[d+g-1]===t&&n[d]===n[k]&&n[++d]===n[k+1]){k+=2;for(d++;n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&n[++k]===n[++d]&&k<r;);if(e=N-(r-k),k=r-N,e>g){if(b.match_start=c,g=e,e>=l)break;t=n[k+g-1];E=n[k+g]}}while((c=q[c&p])>m&&0!==--f);return g<=b.lookahead?g:b.lookahead}function p(b){var c,d,e,f,k=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=k+(k-U)){v.arraySet(b.window,
 b.window,k,k,0);b.match_start-=k;b.strstart-=k;b.block_start-=k;c=d=b.hash_size;do e=b.head[--c],b.head[c]=e>=k?e-k:0;while(--d);c=d=k;do e=b.prev[--c],b.prev[c]=e>=k?e-k:0;while(--d);f+=k}if(0===b.strm.avail_in)break;c=b.strm;e=b.window;var g=b.strstart+b.lookahead,l=c.avail_in;if(d=(l>f&&(l=f),0===l?0:(c.avail_in-=l,v.arraySet(e,c.input,c.next_in,l,g),1===c.state.wrap?c.adler=G(c.adler,e,l,g):2===c.state.wrap&&(c.adler=F(c.adler,e,l,g)),c.next_in+=l,c.total_in+=l,l)),b.lookahead+=d,b.lookahead+
 b.insert>=K)for(f=b.strstart-b.insert,b.ins_h=b.window[f],b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+1])&b.hash_mask;b.insert&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+K-1])&b.hash_mask,b.prev[f&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=f,f++,b.insert--,!(b.lookahead+b.insert<K)););}while(b.lookahead<U&&0!==b.strm.avail_in)}function q(b,c){for(var d,e;;){if(b.lookahead<U){if(p(b),b.lookahead<U&&c===H)return R;if(0===b.lookahead)break}if(d=0,b.lookahead>=K&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+
 K-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),0!==d&&b.strstart-d<=b.w_size-U&&(b.match_length=n(b,d)),b.match_length>=K)if(e=B._tr_tally(b,b.strstart-b.match_start,b.match_length-K),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=K){b.match_length--;do b.strstart++,b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+K-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(0!==--b.match_length);
@@ -129,65 +129,65 @@ b.strstart+b.lookahead-K;e=B._tr_tally(b,b.strstart-1-b.prev_match,b.prev_length
 b.strstart++,b.lookahead--,0===b.strm.avail_out)return R}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(B._tr_tally(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<K-1?b.strstart:K-1,c===E?(k(b,!0),0===b.strm.avail_out?da:S):b.last_lit&&(k(b,!1),0===b.strm.avail_out)?R:aa}function r(b,c,d,e,f){this.good_length=b;this.max_lazy=c;this.nice_length=d;this.max_chain=e;this.func=f}function u(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=
 this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=T;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=
 this.ins_h=0;this.dyn_ltree=new v.Buf16(2*Y);this.dyn_dtree=new v.Buf16(2*(2*Q+1));this.bl_tree=new v.Buf16(2*(2*J+1));f(this.dyn_ltree);f(this.dyn_dtree);f(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new v.Buf16(O+1);this.heap=new v.Buf16(2*X+1);f(this.heap);this.heap_max=this.heap_len=0;this.depth=new v.Buf16(2*X+1);f(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function x(b){var c;
-return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ba,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ca:Z,b.adler=2===c.wrap?0:1,c.last_flush=H,B._tr_init(c),I):e(b,N)}function z(b){var c=x(b);c===I&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=A[b.level].max_lazy,b.good_match=A[b.level].good_length,b.nice_match=A[b.level].nice_length,b.max_chain_length=A[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
-b.prev_length=K-1,b.match_available=0,b.ins_h=0);return c}function y(b,c,d,f,k,g){if(!b)return N;var l=1;if(c===L&&(c=6),0>f?(l=0,f=-f):15<f&&(l=2,f-=16),1>k||k>D||d!==T||8>f||15<f||0>c||9<c||0>g||g>P)return e(b,N);8===f&&(f=9);var m=new u;return b.state=m,m.strm=b,m.wrap=l,m.gzhead=null,m.w_bits=f,m.w_size=1<<m.w_bits,m.w_mask=m.w_size-1,m.hash_bits=k+7,m.hash_size=1<<m.hash_bits,m.hash_mask=m.hash_size-1,m.hash_shift=~~((m.hash_bits+K-1)/K),m.window=new v.Buf8(2*m.w_size),m.head=new v.Buf16(m.hash_size),
-m.prev=new v.Buf16(m.w_size),m.lit_bufsize=1<<k+6,m.pending_buf_size=4*m.lit_bufsize,m.pending_buf=new v.Buf8(m.pending_buf_size),m.d_buf=1*m.lit_bufsize,m.l_buf=3*m.lit_bufsize,m.level=c,m.strategy=g,m.method=d,z(b)}var A,v=b("../utils/common"),B=b("./trees"),G=b("./adler32"),F=b("./crc32"),C=b("./messages"),H=0,E=4,I=0,N=-2,L=-1,V=1,P=4,ba=2,T=8,D=9,X=286,Q=30,J=19,Y=2*X+1,O=15,K=3,M=258,U=M+K+1,ca=42,Z=113,R=1,aa=2,da=3,S=4;A=[new r(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
+return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ba,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ca:Z,b.adler=2===c.wrap?0:1,c.last_flush=H,B._tr_init(c),I):e(b,M)}function z(b){var c=x(b);c===I&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=A[b.level].max_lazy,b.good_match=A[b.level].good_length,b.nice_match=A[b.level].nice_length,b.max_chain_length=A[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
+b.prev_length=K-1,b.match_available=0,b.ins_h=0);return c}function y(b,c,d,f,k,g){if(!b)return M;var l=1;if(c===L&&(c=6),0>f?(l=0,f=-f):15<f&&(l=2,f-=16),1>k||k>D||d!==T||8>f||15<f||0>c||9<c||0>g||g>P)return e(b,M);8===f&&(f=9);var m=new u;return b.state=m,m.strm=b,m.wrap=l,m.gzhead=null,m.w_bits=f,m.w_size=1<<m.w_bits,m.w_mask=m.w_size-1,m.hash_bits=k+7,m.hash_size=1<<m.hash_bits,m.hash_mask=m.hash_size-1,m.hash_shift=~~((m.hash_bits+K-1)/K),m.window=new v.Buf8(2*m.w_size),m.head=new v.Buf16(m.hash_size),
+m.prev=new v.Buf16(m.w_size),m.lit_bufsize=1<<k+6,m.pending_buf_size=4*m.lit_bufsize,m.pending_buf=new v.Buf8(m.pending_buf_size),m.d_buf=1*m.lit_bufsize,m.l_buf=3*m.lit_bufsize,m.level=c,m.strategy=g,m.method=d,z(b)}var A,v=b("../utils/common"),B=b("./trees"),G=b("./adler32"),F=b("./crc32"),C=b("./messages"),H=0,E=4,I=0,M=-2,L=-1,V=1,P=4,ba=2,T=8,D=9,X=286,Q=30,J=19,Y=2*X+1,O=15,K=3,N=258,U=N+K+1,ca=42,Z=113,R=1,aa=2,da=3,S=4;A=[new r(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
 (d=b.pending_buf_size-5);;){if(1>=b.lookahead){if(p(b),0===b.lookahead&&c===H)return R;if(0===b.lookahead)break}b.strstart+=b.lookahead;b.lookahead=0;var e=b.block_start+d;if((0===b.strstart||b.strstart>=e)&&(b.lookahead=b.strstart-e,b.strstart=e,k(b,!1),0===b.strm.avail_out)||b.strstart-b.block_start>=b.w_size-U&&(k(b,!1),0===b.strm.avail_out))return R}return b.insert=0,c===E?(k(b,!0),0===b.strm.avail_out?da:S):(b.strstart>b.block_start&&k(b,!1),R)}),new r(4,4,8,4,q),new r(4,5,16,8,q),new r(4,6,
-32,32,q),new r(4,4,16,16,t),new r(8,16,32,32,t),new r(8,16,128,128,t),new r(8,32,128,256,t),new r(32,128,258,1024,t),new r(32,258,258,4096,t)];d.deflateInit=function(b,c){return y(b,c,T,15,8,0)};d.deflateInit2=y;d.deflateReset=z;d.deflateResetKeep=x;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?N:(b.state.gzhead=c,I):N};d.deflate=function(b,c){var d,n,q,t;if(!b||!b.state||5<c||0>c)return b?e(b,N):N;if(n=b.state,!b.output||!b.input&&0!==b.avail_in||666===n.status&&c!==E)return e(b,
-0===b.avail_out?-5:N);if(n.strm=b,d=n.last_flush,n.last_flush=c,n.status===ca)2===n.wrap?(b.adler=0,l(n,31),l(n,139),l(n,8),n.gzhead?(l(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),l(n,255&n.gzhead.time),l(n,n.gzhead.time>>8&255),l(n,n.gzhead.time>>16&255),l(n,n.gzhead.time>>24&255),l(n,9===n.level?2:2<=n.strategy||2>n.level?4:0),l(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(l(n,255&n.gzhead.extra.length),l(n,n.gzhead.extra.length>>
+32,32,q),new r(4,4,16,16,t),new r(8,16,32,32,t),new r(8,16,128,128,t),new r(8,32,128,256,t),new r(32,128,258,1024,t),new r(32,258,258,4096,t)];d.deflateInit=function(b,c){return y(b,c,T,15,8,0)};d.deflateInit2=y;d.deflateReset=z;d.deflateResetKeep=x;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?M:(b.state.gzhead=c,I):M};d.deflate=function(b,c){var d,n,q,r;if(!b||!b.state||5<c||0>c)return b?e(b,M):M;if(n=b.state,!b.output||!b.input&&0!==b.avail_in||666===n.status&&c!==E)return e(b,
+0===b.avail_out?-5:M);if(n.strm=b,d=n.last_flush,n.last_flush=c,n.status===ca)2===n.wrap?(b.adler=0,l(n,31),l(n,139),l(n,8),n.gzhead?(l(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),l(n,255&n.gzhead.time),l(n,n.gzhead.time>>8&255),l(n,n.gzhead.time>>16&255),l(n,n.gzhead.time>>24&255),l(n,9===n.level?2:2<=n.strategy||2>n.level?4:0),l(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(l(n,255&n.gzhead.extra.length),l(n,n.gzhead.extra.length>>
 8&255)),n.gzhead.hcrc&&(b.adler=F(b.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=69):(l(n,0),l(n,0),l(n,0),l(n,0),l(n,0),l(n,9===n.level?2:2<=n.strategy||2>n.level?4:0),l(n,3),n.status=Z)):(q=T+(n.w_bits-8<<4)<<8,q|=(2<=n.strategy||2>n.level?0:6>n.level?1:6===n.level?2:3)<<6,0!==n.strstart&&(q|=32),n.status=Z,m(n,q+(31-q%31)),0!==n.strstart&&(m(n,b.adler>>>16),m(n,65535&b.adler)),b.adler=1);if(69===n.status)if(n.gzhead.extra){for(q=n.pending;n.gzindex<(65535&n.gzhead.extra.length)&&(n.pending!==
 n.pending_buf_size||(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q)),g(b),q=n.pending,n.pending!==n.pending_buf_size));)l(n,255&n.gzhead.extra[n.gzindex]),n.gzindex++;n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=73)}else n.status=73;if(73===n.status)if(n.gzhead.name){q=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-
-q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){t=1;break}t=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0;l(n,t)}while(0!==t);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===t&&(n.gzindex=0,n.status=91)}else n.status=91;if(91===n.status)if(n.gzhead.comment){q=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){t=
-1;break}t=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0;l(n,t)}while(0!==t);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===t&&(n.status=103)}else n.status=103;if(103===n.status&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&g(b),n.pending+2<=n.pending_buf_size&&(l(n,255&b.adler),l(n,b.adler>>8&255),b.adler=0,n.status=Z)):n.status=Z),0!==n.pending){if(g(b),0===b.avail_out)return n.last_flush=-1,I}else if(0===b.avail_in&&(c<<1)-
-(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==E)return e(b,-5);if(666===n.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==n.lookahead||c!==H&&666!==n.status){var r;if(2===n.strategy)a:{for(var u;;){if(0===n.lookahead&&(p(n),0===n.lookahead)){if(c===H){r=R;break a}break}if(n.match_length=0,u=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++,u&&(k(n,!1),0===n.strm.avail_out)){r=R;break a}}r=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?
-R:aa)}else if(3===n.strategy)a:{var x,D;for(u=n.window;;){if(n.lookahead<=M){if(p(n),n.lookahead<=M&&c===H){r=R;break a}if(0===n.lookahead)break}if(n.match_length=0,n.lookahead>=K&&0<n.strstart&&(D=n.strstart-1,x=u[D],x===u[++D]&&x===u[++D]&&x===u[++D])){for(d=n.strstart+M;x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&D<d;);n.match_length=M-(d-D);n.match_length>n.lookahead&&(n.match_length=n.lookahead)}if(n.match_length>=K?(r=B._tr_tally(n,1,n.match_length-
-K),n.lookahead-=n.match_length,n.strstart+=n.match_length,n.match_length=0):(r=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++),r&&(k(n,!1),0===n.strm.avail_out)){r=R;break a}}r=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?R:aa)}else r=A[n.level].func(n,c);if(r!==da&&r!==S||(n.status=666),r===R||r===da)return 0===b.avail_out&&(n.last_flush=-1),I;if(r===aa&&(1===c?B._tr_align(n):5!==c&&(B._tr_stored_block(n,0,0,!1),3===c&&(f(n.head),
+q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){r=1;break}r=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0;l(n,r)}while(0!==r);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===r&&(n.gzindex=0,n.status=91)}else n.status=91;if(91===n.status)if(n.gzhead.comment){q=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q)),g(b),q=n.pending,n.pending===n.pending_buf_size)){r=
+1;break}r=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0;l(n,r)}while(0!==r);n.gzhead.hcrc&&n.pending>q&&(b.adler=F(b.adler,n.pending_buf,n.pending-q,q));0===r&&(n.status=103)}else n.status=103;if(103===n.status&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&g(b),n.pending+2<=n.pending_buf_size&&(l(n,255&b.adler),l(n,b.adler>>8&255),b.adler=0,n.status=Z)):n.status=Z),0!==n.pending){if(g(b),0===b.avail_out)return n.last_flush=-1,I}else if(0===b.avail_in&&(c<<1)-
+(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==E)return e(b,-5);if(666===n.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==n.lookahead||c!==H&&666!==n.status){var t;if(2===n.strategy)a:{for(var u;;){if(0===n.lookahead&&(p(n),0===n.lookahead)){if(c===H){t=R;break a}break}if(n.match_length=0,u=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++,u&&(k(n,!1),0===n.strm.avail_out)){t=R;break a}}t=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?
+R:aa)}else if(3===n.strategy)a:{var x,D;for(u=n.window;;){if(n.lookahead<=N){if(p(n),n.lookahead<=N&&c===H){t=R;break a}if(0===n.lookahead)break}if(n.match_length=0,n.lookahead>=K&&0<n.strstart&&(D=n.strstart-1,x=u[D],x===u[++D]&&x===u[++D]&&x===u[++D])){for(d=n.strstart+N;x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&x===u[++D]&&D<d;);n.match_length=N-(d-D);n.match_length>n.lookahead&&(n.match_length=n.lookahead)}if(n.match_length>=K?(t=B._tr_tally(n,1,n.match_length-
+K),n.lookahead-=n.match_length,n.strstart+=n.match_length,n.match_length=0):(t=B._tr_tally(n,0,n.window[n.strstart]),n.lookahead--,n.strstart++),t&&(k(n,!1),0===n.strm.avail_out)){t=R;break a}}t=(n.insert=0,c===E?(k(n,!0),0===n.strm.avail_out?da:S):n.last_lit&&(k(n,!1),0===n.strm.avail_out)?R:aa)}else t=A[n.level].func(n,c);if(t!==da&&t!==S||(n.status=666),t===R||t===da)return 0===b.avail_out&&(n.last_flush=-1),I;if(t===aa&&(1===c?B._tr_align(n):5!==c&&(B._tr_stored_block(n,0,0,!1),3===c&&(f(n.head),
 0===n.lookahead&&(n.strstart=0,n.block_start=0,n.insert=0))),g(b),0===b.avail_out))return n.last_flush=-1,I}return c!==E?I:0>=n.wrap?1:(2===n.wrap?(l(n,255&b.adler),l(n,b.adler>>8&255),l(n,b.adler>>16&255),l(n,b.adler>>24&255),l(n,255&b.total_in),l(n,b.total_in>>8&255),l(n,b.total_in>>16&255),l(n,b.total_in>>24&255)):(m(n,b.adler>>>16),m(n,65535&b.adler)),g(b),0<n.wrap&&(n.wrap=-n.wrap),0!==n.pending?I:1)};d.deflateEnd=function(b){var c;return b&&b.state?(c=b.state.status,c!==ca&&69!==c&&73!==c&&
-91!==c&&103!==c&&c!==Z&&666!==c?e(b,N):(b.state=null,c===Z?e(b,-3):I)):N};d.deflateSetDictionary=function(b,c){var d,e,k,g,l,m,n;e=c.length;if(!b||!b.state||(d=b.state,g=d.wrap,2===g||1===g&&d.status!==ca||d.lookahead))return N;1===g&&(b.adler=G(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===g&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),l=new v.Buf8(d.w_size),v.arraySet(l,c,e-d.w_size,d.w_size,0),c=l,e=d.w_size);l=b.avail_in;m=b.next_in;n=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(p(d);d.lookahead>=
+91!==c&&103!==c&&c!==Z&&666!==c?e(b,M):(b.state=null,c===Z?e(b,-3):I)):M};d.deflateSetDictionary=function(b,c){var d,e,k,g,l,m,n;e=c.length;if(!b||!b.state||(d=b.state,g=d.wrap,2===g||1===g&&d.status!==ca||d.lookahead))return M;1===g&&(b.adler=G(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===g&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),l=new v.Buf8(d.w_size),v.arraySet(l,c,e-d.w_size,d.w_size,0),c=l,e=d.w_size);l=b.avail_in;m=b.next_in;n=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(p(d);d.lookahead>=
 K;){e=d.strstart;k=d.lookahead-(K-1);do d.ins_h=(d.ins_h<<d.hash_shift^d.window[e+K-1])&d.hash_mask,d.prev[e&d.w_mask]=d.head[d.ins_h],d.head[d.ins_h]=e,e++;while(--k);d.strstart=e;d.lookahead=K-1;p(d)}return d.strstart+=d.lookahead,d.block_start=d.strstart,d.insert=d.lookahead,d.lookahead=0,d.match_length=d.prev_length=K-1,d.match_available=0,b.next_in=m,b.input=n,b.avail_in=l,d.wrap=g,I};d.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":3,"./adler32":5,"./crc32":7,"./messages":13,
-"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,m,n,p,q,t,r,u,x,z,y,A,v,B,G,F,C,H,E,I,N,L;d=b.state;e=b.next_in;N=b.input;f=e+(b.avail_in-5);m=b.next_out;L=b.output;n=m-(c-b.avail_out);p=m+(b.avail_out-257);q=d.dmax;t=d.wsize;r=d.whave;u=d.wnext;x=d.window;z=d.hold;y=d.bits;A=d.lencode;v=d.distcode;B=(1<<d.lenbits)-
-1;G=(1<<d.distbits)-1;a:do b:for(15>y&&(z+=N[e++]<<y,y+=8,z+=N[e++]<<y,y+=8),F=A[z&B];;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,0===C)L[m++]=65535&F;else{if(!(16&C)){if(0===(64&C)){F=A[(65535&F)+(z&(1<<C)-1)];continue b}if(32&C){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}H=65535&F;(C&=15)&&(y<C&&(z+=N[e++]<<y,y+=8),H+=z&(1<<C)-1,z>>>=C,y-=C);15>y&&(z+=N[e++]<<y,y+=8,z+=N[e++]<<y,y+=8);F=v[z&G];c:for(;;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,!(16&C)){if(0===(64&C)){F=v[(65535&
-F)+(z&(1<<C)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(E=65535&F,C&=15,y<C&&(z+=N[e++]<<y,y+=8,y<C&&(z+=N[e++]<<y,y+=8)),E+=z&(1<<C)-1,E>q){b.msg="invalid distance too far back";d.mode=30;break a}if(z>>>=C,y-=C,C=m-n,E>C){if(C=E-C,C>r&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(F=0,I=x,0===u){if(F+=t-C,C<H){H-=C;do L[m++]=x[F++];while(--C);F=m-E;I=L}}else if(u<C){if(F+=t+u-C,C-=u,C<H){H-=C;do L[m++]=x[F++];while(--C);if(F=0,u<H){C=u;H-=C;do L[m++]=x[F++];
+"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,m,n,p,q,t,r,u,x,z,y,A,v,B,G,F,C,H,E,I,M,L;d=b.state;e=b.next_in;M=b.input;f=e+(b.avail_in-5);m=b.next_out;L=b.output;n=m-(c-b.avail_out);p=m+(b.avail_out-257);q=d.dmax;t=d.wsize;r=d.whave;u=d.wnext;x=d.window;z=d.hold;y=d.bits;A=d.lencode;v=d.distcode;B=(1<<d.lenbits)-
+1;G=(1<<d.distbits)-1;a:do b:for(15>y&&(z+=M[e++]<<y,y+=8,z+=M[e++]<<y,y+=8),F=A[z&B];;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,0===C)L[m++]=65535&F;else{if(!(16&C)){if(0===(64&C)){F=A[(65535&F)+(z&(1<<C)-1)];continue b}if(32&C){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}H=65535&F;(C&=15)&&(y<C&&(z+=M[e++]<<y,y+=8),H+=z&(1<<C)-1,z>>>=C,y-=C);15>y&&(z+=M[e++]<<y,y+=8,z+=M[e++]<<y,y+=8);F=v[z&G];c:for(;;){if(C=F>>>24,z>>>=C,y-=C,C=F>>>16&255,!(16&C)){if(0===(64&C)){F=v[(65535&
+F)+(z&(1<<C)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(E=65535&F,C&=15,y<C&&(z+=M[e++]<<y,y+=8,y<C&&(z+=M[e++]<<y,y+=8)),E+=z&(1<<C)-1,E>q){b.msg="invalid distance too far back";d.mode=30;break a}if(z>>>=C,y-=C,C=m-n,E>C){if(C=E-C,C>r&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(F=0,I=x,0===u){if(F+=t-C,C<H){H-=C;do L[m++]=x[F++];while(--C);F=m-E;I=L}}else if(u<C){if(F+=t+u-C,C-=u,C<H){H-=C;do L[m++]=x[F++];while(--C);if(F=0,u<H){C=u;H-=C;do L[m++]=x[F++];
 while(--C);F=m-E;I=L}}}else if(F+=u-C,C<H){H-=C;do L[m++]=x[F++];while(--C);F=m-E;I=L}for(;2<H;)L[m++]=I[F++],L[m++]=I[F++],L[m++]=I[F++],H-=3;H&&(L[m++]=I[F++],1<H&&(L[m++]=I[F++]))}else{F=m-E;do L[m++]=L[F++],L[m++]=L[F++],L[m++]=L[F++],H-=3;while(2<H);H&&(L[m++]=L[F++],1<H&&(L[m++]=L[F++]))}break}}break}while(e<f&&m<p);H=y>>3;e-=H;y-=H<<3;b.next_in=e;b.next_out=m;b.avail_in=e<f?5+(f-e):5-(e-f);b.avail_out=m<p?257+(p-m):257-(m-p);d.hold=z&(1<<y)-1;d.bits=y}},{}],11:[function(b,c,d){function e(b){return(b>>>
 24&255)+(b>>>8&65280)+((65280&b)<<8)+((255&b)<<24)}function f(){this.mode=0;this.last=!1;this.wrap=0;this.havedict=!1;this.total=this.check=this.dmax=this.flags=0;this.head=null;this.wnext=this.whave=this.wsize=this.wbits=0;this.window=null;this.extra=this.offset=this.length=this.bits=this.hold=0;this.distcode=this.lencode=null;this.have=this.ndist=this.nlen=this.ncode=this.distbits=this.lenbits=0;this.next=null;this.lens=new t.Buf16(320);this.work=new t.Buf16(288);this.distdyn=this.lendyn=null;this.was=
 this.back=this.sane=0}function g(b){var c;return b&&b.state?(c=b.state,b.total_in=b.total_out=c.total=0,b.msg="",c.wrap&&(b.adler=1&c.wrap),c.mode=v,c.last=0,c.havedict=0,c.dmax=32768,c.head=null,c.hold=0,c.bits=0,c.lencode=c.lendyn=new t.Buf32(B),c.distcode=c.distdyn=new t.Buf32(G),c.sane=1,c.back=-1,y):A}function k(b){var c;return b&&b.state?(c=b.state,c.wsize=0,c.whave=0,c.wnext=0,g(b)):A}function l(b,c){var d,e;return b&&b.state?(e=b.state,0>c?(d=0,c=-c):(d=(c>>4)+1,48>c&&(c&=15)),c&&(8>c||15<
 c)?A:(null!==e.window&&e.wbits!==c&&(e.window=null),e.wrap=d,e.wbits=c,k(b))):A}function m(b,c){var d,e;return b?(e=new f,b.state=e,e.window=null,d=l(b,c),d!==y&&(b.state=null),d):A}function n(b,c,d,e){var f;b=b.state;return null===b.window&&(b.wsize=1<<b.wbits,b.wnext=0,b.whave=0,b.window=new t.Buf8(b.wsize)),e>=b.wsize?(t.arraySet(b.window,c,d-b.wsize,b.wsize,0),b.wnext=0,b.whave=b.wsize):(f=b.wsize-b.wnext,f>e&&(f=e),t.arraySet(b.window,c,d-e,f,b.wnext),e-=f,e?(t.arraySet(b.window,c,d-e,e,0),b.wnext=
-e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var p,q,t=b("../utils/common"),r=b("./adler32"),u=b("./crc32"),x=b("./inffast"),z=b("./inftrees"),y=0,A=-2,v=1,B=852,G=592,F=!0;d.inflateReset=k;d.inflateReset2=l;d.inflateResetKeep=g;d.inflateInit=function(b){return m(b,15)};d.inflateInit2=m;d.inflate=function(b,c){var d,f,k,g,l,m,C,B,D,X,H,J,G,O,K,M,U,ca,Z,R,aa,da,S=0,W=new t.Buf8(4),ga=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
+e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var p,q,t=b("../utils/common"),r=b("./adler32"),u=b("./crc32"),x=b("./inffast"),z=b("./inftrees"),y=0,A=-2,v=1,B=852,G=592,F=!0;d.inflateReset=k;d.inflateReset2=l;d.inflateResetKeep=g;d.inflateInit=function(b){return m(b,15)};d.inflateInit2=m;d.inflate=function(b,c){var d,f,k,g,l,m,C,B,D,X,H,J,G,O,K,N,U,ca,Z,R,aa,da,S=0,W=new t.Buf8(4),ga=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
 !b.output||!b.input&&0!==b.avail_in)return A;d=b.state;12===d.mode&&(d.mode=13);l=b.next_out;k=b.output;C=b.avail_out;g=b.next_in;f=b.input;m=b.avail_in;B=d.hold;D=d.bits;X=m;H=C;aa=y;a:for(;;)switch(d.mode){case v:if(0===d.wrap){d.mode=13;break}for(;16>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(2&d.wrap&&35615===B){d.check=0;W[0]=255&B;W[1]=B>>>8&255;d.check=u(d.check,W,2,0);D=B=0;d.mode=2;break}if(d.flags=0,d.head&&(d.head.done=!1),!(1&d.wrap)||(((255&B)<<8)+(B>>8))%31){b.msg="incorrect header check";
 d.mode=30;break}if(8!==(15&B)){b.msg="unknown compression method";d.mode=30;break}if(B>>>=4,D-=4,R=(15&B)+8,0===d.wbits)d.wbits=R;else if(R>d.wbits){b.msg="invalid window size";d.mode=30;break}d.dmax=1<<R;b.adler=d.check=1;d.mode=512&B?10:12;D=B=0;break;case 2:for(;16>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(d.flags=B,8!==(255&d.flags)){b.msg="unknown compression method";d.mode=30;break}if(57344&d.flags){b.msg="unknown header flags set";d.mode=30;break}d.head&&(d.head.text=B>>8&1);512&d.flags&&
 (W[0]=255&B,W[1]=B>>>8&255,d.check=u(d.check,W,2,0));D=B=0;d.mode=3;case 3:for(;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.head&&(d.head.time=B);512&d.flags&&(W[0]=255&B,W[1]=B>>>8&255,W[2]=B>>>16&255,W[3]=B>>>24&255,d.check=u(d.check,W,4,0));D=B=0;d.mode=4;case 4:for(;16>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.head&&(d.head.xflags=255&B,d.head.os=B>>8);512&d.flags&&(W[0]=255&B,W[1]=B>>>8&255,d.check=u(d.check,W,2,0));D=B=0;d.mode=5;case 5:if(1024&d.flags){for(;16>D;){if(0===m)break a;m--;
 B+=f[g++]<<D;D+=8}d.length=B;d.head&&(d.head.extra_len=B);512&d.flags&&(W[0]=255&B,W[1]=B>>>8&255,d.check=u(d.check,W,2,0));D=B=0}else d.head&&(d.head.extra=null);d.mode=6;case 6:if(1024&d.flags&&(J=d.length,J>m&&(J=m),J&&(d.head&&(R=d.head.extra_len-d.length,d.head.extra||(d.head.extra=Array(d.head.extra_len)),t.arraySet(d.head.extra,f,g,J,R)),512&d.flags&&(d.check=u(d.check,f,J,g)),m-=J,g+=J,d.length-=J),d.length))break a;d.length=0;d.mode=7;case 7:if(2048&d.flags){if(0===m)break a;J=0;do R=f[g+
 J++],d.head&&R&&65536>d.length&&(d.head.name+=String.fromCharCode(R));while(R&&J<m);if(512&d.flags&&(d.check=u(d.check,f,J,g)),m-=J,g+=J,R)break a}else d.head&&(d.head.name=null);d.length=0;d.mode=8;case 8:if(4096&d.flags){if(0===m)break a;J=0;do R=f[g+J++],d.head&&R&&65536>d.length&&(d.head.comment+=String.fromCharCode(R));while(R&&J<m);if(512&d.flags&&(d.check=u(d.check,f,J,g)),m-=J,g+=J,R)break a}else d.head&&(d.head.comment=null);d.mode=9;case 9:if(512&d.flags){for(;16>D;){if(0===m)break a;m--;
 B+=f[g++]<<D;D+=8}if(B!==(65535&d.check)){b.msg="header crc mismatch";d.mode=30;break}D=B=0}d.head&&(d.head.hcrc=d.flags>>9&1,d.head.done=!0);b.adler=d.check=0;d.mode=12;break;case 10:for(;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}b.adler=d.check=e(B);D=B=0;d.mode=11;case 11:if(0===d.havedict)return b.next_out=l,b.avail_out=C,b.next_in=g,b.avail_in=m,d.hold=B,d.bits=D,2;b.adler=d.check=1;d.mode=12;case 12:if(5===c||6===c)break a;case 13:if(d.last){B>>>=7&D;D-=7&D;d.mode=27;break}for(;3>D;){if(0===
-m)break a;m--;B+=f[g++]<<D;D+=8}switch(d.last=1&B,B>>>=1,--D,3&B){case 0:d.mode=14;break;case 1:M=d;if(F){p=new t.Buf32(512);q=new t.Buf32(32);for(O=0;144>O;)M.lens[O++]=8;for(;256>O;)M.lens[O++]=9;for(;280>O;)M.lens[O++]=7;for(;288>O;)M.lens[O++]=8;z(1,M.lens,0,288,p,0,M.work,{bits:9});for(O=0;32>O;)M.lens[O++]=5;z(2,M.lens,0,32,q,0,M.work,{bits:5});F=!1}M.lencode=p;M.lenbits=9;M.distcode=q;M.distbits=5;if(d.mode=20,6===c){B>>>=2;D-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
+m)break a;m--;B+=f[g++]<<D;D+=8}switch(d.last=1&B,B>>>=1,--D,3&B){case 0:d.mode=14;break;case 1:N=d;if(F){p=new t.Buf32(512);q=new t.Buf32(32);for(O=0;144>O;)N.lens[O++]=8;for(;256>O;)N.lens[O++]=9;for(;280>O;)N.lens[O++]=7;for(;288>O;)N.lens[O++]=8;z(1,N.lens,0,288,p,0,N.work,{bits:9});for(O=0;32>O;)N.lens[O++]=5;z(2,N.lens,0,32,q,0,N.work,{bits:5});F=!1}N.lencode=p;N.lenbits=9;N.distcode=q;N.distbits=5;if(d.mode=20,6===c){B>>>=2;D-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
 d.mode=30}B>>>=2;D-=2;break;case 14:B>>>=7&D;for(D-=7&D;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if((65535&B)!==(B>>>16^65535)){b.msg="invalid stored block lengths";d.mode=30;break}if(d.length=65535&B,B=0,D=0,d.mode=15,6===c)break a;case 15:d.mode=16;case 16:if(J=d.length){if(J>m&&(J=m),J>C&&(J=C),0===J)break a;t.arraySet(k,f,g,J,l);m-=J;g+=J;C-=J;l+=J;d.length-=J;break}d.mode=12;break;case 17:for(;14>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(d.nlen=(31&B)+257,B>>>=5,D-=5,d.ndist=(31&B)+
 1,B>>>=5,D-=5,d.ncode=(15&B)+4,B>>>=4,D-=4,286<d.nlen||30<d.ndist){b.msg="too many length or distance symbols";d.mode=30;break}d.have=0;d.mode=18;case 18:for(;d.have<d.ncode;){for(;3>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.lens[ga[d.have++]]=7&B;B>>>=3;D-=3}for(;19>d.have;)d.lens[ga[d.have++]]=0;if(d.lencode=d.lendyn,d.lenbits=7,da={bits:d.lenbits},aa=z(0,d.lens,0,19,d.lencode,0,d.work,da),d.lenbits=da.bits,aa){b.msg="invalid code lengths set";d.mode=30;break}d.have=0;d.mode=19;case 19:for(;d.have<
-d.nlen+d.ndist;){for(;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,M=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(16>M)B>>>=K,D-=K,d.lens[d.have++]=M;else{if(16===M){for(O=K+2;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(B>>>=K,D-=K,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}R=d.lens[d.have-1];J=3+(3&B);B>>>=2;D-=2}else if(17===M){for(O=K+3;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=K;D-=K;R=0;J=3+(7&B);B>>>=3;D-=3}else{for(O=K+7;D<O;){if(0===m)break a;m--;
+d.nlen+d.ndist;){for(;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,N=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(16>N)B>>>=K,D-=K,d.lens[d.have++]=N;else{if(16===N){for(O=K+2;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(B>>>=K,D-=K,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}R=d.lens[d.have-1];J=3+(3&B);B>>>=2;D-=2}else if(17===N){for(O=K+3;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=K;D-=K;R=0;J=3+(7&B);B>>>=3;D-=3}else{for(O=K+7;D<O;){if(0===m)break a;m--;
 B+=f[g++]<<D;D+=8}B>>>=K;D-=K;R=0;J=11+(127&B);B>>>=7;D-=7}if(d.have+J>d.nlen+d.ndist){b.msg="invalid bit length repeat";d.mode=30;break}for(;J--;)d.lens[d.have++]=R}}if(30===d.mode)break;if(0===d.lens[256]){b.msg="invalid code -- missing end-of-block";d.mode=30;break}if(d.lenbits=9,da={bits:d.lenbits},aa=z(1,d.lens,0,d.nlen,d.lencode,0,d.work,da),d.lenbits=da.bits,aa){b.msg="invalid literal/lengths set";d.mode=30;break}if(d.distbits=6,d.distcode=d.distdyn,da={bits:d.distbits},aa=z(2,d.lens,d.nlen,
-d.ndist,d.distcode,0,d.work,da),d.distbits=da.bits,aa){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=m&&258<=C){b.next_out=l;b.avail_out=C;b.next_in=g;b.avail_in=m;d.hold=B;d.bits=D;x(b,H);l=b.next_out;k=b.output;C=b.avail_out;g=b.next_in;f=b.input;m=b.avail_in;B=d.hold;D=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,O=S>>>16&255,M=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(O&&
-0===(240&O)){U=K;ca=O;for(Z=M;S=d.lencode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,M=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,d.length=M,0===O){d.mode=26;break}if(32&O){d.back=-1;d.mode=12;break}if(64&O){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&O;d.mode=22;case 22:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.length+=B&(1<<d.extra)-1;B>>>=d.extra;D-=d.extra;d.back+=d.extra}d.was=
-d.length;d.mode=23;case 23:for(;S=d.distcode[B&(1<<d.distbits)-1],K=S>>>24,O=S>>>16&255,M=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(0===(240&O)){U=K;ca=O;for(Z=M;S=d.distcode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,M=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,64&O){b.msg="invalid distance code";d.mode=30;break}d.offset=M;d.extra=15&O;d.mode=24;case 24:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<
+d.ndist,d.distcode,0,d.work,da),d.distbits=da.bits,aa){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=m&&258<=C){b.next_out=l;b.avail_out=C;b.next_in=g;b.avail_in=m;d.hold=B;d.bits=D;x(b,H);l=b.next_out;k=b.output;C=b.avail_out;g=b.next_in;f=b.input;m=b.avail_in;B=d.hold;D=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;S=d.lencode[B&(1<<d.lenbits)-1],K=S>>>24,O=S>>>16&255,N=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(O&&
+0===(240&O)){U=K;ca=O;for(Z=N;S=d.lencode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,N=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,d.length=N,0===O){d.mode=26;break}if(32&O){d.back=-1;d.mode=12;break}if(64&O){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&O;d.mode=22;case 22:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}d.length+=B&(1<<d.extra)-1;B>>>=d.extra;D-=d.extra;d.back+=d.extra}d.was=
+d.length;d.mode=23;case 23:for(;S=d.distcode[B&(1<<d.distbits)-1],K=S>>>24,O=S>>>16&255,N=65535&S,!(K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(0===(240&O)){U=K;ca=O;for(Z=N;S=d.distcode[Z+((B&(1<<U+ca)-1)>>U)],K=S>>>24,O=S>>>16&255,N=65535&S,!(U+K<=D);){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}B>>>=U;D-=U;d.back+=U}if(B>>>=K,D-=K,d.back+=K,64&O){b.msg="invalid distance code";d.mode=30;break}d.offset=N;d.extra=15&O;d.mode=24;case 24:if(d.extra){for(O=d.extra;D<O;){if(0===m)break a;m--;B+=f[g++]<<
 D;D+=8}d.offset+=B&(1<<d.extra)-1;B>>>=d.extra;D-=d.extra;d.back+=d.extra}if(d.offset>d.dmax){b.msg="invalid distance too far back";d.mode=30;break}d.mode=25;case 25:if(0===C)break a;if(J=H-C,d.offset>J){if(J=d.offset-J,J>d.whave&&d.sane){b.msg="invalid distance too far back";d.mode=30;break}J>d.wnext?(J-=d.wnext,G=d.wsize-J):G=d.wnext-J;J>d.length&&(J=d.length);O=d.window}else O=k,G=l-d.offset,J=d.length;J>C&&(J=C);C-=J;d.length-=J;do k[l++]=O[G++];while(--J);0===d.length&&(d.mode=21);break;case 26:if(0===
 C)break a;k[l++]=d.length;C--;d.mode=21;break;case 27:if(d.wrap){for(;32>D;){if(0===m)break a;m--;B|=f[g++]<<D;D+=8}if(H-=C,b.total_out+=H,d.total+=H,H&&(b.adler=d.check=d.flags?u(d.check,k,H,l-H):r(d.check,k,H,l-H)),H=C,(d.flags?B:e(B))!==d.check){b.msg="incorrect data check";d.mode=30;break}D=B=0}d.mode=28;case 28:if(d.wrap&&d.flags){for(;32>D;){if(0===m)break a;m--;B+=f[g++]<<D;D+=8}if(B!==(4294967295&d.total)){b.msg="incorrect length check";d.mode=30;break}D=B=0}d.mode=29;case 29:aa=1;break a;
 case 30:aa=-3;break a;case 31:return-4;default:return A}return b.next_out=l,b.avail_out=C,b.next_in=g,b.avail_in=m,d.hold=B,d.bits=D,(d.wsize||H!==b.avail_out&&30>d.mode&&(27>d.mode||4!==c))&&n(b,b.output,b.next_out,H-b.avail_out)?(d.mode=31,-4):(X-=b.avail_in,H-=b.avail_out,b.total_in+=X,b.total_out+=H,d.total+=H,d.wrap&&H&&(b.adler=d.check=d.flags?u(d.check,k,H,b.next_out-H):r(d.check,k,H,b.next_out-H)),b.data_type=d.bits+(d.last?64:0)+(12===d.mode?128:0)+(20===d.mode||15===d.mode?256:0),(0===X&&
 0===H||4===c)&&aa===y&&(aa=-5),aa)};d.inflateEnd=function(b){if(!b||!b.state)return A;var c=b.state;return c.window&&(c.window=null),b.state=null,y};d.inflateGetHeader=function(b,c){var d;return b&&b.state?(d=b.state,0===(2&d.wrap)?A:(d.head=c,c.done=!1,y)):A};d.inflateSetDictionary=function(b,c){var d,e,f=c.length;return b&&b.state?(d=b.state,0!==d.wrap&&11!==d.mode?A:11===d.mode&&(e=1,e=r(e,c,f,0),e!==d.check)?-3:n(b,c,f,f)?(d.mode=31,-4):(d.havedict=1,y)):A};d.inflateInfo="pako inflate (from Nodeca project)"},
 {"../utils/common":3,"./adler32":5,"./crc32":7,"./inffast":10,"./inftrees":12}],12:[function(b,c,d){var e=b("../utils/common"),f=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],k=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],l=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,
-25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,q,t,r,u,x){var m,n,p,v,B,G,F,C,H=x.bits,E,I,N,L,V,P,ba=0,T,D=null,X=0,Q=new e.Buf16(16);v=new e.Buf16(16);var J=null,Y=0;for(E=0;15>=E;E++)Q[E]=0;for(I=0;I<q;I++)Q[c[d+I]]++;L=H;for(N=15;1<=N&&0===Q[N];N--);if(L>N&&(L=N),0===N)return t[r++]=20971520,t[r++]=20971520,x.bits=1,0;for(H=1;H<N&&0===Q[H];H++);L<H&&(L=H);for(E=m=1;15>=E;E++)if(m<<=1,m-=Q[E],0>m)return-1;if(0<m&&(0===b||1!==N))return-1;v[1]=0;for(E=1;15>E;E++)v[E+1]=v[E]+Q[E];for(I=
-0;I<q;I++)0!==c[d+I]&&(u[v[c[d+I]]++]=I);if(0===b?(D=J=u,B=19):1===b?(D=f,X-=257,J=g,Y-=257,B=256):(D=k,J=l,B=-1),T=0,I=0,E=H,v=r,V=L,P=0,p=-1,ba=1<<L,q=ba-1,1===b&&852<ba||2===b&&592<ba)return 1;for(var O=0;;){O++;G=E-P;u[I]<B?(F=0,C=u[I]):u[I]>B?(F=J[Y+u[I]],C=D[X+u[I]]):(F=96,C=0);m=1<<E-P;H=n=1<<V;do n-=m,t[v+(T>>P)+n]=G<<24|F<<16|C|0;while(0!==n);for(m=1<<E-1;T&m;)m>>=1;if(0!==m?(T&=m-1,T+=m):T=0,I++,0===--Q[E]){if(E===N)break;E=c[d+u[I]]}if(E>L&&(T&q)!==p){0===P&&(P=L);v+=H;V=E-P;for(m=1<<V;V+
-P<N&&(m-=Q[V+P],!(0>=m));)V++,m<<=1;if(ba+=1<<V,1===b&&852<ba||2===b&&592<ba)return 1;p=T&q;t[p]=L<<24|V<<16|v-r|0}}return 0!==T&&(t[v+T]=E-P<<24|4194304),x.bits=L,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
+25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,q,t,r,u,x){var m,n,p,v,B,G,F,C,H=x.bits,E,I,M,L,V,P,ba=0,T,D=null,X=0,Q=new e.Buf16(16);v=new e.Buf16(16);var J=null,Y=0;for(E=0;15>=E;E++)Q[E]=0;for(I=0;I<q;I++)Q[c[d+I]]++;L=H;for(M=15;1<=M&&0===Q[M];M--);if(L>M&&(L=M),0===M)return t[r++]=20971520,t[r++]=20971520,x.bits=1,0;for(H=1;H<M&&0===Q[H];H++);L<H&&(L=H);for(E=m=1;15>=E;E++)if(m<<=1,m-=Q[E],0>m)return-1;if(0<m&&(0===b||1!==M))return-1;v[1]=0;for(E=1;15>E;E++)v[E+1]=v[E]+Q[E];for(I=
+0;I<q;I++)0!==c[d+I]&&(u[v[c[d+I]]++]=I);if(0===b?(D=J=u,B=19):1===b?(D=f,X-=257,J=g,Y-=257,B=256):(D=k,J=l,B=-1),T=0,I=0,E=H,v=r,V=L,P=0,p=-1,ba=1<<L,q=ba-1,1===b&&852<ba||2===b&&592<ba)return 1;for(var O=0;;){O++;G=E-P;u[I]<B?(F=0,C=u[I]):u[I]>B?(F=J[Y+u[I]],C=D[X+u[I]]):(F=96,C=0);m=1<<E-P;H=n=1<<V;do n-=m,t[v+(T>>P)+n]=G<<24|F<<16|C|0;while(0!==n);for(m=1<<E-1;T&m;)m>>=1;if(0!==m?(T&=m-1,T+=m):T=0,I++,0===--Q[E]){if(E===M)break;E=c[d+u[I]]}if(E>L&&(T&q)!==p){0===P&&(P=L);v+=H;V=E-P;for(m=1<<V;V+
+P<M&&(m-=Q[V+P],!(0>=m));)V++,m<<=1;if(ba+=1<<V,1===b&&852<ba||2===b&&592<ba)return 1;p=T&q;t[p]=L<<24|V<<16|v-r|0}}return 0!==T&&(t[v+T]=E-P<<24|4194304),x.bits=L,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
 b;this.extra_bits=c;this.extra_base=d;this.elems=e;this.max_length=f;this.has_stree=b&&b.length}function g(b,c){this.dyn_tree=b;this.max_code=0;this.stat_desc=c}function k(b,c){b.pending_buf[b.pending++]=255&c;b.pending_buf[b.pending++]=c>>>8&255}function l(b,c,d){b.bi_valid>ba-d?(b.bi_buf|=c<<b.bi_valid&65535,k(b,b.bi_buf),b.bi_buf=c>>ba-b.bi_valid,b.bi_valid+=d-ba):(b.bi_buf|=c<<b.bi_valid&65535,b.bi_valid+=d)}function m(b,c,d){l(b,d[2*c],d[2*c+1])}function n(b,c){var d=0;do d|=1&b,b>>>=1,d<<=1;
-while(0<--c);return d>>>1}function p(b,c,d){var e,f=Array(P+1),k=0;for(e=1;e<=P;e++)f[e]=k=k+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=n(f[e]++,e))}function q(b){var c;for(c=0;c<I;c++)b.dyn_ltree[2*c]=0;for(c=0;c<N;c++)b.dyn_dtree[2*c]=0;for(c=0;c<L;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*T]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function t(b){8<b.bi_valid?k(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function r(b,c,d,e){var f=2*c,k=2*d;
+while(0<--c);return d>>>1}function p(b,c,d){var e,f=Array(P+1),k=0;for(e=1;e<=P;e++)f[e]=k=k+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=n(f[e]++,e))}function q(b){var c;for(c=0;c<I;c++)b.dyn_ltree[2*c]=0;for(c=0;c<M;c++)b.dyn_dtree[2*c]=0;for(c=0;c<L;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*T]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function t(b){8<b.bi_valid?k(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function r(b,c,d,e){var f=2*c,k=2*d;
 return b[f]<b[k]||b[f]===b[k]&&e[c]<=e[d]}function u(b,c,d){for(var e=b.heap[d],f=d<<1;f<=b.heap_len&&(f<b.heap_len&&r(c,b.heap[f+1],b.heap[f],b.depth)&&f++,!r(c,e,b.heap[f],b.depth));)b.heap[d]=b.heap[f],d=f,f<<=1;b.heap[d]=e}function x(b,c,d){var e,f,k,g,n=0;if(0!==b.last_lit){do e=b.pending_buf[b.d_buf+2*n]<<8|b.pending_buf[b.d_buf+2*n+1],f=b.pending_buf[b.l_buf+n],n++,0===e?m(b,f,c):(k=Z[f],m(b,k+E+1,c),g=J[k],0!==g&&(f-=R[k],l(b,f,g)),e--,k=256>e?ca[e]:ca[256+(e>>>7)],m(b,k,d),g=Y[k],0!==g&&
 (e-=aa[k],l(b,e,g)));while(n<b.last_lit)}m(b,T,c)}function z(b,c){var d,e,f,k=c.dyn_tree;e=c.stat_desc.static_tree;var g=c.stat_desc.has_stree,l=c.stat_desc.elems,m=-1;b.heap_len=0;b.heap_max=V;for(d=0;d<l;d++)0!==k[2*d]?(b.heap[++b.heap_len]=m=d,b.depth[d]=0):k[2*d+1]=0;for(;2>b.heap_len;)f=b.heap[++b.heap_len]=2>m?++m:0,k[2*f]=1,b.depth[f]=0,b.opt_len--,g&&(b.static_len-=e[2*f+1]);c.max_code=m;for(d=b.heap_len>>1;1<=d;d--)u(b,k,d);f=l;do d=b.heap[1],b.heap[1]=b.heap[b.heap_len--],u(b,k,1),e=b.heap[1],
-b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,k[2*f]=k[2*d]+k[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,k[2*d+1]=k[2*e+1]=f,b.heap[1]=f++,u(b,k,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var n,q,g=c.dyn_tree,l=c.max_code,r=c.stat_desc.static_tree,t=c.stat_desc.has_stree,x=c.stat_desc.extra_bits,D=c.stat_desc.extra_base,v=c.stat_desc.max_length,z=0;for(e=0;e<=P;e++)b.bl_count[e]=0;g[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=g[2*g[2*f+1]+1]+
-1,e>v&&(e=v,z++),g[2*f+1]=e,f>l||(b.bl_count[e]++,n=0,f>=D&&(n=x[f-D]),q=g[2*f],b.opt_len+=q*(e+n),t&&(b.static_len+=q*(r[2*f+1]+n)));if(0!==z){do{for(e=v-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[v]--;z-=2}while(0<z);for(e=v;0!==e;e--)for(f=b.bl_count[e];0!==f;)n=b.heap[--d],n>l||(g[2*n+1]!==e&&(b.opt_len+=(e-g[2*n+1])*g[2*n],g[2*n+1]=e),f--)}p(k,m,b.bl_count)}function y(b,c,d){var e,f,k=-1,g=c[1],l=0,m=7,n=4;0===g&&(m=138,n=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=g,
+b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,k[2*f]=k[2*d]+k[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,k[2*d+1]=k[2*e+1]=f,b.heap[1]=f++,u(b,k,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var n,q,g=c.dyn_tree,l=c.max_code,t=c.stat_desc.static_tree,r=c.stat_desc.has_stree,x=c.stat_desc.extra_bits,D=c.stat_desc.extra_base,v=c.stat_desc.max_length,z=0;for(e=0;e<=P;e++)b.bl_count[e]=0;g[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=g[2*g[2*f+1]+1]+
+1,e>v&&(e=v,z++),g[2*f+1]=e,f>l||(b.bl_count[e]++,n=0,f>=D&&(n=x[f-D]),q=g[2*f],b.opt_len+=q*(e+n),r&&(b.static_len+=q*(t[2*f+1]+n)));if(0!==z){do{for(e=v-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[v]--;z-=2}while(0<z);for(e=v;0!==e;e--)for(f=b.bl_count[e];0!==f;)n=b.heap[--d],n>l||(g[2*n+1]!==e&&(b.opt_len+=(e-g[2*n+1])*g[2*n],g[2*n+1]=e),f--)}p(k,m,b.bl_count)}function y(b,c,d){var e,f,k=-1,g=c[1],l=0,m=7,n=4;0===g&&(m=138,n=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=g,
 g=c[2*(e+1)+1],++l<m&&f===g||(l<n?b.bl_tree[2*f]+=l:0!==f?(f!==k&&b.bl_tree[2*f]++,b.bl_tree[2*D]++):10>=l?b.bl_tree[2*X]++:b.bl_tree[2*Q]++,l=0,k=f,0===g?(m=138,n=3):f===g?(m=6,n=3):(m=7,n=4))}function A(b,c,d){var e,f,k=-1,g=c[1],n=0,p=7,q=4;0===g&&(p=138,q=3);for(e=0;e<=d;e++)if(f=g,g=c[2*(e+1)+1],!(++n<p&&f===g)){if(n<q){do m(b,f,b.bl_tree);while(0!==--n)}else 0!==f?(f!==k&&(m(b,f,b.bl_tree),n--),m(b,D,b.bl_tree),l(b,n-3,2)):10>=n?(m(b,X,b.bl_tree),l(b,n-3,3)):(m(b,Q,b.bl_tree),l(b,n-11,7));n=
-0;k=f;0===g?(p=138,q=3):f===g?(p=6,q=3):(p=7,q=4)}}function v(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return F;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return C;for(c=32;c<E;c++)if(0!==b.dyn_ltree[2*c])return C;return F}function B(b,c,d,e){l(b,(H<<1)+(e?1:0),3);t(b);k(b,d);k(b,~d);G.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var G=b("../utils/common"),F=0,C=1,H=0,E=256,I=E+1+29,N=30,L=19,V=2*I+1,P=15,ba=16,T=256,D=16,X=17,
-Q=18,J=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Y=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],O=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],K=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],M=Array(2*(I+2));e(M);var U=Array(2*N);e(U);var ca=Array(512);e(ca);var Z=Array(256);e(Z);var R=Array(29);e(R);var aa=Array(N);e(aa);var da,S,W,ga=!1;d._tr_init=function(b){if(!ga){var c,d,e,k=Array(P+1);for(e=d=0;28>e;e++)for(R[e]=d,c=0;c<1<<J[e];c++)Z[d++]=e;Z[d-1]=e;
-for(e=d=0;16>e;e++)for(aa[e]=d,c=0;c<1<<Y[e];c++)ca[d++]=e;for(d>>=7;e<N;e++)for(aa[e]=d<<7,c=0;c<1<<Y[e]-7;c++)ca[256+d++]=e;for(c=0;c<=P;c++)k[c]=0;for(c=0;143>=c;)M[2*c+1]=8,c++,k[8]++;for(;255>=c;)M[2*c+1]=9,c++,k[9]++;for(;279>=c;)M[2*c+1]=7,c++,k[7]++;for(;287>=c;)M[2*c+1]=8,c++,k[8]++;p(M,I+1,k);for(c=0;c<N;c++)U[2*c+1]=5,U[2*c]=n(c,5);da=new f(M,J,E+1,I,P);S=new f(U,Y,0,N,P);W=new f([],O,0,L,7);ga=!0}b.l_desc=new g(b.dyn_ltree,da);b.d_desc=new g(b.dyn_dtree,S);b.bl_desc=new g(b.bl_tree,W);
-b.bi_buf=0;b.bi_valid=0;q(b)};d._tr_stored_block=B;d._tr_flush_block=function(b,c,d,e){var f,k,g=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=v(b));z(b,b.l_desc);z(b,b.d_desc);y(b,b.dyn_ltree,b.l_desc.max_code);y(b,b.dyn_dtree,b.d_desc.max_code);z(b,b.bl_desc);for(g=L-1;3<=g&&0===b.bl_tree[2*K[g]+1];g--);g=(b.opt_len+=3*(g+1)+14,g);f=b.opt_len+3+7>>>3;k=b.static_len+3+7>>>3;k<=f&&(f=k)}else f=k=d+5;if(d+4<=f&&-1!==c)B(b,c,d,e);else if(4===b.strategy||k===f)l(b,2+(e?1:0),3),x(b,M,U);else{l(b,
+0;k=f;0===g?(p=138,q=3):f===g?(p=6,q=3):(p=7,q=4)}}function v(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return F;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return C;for(c=32;c<E;c++)if(0!==b.dyn_ltree[2*c])return C;return F}function B(b,c,d,e){l(b,(H<<1)+(e?1:0),3);t(b);k(b,d);k(b,~d);G.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var G=b("../utils/common"),F=0,C=1,H=0,E=256,I=E+1+29,M=30,L=19,V=2*I+1,P=15,ba=16,T=256,D=16,X=17,
+Q=18,J=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Y=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],O=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],K=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],N=Array(2*(I+2));e(N);var U=Array(2*M);e(U);var ca=Array(512);e(ca);var Z=Array(256);e(Z);var R=Array(29);e(R);var aa=Array(M);e(aa);var da,S,W,ga=!1;d._tr_init=function(b){if(!ga){var c,d,e,k=Array(P+1);for(e=d=0;28>e;e++)for(R[e]=d,c=0;c<1<<J[e];c++)Z[d++]=e;Z[d-1]=e;
+for(e=d=0;16>e;e++)for(aa[e]=d,c=0;c<1<<Y[e];c++)ca[d++]=e;for(d>>=7;e<M;e++)for(aa[e]=d<<7,c=0;c<1<<Y[e]-7;c++)ca[256+d++]=e;for(c=0;c<=P;c++)k[c]=0;for(c=0;143>=c;)N[2*c+1]=8,c++,k[8]++;for(;255>=c;)N[2*c+1]=9,c++,k[9]++;for(;279>=c;)N[2*c+1]=7,c++,k[7]++;for(;287>=c;)N[2*c+1]=8,c++,k[8]++;p(N,I+1,k);for(c=0;c<M;c++)U[2*c+1]=5,U[2*c]=n(c,5);da=new f(N,J,E+1,I,P);S=new f(U,Y,0,M,P);W=new f([],O,0,L,7);ga=!0}b.l_desc=new g(b.dyn_ltree,da);b.d_desc=new g(b.dyn_dtree,S);b.bl_desc=new g(b.bl_tree,W);
+b.bi_buf=0;b.bi_valid=0;q(b)};d._tr_stored_block=B;d._tr_flush_block=function(b,c,d,e){var f,k,g=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=v(b));z(b,b.l_desc);z(b,b.d_desc);y(b,b.dyn_ltree,b.l_desc.max_code);y(b,b.dyn_dtree,b.d_desc.max_code);z(b,b.bl_desc);for(g=L-1;3<=g&&0===b.bl_tree[2*K[g]+1];g--);g=(b.opt_len+=3*(g+1)+14,g);f=b.opt_len+3+7>>>3;k=b.static_len+3+7>>>3;k<=f&&(f=k)}else f=k=d+5;if(d+4<=f&&-1!==c)B(b,c,d,e);else if(4===b.strategy||k===f)l(b,2+(e?1:0),3),x(b,N,U);else{l(b,
 4+(e?1:0),3);c=b.l_desc.max_code+1;d=b.d_desc.max_code+1;g+=1;l(b,c-257,5);l(b,d-1,5);l(b,g-4,4);for(f=0;f<g;f++)l(b,b.bl_tree[2*K[f]+1],3);A(b,b.dyn_ltree,c-1);A(b,b.dyn_dtree,d-1);x(b,b.dyn_ltree,b.dyn_dtree)}q(b);e&&t(b)};d._tr_tally=function(b,c,d){return b.pending_buf[b.d_buf+2*b.last_lit]=c>>>8&255,b.pending_buf[b.d_buf+2*b.last_lit+1]=255&c,b.pending_buf[b.l_buf+b.last_lit]=255&d,b.last_lit++,0===c?b.dyn_ltree[2*d]++:(b.matches++,c--,b.dyn_ltree[2*(Z[d]+E+1)]++,b.dyn_dtree[2*(256>c?ca[c]:ca[256+
-(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){l(b,2,3);m(b,T,M);16===b.bi_valid?(k(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,c,d){d=
+(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){l(b,2,3);m(b,T,N);16===b.bi_valid?(k(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,c,d){d=
 b("./lib/utils/common").assign;var e=b("./lib/deflate"),f=b("./lib/inflate");b=b("./lib/zlib/constants");var g={};d(g,e,f,b);c.exports=g},{"./lib/deflate":1,"./lib/inflate":2,"./lib/utils/common":3,"./lib/zlib/constants":6}]},{},[])("/")});window.urlParams=window.urlParams||{};window.isLocalStorage=window.isLocalStorage||!1;window.isSvgBrowser=window.isSvgBrowser||0>navigator.userAgent.indexOf("MSIE")||9<=document.documentMode;window.EXPORT_URL=window.EXPORT_URL||"https://exp.draw.io/ImageExport4/export";
 window.SAVE_URL=window.SAVE_URL||"save";window.OPEN_URL=window.OPEN_URL||"open";window.PROXY_URL=window.PROXY_URL||"proxy";window.SHAPES_PATH=window.SHAPES_PATH||"shapes";window.GRAPH_IMAGE_PATH=window.GRAPH_IMAGE_PATH||"img";window.ICONSEARCH_PATH=window.ICONSEARCH_PATH||0<=navigator.userAgent.indexOf("MSIE")||urlParams.dev?"iconSearch":"https://www.draw.io/iconSearch";window.TEMPLATE_PATH=window.TEMPLATE_PATH||"/templates";window.RESOURCES_PATH=window.RESOURCES_PATH||"resources";
 window.RESOURCE_BASE=window.RESOURCE_BASE||RESOURCES_PATH+"/dia";window.DRAWIO_LOG_URL=window.DRAWIO_LOG_URL||"";window.mxLoadResources=window.mxLoadResources||!1;window.mxLanguage=window.mxLanguage||function(){var a="1"==urlParams.offline?"en":urlParams.lang;if(null==a&&"undefined"!=typeof JSON&&isLocalStorage)try{var b=localStorage.getItem(".drawio-config");null!=b&&(a=JSON.parse(b).language||null)}catch(c){isLocalStorage=!1}return a}();
@@ -663,8 +663,8 @@ mxArrowConnector.prototype.resetStyles=function(){mxShape.prototype.resetStyles.
 mxArrowConnector.prototype.augmentBoundingBox=function(a){mxShape.prototype.augmentBoundingBox.apply(this,arguments);var b=this.getEdgeWidth();this.isMarkerStart()&&(b=Math.max(b,this.getStartArrowWidth()));this.isMarkerEnd()&&(b=Math.max(b,this.getEndArrowWidth()));a.grow((b/2+this.strokewidth)*this.scale)};
 mxArrowConnector.prototype.paintEdgeShape=function(a,b){var c=this.strokewidth;this.outline&&(c=Math.max(1,mxUtils.getNumber(this.style,mxConstants.STYLE_STROKEWIDTH,this.strokewidth)));for(var d=this.getStartArrowWidth()+c,e=this.getEndArrowWidth()+c,f=this.outline?this.getEdgeWidth()+c:this.getEdgeWidth(),g=this.isOpenEnded(),k=this.isMarkerStart(),l=this.isMarkerEnd(),m=g?0:this.arrowSpacing+c/2,n=this.startSize+c,c=this.endSize+c,p=this.isArrowRounded(),q=b[b.length-1],t=1;t<b.length-1&&b[t].x==
 b[0].x&&b[t].y==b[0].y;)t++;var r=b[t].x-b[0].x,t=b[t].y-b[0].y,u=Math.sqrt(r*r+t*t);if(0!=u){var x=r/u,z,y=x,A=t/u,v,B=A,u=f*A,G=-f*x,F=[];p?a.setLineJoin("round"):2<b.length&&a.setMiterLimit(1.42);a.begin();r=x;t=A;if(k&&!g)this.paintMarker(a,b[0].x,b[0].y,x,A,n,d,f,m,!0);else{z=b[0].x+u/2+m*x;v=b[0].y+G/2+m*A;var C=b[0].x-u/2+m*x,H=b[0].y-G/2+m*A;g?(a.moveTo(z,v),F.push(function(){a.lineTo(C,H)})):(a.moveTo(C,H),a.lineTo(z,v))}for(var E=v=z=0,u=0;u<b.length-2;u++)if(G=mxUtils.relativeCcw(b[u].x,
-b[u].y,b[u+1].x,b[u+1].y,b[u+2].x,b[u+2].y),z=b[u+2].x-b[u+1].x,v=b[u+2].y-b[u+1].y,E=Math.sqrt(z*z+v*v),0!=E&&(y=z/E,B=v/E,tmp=Math.max(Math.sqrt((x*y+A*B+1)/2),.04),z=x+y,v=A+B,E=Math.sqrt(z*z+v*v),0!=E)){z/=E;v/=E;var E=Math.max(tmp,Math.min(this.strokewidth/200+.04,.35)),E=0!=G&&p?Math.max(.1,E):Math.max(tmp,.06),I=b[u+1].x+v*f/2/E,N=b[u+1].y-z*f/2/E;v=b[u+1].x-v*f/2/E;z=b[u+1].y+z*f/2/E;0!=G&&p?-1==G?(G=v+B*f,E=z-y*f,a.lineTo(v+A*f,z-x*f),a.quadTo(I,N,G,E),function(b,c){F.push(function(){a.lineTo(b,
-c)})}(v,z)):(a.lineTo(I,N),function(b,c){var d=I-A*f,e=N+x*f,k=I-B*f,g=N+y*f;F.push(function(){a.quadTo(b,c,d,e)});F.push(function(){a.lineTo(k,g)})}(v,z)):(a.lineTo(I,N),function(b,c){F.push(function(){a.lineTo(b,c)})}(v,z));x=y;A=B}u=f*B;G=-f*y;if(l&&!g)this.paintMarker(a,q.x,q.y,-x,-A,c,e,f,m,!1);else{a.lineTo(q.x-m*y+u/2,q.y-m*B+G/2);var L=q.x-m*y-u/2,V=q.y-m*B-G/2;g?(a.moveTo(L,V),F.splice(0,0,function(){a.moveTo(L,V)})):a.lineTo(L,V)}for(u=F.length-1;0<=u;u--)F[u]();g?(a.end(),a.stroke()):(a.close(),
+b[u].y,b[u+1].x,b[u+1].y,b[u+2].x,b[u+2].y),z=b[u+2].x-b[u+1].x,v=b[u+2].y-b[u+1].y,E=Math.sqrt(z*z+v*v),0!=E&&(y=z/E,B=v/E,tmp=Math.max(Math.sqrt((x*y+A*B+1)/2),.04),z=x+y,v=A+B,E=Math.sqrt(z*z+v*v),0!=E)){z/=E;v/=E;var E=Math.max(tmp,Math.min(this.strokewidth/200+.04,.35)),E=0!=G&&p?Math.max(.1,E):Math.max(tmp,.06),I=b[u+1].x+v*f/2/E,M=b[u+1].y-z*f/2/E;v=b[u+1].x-v*f/2/E;z=b[u+1].y+z*f/2/E;0!=G&&p?-1==G?(G=v+B*f,E=z-y*f,a.lineTo(v+A*f,z-x*f),a.quadTo(I,M,G,E),function(b,c){F.push(function(){a.lineTo(b,
+c)})}(v,z)):(a.lineTo(I,M),function(b,c){var d=I-A*f,e=M+x*f,k=I-B*f,g=M+y*f;F.push(function(){a.quadTo(b,c,d,e)});F.push(function(){a.lineTo(k,g)})}(v,z)):(a.lineTo(I,M),function(b,c){F.push(function(){a.lineTo(b,c)})}(v,z));x=y;A=B}u=f*B;G=-f*y;if(l&&!g)this.paintMarker(a,q.x,q.y,-x,-A,c,e,f,m,!1);else{a.lineTo(q.x-m*y+u/2,q.y-m*B+G/2);var L=q.x-m*y-u/2,V=q.y-m*B-G/2;g?(a.moveTo(L,V),F.splice(0,0,function(){a.moveTo(L,V)})):a.lineTo(L,V)}for(u=F.length-1;0<=u;u--)F[u]();g?(a.end(),a.stroke()):(a.close(),
 a.fillAndStroke());a.setShadow(!1);a.setMiterLimit(4);p&&a.setLineJoin("flat");2<b.length&&(a.setMiterLimit(4),k&&!g&&(a.begin(),this.paintMarker(a,b[0].x,b[0].y,r,t,n,d,f,m,!0),a.stroke(),a.end()),l&&!g&&(a.begin(),this.paintMarker(a,q.x,q.y,-x,-A,c,e,f,m,!0),a.stroke(),a.end()))}};
 mxArrowConnector.prototype.paintMarker=function(a,b,c,d,e,f,g,k,l,m){g=k/g;var n=k*e/2;k=-k*d/2;var p=(l+f)*d;f=(l+f)*e;m?a.moveTo(b-n+p,c-k+f):a.lineTo(b-n+p,c-k+f);a.lineTo(b-n/g+p,c-k/g+f);a.lineTo(b+l*d,c+l*e);a.lineTo(b+n/g+p,c+k/g+f);a.lineTo(b+n+p,c+k+f)};mxArrowConnector.prototype.isArrowRounded=function(){return this.isRounded};mxArrowConnector.prototype.getStartArrowWidth=function(){return mxConstants.ARROW_WIDTH};mxArrowConnector.prototype.getEndArrowWidth=function(){return mxConstants.ARROW_WIDTH};
 mxArrowConnector.prototype.getEdgeWidth=function(){return mxConstants.ARROW_WIDTH/3};mxArrowConnector.prototype.isOpenEnded=function(){return!1};mxArrowConnector.prototype.isMarkerStart=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE};mxArrowConnector.prototype.isMarkerEnd=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE};
@@ -2322,12 +2322,12 @@ k=d.getAttribute("h"),g=null==g?80:parseInt(g,10),k=null==k?80:parseInt(k,10);b(
 "#00a8ff";mxConstants.DEFAULT_VALID_COLOR="#00a8ff";mxConstants.LABEL_HANDLE_FILLCOLOR="#cee7ff";mxConstants.GUIDE_COLOR="#0088cf";mxConstants.HIGHLIGHT_OPACITY=30;mxConstants.HIGHLIGHT_SIZE=8;mxEdgeHandler.prototype.snapToTerminals=!0;mxGraphHandler.prototype.guidesEnabled=!0;mxGuide.prototype.isEnabledForEvent=function(a){return!mxEvent.isAltDown(a)};var b=mxConnectionHandler.prototype.isCreateTarget;mxConnectionHandler.prototype.isCreateTarget=function(a){return mxEvent.isControlDown(a)||b.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=!0;mxConnectionHandler.prototype.cursor="crosshair";mxConnectionHandler.prototype.createEdgeState=function(a){a=this.graph.createCurrentEdgeStyle();a=this.graph.createEdge(null,null,null,null,null,a);a=new mxCellState(this.graph.view,a,this.graph.getCellStyle(a));for(var b in this.graph.currentEdgeStyle)a.style[b]=
 this.graph.currentEdgeStyle[b];return a};var c=mxConnectionHandler.prototype.createShape;mxConnectionHandler.prototype.createShape=function(){var a=c.apply(this,arguments);a.isDashed="1"==this.graph.currentEdgeStyle[mxConstants.STYLE_DASHED];return a};mxConnectionHandler.prototype.updatePreview=function(a){};var d=mxConnectionHandler.prototype.createMarker;mxConnectionHandler.prototype.createMarker=function(){var a=d.apply(this,arguments),b=a.getCell;a.getCell=mxUtils.bind(this,function(a){var c=
-b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",html:"1",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");
-null!=this.currentEdgeStyle.rounded&&(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(a+="elbow="+this.currentEdgeStyle.elbow+";");return 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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(K){}return d}if(null!=
-a.shape)if(null!=a.shape.stencil){if(null!=a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};
-Graph.prototype.isValidRoot=function(a){for(var b=this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget",
-"1"))};Graph.prototype.createGroupCell=function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
+b.apply(this,arguments);this.error=null;return c});return a};Graph.prototype.defaultVertexStyle={};Graph.prototype.defaultEdgeStyle={edgeStyle:"orthogonalEdgeStyle",rounded:"0",jettySize:"auto",orthogonalLoop:"1"};Graph.prototype.createCurrentEdgeStyle=function(){var a="edgeStyle="+(this.currentEdgeStyle.edgeStyle||"none")+";";null!=this.currentEdgeStyle.shape&&(a+="shape="+this.currentEdgeStyle.shape+";");null!=this.currentEdgeStyle.curved&&(a+="curved="+this.currentEdgeStyle.curved+";");null!=this.currentEdgeStyle.rounded&&
+(a+="rounded="+this.currentEdgeStyle.rounded+";");null!=this.currentEdgeStyle.comic&&(a+="comic="+this.currentEdgeStyle.comic+";");"elbowEdgeStyle"==this.currentEdgeStyle.edgeStyle&&null!=this.currentEdgeStyle.elbow&&(a+="elbow="+this.currentEdgeStyle.elbow+";");return 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.getAllConnectionConstraints=function(a,b){if(null!=a){var c=mxUtils.getValue(a.style,"points",null);if(null!=c){var d=[];try{for(var e=JSON.parse(c),c=0;c<e.length;c++){var f=e[c];d.push(new mxConnectionConstraint(new mxPoint(f[0],f[1]),2<f.length?"0"!=f[2]:!0))}}catch(K){}return d}if(null!=a.shape)if(null!=a.shape.stencil){if(null!=
+a.shape.stencil)return a.shape.stencil.constraints}else if(null!=a.shape.constraints)return a.shape.constraints}return null};Graph.prototype.flipEdge=function(a){if(null!=a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);null!=b&&(b=mxUtils.getValue(b,mxConstants.STYLE_ELBOW,mxConstants.ELBOW_HORIZONTAL)==mxConstants.ELBOW_HORIZONTAL?mxConstants.ELBOW_VERTICAL:mxConstants.ELBOW_HORIZONTAL,this.setCellStyles(mxConstants.STYLE_ELBOW,b,[a]))}};Graph.prototype.isValidRoot=function(a){for(var b=
+this.model.getChildCount(a),c=0,d=0;d<b;d++){var e=this.model.getChildAt(a,d);this.model.isVertex(e)&&(e=this.getCellGeometry(e),null==e||e.relative||c++)}return 0<c||this.isContainer(a)};Graph.prototype.isValidDropTarget=function(a){var b=this.view.getState(a),b=null!=b?b.style:this.getCellStyle(a);return"1"!=mxUtils.getValue(b,"part","0")&&(this.isContainer(a)||mxGraph.prototype.isValidDropTarget.apply(this,arguments)&&"0"!=mxUtils.getValue(b,"dropTarget","1"))};Graph.prototype.createGroupCell=
+function(){var a=mxGraph.prototype.createGroupCell.apply(this,arguments);a.setStyle("group");return a};Graph.prototype.isExtendParentsOnAdd=function(a){var b=mxGraph.prototype.isExtendParentsOnAdd.apply(this,arguments);if(b&&null!=a&&null!=this.layoutManager){var c=this.model.getParent(a);null!=c&&(c=this.layoutManager.getLayout(c),null!=c&&c.constructor==mxStackLayout&&(b=!1))}return b};Graph.prototype.getPreferredSizeForCell=function(a){var b=mxGraph.prototype.getPreferredSizeForCell.apply(this,
 arguments);null!=b&&(b.width+=10,b.height+=4,this.gridEnabled&&(b.width=this.snap(b.width),b.height=this.snap(b.height)));return b};Graph.prototype.turnShapes=function(a){var b=this.getModel(),c=[];b.beginUpdate();try{for(var d=0;d<a.length;d++){var e=a[d];if(b.isEdge(e)){var f=b.getTerminal(e,!0),k=b.getTerminal(e,!1);b.setTerminal(e,k,!0);b.setTerminal(e,f,!1);var g=b.getGeometry(e);if(null!=g){g=g.clone();null!=g.points&&g.points.reverse();var l=g.getTerminalPoint(!0),m=g.getTerminalPoint(!1);
 g.setTerminalPoint(l,!1);g.setTerminalPoint(m,!0);b.setGeometry(e,g);var n=this.view.getState(e),p=this.view.getState(f),q=this.view.getState(k);if(null!=n){var t=null!=p?this.getConnectionConstraint(n,p,!0):null,r=null!=q?this.getConnectionConstraint(n,q,!1):null;this.setConnectionConstraint(e,f,!0,r);this.setConnectionConstraint(e,k,!1,t)}c.push(e)}}else if(b.isVertex(e)&&(g=this.getCellGeometry(e),null!=g)){g=g.clone();g.x+=g.width/2-g.height/2;g.y+=g.height/2-g.width/2;var u=g.width;g.width=g.height;
 g.height=u;b.setGeometry(e,g);var x=this.view.getState(e);if(null!=x){var v=x.style[mxConstants.STYLE_DIRECTION]||"east";"east"==v?v="south":"south"==v?v="west":"west"==v?v="north":"north"==v&&(v="east");this.setCellStyles(mxConstants.STYLE_DIRECTION,v,[e])}c.push(e)}}}finally{b.endUpdate()}return c};Graph.prototype.processChange=function(a){mxGraph.prototype.processChange.apply(this,arguments);if(a instanceof mxValueChange&&null!=a.cell.value&&"object"==typeof a.cell.value){var b=this.model.getDescendants(a.cell);
@@ -2422,7 +2422,7 @@ this.editingHandler);var c=this.graph.getLinkForCell(this.state.cell);this.updat
 "",this.updateLinkHint(b),this.graph.container.appendChild(this.linkHint)),b=this.graph.createLinkForHint(b,b),this.linkHint.innerHTML="",this.linkHint.appendChild(b),this.graph.isEnabled()&&"function"===typeof this.graph.editLink&&(b=document.createElement("img"),b.setAttribute("src",IMAGE_PATH+"/edit.gif"),b.setAttribute("title",mxResources.get("editLink")),b.setAttribute("width","11"),b.setAttribute("height","11"),b.style.marginLeft="10px",b.style.marginBottom="-1px",b.style.cursor="pointer",this.linkHint.appendChild(b),
 mxEvent.addListener(b,"click",mxUtils.bind(this,function(a){this.graph.setSelectionCell(this.state.cell);this.graph.editLink();mxEvent.consume(a)}))))};mxEdgeHandler.prototype.updateLinkHint=mxVertexHandler.prototype.updateLinkHint;var E=mxEdgeHandler.prototype.init;mxEdgeHandler.prototype.init=function(){E.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.state.view.graph.connectionHandler.isEnabled()});var a=mxUtils.bind(this,function(){null!=this.linkHint&&
 (this.linkHint.style.display=1==this.graph.getSelectionCount()?"":"none");null!=this.labelShape&&(this.labelShape.node.style.display=this.graph.isEnabled()&&this.graph.getSelectionCount()<this.graph.graphHandler.maxCells?"":"none")});this.selectionHandler=mxUtils.bind(this,function(b,c){a()});this.graph.getSelectionModel().addListener(mxEvent.CHANGE,this.selectionHandler);this.changeHandler=mxUtils.bind(this,function(b,c){this.updateLinkHint(this.graph.getLinkForCell(this.state.cell));a();this.redrawHandles()});
-this.graph.getModel().addListener(mxEvent.CHANGE,this.changeHandler);var b=this.graph.getLinkForCell(this.state.cell);null!=b&&(this.updateLinkHint(b),this.redrawHandles())};var I=mxConnectionHandler.prototype.init;mxConnectionHandler.prototype.init=function(){I.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.graph.connectionHandler.isEnabled()})};var N=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){N.apply(this);
+this.graph.getModel().addListener(mxEvent.CHANGE,this.changeHandler);var b=this.graph.getLinkForCell(this.state.cell);null!=b&&(this.updateLinkHint(b),this.redrawHandles())};var I=mxConnectionHandler.prototype.init;mxConnectionHandler.prototype.init=function(){I.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.graph.connectionHandler.isEnabled()})};var M=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){M.apply(this);
 if(null!=this.state&&null!=this.linkHint){var a=new mxPoint(this.state.getCenterX(),this.state.getCenterY()),b=new mxRectangle(this.state.x,this.state.y-22,this.state.width+24,this.state.height+22),a=mxUtils.getBoundingBox(b,this.state.style[mxConstants.STYLE_ROTATION]||"0",a),b=null!=a?mxUtils.getBoundingBox(this.state,this.state.style[mxConstants.STYLE_ROTATION]||"0"):this.state;null==a&&(a=this.state);this.linkHint.style.left=Math.round(b.x+(b.width-this.linkHint.clientWidth)/2)+"px";this.linkHint.style.top=
 Math.round(a.y+a.height+this.verticalOffset/2+6+this.state.view.graph.tolerance)+"px"}};var L=mxVertexHandler.prototype.reset;mxVertexHandler.prototype.reset=function(){L.apply(this,arguments);null!=this.rotationShape&&null!=this.rotationShape.node&&(this.rotationShape.node.style.display=1==this.graph.getSelectionCount()?"":"none")};var V=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=function(){V.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),
 this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var P=mxEdgeHandler.prototype.redrawHandles;mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(P.apply(this),null!=this.state&&
@@ -2431,8 +2431,8 @@ var T=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function()
 (function(){function a(){mxCylinder.call(this)}function b(){mxActor.call(this)}function c(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function e(){mxCylinder.call(this)}function f(){mxActor.call(this)}function g(){mxCylinder.call(this)}function k(){mxActor.call(this)}function l(){mxActor.call(this)}function m(){mxActor.call(this)}function n(){mxActor.call(this)}function p(){mxActor.call(this)}function q(){mxActor.call(this)}function t(){mxActor.call(this)}function r(a,b){this.canvas=
 a;this.canvas.setLineJoin("round");this.canvas.setLineCap("round");this.defaultVariation=b;this.originalLineTo=this.canvas.lineTo;this.canvas.lineTo=mxUtils.bind(this,r.prototype.lineTo);this.originalMoveTo=this.canvas.moveTo;this.canvas.moveTo=mxUtils.bind(this,r.prototype.moveTo);this.originalClose=this.canvas.close;this.canvas.close=mxUtils.bind(this,r.prototype.close);this.originalQuadTo=this.canvas.quadTo;this.canvas.quadTo=mxUtils.bind(this,r.prototype.quadTo);this.originalCurveTo=this.canvas.curveTo;
 this.canvas.curveTo=mxUtils.bind(this,r.prototype.curveTo);this.originalArcTo=this.canvas.arcTo;this.canvas.arcTo=mxUtils.bind(this,r.prototype.arcTo)}function u(){mxRectangleShape.call(this)}function x(){mxActor.call(this)}function z(){mxActor.call(this)}function y(){mxRectangleShape.call(this)}function A(){mxRectangleShape.call(this)}function v(){mxCylinder.call(this)}function B(){mxShape.call(this)}function G(){mxShape.call(this)}function F(){mxEllipse.call(this)}function C(){mxShape.call(this)}
-function H(){mxShape.call(this)}function E(){mxRectangleShape.call(this)}function I(){mxShape.call(this)}function N(){mxShape.call(this)}function L(){mxShape.call(this)}function V(){mxCylinder.call(this)}function P(){mxDoubleEllipse.call(this)}function ba(){mxDoubleEllipse.call(this)}function T(){mxArrowConnector.call(this);this.spacing=0}function D(){mxArrowConnector.call(this);this.spacing=0}function X(){mxActor.call(this)}function Q(){mxRectangleShape.call(this)}function J(){mxActor.call(this)}
-function Y(){mxActor.call(this)}function O(){mxActor.call(this)}function K(){mxActor.call(this)}function M(){mxActor.call(this)}function U(){mxActor.call(this)}function ca(){mxActor.call(this)}function Z(){mxActor.call(this)}function R(){mxActor.call(this)}function aa(){mxEllipse.call(this)}function da(){mxEllipse.call(this)}function S(){mxEllipse.call(this)}function W(){mxRhombus.call(this)}function ga(){mxEllipse.call(this)}function ea(){mxEllipse.call(this)}function ha(){mxEllipse.call(this)}function la(){mxEllipse.call(this)}
+function H(){mxShape.call(this)}function E(){mxRectangleShape.call(this)}function I(){mxShape.call(this)}function M(){mxShape.call(this)}function L(){mxShape.call(this)}function V(){mxCylinder.call(this)}function P(){mxDoubleEllipse.call(this)}function ba(){mxDoubleEllipse.call(this)}function T(){mxArrowConnector.call(this);this.spacing=0}function D(){mxArrowConnector.call(this);this.spacing=0}function X(){mxActor.call(this)}function Q(){mxRectangleShape.call(this)}function J(){mxActor.call(this)}
+function Y(){mxActor.call(this)}function O(){mxActor.call(this)}function K(){mxActor.call(this)}function N(){mxActor.call(this)}function U(){mxActor.call(this)}function ca(){mxActor.call(this)}function Z(){mxActor.call(this)}function R(){mxActor.call(this)}function aa(){mxEllipse.call(this)}function da(){mxEllipse.call(this)}function S(){mxEllipse.call(this)}function W(){mxRhombus.call(this)}function ga(){mxEllipse.call(this)}function ea(){mxEllipse.call(this)}function ha(){mxEllipse.call(this)}function la(){mxEllipse.call(this)}
 function ma(){mxActor.call(this)}function na(){mxActor.call(this)}function oa(){mxActor.call(this)}function xa(a,b,c,d,e,f,k,g,l,m){k+=l;var n=d.clone();d.x-=e*(2*k+l);d.y-=f*(2*k+l);e*=k+l;f*=k+l;return function(){a.ellipse(n.x-e-k,n.y-f-k,2*k,2*k);m?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,mxCylinder);a.prototype.size=20;a.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(b,e),a.lineTo(b,b),
 a.lineTo(0,0),a.moveTo(b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(b,e),a.lineTo(0,e-b),a.lineTo(0,0),a.close());a.end()};mxCellRenderer.prototype.defaultShapes.cube=a;var ua=Math.tan(mxUtils.toRadians(30)),ja=(.5-ua)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/ua);a.translate((d-b)/2,(e-b)/2+b/4);a.moveTo(0,.25*b);a.lineTo(.5*b,b*ja);a.lineTo(b,.25*b);a.lineTo(.5*b,(.5-ja)*b);a.lineTo(0,.25*
 b);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.isoRectangle=b;mxUtils.extend(c,mxCylinder);c.prototype.size=20;c.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(d,e/(.5+ua));f?(a.moveTo(0,.25*b),a.lineTo(.5*b,(.5-ja)*b),a.lineTo(b,.25*b),a.moveTo(.5*b,(.5-ja)*b),a.lineTo(.5*b,(1-ja)*b)):(a.translate((d-b)/2,(e-b)/2),a.moveTo(0,.25*b),a.lineTo(.5*b,b*ja),a.lineTo(b,.25*b),a.lineTo(b,.75*b),a.lineTo(.5*b,(1-ja)*b),a.lineTo(0,.75*b),a.close());a.end()};mxCellRenderer.prototype.defaultShapes.isoCube=
@@ -2472,7 +2472,7 @@ a,b,c,d,Math.min(e,f))};mxCellRenderer.prototype.defaultShapes.umlLifeline=E;mxU
 e){var f=this.corner,k=Math.min(d,Math.max(f,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),g=Math.min(e,Math.max(1.5*f,parseFloat(mxUtils.getValue(this.style,"height",this.height))));a.begin();a.moveTo(b,c);a.lineTo(b+k,c);a.lineTo(b+k,c+Math.max(0,g-1.5*f));a.lineTo(b+Math.max(0,k-f),c+g);a.lineTo(b,c+g);a.close();a.fillAndStroke();a.begin();a.moveTo(b+k,c);a.lineTo(b+d,c);a.lineTo(b+d,c+e);a.lineTo(b,c+e);a.lineTo(b,c+g);a.stroke()};mxCellRenderer.prototype.defaultShapes.umlFrame=
 I;mxPerimeter.LifelinePerimeter=function(a,b,c,d){d=E.prototype.size;null!=b&&(d=mxUtils.getValue(b.style,"size",d)*b.view.scale);b=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;c.x<a.getCenterX()&&(b=-1*(b+1));return new mxPoint(a.getCenterX()+b,Math.min(a.y+a.height,Math.max(a.y+d,c.y)))};mxStyleRegistry.putValue("lifelinePerimeter",mxPerimeter.LifelinePerimeter);mxPerimeter.OrthogonalPerimeter=function(a,b,c,d){d=!0;return mxPerimeter.RectanglePerimeter.apply(this,arguments)};
 mxStyleRegistry.putValue("orthogonalPerimeter",mxPerimeter.OrthogonalPerimeter);mxPerimeter.BackbonePerimeter=function(a,b,c,d){d=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;null!=b.style.backboneSize&&(d+=parseFloat(b.style.backboneSize)*b.view.scale/2-1);if("south"==b.style[mxConstants.STYLE_DIRECTION]||"north"==b.style[mxConstants.STYLE_DIRECTION])return c.x<a.getCenterX()&&(d=-1*(d+1)),new mxPoint(a.getCenterX()+d,Math.min(a.y+a.height,Math.max(a.y,c.y)));c.y<a.getCenterY()&&
-(d=-1*(d+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,c.x)),a.getCenterY()+d)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxUtils.extend(N,mxShape);N.prototype.size=10;N.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.lollipop=N;mxUtils.extend(L,
+(d=-1*(d+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,c.x)),a.getCenterY()+d)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxUtils.extend(M,mxShape);M.prototype.size=10;M.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.lollipop=M;mxUtils.extend(L,
 mxShape);L.prototype.size=10;L.prototype.inset=2;L.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size)),k=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,c);a.begin();a.moveTo(d/2,f+k);a.lineTo(d/2,e);a.end();a.stroke();a.begin();a.moveTo((d-f)/2-k,f/2);a.quadTo((d-f)/2-k,f+k,d/2,f+k);a.quadTo((d+f)/2+k,f+k,(d+f)/2+k,f/2);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.requires=L;mxUtils.extend(V,
 mxCylinder);V.prototype.jettyWidth=32;V.prototype.jettyHeight=12;V.prototype.redrawPath=function(a,b,c,d,e,f){var k=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));b=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));c=k/2;var k=c+k/2,g=.3*e-b/2,l=.7*e-b/2;f?(a.moveTo(c,g),a.lineTo(k,g),a.lineTo(k,g+b),a.lineTo(c,g+b),a.moveTo(c,l),a.lineTo(k,l),a.lineTo(k,l+b),a.lineTo(c,l+b)):(a.moveTo(c,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(c,e),a.lineTo(c,l+b),a.lineTo(0,
 l+b),a.lineTo(0,l),a.lineTo(c,l),a.lineTo(c,g+b),a.lineTo(0,g+b),a.lineTo(0,g),a.lineTo(c,g),a.close());a.end()};mxCellRenderer.prototype.defaultShapes.component=V;mxUtils.extend(P,mxDoubleEllipse);P.prototype.outerStroke=!0;P.prototype.paintVertexShape=function(a,b,c,d,e){var f=Math.min(4,Math.min(d/5,e/5));0<d&&0<e&&(a.ellipse(b+f,c+f,d-2*f,e-2*f),a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(b,c,d,e),a.stroke())};mxCellRenderer.prototype.defaultShapes.endState=P;mxUtils.extend(ba,
@@ -2485,7 +2485,7 @@ c+e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.internalStorage=
 var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint((d+b)/2,c),new mxPoint((d+b)/2,e),new mxPoint((d-b)/2,e),new mxPoint((d-b)/2,c),new mxPoint(0,c)],this.isRounded,f,!0);a.end()};mxCellRenderer.prototype.defaultShapes.tee=Y;mxUtils.extend(O,mxActor);O.prototype.arrowWidth=.3;O.prototype.arrowSize=.2;O.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,
 "arrowWidth",this.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));c=(e-f)/2;var f=c+f,k=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(0,f)],this.isRounded,k,!0);a.end()};mxCellRenderer.prototype.defaultShapes.singleArrow=O;mxUtils.extend(K,mxActor);K.prototype.redrawPath=
 function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",O.prototype.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",O.prototype.arrowSize))));c=(e-f)/2;var f=c+f,k=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e/2),new mxPoint(b,0),new mxPoint(b,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),
-new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,k,!0);a.end()};mxCellRenderer.prototype.defaultShapes.doubleArrow=K;mxUtils.extend(M,mxActor);M.prototype.size=.1;M.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.dataStorage=M;mxUtils.extend(U,mxActor);U.prototype.redrawPath=
+new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,k,!0);a.end()};mxCellRenderer.prototype.defaultShapes.doubleArrow=K;mxUtils.extend(N,mxActor);N.prototype.size=.1;N.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.dataStorage=N;mxUtils.extend(U,mxActor);U.prototype.redrawPath=
 function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.or=U;mxUtils.extend(ca,mxActor);ca.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.quadTo(d/2,e/2,0,0);a.close();a.end()};mxCellRenderer.prototype.defaultShapes.xor=ca;mxUtils.extend(Z,mxActor);Z.prototype.size=20;Z.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d/2,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",
 this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.8*b),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,.8*b)],this.isRounded,c,!0);a.end()};mxCellRenderer.prototype.defaultShapes.loopLimit=Z;mxUtils.extend(R,mxActor);R.prototype.size=.375;R.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,
 mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-b),new mxPoint(d/2,e),new mxPoint(0,e-b)],this.isRounded,c,!0);a.end()};mxCellRenderer.prototype.defaultShapes.offPageConnector=R;mxUtils.extend(aa,mxEllipse);aa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/2,c+e);a.lineTo(b+d,c+e);a.end();a.stroke()};mxCellRenderer.prototype.defaultShapes.tapeData=
@@ -2521,7 +2521,7 @@ parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFA
 !1)];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},process:function(a){var b=[fa(a,["size"],function(a){var b=Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.state.style,"size",u.prototype.size))));return new mxPoint(a.x+a.width*b,a.y+a.height/4)},function(a,b){this.state.style.size=Math.max(0,Math.min(.5,(b.x-a.x)/a.width))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},cross:function(a){return[fa(a,["size"],function(a){var b=
 Math.min(a.width,a.height),b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"size",na.prototype.size)))*b/2;return new mxPoint(a.getCenterX()-b,a.getCenterY()-b)},function(a,b){var c=Math.min(a.width,a.height);this.state.style.size=Math.max(0,Math.min(1,Math.min(Math.max(0,a.getCenterY()-b.y)/c*2,Math.max(0,a.getCenterX()-b.x)/c*2)))})]},note:function(a){return[fa(a,["size"],function(a){var b=Math.max(0,Math.min(a.width,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",
 e.prototype.size)))));return new mxPoint(a.x+a.width-b,a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(a.width,a.x+a.width-b.x),Math.min(a.height,b.y-a.y))))})]},manualInput:function(a){var b=[fa(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",X.prototype.size)));return new mxPoint(a.x+a.width/4,a.y+3*b/4)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,4*(b.y-a.y)/3)))})];mxUtils.getValue(a.style,
-mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},dataStorage:function(a){return[fa(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",M.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-b.x)/a.width))})]},internalStorage:function(a){var b=[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",Q.prototype.dx))),
+mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},dataStorage:function(a){return[fa(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",N.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-b.x)/a.width))})]},internalStorage:function(a){var b=[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",Q.prototype.dx))),
 c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",Q.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ia(a));return b},corner:function(a){return[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",J.prototype.dx))),
 c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",J.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},tee:function(a){return[fa(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",Y.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",Y.prototype.dy)));
 return new mxPoint(a.x+(a.width+b)/2,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,b.x-a.x-a.width/2)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},singleArrow:ka(1),doubleArrow:ka(.5),folder:function(a){return[fa(a,["tabWidth","tabHeight"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"tabWidth",g.prototype.tabWidth))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"tabHeight",
@@ -2535,7 +2535,7 @@ k&&null!=g){a=function(a,b,c){a-=t.x;var d=b-t.y;b=(p*a-n*d)/(l*p-m*n);a=(m*a-l*
 function(a,b){if(b==mxEdgeStyle.IsometricConnector){var c=new mxElbowEdgeHandler(a);c.snapToTerminals=!1;return c}return Fa.apply(this,arguments)};b.prototype.constraints=[];c.prototype.constraints=[];mxRectangleShape.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),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxEllipse.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!0),new mxConnectionConstraint(new mxPoint(1,0),!0),new mxConnectionConstraint(new mxPoint(0,1),!0),new mxConnectionConstraint(new mxPoint(1,
 1),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,.5))];mxLabel.prototype.constraints=mxRectangleShape.prototype.constraints;mxImageShape.prototype.constraints=mxRectangleShape.prototype.constraints;mxSwimlane.prototype.constraints=mxRectangleShape.prototype.constraints;y.prototype.constraints=mxRectangleShape.prototype.constraints;e.prototype.constraints=
-mxRectangleShape.prototype.constraints;k.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;Q.prototype.constraints=mxRectangleShape.prototype.constraints;M.prototype.constraints=mxRectangleShape.prototype.constraints;aa.prototype.constraints=mxEllipse.prototype.constraints;da.prototype.constraints=mxEllipse.prototype.constraints;S.prototype.constraints=mxEllipse.prototype.constraints;
+mxRectangleShape.prototype.constraints;k.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;Q.prototype.constraints=mxRectangleShape.prototype.constraints;N.prototype.constraints=mxRectangleShape.prototype.constraints;aa.prototype.constraints=mxEllipse.prototype.constraints;da.prototype.constraints=mxEllipse.prototype.constraints;S.prototype.constraints=mxEllipse.prototype.constraints;
 la.prototype.constraints=mxEllipse.prototype.constraints;X.prototype.constraints=mxRectangleShape.prototype.constraints;ma.prototype.constraints=mxRectangleShape.prototype.constraints;oa.prototype.constraints=mxRectangleShape.prototype.constraints;Z.prototype.constraints=mxRectangleShape.prototype.constraints;R.prototype.constraints=mxRectangleShape.prototype.constraints;mxCylinder.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.15,.05),!1),new mxConnectionConstraint(new mxPoint(.5,
 0),!0),new mxConnectionConstraint(new mxPoint(.85,.05),!1),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.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)];B.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)];V.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),
@@ -2544,7 +2544,7 @@ new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new
 f.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)];l.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)];x.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(.1,.25),!1),new mxConnectionConstraint(new mxPoint(.2,.5),!1),new mxConnectionConstraint(new mxPoint(.1,.75),!1),new mxConnectionConstraint(new mxPoint(.9,.25),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.9,.75),!1)];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)];N.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,
+.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];M.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(.125,.25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(.125,.75),!1),new mxConnectionConstraint(new mxPoint(.875,
 .25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(.875,.75),!1),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)];n.prototype.constraints=mxRectangleShape.prototype.constraints;p.prototype.constraints=
@@ -2622,31 +2622,32 @@ IMAGE_PATH+"/delete.png";Editor.plusImage=mxClient.IS_SVG?"data:image/png;base64
 IMAGE_PATH+"/plus.png";Editor.spinImage=mxClient.IS_SVG?"data:image/gif;base64,R0lGODlhDAAMAPUxAEVriVp7lmCAmmGBm2OCnGmHn3OPpneSqYKbr4OcsIScsI2kto6kt46lt5KnuZmtvpquvpuvv56ywaCzwqK1xKu7yay9yq+/zLHAzbfF0bjG0bzJ1LzK1MDN18jT28nT3M3X3tHa4dTc49Xd5Njf5dng5t3k6d/l6uDm6uru8e7x8/Dz9fT29/b4+Pj5+fj5+vr6+v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkKADEAIf8LTkVUU0NBUEUyLjADAQAAACwAAAAADAAMAAAGR8CYcEgsOgYAIax4CCQuQldrCBEsiK8VS2hoFGOrlJDA+cZQwkLnqyoJFZKviSS0ICrE0ec0jDAwIiUeGyBFGhMPFBkhZo1BACH5BAkKAC4ALAAAAAAMAAwAhVB0kFR3k1V4k2CAmmWEnW6Lo3KOpXeSqH2XrIOcsISdsImhtIqhtJCmuJGnuZuwv52wwJ+ywZ+ywqm6yLHBzbLCzrXEz7fF0LnH0rrI0r7L1b/M1sXR2cfT28rV3czW3s/Z4Nfe5Nvi6ODm6uLn6+Ln7OLo7OXq7efs7+zw8u/y9PDy9PX3+Pr7+////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAZDQJdwSCxGDAIAoVFkFBwYSyIwGE4OkCJxIdG6WkJEx8sSKj7elfBB0a5SQg1EQ0SVVMPKhDM6iUIkRR4ZFxsgJl6JQQAh+QQJCgAxACwAAAAADAAMAIVGa4lcfZdjgpxkg51nhp5ui6N3kqh5lKqFnbGHn7KIoLOQp7iRp7mSqLmTqbqarr6br7+fssGitcOitcSuvsuuv8uwwMyzw861xNC5x9K6x9K/zNbDztjE0NnG0drJ1NzQ2eDS2+LT2+LV3ePZ4Oba4ebb4ufc4+jm6+7t8PLt8PPt8fPx8/Xx9PX09vf19/j3+Pn///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CYcEgsUhQFggFSjCQmnE1jcBhqGBXiIuAQSi7FGEIgfIzCFoCXFCZiPO0hKBMiwl7ET6eUYqlWLkUnISImKC1xbUEAIfkECQoAMgAsAAAAAAwADACFTnKPT3KPVHaTYoKcb4yjcY6leZSpf5mtgZuvh5+yiqG0i6K1jqW3kae5nrHBnrLBn7LCoLPCobTDqbrIqrvIs8LOtMPPtcPPtcTPuMbRucfSvcrUvsvVwMzWxdHaydTcytXdzNbezdff0drh2ODl2+Ln3eTp4Obq4ujs5Ont5uvu6O3w6u7w6u7x7/L09vj5+vr7+vv7////AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABkdAmXBILHIcicOCUqxELKKPxKAYgiYd4oMAEWo8RVmjIMScwhmBcJMKXwLCECmMGAhPI1QRwBiaSixCMDFhLSorLi8wYYxCQQAh+QQJCgAxACwAAAAADAAMAIVZepVggJphgZtnhp5vjKN2kah3kqmBmq+KobSLorWNpLaRp7mWq7ybr7+gs8KitcSktsWnuManucexwM2ywc63xtG6yNO9ytS+ytW/zNbDz9jH0tvL1d3N197S2+LU3OPU3ePV3eTX3+Xa4efb4ufd5Onl6u7r7vHs7/Lt8PLw8/Xy9Pby9fb09ff2+Pn3+Pn6+vr///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGSMCYcEgseiwSR+RS7GA4JFGF8RiWNiEiJTERgkjFGAQh/KTCGoJwpApnBkITKrwoCFWnFlEhaAxXLC9CBwAGRS4wQgELYY1CQQAh+QQJCgAzACwAAAAADAAMAIVMcI5SdZFhgZtti6JwjaR4k6mAma6Cm6+KobSLorWLo7WNo7aPpredsMCescGitMOitcSmuMaqu8ixwc2zws63xdC4xtG5x9K9ytXAzdfCztjF0NnF0drK1d3M1t7P2N/P2eDT2+LX3+Xe5Onh5+vi5+vj6Ozk6e3n7O/o7O/q7vHs7/Lt8PPu8fPx8/X3+Pn6+vv7+/v8/Pz///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRcCZcEgsmkIbTOZTLIlGqZNnchm2SCgiJ6IRqljFmQUiXIVnoITQde4chC9Y+LEQxmTFRkFSNFAqDAMIRQoCAAEEDmeLQQAh+QQJCgAwACwAAAAADAAMAIVXeZRefplff5lhgZtph59yjqV2kaeAmq6FnbGFnrGLorWNpLaQp7mRqLmYrb2essGgs8Klt8apusitvcquv8u2xNC7yNO8ydS8ytTAzdfBzdfM1t7N197Q2eDU3OPX3+XZ4ObZ4ebc4+jf5erg5erg5uvp7fDu8fPv8vTz9fb09vf19/j3+Pn4+fn5+vr6+/v///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGRUCYcEgspkwjEKhUVJ1QsBNp0xm2VixiSOMRvlxFGAcTJook5eEHIhQcwpWIkAFQECkNy9AQWFwyEAkPRQ4FAwQIE2llQQAh+QQJCgAvACwAAAAADAAMAIVNcY5SdZFigptph6BvjKN0kKd8lquAmq+EnbGGn7KHn7ONpLaOpbearr+csMCdscCescGhtMOnuMauvsuzws60w862xdC9ytW/y9a/zNbCztjG0drH0tvK1N3M1t7N19/U3ePb4uff5urj6Ozk6e3l6u7m6u7o7PDq7vDt8PPv8vTw8vTw8/X19vf6+vv///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGQ8CXcEgsvlytVUplJLJIpSEDUESFTELBwSgCCQEV42kjDFiMo4uQsDB2MkLHoEHUTD7DRAHC8VAiZ0QSCgYIDxhNiUEAOw==":
 IMAGE_PATH+"/spin.gif";Editor.tweetImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAARlJREFUeNpi/P//PwM1ABMDlQDVDGKAeo0biMXwKOMD4ilA/AiInwDxfCBWBeIgINYDmwE1yB2Ir0Alsbl6JchONPwNiC8CsTPIDJjXuIBYG4gPAnE8EDMjGaQCxGFYLOAEYlYg/o3sNSkgfo1k2ykgLgRiIyAOwOIaGE6CmwE1SA6IZ0BNR1f8GY9BXugG2UMN+YtHEzr+Aw0OFINYgHgdCYaA8HUgZkM3CASEoYb9ItKgapQkhGQQKC0dJdKQx1CLsRoEArpAvAuI3+Ix5B8Q+2AkaiyZVgGId+MwBBQhKVhzB9QgKyDuAOJ90BSLzZBzQOyCK5uxQNnXoGlJHogfIOU7UCI9C8SbgHgjEP/ElRkZB115BBBgAPbkvQ/azcC0AAAAAElFTkSuQmCC":
 IMAGE_PATH+"/tweet.png";Editor.facebookImage=mxClient.IS_SVG?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAARVBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADc6ur3AAAAFnRSTlMAYmRg2KVCC/oPq0uAcVQtHtvZuoYh/a7JUAAAAGJJREFUGNOlzkkOgCAMQNEvagvigBP3P6pRNoCJG/+myVu0RdsqxcQqQ/NFVkKQgqwDzoJ2WKajoB66atcAa0GjX0D8lJHwNGfknYJzY77LDtDZ+L74j0z26pZI2yYlMN9TL17xEd+fl1D+AAAAAElFTkSuQmCC":IMAGE_PATH+"/facebook.png";Editor.blankImage="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAACklEQVR4nGMAAQAABQABDQottAAAAABJRU5ErkJggg==";
-Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
-Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;var b=Graph.prototype.loadStylesheet;Graph.prototype.loadStylesheet=function(){b.apply(this,arguments);
-null!=a.defaultVertexStyle&&this.getStylesheet().putDefaultVertexStyle(a.defaultVertexStyle);null!=a.defaultEdgeStyle&&this.getStylesheet().putDefaultEdgeStyle(a.defaultEdgeStyle)}}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):
-null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,
-this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);
-mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};};var b=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var c=b.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&c.setAttribute("style",this.graph.currentStyle);
-null!=this.graph.backgroundImage&&c.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));c.setAttribute("math",this.graph.mathEnabled?"1":"0");c.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return c};Editor.prototype.isDataSvg=function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),
-null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),
-a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};
-null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var c=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=
-null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;c.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";
-Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX","input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});
-MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,
-b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;
-var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var e=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,b){e.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()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):
-this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),
-a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",
-stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=
-function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom=
-"2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=
-mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,
-"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin="0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+
-" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";
-e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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=);";
+Editor.defaultCustomLibraries=[];Editor.defaultCsvValue='##\n## Example CSV import. Use ## for comments and # for configuration. Paste CSV below.\n## The following names are reserved and should not be used (or ignored):\n## id, tooltip, placeholder(s), link and label (see below)\n##\n#\n## Node label with placeholders and HTML.\n## Default is \'%name_of_first_column%\'.\n#\n# label: %name%<br><i style="color:gray;">%position%</i><br><a href="mailto:%email%">Email</a>\n#\n## Node style (placeholders are replaced once).\n## Default is the current style for nodes.\n#\n# style: label;image=%image%;whiteSpace=wrap;html=1;rounded=1;fillColor=%fill%;strokeColor=%stroke%;\n#\n## Uses the given column name as the identity for cells (updates existing cells).\n## Default is no identity (empty value or -).\n#\n# identity: -\n#\n## Connections between rows ("from": source colum, "to": target column).\n## Label, style and invert are optional. Defaults are \'\', current style and false.\n## The target column may contain a comma-separated list of values.\n## Multiple connect entries are allowed.\n#\n# connect: {"from": "manager", "to": "name", "invert": true, "label": "manages", \\\n#          "style": "curved=1;endArrow=blockThin;endFill=1;fontSize=11;"}\n# connect: {"from": "refs", "to": "id", "style": "curved=1;fontSize=11;"}\n#\n## Node width. Possible value are px or auto. Default is auto.\n#\n# width: auto\n#\n## Node height. Possible value are px or auto. Default is auto.\n#\n# height: auto\n#\n## Padding for autosize. Default is 0.\n#\n# padding: -26\n#\n## Comma-separated list of ignored columns for metadata. (These can be\n## used for connections and styles but will not be added as metadata.)\n#\n# ignore: id,image,fill,stroke\n#\n## Column to be renamed to link attribute (used as link).\n#\n# link: url\n#\n## Spacing between nodes. Default is 40.\n#\n# nodespacing: 40\n#\n## Spacing between parallel edges. Default is 40.\n#\n# edgespacing: 40\n#\n## Name of layout. Possible values are auto, none, verticaltree, horizontaltree,\n## verticalflow, horizontalflow, organic, circle. Default is auto.\n#\n# layout: auto\n#\n## ---- CSV below this line. First line are column names. ----\nname,position,id,location,manager,email,fill,stroke,refs,url,image\nEvan Miller,CFO,emi,Office 1,,me@example.com,#dae8fc,#6c8ebf,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-9-2-128.png\nEdward Morrison,Brand Manager,emo,Office 2,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-10-3-128.png\nRon Donovan,System Admin,rdo,Office 3,Evan Miller,me@example.com,#d5e8d4,#82b366,"emo,tva",https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-2-128.png\nTessa Valet,HR Director,tva,Office 4,Evan Miller,me@example.com,#d5e8d4,#82b366,,https://www.draw.io,https://cdn3.iconfinder.com/data/icons/user-avatars-1/512/users-3-128.png\n';
+Editor.configure=function(a){if(null!=a){Menus.prototype.defaultFonts=a.defaultFonts||Menus.prototype.defaultFonts;ColorDialog.prototype.presetColors=a.presetColors||ColorDialog.prototype.presetColors;ColorDialog.prototype.defaultColors=a.defaultColors||ColorDialog.prototype.defaultColors;StyleFormatPanel.prototype.defaultColorSchemes=a.defaultColorSchemes||StyleFormatPanel.prototype.defaultColorSchemes;if(null!=a.css){var b=document.createElement("style");b.setAttribute("type","text/css");b.appendChild(document.createTextNode(a.css));
+var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c)}null!=a.defaultLibraries&&(Sidebar.prototype.defaultEntries=a.defaultLibraries);null!=a.defaultCustomLibraries&&(Editor.defaultCustomLibraries=a.defaultCustomLibraries);null!=a.defaultVertexStyle&&(Graph.prototype.defaultVertexStyle=a.defaultVertexStyle);null!=a.defaultEdgeStyle&&(Graph.prototype.defaultEdgeStyle=a.defaultEdgeStyle)}};Editor.prototype.editButtonLink=null!=urlParams.edit?decodeURIComponent(urlParams.edit):
+null;"1"==urlParams.dev&&(Editor.prototype.editBlankUrl+="&dev=1",Editor.prototype.editBlankFallbackUrl+="&dev=1");var a=Editor.prototype.setGraphXml;Editor.prototype.setGraphXml=function(b){b=null!=b&&"mxlibrary"!=b.nodeName?this.extractGraphModel(b):null;if(null!=b){var c=b.getElementsByTagName("parsererror");if(null!=c&&0<c.length){var c=c[0],d=c.getElementsByTagName("div");null!=d&&0<d.length&&(c=d[0]);throw{message:mxUtils.getTextContent(c)};}if("mxGraphModel"==b.nodeName){c=b.getAttribute("style")||
+"default-style2";if("1"==urlParams.embed||null!=c&&""!=c)c!=this.graph.currentStyle&&(d=null!=this.graph.themes?this.graph.themes[c]:mxUtils.load(STYLE_PATH+"/"+c+".xml").getDocumentElement(),null!=d&&(e=new mxCodec(d.ownerDocument),e.decode(d,this.graph.getStylesheet())));else if(d=null!=this.graph.themes?this.graph.themes["default-old"]:mxUtils.load(STYLE_PATH+"/default-old.xml").getDocumentElement(),null!=d){var e=new mxCodec(d.ownerDocument);e.decode(d,this.graph.getStylesheet())}this.graph.currentStyle=
+c;this.graph.mathEnabled="1"==urlParams.math||"1"==b.getAttribute("math");c=b.getAttribute("backgroundImage");null!=c?(c=JSON.parse(c),this.graph.setBackgroundImage(new mxImage(c.src,c.width,c.height))):this.graph.setBackgroundImage(null);mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;this.graph.setShadowVisible("1"==b.getAttribute("shadow"),!1)}a.apply(this,arguments)}else throw{message:mxResources.get("notADiagramFile")||"Invalid data",toString:function(){return this.message}};
+};var b=Editor.prototype.getGraphXml;Editor.prototype.getGraphXml=function(a){a=null!=a?a:!0;var c=b.apply(this,arguments);null!=this.graph.currentStyle&&"default-style2"!=this.graph.currentStyle&&c.setAttribute("style",this.graph.currentStyle);null!=this.graph.backgroundImage&&c.setAttribute("backgroundImage",JSON.stringify(this.graph.backgroundImage));c.setAttribute("math",this.graph.mathEnabled?"1":"0");c.setAttribute("shadow",this.graph.shadowVisible?"1":"0");return c};Editor.prototype.isDataSvg=
+function(a){try{var b=mxUtils.parseXml(a).documentElement.getAttribute("content");if(null!=b&&(null!=b&&"<"!=b.charAt(0)&&"%"!=b.charAt(0)&&(b=unescape(window.atob?atob(b):Base64.decode(cont,b))),null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b)),null!=b&&0<b.length)){var c=mxUtils.parseXml(b).documentElement;return"mxfile"==c.nodeName||"mxGraphModel"==c.nodeName}}catch(z){}return!1};Editor.prototype.extractGraphModel=function(a,b){if(null!=a&&"undefined"!==typeof pako){var c=a.ownerDocument.getElementsByTagName("div"),
+d=[];if(null!=c&&0<c.length)for(var e=0;e<c.length;e++)if("mxgraph"==c[e].getAttribute("class")){d.push(c[e]);break}0<d.length&&(c=d[0].getAttribute("data-mxgraph"),null!=c?(d=JSON.parse(c),null!=d&&null!=d.xml&&(d=mxUtils.parseXml(d.xml),a=d.documentElement)):(d=d[0].getElementsByTagName("div"),0<d.length&&(c=mxUtils.getTextContent(d[0]),c=this.graph.decompress(c),0<c.length&&(d=mxUtils.parseXml(c),a=d.documentElement))))}if(null!=a&&"svg"==a.nodeName)if(c=a.getAttribute("content"),null!=c&&"<"!=
+c.charAt(0)&&"%"!=c.charAt(0)&&(c=unescape(window.atob?atob(c):Base64.decode(cont,c))),null!=c&&"%"==c.charAt(0)&&(c=decodeURIComponent(c)),null!=c&&0<c.length)a=mxUtils.parseXml(c).documentElement;else throw{message:mxResources.get("notADiagramFile")};null==a||b||(d=null,"diagram"==a.nodeName?d=a:"mxfile"==a.nodeName&&(c=a.getElementsByTagName("diagram"),0<c.length&&(d=c[Math.max(0,Math.min(c.length-1,urlParams.page||0))])),null!=d&&(c=this.graph.decompress(mxUtils.getTextContent(d)),null!=c&&0<
+c.length&&(a=mxUtils.parseXml(c).documentElement)));null==a||"mxGraphModel"==a.nodeName||b&&"mxfile"==a.nodeName||(a=null);return a};var c=Editor.prototype.resetGraph;Editor.prototype.resetGraph=function(){this.graph.mathEnabled="1"==urlParams.math;this.graph.view.x0=null;this.graph.view.y0=null;mxClient.NO_FO=this.graph.mathEnabled?!0:this.originalNoForeignObject;c.apply(this,arguments)};Editor.prototype.originalNoForeignObject=mxClient.NO_FO;var d=Editor.prototype.updateGraphComponents;Editor.prototype.updateGraphComponents=
+function(){d.apply(this,arguments);mxClient.NO_FO=this.graph.mathEnabled&&null!=Editor.MathJaxRender?!0:this.originalNoForeignObject};Editor.initMath=function(a,b){a=null!=a?a:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-MML-AM_HTMLorMML";Editor.mathJaxQueue=[];Editor.doMathJaxRender=function(a){MathJax.Hub.Queue(["Typeset",MathJax.Hub,a])};window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config(b||{jax:["input/TeX",
+"input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]},tex2jax:{ignoreClass:"mxCellEditor"},asciimath2jax:{ignoreClass:"mxCellEditor"}});MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<Editor.mathJaxQueue.length;a++)Editor.doMathJaxRender(Editor.mathJaxQueue[a])})}};Editor.MathJaxRender=function(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?
+Editor.doMathJaxRender(a):Editor.mathJaxQueue.push(a)};Editor.MathJaxClear=function(){Editor.mathJaxQueue=[]};var c=Editor.prototype.init;Editor.prototype.init=function(){c.apply(this,arguments);this.graph.addListener(mxEvent.SIZE,mxUtils.bind(this,function(a,b){this.graph.mathEnabled&&Editor.MathJaxRender(this.graph.container)}))};var d=document.getElementsByTagName("script");if(null!=d&&0<d.length){var e=document.createElement("script");e.type="text/javascript";e.src=a;d[0].parentNode.appendChild(e)}};
+Editor.prototype.csvToArray=function(a){if(!/^\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*(?:,\s*(?:'[^'\\]*(?:\\[\S\s][^'\\]*)*'|"[^"\\]*(?:\\[\S\s][^"\\]*)*"|[^,'"\s\\]*(?:\s+[^,'"\s\\]+)*)\s*)*$/.test(a))return null;var b=[];a.replace(/(?!\s*$)\s*(?:'([^'\\]*(?:\\[\S\s][^'\\]*)*)'|"([^"\\]*(?:\\[\S\s][^"\\]*)*)"|([^,'"\s\\]*(?:\s+[^,'"\s\\]+)*))\s*(?:,|$)/g,function(a,c,d,e){void 0!==c?b.push(c.replace(/\\'/g,"'")):void 0!==d?b.push(d.replace(/\\"/g,
+'"')):void 0!==e&&b.push(e);return""});/,\s*$/.test(a)&&b.push("");return b};if(window.ColorDialog){var e=ColorDialog.addRecentColor;ColorDialog.addRecentColor=function(a,b){e.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()}}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 k=Format.prototype.refresh;Format.prototype.refresh=function(){null!=this.editorUi.getCurrentFile()||"1"==urlParams.embed?k.apply(this,arguments):this.clear()};var l=DiagramFormatPanel.prototype.addOptions;DiagramFormatPanel.prototype.addOptions=function(a){a=l.apply(this,arguments);var b=this.editorUi;if(b.editor.graph.isEnabled()){var c=b.getCurrentFile();null!=c&&c.isAutosaveOptional()&&
+(c=this.createOption(mxResources.get("autosave"),function(){return b.editor.autosave},function(a){b.editor.setAutosave(a)},{install:function(a){this.listener=function(){a(b.editor.autosave)};b.editor.addListener("autosaveChanged",this.listener)},destroy:function(){b.editor.removeListener(this.listener)}}),a.appendChild(c))}return a};StyleFormatPanel.prototype.defaultColorSchemes=[[null,{fill:"#f5f5f5",stroke:"#666666"},{fill:"#dae8fc",stroke:"#6c8ebf"},{fill:"#d5e8d4",stroke:"#82b366"},{fill:"#ffe6cc",
+stroke:"#d79b00"},{fill:"#fff2cc",stroke:"#d6b656"},{fill:"#f8cecc",stroke:"#b85450"},{fill:"#e1d5e7",stroke:"#9673a6"}],[null,{fill:"#f5f5f5",stroke:"#666666",gradient:"#b3b3b3"},{fill:"#dae8fc",stroke:"#6c8ebf",gradient:"#7ea6e0"},{fill:"#d5e8d4",stroke:"#82b366",gradient:"#97d077"},{fill:"#ffcd28",stroke:"#d79b00",gradient:"#ffa500"},{fill:"#fff2cc",stroke:"#d6b656",gradient:"#ffd966"},{fill:"#f8cecc",stroke:"#b85450",gradient:"#ea6b66"},{fill:"#e6d0de",stroke:"#996185",gradient:"#d5739d"}],[null,
+{fill:"#eeeeee",stroke:"#36393d"},{fill:"#f9f7ed",stroke:"#36393d"},{fill:"#ffcc99",stroke:"#36393d"},{fill:"#cce5ff",stroke:"#36393d"},{fill:"#ffff88",stroke:"#36393d"},{fill:"#cdeb8b",stroke:"#36393d"},{fill:"#ffcccc",stroke:"#36393d"}]];var m=StyleFormatPanel.prototype.init;StyleFormatPanel.prototype.init=function(){"image"!=this.format.createSelectionState().style.shape&&this.container.appendChild(this.addStyles(this.createPanel()));m.apply(this,arguments)};var n=StyleFormatPanel.prototype.addStyleOps;
+StyleFormatPanel.prototype.addStyleOps=function(a){var b=mxUtils.button(mxResources.get("copyStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("copyStyle").funct()}));b.setAttribute("title",mxResources.get("copyStyle")+" ("+this.editorUi.actions.get("copyStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";b.style.marginRight="2px";a.appendChild(b);b=mxUtils.button(mxResources.get("pasteStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("pasteStyle").funct()}));
+b.setAttribute("title",mxResources.get("pasteStyle")+" ("+this.editorUi.actions.get("pasteStyle").shortcut+")");b.style.marginBottom="2px";b.style.width="100px";a.appendChild(b);mxUtils.br(a);return n.apply(this,arguments)};StyleFormatPanel.prototype.addStyles=function(a){function b(a){function b(a){var b=mxUtils.button("",function(b){d.getModel().beginUpdate();try{var c=d.getSelectionCells();for(b=0;b<c.length;b++){for(var e=d.getModel().getStyle(c[b]),k=0;k<f.length;k++)e=mxUtils.removeStylename(e,
+f[k]);null!=a?(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,a.fill),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,a.stroke),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,a.gradient)):(e=mxUtils.setStyle(e,mxConstants.STYLE_FILLCOLOR,"#ffffff"),e=mxUtils.setStyle(e,mxConstants.STYLE_STROKECOLOR,"#000000"),e=mxUtils.setStyle(e,mxConstants.STYLE_GRADIENTCOLOR,null));d.getModel().setStyle(c[b],e)}}finally{d.getModel().endUpdate()}});b.style.width="36px";b.style.height="30px";b.style.margin=
+"0px 6px 6px 0px";null!=a?(null!=a.gradient?mxClient.IS_IE&&(mxClient.IS_QUIRKS||10>document.documentMode)?b.style.filter="progid:DXImageTransform.Microsoft.Gradient(StartColorStr='"+a.fill+"', EndColorStr='"+a.gradient+"', GradientType=0)":b.style.backgroundImage="linear-gradient("+a.fill+" 0px,"+a.gradient+" 100%)":b.style.backgroundColor=a.fill,b.style.border="1px solid "+a.stroke):(b.style.backgroundColor="#ffffff",b.style.border="1px solid #000000");e.appendChild(b)}e.innerHTML="";for(var c=
+0;c<a.length;c++)0<c&&0==mxUtils.mod(c,4)&&mxUtils.br(e),b(a[c])}function c(a){mxEvent.addListener(a,"mouseenter",function(){a.style.opacity="1"});mxEvent.addListener(a,"mouseleave",function(){a.style.opacity="0.5"})}var d=this.editorUi.editor.graph,e=document.createElement("div");e.style.whiteSpace="normal";e.style.paddingLeft="24px";e.style.paddingRight="20px";a.style.paddingLeft="16px";a.style.paddingBottom="6px";a.style.position="relative";a.appendChild(e);var f="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 k=document.createElement("div");k.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(k,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme-1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));var g=document.createElement("div");g.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(k),a.appendChild(g));mxEvent.addListener(g,"click",mxUtils.bind(this,function(){this.editorUi.currentScheme=mxUtils.mod(this.editorUi.currentScheme+1,this.defaultColorSchemes.length);b(this.defaultColorSchemes[this.editorUi.currentScheme])}));c(k);c(g);b(this.defaultColorSchemes[this.editorUi.currentScheme]);return a};StyleFormatPanel.prototype.addEditOps=function(a){var b=this.format.getSelectionState(),c=null;1==this.editorUi.editor.graph.getSelectionCount()&&
 (c=mxUtils.button(mxResources.get("editStyle"),mxUtils.bind(this,function(a){this.editorUi.actions.get("editStyle").funct()})),c.setAttribute("title",mxResources.get("editStyle")+" ("+this.editorUi.actions.get("editStyle").shortcut+")"),c.style.width="202px",c.style.marginBottom="2px",a.appendChild(c));var d=this.editorUi.editor.graph,e=d.view.getState(d.getSelectionCell());1==d.getSelectionCount()&&null!=e&&null!=e.shape&&null!=e.shape.stencil?(b=mxUtils.button(mxResources.get("editShape"),mxUtils.bind(this,
@@ -2667,7 +2668,7 @@ mxStencilRegistry.libraries.er=[SHAPES_PATH+"/er/mxER.js"];mxStencilRegistry.lib
 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.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 b=null;null!=a&&0<a.length&&("ER"==a.substring(0,2)?b="mxgraph.er":"sysML"==a.substring(0,5)&&(b="mxgraph.sysml"));return b};
 var t=mxMarker.createMarker;mxMarker.createMarker=function(a,b,c,d,e,f,k,g,l,m){if(null!=c&&null==mxMarker.markers[c]){var n=this.getPackageForType(c);null!=n&&mxStencilRegistry.getStencil(n)}return t.apply(this,arguments)};PrintDialog.prototype.create=function(a,b){function c(){t.value=Math.max(1,Math.min(g,Math.max(parseInt(t.value),parseInt(q.value))));q.value=Math.max(1,Math.min(g,Math.min(parseInt(t.value),parseInt(q.value))))}function d(b){function c(a,b,c){var e=a.getGraphBounds(),f=0,k=0,
-g=ca.get(),l=1/a.pageScale,m=P.checked;if(m)var l=parseInt(M.value),n=parseInt(U.value),l=Math.min(g.height*n/(e.height/a.view.scale),g.width*l/(e.width/a.view.scale));else l=parseInt(V.value)/(100*a.pageScale),isNaN(l)&&(d=1/a.pageScale,V.value="100 %");g=mxRectangle.fromRectangle(g);g.width=Math.ceil(g.width*d);g.height=Math.ceil(g.height*d);l*=d;!m&&a.pageVisible?(e=a.getPageLayout(),f-=e.x*g.width,k-=e.y*g.height):m=!0;if(null==b){b=PrintDialog.createPrintPreview(a,l,g,0,f,k,m);b.pageSelector=
+g=ca.get(),l=1/a.pageScale,m=P.checked;if(m)var l=parseInt(N.value),n=parseInt(U.value),l=Math.min(g.height*n/(e.height/a.view.scale),g.width*l/(e.width/a.view.scale));else l=parseInt(V.value)/(100*a.pageScale),isNaN(l)&&(d=1/a.pageScale,V.value="100 %");g=mxRectangle.fromRectangle(g);g.width=Math.ceil(g.width*d);g.height=Math.ceil(g.height*d);l*=d;!m&&a.pageVisible?(e=a.getPageLayout(),f-=e.x*g.width,k-=e.y*g.height):m=!0;if(null==b){b=PrintDialog.createPrintPreview(a,l,g,0,f,k,m);b.pageSelector=
 !1;b.mathEnabled=!1;if("undefined"!==typeof MathJax){var p=b.renderPage;b.renderPage=function(a,b,c,d,e,f){var k=p.apply(this,arguments);this.graph.mathEnabled?this.mathEnabled=!0:k.className="geDisableMathJax";return k}}b.open(null,null,c,!0)}else{g=a.background;if(null==g||""==g||g==mxConstants.NONE)g="#ffffff";b.backgroundColor=g;b.autoOrigin=m;b.appendGraph(a,l,f,k,c,!0)}return b}var d=parseInt(Z.value)/100;isNaN(d)&&(d=1,Z.value="100 %");var d=.75*d,f=q.value,k=t.value,g=!n.checked,m=null;g&&
 (g=f==l&&k==l);if(!g&&null!=a.pages&&a.pages.length){var p=0,g=a.pages.length-1;n.checked||(p=parseInt(f)-1,g=parseInt(k)-1);for(var r=p;r<=g;r++){var u=a.pages[r],f=u==a.currentPage?e:null;if(null==f){var f=a.createTemporaryGraph(e.getStylesheet()),k=!0,p=!1,x=null,v=null;null==u.viewState&&null==u.mapping&&null==u.root&&a.updatePageRoot(u);null!=u.viewState?(k=u.viewState.pageVisible,p=u.viewState.mathEnabled,x=u.viewState.background,v=u.viewState.backgroundImage):null!=u.mapping&&null!=u.mapping.diagramMap&&
 (p="0"!=u.mapping.diagramMap.get("mathEnabled"),x=u.mapping.diagramMap.get("background"),v=u.mapping.diagramMap.get("backgroundImage"),v=null!=v&&0<v.length?JSON.parse(v):null);f.background=x;f.backgroundImage=null!=v?new mxImage(v.src,v.width,v.height):null;f.pageVisible=k;f.mathEnabled=p;var y=f.getGlobalVariable;f.getGlobalVariable=function(a){return"page"==a?u.getName():"pagenumber"==a?r+1:y.apply(this,arguments)};document.body.appendChild(f.container);a.updatePageRoot(u);f.model.setRoot(u.root)}m=
@@ -2678,22 +2679,22 @@ n.setAttribute("name","pages-printdialog");m.appendChild(n);k=document.createEle
 "number");q.setAttribute("min","1");q.style.width="50px";m.appendChild(q);k=document.createElement("span");mxUtils.write(k,mxResources.get("to"));m.appendChild(k);var t=q.cloneNode(!0);m.appendChild(t);mxEvent.addListener(q,"focus",function(){p.checked=!0});mxEvent.addListener(t,"focus",function(){p.checked=!0});mxEvent.addListener(q,"change",c);mxEvent.addListener(t,"change",c);if(null!=a.pages&&(g=a.pages.length,null!=a.currentPage))for(k=0;k<a.pages.length;k++)if(a.currentPage==a.pages[k]){l=k+
 1;q.value=l;t.value=l;break}q.setAttribute("max",g);t.setAttribute("max",g);1<g&&f.appendChild(m);var r=document.createElement("div");r.style.marginBottom="10px";var u=document.createElement("input");u.style.marginRight="8px";u.setAttribute("value","adjust");u.setAttribute("type","radio");u.setAttribute("name","printZoom");r.appendChild(u);k=document.createElement("span");mxUtils.write(k,mxResources.get("adjustTo"));r.appendChild(k);var V=document.createElement("input");V.style.cssText="margin:0 8px 0 8px;";
 V.setAttribute("value","100 %");V.style.width="50px";r.appendChild(V);mxEvent.addListener(V,"focus",function(){u.checked=!0});f.appendChild(r);var m=m.cloneNode(!1),P=u.cloneNode(!0);P.setAttribute("value","fit");u.setAttribute("checked","checked");k=document.createElement("div");k.style.cssText="display:inline-block;height:100%;vertical-align:top;padding-top:2px;";k.appendChild(P);m.appendChild(k);r=document.createElement("table");r.style.display="inline-block";var ba=document.createElement("tbody"),
-T=document.createElement("tr"),D=T.cloneNode(!0),X=document.createElement("td"),Q=X.cloneNode(!0),J=X.cloneNode(!0),Y=X.cloneNode(!0),O=X.cloneNode(!0),K=X.cloneNode(!0);X.style.textAlign="right";Y.style.textAlign="right";mxUtils.write(X,mxResources.get("fitTo"));var M=document.createElement("input");M.style.cssText="margin:0 8px 0 8px;";M.setAttribute("value","1");M.setAttribute("min","1");M.setAttribute("type","number");M.style.width="40px";Q.appendChild(M);k=document.createElement("span");mxUtils.write(k,
-mxResources.get("fitToSheetsAcross"));J.appendChild(k);mxUtils.write(Y,mxResources.get("fitToBy"));var U=M.cloneNode(!0);O.appendChild(U);mxEvent.addListener(M,"focus",function(){P.checked=!0});mxEvent.addListener(U,"focus",function(){P.checked=!0});k=document.createElement("span");mxUtils.write(k,mxResources.get("fitToSheetsDown"));K.appendChild(k);T.appendChild(X);T.appendChild(Q);T.appendChild(J);D.appendChild(Y);D.appendChild(O);D.appendChild(K);ba.appendChild(T);ba.appendChild(D);r.appendChild(ba);
+T=document.createElement("tr"),D=T.cloneNode(!0),X=document.createElement("td"),Q=X.cloneNode(!0),J=X.cloneNode(!0),Y=X.cloneNode(!0),O=X.cloneNode(!0),K=X.cloneNode(!0);X.style.textAlign="right";Y.style.textAlign="right";mxUtils.write(X,mxResources.get("fitTo"));var N=document.createElement("input");N.style.cssText="margin:0 8px 0 8px;";N.setAttribute("value","1");N.setAttribute("min","1");N.setAttribute("type","number");N.style.width="40px";Q.appendChild(N);k=document.createElement("span");mxUtils.write(k,
+mxResources.get("fitToSheetsAcross"));J.appendChild(k);mxUtils.write(Y,mxResources.get("fitToBy"));var U=N.cloneNode(!0);O.appendChild(U);mxEvent.addListener(N,"focus",function(){P.checked=!0});mxEvent.addListener(U,"focus",function(){P.checked=!0});k=document.createElement("span");mxUtils.write(k,mxResources.get("fitToSheetsDown"));K.appendChild(k);T.appendChild(X);T.appendChild(Q);T.appendChild(J);D.appendChild(Y);D.appendChild(O);D.appendChild(K);ba.appendChild(T);ba.appendChild(D);r.appendChild(ba);
 m.appendChild(r);f.appendChild(m);m=document.createElement("div");k=document.createElement("div");k.style.fontWeight="bold";k.style.marginBottom="12px";mxUtils.write(k,mxResources.get("paperSize"));m.appendChild(k);k=document.createElement("div");k.style.marginBottom="12px";var ca=PageSetupDialog.addPageFormatPanel(k,"printdialog",a.editor.graph.pageFormat||mxConstants.PAGE_FORMAT_A4_PORTRAIT);m.appendChild(k);k=document.createElement("span");mxUtils.write(k,mxResources.get("pageScale"));m.appendChild(k);
 var Z=document.createElement("input");Z.style.cssText="margin:0 8px 0 8px;";Z.setAttribute("value","100 %");Z.style.width="60px";m.appendChild(Z);f.appendChild(m);k=document.createElement("div");k.style.cssText="text-align:right;margin:62px 0 0 0;";m=mxUtils.button(mxResources.get("cancel"),function(){a.hideDialog()});m.className="geBtn";a.editor.cancelFirst&&k.appendChild(m);a.isOffline()||(r=mxUtils.button(mxResources.get("help"),function(){window.open("https://desk.draw.io/support/solutions/articles/16000048947")}),
 r.className="geBtn",k.appendChild(r));PrintDialog.previewEnabled&&(r=mxUtils.button(mxResources.get("preview"),function(){a.hideDialog();d(!1)}),r.className="geBtn",k.appendChild(r));r=mxUtils.button(mxResources.get(PrintDialog.previewEnabled?"print":"ok"),function(){a.hideDialog();d(!0)});r.className="geBtn gePrimaryBtn";k.appendChild(r);a.editor.cancelFirst||k.appendChild(m);f.appendChild(k);this.container=f}})();
 (function(){EditorUi.VERSION="@DRAWIO-VERSION@";EditorUi.compactUi="atlas"!=uiTheme;EditorUi.enableLogging=/.*\.draw\.io$/.test(window.location.hostname);EditorUi.isElectronApp=null!=window&&null!=window.process&&null!=window.process.versions&&null!=window.process.versions.electron;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.sidebarFooterHeight=
 36;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.resampleThreshold=
-1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();EditorUi.prototype.getLocalData=
-function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=
-function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,length:c,width:Math.round(c/
-3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=2E9,k.style.left=
-Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+"px")),this.pause=
-mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<8)+(a.charCodeAt(1)<<
-16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};var a=
-EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
+1E5;EditorUi.prototype.maxImageBytes=1E6;EditorUi.prototype.maxBackgroundBytes=25E5;EditorUi.prototype.currentFile=null;EditorUi.prototype.printPdfExport=!1;EditorUi.prototype.pdfPageExport=!0;EditorUi.prototype.formatEnabled="0"!=urlParams.format;(function(){EditorUi.prototype.useCanvasForExport=!1;EditorUi.prototype.jpgSupported=!1;try{var a=document.createElement("canvas"),b=new Image;b.onload=function(){try{a.getContext("2d").drawImage(b,0,0);var c=a.toDataURL("image/png");EditorUi.prototype.useCanvasForExport=
+null!=c&&6<c.length}catch(p){}};b.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(n){}try{a=document.createElement("canvas");a.width=a.height=1;var c=a.toDataURL("image/jpeg");EditorUi.prototype.jpgSupported=null!==c.match("image/jpeg")}catch(n){}})();
+EditorUi.prototype.getLocalData=function(a,b){b(localStorage.getItem(a))};EditorUi.prototype.setLocalData=function(a,b,c){localStorage.setItem(a,b);c()};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.movePickersToTop=function(){for(var a=document.getElementsByTagName("div"),b=0;b<a.length;b++)"picker modal-dialog picker-dialog"==a[b].className&&(a[b].style.zIndex=mxPopupMenu.prototype.zIndex+1)};EditorUi.prototype.isOfflineApp=function(){return"1"==urlParams.offline};EditorUi.prototype.isOffline=function(){return mxClient.IS_FF&&this.isOfflineApp()||!navigator.onLine||"1"==urlParams.stealth};EditorUi.prototype.createSpinner=function(a,b,c){c=null!=c?c:24;var d=new Spinner({lines:12,
+length:c,width:Math.round(c/3),radius:Math.round(c/2),rotate:0,color:"#000",speed:1.5,trail:60,shadow:!1,hwaccel:!1,zIndex:2E9}),e=d.spin;d.spin=function(c,f){var k=!1;this.active||(e.call(this,c),this.active=!0,null!=f&&(k=document.createElement("div"),k.style.position="absolute",k.style.whiteSpace="nowrap",k.style.background="#4B4243",k.style.color="white",k.style.fontFamily="Helvetica, Arial",k.style.fontSize="9pt",k.style.padding="6px",k.style.paddingLeft="10px",k.style.paddingRight="10px",k.style.zIndex=
+2E9,k.style.left=Math.max(0,a)+"px",k.style.top=Math.max(0,b+70)+"px",mxUtils.setPrefixedStyle(k.style,"borderRadius","6px"),mxUtils.setPrefixedStyle(k.style,"boxShadow","2px 2px 3px 0px #ddd"),mxUtils.setPrefixedStyle(k.style,"transform","translate(-50%,-50%)"),k.innerHTML=f+"...",c.appendChild(k),d.status=k,mxClient.IS_VML&&(null==document.documentMode||8>=document.documentMode)&&(k.style.left=Math.round(Math.max(0,a-k.offsetWidth/2))+"px",k.style.top=Math.round(Math.max(0,b+70-k.offsetHeight/2))+
+"px")),this.pause=mxUtils.bind(this,function(){var a=function(){};this.active&&(a=mxUtils.bind(this,function(){this.spin(c,f)}));this.stop();return a}),k=!0);return k};var f=d.stop;d.stop=function(){f.call(this);this.active=!1;null!=d.status&&(d.status.parentNode.removeChild(d.status),d.status=null)};d.pause=function(){return function(){}};return d};EditorUi.parsePng=function(a,b,c){function d(a,b){var c=f;f+=b;return a.substring(c,f)}function e(a){a=d(a,4);return a.charCodeAt(3)+(a.charCodeAt(2)<<
+8)+(a.charCodeAt(1)<<16)+(a.charCodeAt(0)<<24)}var f=0;if(d(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=c&&c();else if(d(a,4),"IHDR"!=d(a,4))null!=c&&c();else{d(a,17);do{c=e(a);var k=d(a,4);if(null!=b&&b(f-8,k,c))break;value=d(a,c);d(a,4);if("IEND"==k)break}while(c)}};EditorUi.prototype.isCompatibleString=function(a){try{var b=mxUtils.parseXml(a),c=this.editor.extractGraphModel(b.documentElement,!0);return null!=c&&0==c.getElementsByTagName("parsererror").length}catch(n){}return!1};
+var a=EditorUi.prototype.extractGraphModelFromHtml;EditorUi.prototype.extractGraphModelFromHtml=function(b){var c=a.apply(this,arguments);if(null==c)try{var d=b.indexOf("&lt;mxfile ");if(0<=d){var e=b.lastIndexOf("&lt;/mxfile&gt;");e>d&&(c=b.substring(d,e+15).replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/\\&quot;/g,'"').replace(/\n/g,""))}else var f=mxUtils.parseXml(b),k=this.editor.extractGraphModel(f.documentElement,null!=this.pages),c=null!=k?mxUtils.getXml(k):""}catch(t){}return c};EditorUi.prototype.validateFileData=
 function(a){if(null!=a&&0<a.length){var b=a.indexOf('<meta charset="utf-8">');0<=b&&(a=a.slice(0,b)+'<meta charset="utf-8"/>'+a.slice(b+23-1,a.length))}return a};EditorUi.prototype.replaceFileData=function(a){a=this.validateFileData(a);a=null!=a&&0<a.length?mxUtils.parseXml(a).documentElement:null;var b=null!=a?this.editor.extractGraphModel(a,!0):null;null!=b&&(a=b);if(null!=a){b=this.editor.graph;b.model.beginUpdate();try{var c=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 f=this.updatePageRoot(new DiagramPage(d[e]));null==f.getName()&&f.setName(mxResources.get("pageWithNumber",[e+1]));b.model.execute(new ChangePage(this,f,0==e?f: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])),b.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!=c)for(e=0;e<c.length;e++)b.model.execute(new ChangePage(this,c[e],null))}finally{b.model.endUpdate()}}};EditorUi.prototype.createFileData=function(a,b,c,d,e,f,g,r,u,x){b=null!=b?b:this.editor.graph;e=null!=e?e:!1;u=null!=u?u:!0;var k,l=null;null==c||
@@ -2802,17 +2803,17 @@ EditorUi.prototype.createEmbedSvg=function(a,b,c,d,e,f,g){var k=this.editor.grap
 " "+mxResources.get("months");b=Math.floor(a/86400);if(1<b)return b+" "+mxResources.get("days");b=Math.floor(a/3600);if(1<b)return b+" "+mxResources.get("hours");b=Math.floor(a/60);return 1<b?b+" "+mxResources.get("minutes"):1==b?b+" "+mxResources.get("minute"):null};EditorUi.prototype.convertMath=function(a,b,c,d){d()};EditorUi.prototype.getEmbeddedSvg=function(a,b,c,d,e,f,g){g=b.background;g==mxConstants.NONE&&(g=null);b=b.getSvg(g,null,null,null,null,f);null!=a&&b.setAttribute("content",a);null!=
 c&&b.setAttribute("resource",c);if(null!=e)this.convertImages(b,mxUtils.bind(this,function(a){e((d?"":'<?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(d?"":'<?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(b)};EditorUi.prototype.exportImage=function(a,b,c,d,e,f,g,
 r,u){u=null!=u?u:"png";if(this.spinner.spin(document.body,mxResources.get("exporting"))){var k=this.editor.graph.isSelectionEmpty();c=null!=c?c:k;null==this.thumbImageCache&&(this.thumbImageCache={});try{this.exportToCanvas(mxUtils.bind(this,function(a){this.spinner.stop();try{this.saveCanvas(a,e?this.getFileData(!0,null,null,null,c,r):null,u)}catch(y){"Invalid image"==y.message?this.downloadFile(u):this.handleError(y)}}),null,this.thumbImageCache,null,mxUtils.bind(this,function(a){this.spinner.stop();
-this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,r,u,x,z,y,A,v){f=null!=f?f:!0;y=null!=y?y:this.editor.graph;A=null!=A?A:0;var k=u?null:y.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==u&&(k="#ffffff");this.convertImages(y.getSvg(k,null,null,v,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){var e=document.createElement("canvas"),
-g=parseInt(c.getAttribute("width")),l=parseInt(c.getAttribute("height"));r=null!=r?r:1;null!=b&&(r=f?Math.min(1,Math.min(3*b/(4*l),b/g)):b/g);g=Math.ceil(r*g)+2*A;l=Math.ceil(r*l)+2*A;e.setAttribute("width",g);e.setAttribute("height",l);var m=e.getContext("2d");null!=k&&(m.beginPath(),m.rect(0,0,g,l),m.fillStyle=k,m.fill());m.scale(r,r);m.drawImage(d,A/r,A/r);a(e)});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(y,c,!0,mxUtils.bind(this,function(){d.src=
-this.createSvgDataUri(mxUtils.getXml(c))}))}catch(C){null!=e&&e(C)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=function(a,b,
-c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,g){for(var k=a.getElementsByTagName(c),l=0;l<k.length;l++)mxUtils.bind(this,function(c){var k=d.convert(c.getAttribute(g));if(null!=k&&"data:"!=k.substring(0,5)){var l=f[k];null==l?(e++,this.convertImageToDataUri(k,function(d){null!=d&&(f[k]=d,c.setAttribute(g,d));e--;0==e&&b(a)})):c.setAttribute(g,l)}})(k[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=function(a){return"https?://raw.githubusercontent.com/"===
-a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=
-function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var g=this.editor.graph;if(null!=a&&0<a.length){var k=mxUtils.parseXml(a),l=this.editor.extractGraphModel(k.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(g.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){g.model.beginUpdate();try{for(var n=0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),
-A=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[A+1]));g.model.execute(new ChangePage(this,p,p,A))}}finally{g.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var v=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,v);var B=v.getChildCount(v.getRoot());g.model.getChildCount(g.model.getRoot());g.model.beginUpdate();try{a={};for(n=0;n<B;n++){var G=v.getChildAt(v.getRoot(),n);if(1!=B||g.isCellLocked(g.getDefaultParent()))G=g.importCells([G],0,0,g.model.getRoot(),
-null,a)[0],F=g.model.getChildren(G),g.moveCells(F,b,c),f=f.concat(F);else var F=v.getChildren(G),f=f.concat(g.importCells(F,b,c,g.getDefaultParent(),null,a))}if(d){g.isGridEnabled()&&(b=g.snap(b),c=g.snap(c));var C=g.getBoundingBoxFromGeometry(f,!0);null!=C&&g.moveCells(f,b-C.x,c-C.y)}}finally{g.model.endUpdate()}}}}catch(H){throw e||this.handleError(H,mxResources.get("invalidOrMissingFile")),H;}return f};EditorUi.prototype.insertLucidChart=function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,
-b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var g=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var k=this.extractGraphModelFromPng(a),l=this.importXml(k,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,19))try{if(k=null,"data:image/svg+xml;base64,"==a.substring(0,
-26)?(k=a.substring(a.indexOf(",")+1),k=window.atob&&!mxClient.IS_SF?atob(k):Base64.decode(k,!0)):k=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(k,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){g.setSelectionCell(g.insertVertex(null,null,"",g.snap(b),g.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
+this.handleError(a)}),null,c,a||1,b,d,null,null,f,g)}catch(z){this.spinner.stop(),this.handleError(z)}}};EditorUi.prototype.exportToCanvas=function(a,b,c,d,e,f,g,r,u,x,z,y,A,v){f=null!=f?f:!0;y=null!=y?y:this.editor.graph;A=null!=A?A:0;var k=u?null:y.background;k==mxConstants.NONE&&(k=null);null==k&&(k=d);null==k&&0==u&&(k="#ffffff");this.convertImages(y.getSvg(k,null,null,v,null,null!=g?g:!0),mxUtils.bind(this,function(c){var d=new Image;d.onload=mxUtils.bind(this,function(){try{var g=document.createElement("canvas"),
+l=parseInt(c.getAttribute("width")),m=parseInt(c.getAttribute("height"));r=null!=r?r:1;null!=b&&(r=f?Math.min(1,Math.min(3*b/(4*m),b/l)):b/l);l=Math.ceil(r*l)+2*A;m=Math.ceil(r*m)+2*A;g.setAttribute("width",l);g.setAttribute("height",m);var n=g.getContext("2d");null!=k&&(n.beginPath(),n.rect(0,0,l,m),n.fillStyle=k,n.fill());n.scale(r,r);n.drawImage(d,A/r,A/r);a(g)}catch(M){null!=e&&e(M)}});d.onerror=function(a){null!=e&&e(a)};try{x&&this.editor.graph.addSvgShadow(c),this.convertMath(y,c,!0,mxUtils.bind(this,
+function(){d.src=this.createSvgDataUri(mxUtils.getXml(c))}))}catch(C){null!=e&&e(C)}}),c,z)};EditorUi.prototype.createImageUrlConverter=function(){var a=new mxUrlConverter;a.updateBaseUrl();var b=a.convert;a.convert=function(c){null!=c&&("http://"!=c.substring(0,7)&&"https://"!=c.substring(0,8)||c.substring(0,a.baseUrl.length)==a.baseUrl?"chrome-extension://"!=c.substring(0,19)&&(c=b.apply(this,arguments)):c=PROXY_URL+"?url="+encodeURIComponent(c));return c};return a};EditorUi.prototype.convertImages=
+function(a,b,c,d){null==d&&(d=this.createImageUrlConverter());var e=0,f=c||{};c=mxUtils.bind(this,function(c,g){for(var k=a.getElementsByTagName(c),l=0;l<k.length;l++)mxUtils.bind(this,function(c){var k=d.convert(c.getAttribute(g));if(null!=k&&"data:"!=k.substring(0,5)){var l=f[k];null==l?(e++,this.convertImageToDataUri(k,function(d){null!=d&&(f[k]=d,c.setAttribute(g,d));e--;0==e&&b(a)})):c.setAttribute(g,l)}})(k[l])});c("image","xlink:href");c("img","src");0==e&&b(a)};EditorUi.prototype.isCorsEnabledForUrl=
+function(a){return"https?://raw.githubusercontent.com/"===a.substring(0,34)||/^https?:\/\/.*\.github\.io\//.test(a)||/^https?:\/\/(.*\.)?rawgit\.com\//.test(a)};EditorUi.prototype.convertImageToDataUri=function(a,b){if(/(\.svg)$/i.test(a))mxUtils.get(a,mxUtils.bind(this,function(a){b(this.createSvgDataUri(a.getText()))}),function(){b()});else{var c=new Image;c.onload=function(){var a=document.createElement("canvas"),d=a.getContext("2d");a.height=c.height;a.width=c.width;d.drawImage(c,0,0);b(a.toDataURL())};
+c.onerror=function(){b()};c.src=a}};EditorUi.prototype.importXml=function(a,b,c,d,e){b=null!=b?b:0;c=null!=c?c:0;var f=[];try{var g=this.editor.graph;if(null!=a&&0<a.length){var k=mxUtils.parseXml(a),l=this.editor.extractGraphModel(k.documentElement,null!=this.pages);if(null!=l&&"mxfile"==l.nodeName&&null!=this.pages){var m=l.getElementsByTagName("diagram");if(1==m.length)l=mxUtils.parseXml(g.decompress(mxUtils.getTextContent(m[0]))).documentElement;else if(1<m.length){g.model.beginUpdate();try{for(var n=
+0;n<m.length;n++){var p=this.updatePageRoot(new DiagramPage(m[n])),A=this.pages.length;null==p.getName()&&p.setName(mxResources.get("pageWithNumber",[A+1]));g.model.execute(new ChangePage(this,p,p,A))}}finally{g.model.endUpdate()}}}if(null!=l&&"mxGraphModel"===l.nodeName){var v=new mxGraphModel;(new mxCodec(l.ownerDocument)).decode(l,v);var B=v.getChildCount(v.getRoot());g.model.getChildCount(g.model.getRoot());g.model.beginUpdate();try{a={};for(n=0;n<B;n++){var G=v.getChildAt(v.getRoot(),n);if(1!=
+B||g.isCellLocked(g.getDefaultParent()))G=g.importCells([G],0,0,g.model.getRoot(),null,a)[0],F=g.model.getChildren(G),g.moveCells(F,b,c),f=f.concat(F);else var F=v.getChildren(G),f=f.concat(g.importCells(F,b,c,g.getDefaultParent(),null,a))}if(d){g.isGridEnabled()&&(b=g.snap(b),c=g.snap(c));var C=g.getBoundingBoxFromGeometry(f,!0);null!=C&&g.moveCells(f,b-C.x,c-C.y)}}finally{g.model.endUpdate()}}}}catch(H){throw e||this.handleError(H,mxResources.get("invalidOrMissingFile")),H;}return f};EditorUi.prototype.insertLucidChart=
+function(a,b,c,d){var e=mxUtils.bind(this,function(){if(this.pasteLucidChart)try{this.pasteLucidChart(a,b,c,d)}catch(q){}});this.pasteLucidChart||this.loadingExtensions||this.isOffline()?window.setTimeout(e,0):(this.loadingExtensions=!0,"1"==urlParams.dev?mxscript("/js/diagramly/Extensions.js",e):mxscript("/js/extensions.min.js",e))};EditorUi.prototype.insertTextAt=function(a,b,c,d,e,f){f=null!=f?f:!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,c,!0))}));else if("data:"==a.substring(0,5)||!this.isOffline()&&(e||/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(a))){var g=this.editor.graph;if("data:image/png;base64,"==a.substring(0,22)){var k=this.extractGraphModelFromPng(a),l=this.importXml(k,b,c,f,!0);if(0<l.length)return l}if("data:image/svg+xml;"==a.substring(0,
+19))try{if(k=null,"data:image/svg+xml;base64,"==a.substring(0,26)?(k=a.substring(a.indexOf(",")+1),k=window.atob&&!mxClient.IS_SF?atob(k):Base64.decode(k,!0)):k=decodeURIComponent(a.substring(a.indexOf(",")+1)),l=this.importXml(k,b,c,f,!0),0<l.length)return l}catch(z){}this.loadImage(a,mxUtils.bind(this,function(d){if("data:"==a.substring(0,5))this.resizeImage(d,a,mxUtils.bind(this,function(a,d,e){g.setSelectionCell(g.insertVertex(null,null,"",g.snap(b),g.snap(c),d,e,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+
 this.convertDataUri(a)+";"))}),!0,this.maxImageSize);else{var e=Math.min(1,Math.min(this.maxImageSize/d.width,this.maxImageSize/d.height)),f=Math.round(d.width*e);d=Math.round(d.height*e);g.setSelectionCell(g.insertVertex(null,null,"",g.snap(b),g.snap(c),f,d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+a+";"))}}),mxUtils.bind(this,function(){var e=null;g.getModel().beginUpdate();try{e=g.insertVertex(g.getDefaultParent(),
 null,a,g.snap(b),g.snap(c),1,1,"text;"+(d?"html=1;":"")),g.updateCellSize(e),g.fireEvent(new mxEventObject("textInserted","cells",[e]))}finally{g.getModel().endUpdate()}g.setSelectionCell(e)}))}else{a=this.editor.graph.zapGremlins(mxUtils.trim(a));if(this.isCompatibleString(a))return this.importXml(a,b,c,f);if(0<a.length)if('{"state":"{\\"Properties\\":'==a.substring(0,26)){e=JSON.parse(JSON.parse(a).state);var k=null,m;for(m in e.Pages)if(l=e.Pages[m],null!=l&&"0"==l.Properties.Order){k=l;break}null!=
 k&&this.insertLucidChart(k,b,c,f)}else{g=this.editor.graph;f=null;g.getModel().beginUpdate();try{f=g.insertVertex(g.getDefaultParent(),null,"",g.snap(b),g.snap(c),1,1,"text;"+(d?"html=1;":"")),g.fireEvent(new mxEventObject("textInserted","cells",[f])),f.value=a,g.updateCellSize(f),/\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/i.test(f.value)&&
@@ -2834,11 +2835,11 @@ for(var b=0;256>b;b++)for(var c=b,d=0;8>d;d++)c=1==(c&1)?3988292384^c>>>1:c>>>1,
 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 l=0;if(f(a,8)!=String.fromCharCode(137)+"PNG"+String.fromCharCode(13,10,26,10))null!=e&&e();else if(f(a,4),"IHDR"!=f(a,4))null!=e&&e();else{f(a,17);e=a.substring(0,l);do{var m=g(a);if("IDAT"==f(a,4)){e=a.substring(0,l-8);c=c+String.fromCharCode(0)+("zTXt"==b?String.fromCharCode(0):"")+d;d=4294967295;d=this.updateCRC(d,b,0,4);d=this.updateCRC(d,c,0,c.length);e+=k(c.length)+b+c+k(d^4294967295);
 e+=a.substring(l-8,a.length);break}e+=a.substring(l-8,l-4+m);d=f(a,m);f(a,4)}while(m);return"data:image/png;base64,"+(window.btoa?btoa(e):Base64.encode(e,!0))}};EditorUi.prototype.extractGraphModelFromPng=function(a){var b=null;try{var c=a.substring(a.indexOf(",")+1),d=window.atob&&!mxClient.IS_SF?atob(c):Base64.decode(c,!0);EditorUi.parsePng(d,mxUtils.bind(this,function(a,c,e){a=d.substring(a+8,a+8+e);"zTXt"==c?(e=a.indexOf(String.fromCharCode(0)),"mxGraphModel"==a.substring(0,e)&&(a=this.editor.graph.bytesToString(pako.inflateRaw(a.substring(e+
 2))).replace(/\+/g," "),null!=a&&0<a.length&&(b=a))):"tEXt"==c&&(a=a.split(String.fromCharCode(0)),1<a.length&&"mxGraphModel"==a[0]&&(b=a[1]));if(null!=b||"IDAT"==c)return!0}))}catch(p){}null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));null!=b&&"%"==b.charAt(0)&&(b=decodeURIComponent(b));return b};EditorUi.prototype.loadImage=function(a,b,c){var d=new Image;d.onload=function(){b(d)};null!=c&&(d.onerror=c);d.src=a};var e=EditorUi.prototype.init;EditorUi.prototype.init=function(){function a(a){var c=
-a.indexOf(",");0<c&&(a=b.getPageById(a.substring(c+1)))&&b.selectPage(a)}var b=this,c=this.editor.graph,d=c.addClickHandler;c.addClickHandler=function(b,e,f){var g=e;e=function(b,d){if(null==d){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(d=e.getAttribute("href"))}null!=d&&c.isPageLink(d)&&(a(d),mxEvent.consume(b));null!=g&&g(b)};d.call(this,b,e,f)};e.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(c.view.canvas.ownerSVGElement,null,!0);b.actions.get("print").funct=
-function(){b.showDialog((new PrintDialog(b)).container,360,null!=b.pages&&1<b.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=c.getGlobalVariable;c.getGlobalVariable=function(a){return"page"==a&&null!=b.currentPage?b.currentPage.getName():"pagenumber"==a?null!=b.currentPage&&null!=b.pages?mxUtils.indexOf(b.pages,b.currentPage)+1:1:f.apply(this,arguments)};var g=c.createLinkForHint;c.createLinkForHint=function(d,e){var f=c.isPageLink(d);if(f){var k=d.indexOf(",");
-0<k&&(k=b.getPageById(d.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(b){a(d);mxEvent.consume(b)});return k};var t=c.labelLinkClicked;c.labelLinkClicked=function(b,d,e){var f=d.getAttribute("href");c.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=b.defaultFilename,c=b.getCurrentFile();null!=c&&(a=null!=c.getTitle()?c.getTitle():a);return a};
-var r=this.actions.get("print");r.setEnabled(!mxClient.IS_IOS||!navigator.standalone);r.visible=r.isEnabled();if(!this.editor.chromeless){var u=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||c.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var g=f[index];if("file"===g.kind){if(b.isEditing())this.importFiles([g.getAsFile()],
+a.indexOf(",");0<c&&(a=b.getPageById(a.substring(c+1)))&&b.selectPage(a)}"undefined"!==typeof window.mxSettings&&(this.formatWidth=mxSettings.getFormatWidth());var b=this,c=this.editor.graph,d=c.addClickHandler;c.addClickHandler=function(b,e,f){var g=e;e=function(b,d){if(null==d){var e=mxEvent.getSource(b);"a"==e.nodeName.toLowerCase()&&(d=e.getAttribute("href"))}null!=d&&c.isPageLink(d)&&(a(d),mxEvent.consume(b));null!=g&&g(b)};d.call(this,b,e,f)};e.apply(this,arguments);mxClient.IS_SVG&&this.editor.graph.addSvgShadow(c.view.canvas.ownerSVGElement,
+null,!0);b.actions.get("print").funct=function(){b.showDialog((new PrintDialog(b)).container,360,null!=b.pages&&1<b.pages.length?420:360,!0,!0)};this.defaultFilename=mxResources.get("untitledDiagram");var f=c.getGlobalVariable;c.getGlobalVariable=function(a){return"page"==a&&null!=b.currentPage?b.currentPage.getName():"pagenumber"==a?null!=b.currentPage&&null!=b.pages?mxUtils.indexOf(b.pages,b.currentPage)+1:1:f.apply(this,arguments)};var g=c.createLinkForHint;c.createLinkForHint=function(d,e){var f=
+c.isPageLink(d);if(f){var k=d.indexOf(",");0<k&&(k=b.getPageById(d.substring(k+1)),e=null!=k?k.getName():mxResources.get("pageNotFound"))}k=g.apply(this,arguments);f&&mxEvent.addListener(k,"click",function(b){a(d);mxEvent.consume(b)});return k};var t=c.labelLinkClicked;c.labelLinkClicked=function(b,d,e){var f=d.getAttribute("href");c.isPageLink(f)?(a(f),mxEvent.consume(e)):t.apply(this,arguments)};this.editor.getOrCreateFilename=function(){var a=b.defaultFilename,c=b.getCurrentFile();null!=c&&(a=
+null!=c.getTitle()?c.getTitle():a);return a};var r=this.actions.get("print");r.setEnabled(!mxClient.IS_IOS||!navigator.standalone);r.visible=r.isEnabled();if(!this.editor.chromeless){var u=function(){window.setTimeout(function(){x.innerHTML="&nbsp;";x.focus();document.execCommand("selectAll",!1,null)},0)};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",!0);mxClient.IS_IE||c.container.addEventListener("paste",mxUtils.bind(this,function(a){var b=this.editor.graph;if(!mxEvent.isConsumed(a))try{for(var c=a.clipboardData||a.originalEvent.clipboardData,d=!1,e=0;e<c.types.length;e++)if("text/"===c.types[e].substring(0,5)){d=!0;break}if(!d){var f=c.items;for(index in f){var g=f[index];if("file"===g.kind){if(b.isEditing())this.importFiles([g.getAsFile()],
 0,0,this.maxImageSize,function(a,c,d,e,f,g){b.insertImage(a,f,g)},function(){},function(a){return"image/"==a.type.substring(0,6)},function(a){for(var b=0;b<a.length;b++)a[b]()});else{var k=this.editor.graph.getInsertPoint();this.importFiles([g.getAsFile()],k.x,k.y,this.maxImageSize);mxEvent.consume(a)}break}}}}catch(L){}}),!1);var x=document.createElement("div");x.style.position="absolute";x.style.whiteSpace="nowrap";x.style.overflow="hidden";x.style.display="block";x.contentEditable=!0;mxUtils.setOpacity(x,
 0);x.style.width="1px";x.style.height="1px";x.innerHTML="&nbsp;";var z=!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 b=mxEvent.getSource(a);null==c.container||!c.isEnabled()||c.isMouseDown||c.isEditing()||null!=this.dialog||"INPUT"==b.nodeName||"TEXTAREA"==b.nodeName||!(224==a.keyCode||!mxClient.IS_MAC&&17==a.keyCode||mxClient.IS_MAC&&91==a.keyCode)||
 z||(x.style.left=c.container.scrollLeft+10+"px",x.style.top=c.container.scrollTop+10+"px",c.container.appendChild(x),z=!0,mxClient.IS_QUIRKS?window.setTimeout(function(){x.focus();document.execCommand("selectAll",!1,null)},0):(x.focus(),document.execCommand("selectAll",!1,null)))}));mxEvent.addListener(document,"keyup",mxUtils.bind(this,function(a){var b=a.keyCode;window.setTimeout(mxUtils.bind(this,function(){!z||224!=b&&17!=b&&91!=b||(z=!1,c.isEditing()||null!=this.dialog||null==c.container||c.container.focus(),
@@ -2853,53 +2854,57 @@ null;mxEvent.addListener(c.container,"dragleave",function(a){c.isEnabled()&&(nul
 v=null);if(c.isEnabled()){var b=mxUtils.convertPoint(c.container,mxEvent.getClientX(a),mxEvent.getClientY(a)),d=c.view.translate,e=c.view.scale,f=b.x/e-d.x,g=b.y/e-d.y;mxEvent.isAltDown(a)&&(g=f=0);if(0<a.dataTransfer.files.length)this.importFiles(a.dataTransfer.files,f,g,this.maxImageSize,null,null,null,null,!mxEvent.isControlDown(a),null,null,mxEvent.isShiftDown(a));else{var k=0<=mxUtils.indexOf(a.dataTransfer.types,"text/uri-list")?a.dataTransfer.getData("text/uri-list"):null,b=this.extractGraphModelFromEvent(a,
 null!=this.pages);if(null!=b)c.setSelectionCells(this.importXml(b,f,g,!0));else if(0<=mxUtils.indexOf(a.dataTransfer.types,"text/html")){b=a.dataTransfer.getData("text/html");e=document.createElement("div");e.innerHTML=b;var d=null,l=e.getElementsByTagName("img");null!=l&&1==l.length?(b=l[0].getAttribute("src"),/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(b)||(d=!0)):(e=e.getElementsByTagName("a"),null!=e&&1==e.length&&(b=e[0].getAttribute("href")));c.setSelectionCells(this.insertTextAt(b,f,g,!0,d))}else null!=
 k&&/\.(gif|jpg|jpeg|tiff|png|svg)$/i.test(k)?this.loadImage(decodeURIComponent(k),mxUtils.bind(this,function(a){var b=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,b)),d/Math.max(1,a));c.setSelectionCell(c.insertVertex(null,null,"",f,g,b*d,a*d,"shape=image;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;aspect=fixed;imageAspect=0;image="+k+";"))}),mxUtils.bind(this,function(a){c.setSelectionCells(this.insertTextAt(k,
-f,g,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&c.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,g,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode()};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,
-encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=
-this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var g=e.lastIndexOf("%3E");0<=g&&g<e.length-3&&(e=e.substring(0,g+3))}catch(u){}try{var c=b.getElementsByTagName("span"),k=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(k)&&(f=!0,e=k)}catch(u){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=
-e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(u){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=
-null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,
-function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;
-var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?
-this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=
-0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?
-this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(r){this.handleError(r,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,
-d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,
-a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),
-this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),
-c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=
-null!=c?c:!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 b=
-this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,
-f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function k(a){if(null!=a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(I){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(E){l=null}if(null==l)return;
-if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&g.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?
-mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):k(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",
-result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(E){g.postMessage(JSON.stringify({event:"draft",error:E.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?
-g.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=
-l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,
-t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;g.postMessage(JSON.stringify(b),"*")}),r=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=
-this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),F=q.getGlobalVariable,C=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?C.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(C.root)}this.exportToCanvas(mxUtils.bind(this,function(a){r(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){r(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+
-("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):r(null)}),mxUtils.bind(this,function(){r(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=
-this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),
-"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);g.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));g.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),
-this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=this.createSvgDataUri(m)}g.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight=
-"12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight="38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{g.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=k(l);c=!0;try{a(l,f)}catch(E){this.handleError(E)}c=!1;null!=
-urlParams.modified&&this.editor.setStatus("");var H=mxUtils.bind(this,function(){return"0"!=urlParams.pages||null!=this.pages&&1<this.pages.length?this.getFileData(!0):mxUtils.getXml(this.editor.getGraphXml())});e=H();d&&null==b&&(b=mxUtils.bind(this,function(a,b){var d=H();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",
-b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||g.postMessage(JSON.stringify(this.createLoadMessage("load")),
-"*")}));var g=window.opener||window.parent,f="json"==urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";g.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",
-mxResources.get("save")+" (Ctrl+S)");b.className="geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor=
-"pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=
-a.split("\n"),c=[];if(0<b.length){var d={},e=null,f=null,g="auto",k="auto",u=40,x=40,z=0,y=this.editor.graph;y.getGraphBounds();for(var A=function(){y.setSelectionCells(M);y.scrollCellToVisible(y.getSelectionCell())},v=y.getFreeInsertPoint(),B=v.x,G=v.y,v=G,F=null,C="auto",H=[],E=null,I=null,N=0;N<b.length&&"#"==b[N].charAt(0);){a=b[N];for(N++;N<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[N].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[N].substring(1)),N++;if("#"!=a.charAt(1)){var L=a.indexOf(":");
-if(0<L){var V=mxUtils.trim(a.substring(1,L)),P=mxUtils.trim(a.substring(L+1));"label"==V?F=y.sanitizeHtml(P):"style"==V?e=P:"identity"==V&&0<P.length&&"-"!=P?f=P:"width"==V?g=P:"height"==V?k=P:"ignore"==V?I=P.split(","):"connect"==V?H.push(JSON.parse(P)):"link"==V?E=P:"padding"==V?z=parseFloat(P):"edgespacing"==V?u=parseFloat(P):"nodespacing"==V?x=parseFloat(P):"layout"==V&&(C=P)}}}var ba=this.editor.csvToArray(b[N]);a=null;if(null!=f)for(var T=0;T<ba.length;T++)if(f==ba[T]){a=T;break}null==F&&(F=
-"%"+ba[0]+"%");if(null!=H)for(var D=0;D<H.length;D++)null==d[H[D].to]&&(d[H[D].to]={});y.model.beginUpdate();try{for(T=N+1;T<b.length;T++){var X=this.editor.csvToArray(b[T]);if(X.length==ba.length){var Q=null,J=null!=a?X[a]:null;null!=J&&(Q=y.model.getCell(J));null==Q&&(Q=new mxCell(F,new mxGeometry(B,v,0,0),e||"whiteSpace=wrap;html=1;"),Q.vertex=!0,Q.id=J);for(var Y=0;Y<X.length;Y++)y.setAttributeForCell(Q,ba[Y],X[Y]);y.setAttributeForCell(Q,"placeholders","1");Q.style=y.replacePlaceholders(Q,Q.style);
-for(D=0;D<H.length;D++)d[H[D].to][Q.getAttribute(H[D].to)]=Q;null!=E&&"link"!=E&&(y.setLinkForCell(Q,Q.getAttribute(E)),y.setAttributeForCell(Q,E,null));var O=this.editor.graph.getPreferredSizeForCell(Q);Q.geometry.width="auto"==g?O.width+z:parseFloat(g);Q.geometry.height="auto"==k?O.height+z:parseFloat(k);v+=Q.geometry.height+x;c.push(y.addCell(Q))}}null==e&&y.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var K=c.slice(),M=c.slice(),D=0;D<H.length;D++)for(var U=H[D],T=0;T<c.length;T++){var Q=
-c[T],ca=Q.getAttribute(U.from);if(null!=ca){y.setAttributeForCell(Q,U.from,null);for(var Z=ca.split(","),Y=0;Y<Z.length;Y++){var R=d[U.to][Z[Y]];null!=R&&(M.push(y.insertEdge(null,null,U.label||"",U.invert?R:Q,U.invert?Q:R,U.style||y.createCurrentEdgeStyle())),mxUtils.remove(U.invert?Q:R,K))}}}if(null!=I)for(T=0;T<c.length;T++)for(Q=c[T],Y=0;Y<I.length;Y++)y.setAttributeForCell(Q,mxUtils.trim(I[Y]),null);var aa=new mxParallelEdgeLayout(y);aa.spacing=u;var da=function(){aa.execute(y.getDefaultParent());
-for(var a=0;a<c.length;a++){var b=y.getCellGeometry(c[a]);b.x=Math.round(y.snap(b.x));b.y=Math.round(y.snap(b.y));"auto"==g&&(b.width=Math.round(y.snap(b.width)));"auto"==k&&(b.height=Math.round(y.snap(b.height)))}};if("circle"==C){var S=new mxCircleLayout(y);S.resetEdges=!1;var W=S.isVertexIgnored;S.isVertexIgnored=function(a){return W.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){S.execute(y.getDefaultParent());da()},!0,A);A=null}else if("horizontaltree"==C||"verticaltree"==
-C||"auto"==C&&M.length==2*c.length-1&&1==K.length){y.view.validate();var ga=new mxCompactTreeLayout(y,"horizontaltree"==C);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(y.getDefaultParent(),0<K.length?K[0]:null)},!0,A);A=null}else if("horizontalflow"==C||"verticalflow"==C||"auto"==C&&1==K.length){y.view.validate();var ea=new mxHierarchicalLayout(y,"horizontalflow"==C?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);ea.intraCellSpacing=x;ea.disableEdgeStyle=
-!1;this.executeLayout(function(){ea.execute(y.getDefaultParent(),M);y.moveCells(M,B,G)},!0,A);A=null}else if("organic"==C||"auto"==C&&M.length>c.length){y.view.validate();var ha=new mxFastOrganicLayout(y);ha.forceConstant=3*x;ha.resetEdges=!1;var la=ha.isVertexIgnored;ha.isVertexIgnored=function(a){return la.apply(this,arguments)||0>mxUtils.indexOf(c,a)};aa=new mxParallelEdgeLayout(y);aa.spacing=u;this.executeLayout(function(){ha.execute(y.getDefaultParent());da()},!0,A);A=null}this.hideDialog()}finally{y.model.endUpdate()}null!=
-A&&A()}}catch(ma){this.handleError(ma)}};EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
+f,g,!0))})):0<=mxUtils.indexOf(a.dataTransfer.types,"text/plain")&&c.setSelectionCells(this.insertTextAt(a.dataTransfer.getData("text/plain"),f,g,!0))}}a.stopPropagation();a.preventDefault()}),!1)}this.initPages();"1"==urlParams.embed&&this.initializeEmbedMode();"undefined"!==typeof window.mxSettings&&this.installSettings()};EditorUi.prototype.installSettings=function(){if(isLocalStorage||mxClient.IS_CHROMEAPP)ColorDialog.recentColors=mxSettings.getRecentColors(),this.editor.graph.currentEdgeStyle=
+mxSettings.getCurrentEdgeStyle(),this.editor.graph.currentVertexStyle=mxSettings.getCurrentVertexStyle(),this.fireEvent(new mxEventObject("styleChanged","keys",[],"values",[],"cells",[])),this.addListener("styleChanged",mxUtils.bind(this,function(a,b){mxSettings.setCurrentEdgeStyle(this.editor.graph.currentEdgeStyle);mxSettings.setCurrentVertexStyle(this.editor.graph.currentVertexStyle);mxSettings.save()})),this.editor.graph.connectionHandler.setCreateTarget(mxSettings.isCreateTarget()),this.fireEvent(new mxEventObject("copyConnectChanged")),
+this.addListener("copyConnectChanged",mxUtils.bind(this,function(a,b){mxSettings.setCreateTarget(this.editor.graph.connectionHandler.isCreateTarget());mxSettings.save()})),this.editor.graph.pageFormat=mxSettings.getPageFormat(),this.addListener("pageFormatChanged",mxUtils.bind(this,function(a,b){mxSettings.setPageFormat(this.editor.graph.pageFormat);mxSettings.save()})),this.editor.graph.view.gridColor=mxSettings.getGridColor(),this.addListener("gridColorChanged",mxUtils.bind(this,function(a,b){mxSettings.setGridColor(this.editor.graph.view.gridColor);
+mxSettings.save()})),mxClient.IS_CHROMEAPP&&(this.editor.addListener("autosaveChanged",mxUtils.bind(this,function(a,b){mxSettings.setAutosave(this.editor.autosave);mxSettings.save()})),this.editor.autosave=mxSettings.getAutosave()),null!=this.sidebar&&this.sidebar.showPalette("search",mxSettings.settings.search),!this.editor.chromeless&&null!=this.sidebar&&(mxSettings.settings.isNew||8>=parseInt(mxSettings.settings.version||0))&&(this.toggleScratchpad(),mxSettings.save()),this.addListener("formatWidthChanged",
+function(){mxSettings.setFormatWidth(this.formatWidth);mxSettings.save()})};EditorUi.prototype.copyCells=function(a,b){var c=this.editor.graph;if(c.isSelectionEmpty())a.innerHTML="";else{var d=mxUtils.sortCells(c.model.getTopmostCells(c.getSelectionCells())),e=mxUtils.getXml(this.editor.graph.encodeCells(d));mxUtils.setTextContent(a,encodeURIComponent(e));b?(c.removeCells(d,!1),c.lastPasteXml=null):(c.lastPasteXml=e,c.pasteCounter=0);a.focus();document.execCommand("selectAll",!1,null)}};EditorUi.prototype.pasteCells=
+function(a,b){if(!mxEvent.isConsumed(a)){var c=b.getElementsByTagName("span");if(null!=c&&0<c.length&&"application/vnd.lucid.chart.objects"===c[0].getAttribute("data-lucid-type")){var d=c[0].getAttribute("data-lucid-content");null!=d&&0<d.length&&(this.insertLucidChart(JSON.parse(d)),mxEvent.consume(a))}else{var d=this.editor.graph,e=mxUtils.trim(mxClient.IS_QUIRKS||8==document.documentMode?mxUtils.getTextContent(b):b.textContent),f=!1;try{var g=e.lastIndexOf("%3E");0<=g&&g<e.length-3&&(e=e.substring(0,
+g+3))}catch(u){}try{var c=b.getElementsByTagName("span"),k=null!=c&&0<c.length?mxUtils.trim(decodeURIComponent(c[0].textContent)):decodeURIComponent(e);this.isCompatibleString(k)&&(f=!0,e=k)}catch(u){}d.lastPasteXml==e?d.pasteCounter++:(d.lastPasteXml=e,d.pasteCounter=0);c=d.pasteCounter*d.gridSize;if(null!=e&&0<e.length&&(f||this.isCompatibleString(e)?d.setSelectionCells(this.importXml(e,c,c)):(f=d.getInsertPoint(),d.isMouseInsertPoint()&&(c=0,d.lastPasteXml==e&&0<d.pasteCounter&&d.pasteCounter--),
+d.setSelectionCells(this.insertTextAt(e,f.x+c,f.y+c,!0))),!d.isSelectionEmpty())){d.scrollCellToVisible(d.getSelectionCell());null!=this.hoverIcons&&this.hoverIcons.update(d.view.getState(d.getSelectionCell()));try{mxEvent.consume(a)}catch(u){}}}}};EditorUi.prototype.addFileDropHandler=function(a){if(Graph.fileSupport)for(var b=null,c=0;c<a.length;c++)mxEvent.addListener(a[c],"dragleave",function(a){null!=b&&(b.parentNode.removeChild(b),b=null);a.stopPropagation();a.preventDefault()}),mxEvent.addListener(a[c],
+"dragover",mxUtils.bind(this,function(a){null==b&&(!mxClient.IS_IE||10<document.documentMode&&12>document.documentMode)&&(b=this.highlightElement());a.stopPropagation();a.preventDefault()})),mxEvent.addListener(a[c],"drop",mxUtils.bind(this,function(a){null!=b&&(b.parentNode.removeChild(b),b=null);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);else{var c=this.extractGraphModelFromEvent(a);if(null==c){var d=null!=a.dataTransfer?a.dataTransfer:a.clipboardData;null!=d&&(10==document.documentMode||11==document.documentMode?c=d.getData("Text"):(c=null,c=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!=c&&0<c.length?(d=document.createElement("div"),d.innerHTML=c,d=d.getElementsByTagName("img"),0<d.length&&
+(c=d[0].getAttribute("src"))):0<=mxUtils.indexOf(d.types,"text/plain")&&(c=d.getData("text/plain"))),null!=c&&("data:image/png;base64,"==c.substring(0,22)?(c=this.extractGraphModelFromPng(c),null!=c&&0<c.length&&this.openLocalFile(c,null,!0)):!this.isOffline()&&this.isRemoteFileFormat(c)?(new mxXmlRequest(OPEN_URL,"format=xml&data="+encodeURIComponent(c))).send(mxUtils.bind(this,function(a){200<=a.getStatus()&&299>=a.getStatus()&&this.openLocalFile(a.getText(),null,!0)})):/^https?:\/\//.test(c)&&
+(null==this.getCurrentFile()?window.location.hash="#U"+encodeURIComponent(c):window.openWindow((mxClient.IS_CHROMEAPP?"https://www.draw.io/":"https://"+location.host+"/")+window.location.search+"#U"+encodeURIComponent(c)))))}else this.openLocalFile(c,null,!0)}a.stopPropagation();a.preventDefault()}))};EditorUi.prototype.highlightElement=function(a){var b=0,c=0,d,e;if(null==a){e=document.body;var f=document.documentElement;d=(e.clientWidth||f.clientWidth)-3;e=Math.max(e.clientHeight||0,f.clientHeight)-
+3}else b=a.offsetTop,c=a.offsetLeft,d=a.clientWidth,e=a.clientHeight;f=document.createElement("div");f.style.zIndex=mxPopupMenu.prototype.zIndex+2;f.style.border="3px dotted rgb(254, 137, 12)";f.style.pointerEvents="none";f.style.position="absolute";f.style.top=b+"px";f.style.left=c+"px";f.style.width=Math.max(0,d-3)+"px";f.style.height=Math.max(0,e-3)+"px";null!=a&&a.parentNode==this.editor.graph.container?this.editor.graph.container.appendChild(f):document.body.appendChild(f);return f};EditorUi.prototype.stringToCells=
+function(a){a=mxUtils.parseXml(a);var b=this.editor.extractGraphModel(a.documentElement);a=[];if(null!=b){var c=new mxCodec(b.ownerDocument),d=new mxGraphModel;c.decode(b,d);b=d.getChildAt(d.getRoot(),0);for(c=0;c<d.getChildCount(b);c++)a.push(d.getChildAt(b,c))}return a};EditorUi.prototype.openFiles=function(a){if(this.spinner.spin(document.body,mxResources.get("loading")))for(var b=0;b<a.length;b++)mxUtils.bind(this,function(a){var b=new FileReader;b.onload=mxUtils.bind(this,function(b){var c=b.target.result,
+d=a.name;if(null!=d&&0<d.length)if(/(\.png)$/i.test(d)&&(d=d.substring(0,d.length-4)+".xml"),Graph.fileSupport&&!this.isOffline()&&(new XMLHttpRequest).upload&&this.isRemoteFileFormat(c,d))d=0<=d.lastIndexOf(".")?d.substring(0,d.lastIndexOf("."))+".xml":d+".xml",this.parseFile(a,mxUtils.bind(this,function(a){4==a.readyState&&(this.spinner.stop(),200<=a.status&&299>=a.status?this.openLocalFile(a.responseText,d):this.handleError({message:mxResources.get(413==a.status?"drawingTooLarge":"invalidOrMissingFile")},
+mxResources.get("errorLoadingFile")))}));else if("<mxlibrary"==b.target.result.substring(0,10)){this.spinner.stop();try{this.loadLibrary(new LocalLibrary(this,b.target.result,a.name))}catch(r){this.handleError(r,mxResources.get("errorLoadingFile"))}}else"image/png"==a.type.substring(0,9)&&(c=this.extractGraphModelFromPng(c)),this.spinner.stop(),this.openLocalFile(c,d)});b.onerror=mxUtils.bind(this,function(a){this.spinner.stop();this.handleError(a);window.openFile=null});"image"===a.type.substring(0,
+5)&&"image/svg"!==a.type.substring(0,9)?b.readAsDataURL(a):b.readAsText(a)})(a[b])};EditorUi.prototype.openLocalFile=function(a,b,c){var d=this.getCurrentFile(),e=mxUtils.bind(this,function(){window.openFile=null;if(null==b&&null!=this.getCurrentFile()&&this.isDiagramEmpty()){var d=mxUtils.parseXml(a);null!=d&&(this.editor.setGraphXml(d.documentElement),this.editor.graph.selectAll())}else this.fileLoaded(new LocalFile(this,a,b||this.defaultFilename,c))});null!=a&&0<a.length&&(null!=d&&d.isModified()?
+(window.openFile=new OpenFile(function(){window.openFile=null}),window.openFile.setData(a,b),window.openWindow(this.getUrl(),null,mxUtils.bind(this,function(){this.confirm(mxResources.get("allChangesLost"),null,e,mxResources.get("cancel"),mxResources.get("discardChanges"))}))):e())};EditorUi.prototype.getBasenames=function(){var a={};if(null!=this.pages)for(var b=0;b<this.pages.length;b++)this.updatePageRoot(this.pages[b]),this.addBasenamesForCell(this.pages[b].root,a);else this.addBasenamesForCell(this.editor.graph.model.getRoot(),
+a);var b=[],c;for(c in a)b.push(c);return b};EditorUi.prototype.addBasenamesForCell=function(a,b){function c(a){if(null!=a){var c=a.lastIndexOf(".");0<c&&(a=a.substring(c+1,a.length));null==b[a]&&(b[a]=!0)}}var d=this.editor.graph,e=d.getCellStyle(a);c(mxStencilRegistry.getBasenameForStencil(e[mxConstants.STYLE_SHAPE]));d.model.isEdge(a)&&(c(mxMarker.getPackageForType(e[mxConstants.STYLE_STARTARROW])),c(mxMarker.getPackageForType(e[mxConstants.STYLE_ENDARROW])));for(var e=d.model.getChildCount(a),
+f=0;f<e;f++)this.addBasenamesForCell(d.model.getChildAt(a,f),b)};EditorUi.prototype.setGraphEnabled=function(a){this.diagramContainer.style.visibility=a?"":"hidden";this.formatContainer.style.visibility=a?"":"hidden";this.sidebarFooterContainer.style.display=a?"":"none";this.sidebarContainer.style.display=a?"":"none";this.hsplit.style.display=a?"":"none";this.editor.graph.setEnabled(a)};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,c){this.spinner.stop();this.addEmbedButtons();this.setGraphEnabled(!0);null!=a&&0<a.length?(this.setFileData(a),this.showLayersDialog()):(this.editor.graph.model.clear(),this.editor.fireEvent(new mxEventObject("resetGraphView")));this.editor.undoManager.clear();this.editor.modified=null!=c?c:!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 b=this.editor.graph;return{event:a,pageVisible:b.pageVisible,translate:b.view.translate,
+scale:b.view.scale,page:b.view.getBackgroundPageBounds(),bounds:b.getGraphBounds()}};EditorUi.prototype.installMessageHandler=function(a){var b=null,c=!1,d=!1,e=null,f=mxUtils.bind(this,function(a,b){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,f);mxEvent.addListener(window,"message",mxUtils.bind(this,function(f){function k(a){if(null!=
+a&&"function"===typeof a.charAt&&"<"!=a.charAt(0))try{"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=this.editor.graph.decompress(a)))}catch(I){}return a}var l=f.data;if("json"==urlParams.proto){try{l=JSON.parse(l)}catch(E){l=null}if(null==l)return;if("dialog"==l.action){this.showError(null!=l.titleKey?mxResources.get(l.titleKey):l.title,
+null!=l.messageKey?mxResources.get(l.messageKey):l.message,null!=l.buttonKey?mxResources.get(l.buttonKey):l.button);null!=l.modified&&(this.editor.modified=l.modified);return}if("prompt"==l.action){this.spinner.stop();var m=new FilenameDialog(this,l.defaultValue||"",null!=l.okKey?mxResources.get(l.okKey):null,function(a){null!=a&&g.postMessage(JSON.stringify({event:"prompt",value:a,message:l}),"*")},null!=l.titleKey?mxResources.get(l.titleKey):l.title);this.showDialog(m.container,300,80,!0,!1);m.init();
+return}if("draft"==l.action){m=null;m="data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):k(l.xml);this.spinner.stop();m=new DraftDialog(this,mxResources.get("draftFound",[l.name||this.defaultFilename]),m,mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"edit",message:l}),"*")}),mxUtils.bind(this,function(){this.hideDialog();g.postMessage(JSON.stringify({event:"draft",result:"discard",message:l}),"*")}),l.editKey?mxResources.get(l.editKey):
+null,l.discardKey?mxResources.get(l.discardKey):null);this.showDialog(m.container,640,480,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));try{m.init()}catch(E){g.postMessage(JSON.stringify({event:"draft",error:E.toString(),message:l}),"*")}return}if("template"==l.action){this.spinner.stop();m=new NewDialog(this,!1,null!=l.callback,mxUtils.bind(this,function(b,c){b=b||this.emptyDiagramXml;null!=l.callback?g.postMessage(JSON.stringify({event:"template",xml:b,blank:b==this.emptyDiagramXml,
+name:c}),"*"):(a(b,f,b!=this.emptyDiagramXml),this.editor.modified||this.editor.setStatus(""))}));this.showDialog(m.container,620,440,!0,!1,mxUtils.bind(this,function(a){a&&this.actions.get("exit").funct()}));m.init();return}if("status"==l.action){null!=l.messageKey?this.editor.setStatus(mxUtils.htmlEntities(mxResources.get(l.messageKey))):null!=l.message&&this.editor.setStatus(mxUtils.htmlEntities(l.message));null!=l.modified&&(this.editor.modified=l.modified);return}if("spinner"==l.action){var n=
+null!=l.messageKey?mxResources.get(l.messageKey):l.message;null==l.show||l.show?this.spinner.spin(document.body,n):this.spinner.stop();return}if("export"==l.action){if("png"==l.format||"xmlpng"==l.format){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin)){var p=null!=l.xml?l.xml:this.getFileData(!0);this.editor.graph.setEnabled(!1);var q=this.editor.graph,t=mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();
+var b=this.createLoadMessage("export");b.format=l.format;b.xml=encodeURIComponent(p);b.data=a;g.postMessage(JSON.stringify(b),"*")}),r=mxUtils.bind(this,function(a){null==a&&(a=Editor.blankImage);"xmlpng"==l.format&&(a=this.writeGraphModelToPng(a,"zTXt","mxGraphModel",atob(this.editor.graph.compress(p))));q!=this.editor.graph&&q.container.parentNode.removeChild(q.container);t(a)});if(this.isExportToCanvas()){if(null!=this.pages&&this.currentPage!=this.pages[0]){var q=this.createTemporaryGraph(q.getStylesheet()),
+F=q.getGlobalVariable,C=this.pages[0];q.getGlobalVariable=function(a){return"page"==a?C.getName():"pagenumber"==a?1:F.apply(this,arguments)};document.body.appendChild(q.container);q.model.setRoot(C.root)}this.exportToCanvas(mxUtils.bind(this,function(a){r(a.toDataURL("image/png"))}),null,null,null,mxUtils.bind(this,function(){r(null)}),null,null,null,null,null,null,q)}else(new mxXmlRequest(EXPORT_URL,"format=png&embedXml="+("xmlpng"==l.format?"1":"0")+"&base64=1&xml="+encodeURIComponent(encodeURIComponent(p)))).send(mxUtils.bind(this,
+function(a){200<=a.getStatus()&&299>=a.getStatus()?t("data:image/png;base64,"+a.getText()):r(null)}),mxUtils.bind(this,function(){r(null)}))}}else{null!=l.xml&&0<l.xml.length&&this.setFileData(l.xml);n=this.createLoadMessage("export");if("html2"==l.format||"html"==l.format&&("0"!=urlParams.pages||null!=this.pages&&1<this.pages.length))m=this.getXmlFileData(),n.xml=mxUtils.getXml(m),n.data=this.getFileData(null,null,!0,null,null,null,m),n.format=l.format;else if("html"==l.format)p=this.editor.getGraphXml(),
+n.data=this.getHtml(p,this.editor.graph),n.xml=mxUtils.getXml(p),n.format=l.format;else{mxSvgCanvas2D.prototype.foAltText=null;m=this.editor.graph.background;m==mxConstants.NONE&&(m=null);n.xml=this.getFileData(!0);n.format="svg";if(l.embedImages||null==l.embedImages){if(null==l.spin&&null==l.spinKey||this.spinner.spin(document.body,null!=l.spinKey?mxResources.get(l.spinKey):l.spin))this.editor.graph.setEnabled(!1),"xmlsvg"==l.format?this.getEmbeddedSvg(n.xml,this.editor.graph,null,!0,mxUtils.bind(this,
+function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(a);g.postMessage(JSON.stringify(n),"*")})):this.convertImages(this.editor.graph.getSvg(m),mxUtils.bind(this,function(a){this.editor.graph.setEnabled(!0);this.spinner.stop();n.data=this.createSvgDataUri(mxUtils.getXml(a));g.postMessage(JSON.stringify(n),"*")}));return}m="xmlsvg"==l.format?this.getEmbeddedSvg(this.getFileData(!0),this.editor.graph,null,!0):mxUtils.getXml(this.editor.graph.getSvg(m));n.data=
+this.createSvgDataUri(m)}g.postMessage(JSON.stringify(n),"*")}return}if("load"==l.action)d=1==l.autosave,this.hideDialog(),null!=l.modified&&null==urlParams.modified&&(urlParams.modified=l.modified),null!=l.saveAndExit&&null==urlParams.saveAndExit&&(urlParams.saveAndExit=l.saveAndExit),null!=l.title&&null!=this.buttonContainer&&(m=document.createElement("span"),mxUtils.write(m,l.title),"atlas"==uiTheme?(this.buttonContainer.style.paddingRight="12px",this.buttonContainer.style.paddingTop="12px"):(this.buttonContainer.style.paddingRight=
+"38px",this.buttonContainer.style.paddingTop="6px"),this.buttonContainer.appendChild(m)),l=null!=l.xmlpng?this.extractGraphModelFromPng(l.xmlpng):null!=l.xml&&"data:image/png;base64,"==l.xml.substring(0,22)?this.extractGraphModelFromPng(l.xml):l.xml;else{g.postMessage(JSON.stringify({error:"unknownMessage",data:JSON.stringify(l)}),"*");return}}l=k(l);c=!0;try{a(l,f)}catch(E){this.handleError(E)}c=!1;null!=urlParams.modified&&this.editor.setStatus("");var H=mxUtils.bind(this,function(){return"0"!=
+urlParams.pages||null!=this.pages&&1<this.pages.length?this.getFileData(!0):mxUtils.getXml(this.editor.getGraphXml())});e=H();d&&null==b&&(b=mxUtils.bind(this,function(a,b){var d=H();if(d!=e&&!c){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,b),this.editor.graph.addListener("gridSizeChanged",b),this.editor.graph.addListener("shadowVisibleChanged",b),this.addListener("pageFormatChanged",
+b),this.addListener("pageScaleChanged",b),this.addListener("backgroundColorChanged",b),this.addListener("backgroundImageChanged",b),this.addListener("foldingEnabledChanged",b),this.addListener("mathEnabledChanged",b),this.addListener("gridEnabledChanged",b),this.addListener("guidesEnabledChanged",b),this.addListener("pageViewChanged",b));"1"!=urlParams.returnbounds&&"json"!=urlParams.proto||g.postMessage(JSON.stringify(this.createLoadMessage("load")),"*")}));var g=window.opener||window.parent,f="json"==
+urlParams.proto?JSON.stringify({event:"init"}):urlParams.ready||"ready";g.postMessage(f,"*")};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":"3px";a.style.paddingLeft="8px";a.style.paddingBottom="2px";var b=document.createElement("button");mxUtils.write(b,mxResources.get("save"));b.setAttribute("title",mxResources.get("save")+" (Ctrl+S)");b.className=
+"geBigButton";b.style.fontSize="12px";b.style.padding="4px 6px 4px 6px";b.style.borderRadius="3px";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.style.fontSize="12px",b.style.marginLeft="6px",b.style.padding="4px",b.style.cursor="pointer",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.style.fontSize="12px";b.style.marginLeft="6px";b.style.marginRight="20px";b.style.padding="4px";b.style.cursor="pointer";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.showDialog(this.importCsvDialog.container,640,520,!0,!0);this.importCsvDialog.init()};EditorUi.prototype.importCsv=function(a){try{var b=a.split("\n"),c=[];if(0<b.length){var d={},e=
+null,f=null,g="auto",k="auto",u=40,x=40,z=0,y=this.editor.graph;y.getGraphBounds();for(var A=function(){y.setSelectionCells(N);y.scrollCellToVisible(y.getSelectionCell())},v=y.getFreeInsertPoint(),B=v.x,G=v.y,v=G,F=null,C="auto",H=[],E=null,I=null,M=0;M<b.length&&"#"==b[M].charAt(0);){a=b[M];for(M++;M<b.length&&"\\"==a.charAt(a.length-1)&&"#"==b[M].charAt(0);)a=a.substring(0,a.length-1)+mxUtils.trim(b[M].substring(1)),M++;if("#"!=a.charAt(1)){var L=a.indexOf(":");if(0<L){var V=mxUtils.trim(a.substring(1,
+L)),P=mxUtils.trim(a.substring(L+1));"label"==V?F=y.sanitizeHtml(P):"style"==V?e=P:"identity"==V&&0<P.length&&"-"!=P?f=P:"width"==V?g=P:"height"==V?k=P:"ignore"==V?I=P.split(","):"connect"==V?H.push(JSON.parse(P)):"link"==V?E=P:"padding"==V?z=parseFloat(P):"edgespacing"==V?u=parseFloat(P):"nodespacing"==V?x=parseFloat(P):"layout"==V&&(C=P)}}}var ba=this.editor.csvToArray(b[M]);a=null;if(null!=f)for(var T=0;T<ba.length;T++)if(f==ba[T]){a=T;break}null==F&&(F="%"+ba[0]+"%");if(null!=H)for(var D=0;D<
+H.length;D++)null==d[H[D].to]&&(d[H[D].to]={});y.model.beginUpdate();try{for(T=M+1;T<b.length;T++){var X=this.editor.csvToArray(b[T]);if(X.length==ba.length){var Q=null,J=null!=a?X[a]:null;null!=J&&(Q=y.model.getCell(J));null==Q&&(Q=new mxCell(F,new mxGeometry(B,v,0,0),e||"whiteSpace=wrap;html=1;"),Q.vertex=!0,Q.id=J);for(var Y=0;Y<X.length;Y++)y.setAttributeForCell(Q,ba[Y],X[Y]);y.setAttributeForCell(Q,"placeholders","1");Q.style=y.replacePlaceholders(Q,Q.style);for(D=0;D<H.length;D++)d[H[D].to][Q.getAttribute(H[D].to)]=
+Q;null!=E&&"link"!=E&&(y.setLinkForCell(Q,Q.getAttribute(E)),y.setAttributeForCell(Q,E,null));var O=this.editor.graph.getPreferredSizeForCell(Q);Q.geometry.width="auto"==g?O.width+z:parseFloat(g);Q.geometry.height="auto"==k?O.height+z:parseFloat(k);v+=Q.geometry.height+x;c.push(y.addCell(Q))}}null==e&&y.fireEvent(new mxEventObject("cellsInserted","cells",c));for(var K=c.slice(),N=c.slice(),D=0;D<H.length;D++)for(var U=H[D],T=0;T<c.length;T++){var Q=c[T],ca=Q.getAttribute(U.from);if(null!=ca){y.setAttributeForCell(Q,
+U.from,null);for(var Z=ca.split(","),Y=0;Y<Z.length;Y++){var R=d[U.to][Z[Y]];null!=R&&(N.push(y.insertEdge(null,null,U.label||"",U.invert?R:Q,U.invert?Q:R,U.style||y.createCurrentEdgeStyle())),mxUtils.remove(U.invert?Q:R,K))}}}if(null!=I)for(T=0;T<c.length;T++)for(Q=c[T],Y=0;Y<I.length;Y++)y.setAttributeForCell(Q,mxUtils.trim(I[Y]),null);var aa=new mxParallelEdgeLayout(y);aa.spacing=u;var da=function(){aa.execute(y.getDefaultParent());for(var a=0;a<c.length;a++){var b=y.getCellGeometry(c[a]);b.x=
+Math.round(y.snap(b.x));b.y=Math.round(y.snap(b.y));"auto"==g&&(b.width=Math.round(y.snap(b.width)));"auto"==k&&(b.height=Math.round(y.snap(b.height)))}};if("circle"==C){var S=new mxCircleLayout(y);S.resetEdges=!1;var W=S.isVertexIgnored;S.isVertexIgnored=function(a){return W.apply(this,arguments)||0>mxUtils.indexOf(c,a)};this.executeLayout(function(){S.execute(y.getDefaultParent());da()},!0,A);A=null}else if("horizontaltree"==C||"verticaltree"==C||"auto"==C&&N.length==2*c.length-1&&1==K.length){y.view.validate();
+var ga=new mxCompactTreeLayout(y,"horizontaltree"==C);ga.levelDistance=x;ga.edgeRouting=!1;ga.resetEdges=!1;this.executeLayout(function(){ga.execute(y.getDefaultParent(),0<K.length?K[0]:null)},!0,A);A=null}else if("horizontalflow"==C||"verticalflow"==C||"auto"==C&&1==K.length){y.view.validate();var ea=new mxHierarchicalLayout(y,"horizontalflow"==C?mxConstants.DIRECTION_WEST:mxConstants.DIRECTION_NORTH);ea.intraCellSpacing=x;ea.disableEdgeStyle=!1;this.executeLayout(function(){ea.execute(y.getDefaultParent(),
+N);y.moveCells(N,B,G)},!0,A);A=null}else if("organic"==C||"auto"==C&&N.length>c.length){y.view.validate();var ha=new mxFastOrganicLayout(y);ha.forceConstant=3*x;ha.resetEdges=!1;var la=ha.isVertexIgnored;ha.isVertexIgnored=function(a){return la.apply(this,arguments)||0>mxUtils.indexOf(c,a)};aa=new mxParallelEdgeLayout(y);aa.spacing=u;this.executeLayout(function(){ha.execute(y.getDefaultParent());da()},!0,A);A=null}this.hideDialog()}finally{y.model.endUpdate()}null!=A&&A()}}catch(ma){this.handleError(ma)}};
+EditorUi.prototype.getSearch=function(a){var b="";if("1"!=urlParams.offline&&"1"!=urlParams.demo&&null!=a&&0<window.location.search.length){var c="?",d;for(d in urlParams)0>mxUtils.indexOf(a,d)&&null!=urlParams[d]&&(b+=c+d+"="+urlParams[d],c="&")}else b=window.location.search;return b};EditorUi.prototype.getUrl=function(a){a=null!=a?a:window.location.pathname;var b=0<a.indexOf("?")?1:0;if("1"==urlParams.offline)a+=window.location.search;else{var c="tmp libs clibs state fileId code share notitle data url embed client create title splash".split(" "),
 d;for(d in urlParams)0>mxUtils.indexOf(c,d)&&(a=0==b?a+"?":a+"&",null!=urlParams[d]&&(a+=d+"="+urlParams[d],b++))}return a};EditorUi.prototype.showLinkDialog=function(a,b,c){a=new LinkDialog(this,a,b,c,!0);this.showDialog(a.container,420,120,!0,!0);a.init()};var f=EditorUi.prototype.createOutline;EditorUi.prototype.createOutline=function(a){var b=f.apply(this,arguments),c=this.editor.graph,d=b.getSourceGraphBounds;b.getSourceGraphBounds=function(){if(mxUtils.hasScrollbars(c.container)&&c.pageVisible&&
 null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width-2*a.x/b),Math.ceil(this.source.minimumGraphSize.height-2*a.y/b))}return d.apply(this,arguments)};var e=b.getSourceContainerSize;b.getSourceContainerSize=function(){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var a=this.source.getPagePadding(),b=this.source.view.scale;return new mxRectangle(0,0,Math.ceil(this.source.minimumGraphSize.width*
 b-2*a.x),Math.ceil(this.source.minimumGraphSize.height*b-2*a.y))}return e.apply(this,arguments)};b.getOutlineOffset=function(a){if(mxUtils.hasScrollbars(c.container)&&null!=this.source.minimumGraphSize){var d=this.source.getPagePadding();return new mxPoint(Math.round(Math.max(0,(b.outline.container.clientWidth/a-(this.source.minimumGraphSize.width-2*d.x))/2)-d.x),Math.round(Math.max(0,(b.outline.container.clientHeight/a-(this.source.minimumGraphSize.height-2*d.y))/2)-d.y-5/a))}return new mxPoint(8/
@@ -2910,7 +2915,7 @@ var c=("1"!=urlParams.embed||!this.editor.graph.isEnabled())&&(null==a||a.isRest
 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.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));
 if(this.isOfflineApp()){var d=applicationCache;if(null!=d&&null==this.offlineStatus){this.offlineStatus=document.createElement("div");this.offlineStatus.className="geItem";this.offlineStatus.style.position="absolute";this.offlineStatus.style.fontSize="8pt";this.offlineStatus.style.top="2px";this.offlineStatus.style.right="12px";this.offlineStatus.style.color="#666";this.offlineStatus.style.margin="4px";this.offlineStatus.style.padding="2px";this.offlineStatus.style.verticalAlign="middle";this.offlineStatus.innerHTML=
 "";this.menubarContainer.appendChild(this.offlineStatus);mxEvent.addListener(this.offlineStatus,"click",mxUtils.bind(this,function(){var a=this.offlineStatus.getElementsByTagName("img");null!=a&&0<a.length&&this.alert(a[0].getAttribute("title"))}));var d=window.applicationCache,e=null,b=mxUtils.bind(this,function(){var a=d.status,b;a==d.CHECKING&&(a=d.DOWNLOADING);switch(a){case d.UNCACHED:b="";break;case d.IDLE:b='<img title="draw.io is up to date." border="0" src="'+IMAGE_PATH+'/checkmark.gif"/>';
-break;case d.DOWNLOADING:b='<img title="Downloading new version" border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
+break;case d.DOWNLOADING:b='<img title="Downloading new version..." border="0" src="'+IMAGE_PATH+'/spin.gif"/>';break;case d.UPDATEREADY:b='<img title="'+mxUtils.htmlEntities(mxResources.get("restartForChangeRequired"))+'" border="0" src="'+IMAGE_PATH+'/download.png"/>';break;case d.OBSOLETE:b='<img title="Obsolete" border="0" src="'+IMAGE_PATH+'/clear.gif"/>';break;default:b='<img title="Unknown" border="0" src="'+IMAGE_PATH+'/clear.gif"/>'}a!=e&&(this.offlineStatus.innerHTML=b,e=a)});mxEvent.addListener(d,
 "checking",b);mxEvent.addListener(d,"noupdate",b);mxEvent.addListener(d,"downloading",b);mxEvent.addListener(d,"progress",b);mxEvent.addListener(d,"cached",b);mxEvent.addListener(d,"updateready",b);mxEvent.addListener(d,"obsolete",b);mxEvent.addListener(d,"error",b);b()}}else this.updateUserElement()};EditorUi.prototype.updateButtonContainer=function(){};EditorUi.prototype.updateUserElement=function(){};var g=EditorUi.prototype.updateActionStates;EditorUi.prototype.updateActionStates=function(){g.apply(this,
 arguments);var a=this.editor.graph,b=this.getCurrentFile(),c=null!=b&&b.isEditable()||"1"==urlParams.embed&&this.editor.graph.isEnabled();this.actions.get("pageSetup").setEnabled(c);this.actions.get("autosave").setEnabled(null!=b&&b.isEditable()&&b.isAutosaveOptional());this.actions.get("guides").setEnabled(c);this.actions.get("shadowVisible").setEnabled(c);this.actions.get("connectionArrows").setEnabled(c);this.actions.get("connectionPoints").setEnabled(c);this.actions.get("copyStyle").setEnabled(c&&
 !a.isSelectionEmpty());this.actions.get("pasteStyle").setEnabled(c&&!a.isSelectionEmpty());this.actions.get("editGeometry").setEnabled(a.getModel().isVertex(a.getSelectionCell()));this.actions.get("createShape").setEnabled(c);this.actions.get("createRevision").setEnabled(c);this.actions.get("moveToFolder").setEnabled(null!=b);this.actions.get("makeCopy").setEnabled(null!=b&&!b.isRestricted());this.actions.get("editDiagram").setEnabled("1"==urlParams.embed&&this.editor.graph.isEnabled()||null!=b&&
diff --git a/war/js/vsdx.min.js b/war/js/vsdx.min.js
index b4c65e353a76583d76fbd248e2429e0af2f5dda5..d022108c0644e6d66c730ca27cd5620ff092d7a1 100644
--- a/war/js/vsdx.min.js
+++ b/war/js/vsdx.min.js
@@ -8,240 +8,240 @@ Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/js
 JSZip uses the library pako released under the MIT license :
 https://github.com/nodeca/pako/blob/master/LICENSE
 */
-!function(w){"object"==typeof exports&&"undefined"!=typeof module?module.exports=w():"function"==typeof define&&define.amd?define([],w):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).JSZip=w()}(function(){return function b(f,c,a){function e(g,l){if(!c[g]){if(!f[g]){var h="function"==typeof require&&require;if(!l&&h)return h(g,!0);if(d)return d(g,!0);h=Error("Cannot find module '"+g+"'");throw h.code="MODULE_NOT_FOUND",h;}h=c[g]={exports:{}};
-f[g][0].call(h.exports,function(d){var a=f[g][1][d];return e(a?a:d)},h,h.exports,b,f,c,a)}return c[g].exports}for(var d="function"==typeof require&&require,g=0;g<a.length;g++)e(a[g]);return e}({1:[function(b,f,c){var a=b("./utils"),e=b("./support");c.encode=function(d){for(var e,b,c,n,q,u,y,F=[],f=0,H=d.length,v="string"!==a.getTypeOf(d);f<d.length;)y=H-f,v?(e=d[f++],b=f<H?d[f++]:0,c=f<H?d[f++]:0):(e=d.charCodeAt(f++),b=f<H?d.charCodeAt(f++):0,c=f<H?d.charCodeAt(f++):0),n=e>>2,q=(3&e)<<4|b>>4,u=1<
-y?(15&b)<<2|c>>6:64,y=2<y?63&c:64,F.push("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(n)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(q)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(u)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(y));return F.join("")};c.decode=function(d){var a,b,c,n,q,u=0,y=0;if("data:"===d.substr(0,5))throw Error("Invalid base64 input, it looks like a data url.");
-d=d.replace(/[^A-Za-z0-9\+\/\=]/g,"");n=3*d.length/4;if("="===d.charAt(d.length-1)&&n--,"="===d.charAt(d.length-2)&&n--,0!==n%1)throw Error("Invalid base64 input, bad content length.");var F;for(F=e.uint8array?new Uint8Array(0|n):Array(0|n);u<d.length;)a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(d.charAt(u++)),b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(d.charAt(u++)),n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(d.charAt(u++)),
-q="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(d.charAt(u++)),a=a<<2|b>>4,b=(15&b)<<4|n>>2,c=(3&n)<<6|q,F[y++]=a,64!==n&&(F[y++]=b),64!==q&&(F[y++]=c);return F}},{"./support":30,"./utils":32}],2:[function(b,f,c){function a(a,d,b,e,g){this.compressedSize=a;this.uncompressedSize=d;this.crc32=b;this.compression=e;this.compressedContent=g}var e=b("./external"),d=b("./stream/DataWorker"),g=b("./stream/DataLengthProbe"),h=b("./stream/Crc32Probe"),g=b("./stream/DataLengthProbe");
-a.prototype={getContentWorker:function(){var a=(new d(e.Promise.resolve(this.compressedContent))).pipe(this.compression.uncompressWorker()).pipe(new g("data_length")),b=this;return a.on("end",function(){if(this.streamInfo.data_length!==b.uncompressedSize)throw Error("Bug : uncompressed data size mismatch");}),a},getCompressedWorker:function(){return(new d(e.Promise.resolve(this.compressedContent))).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",
-this.crc32).withStreamInfo("compression",this.compression)}};a.createWorkerFrom=function(a,d,b){return a.pipe(new h).pipe(new g("uncompressedSize")).pipe(d.compressWorker(b)).pipe(new g("compressedSize")).withStreamInfo("compression",d)};f.exports=a},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(b,f,c){var a=b("./stream/GenericWorker");c.STORE={magic:"\x00\x00",compressWorker:function(b){return new a("STORE compression")},uncompressWorker:function(){return new a("STORE decompression")}};
-c.DEFLATE=b("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(b,f,c){var a=b("./utils"),e=function(){for(var a,b=[],e=0;256>e;e++){a=e;for(var c=0;8>c;c++)a=1&a?3988292384^a>>>1:a>>>1;b[e]=a}return b}();f.exports=function(d,b){if("undefined"==typeof d||!d.length)return 0;var g;if("string"!==a.getTypeOf(d)){var c=0+d.length;g=(0|b)^-1;for(var n=0;n<c;n++)g=g>>>8^e[255&(g^d[n])]}else for(c=0+d.length,g=(0|b)^-1,n=0;n<c;n++)g=g>>>8^e[255&(g^d.charCodeAt(n))];return g^=-1}},{"./utils":32}],
-5:[function(b,f,c){c.base64=!1;c.binary=!1;c.dir=!1;c.createFolders=!0;c.date=null;c.compression=null;c.compressionOptions=null;c.comment=null;c.unixPermissions=null;c.dosPermissions=null},{}],6:[function(b,f,c){b="undefined"!=typeof Promise?Promise:b("lie");f.exports={Promise:b}},{lie:58}],7:[function(b,f,c){function a(a,d){g.call(this,"FlateWorker/"+a);this._pako=new e[a]({raw:!0,level:d.level||-1});this.meta={};var b=this;this._pako.onData=function(a){b.push({data:a,meta:b.meta})}}f="undefined"!=
-typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array;var e=b("pako"),d=b("./utils"),g=b("./stream/GenericWorker"),h=f?"uint8array":"array";c.magic="\b\x00";d.inherits(a,g);a.prototype.processChunk=function(a){this.meta=a.meta;this._pako.push(d.transformTo(h,a.data),!1)};a.prototype.flush=function(){g.prototype.flush.call(this);this._pako.push([],!0)};a.prototype.cleanUp=function(){g.prototype.cleanUp.call(this);this._pako=null};c.compressWorker=function(d){return new a("Deflate",
-d)};c.uncompressWorker=function(){return new a("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:59}],8:[function(b,f,c){function a(a,b,e,g){d.call(this,"ZipFileWorker");this.bytesWritten=0;this.zipComment=b;this.zipPlatform=e;this.encodeFileName=g;this.streamFiles=a;this.accumulate=!1;this.contentBuffer=[];this.dirRecords=[];this.entriesCount=this.currentSourceOffset=0;this.currentFile=null;this._sources=[]}var e=b("../utils"),d=b("../stream/GenericWorker"),g=b("../utf8"),h=b("../crc32"),
-l=b("../signature"),n=function(a,d){var b,e="";for(b=0;b<d;b++)e+=String.fromCharCode(255&a),a>>>=8;return e},q=function(a,d,b,c,v,u){var t,y;t=a.file;var H=a.compression,z=u!==g.utf8encode,q=e.transformTo("string",u(t.name)),p=e.transformTo("string",g.utf8encode(t.name)),f=t.comment;u=e.transformTo("string",u(f));var x=e.transformTo("string",g.utf8encode(f)),F=p.length!==t.name.length,D=x.length!==f.length,G=f="",X="";y=t.dir;var T=t.date,aa=0,V=0,r=0;d&&!b||(aa=a.crc32,V=a.compressedSize,r=a.uncompressedSize);
-a=0;d&&(a|=8);z||!F&&!D||(a|=2048);d=0;y&&(d|=16);"UNIX"===v?(v=798,t=z=t.unixPermissions,y=(z||(t=y?16893:33204),(65535&t)<<16),d|=y):(v=20,d|=63&(t.dosPermissions||0));t=T.getUTCHours();t=t<<6|T.getUTCMinutes();t=t<<5|T.getUTCSeconds()/2;y=T.getUTCFullYear()-1980;y=y<<4|T.getUTCMonth()+1;y=y<<5|T.getUTCDate();F&&(G=n(1,1)+n(h(q),4)+p,f+="up"+n(G.length,2)+G);D&&(X=n(1,1)+n(h(u),4)+x,f+="uc"+n(X.length,2)+X);p="\n\x00"+n(a,2);p+=H.magic;p+=n(t,2);p+=n(y,2);p+=n(aa,4);p+=n(V,4);p+=n(r,4);p+=n(q.length,
-2);p+=n(f.length,2);H=l.LOCAL_FILE_HEADER+p+q+f;c=l.CENTRAL_FILE_HEADER+n(v,2)+p+n(u.length,2)+"\x00\x00\x00\x00"+n(d,4)+n(c,4)+q+f+u;return{fileRecord:H,dirRecord:c}},u=function(a){return l.DATA_DESCRIPTOR+n(a.crc32,4)+n(a.compressedSize,4)+n(a.uncompressedSize,4)};e.inherits(a,d);a.prototype.push=function(a){var b=a.meta.percent||0,e=this.entriesCount,g=this._sources.length;this.accumulate?this.contentBuffer.push(a):(this.bytesWritten+=a.data.length,d.prototype.push.call(this,{data:a.data,meta:{currentFile:this.currentFile,
-percent:e?(b+100*(e-g-1))/e:100}}))};a.prototype.openedSource=function(a){this.currentSourceOffset=this.bytesWritten;this.currentFile=a.file.name;var d=this.streamFiles&&!a.file.dir;d?(a=q(a,d,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName),this.push({data:a.fileRecord,meta:{percent:0}})):this.accumulate=!0};a.prototype.closedSource=function(a){this.accumulate=!1;var d=this.streamFiles&&!a.file.dir,b=q(a,d,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(b.dirRecord),
-d)this.push({data:u(a),meta:{percent:100}});else for(this.push({data:b.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null};a.prototype.flush=function(){for(var a=this.bytesWritten,d=0;d<this.dirRecords.length;d++)this.push({data:this.dirRecords[d],meta:{percent:100}});var d=this.dirRecords.length,b=this.bytesWritten-a,g=e.transformTo("string",(0,this.encodeFileName)(this.zipComment)),a=l.CENTRAL_DIRECTORY_END+"\x00\x00\x00\x00"+n(d,
-2)+n(d,2)+n(b,4)+n(a,4)+n(g.length,2)+g;this.push({data:a,meta:{percent:100}})};a.prototype.prepareNextSource=function(){this.previous=this._sources.shift();this.openedSource(this.previous.streamInfo);this.isPaused?this.previous.pause():this.previous.resume()};a.prototype.registerPrevious=function(a){this._sources.push(a);var d=this;return a.on("data",function(a){d.processChunk(a)}),a.on("end",function(){d.closedSource(d.previous.streamInfo);d._sources.length?d.prepareNextSource():d.end()}),a.on("error",
-function(a){d.error(a)}),this};a.prototype.resume=function(){return!!d.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))};a.prototype.error=function(a){var b=this._sources;if(!d.prototype.error.call(this,a))return!1;for(var e=0;e<b.length;e++)try{b[e].error(a)}catch(H){}return!0};a.prototype.lock=function(){d.prototype.lock.call(this);for(var a=this._sources,b=0;b<a.length;b++)a[b].lock()};
-f.exports=a},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(b,f,c){var a=b("../compressions"),e=b("./ZipFileWorker");c.generateWorker=function(d,b,c){var g=new e(b.streamFiles,c,b.platform,b.encodeFileName),h=0;try{d.forEach(function(d,e){h++;var c=e.options.compression||b.compression,u=a[c];if(!u)throw Error(c+" is not a valid compression method !");var c=e.dir,n=e.date;e._compressWorker(u,e.options.compressionOptions||b.compressionOptions||
-{}).withStreamInfo("file",{name:d,dir:c,date:n,comment:e.comment||"",unixPermissions:e.unixPermissions,dosPermissions:e.dosPermissions}).pipe(g)}),g.entriesCount=h}catch(q){g.error(q)}return g}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(b,f,c){function a(){if(!(this instanceof a))return new a;if(arguments.length)throw Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files={};this.comment=null;this.root="";this.clone=function(){var b=
-new a,d;for(d in this)"function"!=typeof this[d]&&(b[d]=this[d]);return b}}a.prototype=b("./object");a.prototype.loadAsync=b("./load");a.support=b("./support");a.defaults=b("./defaults");a.version="3.1.3";a.loadAsync=function(b,d){return(new a).loadAsync(b,d)};a.external=b("./external");f.exports=a},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(b,f,c){function a(a){return new d.Promise(function(d,b){var e=a.decompressed.getContentWorker().pipe(new l);e.on("error",
-function(a){b(a)}).on("end",function(){e.streamInfo.crc32!==a.decompressed.crc32?b(Error("Corrupted zip : CRC32 mismatch")):d()}).resume()})}var e=b("./utils"),d=b("./external"),g=b("./utf8"),e=b("./utils"),h=b("./zipEntries"),l=b("./stream/Crc32Probe"),n=b("./nodejsUtils");f.exports=function(b,c){var u=this;return c=e.extend(c||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:g.utf8decode}),n.isNode&&n.isStream(b)?d.Promise.reject(Error("JSZip can't accept a stream when loading a zip file.")):
-e.prepareContent("the loaded zip file",b,!0,c.optimizedBinaryString,c.base64).then(function(a){var d=new h(c);return d.load(a),d}).then(function(b){var e=[d.Promise.resolve(b)];b=b.files;if(c.checkCRC32)for(var g=0;g<b.length;g++)e.push(a(b[g]));return d.Promise.all(e)}).then(function(a){a=a.shift();for(var d=a.files,b=0;b<d.length;b++){var e=d[b];u.file(e.fileNameStr,e.decompressed,{binary:!0,optimizedBinaryString:!0,date:e.date,dir:e.dir,comment:e.fileCommentStr.length?e.fileCommentStr:null,unixPermissions:e.unixPermissions,
-dosPermissions:e.dosPermissions,createFolders:c.createFolders})}return a.zipComment.length&&(u.comment=a.zipComment),u})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(b,f,c){function a(a,b){e.call(this,"Nodejs stream input adapter for "+a);this._upstreamEnded=!1;this._bindStream(b)}c=b("../utils");var e=b("../stream/GenericWorker");c.inherits(a,e);a.prototype._bindStream=function(a){var d=this;this._stream=a;a.pause();a.on("data",
-function(a){d.push({data:a,meta:{percent:0}})}).on("error",function(a){d.isPaused?this.generatedError=a:d.error(a)}).on("end",function(){d.isPaused?d._upstreamEnded=!0:d.end()})};a.prototype.pause=function(){return!!e.prototype.pause.call(this)&&(this._stream.pause(),!0)};a.prototype.resume=function(){return!!e.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)};f.exports=a},{"../stream/GenericWorker":28,"../utils":32}],13:[function(b,f,c){function a(a,b,c){e.call(this,
-b);this._helper=a;var d=this;a.on("data",function(a,b){d.push(a)||d._helper.pause();c&&c(b)}).on("error",function(a){d.emit("error",a)}).on("end",function(){d.push(null)})}var e=b("readable-stream").Readable;b("util").inherits(a,e);a.prototype._read=function(){this._helper.resume()};f.exports=a},{"readable-stream":16,util:void 0}],14:[function(b,f,c){f.exports={isNode:"undefined"!=typeof Buffer,newBuffer:function(a,b){return new Buffer(a,b)},isBuffer:function(a){return Buffer.isBuffer(a)},isStream:function(a){return a&&
-"function"==typeof a.on&&"function"==typeof a.pause&&"function"==typeof a.resume}}},{}],15:[function(b,f,c){var a=b("./utf8"),e=b("./utils"),d=b("./stream/GenericWorker"),g=b("./stream/StreamHelper"),h=b("./defaults"),l=b("./compressedObject"),n=b("./zipObject"),q=b("./generate"),u=b("./nodejsUtils"),y=b("./nodejs/NodejsStreamInputAdapter"),F=function(a,b,t){var v,g=e.getTypeOf(b),c=e.extend(t||{},h);c.date=c.date||new Date;null!==c.compression&&(c.compression=c.compression.toUpperCase());"string"==
-typeof c.unixPermissions&&(c.unixPermissions=parseInt(c.unixPermissions,8));c.unixPermissions&&16384&c.unixPermissions&&(c.dir=!0);c.dosPermissions&&16&c.dosPermissions&&(c.dir=!0);c.dir&&(a=D(a));var f;if(f=c.createFolders)v=a,"/"===v.slice(-1)&&(v=v.substring(0,v.length-1)),f=v.lastIndexOf("/"),f=v=0<f?v.substring(0,f):"";f&&H.call(this,v,!0);g="string"===g&&!1===c.binary&&!1===c.base64;t&&"undefined"!=typeof t.binary||(c.binary=!g);(b instanceof l&&0===b.uncompressedSize||c.dir||!b||0===b.length)&&
-(c.base64=!1,c.binary=!0,b="",c.compression="STORE");b=b instanceof l||b instanceof d?b:u.isNode&&u.isStream(b)?new y(a,b):e.prepareContent(a,b,c.binary,c.optimizedBinaryString,c.base64);c=new n(a,b,c);this.files[a]=c},D=function(a){return"/"!==a.slice(-1)&&(a+="/"),a},H=function(a,d){return d="undefined"!=typeof d?d:h.createFolders,a=D(a),this.files[a]||F.call(this,a,null,{dir:!0,createFolders:d}),this.files[a]};f.exports={load:function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.");
-},forEach:function(a){var d,b,e;for(d in this.files)this.files.hasOwnProperty(d)&&(e=this.files[d],b=d.slice(this.root.length,d.length),b&&d.slice(0,this.root.length)===this.root&&a(b,e))},filter:function(a){var d=[];return this.forEach(function(b,e){a(b,e)&&d.push(e)}),d},file:function(a,d,b){if(1===arguments.length){if("[object RegExp]"===Object.prototype.toString.call(a)){var e=a;return this.filter(function(a,d){return!d.dir&&e.test(a)})}var c=this.files[this.root+a];return c&&!c.dir?c:null}return a=
-this.root+a,F.call(this,a,d,b),this},folder:function(a){if(!a)return this;if("[object RegExp]"===Object.prototype.toString.call(a))return this.filter(function(d,b){return b.dir&&a.test(d)});var d=H.call(this,this.root+a),b=this.clone();return b.root=d.name,b},remove:function(a){a=this.root+a;var d=this.files[a];if(d||("/"!==a.slice(-1)&&(a+="/"),d=this.files[a]),d&&!d.dir)delete this.files[a];else for(var d=this.filter(function(d,b){return b.name.slice(0,a.length)===a}),b=0;b<d.length;b++)delete this.files[d[b].name];
-return this},generate:function(a){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.");},generateInternalStream:function(b){var c,t={};try{if(t=e.extend(b||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:a.utf8encode}),t.type=t.type.toLowerCase(),t.compression=t.compression.toUpperCase(),"binarystring"===t.type&&(t.type="string"),!t.type)throw Error("No output type specified.");
-e.checkSupport(t.type);"darwin"!==t.platform&&"freebsd"!==t.platform&&"linux"!==t.platform&&"sunos"!==t.platform||(t.platform="UNIX");"win32"===t.platform&&(t.platform="DOS");c=q.generateWorker(this,t,t.comment||this.comment||"")}catch(E){c=new d("error"),c.error(E)}return new g(c,t.type||"string",t.mimeType)},generateAsync:function(a,d){return this.generateInternalStream(a).accumulate(d)},generateNodeStream:function(a,d){return a=a||{},a.type||(a.type="nodebuffer"),this.generateInternalStream(a).toNodejsStream(d)}}},
-{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(b,f,c){f.exports=b("stream")},{stream:void 0}],17:[function(b,f,c){function a(a){e.call(this,a);for(var d=0;d<this.data.length;d++)a[d]&=255}var e=b("./DataReader");b("../utils").inherits(a,e);a.prototype.byteAt=function(a){return this.data[this.zero+a]};a.prototype.lastIndexOfSignature=
-function(a){var d=a.charCodeAt(0),b=a.charCodeAt(1),e=a.charCodeAt(2);a=a.charCodeAt(3);for(var c=this.length-4;0<=c;--c)if(this.data[c]===d&&this.data[c+1]===b&&this.data[c+2]===e&&this.data[c+3]===a)return c-this.zero;return-1};a.prototype.readAndCheckSignature=function(a){var d=a.charCodeAt(0),b=a.charCodeAt(1),e=a.charCodeAt(2);a=a.charCodeAt(3);var c=this.readData(4);return d===c[0]&&b===c[1]&&e===c[2]&&a===c[3]};a.prototype.readData=function(a){if(this.checkOffset(a),0===a)return[];var b=this.data.slice(this.zero+
-this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./DataReader":18}],18:[function(b,f,c){function a(a){this.data=a;this.length=a.length;this.zero=this.index=0}var e=b("../utils");a.prototype={checkOffset:function(a){this.checkIndex(this.index+a)},checkIndex:function(a){if(this.length<this.zero+a||0>a)throw Error("End of data reached (data length = "+this.length+", asked index = "+a+"). Corrupted zip ?");},setIndex:function(a){this.checkIndex(a);this.index=a},
-skip:function(a){this.setIndex(this.index+a)},byteAt:function(a){},readInt:function(a){var b,d=0;this.checkOffset(a);for(b=this.index+a-1;b>=this.index;b--)d=(d<<8)+this.byteAt(b);return this.index+=a,d},readString:function(a){return e.transformTo("string",this.readData(a))},readData:function(a){},lastIndexOfSignature:function(a){},readAndCheckSignature:function(a){},readDate:function(){var a=this.readInt(4);return new Date(Date.UTC((a>>25&127)+1980,(a>>21&15)-1,a>>16&31,a>>11&31,a>>5&63,(31&a)<<
-1))}};f.exports=a},{"../utils":32}],19:[function(b,f,c){function a(a){e.call(this,a)}var e=b("./Uint8ArrayReader");b("../utils").inherits(a,e);a.prototype.readData=function(a){this.checkOffset(a);var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(b,f,c){function a(a){e.call(this,a)}var e=b("./DataReader");b("../utils").inherits(a,e);a.prototype.byteAt=function(a){return this.data.charCodeAt(this.zero+
-a)};a.prototype.lastIndexOfSignature=function(a){return this.data.lastIndexOf(a)-this.zero};a.prototype.readAndCheckSignature=function(a){var b=this.readData(4);return a===b};a.prototype.readData=function(a){this.checkOffset(a);var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./DataReader":18}],21:[function(b,f,c){function a(a){e.call(this,a)}var e=b("./ArrayReader");b("../utils").inherits(a,e);a.prototype.readData=function(a){if(this.checkOffset(a),
-0===a)return new Uint8Array(0);var b=this.data.subarray(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./ArrayReader":17}],22:[function(b,f,c){var a=b("../utils"),e=b("../support"),d=b("./ArrayReader"),g=b("./StringReader"),h=b("./NodeBufferReader"),l=b("./Uint8ArrayReader");f.exports=function(b){var c=a.getTypeOf(b);return a.checkSupport(c),"string"!==c||e.uint8array?"nodebuffer"===c?new h(b):e.uint8array?new l(a.transformTo("uint8array",b)):new d(a.transformTo("array",
-b)):new g(b)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(b,f,c){c.LOCAL_FILE_HEADER="PK";c.CENTRAL_FILE_HEADER="PK";c.CENTRAL_DIRECTORY_END="PK";c.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK";c.ZIP64_CENTRAL_DIRECTORY_END="PK";c.DATA_DESCRIPTOR="PK\b"},{}],24:[function(b,f,c){function a(a){e.call(this,"ConvertWorker to "+a);this.destType=a}var e=b("./GenericWorker"),d=b("../utils");d.inherits(a,e);a.prototype.processChunk=
-function(a){this.push({data:d.transformTo(this.destType,a.data),meta:a.meta})};f.exports=a},{"../utils":32,"./GenericWorker":28}],25:[function(b,f,c){function a(){e.call(this,"Crc32Probe");this.withStreamInfo("crc32",0)}var e=b("./GenericWorker"),d=b("../crc32");b("../utils").inherits(a,e);a.prototype.processChunk=function(a){this.streamInfo.crc32=d(a.data,this.streamInfo.crc32||0);this.push(a)};f.exports=a},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(b,f,c){function a(a){e.call(this,
-"DataLengthProbe for "+a);this.propName=a;this.withStreamInfo(a,0)}c=b("../utils");var e=b("./GenericWorker");c.inherits(a,e);a.prototype.processChunk=function(a){a&&(this.streamInfo[this.propName]=(this.streamInfo[this.propName]||0)+a.data.length);e.prototype.processChunk.call(this,a)};f.exports=a},{"../utils":32,"./GenericWorker":28}],27:[function(b,f,c){function a(a){d.call(this,"DataWorker");var b=this;this.dataIsReady=!1;this.max=this.index=0;this.data=null;this.type="";this._tickScheduled=!1;
-a.then(function(a){b.dataIsReady=!0;b.data=a;b.max=a&&a.length||0;b.type=e.getTypeOf(a);b.isPaused||b._tickAndRepeat()},function(a){b.error(a)})}var e=b("../utils"),d=b("./GenericWorker");e.inherits(a,d);a.prototype.cleanUp=function(){d.prototype.cleanUp.call(this);this.data=null};a.prototype.resume=function(){return!!d.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,e.delay(this._tickAndRepeat,[],this)),!0)};a.prototype._tickAndRepeat=function(){this._tickScheduled=
+!function(w){"object"==typeof exports&&"undefined"!=typeof module?module.exports=w():"function"==typeof define&&define.amd?define([],w):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).JSZip=w()}(function(){return function b(f,d,a){function e(g,h){if(!d[g]){if(!f[g]){var l="function"==typeof require&&require;if(!h&&l)return l(g,!0);if(c)return c(g,!0);l=Error("Cannot find module '"+g+"'");throw l.code="MODULE_NOT_FOUND",l;}l=d[g]={exports:{}};
+f[g][0].call(l.exports,function(c){var a=f[g][1][c];return e(a?a:c)},l,l.exports,b,f,d,a)}return d[g].exports}for(var c="function"==typeof require&&require,g=0;g<a.length;g++)e(a[g]);return e}({1:[function(b,f,d){var a=b("./utils"),e=b("./support");d.encode=function(c){for(var b,e,d,n,q,t,A,B=[],f=0,z=c.length,x="string"!==a.getTypeOf(c);f<c.length;)A=z-f,x?(b=c[f++],e=f<z?c[f++]:0,d=f<z?c[f++]:0):(b=c.charCodeAt(f++),e=f<z?c.charCodeAt(f++):0,d=f<z?c.charCodeAt(f++):0),n=b>>2,q=(3&b)<<4|e>>4,t=1<
+A?(15&e)<<2|d>>6:64,A=2<A?63&d:64,B.push("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(n)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(q)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(t)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(A));return B.join("")};d.decode=function(c){var a,b,d,n,q,t=0,A=0;if("data:"===c.substr(0,5))throw Error("Invalid base64 input, it looks like a data url.");
+c=c.replace(/[^A-Za-z0-9\+\/\=]/g,"");n=3*c.length/4;if("="===c.charAt(c.length-1)&&n--,"="===c.charAt(c.length-2)&&n--,0!==n%1)throw Error("Invalid base64 input, bad content length.");var B;for(B=e.uint8array?new Uint8Array(0|n):Array(0|n);t<c.length;)a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(c.charAt(t++)),b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(c.charAt(t++)),n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(c.charAt(t++)),
+q="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(c.charAt(t++)),a=a<<2|b>>4,b=(15&b)<<4|n>>2,d=(3&n)<<6|q,B[A++]=a,64!==n&&(B[A++]=b),64!==q&&(B[A++]=d);return B}},{"./support":30,"./utils":32}],2:[function(b,f,d){function a(a,c,b,e,g){this.compressedSize=a;this.uncompressedSize=c;this.crc32=b;this.compression=e;this.compressedContent=g}var e=b("./external"),c=b("./stream/DataWorker"),g=b("./stream/DataLengthProbe"),l=b("./stream/Crc32Probe"),g=b("./stream/DataLengthProbe");
+a.prototype={getContentWorker:function(){var a=(new c(e.Promise.resolve(this.compressedContent))).pipe(this.compression.uncompressWorker()).pipe(new g("data_length")),b=this;return a.on("end",function(){if(this.streamInfo.data_length!==b.uncompressedSize)throw Error("Bug : uncompressed data size mismatch");}),a},getCompressedWorker:function(){return(new c(e.Promise.resolve(this.compressedContent))).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",
+this.crc32).withStreamInfo("compression",this.compression)}};a.createWorkerFrom=function(a,c,b){return a.pipe(new l).pipe(new g("uncompressedSize")).pipe(c.compressWorker(b)).pipe(new g("compressedSize")).withStreamInfo("compression",c)};f.exports=a},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(b,f,d){var a=b("./stream/GenericWorker");d.STORE={magic:"\x00\x00",compressWorker:function(b){return new a("STORE compression")},uncompressWorker:function(){return new a("STORE decompression")}};
+d.DEFLATE=b("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(b,f,d){var a=b("./utils"),e=function(){for(var a,b=[],e=0;256>e;e++){a=e;for(var d=0;8>d;d++)a=1&a?3988292384^a>>>1:a>>>1;b[e]=a}return b}();f.exports=function(c,b){if("undefined"==typeof c||!c.length)return 0;var g;if("string"!==a.getTypeOf(c)){var d=0+c.length;g=(0|b)^-1;for(var n=0;n<d;n++)g=g>>>8^e[255&(g^c[n])]}else for(d=0+c.length,g=(0|b)^-1,n=0;n<d;n++)g=g>>>8^e[255&(g^c.charCodeAt(n))];return g^=-1}},{"./utils":32}],
+5:[function(b,f,d){d.base64=!1;d.binary=!1;d.dir=!1;d.createFolders=!0;d.date=null;d.compression=null;d.compressionOptions=null;d.comment=null;d.unixPermissions=null;d.dosPermissions=null},{}],6:[function(b,f,d){b="undefined"!=typeof Promise?Promise:b("lie");f.exports={Promise:b}},{lie:58}],7:[function(b,f,d){function a(a,c){g.call(this,"FlateWorker/"+a);this._pako=new e[a]({raw:!0,level:c.level||-1});this.meta={};var b=this;this._pako.onData=function(a){b.push({data:a,meta:b.meta})}}f="undefined"!=
+typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array;var e=b("pako"),c=b("./utils"),g=b("./stream/GenericWorker"),l=f?"uint8array":"array";d.magic="\b\x00";c.inherits(a,g);a.prototype.processChunk=function(a){this.meta=a.meta;this._pako.push(c.transformTo(l,a.data),!1)};a.prototype.flush=function(){g.prototype.flush.call(this);this._pako.push([],!0)};a.prototype.cleanUp=function(){g.prototype.cleanUp.call(this);this._pako=null};d.compressWorker=function(c){return new a("Deflate",
+c)};d.uncompressWorker=function(){return new a("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:59}],8:[function(b,f,d){function a(a,b,e,g){c.call(this,"ZipFileWorker");this.bytesWritten=0;this.zipComment=b;this.zipPlatform=e;this.encodeFileName=g;this.streamFiles=a;this.accumulate=!1;this.contentBuffer=[];this.dirRecords=[];this.entriesCount=this.currentSourceOffset=0;this.currentFile=null;this._sources=[]}var e=b("../utils"),c=b("../stream/GenericWorker"),g=b("../utf8"),l=b("../crc32"),
+h=b("../signature"),n=function(a,c){var b,e="";for(b=0;b<c;b++)e+=String.fromCharCode(255&a),a>>>=8;return e},q=function(a,c,b,d,x,t){var p,A;p=a.file;var z=a.compression,y=t!==g.utf8encode,q=e.transformTo("string",t(p.name)),u=e.transformTo("string",g.utf8encode(p.name)),B=p.comment;t=e.transformTo("string",t(B));var v=e.transformTo("string",g.utf8encode(B)),f=u.length!==p.name.length,G=v.length!==B.length,F=B="",X="";A=p.dir;var T=p.date,aa=0,V=0,r=0;c&&!b||(aa=a.crc32,V=a.compressedSize,r=a.uncompressedSize);
+a=0;c&&(a|=8);y||!f&&!G||(a|=2048);c=0;A&&(c|=16);"UNIX"===x?(x=798,p=y=p.unixPermissions,A=(y||(p=A?16893:33204),(65535&p)<<16),c|=A):(x=20,c|=63&(p.dosPermissions||0));p=T.getUTCHours();p=p<<6|T.getUTCMinutes();p=p<<5|T.getUTCSeconds()/2;A=T.getUTCFullYear()-1980;A=A<<4|T.getUTCMonth()+1;A=A<<5|T.getUTCDate();f&&(F=n(1,1)+n(l(q),4)+u,B+="up"+n(F.length,2)+F);G&&(X=n(1,1)+n(l(t),4)+v,B+="uc"+n(X.length,2)+X);u="\n\x00"+n(a,2);u+=z.magic;u+=n(p,2);u+=n(A,2);u+=n(aa,4);u+=n(V,4);u+=n(r,4);u+=n(q.length,
+2);u+=n(B.length,2);z=h.LOCAL_FILE_HEADER+u+q+B;d=h.CENTRAL_FILE_HEADER+n(x,2)+u+n(t.length,2)+"\x00\x00\x00\x00"+n(c,4)+n(d,4)+q+B+t;return{fileRecord:z,dirRecord:d}},t=function(a){return h.DATA_DESCRIPTOR+n(a.crc32,4)+n(a.compressedSize,4)+n(a.uncompressedSize,4)};e.inherits(a,c);a.prototype.push=function(a){var b=a.meta.percent||0,e=this.entriesCount,g=this._sources.length;this.accumulate?this.contentBuffer.push(a):(this.bytesWritten+=a.data.length,c.prototype.push.call(this,{data:a.data,meta:{currentFile:this.currentFile,
+percent:e?(b+100*(e-g-1))/e:100}}))};a.prototype.openedSource=function(a){this.currentSourceOffset=this.bytesWritten;this.currentFile=a.file.name;var c=this.streamFiles&&!a.file.dir;c?(a=q(a,c,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName),this.push({data:a.fileRecord,meta:{percent:0}})):this.accumulate=!0};a.prototype.closedSource=function(a){this.accumulate=!1;var c=this.streamFiles&&!a.file.dir,b=q(a,c,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(b.dirRecord),
+c)this.push({data:t(a),meta:{percent:100}});else for(this.push({data:b.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null};a.prototype.flush=function(){for(var a=this.bytesWritten,c=0;c<this.dirRecords.length;c++)this.push({data:this.dirRecords[c],meta:{percent:100}});var c=this.dirRecords.length,b=this.bytesWritten-a,g=e.transformTo("string",(0,this.encodeFileName)(this.zipComment)),a=h.CENTRAL_DIRECTORY_END+"\x00\x00\x00\x00"+n(c,
+2)+n(c,2)+n(b,4)+n(a,4)+n(g.length,2)+g;this.push({data:a,meta:{percent:100}})};a.prototype.prepareNextSource=function(){this.previous=this._sources.shift();this.openedSource(this.previous.streamInfo);this.isPaused?this.previous.pause():this.previous.resume()};a.prototype.registerPrevious=function(a){this._sources.push(a);var c=this;return a.on("data",function(a){c.processChunk(a)}),a.on("end",function(){c.closedSource(c.previous.streamInfo);c._sources.length?c.prepareNextSource():c.end()}),a.on("error",
+function(a){c.error(a)}),this};a.prototype.resume=function(){return!!c.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))};a.prototype.error=function(a){var b=this._sources;if(!c.prototype.error.call(this,a))return!1;for(var e=0;e<b.length;e++)try{b[e].error(a)}catch(z){}return!0};a.prototype.lock=function(){c.prototype.lock.call(this);for(var a=this._sources,b=0;b<a.length;b++)a[b].lock()};
+f.exports=a},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(b,f,d){var a=b("../compressions"),e=b("./ZipFileWorker");d.generateWorker=function(c,b,d){var g=new e(b.streamFiles,d,b.platform,b.encodeFileName),l=0;try{c.forEach(function(c,e){l++;var d=e.options.compression||b.compression,t=a[d];if(!t)throw Error(d+" is not a valid compression method !");var d=e.dir,n=e.date;e._compressWorker(t,e.options.compressionOptions||b.compressionOptions||
+{}).withStreamInfo("file",{name:c,dir:d,date:n,comment:e.comment||"",unixPermissions:e.unixPermissions,dosPermissions:e.dosPermissions}).pipe(g)}),g.entriesCount=l}catch(q){g.error(q)}return g}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(b,f,d){function a(){if(!(this instanceof a))return new a;if(arguments.length)throw Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files={};this.comment=null;this.root="";this.clone=function(){var b=
+new a,c;for(c in this)"function"!=typeof this[c]&&(b[c]=this[c]);return b}}a.prototype=b("./object");a.prototype.loadAsync=b("./load");a.support=b("./support");a.defaults=b("./defaults");a.version="3.1.3";a.loadAsync=function(b,c){return(new a).loadAsync(b,c)};a.external=b("./external");f.exports=a},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(b,f,d){function a(a){return new c.Promise(function(c,b){var e=a.decompressed.getContentWorker().pipe(new h);e.on("error",
+function(a){b(a)}).on("end",function(){e.streamInfo.crc32!==a.decompressed.crc32?b(Error("Corrupted zip : CRC32 mismatch")):c()}).resume()})}var e=b("./utils"),c=b("./external"),g=b("./utf8"),e=b("./utils"),l=b("./zipEntries"),h=b("./stream/Crc32Probe"),n=b("./nodejsUtils");f.exports=function(b,d){var t=this;return d=e.extend(d||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:g.utf8decode}),n.isNode&&n.isStream(b)?c.Promise.reject(Error("JSZip can't accept a stream when loading a zip file.")):
+e.prepareContent("the loaded zip file",b,!0,d.optimizedBinaryString,d.base64).then(function(a){var c=new l(d);return c.load(a),c}).then(function(b){var e=[c.Promise.resolve(b)];b=b.files;if(d.checkCRC32)for(var g=0;g<b.length;g++)e.push(a(b[g]));return c.Promise.all(e)}).then(function(a){a=a.shift();for(var c=a.files,b=0;b<c.length;b++){var e=c[b];t.file(e.fileNameStr,e.decompressed,{binary:!0,optimizedBinaryString:!0,date:e.date,dir:e.dir,comment:e.fileCommentStr.length?e.fileCommentStr:null,unixPermissions:e.unixPermissions,
+dosPermissions:e.dosPermissions,createFolders:d.createFolders})}return a.zipComment.length&&(t.comment=a.zipComment),t})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(b,f,d){function a(a,b){e.call(this,"Nodejs stream input adapter for "+a);this._upstreamEnded=!1;this._bindStream(b)}d=b("../utils");var e=b("../stream/GenericWorker");d.inherits(a,e);a.prototype._bindStream=function(a){var c=this;this._stream=a;a.pause();a.on("data",
+function(a){c.push({data:a,meta:{percent:0}})}).on("error",function(a){c.isPaused?this.generatedError=a:c.error(a)}).on("end",function(){c.isPaused?c._upstreamEnded=!0:c.end()})};a.prototype.pause=function(){return!!e.prototype.pause.call(this)&&(this._stream.pause(),!0)};a.prototype.resume=function(){return!!e.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)};f.exports=a},{"../stream/GenericWorker":28,"../utils":32}],13:[function(b,f,d){function a(a,b,d){e.call(this,
+b);this._helper=a;var c=this;a.on("data",function(a,b){c.push(a)||c._helper.pause();d&&d(b)}).on("error",function(a){c.emit("error",a)}).on("end",function(){c.push(null)})}var e=b("readable-stream").Readable;b("util").inherits(a,e);a.prototype._read=function(){this._helper.resume()};f.exports=a},{"readable-stream":16,util:void 0}],14:[function(b,f,d){f.exports={isNode:"undefined"!=typeof Buffer,newBuffer:function(a,b){return new Buffer(a,b)},isBuffer:function(a){return Buffer.isBuffer(a)},isStream:function(a){return a&&
+"function"==typeof a.on&&"function"==typeof a.pause&&"function"==typeof a.resume}}},{}],15:[function(b,f,d){var a=b("./utf8"),e=b("./utils"),c=b("./stream/GenericWorker"),g=b("./stream/StreamHelper"),l=b("./defaults"),h=b("./compressedObject"),n=b("./zipObject"),q=b("./generate"),t=b("./nodejsUtils"),A=b("./nodejs/NodejsStreamInputAdapter"),B=function(a,b,p){var x,g=e.getTypeOf(b),d=e.extend(p||{},l);d.date=d.date||new Date;null!==d.compression&&(d.compression=d.compression.toUpperCase());"string"==
+typeof d.unixPermissions&&(d.unixPermissions=parseInt(d.unixPermissions,8));d.unixPermissions&&16384&d.unixPermissions&&(d.dir=!0);d.dosPermissions&&16&d.dosPermissions&&(d.dir=!0);d.dir&&(a=G(a));var y;if(y=d.createFolders)x=a,"/"===x.slice(-1)&&(x=x.substring(0,x.length-1)),y=x.lastIndexOf("/"),y=x=0<y?x.substring(0,y):"";y&&z.call(this,x,!0);g="string"===g&&!1===d.binary&&!1===d.base64;p&&"undefined"!=typeof p.binary||(d.binary=!g);(b instanceof h&&0===b.uncompressedSize||d.dir||!b||0===b.length)&&
+(d.base64=!1,d.binary=!0,b="",d.compression="STORE");b=b instanceof h||b instanceof c?b:t.isNode&&t.isStream(b)?new A(a,b):e.prepareContent(a,b,d.binary,d.optimizedBinaryString,d.base64);d=new n(a,b,d);this.files[a]=d},G=function(a){return"/"!==a.slice(-1)&&(a+="/"),a},z=function(a,b){return b="undefined"!=typeof b?b:l.createFolders,a=G(a),this.files[a]||B.call(this,a,null,{dir:!0,createFolders:b}),this.files[a]};f.exports={load:function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.");
+},forEach:function(a){var b,c,e;for(b in this.files)this.files.hasOwnProperty(b)&&(e=this.files[b],c=b.slice(this.root.length,b.length),c&&b.slice(0,this.root.length)===this.root&&a(c,e))},filter:function(a){var b=[];return this.forEach(function(c,e){a(c,e)&&b.push(e)}),b},file:function(a,b,c){if(1===arguments.length){if("[object RegExp]"===Object.prototype.toString.call(a)){var e=a;return this.filter(function(a,b){return!b.dir&&e.test(a)})}var d=this.files[this.root+a];return d&&!d.dir?d:null}return a=
+this.root+a,B.call(this,a,b,c),this},folder:function(a){if(!a)return this;if("[object RegExp]"===Object.prototype.toString.call(a))return this.filter(function(b,c){return c.dir&&a.test(b)});var b=z.call(this,this.root+a),c=this.clone();return c.root=b.name,c},remove:function(a){a=this.root+a;var b=this.files[a];if(b||("/"!==a.slice(-1)&&(a+="/"),b=this.files[a]),b&&!b.dir)delete this.files[a];else for(var b=this.filter(function(b,c){return c.name.slice(0,a.length)===a}),c=0;c<b.length;c++)delete this.files[b[c].name];
+return this},generate:function(a){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.");},generateInternalStream:function(b){var d,p={};try{if(p=e.extend(b||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:a.utf8encode}),p.type=p.type.toLowerCase(),p.compression=p.compression.toUpperCase(),"binarystring"===p.type&&(p.type="string"),!p.type)throw Error("No output type specified.");
+e.checkSupport(p.type);"darwin"!==p.platform&&"freebsd"!==p.platform&&"linux"!==p.platform&&"sunos"!==p.platform||(p.platform="UNIX");"win32"===p.platform&&(p.platform="DOS");d=q.generateWorker(this,p,p.comment||this.comment||"")}catch(D){d=new c("error"),d.error(D)}return new g(d,p.type||"string",p.mimeType)},generateAsync:function(a,b){return this.generateInternalStream(a).accumulate(b)},generateNodeStream:function(a,b){return a=a||{},a.type||(a.type="nodebuffer"),this.generateInternalStream(a).toNodejsStream(b)}}},
+{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(b,f,d){f.exports=b("stream")},{stream:void 0}],17:[function(b,f,d){function a(a){e.call(this,a);for(var b=0;b<this.data.length;b++)a[b]&=255}var e=b("./DataReader");b("../utils").inherits(a,e);a.prototype.byteAt=function(a){return this.data[this.zero+a]};a.prototype.lastIndexOfSignature=
+function(a){var b=a.charCodeAt(0),c=a.charCodeAt(1),e=a.charCodeAt(2);a=a.charCodeAt(3);for(var d=this.length-4;0<=d;--d)if(this.data[d]===b&&this.data[d+1]===c&&this.data[d+2]===e&&this.data[d+3]===a)return d-this.zero;return-1};a.prototype.readAndCheckSignature=function(a){var b=a.charCodeAt(0),c=a.charCodeAt(1),e=a.charCodeAt(2);a=a.charCodeAt(3);var d=this.readData(4);return b===d[0]&&c===d[1]&&e===d[2]&&a===d[3]};a.prototype.readData=function(a){if(this.checkOffset(a),0===a)return[];var b=this.data.slice(this.zero+
+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./DataReader":18}],18:[function(b,f,d){function a(a){this.data=a;this.length=a.length;this.zero=this.index=0}var e=b("../utils");a.prototype={checkOffset:function(a){this.checkIndex(this.index+a)},checkIndex:function(a){if(this.length<this.zero+a||0>a)throw Error("End of data reached (data length = "+this.length+", asked index = "+a+"). Corrupted zip ?");},setIndex:function(a){this.checkIndex(a);this.index=a},
+skip:function(a){this.setIndex(this.index+a)},byteAt:function(a){},readInt:function(a){var b,c=0;this.checkOffset(a);for(b=this.index+a-1;b>=this.index;b--)c=(c<<8)+this.byteAt(b);return this.index+=a,c},readString:function(a){return e.transformTo("string",this.readData(a))},readData:function(a){},lastIndexOfSignature:function(a){},readAndCheckSignature:function(a){},readDate:function(){var a=this.readInt(4);return new Date(Date.UTC((a>>25&127)+1980,(a>>21&15)-1,a>>16&31,a>>11&31,a>>5&63,(31&a)<<
+1))}};f.exports=a},{"../utils":32}],19:[function(b,f,d){function a(a){e.call(this,a)}var e=b("./Uint8ArrayReader");b("../utils").inherits(a,e);a.prototype.readData=function(a){this.checkOffset(a);var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(b,f,d){function a(a){e.call(this,a)}var e=b("./DataReader");b("../utils").inherits(a,e);a.prototype.byteAt=function(a){return this.data.charCodeAt(this.zero+
+a)};a.prototype.lastIndexOfSignature=function(a){return this.data.lastIndexOf(a)-this.zero};a.prototype.readAndCheckSignature=function(a){var b=this.readData(4);return a===b};a.prototype.readData=function(a){this.checkOffset(a);var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./DataReader":18}],21:[function(b,f,d){function a(a){e.call(this,a)}var e=b("./ArrayReader");b("../utils").inherits(a,e);a.prototype.readData=function(a){if(this.checkOffset(a),
+0===a)return new Uint8Array(0);var b=this.data.subarray(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b};f.exports=a},{"../utils":32,"./ArrayReader":17}],22:[function(b,f,d){var a=b("../utils"),e=b("../support"),c=b("./ArrayReader"),g=b("./StringReader"),l=b("./NodeBufferReader"),h=b("./Uint8ArrayReader");f.exports=function(b){var d=a.getTypeOf(b);return a.checkSupport(d),"string"!==d||e.uint8array?"nodebuffer"===d?new l(b):e.uint8array?new h(a.transformTo("uint8array",b)):new c(a.transformTo("array",
+b)):new g(b)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(b,f,d){d.LOCAL_FILE_HEADER="PK";d.CENTRAL_FILE_HEADER="PK";d.CENTRAL_DIRECTORY_END="PK";d.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK";d.ZIP64_CENTRAL_DIRECTORY_END="PK";d.DATA_DESCRIPTOR="PK\b"},{}],24:[function(b,f,d){function a(a){e.call(this,"ConvertWorker to "+a);this.destType=a}var e=b("./GenericWorker"),c=b("../utils");c.inherits(a,e);a.prototype.processChunk=
+function(a){this.push({data:c.transformTo(this.destType,a.data),meta:a.meta})};f.exports=a},{"../utils":32,"./GenericWorker":28}],25:[function(b,f,d){function a(){e.call(this,"Crc32Probe");this.withStreamInfo("crc32",0)}var e=b("./GenericWorker"),c=b("../crc32");b("../utils").inherits(a,e);a.prototype.processChunk=function(a){this.streamInfo.crc32=c(a.data,this.streamInfo.crc32||0);this.push(a)};f.exports=a},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(b,f,d){function a(a){e.call(this,
+"DataLengthProbe for "+a);this.propName=a;this.withStreamInfo(a,0)}d=b("../utils");var e=b("./GenericWorker");d.inherits(a,e);a.prototype.processChunk=function(a){a&&(this.streamInfo[this.propName]=(this.streamInfo[this.propName]||0)+a.data.length);e.prototype.processChunk.call(this,a)};f.exports=a},{"../utils":32,"./GenericWorker":28}],27:[function(b,f,d){function a(a){c.call(this,"DataWorker");var b=this;this.dataIsReady=!1;this.max=this.index=0;this.data=null;this.type="";this._tickScheduled=!1;
+a.then(function(a){b.dataIsReady=!0;b.data=a;b.max=a&&a.length||0;b.type=e.getTypeOf(a);b.isPaused||b._tickAndRepeat()},function(a){b.error(a)})}var e=b("../utils"),c=b("./GenericWorker");e.inherits(a,c);a.prototype.cleanUp=function(){c.prototype.cleanUp.call(this);this.data=null};a.prototype.resume=function(){return!!c.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,e.delay(this._tickAndRepeat,[],this)),!0)};a.prototype._tickAndRepeat=function(){this._tickScheduled=
 !1;this.isPaused||this.isFinished||(this._tick(),this.isFinished||(e.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))};a.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var a=null,b=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case "string":a=this.data.substring(this.index,b);break;case "uint8array":a=this.data.subarray(this.index,b);break;case "array":case "nodebuffer":a=this.data.slice(this.index,b)}return this.index=
-b,this.push({data:a,meta:{percent:this.max?this.index/this.max*100:0}})};f.exports=a},{"../utils":32,"./GenericWorker":28}],28:[function(b,f,c){function a(a){this.name=a||"default";this.streamInfo={};this.generatedError=null;this.extraStreamInfo={};this.isPaused=!0;this.isLocked=this.isFinished=!1;this._listeners={data:[],end:[],error:[]};this.previous=null}a.prototype={push:function(a){this.emit("data",a)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),
-this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(a){return!this.isFinished&&(this.isPaused?this.generatedError=a:(this.isFinished=!0,this.emit("error",a),this.previous&&this.previous.error(a),this.cleanUp()),!0)},on:function(a,b){return this._listeners[a].push(b),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null;this._listeners=[]},emit:function(a,b){if(this._listeners[a])for(var d=0;d<this._listeners[a].length;d++)this._listeners[a][d].call(this,
+b,this.push({data:a,meta:{percent:this.max?this.index/this.max*100:0}})};f.exports=a},{"../utils":32,"./GenericWorker":28}],28:[function(b,f,d){function a(a){this.name=a||"default";this.streamInfo={};this.generatedError=null;this.extraStreamInfo={};this.isPaused=!0;this.isLocked=this.isFinished=!1;this._listeners={data:[],end:[],error:[]};this.previous=null}a.prototype={push:function(a){this.emit("data",a)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),
+this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(a){return!this.isFinished&&(this.isPaused?this.generatedError=a:(this.isFinished=!0,this.emit("error",a),this.previous&&this.previous.error(a),this.cleanUp()),!0)},on:function(a,b){return this._listeners[a].push(b),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null;this._listeners=[]},emit:function(a,b){if(this._listeners[a])for(var e=0;e<this._listeners[a].length;e++)this._listeners[a][e].call(this,
 b)},pipe:function(a){return a.registerPrevious(this)},registerPrevious:function(a){if(this.isLocked)throw Error("The stream '"+this+"' has already been used.");this.streamInfo=a.streamInfo;this.mergeStreamInfo();this.previous=a;var b=this;return a.on("data",function(a){b.processChunk(a)}),a.on("end",function(){b.end()}),a.on("error",function(a){b.error(a)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||
 this.isFinished)return!1;var a=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),a=!0),this.previous&&this.previous.resume(),!a},flush:function(){},processChunk:function(a){this.push(a)},withStreamInfo:function(a,b){return this.extraStreamInfo[a]=b,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var a in this.extraStreamInfo)this.extraStreamInfo.hasOwnProperty(a)&&(this.streamInfo[a]=this.extraStreamInfo[a])},lock:function(){if(this.isLocked)throw Error("The stream '"+
-this+"' has already been used.");this.isLocked=!0;this.previous&&this.previous.lock()},toString:function(){var a="Worker "+this.name;return this.previous?this.previous+" -> "+a:a}};f.exports=a},{}],29:[function(b,f,c){function a(a,b){var d,e=0,c;for(d=c=0;d<b.length;d++)c+=b[d].length;switch(a){case "string":return b.join("");case "array":return Array.prototype.concat.apply([],b);case "uint8array":c=new Uint8Array(c);for(d=0;d<b.length;d++)c.set(b[d],e),e+=b[d].length;return c;case "nodebuffer":return Buffer.concat(b);
-default:throw Error("concat : unsupported type '"+a+"'");}}function e(b,d){return new q.Promise(function(e,c){var v=[],u=b._internalType,t=b._outputType,f=b._mimeType;b.on("data",function(a,b){v.push(a);d&&d(b)}).on("error",function(a){v=[];c(a)}).on("end",function(){try{var b;a:{var d=v,y=null;switch(t){case "blob":b=g.newBlob(d,f);break a;case "base64":b=(y=a(u,d),n.encode(y));break a;default:b=(y=a(u,d),g.transformTo(t,y))}}e(b)}catch(p){c(p)}v=[]}).resume()})}function d(a,b,d){var c=b;switch(b){case "blob":c=
-"arraybuffer";break;case "arraybuffer":c="uint8array";break;case "base64":c="string"}try{this._internalType=c,this._outputType=b,this._mimeType=d,g.checkSupport(c),this._worker=a.pipe(new h(c)),a.lock()}catch(v){this._worker=new l("error"),this._worker.error(v)}}var g=b("../utils"),h=b("./ConvertWorker"),l=b("./GenericWorker"),n=b("../base64");c=b("../support");var q=b("../external"),u=null;if(c.nodestream)try{u=b("../nodejs/NodejsStreamOutputAdapter")}catch(y){}d.prototype={accumulate:function(a){return e(this,
-a)},on:function(a,b){var d=this;return"data"===a?this._worker.on(a,function(a){b.call(d,a.data,a.meta)}):this._worker.on(a,function(){g.delay(b,arguments,d)}),this},resume:function(){return g.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(a){if(g.checkSupport("nodestream"),"nodebuffer"!==this._outputType)throw Error(this._outputType+" is not supported by this method");return new u(this,{objectMode:"nodebuffer"!==this._outputType},
-a)}};f.exports=d},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(b,f,c){if(c.base64=!0,c.array=!0,c.string=!0,c.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,c.nodebuffer="undefined"!=typeof Buffer,c.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)c.blob=!1;else{f=new ArrayBuffer(0);try{c.blob=0===(new Blob([f],{type:"application/zip"})).size}catch(e){try{var a=
-new (window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder);a.append(f);c.blob=0===a.getBlob("application/zip").size}catch(d){c.blob=!1}}}try{c.nodestream=!!b("readable-stream").Readable}catch(e){c.nodestream=!1}},{"readable-stream":16}],31:[function(b,f,c){function a(){l.call(this,"utf-8 decode");this.leftOver=null}function e(){l.call(this,"utf-8 encode")}var d=b("./utils"),g=b("./support"),h=b("./nodejsUtils"),l=b("./stream/GenericWorker"),n=Array(256);for(b=
-0;256>b;b++)n[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;n[254]=n[254]=1;c.utf8encode=function(a){if(g.nodebuffer)a=h.newBuffer(a,"utf-8");else{var b,d,c,e,f,v=a.length,n=0;for(e=0;e<v;e++)d=a.charCodeAt(e),55296===(64512&d)&&e+1<v&&(c=a.charCodeAt(e+1),56320===(64512&c)&&(d=65536+(d-55296<<10)+(c-56320),e++)),n+=128>d?1:2048>d?2:65536>d?3:4;b=g.uint8array?new Uint8Array(n):Array(n);for(e=f=0;f<n;e++)d=a.charCodeAt(e),55296===(64512&d)&&e+1<v&&(c=a.charCodeAt(e+1),56320===(64512&c)&&(d=65536+
-(d-55296<<10)+(c-56320),e++)),128>d?b[f++]=d:2048>d?(b[f++]=192|d>>>6,b[f++]=128|63&d):65536>d?(b[f++]=224|d>>>12,b[f++]=128|d>>>6&63,b[f++]=128|63&d):(b[f++]=240|d>>>18,b[f++]=128|d>>>12&63,b[f++]=128|d>>>6&63,b[f++]=128|63&d);a=b}return a};c.utf8decode=function(a){var b;if(g.nodebuffer)b=d.transformTo("nodebuffer",a).toString("utf-8");else{var c=a=d.transformTo(g.uint8array?"uint8array":"array",a),e,f,h,v=c.length;a=Array(2*v);for(e=f=0;e<v;)if(b=c[e++],128>b)a[f++]=b;else if(h=n[b],4<h)a[f++]=
-65533,e+=h-1;else{for(b&=2===h?31:3===h?15:7;1<h&&e<v;)b=b<<6|63&c[e++],h--;1<h?a[f++]=65533:65536>b?a[f++]=b:(b-=65536,a[f++]=55296|b>>10&1023,a[f++]=56320|1023&b)}b=(a.length!==f&&(a.subarray?a=a.subarray(0,f):a.length=f),d.applyFromCharCode(a))}return b};d.inherits(a,l);a.prototype.processChunk=function(a){var b=d.transformTo(g.uint8array?"uint8array":"array",a.data);if(this.leftOver&&this.leftOver.length){if(g.uint8array){var e=b,b=new Uint8Array(e.length+this.leftOver.length);b.set(this.leftOver,
-0);b.set(e,this.leftOver.length)}else b=this.leftOver.concat(b);this.leftOver=null}var f,e=b.length;e>b.length&&(e=b.length);for(f=e-1;0<=f&&128===(192&b[f]);)f--;e=0>f?e:0===f?e:f+n[b[f]]>e?f:e;f=b;e!==b.length&&(g.uint8array?(f=b.subarray(0,e),this.leftOver=b.subarray(e,b.length)):(f=b.slice(0,e),this.leftOver=b.slice(e,b.length)));this.push({data:c.utf8decode(f),meta:a.meta})};a.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:c.utf8decode(this.leftOver),meta:{}}),
-this.leftOver=null)};c.Utf8DecodeWorker=a;d.inherits(e,l);e.prototype.processChunk=function(a){this.push({data:c.utf8encode(a.data),meta:a.meta})};c.Utf8EncodeWorker=e},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(b,f,c){function a(a){return a}function e(a,b){for(var d=0;d<a.length;++d)b[d]=255&a.charCodeAt(d);return b}function d(a){var b=65536,d=c.getTypeOf(a),e=!0;if("uint8array"===d?e=D.applyCanBeUsed.uint8array:"nodebuffer"===d&&(e=D.applyCanBeUsed.nodebuffer),
-e)for(;1<b;)try{return D.stringifyByChunk(a,d,b)}catch(m){b=Math.floor(b/2)}return D.stringifyByChar(a)}function g(a,b){for(var d=0;d<a.length;d++)b[d]=a[d];return b}var h=b("./support"),l=b("./base64"),n=b("./nodejsUtils"),q=b("core-js/library/fn/set-immediate"),u=b("./external");c.newBlob=function(a,b){c.checkSupport("blob");try{return new Blob(a,{type:b})}catch(m){try{for(var d=new (window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder),e=0;e<a.length;e++)d.append(a[e]);
-return d.getBlob(b)}catch(P){throw Error("Bug : can't construct the Blob.");}}};var y;try{y=h.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(v){y=!1}b=y;var F;try{F=h.nodebuffer&&1===String.fromCharCode.apply(null,n.newBuffer(1)).length}catch(v){F=!1}var D={stringifyByChunk:function(a,b,d){var e=[],c=0,t=a.length;if(t<=d)return String.fromCharCode.apply(null,a);for(;c<t;)"array"===b||"nodebuffer"===b?e.push(String.fromCharCode.apply(null,a.slice(c,Math.min(c+d,t)))):
-e.push(String.fromCharCode.apply(null,a.subarray(c,Math.min(c+d,t)))),c+=d;return e.join("")},stringifyByChar:function(a){for(var b="",d=0;d<a.length;d++)b+=String.fromCharCode(a[d]);return b},applyCanBeUsed:{uint8array:b,nodebuffer:F}};c.applyFromCharCode=d;var H={};H.string={string:a,array:function(a){return e(a,Array(a.length))},arraybuffer:function(a){return H.string.uint8array(a).buffer},uint8array:function(a){return e(a,new Uint8Array(a.length))},nodebuffer:function(a){return e(a,n.newBuffer(a.length))}};
-H.array={string:d,array:a,arraybuffer:function(a){return(new Uint8Array(a)).buffer},uint8array:function(a){return new Uint8Array(a)},nodebuffer:function(a){return n.newBuffer(a)}};H.arraybuffer={string:function(a){return d(new Uint8Array(a))},array:function(a){return g(new Uint8Array(a),Array(a.byteLength))},arraybuffer:a,uint8array:function(a){return new Uint8Array(a)},nodebuffer:function(a){return n.newBuffer(new Uint8Array(a))}};H.uint8array={string:d,array:function(a){return g(a,Array(a.length))},
-arraybuffer:function(a){var b=new Uint8Array(a.length);return a.length&&b.set(a,0),b.buffer},uint8array:a,nodebuffer:function(a){return n.newBuffer(a)}};H.nodebuffer={string:d,array:function(a){return g(a,Array(a.length))},arraybuffer:function(a){return H.nodebuffer.uint8array(a).buffer},uint8array:function(a){return g(a,new Uint8Array(a.length))},nodebuffer:a};c.transformTo=function(a,b){if(b||(b=""),!a)return b;c.checkSupport(a);var d=c.getTypeOf(b);return H[d][a](b)};c.getTypeOf=function(a){return"string"==
-typeof a?"string":"[object Array]"===Object.prototype.toString.call(a)?"array":h.nodebuffer&&n.isBuffer(a)?"nodebuffer":h.uint8array&&a instanceof Uint8Array?"uint8array":h.arraybuffer&&a instanceof ArrayBuffer?"arraybuffer":void 0};c.checkSupport=function(a){if(!h[a.toLowerCase()])throw Error(a+" is not supported by this platform");};c.MAX_VALUE_16BITS=65535;c.MAX_VALUE_32BITS=-1;c.pretty=function(a){var b,d,e="";for(d=0;d<(a||"").length;d++)b=a.charCodeAt(d),e+="\\x"+(16>b?"0":"")+b.toString(16).toUpperCase();
-return e};c.delay=function(a,b,d){q(function(){a.apply(d||null,b||[])})};c.inherits=function(a,b){var d=function(){};d.prototype=b.prototype;a.prototype=new d};c.extend=function(){var a,b,d={};for(a=0;a<arguments.length;a++)for(b in arguments[a])arguments[a].hasOwnProperty(b)&&"undefined"==typeof d[b]&&(d[b]=arguments[a][b]);return d};c.prepareContent=function(a,b,d,f,g){return u.Promise.resolve(b).then(function(a){return h.blob&&(a instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(a)))&&
-"undefined"!=typeof FileReader?new u.Promise(function(b,d){var e=new FileReader;e.onload=function(a){b(a.target.result)};e.onerror=function(a){d(a.target.error)};e.readAsArrayBuffer(a)}):a}).then(function(b){var t=c.getTypeOf(b);t?"arraybuffer"===t?b=c.transformTo("uint8array",b):"string"===t&&(g?b=l.decode(b):d&&!0!==f&&(t=null,b=(t=h.uint8array?new Uint8Array(b.length):Array(b.length),e(b,t)))):b=u.Promise.reject(Error("The data of '"+a+"' is in an unsupported format !"));return b})}},{"./base64":1,
-"./external":6,"./nodejsUtils":14,"./support":30,"core-js/library/fn/set-immediate":36}],33:[function(b,f,c){function a(a){this.files=[];this.loadOptions=a}var e=b("./reader/readerFor"),d=b("./utils"),g=b("./signature"),h=b("./zipEntry"),l=(b("./utf8"),b("./support"));a.prototype={checkSignature:function(a){if(!this.reader.readAndCheckSignature(a)){this.reader.index-=4;var b=this.reader.readString(4);throw Error("Corrupted zip or bug : unexpected signature ("+d.pretty(b)+", expected "+d.pretty(a)+
-")");}},isSignature:function(a,b){var d=this.reader.index;this.reader.setIndex(a);var e=this.reader.readString(4)===b;return this.reader.setIndex(d),e},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2);this.diskWithCentralDirStart=this.reader.readInt(2);this.centralDirRecordsOnThisDisk=this.reader.readInt(2);this.centralDirRecords=this.reader.readInt(2);this.centralDirSize=this.reader.readInt(4);this.centralDirOffset=this.reader.readInt(4);this.zipCommentLength=this.reader.readInt(2);
-var a=this.reader.readData(this.zipCommentLength),a=d.transformTo(l.uint8array?"uint8array":"array",a);this.zipComment=this.loadOptions.decodeFileName(a)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8);this.reader.skip(4);this.diskNumber=this.reader.readInt(4);this.diskWithCentralDirStart=this.reader.readInt(4);this.centralDirRecordsOnThisDisk=this.reader.readInt(8);this.centralDirRecords=this.reader.readInt(8);this.centralDirSize=this.reader.readInt(8);this.centralDirOffset=
-this.reader.readInt(8);this.zip64ExtensibleData={};for(var a,b,d,e=this.zip64EndOfCentralSize-44;0<e;)a=this.reader.readInt(2),b=this.reader.readInt(4),d=this.reader.readData(b),this.zip64ExtensibleData[a]={id:a,length:b,value:d}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw Error("Multi-volumes zip are not supported");
-},readLocalFiles:function(){var a,b;for(a=0;a<this.files.length;a++)b=this.files[a],this.reader.setIndex(b.localHeaderOffset),this.checkSignature(g.LOCAL_FILE_HEADER),b.readLocalPart(this.reader),b.handleUTF8(),b.processAttributes()},readCentralDir:function(){var a;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(g.CENTRAL_FILE_HEADER);)a=new h({zip64:this.zip64},this.loadOptions),a.readCentralPart(this.reader),this.files.push(a);if(this.centralDirRecords!==this.files.length&&
+this+"' has already been used.");this.isLocked=!0;this.previous&&this.previous.lock()},toString:function(){var a="Worker "+this.name;return this.previous?this.previous+" -> "+a:a}};f.exports=a},{}],29:[function(b,f,d){function a(a,b){var c,e=0,d;for(c=d=0;c<b.length;c++)d+=b[c].length;switch(a){case "string":return b.join("");case "array":return Array.prototype.concat.apply([],b);case "uint8array":d=new Uint8Array(d);for(c=0;c<b.length;c++)d.set(b[c],e),e+=b[c].length;return d;case "nodebuffer":return Buffer.concat(b);
+default:throw Error("concat : unsupported type '"+a+"'");}}function e(b,c){return new q.Promise(function(e,d){var x=[],t=b._internalType,p=b._outputType,A=b._mimeType;b.on("data",function(a,b){x.push(a);c&&c(b)}).on("error",function(a){x=[];d(a)}).on("end",function(){try{var b;a:{var c=x,z=null;switch(p){case "blob":b=g.newBlob(c,A);break a;case "base64":b=(z=a(t,c),n.encode(z));break a;default:b=(z=a(t,c),g.transformTo(p,z))}}e(b)}catch(u){d(u)}x=[]}).resume()})}function c(a,b,c){var e=b;switch(b){case "blob":e=
+"arraybuffer";break;case "arraybuffer":e="uint8array";break;case "base64":e="string"}try{this._internalType=e,this._outputType=b,this._mimeType=c,g.checkSupport(e),this._worker=a.pipe(new l(e)),a.lock()}catch(x){this._worker=new h("error"),this._worker.error(x)}}var g=b("../utils"),l=b("./ConvertWorker"),h=b("./GenericWorker"),n=b("../base64");d=b("../support");var q=b("../external"),t=null;if(d.nodestream)try{t=b("../nodejs/NodejsStreamOutputAdapter")}catch(A){}c.prototype={accumulate:function(a){return e(this,
+a)},on:function(a,b){var c=this;return"data"===a?this._worker.on(a,function(a){b.call(c,a.data,a.meta)}):this._worker.on(a,function(){g.delay(b,arguments,c)}),this},resume:function(){return g.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(a){if(g.checkSupport("nodestream"),"nodebuffer"!==this._outputType)throw Error(this._outputType+" is not supported by this method");return new t(this,{objectMode:"nodebuffer"!==this._outputType},
+a)}};f.exports=c},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(b,f,d){if(d.base64=!0,d.array=!0,d.string=!0,d.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,d.nodebuffer="undefined"!=typeof Buffer,d.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)d.blob=!1;else{f=new ArrayBuffer(0);try{d.blob=0===(new Blob([f],{type:"application/zip"})).size}catch(e){try{var a=
+new (window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder);a.append(f);d.blob=0===a.getBlob("application/zip").size}catch(c){d.blob=!1}}}try{d.nodestream=!!b("readable-stream").Readable}catch(e){d.nodestream=!1}},{"readable-stream":16}],31:[function(b,f,d){function a(){h.call(this,"utf-8 decode");this.leftOver=null}function e(){h.call(this,"utf-8 encode")}var c=b("./utils"),g=b("./support"),l=b("./nodejsUtils"),h=b("./stream/GenericWorker"),n=Array(256);for(b=
+0;256>b;b++)n[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;n[254]=n[254]=1;d.utf8encode=function(a){if(g.nodebuffer)a=l.newBuffer(a,"utf-8");else{var b,c,e,d,z,x=a.length,n=0;for(d=0;d<x;d++)c=a.charCodeAt(d),55296===(64512&c)&&d+1<x&&(e=a.charCodeAt(d+1),56320===(64512&e)&&(c=65536+(c-55296<<10)+(e-56320),d++)),n+=128>c?1:2048>c?2:65536>c?3:4;b=g.uint8array?new Uint8Array(n):Array(n);for(d=z=0;z<n;d++)c=a.charCodeAt(d),55296===(64512&c)&&d+1<x&&(e=a.charCodeAt(d+1),56320===(64512&e)&&(c=65536+
+(c-55296<<10)+(e-56320),d++)),128>c?b[z++]=c:2048>c?(b[z++]=192|c>>>6,b[z++]=128|63&c):65536>c?(b[z++]=224|c>>>12,b[z++]=128|c>>>6&63,b[z++]=128|63&c):(b[z++]=240|c>>>18,b[z++]=128|c>>>12&63,b[z++]=128|c>>>6&63,b[z++]=128|63&c);a=b}return a};d.utf8decode=function(a){var b;if(g.nodebuffer)b=c.transformTo("nodebuffer",a).toString("utf-8");else{var e=a=c.transformTo(g.uint8array?"uint8array":"array",a),d,l,z,x=e.length;a=Array(2*x);for(d=l=0;d<x;)if(b=e[d++],128>b)a[l++]=b;else if(z=n[b],4<z)a[l++]=
+65533,d+=z-1;else{for(b&=2===z?31:3===z?15:7;1<z&&d<x;)b=b<<6|63&e[d++],z--;1<z?a[l++]=65533:65536>b?a[l++]=b:(b-=65536,a[l++]=55296|b>>10&1023,a[l++]=56320|1023&b)}b=(a.length!==l&&(a.subarray?a=a.subarray(0,l):a.length=l),c.applyFromCharCode(a))}return b};c.inherits(a,h);a.prototype.processChunk=function(a){var b=c.transformTo(g.uint8array?"uint8array":"array",a.data);if(this.leftOver&&this.leftOver.length){if(g.uint8array){var e=b,b=new Uint8Array(e.length+this.leftOver.length);b.set(this.leftOver,
+0);b.set(e,this.leftOver.length)}else b=this.leftOver.concat(b);this.leftOver=null}var l,e=b.length;e>b.length&&(e=b.length);for(l=e-1;0<=l&&128===(192&b[l]);)l--;e=0>l?e:0===l?e:l+n[b[l]]>e?l:e;l=b;e!==b.length&&(g.uint8array?(l=b.subarray(0,e),this.leftOver=b.subarray(e,b.length)):(l=b.slice(0,e),this.leftOver=b.slice(e,b.length)));this.push({data:d.utf8decode(l),meta:a.meta})};a.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:d.utf8decode(this.leftOver),meta:{}}),
+this.leftOver=null)};d.Utf8DecodeWorker=a;c.inherits(e,h);e.prototype.processChunk=function(a){this.push({data:d.utf8encode(a.data),meta:a.meta})};d.Utf8EncodeWorker=e},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(b,f,d){function a(a){return a}function e(a,b){for(var c=0;c<a.length;++c)b[c]=255&a.charCodeAt(c);return b}function c(a){var b=65536,c=d.getTypeOf(a),e=!0;if("uint8array"===c?e=G.applyCanBeUsed.uint8array:"nodebuffer"===c&&(e=G.applyCanBeUsed.nodebuffer),
+e)for(;1<b;)try{return G.stringifyByChunk(a,c,b)}catch(m){b=Math.floor(b/2)}return G.stringifyByChar(a)}function g(a,b){for(var c=0;c<a.length;c++)b[c]=a[c];return b}var l=b("./support"),h=b("./base64"),n=b("./nodejsUtils"),q=b("core-js/library/fn/set-immediate"),t=b("./external");d.newBlob=function(a,b){d.checkSupport("blob");try{return new Blob(a,{type:b})}catch(m){try{for(var c=new (window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder),e=0;e<a.length;e++)c.append(a[e]);
+return c.getBlob(b)}catch(O){throw Error("Bug : can't construct the Blob.");}}};var A;try{A=l.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(x){A=!1}b=A;var B;try{B=l.nodebuffer&&1===String.fromCharCode.apply(null,n.newBuffer(1)).length}catch(x){B=!1}var G={stringifyByChunk:function(a,b,c){var e=[],d=0,p=a.length;if(p<=c)return String.fromCharCode.apply(null,a);for(;d<p;)"array"===b||"nodebuffer"===b?e.push(String.fromCharCode.apply(null,a.slice(d,Math.min(d+c,p)))):
+e.push(String.fromCharCode.apply(null,a.subarray(d,Math.min(d+c,p)))),d+=c;return e.join("")},stringifyByChar:function(a){for(var b="",c=0;c<a.length;c++)b+=String.fromCharCode(a[c]);return b},applyCanBeUsed:{uint8array:b,nodebuffer:B}};d.applyFromCharCode=c;var z={};z.string={string:a,array:function(a){return e(a,Array(a.length))},arraybuffer:function(a){return z.string.uint8array(a).buffer},uint8array:function(a){return e(a,new Uint8Array(a.length))},nodebuffer:function(a){return e(a,n.newBuffer(a.length))}};
+z.array={string:c,array:a,arraybuffer:function(a){return(new Uint8Array(a)).buffer},uint8array:function(a){return new Uint8Array(a)},nodebuffer:function(a){return n.newBuffer(a)}};z.arraybuffer={string:function(a){return c(new Uint8Array(a))},array:function(a){return g(new Uint8Array(a),Array(a.byteLength))},arraybuffer:a,uint8array:function(a){return new Uint8Array(a)},nodebuffer:function(a){return n.newBuffer(new Uint8Array(a))}};z.uint8array={string:c,array:function(a){return g(a,Array(a.length))},
+arraybuffer:function(a){var b=new Uint8Array(a.length);return a.length&&b.set(a,0),b.buffer},uint8array:a,nodebuffer:function(a){return n.newBuffer(a)}};z.nodebuffer={string:c,array:function(a){return g(a,Array(a.length))},arraybuffer:function(a){return z.nodebuffer.uint8array(a).buffer},uint8array:function(a){return g(a,new Uint8Array(a.length))},nodebuffer:a};d.transformTo=function(a,b){if(b||(b=""),!a)return b;d.checkSupport(a);var c=d.getTypeOf(b);return z[c][a](b)};d.getTypeOf=function(a){return"string"==
+typeof a?"string":"[object Array]"===Object.prototype.toString.call(a)?"array":l.nodebuffer&&n.isBuffer(a)?"nodebuffer":l.uint8array&&a instanceof Uint8Array?"uint8array":l.arraybuffer&&a instanceof ArrayBuffer?"arraybuffer":void 0};d.checkSupport=function(a){if(!l[a.toLowerCase()])throw Error(a+" is not supported by this platform");};d.MAX_VALUE_16BITS=65535;d.MAX_VALUE_32BITS=-1;d.pretty=function(a){var b,c,e="";for(c=0;c<(a||"").length;c++)b=a.charCodeAt(c),e+="\\x"+(16>b?"0":"")+b.toString(16).toUpperCase();
+return e};d.delay=function(a,b,c){q(function(){a.apply(c||null,b||[])})};d.inherits=function(a,b){var c=function(){};c.prototype=b.prototype;a.prototype=new c};d.extend=function(){var a,b,c={};for(a=0;a<arguments.length;a++)for(b in arguments[a])arguments[a].hasOwnProperty(b)&&"undefined"==typeof c[b]&&(c[b]=arguments[a][b]);return c};d.prepareContent=function(a,b,c,g,n){return t.Promise.resolve(b).then(function(a){return l.blob&&(a instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(a)))&&
+"undefined"!=typeof FileReader?new t.Promise(function(b,c){var e=new FileReader;e.onload=function(a){b(a.target.result)};e.onerror=function(a){c(a.target.error)};e.readAsArrayBuffer(a)}):a}).then(function(b){var p=d.getTypeOf(b);p?"arraybuffer"===p?b=d.transformTo("uint8array",b):"string"===p&&(n?b=h.decode(b):c&&!0!==g&&(p=null,b=(p=l.uint8array?new Uint8Array(b.length):Array(b.length),e(b,p)))):b=t.Promise.reject(Error("The data of '"+a+"' is in an unsupported format !"));return b})}},{"./base64":1,
+"./external":6,"./nodejsUtils":14,"./support":30,"core-js/library/fn/set-immediate":36}],33:[function(b,f,d){function a(a){this.files=[];this.loadOptions=a}var e=b("./reader/readerFor"),c=b("./utils"),g=b("./signature"),l=b("./zipEntry"),h=(b("./utf8"),b("./support"));a.prototype={checkSignature:function(a){if(!this.reader.readAndCheckSignature(a)){this.reader.index-=4;var b=this.reader.readString(4);throw Error("Corrupted zip or bug : unexpected signature ("+c.pretty(b)+", expected "+c.pretty(a)+
+")");}},isSignature:function(a,b){var c=this.reader.index;this.reader.setIndex(a);var e=this.reader.readString(4)===b;return this.reader.setIndex(c),e},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2);this.diskWithCentralDirStart=this.reader.readInt(2);this.centralDirRecordsOnThisDisk=this.reader.readInt(2);this.centralDirRecords=this.reader.readInt(2);this.centralDirSize=this.reader.readInt(4);this.centralDirOffset=this.reader.readInt(4);this.zipCommentLength=this.reader.readInt(2);
+var a=this.reader.readData(this.zipCommentLength),a=c.transformTo(h.uint8array?"uint8array":"array",a);this.zipComment=this.loadOptions.decodeFileName(a)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8);this.reader.skip(4);this.diskNumber=this.reader.readInt(4);this.diskWithCentralDirStart=this.reader.readInt(4);this.centralDirRecordsOnThisDisk=this.reader.readInt(8);this.centralDirRecords=this.reader.readInt(8);this.centralDirSize=this.reader.readInt(8);this.centralDirOffset=
+this.reader.readInt(8);this.zip64ExtensibleData={};for(var a,b,c,e=this.zip64EndOfCentralSize-44;0<e;)a=this.reader.readInt(2),b=this.reader.readInt(4),c=this.reader.readData(b),this.zip64ExtensibleData[a]={id:a,length:b,value:c}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw Error("Multi-volumes zip are not supported");
+},readLocalFiles:function(){var a,b;for(a=0;a<this.files.length;a++)b=this.files[a],this.reader.setIndex(b.localHeaderOffset),this.checkSignature(g.LOCAL_FILE_HEADER),b.readLocalPart(this.reader),b.handleUTF8(),b.processAttributes()},readCentralDir:function(){var a;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(g.CENTRAL_FILE_HEADER);)a=new l({zip64:this.zip64},this.loadOptions),a.readCentralPart(this.reader),this.files.push(a);if(this.centralDirRecords!==this.files.length&&
 0!==this.centralDirRecords&&0===this.files.length)throw Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length);},readEndOfCentral:function(){var a=this.reader.lastIndexOfSignature(g.CENTRAL_DIRECTORY_END);if(0>a)throw this.isSignature(0,g.LOCAL_FILE_HEADER)?Error("Corrupted zip : can't find end of central directory"):Error("Can't find end of central directory : is this a zip file ? If it is, see http://stuk.github.io/jszip/documentation/howto/read_zip.html");
-this.reader.setIndex(a);var b=a;if(this.checkSignature(g.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===d.MAX_VALUE_16BITS||this.diskWithCentralDirStart===d.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===d.MAX_VALUE_16BITS||this.centralDirRecords===d.MAX_VALUE_16BITS||this.centralDirSize===d.MAX_VALUE_32BITS||this.centralDirOffset===d.MAX_VALUE_32BITS){if(this.zip64=!0,a=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR),0>a)throw Error("Corrupted zip : can't find the ZIP64 end of central directory locator");
+this.reader.setIndex(a);var b=a;if(this.checkSignature(g.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===c.MAX_VALUE_16BITS||this.diskWithCentralDirStart===c.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===c.MAX_VALUE_16BITS||this.centralDirRecords===c.MAX_VALUE_16BITS||this.centralDirSize===c.MAX_VALUE_32BITS||this.centralDirOffset===c.MAX_VALUE_32BITS){if(this.zip64=!0,a=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR),0>a)throw Error("Corrupted zip : can't find the ZIP64 end of central directory locator");
 if(this.reader.setIndex(a),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,g.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_END),0>this.relativeOffsetEndOfZip64CentralDir))throw Error("Corrupted zip : can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir);this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_END);
 this.readBlockZip64EndOfCentral()}a=this.centralDirOffset+this.centralDirSize;this.zip64&&(a+=20,a+=12+this.zip64EndOfCentralSize);a=b-a;if(0<a)this.isSignature(b,g.CENTRAL_FILE_HEADER)||(this.reader.zero=a);else if(0>a)throw Error("Corrupted zip: missing "+Math.abs(a)+" bytes.");},prepareReader:function(a){this.reader=e(a)},load:function(a){this.prepareReader(a);this.readEndOfCentral();this.readCentralDir();this.readLocalFiles()}};f.exports=a},{"./reader/readerFor":22,"./signature":23,"./support":30,
-"./utf8":31,"./utils":32,"./zipEntry":34}],34:[function(b,f,c){function a(a,b){this.options=a;this.loadOptions=b}var e=b("./reader/readerFor"),d=b("./utils"),g=b("./compressedObject"),h=b("./crc32"),l=b("./utf8"),n=b("./compressions"),q=b("./support");a.prototype={isEncrypted:function(){return 1===(1&this.bitFlag)},useUTF8:function(){return 2048===(2048&this.bitFlag)},readLocalPart:function(a){var b,e;if(a.skip(22),this.fileNameLength=a.readInt(2),e=a.readInt(2),this.fileName=a.readData(this.fileNameLength),
-a.skip(e),-1===this.compressedSize||-1===this.uncompressedSize)throw Error("Bug or corrupted zip : didn't get enough informations from the central directory (compressedSize === -1 || uncompressedSize === -1)");var c;a:{e=this.compressionMethod;for(c in n)if(n.hasOwnProperty(c)&&n[c].magic===e){c=n[c];break a}c=null}if(b=c,null===b)throw Error("Corrupted zip : compression "+d.pretty(this.compressionMethod)+" unknown (inner file : "+d.transformTo("string",this.fileName)+")");this.decompressed=new g(this.compressedSize,
+"./utf8":31,"./utils":32,"./zipEntry":34}],34:[function(b,f,d){function a(a,b){this.options=a;this.loadOptions=b}var e=b("./reader/readerFor"),c=b("./utils"),g=b("./compressedObject"),l=b("./crc32"),h=b("./utf8"),n=b("./compressions"),q=b("./support");a.prototype={isEncrypted:function(){return 1===(1&this.bitFlag)},useUTF8:function(){return 2048===(2048&this.bitFlag)},readLocalPart:function(a){var b,e;if(a.skip(22),this.fileNameLength=a.readInt(2),e=a.readInt(2),this.fileName=a.readData(this.fileNameLength),
+a.skip(e),-1===this.compressedSize||-1===this.uncompressedSize)throw Error("Bug or corrupted zip : didn't get enough informations from the central directory (compressedSize === -1 || uncompressedSize === -1)");var d;a:{e=this.compressionMethod;for(d in n)if(n.hasOwnProperty(d)&&n[d].magic===e){d=n[d];break a}d=null}if(b=d,null===b)throw Error("Corrupted zip : compression "+c.pretty(this.compressionMethod)+" unknown (inner file : "+c.transformTo("string",this.fileName)+")");this.decompressed=new g(this.compressedSize,
 this.uncompressedSize,this.crc32,b,a.readData(this.compressedSize))},readCentralPart:function(a){this.versionMadeBy=a.readInt(2);a.skip(2);this.bitFlag=a.readInt(2);this.compressionMethod=a.readString(2);this.date=a.readDate();this.crc32=a.readInt(4);this.compressedSize=a.readInt(4);this.uncompressedSize=a.readInt(4);var b=a.readInt(2);if(this.extraFieldsLength=a.readInt(2),this.fileCommentLength=a.readInt(2),this.diskNumberStart=a.readInt(2),this.internalFileAttributes=a.readInt(2),this.externalFileAttributes=
 a.readInt(4),this.localHeaderOffset=a.readInt(4),this.isEncrypted())throw Error("Encrypted zip are not supported");a.skip(b);this.readExtraFields(a);this.parseZIP64ExtraField(a);this.fileComment=a.readData(this.fileCommentLength)},processAttributes:function(){this.dosPermissions=this.unixPermissions=null;var a=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes);0===a&&(this.dosPermissions=63&this.externalFileAttributes);3===a&&(this.unixPermissions=this.externalFileAttributes>>16&65535);
-this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(a){this.extraFields[1]&&(a=e(this.extraFields[1].value),this.uncompressedSize===d.MAX_VALUE_32BITS&&(this.uncompressedSize=a.readInt(8)),this.compressedSize===d.MAX_VALUE_32BITS&&(this.compressedSize=a.readInt(8)),this.localHeaderOffset===d.MAX_VALUE_32BITS&&(this.localHeaderOffset=a.readInt(8)),this.diskNumberStart===d.MAX_VALUE_32BITS&&(this.diskNumberStart=a.readInt(4)))},readExtraFields:function(a){var b,
-d,e,c=a.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});a.index<c;)b=a.readInt(2),d=a.readInt(2),e=a.readData(d),this.extraFields[b]={id:b,length:d,value:e}},handleUTF8:function(){var a=q.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=l.utf8decode(this.fileName),this.fileCommentStr=l.utf8decode(this.fileComment);else{var b=this.findExtraFieldUnicodePath();null!==b?this.fileNameStr=b:(b=d.transformTo(a,this.fileName),this.fileNameStr=this.loadOptions.decodeFileName(b));
-b=this.findExtraFieldUnicodeComment();null!==b?this.fileCommentStr=b:(a=d.transformTo(a,this.fileComment),this.fileCommentStr=this.loadOptions.decodeFileName(a))}},findExtraFieldUnicodePath:function(){var a=this.extraFields[28789];if(a){var b=e(a.value);return 1!==b.readInt(1)?null:h(this.fileName)!==b.readInt(4)?null:l.utf8decode(b.readData(a.length-5))}return null},findExtraFieldUnicodeComment:function(){var a=this.extraFields[25461];if(a){var b=e(a.value);return 1!==b.readInt(1)?null:h(this.fileComment)!==
-b.readInt(4)?null:l.utf8decode(b.readData(a.length-5))}return null}};f.exports=a},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(b,f,c){var a=b("./stream/StreamHelper"),e=b("./stream/DataWorker"),d=b("./utf8"),g=b("./compressedObject"),h=b("./stream/GenericWorker");b=function(a,b,d){this.name=a;this.dir=d.dir;this.date=d.date;this.comment=d.comment;this.unixPermissions=d.unixPermissions;this.dosPermissions=d.dosPermissions;
-this._data=b;this._dataBinary=d.binary;this.options={compression:d.compression,compressionOptions:d.compressionOptions}};b.prototype={internalStream:function(b){b=b.toLowerCase();var e="string"===b||"text"===b;"binarystring"!==b&&"text"!==b||(b="string");var c=this._decompressWorker(),f=!this._dataBinary;return f&&!e&&(c=c.pipe(new d.Utf8EncodeWorker)),!f&&e&&(c=c.pipe(new d.Utf8DecodeWorker)),new a(c,b,"")},async:function(a,b){return this.internalStream(a).accumulate(b)},nodeStream:function(a,b){return this.internalStream(a||
-"nodebuffer").toNodejsStream(b)},_compressWorker:function(a,b){if(this._data instanceof g&&this._data.compression.magic===a.magic)return this._data.getCompressedWorker();var e=this._decompressWorker();return this._dataBinary||(e=e.pipe(new d.Utf8EncodeWorker)),g.createWorkerFrom(e,a,b)},_decompressWorker:function(){return this._data instanceof g?this._data.getContentWorker():this._data instanceof h?this._data:new e(this._data)}};c=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"];
-for(var l=function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.");},n=0;n<c.length;n++)b.prototype[c[n]]=l;f.exports=b},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(b,f,c){b("../modules/web.immediate");f.exports=b("../modules/_core").setImmediate},{"../modules/_core":40,"../modules/web.immediate":56}],37:[function(b,f,c){f.exports=function(a){if("function"!=typeof a)throw TypeError(a+
-" is not a function!");return a}},{}],38:[function(b,f,c){var a=b("./_is-object");f.exports=function(b){if(!a(b))throw TypeError(b+" is not an object!");return b}},{"./_is-object":51}],39:[function(b,f,c){var a={}.toString;f.exports=function(b){return a.call(b).slice(8,-1)}},{}],40:[function(b,f,c){b=f.exports={version:"2.3.0"};"number"==typeof __e&&(__e=b)},{}],41:[function(b,f,c){var a=b("./_a-function");f.exports=function(b,d,c){if(a(b),void 0===d)return b;switch(c){case 1:return function(a){return b.call(d,
-a)};case 2:return function(a,e){return b.call(d,a,e)};case 3:return function(a,e,c){return b.call(d,a,e,c)}}return function(){return b.apply(d,arguments)}}},{"./_a-function":37}],42:[function(b,f,c){f.exports=!b("./_fails")(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},{"./_fails":45}],43:[function(b,f,c){c=b("./_is-object");var a=b("./_global").document,e=c(a)&&c(a.createElement);f.exports=function(b){return e?a.createElement(b):{}}},{"./_global":46,"./_is-object":51}],
-44:[function(b,f,c){var a=b("./_global"),e=b("./_core"),d=b("./_ctx"),g=b("./_hide"),h=function(b,c,f){var l,n,q=b&h.F,D=b&h.G,H=b&h.S,v=b&h.P,z=b&h.B,t=b&h.W,E=D?e:e[c]||(e[c]={}),m=E.prototype,H=D?a:H?a[c]:(a[c]||{}).prototype;D&&(f=c);for(l in f)(c=!q&&H&&void 0!==H[l])&&l in E||(n=c?H[l]:f[l],E[l]=D&&"function"!=typeof H[l]?f[l]:z&&c?d(n,a):t&&H[l]==n?function(a){var b=function(b,d,x){if(this instanceof a){switch(arguments.length){case 0:return new a;case 1:return new a(b);case 2:return new a(b,
-d)}return new a(b,d,x)}return a.apply(this,arguments)};return b.prototype=a.prototype,b}(n):v&&"function"==typeof n?d(Function.call,n):n,v&&((E.virtual||(E.virtual={}))[l]=n,b&h.R&&m&&!m[l]&&g(m,l,n)))};h.F=1;h.G=2;h.S=4;h.P=8;h.B=16;h.W=32;h.U=64;h.R=128;f.exports=h},{"./_core":40,"./_ctx":41,"./_global":46,"./_hide":47}],45:[function(b,f,c){f.exports=function(a){try{return!!a()}catch(e){return!0}}},{}],46:[function(b,f,c){b=f.exports="undefined"!=typeof window&&Math==Math?window:"undefined"!=typeof self&&
-self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=b)},{}],47:[function(b,f,c){var a=b("./_object-dp"),e=b("./_property-desc");f.exports=b("./_descriptors")?function(b,c,f){return a.f(b,c,e(1,f))}:function(a,b,e){return a[b]=e,a}},{"./_descriptors":42,"./_object-dp":52,"./_property-desc":53}],48:[function(b,f,c){f.exports=b("./_global").document&&document.documentElement},{"./_global":46}],49:[function(b,f,c){f.exports=!b("./_descriptors")&&!b("./_fails")(function(){return 7!=
-Object.defineProperty(b("./_dom-create")("div"),"a",{get:function(){return 7}}).a})},{"./_descriptors":42,"./_dom-create":43,"./_fails":45}],50:[function(b,f,c){f.exports=function(a,b,d){var c=void 0===d;switch(b.length){case 0:return c?a():a.call(d);case 1:return c?a(b[0]):a.call(d,b[0]);case 2:return c?a(b[0],b[1]):a.call(d,b[0],b[1]);case 3:return c?a(b[0],b[1],b[2]):a.call(d,b[0],b[1],b[2]);case 4:return c?a(b[0],b[1],b[2],b[3]):a.call(d,b[0],b[1],b[2],b[3])}return a.apply(d,b)}},{}],51:[function(b,
-f,c){f.exports=function(a){return"object"==typeof a?null!==a:"function"==typeof a}},{}],52:[function(b,f,c){var a=b("./_an-object"),e=b("./_ie8-dom-define"),d=b("./_to-primitive"),g=Object.defineProperty;c.f=b("./_descriptors")?Object.defineProperty:function(b,c,f){if(a(b),c=d(c,!0),a(f),e)try{return g(b,c,f)}catch(q){}if("get"in f||"set"in f)throw TypeError("Accessors not supported!");return"value"in f&&(b[c]=f.value),b}},{"./_an-object":38,"./_descriptors":42,"./_ie8-dom-define":49,"./_to-primitive":55}],
-53:[function(b,f,c){f.exports=function(a,b){return{enumerable:!(1&a),configurable:!(2&a),writable:!(4&a),value:b}}},{}],54:[function(b,f,c){var a,e,d,g=b("./_ctx"),h=b("./_invoke"),l=b("./_html"),n=b("./_dom-create"),q=b("./_global"),u=q.process;c=q.setImmediate;var y=q.clearImmediate,F=q.MessageChannel,D=0,H={},v=function(){var a=+this;if(H.hasOwnProperty(a)){var b=H[a];delete H[a];b()}},z=function(a){v.call(a.data)};c&&y||(c=function(b){for(var d=[],c=1;arguments.length>c;)d.push(arguments[c++]);
-return H[++D]=function(){h("function"==typeof b?b:Function(b),d)},a(D),D},y=function(a){delete H[a]},"process"==b("./_cof")(u)?a=function(a){u.nextTick(g(v,a,1))}:F?(e=new F,d=e.port2,e.port1.onmessage=z,a=g(d.postMessage,d,1)):q.addEventListener&&"function"==typeof postMessage&&!q.importScripts?(a=function(a){q.postMessage(a+"","*")},q.addEventListener("message",z,!1)):a="onreadystatechange"in n("script")?function(a){l.appendChild(n("script")).onreadystatechange=function(){l.removeChild(this);v.call(a)}}:
-function(a){setTimeout(g(v,a,1),0)});f.exports={set:c,clear:y}},{"./_cof":39,"./_ctx":41,"./_dom-create":43,"./_global":46,"./_html":48,"./_invoke":50}],55:[function(b,f,c){var a=b("./_is-object");f.exports=function(b,d){if(!a(b))return b;var c,e;if(d&&"function"==typeof(c=b.toString)&&!a(e=c.call(b))||"function"==typeof(c=b.valueOf)&&!a(e=c.call(b))||!d&&"function"==typeof(c=b.toString)&&!a(e=c.call(b)))return e;throw TypeError("Can't convert object to primitive value");}},{"./_is-object":51}],56:[function(b,
-f,c){f=b("./_export");b=b("./_task");f(f.G+f.B,{setImmediate:b.set,clearImmediate:b.clear})},{"./_export":44,"./_task":54}],57:[function(b,f,c){(function(a){function b(){q=!0;for(var a,b,d=u.length;d;){b=u;u=[];for(a=-1;++a<d;)b[a]();d=u.length}q=!1}var d,c=a.MutationObserver||a.WebKitMutationObserver;if(c){var h=0,c=new c(b),l=a.document.createTextNode("");c.observe(l,{characterData:!0});d=function(){l.data=h=++h%2}}else if(a.setImmediate||"undefined"==typeof a.MessageChannel)d="document"in a&&"onreadystatechange"in
-a.document.createElement("script")?function(){var d=a.document.createElement("script");d.onreadystatechange=function(){b();d.onreadystatechange=null;d.parentNode.removeChild(d);d=null};a.document.documentElement.appendChild(d)}:function(){setTimeout(b,0)};else{var n=new a.MessageChannel;n.port1.onmessage=b;d=function(){n.port2.postMessage(0)}}var q,u=[];f.exports=function(a){1!==u.push(a)||q||d()}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?
-window:{})},{}],58:[function(b,f,c){function a(){}function e(b){if("function"!=typeof b)throw new TypeError("resolver must be a function");this.state=D;this.queue=[];this.outcome=void 0;b!==a&&l(this,b)}function d(a,b,d){this.promise=a;"function"==typeof b&&(this.onFulfilled=b,this.callFulfilled=this.otherCallFulfilled);"function"==typeof d&&(this.onRejected=d,this.callRejected=this.otherCallRejected)}function g(a,b,d){q(function(){var c;try{c=b(d)}catch(E){return u.reject(a,E)}c===a?u.reject(a,new TypeError("Cannot resolve promise with itself")):
-u.resolve(a,c)})}function h(a){var b=a&&a.then;if(a&&"object"==typeof a&&"function"==typeof b)return function(){b.apply(a,arguments)}}function l(a,b){function d(b){e||(e=!0,u.reject(a,b))}function c(b){e||(e=!0,u.resolve(a,b))}var e=!1,f=n(function(){b(c,d)});"error"===f.status&&d(f.value)}function n(a,b){var d={};try{d.value=a(b),d.status="success"}catch(t){d.status="error",d.value=t}return d}var q=b("immediate"),u={},y=["REJECTED"],F=["FULFILLED"],D=["PENDING"];f.exports=e;e.prototype["catch"]=
-function(a){return this.then(null,a)};e.prototype.then=function(b,c){if("function"!=typeof b&&this.state===F||"function"!=typeof c&&this.state===y)return this;var e=new this.constructor(a);this.state!==D?g(e,this.state===F?b:c,this.outcome):this.queue.push(new d(e,b,c));return e};d.prototype.callFulfilled=function(a){u.resolve(this.promise,a)};d.prototype.otherCallFulfilled=function(a){g(this.promise,this.onFulfilled,a)};d.prototype.callRejected=function(a){u.reject(this.promise,a)};d.prototype.otherCallRejected=
-function(a){g(this.promise,this.onRejected,a)};u.resolve=function(a,b){var d=n(h,b);if("error"===d.status)return u.reject(a,d.value);if(d=d.value)l(a,d);else{a.state=F;a.outcome=b;for(var d=-1,c=a.queue.length;++d<c;)a.queue[d].callFulfilled(b)}return a};u.reject=function(a,b){a.state=y;a.outcome=b;for(var d=-1,c=a.queue.length;++d<c;)a.queue[d].callRejected(b);return a};e.resolve=function(b){return b instanceof this?b:u.resolve(new this(a),b)};e.reject=function(b){var d=new this(a);return u.reject(d,
-b)};e.all=function(b){function d(a,b){c.resolve(a).then(function(a){g[b]=a;++h!==e||f||(f=!0,u.resolve(p,g))},function(a){f||(f=!0,u.reject(p,a))})}var c=this;if("[object Array]"!==Object.prototype.toString.call(b))return this.reject(new TypeError("must be an array"));var e=b.length,f=!1;if(!e)return this.resolve([]);for(var g=Array(e),h=0,l=-1,p=new this(a);++l<e;)d(b[l],l);return p};e.race=function(b){function d(a){c.resolve(a).then(function(a){f||(f=!0,u.resolve(l,a))},function(a){f||(f=!0,u.reject(l,
-a))})}var c=this;if("[object Array]"!==Object.prototype.toString.call(b))return this.reject(new TypeError("must be an array"));var e=b.length,f=!1;if(!e)return this.resolve([]);for(var g=-1,l=new this(a);++g<e;)d(b[g]);return l}},{immediate:57}],59:[function(b,f,c){c=b("./lib/utils/common").assign;var a=b("./lib/deflate"),e=b("./lib/inflate");b=b("./lib/zlib/constants");var d={};c(d,a,e,b);f.exports=d},{"./lib/deflate":60,"./lib/inflate":61,"./lib/utils/common":62,"./lib/zlib/constants":65}],60:[function(b,
-f,c){function a(b){if(!(this instanceof a))return new a(b);b=this.options=g.assign({level:y,method:D,chunkSize:16384,windowBits:15,memLevel:8,strategy:F,to:""},b||{});b.raw&&0<b.windowBits?b.windowBits=-b.windowBits:b.gzip&&0<b.windowBits&&16>b.windowBits&&(b.windowBits+=16);this.err=0;this.msg="";this.ended=!1;this.chunks=[];this.strm=new n;this.strm.avail_out=0;var c=d.deflateInit2(this.strm,b.level,b.method,b.windowBits,b.memLevel,b.strategy);if(c!==u)throw Error(l[c]);if(b.header&&d.deflateSetHeader(this.strm,
-b.header),b.dictionary){var e;if(e="string"==typeof b.dictionary?h.string2buf(b.dictionary):"[object ArrayBuffer]"===q.call(b.dictionary)?new Uint8Array(b.dictionary):b.dictionary,c=d.deflateSetDictionary(this.strm,e),c!==u)throw Error(l[c]);this._dict_set=!0}}function e(b,d){var c=new a(d);if(c.push(b,!0),c.err)throw c.msg;return c.result}var d=b("./zlib/deflate"),g=b("./utils/common"),h=b("./utils/strings"),l=b("./zlib/messages"),n=b("./zlib/zstream"),q=Object.prototype.toString,u=0,y=-1,F=0,D=
-8;a.prototype.push=function(a,b){var c,e,f=this.strm,l=this.options.chunkSize;if(this.ended)return!1;e=b===~~b?b:!0===b?4:0;"string"==typeof a?f.input=h.string2buf(a):"[object ArrayBuffer]"===q.call(a)?f.input=new Uint8Array(a):f.input=a;f.next_in=0;f.avail_in=f.input.length;do{if(0===f.avail_out&&(f.output=new g.Buf8(l),f.next_out=0,f.avail_out=l),c=d.deflate(f,e),1!==c&&c!==u)return this.onEnd(c),this.ended=!0,!1;0!==f.avail_out&&(0!==f.avail_in||4!==e&&2!==e)||("string"===this.options.to?this.onData(h.buf2binstring(g.shrinkBuf(f.output,
-f.next_out))):this.onData(g.shrinkBuf(f.output,f.next_out)))}while((0<f.avail_in||0===f.avail_out)&&1!==c);return 4===e?(c=d.deflateEnd(this.strm),this.onEnd(c),this.ended=!0,c===u):2!==e||(this.onEnd(u),f.avail_out=0,!0)};a.prototype.onData=function(a){this.chunks.push(a)};a.prototype.onEnd=function(a){a===u&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=g.flattenChunks(this.chunks));this.chunks=[];this.err=a;this.msg=this.strm.msg};c.Deflate=a;c.deflate=e;c.deflateRaw=
-function(a,b){return b=b||{},b.raw=!0,e(a,b)};c.gzip=function(a,b){return b=b||{},b.gzip=!0,e(a,b)}},{"./utils/common":62,"./utils/strings":63,"./zlib/deflate":67,"./zlib/messages":72,"./zlib/zstream":74}],61:[function(b,f,c){function a(b){if(!(this instanceof a))return new a(b);var c=this.options=g.assign({chunkSize:16384,windowBits:0,to:""},b||{});c.raw&&0<=c.windowBits&&16>c.windowBits&&(c.windowBits=-c.windowBits,0===c.windowBits&&(c.windowBits=-15));!(0<=c.windowBits&&16>c.windowBits)||b&&b.windowBits||
-(c.windowBits+=32);15<c.windowBits&&48>c.windowBits&&0===(15&c.windowBits)&&(c.windowBits|=15);this.err=0;this.msg="";this.ended=!1;this.chunks=[];this.strm=new q;this.strm.avail_out=0;b=d.inflateInit2(this.strm,c.windowBits);if(b!==l.Z_OK)throw Error(n[b]);this.header=new u;d.inflateGetHeader(this.strm,this.header)}function e(b,d){var c=new a(d);if(c.push(b,!0),c.err)throw c.msg;return c.result}var d=b("./zlib/inflate"),g=b("./utils/common"),h=b("./utils/strings"),l=b("./zlib/constants"),n=b("./zlib/messages"),
-q=b("./zlib/zstream"),u=b("./zlib/gzheader"),y=Object.prototype.toString;a.prototype.push=function(a,b){var c,e,f,t,n,m,q=this.strm,C=this.options.chunkSize,p=this.options.dictionary,I=!1;if(this.ended)return!1;e=b===~~b?b:!0===b?l.Z_FINISH:l.Z_NO_FLUSH;"string"==typeof a?q.input=h.binstring2buf(a):"[object ArrayBuffer]"===y.call(a)?q.input=new Uint8Array(a):q.input=a;q.next_in=0;q.avail_in=q.input.length;do{if(0===q.avail_out&&(q.output=new g.Buf8(C),q.next_out=0,q.avail_out=C),c=d.inflate(q,l.Z_NO_FLUSH),
-c===l.Z_NEED_DICT&&p&&(m="string"==typeof p?h.string2buf(p):"[object ArrayBuffer]"===y.call(p)?new Uint8Array(p):p,c=d.inflateSetDictionary(this.strm,m)),c===l.Z_BUF_ERROR&&!0===I&&(c=l.Z_OK,I=!1),c!==l.Z_STREAM_END&&c!==l.Z_OK)return this.onEnd(c),this.ended=!0,!1;q.next_out&&(0!==q.avail_out&&c!==l.Z_STREAM_END&&(0!==q.avail_in||e!==l.Z_FINISH&&e!==l.Z_SYNC_FLUSH)||("string"===this.options.to?(f=h.utf8border(q.output,q.next_out),t=q.next_out-f,n=h.buf2string(q.output,f),q.next_out=t,q.avail_out=
-C-t,t&&g.arraySet(q.output,q.output,f,t,0),this.onData(n)):this.onData(g.shrinkBuf(q.output,q.next_out))));0===q.avail_in&&0===q.avail_out&&(I=!0)}while((0<q.avail_in||0===q.avail_out)&&c!==l.Z_STREAM_END);return c===l.Z_STREAM_END&&(e=l.Z_FINISH),e===l.Z_FINISH?(c=d.inflateEnd(this.strm),this.onEnd(c),this.ended=!0,c===l.Z_OK):e!==l.Z_SYNC_FLUSH||(this.onEnd(l.Z_OK),q.avail_out=0,!0)};a.prototype.onData=function(a){this.chunks.push(a)};a.prototype.onEnd=function(a){a===l.Z_OK&&("string"===this.options.to?
-this.result=this.chunks.join(""):this.result=g.flattenChunks(this.chunks));this.chunks=[];this.err=a;this.msg=this.strm.msg};c.Inflate=a;c.inflate=e;c.inflateRaw=function(a,b){return b=b||{},b.raw=!0,e(a,b)};c.ungzip=e},{"./utils/common":62,"./utils/strings":63,"./zlib/constants":65,"./zlib/gzheader":68,"./zlib/inflate":70,"./zlib/messages":72,"./zlib/zstream":74}],62:[function(b,f,c){b="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;c.assign=function(a){for(var b=
-Array.prototype.slice.call(arguments,1);b.length;){var d=b.shift();if(d){if("object"!=typeof d)throw new TypeError(d+"must be non-object");for(var c in d)d.hasOwnProperty(c)&&(a[c]=d[c])}}return a};c.shrinkBuf=function(a,b){return a.length===b?a:a.subarray?a.subarray(0,b):(a.length=b,a)};var a={arraySet:function(a,b,c,e,f){if(b.subarray&&a.subarray)return void a.set(b.subarray(c,c+e),f);for(var d=0;d<e;d++)a[f+d]=b[c+d]},flattenChunks:function(a){var b,d,c,e,f;b=c=0;for(d=a.length;b<d;b++)c+=a[b].length;
-f=new Uint8Array(c);b=c=0;for(d=a.length;b<d;b++)e=a[b],f.set(e,c),c+=e.length;return f}},e={arraySet:function(a,b,c,e,f){for(var d=0;d<e;d++)a[f+d]=b[c+d]},flattenChunks:function(a){return[].concat.apply([],a)}};c.setTyped=function(b){b?(c.Buf8=Uint8Array,c.Buf16=Uint16Array,c.Buf32=Int32Array,c.assign(c,a)):(c.Buf8=Array,c.Buf16=Array,c.Buf32=Array,c.assign(c,e))};c.setTyped(b)},{}],63:[function(b,f,c){function a(a,b){if(65537>b&&(a.subarray&&g||!a.subarray&&d))return String.fromCharCode.apply(null,
-e.shrinkBuf(a,b));for(var c="",f=0;f<b;f++)c+=String.fromCharCode(a[f]);return c}var e=b("./common"),d=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch(l){d=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(l){g=!1}var h=new e.Buf8(256);for(b=0;256>b;b++)h[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;h[254]=h[254]=1;c.string2buf=function(a){var b,d,c,f,g,h=a.length,l=0;for(f=0;f<h;f++)d=a.charCodeAt(f),55296===(64512&d)&&f+1<h&&(c=a.charCodeAt(f+1),56320===(64512&c)&&(d=65536+
-(d-55296<<10)+(c-56320),f++)),l+=128>d?1:2048>d?2:65536>d?3:4;b=new e.Buf8(l);for(f=g=0;g<l;f++)d=a.charCodeAt(f),55296===(64512&d)&&f+1<h&&(c=a.charCodeAt(f+1),56320===(64512&c)&&(d=65536+(d-55296<<10)+(c-56320),f++)),128>d?b[g++]=d:2048>d?(b[g++]=192|d>>>6,b[g++]=128|63&d):65536>d?(b[g++]=224|d>>>12,b[g++]=128|d>>>6&63,b[g++]=128|63&d):(b[g++]=240|d>>>18,b[g++]=128|d>>>12&63,b[g++]=128|d>>>6&63,b[g++]=128|63&d);return b};c.buf2binstring=function(b){return a(b,b.length)};c.binstring2buf=function(a){for(var b=
-new e.Buf8(a.length),d=0,c=b.length;d<c;d++)b[d]=a.charCodeAt(d);return b};c.buf2string=function(b,d){var c,e,f,g,l=d||b.length,n=Array(2*l);for(c=e=0;c<l;)if(f=b[c++],128>f)n[e++]=f;else if(g=h[f],4<g)n[e++]=65533,c+=g-1;else{for(f&=2===g?31:3===g?15:7;1<g&&c<l;)f=f<<6|63&b[c++],g--;1<g?n[e++]=65533:65536>f?n[e++]=f:(f-=65536,n[e++]=55296|f>>10&1023,n[e++]=56320|1023&f)}return a(n,e)};c.utf8border=function(a,b){var d;b=b||a.length;b>a.length&&(b=a.length);for(d=b-1;0<=d&&128===(192&a[d]);)d--;return 0>
-d?b:0===d?b:d+h[a[d]]>b?d:b}},{"./common":62}],64:[function(b,f,c){f.exports=function(a,b,d,c){var e=65535&a|0;a=a>>>16&65535|0;for(var f;0!==d;){f=2E3<d?2E3:d;d-=f;do e=e+b[c++]|0,a=a+e|0;while(--f);e%=65521;a%=65521}return e|a<<16|0}},{}],65:[function(b,f,c){f.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,
-Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],66:[function(b,f,c){var a=function(){for(var a,b=[],c=0;256>c;c++){a=c;for(var f=0;8>f;f++)a=1&a?3988292384^a>>>1:a>>>1;b[c]=a}return b}();f.exports=function(b,d,c,f){c=f+c;for(b^=-1;f<c;f++)b=b>>>8^a[255&(b^d[f])];return b^-1}},{}],67:[function(b,f,c){function a(a,b){return a.msg=p[b],b}function e(a){for(var b=a.length;0<=--b;)a[b]=0}function d(a){var b=
-a.state,d=b.pending;d>a.avail_out&&(d=a.avail_out);0!==d&&(E.arraySet(a.output,b.pending_buf,b.pending_out,d,a.next_out),a.next_out+=d,b.pending_out+=d,a.total_out+=d,a.avail_out-=d,b.pending-=d,0===b.pending&&(b.pending_out=0))}function g(a,b){m._tr_flush_block(a,0<=a.block_start?a.block_start:-1,a.strstart-a.block_start,b);a.block_start=a.strstart;d(a.strm)}function h(a,b){a.pending_buf[a.pending++]=b}function l(a,b){a.pending_buf[a.pending++]=b>>>8&255;a.pending_buf[a.pending++]=255&b}function n(a,
-b){var d,c,x=a.max_chain_length,e=a.strstart,L=a.prev_length,f=a.nice_match,p=a.strstart>a.w_size-Q?a.strstart-(a.w_size-Q):0,g=a.window,t=a.w_mask,h=a.prev,l=a.strstart+J,I=g[e+L-1],E=g[e+L];a.prev_length>=a.good_match&&(x>>=2);f>a.lookahead&&(f=a.lookahead);do if(d=b,g[d+L]===E&&g[d+L-1]===I&&g[d]===g[e]&&g[++d]===g[e+1]){e+=2;for(d++;g[++e]===g[++d]&&g[++e]===g[++d]&&g[++e]===g[++d]&&g[++e]===g[++d]&&g[++e]===g[++d]&&g[++e]===g[++d]&&g[++e]===g[++d]&&g[++e]===g[++d]&&e<l;);if(c=J-(l-e),e=l-J,c>
-L){if(a.match_start=b,L=c,c>=f)break;I=g[e+L-1];E=g[e+L]}}while((b=h[b&t])>p&&0!==--x);return L<=a.lookahead?L:a.lookahead}function q(a){var b,d,c,e,x=a.w_size;do{if(e=a.window_size-a.lookahead-a.strstart,a.strstart>=x+(x-Q)){E.arraySet(a.window,a.window,x,x,0);a.match_start-=x;a.strstart-=x;a.block_start-=x;b=d=a.hash_size;do c=a.head[--b],a.head[b]=c>=x?c-x:0;while(--d);b=d=x;do c=a.prev[--b],a.prev[b]=c>=x?c-x:0;while(--d);e+=x}if(0===a.strm.avail_in)break;b=a.strm;c=a.window;var f=a.strstart+
-a.lookahead,L=b.avail_in;if(d=(L>e&&(L=e),0===L?0:(b.avail_in-=L,E.arraySet(c,b.input,b.next_in,L,f),1===b.state.wrap?b.adler=P(b.adler,c,L,f):2===b.state.wrap&&(b.adler=C(b.adler,c,L,f)),b.next_in+=L,b.total_in+=L,L)),a.lookahead+=d,a.lookahead+a.insert>=A)for(e=a.strstart-a.insert,a.ins_h=a.window[e],a.ins_h=(a.ins_h<<a.hash_shift^a.window[e+1])&a.hash_mask;a.insert&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[e+A-1])&a.hash_mask,a.prev[e&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=e,e++,a.insert--,
-!(a.lookahead+a.insert<A)););}while(a.lookahead<Q&&0!==a.strm.avail_in)}function u(a,b){for(var d,c;;){if(a.lookahead<Q){if(q(a),a.lookahead<Q&&b===I)return M;if(0===a.lookahead)break}if(d=0,a.lookahead>=A&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+A-1])&a.hash_mask,d=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),0!==d&&a.strstart-d<=a.w_size-Q&&(a.match_length=n(a,d)),a.match_length>=A)if(c=m._tr_tally(a,a.strstart-a.match_start,a.match_length-A),a.lookahead-=
-a.match_length,a.match_length<=a.max_lazy_match&&a.lookahead>=A){a.match_length--;do a.strstart++,a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+A-1])&a.hash_mask,d=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart;while(0!==--a.match_length);a.strstart++}else a.strstart+=a.match_length,a.match_length=0,a.ins_h=a.window[a.strstart],a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+1])&a.hash_mask;else c=m._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++;if(c&&
-(g(a,!1),0===a.strm.avail_out))return M}return a.insert=a.strstart<A-1?a.strstart:A-1,b===x?(g(a,!0),0===a.strm.avail_out?W:R):a.last_lit&&(g(a,!1),0===a.strm.avail_out)?M:U}function y(a,b){for(var d,c,e;;){if(a.lookahead<Q){if(q(a),a.lookahead<Q&&b===I)return M;if(0===a.lookahead)break}if(d=0,a.lookahead>=A&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+A-1])&a.hash_mask,d=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),a.prev_length=a.match_length,a.prev_match=a.match_start,
-a.match_length=A-1,0!==d&&a.prev_length<a.max_lazy_match&&a.strstart-d<=a.w_size-Q&&(a.match_length=n(a,d),5>=a.match_length&&(a.strategy===X||a.match_length===A&&4096<a.strstart-a.match_start)&&(a.match_length=A-1)),a.prev_length>=A&&a.match_length<=a.prev_length){e=a.strstart+a.lookahead-A;c=m._tr_tally(a,a.strstart-1-a.prev_match,a.prev_length-A);a.lookahead-=a.prev_length-1;a.prev_length-=2;do++a.strstart<=e&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+A-1])&a.hash_mask,d=a.prev[a.strstart&
-a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart);while(0!==--a.prev_length);if(a.match_available=0,a.match_length=A-1,a.strstart++,c&&(g(a,!1),0===a.strm.avail_out))return M}else if(a.match_available){if(c=m._tr_tally(a,0,a.window[a.strstart-1]),c&&g(a,!1),a.strstart++,a.lookahead--,0===a.strm.avail_out)return M}else a.match_available=1,a.strstart++,a.lookahead--}return a.match_available&&(m._tr_tally(a,0,a.window[a.strstart-1]),a.match_available=0),a.insert=a.strstart<A-1?a.strstart:A-1,b===
-x?(g(a,!0),0===a.strm.avail_out?W:R):a.last_lit&&(g(a,!1),0===a.strm.avail_out)?M:U}function F(a,b,d,c,e){this.good_length=a;this.max_lazy=b;this.nice_length=d;this.max_chain=c;this.func=e}function D(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=V;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=
-this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=this.ins_h=0;this.dyn_ltree=new E.Buf16(2*ba);this.dyn_dtree=new E.Buf16(2*(2*ca+1));this.bl_tree=new E.Buf16(2*(2*B+1));e(this.dyn_ltree);e(this.dyn_dtree);e(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new E.Buf16(K+
-1);this.heap=new E.Buf16(2*da+1);e(this.heap);this.heap_max=this.heap_len=0;this.depth=new E.Buf16(2*da+1);e(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function H(b){var d;return b&&b.state?(b.total_in=b.total_out=0,b.data_type=aa,d=b.state,d.pending=0,d.pending_out=0,0>d.wrap&&(d.wrap=-d.wrap),d.status=d.wrap?Z:Y,b.adler=2===d.wrap?0:1,d.last_flush=I,m._tr_init(d),S):a(b,O)}function v(a){var b=
-H(a);b===S&&(a=a.state,a.window_size=2*a.w_size,e(a.head),a.max_lazy_match=t[a.level].max_lazy,a.good_match=t[a.level].good_length,a.nice_match=t[a.level].nice_length,a.max_chain_length=t[a.level].max_chain,a.strstart=0,a.block_start=0,a.lookahead=0,a.insert=0,a.match_length=a.prev_length=A-1,a.match_available=0,a.ins_h=0);return b}function z(b,d,c,e,x,f){if(!b)return O;var k=1;if(d===G&&(d=6),0>e?(k=0,e=-e):15<e&&(k=2,e-=16),1>x||x>r||c!==V||8>e||15<e||0>d||9<d||0>f||f>T)return a(b,O);8===e&&(e=
-9);var N=new D;return b.state=N,N.strm=b,N.wrap=k,N.gzhead=null,N.w_bits=e,N.w_size=1<<N.w_bits,N.w_mask=N.w_size-1,N.hash_bits=x+7,N.hash_size=1<<N.hash_bits,N.hash_mask=N.hash_size-1,N.hash_shift=~~((N.hash_bits+A-1)/A),N.window=new E.Buf8(2*N.w_size),N.head=new E.Buf16(N.hash_size),N.prev=new E.Buf16(N.w_size),N.lit_bufsize=1<<x+6,N.pending_buf_size=4*N.lit_bufsize,N.pending_buf=new E.Buf8(N.pending_buf_size),N.d_buf=1*N.lit_bufsize,N.l_buf=3*N.lit_bufsize,N.level=d,N.strategy=f,N.method=c,v(b)}
-var t,E=b("../utils/common"),m=b("./trees"),P=b("./adler32"),C=b("./crc32"),p=b("./messages"),I=0,x=4,S=0,O=-2,G=-1,X=1,T=4,aa=2,V=8,r=9,da=286,ca=30,B=19,ba=2*da+1,K=15,A=3,J=258,Q=J+A+1,Z=42,Y=113,M=1,U=2,W=3,R=4;t=[new F(0,0,0,0,function(a,b){var d=65535;for(d>a.pending_buf_size-5&&(d=a.pending_buf_size-5);;){if(1>=a.lookahead){if(q(a),0===a.lookahead&&b===I)return M;if(0===a.lookahead)break}a.strstart+=a.lookahead;a.lookahead=0;var c=a.block_start+d;if((0===a.strstart||a.strstart>=c)&&(a.lookahead=
-a.strstart-c,a.strstart=c,g(a,!1),0===a.strm.avail_out)||a.strstart-a.block_start>=a.w_size-Q&&(g(a,!1),0===a.strm.avail_out))return M}return a.insert=0,b===x?(g(a,!0),0===a.strm.avail_out?W:R):(a.strstart>a.block_start&&g(a,!1),M)}),new F(4,4,8,4,u),new F(4,5,16,8,u),new F(4,6,32,32,u),new F(4,4,16,16,y),new F(8,16,32,32,y),new F(8,16,128,128,y),new F(8,32,128,256,y),new F(32,128,258,1024,y),new F(32,258,258,4096,y)];c.deflateInit=function(a,b){return z(a,b,V,15,8,0)};c.deflateInit2=z;c.deflateReset=
-v;c.deflateResetKeep=H;c.deflateSetHeader=function(a,b){return a&&a.state?2!==a.state.wrap?O:(a.state.gzhead=b,S):O};c.deflate=function(b,c){var f,k,p,E;if(!b||!b.state||5<c||0>c)return b?a(b,O):O;if(k=b.state,!b.output||!b.input&&0!==b.avail_in||666===k.status&&c!==x)return a(b,0===b.avail_out?-5:O);if(k.strm=b,f=k.last_flush,k.last_flush=c,k.status===Z)2===k.wrap?(b.adler=0,h(k,31),h(k,139),h(k,8),k.gzhead?(h(k,(k.gzhead.text?1:0)+(k.gzhead.hcrc?2:0)+(k.gzhead.extra?4:0)+(k.gzhead.name?8:0)+(k.gzhead.comment?
-16:0)),h(k,255&k.gzhead.time),h(k,k.gzhead.time>>8&255),h(k,k.gzhead.time>>16&255),h(k,k.gzhead.time>>24&255),h(k,9===k.level?2:2<=k.strategy||2>k.level?4:0),h(k,255&k.gzhead.os),k.gzhead.extra&&k.gzhead.extra.length&&(h(k,255&k.gzhead.extra.length),h(k,k.gzhead.extra.length>>8&255)),k.gzhead.hcrc&&(b.adler=C(b.adler,k.pending_buf,k.pending,0)),k.gzindex=0,k.status=69):(h(k,0),h(k,0),h(k,0),h(k,0),h(k,0),h(k,9===k.level?2:2<=k.strategy||2>k.level?4:0),h(k,3),k.status=Y)):(p=V+(k.w_bits-8<<4)<<8,p|=
-(2<=k.strategy||2>k.level?0:6>k.level?1:6===k.level?2:3)<<6,0!==k.strstart&&(p|=32),k.status=Y,l(k,p+(31-p%31)),0!==k.strstart&&(l(k,b.adler>>>16),l(k,65535&b.adler)),b.adler=1);if(69===k.status)if(k.gzhead.extra){for(p=k.pending;k.gzindex<(65535&k.gzhead.extra.length)&&(k.pending!==k.pending_buf_size||(k.gzhead.hcrc&&k.pending>p&&(b.adler=C(b.adler,k.pending_buf,k.pending-p,p)),d(b),p=k.pending,k.pending!==k.pending_buf_size));)h(k,255&k.gzhead.extra[k.gzindex]),k.gzindex++;k.gzhead.hcrc&&k.pending>
-p&&(b.adler=C(b.adler,k.pending_buf,k.pending-p,p));k.gzindex===k.gzhead.extra.length&&(k.gzindex=0,k.status=73)}else k.status=73;if(73===k.status)if(k.gzhead.name){p=k.pending;do{if(k.pending===k.pending_buf_size&&(k.gzhead.hcrc&&k.pending>p&&(b.adler=C(b.adler,k.pending_buf,k.pending-p,p)),d(b),p=k.pending,k.pending===k.pending_buf_size)){E=1;break}E=k.gzindex<k.gzhead.name.length?255&k.gzhead.name.charCodeAt(k.gzindex++):0;h(k,E)}while(0!==E);k.gzhead.hcrc&&k.pending>p&&(b.adler=C(b.adler,k.pending_buf,
-k.pending-p,p));0===E&&(k.gzindex=0,k.status=91)}else k.status=91;if(91===k.status)if(k.gzhead.comment){p=k.pending;do{if(k.pending===k.pending_buf_size&&(k.gzhead.hcrc&&k.pending>p&&(b.adler=C(b.adler,k.pending_buf,k.pending-p,p)),d(b),p=k.pending,k.pending===k.pending_buf_size)){E=1;break}E=k.gzindex<k.gzhead.comment.length?255&k.gzhead.comment.charCodeAt(k.gzindex++):0;h(k,E)}while(0!==E);k.gzhead.hcrc&&k.pending>p&&(b.adler=C(b.adler,k.pending_buf,k.pending-p,p));0===E&&(k.status=103)}else k.status=
-103;if(103===k.status&&(k.gzhead.hcrc?(k.pending+2>k.pending_buf_size&&d(b),k.pending+2<=k.pending_buf_size&&(h(k,255&b.adler),h(k,b.adler>>8&255),b.adler=0,k.status=Y)):k.status=Y),0!==k.pending){if(d(b),0===b.avail_out)return k.last_flush=-1,S}else if(0===b.avail_in&&(c<<1)-(4<c?9:0)<=(f<<1)-(4<f?9:0)&&c!==x)return a(b,-5);if(666===k.status&&0!==b.avail_in)return a(b,-5);if(0!==b.avail_in||0!==k.lookahead||c!==I&&666!==k.status){var n;if(2===k.strategy)a:{for(var r;;){if(0===k.lookahead&&(q(k),
-0===k.lookahead)){if(c===I){n=M;break a}break}if(k.match_length=0,r=m._tr_tally(k,0,k.window[k.strstart]),k.lookahead--,k.strstart++,r&&(g(k,!1),0===k.strm.avail_out)){n=M;break a}}n=(k.insert=0,c===x?(g(k,!0),0===k.strm.avail_out?W:R):k.last_lit&&(g(k,!1),0===k.strm.avail_out)?M:U)}else if(3===k.strategy)a:{var G,v;for(r=k.window;;){if(k.lookahead<=J){if(q(k),k.lookahead<=J&&c===I){n=M;break a}if(0===k.lookahead)break}if(k.match_length=0,k.lookahead>=A&&0<k.strstart&&(v=k.strstart-1,G=r[v],G===r[++v]&&
-G===r[++v]&&G===r[++v])){for(f=k.strstart+J;G===r[++v]&&G===r[++v]&&G===r[++v]&&G===r[++v]&&G===r[++v]&&G===r[++v]&&G===r[++v]&&G===r[++v]&&v<f;);k.match_length=J-(f-v);k.match_length>k.lookahead&&(k.match_length=k.lookahead)}if(k.match_length>=A?(n=m._tr_tally(k,1,k.match_length-A),k.lookahead-=k.match_length,k.strstart+=k.match_length,k.match_length=0):(n=m._tr_tally(k,0,k.window[k.strstart]),k.lookahead--,k.strstart++),n&&(g(k,!1),0===k.strm.avail_out)){n=M;break a}}n=(k.insert=0,c===x?(g(k,!0),
-0===k.strm.avail_out?W:R):k.last_lit&&(g(k,!1),0===k.strm.avail_out)?M:U)}else n=t[k.level].func(k,c);if(n!==W&&n!==R||(k.status=666),n===M||n===W)return 0===b.avail_out&&(k.last_flush=-1),S;if(n===U&&(1===c?m._tr_align(k):5!==c&&(m._tr_stored_block(k,0,0,!1),3===c&&(e(k.head),0===k.lookahead&&(k.strstart=0,k.block_start=0,k.insert=0))),d(b),0===b.avail_out))return k.last_flush=-1,S}return c!==x?S:0>=k.wrap?1:(2===k.wrap?(h(k,255&b.adler),h(k,b.adler>>8&255),h(k,b.adler>>16&255),h(k,b.adler>>24&255),
-h(k,255&b.total_in),h(k,b.total_in>>8&255),h(k,b.total_in>>16&255),h(k,b.total_in>>24&255)):(l(k,b.adler>>>16),l(k,65535&b.adler)),d(b),0<k.wrap&&(k.wrap=-k.wrap),0!==k.pending?S:1)};c.deflateEnd=function(b){var d;return b&&b.state?(d=b.state.status,d!==Z&&69!==d&&73!==d&&91!==d&&103!==d&&d!==Y&&666!==d?a(b,O):(b.state=null,d===Y?a(b,-3):S)):O};c.deflateSetDictionary=function(a,b){var d,c,x,f,p,g,t;c=b.length;if(!a||!a.state||(d=a.state,f=d.wrap,2===f||1===f&&d.status!==Z||d.lookahead))return O;1===
-f&&(a.adler=P(a.adler,b,c,0));d.wrap=0;c>=d.w_size&&(0===f&&(e(d.head),d.strstart=0,d.block_start=0,d.insert=0),p=new E.Buf8(d.w_size),E.arraySet(p,b,c-d.w_size,d.w_size,0),b=p,c=d.w_size);p=a.avail_in;g=a.next_in;t=a.input;a.avail_in=c;a.next_in=0;a.input=b;for(q(d);d.lookahead>=A;){c=d.strstart;x=d.lookahead-(A-1);do d.ins_h=(d.ins_h<<d.hash_shift^d.window[c+A-1])&d.hash_mask,d.prev[c&d.w_mask]=d.head[d.ins_h],d.head[d.ins_h]=c,c++;while(--x);d.strstart=c;d.lookahead=A-1;q(d)}return d.strstart+=
-d.lookahead,d.block_start=d.strstart,d.insert=d.lookahead,d.lookahead=0,d.match_length=d.prev_length=A-1,d.match_available=0,a.next_in=g,a.input=t,a.avail_in=p,d.wrap=f,S};c.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":62,"./adler32":64,"./crc32":66,"./messages":72,"./trees":73}],68:[function(b,f,c){f.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],69:[function(b,f,c){f.exports=
-function(a,b){var d,c,e,f,n,q,u,y,F,D,H,v,z,t,E,m,P,C,p,I,x,S,O,G;d=a.state;c=a.next_in;O=a.input;e=c+(a.avail_in-5);f=a.next_out;G=a.output;n=f-(b-a.avail_out);q=f+(a.avail_out-257);u=d.dmax;y=d.wsize;F=d.whave;D=d.wnext;H=d.window;v=d.hold;z=d.bits;t=d.lencode;E=d.distcode;m=(1<<d.lenbits)-1;P=(1<<d.distbits)-1;a:do b:for(15>z&&(v+=O[c++]<<z,z+=8,v+=O[c++]<<z,z+=8),C=t[v&m];;){if(p=C>>>24,v>>>=p,z-=p,p=C>>>16&255,0===p)G[f++]=65535&C;else{if(!(16&p)){if(0===(64&p)){C=t[(65535&C)+(v&(1<<p)-1)];continue b}if(32&
-p){d.mode=12;break a}a.msg="invalid literal/length code";d.mode=30;break a}I=65535&C;(p&=15)&&(z<p&&(v+=O[c++]<<z,z+=8),I+=v&(1<<p)-1,v>>>=p,z-=p);15>z&&(v+=O[c++]<<z,z+=8,v+=O[c++]<<z,z+=8);C=E[v&P];c:for(;;){if(p=C>>>24,v>>>=p,z-=p,p=C>>>16&255,!(16&p)){if(0===(64&p)){C=E[(65535&C)+(v&(1<<p)-1)];continue c}a.msg="invalid distance code";d.mode=30;break a}if(x=65535&C,p&=15,z<p&&(v+=O[c++]<<z,z+=8,z<p&&(v+=O[c++]<<z,z+=8)),x+=v&(1<<p)-1,x>u){a.msg="invalid distance too far back";d.mode=30;break a}if(v>>>=
-p,z-=p,p=f-n,x>p){if(p=x-p,p>F&&d.sane){a.msg="invalid distance too far back";d.mode=30;break a}if(C=0,S=H,0===D){if(C+=y-p,p<I){I-=p;do G[f++]=H[C++];while(--p);C=f-x;S=G}}else if(D<p){if(C+=y+D-p,p-=D,p<I){I-=p;do G[f++]=H[C++];while(--p);if(C=0,D<I){p=D;I-=p;do G[f++]=H[C++];while(--p);C=f-x;S=G}}}else if(C+=D-p,p<I){I-=p;do G[f++]=H[C++];while(--p);C=f-x;S=G}for(;2<I;)G[f++]=S[C++],G[f++]=S[C++],G[f++]=S[C++],I-=3;I&&(G[f++]=S[C++],1<I&&(G[f++]=S[C++]))}else{C=f-x;do G[f++]=G[C++],G[f++]=G[C++],
-G[f++]=G[C++],I-=3;while(2<I);I&&(G[f++]=G[C++],1<I&&(G[f++]=G[C++]))}break}}break}while(c<e&&f<q);I=z>>3;c-=I;z-=I<<3;a.next_in=c;a.next_out=f;a.avail_in=c<e?5+(e-c):5-(c-e);a.avail_out=f<q?257+(q-f):257-(f-q);d.hold=v&(1<<z)-1;d.bits=z}},{}],70:[function(b,f,c){function a(a){return(a>>>24&255)+(a>>>8&65280)+((65280&a)<<8)+((255&a)<<24)}function e(){this.mode=0;this.last=!1;this.wrap=0;this.havedict=!1;this.total=this.check=this.dmax=this.flags=0;this.head=null;this.wnext=this.whave=this.wsize=this.wbits=
-0;this.window=null;this.extra=this.offset=this.length=this.bits=this.hold=0;this.distcode=this.lencode=null;this.have=this.ndist=this.nlen=this.ncode=this.distbits=this.lenbits=0;this.next=null;this.lens=new y.Buf16(320);this.work=new y.Buf16(288);this.distdyn=this.lendyn=null;this.was=this.back=this.sane=0}function d(a){var b;return a&&a.state?(b=a.state,a.total_in=a.total_out=b.total=0,a.msg="",b.wrap&&(a.adler=1&b.wrap),b.mode=E,b.last=0,b.havedict=0,b.dmax=32768,b.head=null,b.hold=0,b.bits=0,
-b.lencode=b.lendyn=new y.Buf32(m),b.distcode=b.distdyn=new y.Buf32(P),b.sane=1,b.back=-1,z):t}function g(a){var b;return a&&a.state?(b=a.state,b.wsize=0,b.whave=0,b.wnext=0,d(a)):t}function h(a,b){var d,c;return a&&a.state?(c=a.state,0>b?(d=0,b=-b):(d=(b>>4)+1,48>b&&(b&=15)),b&&(8>b||15<b)?t:(null!==c.window&&c.wbits!==b&&(c.window=null),c.wrap=d,c.wbits=b,g(a))):t}function l(a,b){var d,c;return a?(c=new e,a.state=c,c.window=null,d=h(a,b),d!==z&&(a.state=null),d):t}function n(a,b,d,c){var e;a=a.state;
-return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new y.Buf8(a.wsize)),c>=a.wsize?(y.arraySet(a.window,b,d-a.wsize,a.wsize,0),a.wnext=0,a.whave=a.wsize):(e=a.wsize-a.wnext,e>c&&(e=c),y.arraySet(a.window,b,d-c,e,a.wnext),c-=e,c?(y.arraySet(a.window,b,d-c,c,0),a.wnext=c,a.whave=a.wsize):(a.wnext+=e,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=e))),0}var q,u,y=b("../utils/common"),F=b("./adler32"),D=b("./crc32"),H=b("./inffast"),v=b("./inftrees"),z=0,t=-2,E=1,m=852,
-P=592,C=!0;c.inflateReset=g;c.inflateReset2=h;c.inflateResetKeep=d;c.inflateInit=function(a){return l(a,15)};c.inflateInit2=l;c.inflate=function(b,d){var c,e,f,g,p,h,l,m,r,I,P,B,ba,K,A,J,Q,Z,Y,M,U,W,R=0,L=new y.Buf8(4),ea=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||!b.output||!b.input&&0!==b.avail_in)return t;c=b.state;12===c.mode&&(c.mode=13);p=b.next_out;f=b.output;l=b.avail_out;g=b.next_in;e=b.input;h=b.avail_in;m=c.hold;r=c.bits;I=h;P=l;U=z;a:for(;;)switch(c.mode){case E:if(0===
-c.wrap){c.mode=13;break}for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(2&c.wrap&&35615===m){c.check=0;L[0]=255&m;L[1]=m>>>8&255;c.check=D(c.check,L,2,0);r=m=0;c.mode=2;break}if(c.flags=0,c.head&&(c.head.done=!1),!(1&c.wrap)||(((255&m)<<8)+(m>>8))%31){b.msg="incorrect header check";c.mode=30;break}if(8!==(15&m)){b.msg="unknown compression method";c.mode=30;break}if(m>>>=4,r-=4,M=(15&m)+8,0===c.wbits)c.wbits=M;else if(M>c.wbits){b.msg="invalid window size";c.mode=30;break}c.dmax=1<<M;b.adler=
-c.check=1;c.mode=512&m?10:12;r=m=0;break;case 2:for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(c.flags=m,8!==(255&c.flags)){b.msg="unknown compression method";c.mode=30;break}if(57344&c.flags){b.msg="unknown header flags set";c.mode=30;break}c.head&&(c.head.text=m>>8&1);512&c.flags&&(L[0]=255&m,L[1]=m>>>8&255,c.check=D(c.check,L,2,0));r=m=0;c.mode=3;case 3:for(;32>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.head&&(c.head.time=m);512&c.flags&&(L[0]=255&m,L[1]=m>>>8&255,L[2]=m>>>16&255,L[3]=
-m>>>24&255,c.check=D(c.check,L,4,0));r=m=0;c.mode=4;case 4:for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.head&&(c.head.xflags=255&m,c.head.os=m>>8);512&c.flags&&(L[0]=255&m,L[1]=m>>>8&255,c.check=D(c.check,L,2,0));r=m=0;c.mode=5;case 5:if(1024&c.flags){for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.length=m;c.head&&(c.head.extra_len=m);512&c.flags&&(L[0]=255&m,L[1]=m>>>8&255,c.check=D(c.check,L,2,0));r=m=0}else c.head&&(c.head.extra=null);c.mode=6;case 6:if(1024&c.flags&&(B=c.length,
-B>h&&(B=h),B&&(c.head&&(M=c.head.extra_len-c.length,c.head.extra||(c.head.extra=Array(c.head.extra_len)),y.arraySet(c.head.extra,e,g,B,M)),512&c.flags&&(c.check=D(c.check,e,B,g)),h-=B,g+=B,c.length-=B),c.length))break a;c.length=0;c.mode=7;case 7:if(2048&c.flags){if(0===h)break a;B=0;do M=e[g+B++],c.head&&M&&65536>c.length&&(c.head.name+=String.fromCharCode(M));while(M&&B<h);if(512&c.flags&&(c.check=D(c.check,e,B,g)),h-=B,g+=B,M)break a}else c.head&&(c.head.name=null);c.length=0;c.mode=8;case 8:if(4096&
-c.flags){if(0===h)break a;B=0;do M=e[g+B++],c.head&&M&&65536>c.length&&(c.head.comment+=String.fromCharCode(M));while(M&&B<h);if(512&c.flags&&(c.check=D(c.check,e,B,g)),h-=B,g+=B,M)break a}else c.head&&(c.head.comment=null);c.mode=9;case 9:if(512&c.flags){for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(m!==(65535&c.check)){b.msg="header crc mismatch";c.mode=30;break}r=m=0}c.head&&(c.head.hcrc=c.flags>>9&1,c.head.done=!0);b.adler=c.check=0;c.mode=12;break;case 10:for(;32>r;){if(0===h)break a;
-h--;m+=e[g++]<<r;r+=8}b.adler=c.check=a(m);r=m=0;c.mode=11;case 11:if(0===c.havedict)return b.next_out=p,b.avail_out=l,b.next_in=g,b.avail_in=h,c.hold=m,c.bits=r,2;b.adler=c.check=1;c.mode=12;case 12:if(5===d||6===d)break a;case 13:if(c.last){m>>>=7&r;r-=7&r;c.mode=27;break}for(;3>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}switch(c.last=1&m,m>>>=1,--r,3&m){case 0:c.mode=14;break;case 1:J=c;if(C){q=new y.Buf32(512);u=new y.Buf32(32);for(K=0;144>K;)J.lens[K++]=8;for(;256>K;)J.lens[K++]=9;for(;280>K;)J.lens[K++]=
-7;for(;288>K;)J.lens[K++]=8;v(1,J.lens,0,288,q,0,J.work,{bits:9});for(K=0;32>K;)J.lens[K++]=5;v(2,J.lens,0,32,u,0,J.work,{bits:5});C=!1}J.lencode=q;J.lenbits=9;J.distcode=u;J.distbits=5;if(c.mode=20,6===d){m>>>=2;r-=2;break a}break;case 2:c.mode=17;break;case 3:b.msg="invalid block type",c.mode=30}m>>>=2;r-=2;break;case 14:m>>>=7&r;for(r-=7&r;32>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if((65535&m)!==(m>>>16^65535)){b.msg="invalid stored block lengths";c.mode=30;break}if(c.length=65535&m,m=0,r=
-0,c.mode=15,6===d)break a;case 15:c.mode=16;case 16:if(B=c.length){if(B>h&&(B=h),B>l&&(B=l),0===B)break a;y.arraySet(f,e,g,B,p);h-=B;g+=B;l-=B;p+=B;c.length-=B;break}c.mode=12;break;case 17:for(;14>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(c.nlen=(31&m)+257,m>>>=5,r-=5,c.ndist=(31&m)+1,m>>>=5,r-=5,c.ncode=(15&m)+4,m>>>=4,r-=4,286<c.nlen||30<c.ndist){b.msg="too many length or distance symbols";c.mode=30;break}c.have=0;c.mode=18;case 18:for(;c.have<c.ncode;){for(;3>r;){if(0===h)break a;h--;m+=e[g++]<<
-r;r+=8}c.lens[ea[c.have++]]=7&m;m>>>=3;r-=3}for(;19>c.have;)c.lens[ea[c.have++]]=0;if(c.lencode=c.lendyn,c.lenbits=7,W={bits:c.lenbits},U=v(0,c.lens,0,19,c.lencode,0,c.work,W),c.lenbits=W.bits,U){b.msg="invalid code lengths set";c.mode=30;break}c.have=0;c.mode=19;case 19:for(;c.have<c.nlen+c.ndist;){for(;R=c.lencode[m&(1<<c.lenbits)-1],A=R>>>24,J=65535&R,!(A<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(16>J)m>>>=A,r-=A,c.lens[c.have++]=J;else{if(16===J){for(K=A+2;r<K;){if(0===h)break a;h--;m+=
-e[g++]<<r;r+=8}if(m>>>=A,r-=A,0===c.have){b.msg="invalid bit length repeat";c.mode=30;break}M=c.lens[c.have-1];B=3+(3&m);m>>>=2;r-=2}else if(17===J){for(K=A+3;r<K;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}m>>>=A;r-=A;M=0;B=3+(7&m);m>>>=3;r-=3}else{for(K=A+7;r<K;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}m>>>=A;r-=A;M=0;B=11+(127&m);m>>>=7;r-=7}if(c.have+B>c.nlen+c.ndist){b.msg="invalid bit length repeat";c.mode=30;break}for(;B--;)c.lens[c.have++]=M}}if(30===c.mode)break;if(0===c.lens[256]){b.msg="invalid code -- missing end-of-block";
-c.mode=30;break}if(c.lenbits=9,W={bits:c.lenbits},U=v(1,c.lens,0,c.nlen,c.lencode,0,c.work,W),c.lenbits=W.bits,U){b.msg="invalid literal/lengths set";c.mode=30;break}if(c.distbits=6,c.distcode=c.distdyn,W={bits:c.distbits},U=v(2,c.lens,c.nlen,c.ndist,c.distcode,0,c.work,W),c.distbits=W.bits,U){b.msg="invalid distances set";c.mode=30;break}if(c.mode=20,6===d)break a;case 20:c.mode=21;case 21:if(6<=h&&258<=l){b.next_out=p;b.avail_out=l;b.next_in=g;b.avail_in=h;c.hold=m;c.bits=r;H(b,P);p=b.next_out;
-f=b.output;l=b.avail_out;g=b.next_in;e=b.input;h=b.avail_in;m=c.hold;r=c.bits;12===c.mode&&(c.back=-1);break}for(c.back=0;R=c.lencode[m&(1<<c.lenbits)-1],A=R>>>24,K=R>>>16&255,J=65535&R,!(A<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(K&&0===(240&K)){Q=A;Z=K;for(Y=J;R=c.lencode[Y+((m&(1<<Q+Z)-1)>>Q)],A=R>>>24,K=R>>>16&255,J=65535&R,!(Q+A<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}m>>>=Q;r-=Q;c.back+=Q}if(m>>>=A,r-=A,c.back+=A,c.length=J,0===K){c.mode=26;break}if(32&K){c.back=-1;c.mode=12;break}if(64&
-K){b.msg="invalid literal/length code";c.mode=30;break}c.extra=15&K;c.mode=22;case 22:if(c.extra){for(K=c.extra;r<K;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.length+=m&(1<<c.extra)-1;m>>>=c.extra;r-=c.extra;c.back+=c.extra}c.was=c.length;c.mode=23;case 23:for(;R=c.distcode[m&(1<<c.distbits)-1],A=R>>>24,K=R>>>16&255,J=65535&R,!(A<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(0===(240&K)){Q=A;Z=K;for(Y=J;R=c.distcode[Y+((m&(1<<Q+Z)-1)>>Q)],A=R>>>24,K=R>>>16&255,J=65535&R,!(Q+A<=r);){if(0===h)break a;
-h--;m+=e[g++]<<r;r+=8}m>>>=Q;r-=Q;c.back+=Q}if(m>>>=A,r-=A,c.back+=A,64&K){b.msg="invalid distance code";c.mode=30;break}c.offset=J;c.extra=15&K;c.mode=24;case 24:if(c.extra){for(K=c.extra;r<K;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.offset+=m&(1<<c.extra)-1;m>>>=c.extra;r-=c.extra;c.back+=c.extra}if(c.offset>c.dmax){b.msg="invalid distance too far back";c.mode=30;break}c.mode=25;case 25:if(0===l)break a;if(B=P-l,c.offset>B){if(B=c.offset-B,B>c.whave&&c.sane){b.msg="invalid distance too far back";
-c.mode=30;break}B>c.wnext?(B-=c.wnext,ba=c.wsize-B):ba=c.wnext-B;B>c.length&&(B=c.length);K=c.window}else K=f,ba=p-c.offset,B=c.length;B>l&&(B=l);l-=B;c.length-=B;do f[p++]=K[ba++];while(--B);0===c.length&&(c.mode=21);break;case 26:if(0===l)break a;f[p++]=c.length;l--;c.mode=21;break;case 27:if(c.wrap){for(;32>r;){if(0===h)break a;h--;m|=e[g++]<<r;r+=8}if(P-=l,b.total_out+=P,c.total+=P,P&&(b.adler=c.check=c.flags?D(c.check,f,P,p-P):F(c.check,f,P,p-P)),P=l,(c.flags?m:a(m))!==c.check){b.msg="incorrect data check";
-c.mode=30;break}r=m=0}c.mode=28;case 28:if(c.wrap&&c.flags){for(;32>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(m!==(4294967295&c.total)){b.msg="incorrect length check";c.mode=30;break}r=m=0}c.mode=29;case 29:U=1;break a;case 30:U=-3;break a;case 31:return-4;default:return t}return b.next_out=p,b.avail_out=l,b.next_in=g,b.avail_in=h,c.hold=m,c.bits=r,(c.wsize||P!==b.avail_out&&30>c.mode&&(27>c.mode||4!==d))&&n(b,b.output,b.next_out,P-b.avail_out)?(c.mode=31,-4):(I-=b.avail_in,P-=b.avail_out,b.total_in+=
-I,b.total_out+=P,c.total+=P,c.wrap&&P&&(b.adler=c.check=c.flags?D(c.check,f,P,b.next_out-P):F(c.check,f,P,b.next_out-P)),b.data_type=c.bits+(c.last?64:0)+(12===c.mode?128:0)+(20===c.mode||15===c.mode?256:0),(0===I&&0===P||4===d)&&U===z&&(U=-5),U)};c.inflateEnd=function(a){if(!a||!a.state)return t;var b=a.state;return b.window&&(b.window=null),a.state=null,z};c.inflateGetHeader=function(a,b){var c;return a&&a.state?(c=a.state,0===(2&c.wrap)?t:(c.head=b,b.done=!1,z)):t};c.inflateSetDictionary=function(a,
-b){var c,d,e=b.length;return a&&a.state?(c=a.state,0!==c.wrap&&11!==c.mode?t:11===c.mode&&(d=1,d=F(d,b,e,0),d!==c.check)?-3:n(a,b,e,e)?(c.mode=31,-4):(c.havedict=1,z)):t};c.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":62,"./adler32":64,"./crc32":66,"./inffast":69,"./inftrees":71}],71:[function(b,f,c){var a=b("../utils/common"),e=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],d=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,
-19,19,19,20,20,20,20,21,21,21,21,16,72,78],g=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],h=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];f.exports=function(b,c,f,u,y,F,D,H){var l,n,t,E,m,P,C,p,I=H.bits,x,q,O,G,X,T,aa=0,V,r=null,da=0,ca=new a.Buf16(16);E=new a.Buf16(16);var B=null,ba=0;for(x=0;15>=x;x++)ca[x]=0;for(q=0;q<u;q++)ca[c[f+q]]++;G=I;for(O=15;1<=O&&0===ca[O];O--);
-if(G>O&&(G=O),0===O)return y[F++]=20971520,y[F++]=20971520,H.bits=1,0;for(I=1;I<O&&0===ca[I];I++);G<I&&(G=I);for(x=l=1;15>=x;x++)if(l<<=1,l-=ca[x],0>l)return-1;if(0<l&&(0===b||1!==O))return-1;E[1]=0;for(x=1;15>x;x++)E[x+1]=E[x]+ca[x];for(q=0;q<u;q++)0!==c[f+q]&&(D[E[c[f+q]]++]=q);if(0===b?(r=B=D,m=19):1===b?(r=e,da-=257,B=d,ba-=257,m=256):(r=g,B=h,m=-1),V=0,q=0,x=I,E=F,X=G,T=0,t=-1,aa=1<<G,u=aa-1,1===b&&852<aa||2===b&&592<aa)return 1;for(var K=0;;){K++;P=x-T;D[q]<m?(C=0,p=D[q]):D[q]>m?(C=B[ba+D[q]],
-p=r[da+D[q]]):(C=96,p=0);l=1<<x-T;I=n=1<<X;do n-=l,y[E+(V>>T)+n]=P<<24|C<<16|p|0;while(0!==n);for(l=1<<x-1;V&l;)l>>=1;if(0!==l?(V&=l-1,V+=l):V=0,q++,0===--ca[x]){if(x===O)break;x=c[f+D[q]]}if(x>G&&(V&u)!==t){0===T&&(T=G);E+=I;X=x-T;for(l=1<<X;X+T<O&&(l-=ca[X+T],!(0>=l));)X++,l<<=1;if(aa+=1<<X,1===b&&852<aa||2===b&&592<aa)return 1;t=V&u;y[t]=G<<24|X<<16|E-F|0}}return 0!==V&&(y[E+V]=x-T<<24|4194304),H.bits=G,0}},{"../utils/common":62}],72:[function(b,f,c){f.exports={2:"need dictionary",1:"stream end",
-0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],73:[function(b,f,c){function a(a){for(var b=a.length;0<=--b;)a[b]=0}function e(a,b,c,d,e){this.static_tree=a;this.extra_bits=b;this.extra_base=c;this.elems=d;this.max_length=e;this.has_stree=a&&a.length}function d(a,b){this.dyn_tree=a;this.max_code=0;this.stat_desc=b}function g(a,b){a.pending_buf[a.pending++]=255&b;a.pending_buf[a.pending++]=b>>>8&255}function h(a,
-b,c){a.bi_valid>aa-c?(a.bi_buf|=b<<a.bi_valid&65535,g(a,a.bi_buf),a.bi_buf=b>>aa-a.bi_valid,a.bi_valid+=c-aa):(a.bi_buf|=b<<a.bi_valid&65535,a.bi_valid+=c)}function l(a,b,c){h(a,c[2*b],c[2*b+1])}function n(a,b){var c=0;do c|=1&a,a>>>=1,c<<=1;while(0<--b);return c>>>1}function q(a,b,c){var d,e=Array(T+1),f=0;for(d=1;d<=T;d++)e[d]=f=f+c[d-1]<<1;for(c=0;c<=b;c++)d=a[2*c+1],0!==d&&(a[2*c]=n(e[d]++,d))}function u(a){var b;for(b=0;b<S;b++)a.dyn_ltree[2*b]=0;for(b=0;b<O;b++)a.dyn_dtree[2*b]=0;for(b=0;b<
-G;b++)a.bl_tree[2*b]=0;a.dyn_ltree[2*V]=1;a.opt_len=a.static_len=0;a.last_lit=a.matches=0}function y(a){8<a.bi_valid?g(a,a.bi_buf):0<a.bi_valid&&(a.pending_buf[a.pending++]=a.bi_buf);a.bi_buf=0;a.bi_valid=0}function F(a,b,c,d){var e=2*b,f=2*c;return a[e]<a[f]||a[e]===a[f]&&d[b]<=d[c]}function D(a,b,c){for(var d=a.heap[c],e=c<<1;e<=a.heap_len&&(e<a.heap_len&&F(b,a.heap[e+1],a.heap[e],a.depth)&&e++,!F(b,d,a.heap[e],a.depth));)a.heap[c]=a.heap[e],c=e,e<<=1;a.heap[c]=d}function H(a,b,c){var d,e,f,k,g=
-0;if(0!==a.last_lit){do d=a.pending_buf[a.d_buf+2*g]<<8|a.pending_buf[a.d_buf+2*g+1],e=a.pending_buf[a.l_buf+g],g++,0===d?l(a,e,b):(f=Y[e],l(a,f+x+1,b),k=B[f],0!==k&&(e-=M[f],h(a,e,k)),d--,f=256>d?Z[d]:Z[256+(d>>>7)],l(a,f,c),k=ba[f],0!==k&&(d-=U[f],h(a,d,k)));while(g<a.last_lit)}l(a,V,b)}function v(a,b){var c,d,e,f=b.dyn_tree;d=b.stat_desc.static_tree;var k=b.stat_desc.has_stree,g=b.stat_desc.elems,m=-1;a.heap_len=0;a.heap_max=X;for(c=0;c<g;c++)0!==f[2*c]?(a.heap[++a.heap_len]=m=c,a.depth[c]=0):
-f[2*c+1]=0;for(;2>a.heap_len;)e=a.heap[++a.heap_len]=2>m?++m:0,f[2*e]=1,a.depth[e]=0,a.opt_len--,k&&(a.static_len-=d[2*e+1]);b.max_code=m;for(c=a.heap_len>>1;1<=c;c--)D(a,f,c);e=g;do c=a.heap[1],a.heap[1]=a.heap[a.heap_len--],D(a,f,1),d=a.heap[1],a.heap[--a.heap_max]=c,a.heap[--a.heap_max]=d,f[2*e]=f[2*c]+f[2*d],a.depth[e]=(a.depth[c]>=a.depth[d]?a.depth[c]:a.depth[d])+1,f[2*c+1]=f[2*d+1]=e,a.heap[1]=e++,D(a,f,1);while(2<=a.heap_len);a.heap[--a.heap_max]=a.heap[1];var h,t,k=b.dyn_tree,g=b.max_code,
-p=b.stat_desc.static_tree,l=b.stat_desc.has_stree,E=b.stat_desc.extra_bits,n=b.stat_desc.extra_base,N=b.stat_desc.max_length,C=0;for(d=0;d<=T;d++)a.bl_count[d]=0;k[2*a.heap[a.heap_max]+1]=0;for(c=a.heap_max+1;c<X;c++)e=a.heap[c],d=k[2*k[2*e+1]+1]+1,d>N&&(d=N,C++),k[2*e+1]=d,e>g||(a.bl_count[d]++,h=0,e>=n&&(h=E[e-n]),t=k[2*e],a.opt_len+=t*(d+h),l&&(a.static_len+=t*(p[2*e+1]+h)));if(0!==C){do{for(d=N-1;0===a.bl_count[d];)d--;a.bl_count[d]--;a.bl_count[d+1]+=2;a.bl_count[N]--;C-=2}while(0<C);for(d=N;0!==
-d;d--)for(e=a.bl_count[d];0!==e;)h=a.heap[--c],h>g||(k[2*h+1]!==d&&(a.opt_len+=(d-k[2*h+1])*k[2*h],k[2*h+1]=d),e--)}q(f,m,a.bl_count)}function z(a,b,c){var d,e,f=-1,k=b[1],g=0,m=7,h=4;0===k&&(m=138,h=3);b[2*(c+1)+1]=65535;for(d=0;d<=c;d++)e=k,k=b[2*(d+1)+1],++g<m&&e===k||(g<h?a.bl_tree[2*e]+=g:0!==e?(e!==f&&a.bl_tree[2*e]++,a.bl_tree[2*r]++):10>=g?a.bl_tree[2*da]++:a.bl_tree[2*ca]++,g=0,f=e,0===k?(m=138,h=3):e===k?(m=6,h=3):(m=7,h=4))}function t(a,b,c){var d,e,f=-1,k=b[1],g=0,m=7,t=4;0===k&&(m=138,
-t=3);for(d=0;d<=c;d++)if(e=k,k=b[2*(d+1)+1],!(++g<m&&e===k)){if(g<t){do l(a,e,a.bl_tree);while(0!==--g)}else 0!==e?(e!==f&&(l(a,e,a.bl_tree),g--),l(a,r,a.bl_tree),h(a,g-3,2)):10>=g?(l(a,da,a.bl_tree),h(a,g-3,3)):(l(a,ca,a.bl_tree),h(a,g-11,7));g=0;f=e;0===k?(m=138,t=3):e===k?(m=6,t=3):(m=7,t=4)}}function E(a){var b,c=4093624447;for(b=0;31>=b;b++,c>>>=1)if(1&c&&0!==a.dyn_ltree[2*b])return C;if(0!==a.dyn_ltree[18]||0!==a.dyn_ltree[20]||0!==a.dyn_ltree[26])return p;for(b=32;b<x;b++)if(0!==a.dyn_ltree[2*
-b])return p;return C}function m(a,b,c,d){h(a,(I<<1)+(d?1:0),3);y(a);g(a,c);g(a,~c);P.arraySet(a.pending_buf,a.window,b,c,a.pending);a.pending+=c}var P=b("../utils/common"),C=0,p=1,I=0,x=256,S=x+1+29,O=30,G=19,X=2*S+1,T=15,aa=16,V=256,r=16,da=17,ca=18,B=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],ba=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],K=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],A=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],J=Array(2*(S+2));a(J);
-var Q=Array(2*O);a(Q);var Z=Array(512);a(Z);var Y=Array(256);a(Y);var M=Array(29);a(M);var U=Array(O);a(U);var W,R,L,ea=!1;c._tr_init=function(a){if(!ea){var b,c,f,g=Array(T+1);for(f=c=0;28>f;f++)for(M[f]=c,b=0;b<1<<B[f];b++)Y[c++]=f;Y[c-1]=f;for(f=c=0;16>f;f++)for(U[f]=c,b=0;b<1<<ba[f];b++)Z[c++]=f;for(c>>=7;f<O;f++)for(U[f]=c<<7,b=0;b<1<<ba[f]-7;b++)Z[256+c++]=f;for(b=0;b<=T;b++)g[b]=0;for(b=0;143>=b;)J[2*b+1]=8,b++,g[8]++;for(;255>=b;)J[2*b+1]=9,b++,g[9]++;for(;279>=b;)J[2*b+1]=7,b++,g[7]++;for(;287>=
-b;)J[2*b+1]=8,b++,g[8]++;q(J,S+1,g);for(b=0;b<O;b++)Q[2*b+1]=5,Q[2*b]=n(b,5);W=new e(J,B,x+1,S,T);R=new e(Q,ba,0,O,T);L=new e([],K,0,G,7);ea=!0}a.l_desc=new d(a.dyn_ltree,W);a.d_desc=new d(a.dyn_dtree,R);a.bl_desc=new d(a.bl_tree,L);a.bi_buf=0;a.bi_valid=0;u(a)};c._tr_stored_block=m;c._tr_flush_block=function(a,b,c,d){var e,f,g=0;if(0<a.level){2===a.strm.data_type&&(a.strm.data_type=E(a));v(a,a.l_desc);v(a,a.d_desc);z(a,a.dyn_ltree,a.l_desc.max_code);z(a,a.dyn_dtree,a.d_desc.max_code);v(a,a.bl_desc);
-for(g=G-1;3<=g&&0===a.bl_tree[2*A[g]+1];g--);g=(a.opt_len+=3*(g+1)+14,g);e=a.opt_len+3+7>>>3;f=a.static_len+3+7>>>3;f<=e&&(e=f)}else e=f=c+5;if(c+4<=e&&-1!==b)m(a,b,c,d);else if(4===a.strategy||f===e)h(a,2+(d?1:0),3),H(a,J,Q);else{h(a,4+(d?1:0),3);b=a.l_desc.max_code+1;c=a.d_desc.max_code+1;g+=1;h(a,b-257,5);h(a,c-1,5);h(a,g-4,4);for(e=0;e<g;e++)h(a,a.bl_tree[2*A[e]+1],3);t(a,a.dyn_ltree,b-1);t(a,a.dyn_dtree,c-1);H(a,a.dyn_ltree,a.dyn_dtree)}u(a);d&&y(a)};c._tr_tally=function(a,b,c){return a.pending_buf[a.d_buf+
-2*a.last_lit]=b>>>8&255,a.pending_buf[a.d_buf+2*a.last_lit+1]=255&b,a.pending_buf[a.l_buf+a.last_lit]=255&c,a.last_lit++,0===b?a.dyn_ltree[2*c]++:(a.matches++,b--,a.dyn_ltree[2*(Y[c]+x+1)]++,a.dyn_dtree[2*(256>b?Z[b]:Z[256+(b>>>7)])]++),a.last_lit===a.lit_bufsize-1};c._tr_align=function(a){h(a,2,3);l(a,V,J);16===a.bi_valid?(g(a,a.bi_buf),a.bi_buf=0,a.bi_valid=0):8<=a.bi_valid&&(a.pending_buf[a.pending++]=255&a.bi_buf,a.bi_buf>>=8,a.bi_valid-=8)}},{"../utils/common":62}],74:[function(b,f,c){f.exports=
-function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}]},{},[10])(10)});function VsdxExport(w,b){function f(a,c,d){mxUtils.get(b+"/allConstants.json",function(b){b=JSON.parse(b.request.responseText);for(var e in b)if(1<c&&e==v.CONTENT_TYPES_XML){for(var f=mxUtils.parseXml(b[e]),g=f.documentElement,m=g.children,h=null,t=0;t<m.length;t++){var l=m[t];"/visio/pages/page1.xml"==l.getAttribute(v.PART_NAME)&&(h=l)}for(t=2;t<=c;t++)m=h.cloneNode(),m.setAttribute(v.PART_NAME,"/visio/pages/page"+t+".xml"),g.appendChild(m);F(a,e,f,!0)}else a.file(e,b[e]);d&&d()})}function c(a){var b=
-{};try{var c=a.getGraphBounds().clone(),d=a.view.scale,e=a.view.translate,f=Math.round(c.x/d)-e.x,g=Math.round(c.y/d)-e.y,h=a.pageFormat.width,t=a.pageFormat.height;0>f&&(f+=Math.ceil((e.x-c.x/d)/h)*h);0>g&&(g+=Math.ceil((e.y-c.y/d)/t)*t);var l=Math.max(1,Math.ceil((c.width/d+f)/h)),n=Math.max(1,Math.ceil((c.height/d+g)/t));b.gridEnabled=a.gridEnabled;b.gridSize=a.gridSize;b.guidesEnabled=a.graphHandler.guidesEnabled;b.pageVisible=a.pageVisible;b.pageScale=a.pageScale;b.pageWidth=a.pageFormat.width*
-l;b.pageHeight=a.pageFormat.height*n;b.backgroundClr=a.background;b.mathEnabled=a.mathEnabled;b.shadowVisible=a.shadowVisible}catch(X){}return b}function a(a,b,c){return e(a,b/v.CONVERSION_FACTOR,c)}function e(a,b,c){c=c.createElement("Cell");c.setAttribute("N",a);c.setAttribute("V",b);return c}function d(b,c,d,e,f){var g=f.createElement("Row");g.setAttribute("T",b);g.setAttribute("IX",c);g.appendChild(a("X",d,f));g.appendChild(a("Y",e,f));return g}function g(b,c,d){var f=b.style[mxConstants.STYLE_FILLCOLOR];
+this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(a){this.extraFields[1]&&(a=e(this.extraFields[1].value),this.uncompressedSize===c.MAX_VALUE_32BITS&&(this.uncompressedSize=a.readInt(8)),this.compressedSize===c.MAX_VALUE_32BITS&&(this.compressedSize=a.readInt(8)),this.localHeaderOffset===c.MAX_VALUE_32BITS&&(this.localHeaderOffset=a.readInt(8)),this.diskNumberStart===c.MAX_VALUE_32BITS&&(this.diskNumberStart=a.readInt(4)))},readExtraFields:function(a){var b,
+c,e,d=a.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});a.index<d;)b=a.readInt(2),c=a.readInt(2),e=a.readData(c),this.extraFields[b]={id:b,length:c,value:e}},handleUTF8:function(){var a=q.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=h.utf8decode(this.fileName),this.fileCommentStr=h.utf8decode(this.fileComment);else{var b=this.findExtraFieldUnicodePath();null!==b?this.fileNameStr=b:(b=c.transformTo(a,this.fileName),this.fileNameStr=this.loadOptions.decodeFileName(b));
+b=this.findExtraFieldUnicodeComment();null!==b?this.fileCommentStr=b:(a=c.transformTo(a,this.fileComment),this.fileCommentStr=this.loadOptions.decodeFileName(a))}},findExtraFieldUnicodePath:function(){var a=this.extraFields[28789];if(a){var b=e(a.value);return 1!==b.readInt(1)?null:l(this.fileName)!==b.readInt(4)?null:h.utf8decode(b.readData(a.length-5))}return null},findExtraFieldUnicodeComment:function(){var a=this.extraFields[25461];if(a){var b=e(a.value);return 1!==b.readInt(1)?null:l(this.fileComment)!==
+b.readInt(4)?null:h.utf8decode(b.readData(a.length-5))}return null}};f.exports=a},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(b,f,d){var a=b("./stream/StreamHelper"),e=b("./stream/DataWorker"),c=b("./utf8"),g=b("./compressedObject"),l=b("./stream/GenericWorker");b=function(a,b,c){this.name=a;this.dir=c.dir;this.date=c.date;this.comment=c.comment;this.unixPermissions=c.unixPermissions;this.dosPermissions=c.dosPermissions;
+this._data=b;this._dataBinary=c.binary;this.options={compression:c.compression,compressionOptions:c.compressionOptions}};b.prototype={internalStream:function(b){b=b.toLowerCase();var e="string"===b||"text"===b;"binarystring"!==b&&"text"!==b||(b="string");var d=this._decompressWorker(),g=!this._dataBinary;return g&&!e&&(d=d.pipe(new c.Utf8EncodeWorker)),!g&&e&&(d=d.pipe(new c.Utf8DecodeWorker)),new a(d,b,"")},async:function(a,b){return this.internalStream(a).accumulate(b)},nodeStream:function(a,b){return this.internalStream(a||
+"nodebuffer").toNodejsStream(b)},_compressWorker:function(a,b){if(this._data instanceof g&&this._data.compression.magic===a.magic)return this._data.getCompressedWorker();var e=this._decompressWorker();return this._dataBinary||(e=e.pipe(new c.Utf8EncodeWorker)),g.createWorkerFrom(e,a,b)},_decompressWorker:function(){return this._data instanceof g?this._data.getContentWorker():this._data instanceof l?this._data:new e(this._data)}};d=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"];
+for(var h=function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.");},n=0;n<d.length;n++)b.prototype[d[n]]=h;f.exports=b},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(b,f,d){b("../modules/web.immediate");f.exports=b("../modules/_core").setImmediate},{"../modules/_core":40,"../modules/web.immediate":56}],37:[function(b,f,d){f.exports=function(a){if("function"!=typeof a)throw TypeError(a+
+" is not a function!");return a}},{}],38:[function(b,f,d){var a=b("./_is-object");f.exports=function(b){if(!a(b))throw TypeError(b+" is not an object!");return b}},{"./_is-object":51}],39:[function(b,f,d){var a={}.toString;f.exports=function(b){return a.call(b).slice(8,-1)}},{}],40:[function(b,f,d){b=f.exports={version:"2.3.0"};"number"==typeof __e&&(__e=b)},{}],41:[function(b,f,d){var a=b("./_a-function");f.exports=function(b,c,d){if(a(b),void 0===c)return b;switch(d){case 1:return function(a){return b.call(c,
+a)};case 2:return function(a,e){return b.call(c,a,e)};case 3:return function(a,e,d){return b.call(c,a,e,d)}}return function(){return b.apply(c,arguments)}}},{"./_a-function":37}],42:[function(b,f,d){f.exports=!b("./_fails")(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},{"./_fails":45}],43:[function(b,f,d){d=b("./_is-object");var a=b("./_global").document,e=d(a)&&d(a.createElement);f.exports=function(b){return e?a.createElement(b):{}}},{"./_global":46,"./_is-object":51}],
+44:[function(b,f,d){var a=b("./_global"),e=b("./_core"),c=b("./_ctx"),g=b("./_hide"),l=function(b,d,f){var h,n,q=b&l.F,G=b&l.G,z=b&l.S,x=b&l.P,y=b&l.B,p=b&l.W,D=G?e:e[d]||(e[d]={}),m=D.prototype,z=G?a:z?a[d]:(a[d]||{}).prototype;G&&(f=d);for(h in f)(d=!q&&z&&void 0!==z[h])&&h in D||(n=d?z[h]:f[h],D[h]=G&&"function"!=typeof z[h]?f[h]:y&&d?c(n,a):p&&z[h]==n?function(a){var b=function(b,c,v){if(this instanceof a){switch(arguments.length){case 0:return new a;case 1:return new a(b);case 2:return new a(b,
+c)}return new a(b,c,v)}return a.apply(this,arguments)};return b.prototype=a.prototype,b}(n):x&&"function"==typeof n?c(Function.call,n):n,x&&((D.virtual||(D.virtual={}))[h]=n,b&l.R&&m&&!m[h]&&g(m,h,n)))};l.F=1;l.G=2;l.S=4;l.P=8;l.B=16;l.W=32;l.U=64;l.R=128;f.exports=l},{"./_core":40,"./_ctx":41,"./_global":46,"./_hide":47}],45:[function(b,f,d){f.exports=function(a){try{return!!a()}catch(e){return!0}}},{}],46:[function(b,f,d){b=f.exports="undefined"!=typeof window&&Math==Math?window:"undefined"!=typeof self&&
+self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=b)},{}],47:[function(b,f,d){var a=b("./_object-dp"),e=b("./_property-desc");f.exports=b("./_descriptors")?function(b,d,l){return a.f(b,d,e(1,l))}:function(a,b,e){return a[b]=e,a}},{"./_descriptors":42,"./_object-dp":52,"./_property-desc":53}],48:[function(b,f,d){f.exports=b("./_global").document&&document.documentElement},{"./_global":46}],49:[function(b,f,d){f.exports=!b("./_descriptors")&&!b("./_fails")(function(){return 7!=
+Object.defineProperty(b("./_dom-create")("div"),"a",{get:function(){return 7}}).a})},{"./_descriptors":42,"./_dom-create":43,"./_fails":45}],50:[function(b,f,d){f.exports=function(a,b,c){var d=void 0===c;switch(b.length){case 0:return d?a():a.call(c);case 1:return d?a(b[0]):a.call(c,b[0]);case 2:return d?a(b[0],b[1]):a.call(c,b[0],b[1]);case 3:return d?a(b[0],b[1],b[2]):a.call(c,b[0],b[1],b[2]);case 4:return d?a(b[0],b[1],b[2],b[3]):a.call(c,b[0],b[1],b[2],b[3])}return a.apply(c,b)}},{}],51:[function(b,
+f,d){f.exports=function(a){return"object"==typeof a?null!==a:"function"==typeof a}},{}],52:[function(b,f,d){var a=b("./_an-object"),e=b("./_ie8-dom-define"),c=b("./_to-primitive"),g=Object.defineProperty;d.f=b("./_descriptors")?Object.defineProperty:function(b,d,f){if(a(b),d=c(d,!0),a(f),e)try{return g(b,d,f)}catch(q){}if("get"in f||"set"in f)throw TypeError("Accessors not supported!");return"value"in f&&(b[d]=f.value),b}},{"./_an-object":38,"./_descriptors":42,"./_ie8-dom-define":49,"./_to-primitive":55}],
+53:[function(b,f,d){f.exports=function(a,b){return{enumerable:!(1&a),configurable:!(2&a),writable:!(4&a),value:b}}},{}],54:[function(b,f,d){var a,e,c,g=b("./_ctx"),l=b("./_invoke"),h=b("./_html"),n=b("./_dom-create"),q=b("./_global"),t=q.process;d=q.setImmediate;var A=q.clearImmediate,B=q.MessageChannel,G=0,z={},x=function(){var a=+this;if(z.hasOwnProperty(a)){var b=z[a];delete z[a];b()}},y=function(a){x.call(a.data)};d&&A||(d=function(b){for(var c=[],d=1;arguments.length>d;)c.push(arguments[d++]);
+return z[++G]=function(){l("function"==typeof b?b:Function(b),c)},a(G),G},A=function(a){delete z[a]},"process"==b("./_cof")(t)?a=function(a){t.nextTick(g(x,a,1))}:B?(e=new B,c=e.port2,e.port1.onmessage=y,a=g(c.postMessage,c,1)):q.addEventListener&&"function"==typeof postMessage&&!q.importScripts?(a=function(a){q.postMessage(a+"","*")},q.addEventListener("message",y,!1)):a="onreadystatechange"in n("script")?function(a){h.appendChild(n("script")).onreadystatechange=function(){h.removeChild(this);x.call(a)}}:
+function(a){setTimeout(g(x,a,1),0)});f.exports={set:d,clear:A}},{"./_cof":39,"./_ctx":41,"./_dom-create":43,"./_global":46,"./_html":48,"./_invoke":50}],55:[function(b,f,d){var a=b("./_is-object");f.exports=function(b,c){if(!a(b))return b;var d,e;if(c&&"function"==typeof(d=b.toString)&&!a(e=d.call(b))||"function"==typeof(d=b.valueOf)&&!a(e=d.call(b))||!c&&"function"==typeof(d=b.toString)&&!a(e=d.call(b)))return e;throw TypeError("Can't convert object to primitive value");}},{"./_is-object":51}],56:[function(b,
+f,d){f=b("./_export");b=b("./_task");f(f.G+f.B,{setImmediate:b.set,clearImmediate:b.clear})},{"./_export":44,"./_task":54}],57:[function(b,f,d){(function(a){function b(){q=!0;for(var a,b,c=t.length;c;){b=t;t=[];for(a=-1;++a<c;)b[a]();c=t.length}q=!1}var c,d=a.MutationObserver||a.WebKitMutationObserver;if(d){var l=0,d=new d(b),h=a.document.createTextNode("");d.observe(h,{characterData:!0});c=function(){h.data=l=++l%2}}else if(a.setImmediate||"undefined"==typeof a.MessageChannel)c="document"in a&&"onreadystatechange"in
+a.document.createElement("script")?function(){var c=a.document.createElement("script");c.onreadystatechange=function(){b();c.onreadystatechange=null;c.parentNode.removeChild(c);c=null};a.document.documentElement.appendChild(c)}:function(){setTimeout(b,0)};else{var n=new a.MessageChannel;n.port1.onmessage=b;c=function(){n.port2.postMessage(0)}}var q,t=[];f.exports=function(a){1!==t.push(a)||q||c()}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?
+window:{})},{}],58:[function(b,f,d){function a(){}function e(b){if("function"!=typeof b)throw new TypeError("resolver must be a function");this.state=G;this.queue=[];this.outcome=void 0;b!==a&&h(this,b)}function c(a,b,c){this.promise=a;"function"==typeof b&&(this.onFulfilled=b,this.callFulfilled=this.otherCallFulfilled);"function"==typeof c&&(this.onRejected=c,this.callRejected=this.otherCallRejected)}function g(a,b,c){q(function(){var d;try{d=b(c)}catch(D){return t.reject(a,D)}d===a?t.reject(a,new TypeError("Cannot resolve promise with itself")):
+t.resolve(a,d)})}function l(a){var b=a&&a.then;if(a&&"object"==typeof a&&"function"==typeof b)return function(){b.apply(a,arguments)}}function h(a,b){function c(b){e||(e=!0,t.reject(a,b))}function d(b){e||(e=!0,t.resolve(a,b))}var e=!1,g=n(function(){b(d,c)});"error"===g.status&&c(g.value)}function n(a,b){var c={};try{c.value=a(b),c.status="success"}catch(p){c.status="error",c.value=p}return c}var q=b("immediate"),t={},A=["REJECTED"],B=["FULFILLED"],G=["PENDING"];f.exports=e;e.prototype["catch"]=
+function(a){return this.then(null,a)};e.prototype.then=function(b,d){if("function"!=typeof b&&this.state===B||"function"!=typeof d&&this.state===A)return this;var e=new this.constructor(a);this.state!==G?g(e,this.state===B?b:d,this.outcome):this.queue.push(new c(e,b,d));return e};c.prototype.callFulfilled=function(a){t.resolve(this.promise,a)};c.prototype.otherCallFulfilled=function(a){g(this.promise,this.onFulfilled,a)};c.prototype.callRejected=function(a){t.reject(this.promise,a)};c.prototype.otherCallRejected=
+function(a){g(this.promise,this.onRejected,a)};t.resolve=function(a,b){var c=n(l,b);if("error"===c.status)return t.reject(a,c.value);if(c=c.value)h(a,c);else{a.state=B;a.outcome=b;for(var c=-1,d=a.queue.length;++c<d;)a.queue[c].callFulfilled(b)}return a};t.reject=function(a,b){a.state=A;a.outcome=b;for(var c=-1,d=a.queue.length;++c<d;)a.queue[c].callRejected(b);return a};e.resolve=function(b){return b instanceof this?b:t.resolve(new this(a),b)};e.reject=function(b){var c=new this(a);return t.reject(c,
+b)};e.all=function(b){function c(a,b){d.resolve(a).then(function(a){f[b]=a;++l!==e||g||(g=!0,t.resolve(u,f))},function(a){g||(g=!0,t.reject(u,a))})}var d=this;if("[object Array]"!==Object.prototype.toString.call(b))return this.reject(new TypeError("must be an array"));var e=b.length,g=!1;if(!e)return this.resolve([]);for(var f=Array(e),l=0,h=-1,u=new this(a);++h<e;)c(b[h],h);return u};e.race=function(b){function c(a){d.resolve(a).then(function(a){g||(g=!0,t.resolve(l,a))},function(a){g||(g=!0,t.reject(l,
+a))})}var d=this;if("[object Array]"!==Object.prototype.toString.call(b))return this.reject(new TypeError("must be an array"));var e=b.length,g=!1;if(!e)return this.resolve([]);for(var f=-1,l=new this(a);++f<e;)c(b[f]);return l}},{immediate:57}],59:[function(b,f,d){d=b("./lib/utils/common").assign;var a=b("./lib/deflate"),e=b("./lib/inflate");b=b("./lib/zlib/constants");var c={};d(c,a,e,b);f.exports=c},{"./lib/deflate":60,"./lib/inflate":61,"./lib/utils/common":62,"./lib/zlib/constants":65}],60:[function(b,
+f,d){function a(b){if(!(this instanceof a))return new a(b);b=this.options=g.assign({level:A,method:G,chunkSize:16384,windowBits:15,memLevel:8,strategy:B,to:""},b||{});b.raw&&0<b.windowBits?b.windowBits=-b.windowBits:b.gzip&&0<b.windowBits&&16>b.windowBits&&(b.windowBits+=16);this.err=0;this.msg="";this.ended=!1;this.chunks=[];this.strm=new n;this.strm.avail_out=0;var d=c.deflateInit2(this.strm,b.level,b.method,b.windowBits,b.memLevel,b.strategy);if(d!==t)throw Error(h[d]);if(b.header&&c.deflateSetHeader(this.strm,
+b.header),b.dictionary){var e;if(e="string"==typeof b.dictionary?l.string2buf(b.dictionary):"[object ArrayBuffer]"===q.call(b.dictionary)?new Uint8Array(b.dictionary):b.dictionary,d=c.deflateSetDictionary(this.strm,e),d!==t)throw Error(h[d]);this._dict_set=!0}}function e(b,c){var d=new a(c);if(d.push(b,!0),d.err)throw d.msg;return d.result}var c=b("./zlib/deflate"),g=b("./utils/common"),l=b("./utils/strings"),h=b("./zlib/messages"),n=b("./zlib/zstream"),q=Object.prototype.toString,t=0,A=-1,B=0,G=
+8;a.prototype.push=function(a,b){var d,e,f=this.strm,h=this.options.chunkSize;if(this.ended)return!1;e=b===~~b?b:!0===b?4:0;"string"==typeof a?f.input=l.string2buf(a):"[object ArrayBuffer]"===q.call(a)?f.input=new Uint8Array(a):f.input=a;f.next_in=0;f.avail_in=f.input.length;do{if(0===f.avail_out&&(f.output=new g.Buf8(h),f.next_out=0,f.avail_out=h),d=c.deflate(f,e),1!==d&&d!==t)return this.onEnd(d),this.ended=!0,!1;0!==f.avail_out&&(0!==f.avail_in||4!==e&&2!==e)||("string"===this.options.to?this.onData(l.buf2binstring(g.shrinkBuf(f.output,
+f.next_out))):this.onData(g.shrinkBuf(f.output,f.next_out)))}while((0<f.avail_in||0===f.avail_out)&&1!==d);return 4===e?(d=c.deflateEnd(this.strm),this.onEnd(d),this.ended=!0,d===t):2!==e||(this.onEnd(t),f.avail_out=0,!0)};a.prototype.onData=function(a){this.chunks.push(a)};a.prototype.onEnd=function(a){a===t&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=g.flattenChunks(this.chunks));this.chunks=[];this.err=a;this.msg=this.strm.msg};d.Deflate=a;d.deflate=e;d.deflateRaw=
+function(a,b){return b=b||{},b.raw=!0,e(a,b)};d.gzip=function(a,b){return b=b||{},b.gzip=!0,e(a,b)}},{"./utils/common":62,"./utils/strings":63,"./zlib/deflate":67,"./zlib/messages":72,"./zlib/zstream":74}],61:[function(b,f,d){function a(b){if(!(this instanceof a))return new a(b);var d=this.options=g.assign({chunkSize:16384,windowBits:0,to:""},b||{});d.raw&&0<=d.windowBits&&16>d.windowBits&&(d.windowBits=-d.windowBits,0===d.windowBits&&(d.windowBits=-15));!(0<=d.windowBits&&16>d.windowBits)||b&&b.windowBits||
+(d.windowBits+=32);15<d.windowBits&&48>d.windowBits&&0===(15&d.windowBits)&&(d.windowBits|=15);this.err=0;this.msg="";this.ended=!1;this.chunks=[];this.strm=new q;this.strm.avail_out=0;b=c.inflateInit2(this.strm,d.windowBits);if(b!==h.Z_OK)throw Error(n[b]);this.header=new t;c.inflateGetHeader(this.strm,this.header)}function e(b,c){var d=new a(c);if(d.push(b,!0),d.err)throw d.msg;return d.result}var c=b("./zlib/inflate"),g=b("./utils/common"),l=b("./utils/strings"),h=b("./zlib/constants"),n=b("./zlib/messages"),
+q=b("./zlib/zstream"),t=b("./zlib/gzheader"),A=Object.prototype.toString;a.prototype.push=function(a,b){var d,e,f,p,n,m,q=this.strm,H=this.options.chunkSize,u=this.options.dictionary,I=!1;if(this.ended)return!1;e=b===~~b?b:!0===b?h.Z_FINISH:h.Z_NO_FLUSH;"string"==typeof a?q.input=l.binstring2buf(a):"[object ArrayBuffer]"===A.call(a)?q.input=new Uint8Array(a):q.input=a;q.next_in=0;q.avail_in=q.input.length;do{if(0===q.avail_out&&(q.output=new g.Buf8(H),q.next_out=0,q.avail_out=H),d=c.inflate(q,h.Z_NO_FLUSH),
+d===h.Z_NEED_DICT&&u&&(m="string"==typeof u?l.string2buf(u):"[object ArrayBuffer]"===A.call(u)?new Uint8Array(u):u,d=c.inflateSetDictionary(this.strm,m)),d===h.Z_BUF_ERROR&&!0===I&&(d=h.Z_OK,I=!1),d!==h.Z_STREAM_END&&d!==h.Z_OK)return this.onEnd(d),this.ended=!0,!1;q.next_out&&(0!==q.avail_out&&d!==h.Z_STREAM_END&&(0!==q.avail_in||e!==h.Z_FINISH&&e!==h.Z_SYNC_FLUSH)||("string"===this.options.to?(f=l.utf8border(q.output,q.next_out),p=q.next_out-f,n=l.buf2string(q.output,f),q.next_out=p,q.avail_out=
+H-p,p&&g.arraySet(q.output,q.output,f,p,0),this.onData(n)):this.onData(g.shrinkBuf(q.output,q.next_out))));0===q.avail_in&&0===q.avail_out&&(I=!0)}while((0<q.avail_in||0===q.avail_out)&&d!==h.Z_STREAM_END);return d===h.Z_STREAM_END&&(e=h.Z_FINISH),e===h.Z_FINISH?(d=c.inflateEnd(this.strm),this.onEnd(d),this.ended=!0,d===h.Z_OK):e!==h.Z_SYNC_FLUSH||(this.onEnd(h.Z_OK),q.avail_out=0,!0)};a.prototype.onData=function(a){this.chunks.push(a)};a.prototype.onEnd=function(a){a===h.Z_OK&&("string"===this.options.to?
+this.result=this.chunks.join(""):this.result=g.flattenChunks(this.chunks));this.chunks=[];this.err=a;this.msg=this.strm.msg};d.Inflate=a;d.inflate=e;d.inflateRaw=function(a,b){return b=b||{},b.raw=!0,e(a,b)};d.ungzip=e},{"./utils/common":62,"./utils/strings":63,"./zlib/constants":65,"./zlib/gzheader":68,"./zlib/inflate":70,"./zlib/messages":72,"./zlib/zstream":74}],62:[function(b,f,d){b="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;d.assign=function(a){for(var b=
+Array.prototype.slice.call(arguments,1);b.length;){var d=b.shift();if(d){if("object"!=typeof d)throw new TypeError(d+"must be non-object");for(var c in d)d.hasOwnProperty(c)&&(a[c]=d[c])}}return a};d.shrinkBuf=function(a,b){return a.length===b?a:a.subarray?a.subarray(0,b):(a.length=b,a)};var a={arraySet:function(a,b,d,e,f){if(b.subarray&&a.subarray)return void a.set(b.subarray(d,d+e),f);for(var c=0;c<e;c++)a[f+c]=b[d+c]},flattenChunks:function(a){var b,d,c,e,f;b=c=0;for(d=a.length;b<d;b++)c+=a[b].length;
+f=new Uint8Array(c);b=c=0;for(d=a.length;b<d;b++)e=a[b],f.set(e,c),c+=e.length;return f}},e={arraySet:function(a,b,d,e,f){for(var c=0;c<e;c++)a[f+c]=b[d+c]},flattenChunks:function(a){return[].concat.apply([],a)}};d.setTyped=function(b){b?(d.Buf8=Uint8Array,d.Buf16=Uint16Array,d.Buf32=Int32Array,d.assign(d,a)):(d.Buf8=Array,d.Buf16=Array,d.Buf32=Array,d.assign(d,e))};d.setTyped(b)},{}],63:[function(b,f,d){function a(a,b){if(65537>b&&(a.subarray&&g||!a.subarray&&c))return String.fromCharCode.apply(null,
+e.shrinkBuf(a,b));for(var d="",f=0;f<b;f++)d+=String.fromCharCode(a[f]);return d}var e=b("./common"),c=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch(h){c=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(h){g=!1}var l=new e.Buf8(256);for(b=0;256>b;b++)l[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;l[254]=l[254]=1;d.string2buf=function(a){var b,d,c,f,g,l=a.length,h=0;for(f=0;f<l;f++)d=a.charCodeAt(f),55296===(64512&d)&&f+1<l&&(c=a.charCodeAt(f+1),56320===(64512&c)&&(d=65536+
+(d-55296<<10)+(c-56320),f++)),h+=128>d?1:2048>d?2:65536>d?3:4;b=new e.Buf8(h);for(f=g=0;g<h;f++)d=a.charCodeAt(f),55296===(64512&d)&&f+1<l&&(c=a.charCodeAt(f+1),56320===(64512&c)&&(d=65536+(d-55296<<10)+(c-56320),f++)),128>d?b[g++]=d:2048>d?(b[g++]=192|d>>>6,b[g++]=128|63&d):65536>d?(b[g++]=224|d>>>12,b[g++]=128|d>>>6&63,b[g++]=128|63&d):(b[g++]=240|d>>>18,b[g++]=128|d>>>12&63,b[g++]=128|d>>>6&63,b[g++]=128|63&d);return b};d.buf2binstring=function(b){return a(b,b.length)};d.binstring2buf=function(a){for(var b=
+new e.Buf8(a.length),d=0,c=b.length;d<c;d++)b[d]=a.charCodeAt(d);return b};d.buf2string=function(b,d){var c,e,f,g,h=d||b.length,n=Array(2*h);for(c=e=0;c<h;)if(f=b[c++],128>f)n[e++]=f;else if(g=l[f],4<g)n[e++]=65533,c+=g-1;else{for(f&=2===g?31:3===g?15:7;1<g&&c<h;)f=f<<6|63&b[c++],g--;1<g?n[e++]=65533:65536>f?n[e++]=f:(f-=65536,n[e++]=55296|f>>10&1023,n[e++]=56320|1023&f)}return a(n,e)};d.utf8border=function(a,b){var d;b=b||a.length;b>a.length&&(b=a.length);for(d=b-1;0<=d&&128===(192&a[d]);)d--;return 0>
+d?b:0===d?b:d+l[a[d]]>b?d:b}},{"./common":62}],64:[function(b,f,d){f.exports=function(a,b,d,f){var c=65535&a|0;a=a>>>16&65535|0;for(var e;0!==d;){e=2E3<d?2E3:d;d-=e;do c=c+b[f++]|0,a=a+c|0;while(--e);c%=65521;a%=65521}return c|a<<16|0}},{}],65:[function(b,f,d){f.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,
+Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],66:[function(b,f,d){var a=function(){for(var a,b=[],d=0;256>d;d++){a=d;for(var f=0;8>f;f++)a=1&a?3988292384^a>>>1:a>>>1;b[d]=a}return b}();f.exports=function(b,d,f,l){f=l+f;for(b^=-1;l<f;l++)b=b>>>8^a[255&(b^d[l])];return b^-1}},{}],67:[function(b,f,d){function a(a,b){return a.msg=u[b],b}function e(a){for(var b=a.length;0<=--b;)a[b]=0}function c(a){var b=
+a.state,d=b.pending;d>a.avail_out&&(d=a.avail_out);0!==d&&(D.arraySet(a.output,b.pending_buf,b.pending_out,d,a.next_out),a.next_out+=d,b.pending_out+=d,a.total_out+=d,a.avail_out-=d,b.pending-=d,0===b.pending&&(b.pending_out=0))}function g(a,b){m._tr_flush_block(a,0<=a.block_start?a.block_start:-1,a.strstart-a.block_start,b);a.block_start=a.strstart;c(a.strm)}function l(a,b){a.pending_buf[a.pending++]=b}function h(a,b){a.pending_buf[a.pending++]=b>>>8&255;a.pending_buf[a.pending++]=255&b}function n(a,
+b){var d,c,e=a.max_chain_length,v=a.strstart,P=a.prev_length,f=a.nice_match,u=a.strstart>a.w_size-Q?a.strstart-(a.w_size-Q):0,g=a.window,p=a.w_mask,l=a.prev,h=a.strstart+K,I=g[v+P-1],D=g[v+P];a.prev_length>=a.good_match&&(e>>=2);f>a.lookahead&&(f=a.lookahead);do if(d=b,g[d+P]===D&&g[d+P-1]===I&&g[d]===g[v]&&g[++d]===g[v+1]){v+=2;for(d++;g[++v]===g[++d]&&g[++v]===g[++d]&&g[++v]===g[++d]&&g[++v]===g[++d]&&g[++v]===g[++d]&&g[++v]===g[++d]&&g[++v]===g[++d]&&g[++v]===g[++d]&&v<h;);if(c=K-(h-v),v=h-K,c>
+P){if(a.match_start=b,P=c,c>=f)break;I=g[v+P-1];D=g[v+P]}}while((b=l[b&p])>u&&0!==--e);return P<=a.lookahead?P:a.lookahead}function q(a){var b,d,c,v,e=a.w_size;do{if(v=a.window_size-a.lookahead-a.strstart,a.strstart>=e+(e-Q)){D.arraySet(a.window,a.window,e,e,0);a.match_start-=e;a.strstart-=e;a.block_start-=e;b=d=a.hash_size;do c=a.head[--b],a.head[b]=c>=e?c-e:0;while(--d);b=d=e;do c=a.prev[--b],a.prev[b]=c>=e?c-e:0;while(--d);v+=e}if(0===a.strm.avail_in)break;b=a.strm;c=a.window;var P=a.strstart+
+a.lookahead,f=b.avail_in;if(d=(f>v&&(f=v),0===f?0:(b.avail_in-=f,D.arraySet(c,b.input,b.next_in,f,P),1===b.state.wrap?b.adler=O(b.adler,c,f,P):2===b.state.wrap&&(b.adler=H(b.adler,c,f,P)),b.next_in+=f,b.total_in+=f,f)),a.lookahead+=d,a.lookahead+a.insert>=C)for(v=a.strstart-a.insert,a.ins_h=a.window[v],a.ins_h=(a.ins_h<<a.hash_shift^a.window[v+1])&a.hash_mask;a.insert&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[v+C-1])&a.hash_mask,a.prev[v&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=v,v++,a.insert--,
+!(a.lookahead+a.insert<C)););}while(a.lookahead<Q&&0!==a.strm.avail_in)}function t(a,b){for(var d,c;;){if(a.lookahead<Q){if(q(a),a.lookahead<Q&&b===I)return M;if(0===a.lookahead)break}if(d=0,a.lookahead>=C&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+C-1])&a.hash_mask,d=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),0!==d&&a.strstart-d<=a.w_size-Q&&(a.match_length=n(a,d)),a.match_length>=C)if(c=m._tr_tally(a,a.strstart-a.match_start,a.match_length-C),a.lookahead-=
+a.match_length,a.match_length<=a.max_lazy_match&&a.lookahead>=C){a.match_length--;do a.strstart++,a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+C-1])&a.hash_mask,d=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart;while(0!==--a.match_length);a.strstart++}else a.strstart+=a.match_length,a.match_length=0,a.ins_h=a.window[a.strstart],a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+1])&a.hash_mask;else c=m._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++;if(c&&
+(g(a,!1),0===a.strm.avail_out))return M}return a.insert=a.strstart<C-1?a.strstart:C-1,b===v?(g(a,!0),0===a.strm.avail_out?W:R):a.last_lit&&(g(a,!1),0===a.strm.avail_out)?M:U}function A(a,b){for(var d,c,e;;){if(a.lookahead<Q){if(q(a),a.lookahead<Q&&b===I)return M;if(0===a.lookahead)break}if(d=0,a.lookahead>=C&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+C-1])&a.hash_mask,d=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),a.prev_length=a.match_length,a.prev_match=a.match_start,
+a.match_length=C-1,0!==d&&a.prev_length<a.max_lazy_match&&a.strstart-d<=a.w_size-Q&&(a.match_length=n(a,d),5>=a.match_length&&(a.strategy===X||a.match_length===C&&4096<a.strstart-a.match_start)&&(a.match_length=C-1)),a.prev_length>=C&&a.match_length<=a.prev_length){e=a.strstart+a.lookahead-C;c=m._tr_tally(a,a.strstart-1-a.prev_match,a.prev_length-C);a.lookahead-=a.prev_length-1;a.prev_length-=2;do++a.strstart<=e&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+C-1])&a.hash_mask,d=a.prev[a.strstart&
+a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart);while(0!==--a.prev_length);if(a.match_available=0,a.match_length=C-1,a.strstart++,c&&(g(a,!1),0===a.strm.avail_out))return M}else if(a.match_available){if(c=m._tr_tally(a,0,a.window[a.strstart-1]),c&&g(a,!1),a.strstart++,a.lookahead--,0===a.strm.avail_out)return M}else a.match_available=1,a.strstart++,a.lookahead--}return a.match_available&&(m._tr_tally(a,0,a.window[a.strstart-1]),a.match_available=0),a.insert=a.strstart<C-1?a.strstart:C-1,b===
+v?(g(a,!0),0===a.strm.avail_out?W:R):a.last_lit&&(g(a,!1),0===a.strm.avail_out)?M:U}function B(a,b,d,c,v){this.good_length=a;this.max_lazy=b;this.nice_length=d;this.max_chain=c;this.func=v}function G(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=V;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=
+this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=this.ins_h=0;this.dyn_ltree=new D.Buf16(2*ba);this.dyn_dtree=new D.Buf16(2*(2*ca+1));this.bl_tree=new D.Buf16(2*(2*E+1));e(this.dyn_ltree);e(this.dyn_dtree);e(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new D.Buf16(L+
+1);this.heap=new D.Buf16(2*da+1);e(this.heap);this.heap_max=this.heap_len=0;this.depth=new D.Buf16(2*da+1);e(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function z(b){var d;return b&&b.state?(b.total_in=b.total_out=0,b.data_type=aa,d=b.state,d.pending=0,d.pending_out=0,0>d.wrap&&(d.wrap=-d.wrap),d.status=d.wrap?Z:Y,b.adler=2===d.wrap?0:1,d.last_flush=I,m._tr_init(d),S):a(b,N)}function x(a){var b=
+z(a);b===S&&(a=a.state,a.window_size=2*a.w_size,e(a.head),a.max_lazy_match=p[a.level].max_lazy,a.good_match=p[a.level].good_length,a.nice_match=p[a.level].nice_length,a.max_chain_length=p[a.level].max_chain,a.strstart=0,a.block_start=0,a.lookahead=0,a.insert=0,a.match_length=a.prev_length=C-1,a.match_available=0,a.ins_h=0);return b}function y(b,d,c,v,e,f){if(!b)return N;var k=1;if(d===F&&(d=6),0>v?(k=0,v=-v):15<v&&(k=2,v-=16),1>e||e>r||c!==V||8>v||15<v||0>d||9<d||0>f||f>T)return a(b,N);8===v&&(v=
+9);var J=new G;return b.state=J,J.strm=b,J.wrap=k,J.gzhead=null,J.w_bits=v,J.w_size=1<<J.w_bits,J.w_mask=J.w_size-1,J.hash_bits=e+7,J.hash_size=1<<J.hash_bits,J.hash_mask=J.hash_size-1,J.hash_shift=~~((J.hash_bits+C-1)/C),J.window=new D.Buf8(2*J.w_size),J.head=new D.Buf16(J.hash_size),J.prev=new D.Buf16(J.w_size),J.lit_bufsize=1<<e+6,J.pending_buf_size=4*J.lit_bufsize,J.pending_buf=new D.Buf8(J.pending_buf_size),J.d_buf=1*J.lit_bufsize,J.l_buf=3*J.lit_bufsize,J.level=d,J.strategy=f,J.method=c,x(b)}
+var p,D=b("../utils/common"),m=b("./trees"),O=b("./adler32"),H=b("./crc32"),u=b("./messages"),I=0,v=4,S=0,N=-2,F=-1,X=1,T=4,aa=2,V=8,r=9,da=286,ca=30,E=19,ba=2*da+1,L=15,C=3,K=258,Q=K+C+1,Z=42,Y=113,M=1,U=2,W=3,R=4;p=[new B(0,0,0,0,function(a,b){var d=65535;for(d>a.pending_buf_size-5&&(d=a.pending_buf_size-5);;){if(1>=a.lookahead){if(q(a),0===a.lookahead&&b===I)return M;if(0===a.lookahead)break}a.strstart+=a.lookahead;a.lookahead=0;var c=a.block_start+d;if((0===a.strstart||a.strstart>=c)&&(a.lookahead=
+a.strstart-c,a.strstart=c,g(a,!1),0===a.strm.avail_out)||a.strstart-a.block_start>=a.w_size-Q&&(g(a,!1),0===a.strm.avail_out))return M}return a.insert=0,b===v?(g(a,!0),0===a.strm.avail_out?W:R):(a.strstart>a.block_start&&g(a,!1),M)}),new B(4,4,8,4,t),new B(4,5,16,8,t),new B(4,6,32,32,t),new B(4,4,16,16,A),new B(8,16,32,32,A),new B(8,16,128,128,A),new B(8,32,128,256,A),new B(32,128,258,1024,A),new B(32,258,258,4096,A)];d.deflateInit=function(a,b){return y(a,b,V,15,8,0)};d.deflateInit2=y;d.deflateReset=
+x;d.deflateResetKeep=z;d.deflateSetHeader=function(a,b){return a&&a.state?2!==a.state.wrap?N:(a.state.gzhead=b,S):N};d.deflate=function(b,d){var J,k,f,u;if(!b||!b.state||5<d||0>d)return b?a(b,N):N;if(k=b.state,!b.output||!b.input&&0!==b.avail_in||666===k.status&&d!==v)return a(b,0===b.avail_out?-5:N);if(k.strm=b,J=k.last_flush,k.last_flush=d,k.status===Z)2===k.wrap?(b.adler=0,l(k,31),l(k,139),l(k,8),k.gzhead?(l(k,(k.gzhead.text?1:0)+(k.gzhead.hcrc?2:0)+(k.gzhead.extra?4:0)+(k.gzhead.name?8:0)+(k.gzhead.comment?
+16:0)),l(k,255&k.gzhead.time),l(k,k.gzhead.time>>8&255),l(k,k.gzhead.time>>16&255),l(k,k.gzhead.time>>24&255),l(k,9===k.level?2:2<=k.strategy||2>k.level?4:0),l(k,255&k.gzhead.os),k.gzhead.extra&&k.gzhead.extra.length&&(l(k,255&k.gzhead.extra.length),l(k,k.gzhead.extra.length>>8&255)),k.gzhead.hcrc&&(b.adler=H(b.adler,k.pending_buf,k.pending,0)),k.gzindex=0,k.status=69):(l(k,0),l(k,0),l(k,0),l(k,0),l(k,0),l(k,9===k.level?2:2<=k.strategy||2>k.level?4:0),l(k,3),k.status=Y)):(f=V+(k.w_bits-8<<4)<<8,f|=
+(2<=k.strategy||2>k.level?0:6>k.level?1:6===k.level?2:3)<<6,0!==k.strstart&&(f|=32),k.status=Y,h(k,f+(31-f%31)),0!==k.strstart&&(h(k,b.adler>>>16),h(k,65535&b.adler)),b.adler=1);if(69===k.status)if(k.gzhead.extra){for(f=k.pending;k.gzindex<(65535&k.gzhead.extra.length)&&(k.pending!==k.pending_buf_size||(k.gzhead.hcrc&&k.pending>f&&(b.adler=H(b.adler,k.pending_buf,k.pending-f,f)),c(b),f=k.pending,k.pending!==k.pending_buf_size));)l(k,255&k.gzhead.extra[k.gzindex]),k.gzindex++;k.gzhead.hcrc&&k.pending>
+f&&(b.adler=H(b.adler,k.pending_buf,k.pending-f,f));k.gzindex===k.gzhead.extra.length&&(k.gzindex=0,k.status=73)}else k.status=73;if(73===k.status)if(k.gzhead.name){f=k.pending;do{if(k.pending===k.pending_buf_size&&(k.gzhead.hcrc&&k.pending>f&&(b.adler=H(b.adler,k.pending_buf,k.pending-f,f)),c(b),f=k.pending,k.pending===k.pending_buf_size)){u=1;break}u=k.gzindex<k.gzhead.name.length?255&k.gzhead.name.charCodeAt(k.gzindex++):0;l(k,u)}while(0!==u);k.gzhead.hcrc&&k.pending>f&&(b.adler=H(b.adler,k.pending_buf,
+k.pending-f,f));0===u&&(k.gzindex=0,k.status=91)}else k.status=91;if(91===k.status)if(k.gzhead.comment){f=k.pending;do{if(k.pending===k.pending_buf_size&&(k.gzhead.hcrc&&k.pending>f&&(b.adler=H(b.adler,k.pending_buf,k.pending-f,f)),c(b),f=k.pending,k.pending===k.pending_buf_size)){u=1;break}u=k.gzindex<k.gzhead.comment.length?255&k.gzhead.comment.charCodeAt(k.gzindex++):0;l(k,u)}while(0!==u);k.gzhead.hcrc&&k.pending>f&&(b.adler=H(b.adler,k.pending_buf,k.pending-f,f));0===u&&(k.status=103)}else k.status=
+103;if(103===k.status&&(k.gzhead.hcrc?(k.pending+2>k.pending_buf_size&&c(b),k.pending+2<=k.pending_buf_size&&(l(k,255&b.adler),l(k,b.adler>>8&255),b.adler=0,k.status=Y)):k.status=Y),0!==k.pending){if(c(b),0===b.avail_out)return k.last_flush=-1,S}else if(0===b.avail_in&&(d<<1)-(4<d?9:0)<=(J<<1)-(4<J?9:0)&&d!==v)return a(b,-5);if(666===k.status&&0!==b.avail_in)return a(b,-5);if(0!==b.avail_in||0!==k.lookahead||d!==I&&666!==k.status){var D;if(2===k.strategy)a:{for(var n;;){if(0===k.lookahead&&(q(k),
+0===k.lookahead)){if(d===I){D=M;break a}break}if(k.match_length=0,n=m._tr_tally(k,0,k.window[k.strstart]),k.lookahead--,k.strstart++,n&&(g(k,!1),0===k.strm.avail_out)){D=M;break a}}D=(k.insert=0,d===v?(g(k,!0),0===k.strm.avail_out?W:R):k.last_lit&&(g(k,!1),0===k.strm.avail_out)?M:U)}else if(3===k.strategy)a:{var r,F;for(n=k.window;;){if(k.lookahead<=K){if(q(k),k.lookahead<=K&&d===I){D=M;break a}if(0===k.lookahead)break}if(k.match_length=0,k.lookahead>=C&&0<k.strstart&&(F=k.strstart-1,r=n[F],r===n[++F]&&
+r===n[++F]&&r===n[++F])){for(J=k.strstart+K;r===n[++F]&&r===n[++F]&&r===n[++F]&&r===n[++F]&&r===n[++F]&&r===n[++F]&&r===n[++F]&&r===n[++F]&&F<J;);k.match_length=K-(J-F);k.match_length>k.lookahead&&(k.match_length=k.lookahead)}if(k.match_length>=C?(D=m._tr_tally(k,1,k.match_length-C),k.lookahead-=k.match_length,k.strstart+=k.match_length,k.match_length=0):(D=m._tr_tally(k,0,k.window[k.strstart]),k.lookahead--,k.strstart++),D&&(g(k,!1),0===k.strm.avail_out)){D=M;break a}}D=(k.insert=0,d===v?(g(k,!0),
+0===k.strm.avail_out?W:R):k.last_lit&&(g(k,!1),0===k.strm.avail_out)?M:U)}else D=p[k.level].func(k,d);if(D!==W&&D!==R||(k.status=666),D===M||D===W)return 0===b.avail_out&&(k.last_flush=-1),S;if(D===U&&(1===d?m._tr_align(k):5!==d&&(m._tr_stored_block(k,0,0,!1),3===d&&(e(k.head),0===k.lookahead&&(k.strstart=0,k.block_start=0,k.insert=0))),c(b),0===b.avail_out))return k.last_flush=-1,S}return d!==v?S:0>=k.wrap?1:(2===k.wrap?(l(k,255&b.adler),l(k,b.adler>>8&255),l(k,b.adler>>16&255),l(k,b.adler>>24&255),
+l(k,255&b.total_in),l(k,b.total_in>>8&255),l(k,b.total_in>>16&255),l(k,b.total_in>>24&255)):(h(k,b.adler>>>16),h(k,65535&b.adler)),c(b),0<k.wrap&&(k.wrap=-k.wrap),0!==k.pending?S:1)};d.deflateEnd=function(b){var d;return b&&b.state?(d=b.state.status,d!==Z&&69!==d&&73!==d&&91!==d&&103!==d&&d!==Y&&666!==d?a(b,N):(b.state=null,d===Y?a(b,-3):S)):N};d.deflateSetDictionary=function(a,b){var d,c,v,f,u,g,p;c=b.length;if(!a||!a.state||(d=a.state,f=d.wrap,2===f||1===f&&d.status!==Z||d.lookahead))return N;1===
+f&&(a.adler=O(a.adler,b,c,0));d.wrap=0;c>=d.w_size&&(0===f&&(e(d.head),d.strstart=0,d.block_start=0,d.insert=0),u=new D.Buf8(d.w_size),D.arraySet(u,b,c-d.w_size,d.w_size,0),b=u,c=d.w_size);u=a.avail_in;g=a.next_in;p=a.input;a.avail_in=c;a.next_in=0;a.input=b;for(q(d);d.lookahead>=C;){c=d.strstart;v=d.lookahead-(C-1);do d.ins_h=(d.ins_h<<d.hash_shift^d.window[c+C-1])&d.hash_mask,d.prev[c&d.w_mask]=d.head[d.ins_h],d.head[d.ins_h]=c,c++;while(--v);d.strstart=c;d.lookahead=C-1;q(d)}return d.strstart+=
+d.lookahead,d.block_start=d.strstart,d.insert=d.lookahead,d.lookahead=0,d.match_length=d.prev_length=C-1,d.match_available=0,a.next_in=g,a.input=p,a.avail_in=u,d.wrap=f,S};d.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":62,"./adler32":64,"./crc32":66,"./messages":72,"./trees":73}],68:[function(b,f,d){f.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],69:[function(b,f,d){f.exports=
+function(a,b){var d,e,f,h,n,q,t,A,B,G,z,x,y,p,D,m,O,H,u,I,v,S,N,F;d=a.state;e=a.next_in;N=a.input;f=e+(a.avail_in-5);h=a.next_out;F=a.output;n=h-(b-a.avail_out);q=h+(a.avail_out-257);t=d.dmax;A=d.wsize;B=d.whave;G=d.wnext;z=d.window;x=d.hold;y=d.bits;p=d.lencode;D=d.distcode;m=(1<<d.lenbits)-1;O=(1<<d.distbits)-1;a:do b:for(15>y&&(x+=N[e++]<<y,y+=8,x+=N[e++]<<y,y+=8),H=p[x&m];;){if(u=H>>>24,x>>>=u,y-=u,u=H>>>16&255,0===u)F[h++]=65535&H;else{if(!(16&u)){if(0===(64&u)){H=p[(65535&H)+(x&(1<<u)-1)];continue b}if(32&
+u){d.mode=12;break a}a.msg="invalid literal/length code";d.mode=30;break a}I=65535&H;(u&=15)&&(y<u&&(x+=N[e++]<<y,y+=8),I+=x&(1<<u)-1,x>>>=u,y-=u);15>y&&(x+=N[e++]<<y,y+=8,x+=N[e++]<<y,y+=8);H=D[x&O];c:for(;;){if(u=H>>>24,x>>>=u,y-=u,u=H>>>16&255,!(16&u)){if(0===(64&u)){H=D[(65535&H)+(x&(1<<u)-1)];continue c}a.msg="invalid distance code";d.mode=30;break a}if(v=65535&H,u&=15,y<u&&(x+=N[e++]<<y,y+=8,y<u&&(x+=N[e++]<<y,y+=8)),v+=x&(1<<u)-1,v>t){a.msg="invalid distance too far back";d.mode=30;break a}if(x>>>=
+u,y-=u,u=h-n,v>u){if(u=v-u,u>B&&d.sane){a.msg="invalid distance too far back";d.mode=30;break a}if(H=0,S=z,0===G){if(H+=A-u,u<I){I-=u;do F[h++]=z[H++];while(--u);H=h-v;S=F}}else if(G<u){if(H+=A+G-u,u-=G,u<I){I-=u;do F[h++]=z[H++];while(--u);if(H=0,G<I){u=G;I-=u;do F[h++]=z[H++];while(--u);H=h-v;S=F}}}else if(H+=G-u,u<I){I-=u;do F[h++]=z[H++];while(--u);H=h-v;S=F}for(;2<I;)F[h++]=S[H++],F[h++]=S[H++],F[h++]=S[H++],I-=3;I&&(F[h++]=S[H++],1<I&&(F[h++]=S[H++]))}else{H=h-v;do F[h++]=F[H++],F[h++]=F[H++],
+F[h++]=F[H++],I-=3;while(2<I);I&&(F[h++]=F[H++],1<I&&(F[h++]=F[H++]))}break}}break}while(e<f&&h<q);I=y>>3;e-=I;y-=I<<3;a.next_in=e;a.next_out=h;a.avail_in=e<f?5+(f-e):5-(e-f);a.avail_out=h<q?257+(q-h):257-(h-q);d.hold=x&(1<<y)-1;d.bits=y}},{}],70:[function(b,f,d){function a(a){return(a>>>24&255)+(a>>>8&65280)+((65280&a)<<8)+((255&a)<<24)}function e(){this.mode=0;this.last=!1;this.wrap=0;this.havedict=!1;this.total=this.check=this.dmax=this.flags=0;this.head=null;this.wnext=this.whave=this.wsize=this.wbits=
+0;this.window=null;this.extra=this.offset=this.length=this.bits=this.hold=0;this.distcode=this.lencode=null;this.have=this.ndist=this.nlen=this.ncode=this.distbits=this.lenbits=0;this.next=null;this.lens=new A.Buf16(320);this.work=new A.Buf16(288);this.distdyn=this.lendyn=null;this.was=this.back=this.sane=0}function c(a){var b;return a&&a.state?(b=a.state,a.total_in=a.total_out=b.total=0,a.msg="",b.wrap&&(a.adler=1&b.wrap),b.mode=D,b.last=0,b.havedict=0,b.dmax=32768,b.head=null,b.hold=0,b.bits=0,
+b.lencode=b.lendyn=new A.Buf32(m),b.distcode=b.distdyn=new A.Buf32(O),b.sane=1,b.back=-1,y):p}function g(a){var b;return a&&a.state?(b=a.state,b.wsize=0,b.whave=0,b.wnext=0,c(a)):p}function l(a,b){var d,c;return a&&a.state?(c=a.state,0>b?(d=0,b=-b):(d=(b>>4)+1,48>b&&(b&=15)),b&&(8>b||15<b)?p:(null!==c.window&&c.wbits!==b&&(c.window=null),c.wrap=d,c.wbits=b,g(a))):p}function h(a,b){var d,c;return a?(c=new e,a.state=c,c.window=null,d=l(a,b),d!==y&&(a.state=null),d):p}function n(a,b,d,c){var e;a=a.state;
+return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new A.Buf8(a.wsize)),c>=a.wsize?(A.arraySet(a.window,b,d-a.wsize,a.wsize,0),a.wnext=0,a.whave=a.wsize):(e=a.wsize-a.wnext,e>c&&(e=c),A.arraySet(a.window,b,d-c,e,a.wnext),c-=e,c?(A.arraySet(a.window,b,d-c,c,0),a.wnext=c,a.whave=a.wsize):(a.wnext+=e,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=e))),0}var q,t,A=b("../utils/common"),B=b("./adler32"),G=b("./crc32"),z=b("./inffast"),x=b("./inftrees"),y=0,p=-2,D=1,m=852,
+O=592,H=!0;d.inflateReset=g;d.inflateReset2=l;d.inflateResetKeep=c;d.inflateInit=function(a){return h(a,15)};d.inflateInit2=h;d.inflate=function(b,d){var c,e,f,g,l,h,u,m,r,I,O,E,ba,L,C,K,Q,Z,Y,M,U,W,R=0,P=new A.Buf8(4),ea=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||!b.output||!b.input&&0!==b.avail_in)return p;c=b.state;12===c.mode&&(c.mode=13);l=b.next_out;f=b.output;u=b.avail_out;g=b.next_in;e=b.input;h=b.avail_in;m=c.hold;r=c.bits;I=h;O=u;U=y;a:for(;;)switch(c.mode){case D:if(0===
+c.wrap){c.mode=13;break}for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(2&c.wrap&&35615===m){c.check=0;P[0]=255&m;P[1]=m>>>8&255;c.check=G(c.check,P,2,0);r=m=0;c.mode=2;break}if(c.flags=0,c.head&&(c.head.done=!1),!(1&c.wrap)||(((255&m)<<8)+(m>>8))%31){b.msg="incorrect header check";c.mode=30;break}if(8!==(15&m)){b.msg="unknown compression method";c.mode=30;break}if(m>>>=4,r-=4,M=(15&m)+8,0===c.wbits)c.wbits=M;else if(M>c.wbits){b.msg="invalid window size";c.mode=30;break}c.dmax=1<<M;b.adler=
+c.check=1;c.mode=512&m?10:12;r=m=0;break;case 2:for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(c.flags=m,8!==(255&c.flags)){b.msg="unknown compression method";c.mode=30;break}if(57344&c.flags){b.msg="unknown header flags set";c.mode=30;break}c.head&&(c.head.text=m>>8&1);512&c.flags&&(P[0]=255&m,P[1]=m>>>8&255,c.check=G(c.check,P,2,0));r=m=0;c.mode=3;case 3:for(;32>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.head&&(c.head.time=m);512&c.flags&&(P[0]=255&m,P[1]=m>>>8&255,P[2]=m>>>16&255,P[3]=
+m>>>24&255,c.check=G(c.check,P,4,0));r=m=0;c.mode=4;case 4:for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.head&&(c.head.xflags=255&m,c.head.os=m>>8);512&c.flags&&(P[0]=255&m,P[1]=m>>>8&255,c.check=G(c.check,P,2,0));r=m=0;c.mode=5;case 5:if(1024&c.flags){for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.length=m;c.head&&(c.head.extra_len=m);512&c.flags&&(P[0]=255&m,P[1]=m>>>8&255,c.check=G(c.check,P,2,0));r=m=0}else c.head&&(c.head.extra=null);c.mode=6;case 6:if(1024&c.flags&&(E=c.length,
+E>h&&(E=h),E&&(c.head&&(M=c.head.extra_len-c.length,c.head.extra||(c.head.extra=Array(c.head.extra_len)),A.arraySet(c.head.extra,e,g,E,M)),512&c.flags&&(c.check=G(c.check,e,E,g)),h-=E,g+=E,c.length-=E),c.length))break a;c.length=0;c.mode=7;case 7:if(2048&c.flags){if(0===h)break a;E=0;do M=e[g+E++],c.head&&M&&65536>c.length&&(c.head.name+=String.fromCharCode(M));while(M&&E<h);if(512&c.flags&&(c.check=G(c.check,e,E,g)),h-=E,g+=E,M)break a}else c.head&&(c.head.name=null);c.length=0;c.mode=8;case 8:if(4096&
+c.flags){if(0===h)break a;E=0;do M=e[g+E++],c.head&&M&&65536>c.length&&(c.head.comment+=String.fromCharCode(M));while(M&&E<h);if(512&c.flags&&(c.check=G(c.check,e,E,g)),h-=E,g+=E,M)break a}else c.head&&(c.head.comment=null);c.mode=9;case 9:if(512&c.flags){for(;16>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(m!==(65535&c.check)){b.msg="header crc mismatch";c.mode=30;break}r=m=0}c.head&&(c.head.hcrc=c.flags>>9&1,c.head.done=!0);b.adler=c.check=0;c.mode=12;break;case 10:for(;32>r;){if(0===h)break a;
+h--;m+=e[g++]<<r;r+=8}b.adler=c.check=a(m);r=m=0;c.mode=11;case 11:if(0===c.havedict)return b.next_out=l,b.avail_out=u,b.next_in=g,b.avail_in=h,c.hold=m,c.bits=r,2;b.adler=c.check=1;c.mode=12;case 12:if(5===d||6===d)break a;case 13:if(c.last){m>>>=7&r;r-=7&r;c.mode=27;break}for(;3>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}switch(c.last=1&m,m>>>=1,--r,3&m){case 0:c.mode=14;break;case 1:K=c;if(H){q=new A.Buf32(512);t=new A.Buf32(32);for(L=0;144>L;)K.lens[L++]=8;for(;256>L;)K.lens[L++]=9;for(;280>L;)K.lens[L++]=
+7;for(;288>L;)K.lens[L++]=8;x(1,K.lens,0,288,q,0,K.work,{bits:9});for(L=0;32>L;)K.lens[L++]=5;x(2,K.lens,0,32,t,0,K.work,{bits:5});H=!1}K.lencode=q;K.lenbits=9;K.distcode=t;K.distbits=5;if(c.mode=20,6===d){m>>>=2;r-=2;break a}break;case 2:c.mode=17;break;case 3:b.msg="invalid block type",c.mode=30}m>>>=2;r-=2;break;case 14:m>>>=7&r;for(r-=7&r;32>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if((65535&m)!==(m>>>16^65535)){b.msg="invalid stored block lengths";c.mode=30;break}if(c.length=65535&m,m=0,r=
+0,c.mode=15,6===d)break a;case 15:c.mode=16;case 16:if(E=c.length){if(E>h&&(E=h),E>u&&(E=u),0===E)break a;A.arraySet(f,e,g,E,l);h-=E;g+=E;u-=E;l+=E;c.length-=E;break}c.mode=12;break;case 17:for(;14>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(c.nlen=(31&m)+257,m>>>=5,r-=5,c.ndist=(31&m)+1,m>>>=5,r-=5,c.ncode=(15&m)+4,m>>>=4,r-=4,286<c.nlen||30<c.ndist){b.msg="too many length or distance symbols";c.mode=30;break}c.have=0;c.mode=18;case 18:for(;c.have<c.ncode;){for(;3>r;){if(0===h)break a;h--;m+=e[g++]<<
+r;r+=8}c.lens[ea[c.have++]]=7&m;m>>>=3;r-=3}for(;19>c.have;)c.lens[ea[c.have++]]=0;if(c.lencode=c.lendyn,c.lenbits=7,W={bits:c.lenbits},U=x(0,c.lens,0,19,c.lencode,0,c.work,W),c.lenbits=W.bits,U){b.msg="invalid code lengths set";c.mode=30;break}c.have=0;c.mode=19;case 19:for(;c.have<c.nlen+c.ndist;){for(;R=c.lencode[m&(1<<c.lenbits)-1],C=R>>>24,K=65535&R,!(C<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(16>K)m>>>=C,r-=C,c.lens[c.have++]=K;else{if(16===K){for(L=C+2;r<L;){if(0===h)break a;h--;m+=
+e[g++]<<r;r+=8}if(m>>>=C,r-=C,0===c.have){b.msg="invalid bit length repeat";c.mode=30;break}M=c.lens[c.have-1];E=3+(3&m);m>>>=2;r-=2}else if(17===K){for(L=C+3;r<L;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}m>>>=C;r-=C;M=0;E=3+(7&m);m>>>=3;r-=3}else{for(L=C+7;r<L;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}m>>>=C;r-=C;M=0;E=11+(127&m);m>>>=7;r-=7}if(c.have+E>c.nlen+c.ndist){b.msg="invalid bit length repeat";c.mode=30;break}for(;E--;)c.lens[c.have++]=M}}if(30===c.mode)break;if(0===c.lens[256]){b.msg="invalid code -- missing end-of-block";
+c.mode=30;break}if(c.lenbits=9,W={bits:c.lenbits},U=x(1,c.lens,0,c.nlen,c.lencode,0,c.work,W),c.lenbits=W.bits,U){b.msg="invalid literal/lengths set";c.mode=30;break}if(c.distbits=6,c.distcode=c.distdyn,W={bits:c.distbits},U=x(2,c.lens,c.nlen,c.ndist,c.distcode,0,c.work,W),c.distbits=W.bits,U){b.msg="invalid distances set";c.mode=30;break}if(c.mode=20,6===d)break a;case 20:c.mode=21;case 21:if(6<=h&&258<=u){b.next_out=l;b.avail_out=u;b.next_in=g;b.avail_in=h;c.hold=m;c.bits=r;z(b,O);l=b.next_out;
+f=b.output;u=b.avail_out;g=b.next_in;e=b.input;h=b.avail_in;m=c.hold;r=c.bits;12===c.mode&&(c.back=-1);break}for(c.back=0;R=c.lencode[m&(1<<c.lenbits)-1],C=R>>>24,L=R>>>16&255,K=65535&R,!(C<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(L&&0===(240&L)){Q=C;Z=L;for(Y=K;R=c.lencode[Y+((m&(1<<Q+Z)-1)>>Q)],C=R>>>24,L=R>>>16&255,K=65535&R,!(Q+C<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}m>>>=Q;r-=Q;c.back+=Q}if(m>>>=C,r-=C,c.back+=C,c.length=K,0===L){c.mode=26;break}if(32&L){c.back=-1;c.mode=12;break}if(64&
+L){b.msg="invalid literal/length code";c.mode=30;break}c.extra=15&L;c.mode=22;case 22:if(c.extra){for(L=c.extra;r<L;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.length+=m&(1<<c.extra)-1;m>>>=c.extra;r-=c.extra;c.back+=c.extra}c.was=c.length;c.mode=23;case 23:for(;R=c.distcode[m&(1<<c.distbits)-1],C=R>>>24,L=R>>>16&255,K=65535&R,!(C<=r);){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(0===(240&L)){Q=C;Z=L;for(Y=K;R=c.distcode[Y+((m&(1<<Q+Z)-1)>>Q)],C=R>>>24,L=R>>>16&255,K=65535&R,!(Q+C<=r);){if(0===h)break a;
+h--;m+=e[g++]<<r;r+=8}m>>>=Q;r-=Q;c.back+=Q}if(m>>>=C,r-=C,c.back+=C,64&L){b.msg="invalid distance code";c.mode=30;break}c.offset=K;c.extra=15&L;c.mode=24;case 24:if(c.extra){for(L=c.extra;r<L;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}c.offset+=m&(1<<c.extra)-1;m>>>=c.extra;r-=c.extra;c.back+=c.extra}if(c.offset>c.dmax){b.msg="invalid distance too far back";c.mode=30;break}c.mode=25;case 25:if(0===u)break a;if(E=O-u,c.offset>E){if(E=c.offset-E,E>c.whave&&c.sane){b.msg="invalid distance too far back";
+c.mode=30;break}E>c.wnext?(E-=c.wnext,ba=c.wsize-E):ba=c.wnext-E;E>c.length&&(E=c.length);L=c.window}else L=f,ba=l-c.offset,E=c.length;E>u&&(E=u);u-=E;c.length-=E;do f[l++]=L[ba++];while(--E);0===c.length&&(c.mode=21);break;case 26:if(0===u)break a;f[l++]=c.length;u--;c.mode=21;break;case 27:if(c.wrap){for(;32>r;){if(0===h)break a;h--;m|=e[g++]<<r;r+=8}if(O-=u,b.total_out+=O,c.total+=O,O&&(b.adler=c.check=c.flags?G(c.check,f,O,l-O):B(c.check,f,O,l-O)),O=u,(c.flags?m:a(m))!==c.check){b.msg="incorrect data check";
+c.mode=30;break}r=m=0}c.mode=28;case 28:if(c.wrap&&c.flags){for(;32>r;){if(0===h)break a;h--;m+=e[g++]<<r;r+=8}if(m!==(4294967295&c.total)){b.msg="incorrect length check";c.mode=30;break}r=m=0}c.mode=29;case 29:U=1;break a;case 30:U=-3;break a;case 31:return-4;default:return p}return b.next_out=l,b.avail_out=u,b.next_in=g,b.avail_in=h,c.hold=m,c.bits=r,(c.wsize||O!==b.avail_out&&30>c.mode&&(27>c.mode||4!==d))&&n(b,b.output,b.next_out,O-b.avail_out)?(c.mode=31,-4):(I-=b.avail_in,O-=b.avail_out,b.total_in+=
+I,b.total_out+=O,c.total+=O,c.wrap&&O&&(b.adler=c.check=c.flags?G(c.check,f,O,b.next_out-O):B(c.check,f,O,b.next_out-O)),b.data_type=c.bits+(c.last?64:0)+(12===c.mode?128:0)+(20===c.mode||15===c.mode?256:0),(0===I&&0===O||4===d)&&U===y&&(U=-5),U)};d.inflateEnd=function(a){if(!a||!a.state)return p;var b=a.state;return b.window&&(b.window=null),a.state=null,y};d.inflateGetHeader=function(a,b){var c;return a&&a.state?(c=a.state,0===(2&c.wrap)?p:(c.head=b,b.done=!1,y)):p};d.inflateSetDictionary=function(a,
+b){var c,d,e=b.length;return a&&a.state?(c=a.state,0!==c.wrap&&11!==c.mode?p:11===c.mode&&(d=1,d=B(d,b,e,0),d!==c.check)?-3:n(a,b,e,e)?(c.mode=31,-4):(c.havedict=1,y)):p};d.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":62,"./adler32":64,"./crc32":66,"./inffast":69,"./inftrees":71}],71:[function(b,f,d){var a=b("../utils/common"),e=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],c=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,
+19,19,19,20,20,20,20,21,21,21,21,16,72,78],g=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],l=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];f.exports=function(b,d,f,t,A,B,G,z){var h,n,p,D,m,O,H,u,I=z.bits,v,q,N,F,X,T,aa=0,V,r=null,da=0,ca=new a.Buf16(16);D=new a.Buf16(16);var E=null,ba=0;for(v=0;15>=v;v++)ca[v]=0;for(q=0;q<t;q++)ca[d[f+q]]++;F=I;for(N=15;1<=N&&0===ca[N];N--);
+if(F>N&&(F=N),0===N)return A[B++]=20971520,A[B++]=20971520,z.bits=1,0;for(I=1;I<N&&0===ca[I];I++);F<I&&(F=I);for(v=h=1;15>=v;v++)if(h<<=1,h-=ca[v],0>h)return-1;if(0<h&&(0===b||1!==N))return-1;D[1]=0;for(v=1;15>v;v++)D[v+1]=D[v]+ca[v];for(q=0;q<t;q++)0!==d[f+q]&&(G[D[d[f+q]]++]=q);if(0===b?(r=E=G,m=19):1===b?(r=e,da-=257,E=c,ba-=257,m=256):(r=g,E=l,m=-1),V=0,q=0,v=I,D=B,X=F,T=0,p=-1,aa=1<<F,t=aa-1,1===b&&852<aa||2===b&&592<aa)return 1;for(var L=0;;){L++;O=v-T;G[q]<m?(H=0,u=G[q]):G[q]>m?(H=E[ba+G[q]],
+u=r[da+G[q]]):(H=96,u=0);h=1<<v-T;I=n=1<<X;do n-=h,A[D+(V>>T)+n]=O<<24|H<<16|u|0;while(0!==n);for(h=1<<v-1;V&h;)h>>=1;if(0!==h?(V&=h-1,V+=h):V=0,q++,0===--ca[v]){if(v===N)break;v=d[f+G[q]]}if(v>F&&(V&t)!==p){0===T&&(T=F);D+=I;X=v-T;for(h=1<<X;X+T<N&&(h-=ca[X+T],!(0>=h));)X++,h<<=1;if(aa+=1<<X,1===b&&852<aa||2===b&&592<aa)return 1;p=V&t;A[p]=F<<24|X<<16|D-B|0}}return 0!==V&&(A[D+V]=v-T<<24|4194304),z.bits=F,0}},{"../utils/common":62}],72:[function(b,f,d){f.exports={2:"need dictionary",1:"stream end",
+0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],73:[function(b,f,d){function a(a){for(var b=a.length;0<=--b;)a[b]=0}function e(a,b,c,d,e){this.static_tree=a;this.extra_bits=b;this.extra_base=c;this.elems=d;this.max_length=e;this.has_stree=a&&a.length}function c(a,b){this.dyn_tree=a;this.max_code=0;this.stat_desc=b}function g(a,b){a.pending_buf[a.pending++]=255&b;a.pending_buf[a.pending++]=b>>>8&255}function l(a,
+b,c){a.bi_valid>aa-c?(a.bi_buf|=b<<a.bi_valid&65535,g(a,a.bi_buf),a.bi_buf=b>>aa-a.bi_valid,a.bi_valid+=c-aa):(a.bi_buf|=b<<a.bi_valid&65535,a.bi_valid+=c)}function h(a,b,c){l(a,c[2*b],c[2*b+1])}function n(a,b){var c=0;do c|=1&a,a>>>=1,c<<=1;while(0<--b);return c>>>1}function q(a,b,c){var d,e=Array(T+1),f=0;for(d=1;d<=T;d++)e[d]=f=f+c[d-1]<<1;for(c=0;c<=b;c++)d=a[2*c+1],0!==d&&(a[2*c]=n(e[d]++,d))}function t(a){var b;for(b=0;b<S;b++)a.dyn_ltree[2*b]=0;for(b=0;b<N;b++)a.dyn_dtree[2*b]=0;for(b=0;b<
+F;b++)a.bl_tree[2*b]=0;a.dyn_ltree[2*V]=1;a.opt_len=a.static_len=0;a.last_lit=a.matches=0}function A(a){8<a.bi_valid?g(a,a.bi_buf):0<a.bi_valid&&(a.pending_buf[a.pending++]=a.bi_buf);a.bi_buf=0;a.bi_valid=0}function B(a,b,c,d){var e=2*b,f=2*c;return a[e]<a[f]||a[e]===a[f]&&d[b]<=d[c]}function G(a,b,c){for(var d=a.heap[c],e=c<<1;e<=a.heap_len&&(e<a.heap_len&&B(b,a.heap[e+1],a.heap[e],a.depth)&&e++,!B(b,d,a.heap[e],a.depth));)a.heap[c]=a.heap[e],c=e,e<<=1;a.heap[c]=d}function z(a,b,c){var d,e,f,k,g=
+0;if(0!==a.last_lit){do d=a.pending_buf[a.d_buf+2*g]<<8|a.pending_buf[a.d_buf+2*g+1],e=a.pending_buf[a.l_buf+g],g++,0===d?h(a,e,b):(f=Y[e],h(a,f+v+1,b),k=E[f],0!==k&&(e-=M[f],l(a,e,k)),d--,f=256>d?Z[d]:Z[256+(d>>>7)],h(a,f,c),k=ba[f],0!==k&&(d-=U[f],l(a,d,k)));while(g<a.last_lit)}h(a,V,b)}function x(a,b){var c,d,e,f=b.dyn_tree;d=b.stat_desc.static_tree;var k=b.stat_desc.has_stree,g=b.stat_desc.elems,m=-1;a.heap_len=0;a.heap_max=X;for(c=0;c<g;c++)0!==f[2*c]?(a.heap[++a.heap_len]=m=c,a.depth[c]=0):
+f[2*c+1]=0;for(;2>a.heap_len;)e=a.heap[++a.heap_len]=2>m?++m:0,f[2*e]=1,a.depth[e]=0,a.opt_len--,k&&(a.static_len-=d[2*e+1]);b.max_code=m;for(c=a.heap_len>>1;1<=c;c--)G(a,f,c);e=g;do c=a.heap[1],a.heap[1]=a.heap[a.heap_len--],G(a,f,1),d=a.heap[1],a.heap[--a.heap_max]=c,a.heap[--a.heap_max]=d,f[2*e]=f[2*c]+f[2*d],a.depth[e]=(a.depth[c]>=a.depth[d]?a.depth[c]:a.depth[d])+1,f[2*c+1]=f[2*d+1]=e,a.heap[1]=e++,G(a,f,1);while(2<=a.heap_len);a.heap[--a.heap_max]=a.heap[1];var h,p,k=b.dyn_tree,g=b.max_code,
+l=b.stat_desc.static_tree,u=b.stat_desc.has_stree,D=b.stat_desc.extra_bits,n=b.stat_desc.extra_base,J=b.stat_desc.max_length,v=0;for(d=0;d<=T;d++)a.bl_count[d]=0;k[2*a.heap[a.heap_max]+1]=0;for(c=a.heap_max+1;c<X;c++)e=a.heap[c],d=k[2*k[2*e+1]+1]+1,d>J&&(d=J,v++),k[2*e+1]=d,e>g||(a.bl_count[d]++,h=0,e>=n&&(h=D[e-n]),p=k[2*e],a.opt_len+=p*(d+h),u&&(a.static_len+=p*(l[2*e+1]+h)));if(0!==v){do{for(d=J-1;0===a.bl_count[d];)d--;a.bl_count[d]--;a.bl_count[d+1]+=2;a.bl_count[J]--;v-=2}while(0<v);for(d=J;0!==
+d;d--)for(e=a.bl_count[d];0!==e;)h=a.heap[--c],h>g||(k[2*h+1]!==d&&(a.opt_len+=(d-k[2*h+1])*k[2*h],k[2*h+1]=d),e--)}q(f,m,a.bl_count)}function y(a,b,c){var d,e,f=-1,k=b[1],g=0,h=7,m=4;0===k&&(h=138,m=3);b[2*(c+1)+1]=65535;for(d=0;d<=c;d++)e=k,k=b[2*(d+1)+1],++g<h&&e===k||(g<m?a.bl_tree[2*e]+=g:0!==e?(e!==f&&a.bl_tree[2*e]++,a.bl_tree[2*r]++):10>=g?a.bl_tree[2*da]++:a.bl_tree[2*ca]++,g=0,f=e,0===k?(h=138,m=3):e===k?(h=6,m=3):(h=7,m=4))}function p(a,b,c){var d,e,f=-1,k=b[1],g=0,m=7,p=4;0===k&&(m=138,
+p=3);for(d=0;d<=c;d++)if(e=k,k=b[2*(d+1)+1],!(++g<m&&e===k)){if(g<p){do h(a,e,a.bl_tree);while(0!==--g)}else 0!==e?(e!==f&&(h(a,e,a.bl_tree),g--),h(a,r,a.bl_tree),l(a,g-3,2)):10>=g?(h(a,da,a.bl_tree),l(a,g-3,3)):(h(a,ca,a.bl_tree),l(a,g-11,7));g=0;f=e;0===k?(m=138,p=3):e===k?(m=6,p=3):(m=7,p=4)}}function D(a){var b,c=4093624447;for(b=0;31>=b;b++,c>>>=1)if(1&c&&0!==a.dyn_ltree[2*b])return H;if(0!==a.dyn_ltree[18]||0!==a.dyn_ltree[20]||0!==a.dyn_ltree[26])return u;for(b=32;b<v;b++)if(0!==a.dyn_ltree[2*
+b])return u;return H}function m(a,b,c,d){l(a,(I<<1)+(d?1:0),3);A(a);g(a,c);g(a,~c);O.arraySet(a.pending_buf,a.window,b,c,a.pending);a.pending+=c}var O=b("../utils/common"),H=0,u=1,I=0,v=256,S=v+1+29,N=30,F=19,X=2*S+1,T=15,aa=16,V=256,r=16,da=17,ca=18,E=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],ba=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],L=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],C=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],K=Array(2*(S+2));a(K);
+var Q=Array(2*N);a(Q);var Z=Array(512);a(Z);var Y=Array(256);a(Y);var M=Array(29);a(M);var U=Array(N);a(U);var W,R,P,ea=!1;d._tr_init=function(a){if(!ea){var b,d,f,g=Array(T+1);for(f=d=0;28>f;f++)for(M[f]=d,b=0;b<1<<E[f];b++)Y[d++]=f;Y[d-1]=f;for(f=d=0;16>f;f++)for(U[f]=d,b=0;b<1<<ba[f];b++)Z[d++]=f;for(d>>=7;f<N;f++)for(U[f]=d<<7,b=0;b<1<<ba[f]-7;b++)Z[256+d++]=f;for(b=0;b<=T;b++)g[b]=0;for(b=0;143>=b;)K[2*b+1]=8,b++,g[8]++;for(;255>=b;)K[2*b+1]=9,b++,g[9]++;for(;279>=b;)K[2*b+1]=7,b++,g[7]++;for(;287>=
+b;)K[2*b+1]=8,b++,g[8]++;q(K,S+1,g);for(b=0;b<N;b++)Q[2*b+1]=5,Q[2*b]=n(b,5);W=new e(K,E,v+1,S,T);R=new e(Q,ba,0,N,T);P=new e([],L,0,F,7);ea=!0}a.l_desc=new c(a.dyn_ltree,W);a.d_desc=new c(a.dyn_dtree,R);a.bl_desc=new c(a.bl_tree,P);a.bi_buf=0;a.bi_valid=0;t(a)};d._tr_stored_block=m;d._tr_flush_block=function(a,b,c,d){var e,f,g=0;if(0<a.level){2===a.strm.data_type&&(a.strm.data_type=D(a));x(a,a.l_desc);x(a,a.d_desc);y(a,a.dyn_ltree,a.l_desc.max_code);y(a,a.dyn_dtree,a.d_desc.max_code);x(a,a.bl_desc);
+for(g=F-1;3<=g&&0===a.bl_tree[2*C[g]+1];g--);g=(a.opt_len+=3*(g+1)+14,g);e=a.opt_len+3+7>>>3;f=a.static_len+3+7>>>3;f<=e&&(e=f)}else e=f=c+5;if(c+4<=e&&-1!==b)m(a,b,c,d);else if(4===a.strategy||f===e)l(a,2+(d?1:0),3),z(a,K,Q);else{l(a,4+(d?1:0),3);b=a.l_desc.max_code+1;c=a.d_desc.max_code+1;g+=1;l(a,b-257,5);l(a,c-1,5);l(a,g-4,4);for(e=0;e<g;e++)l(a,a.bl_tree[2*C[e]+1],3);p(a,a.dyn_ltree,b-1);p(a,a.dyn_dtree,c-1);z(a,a.dyn_ltree,a.dyn_dtree)}t(a);d&&A(a)};d._tr_tally=function(a,b,c){return a.pending_buf[a.d_buf+
+2*a.last_lit]=b>>>8&255,a.pending_buf[a.d_buf+2*a.last_lit+1]=255&b,a.pending_buf[a.l_buf+a.last_lit]=255&c,a.last_lit++,0===b?a.dyn_ltree[2*c]++:(a.matches++,b--,a.dyn_ltree[2*(Y[c]+v+1)]++,a.dyn_dtree[2*(256>b?Z[b]:Z[256+(b>>>7)])]++),a.last_lit===a.lit_bufsize-1};d._tr_align=function(a){l(a,2,3);h(a,V,K);16===a.bi_valid?(g(a,a.bi_buf),a.bi_buf=0,a.bi_valid=0):8<=a.bi_valid&&(a.pending_buf[a.pending++]=255&a.bi_buf,a.bi_buf>>=8,a.bi_valid-=8)}},{"../utils/common":62}],74:[function(b,f,d){f.exports=
+function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}]},{},[10])(10)});function VsdxExport(w,b){function f(a,c,d){mxUtils.get(b+"/allConstants.json",function(b){b=JSON.parse(b.request.responseText);for(var e in b)if(1<c&&e==x.CONTENT_TYPES_XML){for(var f=mxUtils.parseXml(b[e]),g=f.documentElement,m=g.children,h=null,p=0;p<m.length;p++){var l=m[p];"/visio/pages/page1.xml"==l.getAttribute(x.PART_NAME)&&(h=l)}for(p=2;p<=c;p++)m=h.cloneNode(),m.setAttribute(x.PART_NAME,"/visio/pages/page"+p+".xml"),g.appendChild(m);B(a,e,f,!0)}else a.file(e,b[e]);d&&d()})}function d(a){var b=
+{};try{var c=a.getGraphBounds().clone(),d=a.view.scale,e=a.view.translate,f=Math.round(c.x/d)-e.x,g=Math.round(c.y/d)-e.y,h=a.pageFormat.width,l=a.pageFormat.height;0>f&&(f+=Math.ceil((e.x-c.x/d)/h)*h);0>g&&(g+=Math.ceil((e.y-c.y/d)/l)*l);var p=Math.max(1,Math.ceil((c.width/d+f)/h)),n=Math.max(1,Math.ceil((c.height/d+g)/l));b.gridEnabled=a.gridEnabled;b.gridSize=a.gridSize;b.guidesEnabled=a.graphHandler.guidesEnabled;b.pageVisible=a.pageVisible;b.pageScale=a.pageScale;b.pageWidth=a.pageFormat.width*
+p;b.pageHeight=a.pageFormat.height*n;b.backgroundClr=a.background;b.mathEnabled=a.mathEnabled;b.shadowVisible=a.shadowVisible}catch(X){}return b}function a(a,b,c){return e(a,b/x.CONVERSION_FACTOR,c)}function e(a,b,c){c=c.createElement("Cell");c.setAttribute("N",a);c.setAttribute("V",b);return c}function c(b,c,d,e,f){var g=f.createElement("Row");g.setAttribute("T",b);g.setAttribute("IX",c);g.appendChild(a("X",d,f));g.appendChild(a("Y",e,f));return g}function g(b,c,d){var f=b.style[mxConstants.STYLE_FILLCOLOR];
 if(f&&"none"!=f){if(c.appendChild(e("FillForegnd",f,d)),(f=b.style[mxConstants.STYLE_GRADIENTCOLOR])&&"none"!=f){c.appendChild(e("FillBkgnd",f,d));var f=b.style[mxConstants.STYLE_GRADIENT_DIRECTION],g=28;if(f)switch(f){case mxConstants.DIRECTION_EAST:g=25;break;case mxConstants.DIRECTION_WEST:g=27;break;case mxConstants.DIRECTION_NORTH:g=30}c.appendChild(e("FillPattern",g,d))}}else c.appendChild(e("FillPattern",0,d));(f=b.style[mxConstants.STYLE_STROKECOLOR])&&"none"!=f?c.appendChild(e("LineColor",
 f,d)):c.appendChild(e("LinePattern",0,d));(f=b.style[mxConstants.STYLE_STROKEWIDTH])&&c.appendChild(a("LineWeight",f,d));(g=b.style[mxConstants.STYLE_OPACITY])?f=g:(f=b.style[mxConstants.STYLE_FILL_OPACITY],g=b.style[mxConstants.STYLE_STROKE_OPACITY]);f&&c.appendChild(e("FillForegndTrans",1-parseInt(f)/100,d));g&&c.appendChild(e("LineColorTrans",1-parseInt(g)/100,d));if(1==b.style[mxConstants.STYLE_DASHED]){f=b.style[mxConstants.STYLE_DASH_PATTERN];g=9;if(f)switch(f){case "1 1":g=10;break;case "1 2":g=
 3;break;case "1 4":g=17}c.appendChild(e("LinePattern",g,d))}1==b.style[mxConstants.STYLE_SHADOW]&&(c.appendChild(e("ShdwPattern",1,d)),c.appendChild(e("ShdwForegnd","#000000",d)),c.appendChild(e("ShdwForegndTrans",.6,d)),c.appendChild(e("ShapeShdwType",1,d)),c.appendChild(e("ShapeShdwOffsetX","0.02946278254943948",d)),c.appendChild(e("ShapeShdwOffsetY","-0.02946278254943948",d)),c.appendChild(e("ShapeShdwScaleFactor","1",d)),c.appendChild(e("ShapeShdwBlur","0.05555555555555555",d)),c.appendChild(e("ShapeShdwShow",
-2,d)));1==b.style[mxConstants.STYLE_FLIPH]&&c.appendChild(e("FlipX",1,d));1==b.style[mxConstants.STYLE_FLIPV]&&c.appendChild(e("FlipY",1,d));1==b.style[mxConstants.STYLE_ROUNDED]&&c.appendChild(a("Rounding",.1*b.cell.geometry.width,d));(b=b.style[mxConstants.STYLE_LABEL_BACKGROUNDCOLOR])&&c.appendChild(e("TextBkgnd",b,d))}function h(b,c,d,e){var f=d.createElement("Shape");f.setAttribute("ID",b);f.setAttribute("NameU","Shape"+b);f.setAttribute("LineStyle","0");f.setAttribute("FillStyle","0");f.setAttribute("TextStyle",
-"0");b=c.width/2;var g=c.height/2;f.appendChild(a("PinX",c.x+b,d));f.appendChild(a("PinY",e-c.y-g,d));f.appendChild(a("Width",c.width,d));f.appendChild(a("Height",c.height,d));f.appendChild(a("LocPinX",b,d));f.appendChild(a("LocPinY",g,d));return f}function l(a,b){var c=v.ARROWS_MAP[(null==a?"none":a)+"|"+(null==b?"1":b)];return null!=c?c:1}function n(a){return null==a?2:2>=a?0:3>=a?1:5>=a?2:7>=a?3:9>=a?4:22>=a?5:6}function q(b,c,f,h){var m=c.view.getState(b);c=f.createElement("Shape");c.setAttribute("ID",
-b.id);c.setAttribute("NameU","Edge"+b.id);c.setAttribute("LineStyle","0");c.setAttribute("FillStyle","0");c.setAttribute("TextStyle","0");b=m.absolutePoints;var p=m.cellBounds,t=p.width/2,x=p.height/2;c.appendChild(a("PinX",p.x+t,f));c.appendChild(a("PinY",h-p.y-x,f));c.appendChild(a("Width",p.width,f));c.appendChild(a("Height",p.height,f));c.appendChild(a("LocPinX",t,f));c.appendChild(a("LocPinY",x,f));var q=z.state,t=function(a,b){var c=a.x,d=a.y,c=(c-p.x+q.dx)*q.scale,d=((b?0:p.height)-d+p.y-q.dy)*
-q.scale;return{x:c,y:d}},x=t(b[0],!0);c.appendChild(a("BeginX",p.x+x.x,f));c.appendChild(a("BeginY",h-p.y+x.y,f));x=t(b[b.length-1],!0);c.appendChild(a("EndX",p.x+x.x,f));c.appendChild(a("EndY",h-p.y+x.y,f));c.appendChild(e("BegTrigger","2",f));c.appendChild(e("EndTrigger","2",f));c.appendChild(e("ConFixedCode","6",f));c.appendChild(e("LockHeight","1",f));c.appendChild(e("LockCalcWH","1",f));c.appendChild(e("NoAlignBox","1",f));c.appendChild(e("DynFeedback","2",f));c.appendChild(e("GlueType","2",
-f));c.appendChild(e("ObjType","2",f));c.appendChild(e("NoLiveDynamics","1",f));c.appendChild(e("ShapeSplittable","1",f));c.appendChild(e("LayerMember","0",f));g(m,c,f);x=m.style[mxConstants.STYLE_STARTSIZE];h=l(m.style[mxConstants.STYLE_STARTARROW],m.style[mxConstants.STYLE_STARTFILL]);c.appendChild(e("BeginArrow",h,f));c.appendChild(e("BeginArrowSize",n(x),f));x=m.style[mxConstants.STYLE_ENDSIZE];h=l(m.style[mxConstants.STYLE_ENDARROW],m.style[mxConstants.STYLE_ENDFILL]);c.appendChild(e("EndArrow",
-h,f));c.appendChild(e("EndArrowSize",n(x),f));null!=m.text&&m.text.checkBounds()&&(z.save(),m.text.paint(z),z.restore());m=f.createElement("Section");m.setAttribute("N","Geometry");m.setAttribute("IX","0");for(h=0;h<b.length;h++)x=t(b[h]),m.appendChild(d(0==h?"MoveTo":"LineTo",h+1,x.x,x.y,f));m.appendChild(e("NoFill","1",f));m.appendChild(e("NoLine","0",f));c.appendChild(m);return c}function u(a,b,c,d,e){var f=a.geometry;if(null!=f){f.relative&&e&&(f=f.clone(),f.x*=e.width,f.y*=e.height,f.relative=
-0);if(!a.treatAsSingle&&0<a.getChildCount()){d=h(a.id+"10000",f,c,d);d.setAttribute("Type","Group");e=c.createElement("Shapes");z.save();z.translate(-f.x,-f.y);var m=f.clone();m.x=0;m.y=0;a.setGeometry(m);a.treatAsSingle=!0;m=u(a,b,c,f.height,f);a.treatAsSingle=!1;a.setGeometry(f);e.appendChild(m);for(var l=0;l<a.children.length;l++)m=u(a.children[l],b,c,f.height,f),e.appendChild(m);d.appendChild(e);z.restore();return d}return a.vertex?(d=h(a.id,f,c,d),a=b.view.getState(a),g(a,d,c),z.newShape(d,a,
-c),null!=a.text&&a.text.checkBounds()&&(z.save(),a.text.paint(z),z.restore()),null!=a.shape&&a.shape.checkBounds()&&(z.save(),a.shape.paint(z),z.restore()),d.appendChild(z.getShapeGeo()),z.endShape(),d.setAttribute("Type",z.getShapeType()),d):q(a,b,c,d)}return null}function y(a,b){var c=mxUtils.createXmlDocument(),d=c.createElement("PageContents");d.setAttribute("xmlns",v.XMLNS);d.setAttribute("xmlns:r",v.XMLNS_R);d.setAttribute("xml:space",v.XML_SPACE);var e=c.createElement("Shapes");d.appendChild(e);
-var f=a.model,g=a.view.translate,h=a.view.scale,l=a.getGraphBounds(),n=0,t=0;if(l.x/h<g.x||l.y/h<g.y)n=Math.ceil((g.x-l.x/h)/a.pageFormat.width)*a.pageFormat.width,t=Math.ceil((g.y-l.y/h)/a.pageFormat.height)*a.pageFormat.height;z.save();z.translate(-g.x+n,-g.y+t);z.scale(1/h);z.newPage();var h=a.getDefaultParent(),q;for(q in f.cells)g=f.cells[q],g.parent==h&&(g=u(g,a,c,b.pageHeight),null!=g&&e.appendChild(g));e=c.createElement("Connects");d.appendChild(e);for(q in f.cells)g=f.cells[q],g.edge&&(g.source&&
-(h=c.createElement("Connect"),h.setAttribute("FromSheet",g.id),h.setAttribute("FromCell","BeginX"),h.setAttribute("ToSheet",g.source.id),e.appendChild(h)),g.target&&(h=c.createElement("Connect"),h.setAttribute("FromSheet",g.id),h.setAttribute("FromCell","EndX"),h.setAttribute("ToSheet",g.target.id),e.appendChild(h)));c.appendChild(d);z.restore();return c}function F(a,b,c,d){a.file(b,(d?"":'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>')+mxUtils.getXml(c))}function D(b,c,d){var f=mxUtils.createXmlDocument(),
-g=mxUtils.createXmlDocument(),h=f.createElement("Pages");h.setAttribute("xmlns",v.XMLNS);h.setAttribute("xmlns:r",v.XMLNS_R);h.setAttribute("xml:space",v.XML_SPACE);var l=g.createElement("Relationships");l.setAttribute("xmlns",v.RELS_XMLNS);var m=1,n;for(n in c){var t="page"+m+".xml",q=f.createElement("Page");q.setAttribute("ID",m-1);q.setAttribute("NameU",n);q.setAttribute("Name",n);var u=f.createElement("PageSheet"),w=d[n];u.appendChild(a("PageWidth",w.pageWidth,f));u.appendChild(a("PageHeight",
-w.pageHeight,f));u.appendChild(e("PageScale",w.pageScale,f));u.appendChild(e("DrawingScale",1,f));w=f.createElement("Rel");w.setAttribute("r:id","rId"+m);q.appendChild(u);q.appendChild(w);h.appendChild(q);q=g.createElement("Relationship");q.setAttribute("Id","rId"+m);q.setAttribute("Type",v.PAGES_TYPE);q.setAttribute("Target",t);l.appendChild(q);F(b,v.VISIO_PAGES+t,c[n]);m++}f.appendChild(h);g.appendChild(l);F(b,v.VISIO_PAGES+"pages.xml",f);F(b,v.VISIO_PAGES+"_rels/pages.xml.rels",g)}function H(a,
-b){var c=v.VISIO_PAGES_RELS+"page"+b+".xml.rels",d=mxUtils.createXmlDocument(),e=d.createElement("Relationships");e.setAttribute("xmlns",v.RELS_XMLNS);var f=z.images;if(0<f.length)for(var g=0;g<f.length;g++){var h=d.createElement("Relationship");h.setAttribute("Type",v.XMLNS_R+"/image");h.setAttribute("Id","rId"+(g+1));h.setAttribute("Target","../media/"+f[g]);e.appendChild(h)}d.appendChild(e);F(a,c,d)}var v=this;b=b||"js/diagramly/vsdx/resources";var z=new mxVsdxCanvas2D;this.exportCurrentDiagrams=
-function(){try{var a=new JSZip;z.init(a);pages={};modelsAttr={};var b=null!=w.pages?w.pages.length:1;if(null!=w.pages){for(var d=w.currentPage,e=0;e<w.pages.length;e++){var g=w.pages[e];w.selectPage(g);var h=g.getName(),l=w.editor.graph,n=c(l);pages[h]=y(l,n);H(a,e+1);modelsAttr[h]=n}w.selectPage(d)}else l=w.editor.graph,n=c(l),h="Page1",pages[h]=y(l,n),H(a,1),modelsAttr[h]=n;f(a,b,function(){D(a,pages,modelsAttr);var b=function(){0<z.filesLoading?setTimeout(b,200*z.filesLoading):a.generateAsync({type:"blob"}).then(function(a){var b=
+2,d)));1==b.style[mxConstants.STYLE_FLIPH]&&c.appendChild(e("FlipX",1,d));1==b.style[mxConstants.STYLE_FLIPV]&&c.appendChild(e("FlipY",1,d));1==b.style[mxConstants.STYLE_ROUNDED]&&c.appendChild(a("Rounding",.1*b.cell.geometry.width,d));(b=b.style[mxConstants.STYLE_LABEL_BACKGROUNDCOLOR])&&c.appendChild(e("TextBkgnd",b,d))}function l(b,c,d,e){var f=d.createElement("Shape");f.setAttribute("ID",b);f.setAttribute("NameU","Shape"+b);f.setAttribute("LineStyle","0");f.setAttribute("FillStyle","0");f.setAttribute("TextStyle",
+"0");b=c.width/2;var g=c.height/2;f.appendChild(a("PinX",c.x+b,d));f.appendChild(a("PinY",e-c.y-g,d));f.appendChild(a("Width",c.width,d));f.appendChild(a("Height",c.height,d));f.appendChild(a("LocPinX",b,d));f.appendChild(a("LocPinY",g,d));return f}function h(a,b){var c=x.ARROWS_MAP[(null==a?"none":a)+"|"+(null==b?"1":b)];return null!=c?c:1}function n(a){return null==a?2:2>=a?0:3>=a?1:5>=a?2:7>=a?3:9>=a?4:22>=a?5:6}function q(b,d,f,l){var m=d.view.getState(b);d=f.createElement("Shape");d.setAttribute("ID",
+b.id);d.setAttribute("NameU","Edge"+b.id);d.setAttribute("LineStyle","0");d.setAttribute("FillStyle","0");d.setAttribute("TextStyle","0");var p=y.state;b=m.absolutePoints;var q=m.cellBounds,v=q.width/2,t=q.height/2;d.appendChild(a("PinX",q.x+v,f));d.appendChild(a("PinY",l-q.y-t,f));d.appendChild(a("Width",q.width,f));d.appendChild(a("Height",q.height,f));d.appendChild(a("LocPinX",v,f));d.appendChild(a("LocPinY",t,f));y.newEdge(d,m,f);v=function(a,b){var c=a.x,d=a.y,c=c*p.scale-q.x+p.dx,d=(b?0:q.height)-
+d*p.scale+q.y-p.dy;return{x:c,y:d}};t=v(b[0],!0);d.appendChild(a("BeginX",q.x+t.x,f));d.appendChild(a("BeginY",l-q.y+t.y,f));t=v(b[b.length-1],!0);d.appendChild(a("EndX",q.x+t.x,f));d.appendChild(a("EndY",l-q.y+t.y,f));d.appendChild(e("BegTrigger","2",f));d.appendChild(e("EndTrigger","2",f));d.appendChild(e("ConFixedCode","6",f));d.appendChild(e("LockHeight","1",f));d.appendChild(e("LockCalcWH","1",f));d.appendChild(e("NoAlignBox","1",f));d.appendChild(e("DynFeedback","2",f));d.appendChild(e("GlueType",
+"2",f));d.appendChild(e("ObjType","2",f));d.appendChild(e("NoLiveDynamics","1",f));d.appendChild(e("ShapeSplittable","1",f));d.appendChild(e("LayerMember","0",f));g(m,d,f);t=m.style[mxConstants.STYLE_STARTSIZE];l=h(m.style[mxConstants.STYLE_STARTARROW],m.style[mxConstants.STYLE_STARTFILL]);d.appendChild(e("BeginArrow",l,f));d.appendChild(e("BeginArrowSize",n(t),f));t=m.style[mxConstants.STYLE_ENDSIZE];l=h(m.style[mxConstants.STYLE_ENDARROW],m.style[mxConstants.STYLE_ENDFILL]);d.appendChild(e("EndArrow",
+l,f));d.appendChild(e("EndArrowSize",n(t),f));null!=m.text&&m.text.checkBounds()&&(y.save(),m.text.paint(y),y.restore());m=f.createElement("Section");m.setAttribute("N","Geometry");m.setAttribute("IX","0");for(l=0;l<b.length;l++)t=v(b[l]),m.appendChild(c(0==l?"MoveTo":"LineTo",l+1,t.x,t.y,f));m.appendChild(e("NoFill","1",f));m.appendChild(e("NoLine","0",f));d.appendChild(m);return d}function t(a,b,c,d,e){var f=a.geometry;if(null!=f){f.relative&&e&&(f=f.clone(),f.x*=e.width,f.y*=e.height,f.relative=
+0);if(!a.treatAsSingle&&0<a.getChildCount()){d=l(a.id+"10000",f,c,d);d.setAttribute("Type","Group");e=c.createElement("Shapes");y.save();y.translate(-f.x,-f.y);var h=f.clone();h.x=0;h.y=0;a.setGeometry(h);a.treatAsSingle=!0;h=t(a,b,c,f.height,f);a.treatAsSingle=!1;a.setGeometry(f);e.appendChild(h);for(var m=0;m<a.children.length;m++)h=t(a.children[m],b,c,f.height,f),e.appendChild(h);d.appendChild(e);y.restore();return d}return a.vertex?(d=l(a.id,f,c,d),a=b.view.getState(a),g(a,d,c),y.newShape(d,a,
+c),null!=a.text&&a.text.checkBounds()&&(y.save(),a.text.paint(y),y.restore()),null!=a.shape&&a.shape.checkBounds()&&(y.save(),a.shape.paint(y),y.restore()),d.appendChild(y.getShapeGeo()),y.endShape(),d.setAttribute("Type",y.getShapeType()),d):q(a,b,c,d)}return null}function A(a,b){var c=mxUtils.createXmlDocument(),d=c.createElement("PageContents");d.setAttribute("xmlns",x.XMLNS);d.setAttribute("xmlns:r",x.XMLNS_R);d.setAttribute("xml:space",x.XML_SPACE);var e=c.createElement("Shapes");d.appendChild(e);
+var f=a.model,g=a.view.translate,h=a.view.scale,l=a.getGraphBounds(),n=0,p=0;if(l.x/h<g.x||l.y/h<g.y)n=Math.ceil((g.x-l.x/h)/a.pageFormat.width)*a.pageFormat.width,p=Math.ceil((g.y-l.y/h)/a.pageFormat.height)*a.pageFormat.height;y.save();y.translate(-g.x+n,-g.y+p);y.scale(1/h);y.newPage();var h=a.getDefaultParent(),q;for(q in f.cells)g=f.cells[q],g.parent==h&&(g=t(g,a,c,b.pageHeight),null!=g&&e.appendChild(g));e=c.createElement("Connects");d.appendChild(e);for(q in f.cells)g=f.cells[q],g.edge&&(g.source&&
+(h=c.createElement("Connect"),h.setAttribute("FromSheet",g.id),h.setAttribute("FromCell","BeginX"),h.setAttribute("ToSheet",g.source.id),e.appendChild(h)),g.target&&(h=c.createElement("Connect"),h.setAttribute("FromSheet",g.id),h.setAttribute("FromCell","EndX"),h.setAttribute("ToSheet",g.target.id),e.appendChild(h)));c.appendChild(d);y.restore();return c}function B(a,b,c,d){a.file(b,(d?"":'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>')+mxUtils.getXml(c))}function G(b,c,d){var f=mxUtils.createXmlDocument(),
+g=mxUtils.createXmlDocument(),h=f.createElement("Pages");h.setAttribute("xmlns",x.XMLNS);h.setAttribute("xmlns:r",x.XMLNS_R);h.setAttribute("xml:space",x.XML_SPACE);var l=g.createElement("Relationships");l.setAttribute("xmlns",x.RELS_XMLNS);var m=1,n;for(n in c){var q="page"+m+".xml",p=f.createElement("Page");p.setAttribute("ID",m-1);p.setAttribute("NameU",n);p.setAttribute("Name",n);var t=f.createElement("PageSheet"),w=d[n];t.appendChild(a("PageWidth",w.pageWidth,f));t.appendChild(a("PageHeight",
+w.pageHeight,f));t.appendChild(e("PageScale",w.pageScale,f));t.appendChild(e("DrawingScale",1,f));w=f.createElement("Rel");w.setAttribute("r:id","rId"+m);p.appendChild(t);p.appendChild(w);h.appendChild(p);p=g.createElement("Relationship");p.setAttribute("Id","rId"+m);p.setAttribute("Type",x.PAGES_TYPE);p.setAttribute("Target",q);l.appendChild(p);B(b,x.VISIO_PAGES+q,c[n]);m++}f.appendChild(h);g.appendChild(l);B(b,x.VISIO_PAGES+"pages.xml",f);B(b,x.VISIO_PAGES+"_rels/pages.xml.rels",g)}function z(a,
+b){var c=x.VISIO_PAGES_RELS+"page"+b+".xml.rels",d=mxUtils.createXmlDocument(),e=d.createElement("Relationships");e.setAttribute("xmlns",x.RELS_XMLNS);var f=y.images;if(0<f.length)for(var g=0;g<f.length;g++){var h=d.createElement("Relationship");h.setAttribute("Type",x.XMLNS_R+"/image");h.setAttribute("Id","rId"+(g+1));h.setAttribute("Target","../media/"+f[g]);e.appendChild(h)}d.appendChild(e);B(a,c,d)}var x=this;b=b||"js/diagramly/vsdx/resources";var y=new mxVsdxCanvas2D;this.exportCurrentDiagrams=
+function(){try{var a=new JSZip;y.init(a);pages={};modelsAttr={};var b=null!=w.pages?w.pages.length:1;if(null!=w.pages){for(var c=w.currentPage,e=0;e<w.pages.length;e++){var g=w.pages[e];w.selectPage(g);var h=g.getName(),l=w.editor.graph,n=d(l);pages[h]=A(l,n);z(a,e+1);modelsAttr[h]=n}w.selectPage(c)}else l=w.editor.graph,n=d(l),h="Page1",pages[h]=A(l,n),z(a,1),modelsAttr[h]=n;f(a,b,function(){G(a,pages,modelsAttr);var b=function(){0<y.filesLoading?setTimeout(b,200*y.filesLoading):a.generateAsync({type:"blob"}).then(function(a){var b=
 w.getCurrentFile(),b=null!=b&&null!=b.getTitle()?b.getTitle():w.defaultFilename;w.saveData(b+".vsdx","vsdx",a,"application/vnd.visio2013")})};b()});return!0}catch(S){return console.log(S),!1}}}VsdxExport.prototype.CONVERSION_FACTOR=101.6;VsdxExport.prototype.PAGES_TYPE="http://schemas.microsoft.com/visio/2010/relationships/page";VsdxExport.prototype.RELS_XMLNS="http://schemas.openxmlformats.org/package/2006/relationships";VsdxExport.prototype.XML_SPACE="preserve";VsdxExport.prototype.XMLNS_R="http://schemas.openxmlformats.org/officeDocument/2006/relationships";
 VsdxExport.prototype.XMLNS="http://schemas.microsoft.com/office/visio/2012/main";VsdxExport.prototype.VISIO_PAGES="visio/pages/";VsdxExport.prototype.PREFEX="com/mxgraph/io/vsdx/resources/export/";VsdxExport.prototype.VSDX_ENC="ISO-8859-1";VsdxExport.prototype.PART_NAME="PartName";VsdxExport.prototype.CONTENT_TYPES_XML="[Content_Types].xml";VsdxExport.prototype.VISIO_PAGES_RELS="visio/pages/_rels/";
-VsdxExport.prototype.ARROWS_MAP={"none|1":0,"none|0":0,"open|1":1,"open|0":1,"block|0":4,"block|1":14,"classic|1":5,"classic|0":17,"oval|1":10,"oval|0":20,"diamond|1":11,"diamond|0":22,"blockThin|1":2,"blockThin|0":2,"dash|1":23,"dash|0":23,"ERone|1":24,"ERone|0":24,"ERmandOne|1":25,"ERmandOne|0":25,"ERmany|1":27,"ERmany|0":27,"ERoneToMany|1":28,"ERoneToMany|0":28,"ERzeroToMany|1":29,"ERzeroToMany|0":29,"ERzeroToOne|1":30,"ERzeroToOne|0":30,"openAsync|1":9,"openAsync|0":9};function mxVsdxCanvas2D(w){mxAbstractCanvas2D.call(this)}mxUtils.extend(mxVsdxCanvas2D,mxAbstractCanvas2D);mxVsdxCanvas2D.prototype.textEnabled=!0;mxVsdxCanvas2D.prototype.init=function(w){this.filesLoading=0;this.zip=w};
+VsdxExport.prototype.ARROWS_MAP={"none|1":0,"none|0":0,"open|1":1,"open|0":1,"block|1":4,"block|0":14,"classic|1":5,"classic|0":17,"oval|1":10,"oval|0":20,"diamond|1":11,"diamond|0":22,"blockThin|1":2,"blockThin|0":15,"dash|1":23,"dash|0":23,"ERone|1":24,"ERone|0":24,"ERmandOne|1":25,"ERmandOne|0":25,"ERmany|1":27,"ERmany|0":27,"ERoneToMany|1":28,"ERoneToMany|0":28,"ERzeroToMany|1":29,"ERzeroToMany|0":29,"ERzeroToOne|1":30,"ERzeroToOne|0":30,"openAsync|1":9,"openAsync|0":9};function mxVsdxCanvas2D(w){mxAbstractCanvas2D.call(this)}mxUtils.extend(mxVsdxCanvas2D,mxAbstractCanvas2D);mxVsdxCanvas2D.prototype.textEnabled=!0;mxVsdxCanvas2D.prototype.init=function(w){this.filesLoading=0;this.zip=w};
 mxVsdxCanvas2D.prototype.createGeoSec=function(){null!=this.geoSec&&this.shape.appendChild(this.geoSec);var w=this.xmlDoc.createElement("Section");w.setAttribute("N","Geometry");w.setAttribute("IX",this.geoIndex++);this.geoSec=w;this.geoStepIndex=1;this.lastMoveToY=this.lastMoveToX=this.lastY=this.lastX=0};mxVsdxCanvas2D.prototype.newShape=function(w,b,f){this.geoIndex=0;this.shape=w;this.cellState=b;this.xmGeo=b.cell.geometry;this.xmlDoc=f;this.shapeImg=this.geoSec=null;this.shapeType="Shape";this.createGeoSec()};
-mxVsdxCanvas2D.prototype.endShape=function(){null!=this.shapeImg&&this.addForeignData(this.shapeImg.type,this.shapeImg.id)};mxVsdxCanvas2D.prototype.newPage=function(){this.images=[]};mxVsdxCanvas2D.prototype.getShapeType=function(){return this.shapeType};mxVsdxCanvas2D.prototype.getShapeGeo=function(){return this.geoSec};mxVsdxCanvas2D.prototype.createCellElemScaled=function(w,b,f){return this.createCellElem(w,b/VsdxExport.prototype.CONVERSION_FACTOR,f)};
-mxVsdxCanvas2D.prototype.createCellElem=function(w,b,f){var c=this.xmlDoc.createElement("Cell");c.setAttribute("N",w);c.setAttribute("V",b);f&&c.setAttribute("F",f);return c};
-mxVsdxCanvas2D.prototype.createRowRel=function(w,b,f,c,a,e,d,g){var h=this.xmlDoc.createElement("Row");h.setAttribute("T",w);h.setAttribute("IX",b);h.appendChild(this.createCellElem("X",f));h.appendChild(this.createCellElem("Y",c));null!=a&&h.appendChild(this.createCellElem("A",a));null!=e&&h.appendChild(this.createCellElem("B",e));null!=d&&h.appendChild(this.createCellElem("C",d));null!=g&&h.appendChild(this.createCellElem("D",g));return h};
+mxVsdxCanvas2D.prototype.newEdge=function(w,b,f){this.shape=w;this.cellState=b;this.xmGeo=b.cellBounds;this.xmlDoc=f};mxVsdxCanvas2D.prototype.endShape=function(){null!=this.shapeImg&&this.addForeignData(this.shapeImg.type,this.shapeImg.id)};mxVsdxCanvas2D.prototype.newPage=function(){this.images=[]};mxVsdxCanvas2D.prototype.getShapeType=function(){return this.shapeType};mxVsdxCanvas2D.prototype.getShapeGeo=function(){return this.geoSec};
+mxVsdxCanvas2D.prototype.createCellElemScaled=function(w,b,f){return this.createCellElem(w,b/VsdxExport.prototype.CONVERSION_FACTOR,f)};mxVsdxCanvas2D.prototype.createCellElem=function(w,b,f){var d=this.xmlDoc.createElement("Cell");d.setAttribute("N",w);d.setAttribute("V",b);f&&d.setAttribute("F",f);return d};
+mxVsdxCanvas2D.prototype.createRowRel=function(w,b,f,d,a,e,c,g){var l=this.xmlDoc.createElement("Row");l.setAttribute("T",w);l.setAttribute("IX",b);l.appendChild(this.createCellElem("X",f));l.appendChild(this.createCellElem("Y",d));null!=a&&l.appendChild(this.createCellElem("A",a));null!=e&&l.appendChild(this.createCellElem("B",e));null!=c&&l.appendChild(this.createCellElem("C",c));null!=g&&l.appendChild(this.createCellElem("D",g));return l};
 mxVsdxCanvas2D.prototype.begin=function(){1<this.geoStepIndex&&this.createGeoSec()};
-mxVsdxCanvas2D.prototype.rect=function(w,b,f,c){1<this.geoStepIndex&&this.createGeoSec();var a=this.state;f*=a.scale;c*=a.scale;var e=this.xmGeo;w=(w-e.x+a.dx)*a.scale/f;b=(e.height-b+e.y-a.dy)*a.scale/c;this.geoSec.appendChild(this.createRowRel("RelMoveTo",this.geoStepIndex++,w,b));this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w+1,b));this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w+1,b-1));this.geoSec.appendChild(this.createRowRel("RelLineTo",
-this.geoStepIndex++,w,b-1));this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w,b))};mxVsdxCanvas2D.prototype.roundrect=function(w,b,f,c,a,e){this.rect(w,b,f,c);this.shape.appendChild(this.createCellElemScaled("Rounding",a))};
-mxVsdxCanvas2D.prototype.ellipse=function(w,b,f,c){1<this.geoStepIndex&&this.createGeoSec();var a=this.state;f*=a.scale;c*=a.scale;var e=this.xmGeo,d=e.height*a.scale,g=e.width*a.scale;w=(w-e.x+a.dx)*a.scale;b=d+(-b+e.y-a.dy)*a.scale;a=c/d;e=f/g;this.geoSec.appendChild(this.createRowRel("RelMoveTo",this.geoStepIndex++,w/g,b/d-.5*a));w=this.createRowRel("RelEllipticalArcTo",this.geoStepIndex++,w/g,b/d-.5001*a,.5*e+w/g,b/d-a,0);w.appendChild(this.createCellElem("D",f/c,"Width/Height*"+e/a));this.geoSec.appendChild(w)};
-mxVsdxCanvas2D.prototype.moveTo=function(w,b){this.lastMoveToX=w;this.lastMoveToY=b;this.lastX=w;this.lastY=b;var f=this.xmGeo,c=this.state;w=(w-f.x+c.dx)*c.scale;b=(f.height-b+f.y-c.dy)*c.scale;var a=f.height*c.scale,f=f.width*c.scale;this.geoSec.appendChild(this.createRowRel("RelMoveTo",this.geoStepIndex++,w/f,b/a))};
-mxVsdxCanvas2D.prototype.lineTo=function(w,b){this.lastX=w;this.lastY=b;var f=this.xmGeo,c=this.state;w=(w-f.x+c.dx)*c.scale;b=(f.height-b+f.y-c.dy)*c.scale;var a=f.height*c.scale,f=f.width*c.scale;this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w/f,b/a))};
-mxVsdxCanvas2D.prototype.quadTo=function(w,b,f,c){this.lastX=f;this.lastY=c;var a=this.state,e=this.xmGeo,d=e.height*a.scale,g=e.width*a.scale;w=(w-e.x+a.dx)*a.scale;b=(e.height-b+e.y-a.dy)*a.scale;f=(f-e.x+a.dx)*a.scale;c=(e.height-c+e.y-a.dy)*a.scale;this.geoSec.appendChild(this.createRowRel("RelQuadBezTo",this.geoStepIndex++,f/g,c/d,w/g,b/d))};
-mxVsdxCanvas2D.prototype.curveTo=function(w,b,f,c,a,e){this.lastX=a;this.lastY=e;var d=this.state,g=this.xmGeo,h=g.height*d.scale,l=g.width*d.scale;w=(w-g.x+d.dx)*d.scale;b=(g.height-b+g.y-d.dy)*d.scale;f=(f-g.x+d.dx)*d.scale;c=(g.height-c+g.y-d.dy)*d.scale;a=(a-g.x+d.dx)*d.scale;e=(g.height-e+g.y-d.dy)*d.scale;this.geoSec.appendChild(this.createRowRel("RelCubBezTo",this.geoStepIndex++,a/l,e/h,w/l,b/h,f/l,c/h))};
-mxVsdxCanvas2D.prototype.close=function(){this.lastMoveToX==this.lastX&&this.lastMoveToY==this.lastY||this.lineTo(this.lastMoveToX,this.lastMoveToY)};mxVsdxCanvas2D.prototype.addForeignData=function(w,b){var f=this.xmlDoc.createElement("ForeignData");f.setAttribute("ForeignType","Bitmap");w=w.toUpperCase();"BMP"!=w&&f.setAttribute("CompressionType",w);var c=this.xmlDoc.createElement("Rel");c.setAttribute("r:id","rId"+b);f.appendChild(c);this.shape.appendChild(f);this.shapeType="Foreign"};
-mxVsdxCanvas2D.prototype.image=function(w,b,f,c,a,e,d,g){var h="image"+(this.images.length+1)+".",l;if(0==a.indexOf("data:"))l=a.indexOf("base64,"),e=a.substring(l+7),l=a.substring(11,l-1),h+=l,this.zip.file("visio/media/"+h,e,{base64:!0});else if(window.XMLHttpRequest){a=this.converter.convert(a);this.filesLoading++;var n=this;l=a.lastIndexOf(".");l=a.substring(l+1);h+=l;e=new XMLHttpRequest;e.open("GET",a,!0);e.responseType="arraybuffer";e.onreadystatechange=function(a){4==this.readyState&&200==
-this.status&&(n.zip.file("visio/media/"+h,this.response),n.filesLoading--)};e.send()}this.images.push(h);this.shapeImg={type:l,id:this.images.length};a=this.state;f*=a.scale;c*=a.scale;l=this.xmGeo;w=(w-l.x+a.dx)*a.scale;b=(l.height-b+l.y-a.dy)*a.scale;this.shape.appendChild(this.createCellElemScaled("ImgOffsetX",w));this.shape.appendChild(this.createCellElemScaled("ImgOffsetY",b-c));this.shape.appendChild(this.createCellElemScaled("ImgWidth",f));this.shape.appendChild(this.createCellElemScaled("ImgHeight",
-c))};
-mxVsdxCanvas2D.prototype.text=function(w,b,f,c,a,e,d,g,h,l,n,q,u){if(this.textEnabled&&null!=a){mxUtils.isNode(a)&&(a=mxUtils.getOuterHtml(a));"html"==h&&("0"!=mxUtils.getValue(this.cellState.style,"nl2Br","1")&&(a=a.replace(/\n/g,"").replace(/<br\s*.?>/g,"\n")),null==this.html2txtDiv&&(this.html2txtDiv=document.createElement("div")),this.html2txtDiv.innerHTML=a,a=mxUtils.extractTextWithWhitespace(this.html2txtDiv.childNodes));l=this.state;n=this.xmGeo;u=mxUtils.getSizeForString(a,null,null,0<f?f:
-null);h=g=0;switch(e){case "right":g=u.width/4;break;case "left":g=-u.width/4}switch(d){case "top":h=u.height/2;break;case "bottom":h=-u.height/2}c=0<c?c:u.height;f=0<f?f:u.width;f*=l.scale;c*=l.scale;w=(w-n.x+l.dx)*l.scale;b=(n.height-b+n.y-l.dy)*l.scale;e=f/2;d=c/2;this.shape.appendChild(this.createCellElemScaled("TxtPinX",w));this.shape.appendChild(this.createCellElemScaled("TxtPinY",b));this.shape.appendChild(this.createCellElemScaled("TxtWidth",f));this.shape.appendChild(this.createCellElemScaled("TxtHeight",
-c));this.shape.appendChild(this.createCellElemScaled("TxtLocPinX",e+g));this.shape.appendChild(this.createCellElemScaled("TxtLocPinY",d+h));0!=q&&this.shape.appendChild(this.createCellElemScaled("TxtAngle",(360-q)*Math.PI/180));w=this.xmlDoc.createElement("Text");w.textContent=a;this.shape.appendChild(w)}};
-mxVsdxCanvas2D.prototype.rotate=function(w,b,f,c,a){0!=w&&(b=this.state,c+=b.dx,a+=b.dy,c*=b.scale,a*=b.scale,this.shape.appendChild(this.createCellElem("Angle",(360-w)*Math.PI/180)),b.rotation+=w,b.rotationCx=c,b.rotationCy=a)};mxVsdxCanvas2D.prototype.stroke=function(){this.geoSec.appendChild(this.createCellElem("NoFill","1"));this.geoSec.appendChild(this.createCellElem("NoLine","0"))};
-mxVsdxCanvas2D.prototype.fill=function(){this.geoSec.appendChild(this.createCellElem("NoFill","0"));this.geoSec.appendChild(this.createCellElem("NoLine","1"))};mxVsdxCanvas2D.prototype.fillAndStroke=function(){this.geoSec.appendChild(this.createCellElem("NoFill","0"));this.geoSec.appendChild(this.createCellElem("NoLine","0"))};
\ No newline at end of file
+mxVsdxCanvas2D.prototype.rect=function(w,b,f,d){1<this.geoStepIndex&&this.createGeoSec();var a=this.state;f*=a.scale;d*=a.scale;var e=this.xmGeo;w=(w-e.x+a.dx)*a.scale/f;b=(e.height-b+e.y-a.dy)*a.scale/d;this.geoSec.appendChild(this.createRowRel("RelMoveTo",this.geoStepIndex++,w,b));this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w+1,b));this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w+1,b-1));this.geoSec.appendChild(this.createRowRel("RelLineTo",
+this.geoStepIndex++,w,b-1));this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w,b))};mxVsdxCanvas2D.prototype.roundrect=function(w,b,f,d,a,e){this.rect(w,b,f,d);this.shape.appendChild(this.createCellElemScaled("Rounding",a))};
+mxVsdxCanvas2D.prototype.ellipse=function(w,b,f,d){1<this.geoStepIndex&&this.createGeoSec();var a=this.state;f*=a.scale;d*=a.scale;var e=this.xmGeo,c=e.height*a.scale,g=e.width*a.scale;w=(w-e.x+a.dx)*a.scale;b=c+(-b+e.y-a.dy)*a.scale;a=d/c;e=f/g;this.geoSec.appendChild(this.createRowRel("RelMoveTo",this.geoStepIndex++,w/g,b/c-.5*a));w=this.createRowRel("RelEllipticalArcTo",this.geoStepIndex++,w/g,b/c-.5001*a,.5*e+w/g,b/c-a,0);w.appendChild(this.createCellElem("D",f/d,"Width/Height*"+e/a));this.geoSec.appendChild(w)};
+mxVsdxCanvas2D.prototype.moveTo=function(w,b){1<this.geoStepIndex&&this.createGeoSec();this.lastMoveToX=w;this.lastMoveToY=b;this.lastX=w;this.lastY=b;var f=this.xmGeo,d=this.state;w=(w-f.x+d.dx)*d.scale;b=(f.height-b+f.y-d.dy)*d.scale;var a=f.height*d.scale,f=f.width*d.scale;this.geoSec.appendChild(this.createRowRel("RelMoveTo",this.geoStepIndex++,w/f,b/a))};
+mxVsdxCanvas2D.prototype.lineTo=function(w,b){this.lastX=w;this.lastY=b;var f=this.xmGeo,d=this.state;w=(w-f.x+d.dx)*d.scale;b=(f.height-b+f.y-d.dy)*d.scale;var a=f.height*d.scale,f=f.width*d.scale;this.geoSec.appendChild(this.createRowRel("RelLineTo",this.geoStepIndex++,w/f,b/a))};
+mxVsdxCanvas2D.prototype.quadTo=function(w,b,f,d){this.lastX=f;this.lastY=d;var a=this.state,e=this.xmGeo,c=e.height*a.scale,g=e.width*a.scale;w=(w-e.x+a.dx)*a.scale;b=(e.height-b+e.y-a.dy)*a.scale;f=(f-e.x+a.dx)*a.scale;d=(e.height-d+e.y-a.dy)*a.scale;this.geoSec.appendChild(this.createRowRel("RelQuadBezTo",this.geoStepIndex++,f/g,d/c,w/g,b/c))};
+mxVsdxCanvas2D.prototype.curveTo=function(w,b,f,d,a,e){this.lastX=a;this.lastY=e;var c=this.state,g=this.xmGeo,l=g.height*c.scale,h=g.width*c.scale;w=(w-g.x+c.dx)*c.scale;b=(g.height-b+g.y-c.dy)*c.scale;f=(f-g.x+c.dx)*c.scale;d=(g.height-d+g.y-c.dy)*c.scale;a=(a-g.x+c.dx)*c.scale;e=(g.height-e+g.y-c.dy)*c.scale;this.geoSec.appendChild(this.createRowRel("RelCubBezTo",this.geoStepIndex++,a/h,e/l,w/h,b/l,f/h,d/l))};
+mxVsdxCanvas2D.prototype.close=function(){this.lastMoveToX==this.lastX&&this.lastMoveToY==this.lastY||this.lineTo(this.lastMoveToX,this.lastMoveToY)};mxVsdxCanvas2D.prototype.addForeignData=function(w,b){var f=this.xmlDoc.createElement("ForeignData");f.setAttribute("ForeignType","Bitmap");w=w.toUpperCase();"BMP"!=w&&f.setAttribute("CompressionType",w);var d=this.xmlDoc.createElement("Rel");d.setAttribute("r:id","rId"+b);f.appendChild(d);this.shape.appendChild(f);this.shapeType="Foreign"};
+mxVsdxCanvas2D.prototype.image=function(w,b,f,d,a,e,c,g){var l="image"+(this.images.length+1)+".",h;if(0==a.indexOf("data:"))h=a.indexOf("base64,"),e=a.substring(h+7),h=a.substring(11,h-1),l+=h,this.zip.file("visio/media/"+l,e,{base64:!0});else if(window.XMLHttpRequest){a=this.converter.convert(a);this.filesLoading++;var n=this;h=a.lastIndexOf(".");h=a.substring(h+1);l+=h;e=new XMLHttpRequest;e.open("GET",a,!0);e.responseType="arraybuffer";e.onreadystatechange=function(a){4==this.readyState&&200==
+this.status&&(n.zip.file("visio/media/"+l,this.response),n.filesLoading--)};e.send()}this.images.push(l);this.shapeImg={type:h,id:this.images.length};a=this.state;f*=a.scale;d*=a.scale;h=this.xmGeo;w=(w-h.x+a.dx)*a.scale;b=(h.height-b+h.y-a.dy)*a.scale;this.shape.appendChild(this.createCellElemScaled("ImgOffsetX",w));this.shape.appendChild(this.createCellElemScaled("ImgOffsetY",b-d));this.shape.appendChild(this.createCellElemScaled("ImgWidth",f));this.shape.appendChild(this.createCellElemScaled("ImgHeight",
+d))};
+mxVsdxCanvas2D.prototype.text=function(w,b,f,d,a,e,c,g,l,h,n,q,t){if(this.textEnabled&&null!=a){mxUtils.isNode(a)&&(a=mxUtils.getOuterHtml(a));"html"==l&&("0"!=mxUtils.getValue(this.cellState.style,"nl2Br","1")&&(a=a.replace(/\n/g,"").replace(/<br\s*.?>/g,"\n")),null==this.html2txtDiv&&(this.html2txtDiv=document.createElement("div")),this.html2txtDiv.innerHTML=a,a=mxUtils.extractTextWithWhitespace(this.html2txtDiv.childNodes));t=this.state;var A=this.xmGeo;g=this.cellState.style.fontSize;l=this.cellState.style.fontFamily;var B=
+mxUtils.getSizeForString(a,g,l);n=h=0;switch(e){case "right":h=B.width/2;break;case "left":h=-B.width/2}switch(c){case "top":n=B.height/2;break;case "bottom":n=-B.height/2}f*=t.scale;d*=t.scale;d=Math.max(d,B.height);f=Math.max(f,B.width);w=(w-A.x+t.dx)*t.scale;b=(A.height-b+A.y-t.dy)*t.scale;e=f/2;c=d/2;this.shape.appendChild(this.createCellElemScaled("TxtPinX",w));this.shape.appendChild(this.createCellElemScaled("TxtPinY",b));this.shape.appendChild(this.createCellElemScaled("TxtWidth",f));this.shape.appendChild(this.createCellElemScaled("TxtHeight",
+d));this.shape.appendChild(this.createCellElemScaled("TxtLocPinX",e+h));this.shape.appendChild(this.createCellElemScaled("TxtLocPinY",c+n));0!=q&&this.shape.appendChild(this.createCellElemScaled("TxtAngle",(360-q)*Math.PI/180));w=this.xmlDoc.createElement("Section");w.setAttribute("N","Character");b=this.xmlDoc.createElement("Row");b.setAttribute("IX",0);(f=this.cellState.style.fontColor)&&b.appendChild(this.createCellElem("Color",f));g&&b.appendChild(this.createCellElemScaled("Size",.97*g));l&&b.appendChild(this.createCellElem("Font",
+l));w.appendChild(b);this.shape.appendChild(w);w=this.xmlDoc.createElement("Text");b=this.xmlDoc.createElement("cp");b.setAttribute("IX",0);w.appendChild(b);w.textContent=a;this.shape.appendChild(w)}};mxVsdxCanvas2D.prototype.rotate=function(w,b,f,d,a){0!=w&&(b=this.state,d+=b.dx,a+=b.dy,d*=b.scale,a*=b.scale,this.shape.appendChild(this.createCellElem("Angle",(360-w)*Math.PI/180)),b.rotation+=w,b.rotationCx=d,b.rotationCy=a)};
+mxVsdxCanvas2D.prototype.stroke=function(){this.geoSec.appendChild(this.createCellElem("NoFill","1"));this.geoSec.appendChild(this.createCellElem("NoLine","0"))};mxVsdxCanvas2D.prototype.fill=function(){this.geoSec.appendChild(this.createCellElem("NoFill","0"));this.geoSec.appendChild(this.createCellElem("NoLine","1"))};mxVsdxCanvas2D.prototype.fillAndStroke=function(){this.geoSec.appendChild(this.createCellElem("NoFill","0"));this.geoSec.appendChild(this.createCellElem("NoLine","0"))};
\ No newline at end of file