Browse Source

10.1.8 release

Gaudenz Alder 6 years ago
parent
commit
cd654a182c

+ 5 - 0
ChangeLog

@@ -1,3 +1,8 @@
+05-FEB-2019: 10.1.8
+
+- Fixes property focus after save
+- Updated AWS 2019 icon colors
+
 04-FEB-2019: 10.1.7
 
 - Adds auto-resolution for Google add-ons

+ 1 - 1
VERSION

@@ -1 +1 @@
-10.1.7
+10.1.8

+ 1 - 1
src/main/webapp/cache.manifest

@@ -1,7 +1,7 @@
 CACHE MANIFEST
 
 # THIS FILE WAS GENERATED. DO NOT MODIFY!
-# 02/04/2019 11:37 AM
+# 02/05/2019 02:53 PM
 
 app.html
 index.html?offline=1

File diff suppressed because it is too large
+ 363 - 353
src/main/webapp/js/app.min.js


File diff suppressed because it is too large
+ 373 - 367
src/main/webapp/js/atlas-viewer.min.js


File diff suppressed because it is too large
+ 731 - 721
src/main/webapp/js/atlas.min.js


+ 8 - 1
src/main/webapp/js/diagramly/App.js

@@ -440,6 +440,13 @@ App.main = function(callback, createUi)
 		}
 	}
 	
+	// Redirects to the latest AWS icons
+	if (document.referrer != null && urlParams['libs'] == 'aws3' &&
+		document.referrer.substring(0, 42) == 'https://aws.amazon.com/architecture/icons/')
+	{
+		urlParams['libs'] = 'aws4';
+	}
+	
 	if (window.mxscript != null)
 	{
 		// Injects offline dependencies
@@ -4415,7 +4422,7 @@ App.prototype.descriptorChanged = function()
 	
 	this.updateUi();
 
-	if (this.format != null)
+	if (this.format != null && this.editor.graph.isSelectionEmpty())
 	{
 		this.format.refresh();
 	}

+ 31 - 2
src/main/webapp/js/diagramly/DrawioFile.js

@@ -343,9 +343,21 @@ DrawioFile.prototype.mergeFile = function(file, success, error, diffShadow)
 
 		try
 		{
-			if (this.errorReportsEnabled && reportError)
+			if (reportError)
 			{
-				this.sendErrorReport('Error in mergeFile', null, e);
+				if (this.errorReportsEnabled)
+				{
+					this.sendErrorReport('Error in mergeFile', null, e);
+				}
+				else
+				{
+					var user = this.getCurrentUser();
+					var uid = (user != null) ? user.id : 'unknown';
+					
+					EditorUi.logError('Error in mergeFile', null,
+						this.getMode() + '.' + this.getId(),
+						uid, e);
+				}
 			}
 		}
 		catch (e2)
@@ -475,6 +487,14 @@ DrawioFile.prototype.checksumError = function(error, patches, details, etag, fun
 				}), function() {});
 			}
 		}
+		else
+		{
+			var user = this.getCurrentUser();
+			var uid = (user != null) ? user.id : 'unknown';
+			
+			EditorUi.logError('Checksum Error in ' + functionName, null,
+				this.getMode() + '.' + this.getId(), uid);
+		}
 	}
 	catch (e)
 	{
@@ -1673,6 +1693,15 @@ DrawioFile.prototype.fileSaved = function(savedData, lastDesc, success, error)
 			{
 				this.sendErrorReport('Error in fileSaved', null, e);
 			}
+			else
+			{
+				var user = this.getCurrentUser();
+				var uid = (user != null) ? user.id : 'unknown';
+				
+				EditorUi.logError('Error in fileSaved', null,
+					this.getMode() + '.' + this.getId(),
+					uid, e);
+			}
 		}
 		catch (e2)
 		{

+ 10 - 2
src/main/webapp/js/diagramly/DrawioFileSync.js

@@ -973,12 +973,20 @@ DrawioFileSync.prototype.merge = function(patches, checksum, etag, success, erro
 				var to = this.ui.hashValue(etag);
 				
 				this.file.sendErrorReport('Error in merge',
-					'From: ' + from +
-					'\nTo: ' + to +
+					'From: ' + from + '\nTo: ' + to +
 					'\nChecksum: ' + checksum +
 					'\nPatches:\n' + this.file.compressReportData(
 						JSON.stringify(patches, null, 2)), e);
 			}
+			else
+			{
+				var user = this.file.getCurrentUser();
+				var uid = (user != null) ? user.id : 'unknown';
+				
+				EditorUi.logError('Error in merge', null,
+					this.file.getMode() + '.' +
+					this.file.getId(), uid, e);
+			}
 		}
 		catch (e2)
 		{

+ 1 - 0
src/main/webapp/js/diagramly/DriveClient.js

@@ -1143,6 +1143,7 @@ DriveClient.prototype.saveFile = function(file, revision, success, error, noChec
 		{
 			// NOTE: getThumbnail is asynchronous and returns false if no thumbnails can be created
 			if (unloading || file.constructor == DriveLibrary || !this.enableThumbnails || urlParams['thumb'] == '0' ||
+				(file.desc.mimeType != null && file.desc.mimeType.substring(0, 29) != 'application/vnd.jgraph.mxfile') ||
 				!this.ui.getThumbnail(this.thumbnailWidth, mxUtils.bind(this, function(canvas)
 				{
 					// Callback for getThumbnail

+ 1 - 1
src/main/webapp/js/diagramly/Minimal.js

@@ -958,7 +958,7 @@ EditorUi.initMinimalTheme = function()
         div.style.bottom = (urlParams['embed'] != '1' || urlParams['libraries'] == '1') ? '63px' : '32px';
         this.sidebar = this.createSidebar(div);
         
-        if (urlParams['clibs'])
+        if (urlParams['clibs'] != null || urlParams['libs'] != null)
         {
         	toggleShapes(this);
         }

+ 46 - 2
src/main/webapp/js/diagramly/sidebar/Sidebar-AWS4.js

@@ -8,8 +8,8 @@
 		var h = 100 * s;
 		var w2 = 60 * s;
 		var pts = 'points=[[0,0],[0.25,0],[0.5,0],[0.75,0],[1,0],[1,0.25],[1,0.5],[1,0.75],[1,1],[0.75,1],[0.5,1],[0.25,1],[0,1],[0,0.75],[0,0.5],[0,0.25]];';
-		var n = pts + 'outlineConnect=0;fontColor=#232F3E;gradientColor=none;strokeColor=#ffffff;fillColor=#232F3E;dashed=0;verticalLabelPosition=middle;verticalAlign=bottom;align=center;html=1;whiteSpace=wrap;fontSize=10;fontStyle=1;spacing=3;' + mxConstants.STYLE_SHAPE + "=mxgraph.aws4.";
-		var n2 = pts + 'outlineConnect=0;fontColor=#232F3E;gradientColor=none;strokeColor=#232F3E;fillColor=#ffffff;dashed=0;verticalLabelPosition=bottom;verticalAlign=top;align=center;html=1;fontSize=12;fontStyle=0;aspect=fixed;' + mxConstants.STYLE_SHAPE + "=mxgraph.aws4.";
+		var n = pts + 'outlineConnect=0;fontColor=#232F3E;strokeColor=#ffffff;dashed=0;verticalLabelPosition=middle;verticalAlign=bottom;align=center;html=1;whiteSpace=wrap;fontSize=10;fontStyle=1;spacing=3;' + mxConstants.STYLE_SHAPE + "=mxgraph.aws4.";
+		var n2 = pts + 'outlineConnect=0;fontColor=#232F3E;gradientColor=none;fillColor=#ffffff;dashed=0;verticalLabelPosition=bottom;verticalAlign=top;align=center;html=1;fontSize=12;fontStyle=0;aspect=fixed;' + mxConstants.STYLE_SHAPE + "=mxgraph.aws4.";
 		var n3 = 'outlineConnect=0;gradientColor=none;fontColor=#545B64;strokeColor=none;fillColor=#879196;dashed=0;verticalLabelPosition=bottom;verticalAlign=top;align=center;html=1;fontSize=12;fontStyle=0;aspect=fixed;' + mxConstants.STYLE_SHAPE + "=mxgraph.aws4.";
 		var n4 = pts + 'outlineConnect=0;gradientColor=none;html=1;whiteSpace=wrap;fontSize=12;fontStyle=0;' + mxConstants.STYLE_SHAPE + "=mxgraph.aws4.";
 		var gn = 'mxgraph.aws4';
@@ -206,6 +206,8 @@
 	Sidebar.prototype.addAWS4AnalyticsPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service analytics';
+		n = 'gradientColor=#945DF2;gradientDirection=north;fillColor=#5A30B5;' + n;
+		n2 = 'strokeColor=#5A30B5;' + n2;
 		
 		this.addPaletteFunctions('aws4Analytics', 'AWS / Analytics', false,
 		[
@@ -260,6 +262,8 @@
 	Sidebar.prototype.addAWS4ApplicationIntegrationPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service application integration';
+		n = 'gradientColor=#F34482;gradientDirection=north;fillColor=#BC1356;' + n;
+		n2 = 'strokeColor=#BC1356;' + n2;
 		
 		this.addPaletteFunctions('aws4Application Integration', 'AWS / Application Integration', false,
 		[
@@ -290,6 +294,8 @@
 	Sidebar.prototype.addAWS4ARVRPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service ar vr augmented virtual reality';
+		n = 'gradientColor=#F34482;gradientDirection=north;fillColor=#BC1356;' + n;
+		n2 = 'strokeColor=#BC1356;' + n2;
 		
 		this.addPaletteFunctions('aws4AR VR', 'AWS / AR & VR', false,
 		[
@@ -301,6 +307,8 @@
 	Sidebar.prototype.addAWS4CostManagementPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service cost management';
+		n = 'gradientColor=#60A337;gradientDirection=north;fillColor=#277116;' + n;
+		n2 = 'strokeColor=#277116;' + n2;
 		
 		this.addPaletteFunctions('aws4Cost Management', 'AWS / Cost Management', false,
 		[
@@ -318,6 +326,8 @@
 	Sidebar.prototype.addAWS4BusinessProductivityPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service business productivity';
+		n = 'gradientColor=#F54749;gradientDirection=north;fillColor=#C7131F;' + n;
+		n2 = 'strokeColor=#C7131F;' + n2;
 		
 		this.addPaletteFunctions('aws4Business Productivity', 'AWS / Business Productivity', false,
 		[
@@ -329,6 +339,8 @@
 	Sidebar.prototype.addAWS4ComputePalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service compute';
+		n = 'gradientColor=#F78E04;gradientDirection=north;fillColor=#D05C17;' + n;
+		n2 = 'strokeColor=#D05C17;' + n2;
 		
 		this.addPaletteFunctions('aws4Compute', 'AWS / Compute', false,
 		[
@@ -405,6 +417,8 @@
 	Sidebar.prototype.addAWS4CustomerEngagementPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service customer engagement';
+		n = 'gradientColor=#4D72F3;gradientDirection=north;fillColor=#3334B9;' + n;
+		n2 = 'strokeColor=#3334B9;' + n2;
 		
 		this.addPaletteFunctions('aws4Customer Engagement', 'AWS / Customer Engagement', false,
 		[
@@ -423,6 +437,8 @@
 	Sidebar.prototype.addAWS4DatabasePalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service db database';
+		n = 'gradientColor=#4D72F3;gradientDirection=north;fillColor=#3334B9;' + n;
+		n2 = 'strokeColor=#3334B9;' + n2;
 		
 		this.addPaletteFunctions('aws4Database', 'AWS / Database', false,
 		[
@@ -497,6 +513,8 @@
 	Sidebar.prototype.addAWS4DesktopAppStreamingPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service db database';
+		n = 'gradientColor=#4AB29A;gradientDirection=north;fillColor=#116D5B;' + n;
+		n2 = 'strokeColor=#116D5B;' + n2;
 		
 		this.addPaletteFunctions('aws4Desktop App Streaming', 'AWS / Desktop & App Streaming', false,
 		[
@@ -508,6 +526,8 @@
 	Sidebar.prototype.addAWS4DeveloperToolsPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service dev developer tools';
+		n = 'gradientColor=#4D72F3;gradientDirection=north;fillColor=#3334B9;' + n;
+		n2 = 'strokeColor=#3334B9;' + n2;
 		
 		this.addPaletteFunctions('aws4Developer Tools', 'AWS / Developer Tools', false,
 		[
@@ -535,6 +555,8 @@
 	Sidebar.prototype.addAWS4GameDevelopmentPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service game development';
+		n = 'gradientColor=#945DF2;gradientDirection=north;fillColor=#5A30B5;' + n;
+		n2 = 'strokeColor=#5A30B5;' + n2;
 		
 		this.addPaletteFunctions('aws4Game Development', 'AWS / Game Development', false,
 		[
@@ -546,6 +568,8 @@
 	Sidebar.prototype.addAWS4InternetOfThingsPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service internet of things iot';
+		n = 'gradientColor=#60A337;gradientDirection=north;fillColor=#277116;' + n;
+		n2 = 'strokeColor=#277116;' + n2;
 		
 		this.addPaletteFunctions('aws4Internet of Things', 'AWS / Internet of Things', false,
 		[
@@ -571,6 +595,8 @@
 	Sidebar.prototype.addAWS4IOTThingsPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service internet of things iot';
+		n = 'gradientColor=#60A337;gradientDirection=north;fillColor=#277116;' + n;
+		n2 = 'strokeColor=#277116;' + n2;
 		
 		this.addPaletteFunctions('aws4IoT Things', 'AWS / IoT Things', false,
 		[
@@ -614,6 +640,8 @@
 	Sidebar.prototype.addAWS4IOTResourcesPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service internet of things iot resources';
+		n = 'gradientColor=#60A337;gradientDirection=north;fillColor=#277116;' + n;
+		n2 = 'strokeColor=#277116;' + n2;
 		
 		this.addPaletteFunctions('aws4IoT Resources', 'AWS / IoT Resources', false,
 		[
@@ -671,6 +699,8 @@
 	Sidebar.prototype.addAWS4MachineLearningPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service machine learning';
+		n = 'gradientColor=#4AB29A;gradientDirection=north;fillColor=#116D5B;' + n;
+		n2 = 'strokeColor=#116D5B;' + n2;
 		
 		this.addPaletteFunctions('aws4Machine Learning', 'AWS / Machine Learning', false,
 		[
@@ -702,6 +732,8 @@
 	Sidebar.prototype.addAWS4ManagementToolsPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service management tools';
+		n = 'gradientColor=#F34482;gradientDirection=north;fillColor=#BC1356;' + n;
+		n2 = 'strokeColor=#BC1356;' + n2;
 		
 		this.addPaletteFunctions('aws4Management Tools', 'AWS / Management Tools', false,
 		[
@@ -798,6 +830,8 @@
 	Sidebar.prototype.addAWS4MediaServicesPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service media services';
+		n = 'gradientColor=#F78E04;gradientDirection=north;fillColor=#D05C17;' + n;
+		n2 = 'strokeColor=#D05C17;' + n2;
 		
 		this.addPaletteFunctions('aws4Media Services', 'AWS / Media Services', false,
 		[
@@ -821,6 +855,8 @@
 	Sidebar.prototype.addAWS4MigrationPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service migration';
+		n = 'gradientColor=#4AB29A;gradientDirection=north;fillColor=#116D5B;' + n;
+		n2 = 'strokeColor=#116D5B;' + n2;
 		
 		this.addPaletteFunctions('aws4Migration', 'AWS / Migration', false,
 		[
@@ -844,6 +880,8 @@
 	Sidebar.prototype.addAWS4MobileServicesPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service mobile services';
+		n = 'gradientColor=#F54749;gradientDirection=north;fillColor=#C7131F;' + n;
+		n2 = 'strokeColor=#C7131F;' + n2;
 		
 		this.addPaletteFunctions('aws4Mobile Services', 'AWS / Mobile Services', false,
 		[
@@ -863,6 +901,8 @@
 	Sidebar.prototype.addAWS4NetworkContentDeliveryPalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service netowrk content delivery';
+		n = 'gradientColor=#945DF2;gradientDirection=north;fillColor=#5A30B5;' + n;
+		n2 = 'strokeColor=#5A30B5;' + n2;
 		
 		this.addPaletteFunctions('aws4Network Content Delivery', 'AWS / Network & Content Delivery', false,
 		[
@@ -919,6 +959,8 @@
 	Sidebar.prototype.addAWS4SecurityIdentityCompliancePalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service security identity compliance';
+		n = 'gradientColor=#F54749;gradientDirection=north;fillColor=#C7131F;' + n;
+		n2 = 'strokeColor=#C7131F;' + n2;
 		
 		this.addPaletteFunctions('aws4Security Identity Compliance', 'AWS / Security, Identity & Compliance', false,
 		[
@@ -983,6 +1025,8 @@
 	Sidebar.prototype.addAWS4StoragePalette = function(w, h, w2, n, n2, gn, sb)
 	{
 		var dt = 'aws amazon web service storage';
+		n = 'gradientColor=#60A337;gradientDirection=north;fillColor=#277116;' + n;
+		n2 = 'strokeColor=#277116;' + n2;
 		
 		this.addPaletteFunctions('aws4Storage', 'AWS / Storage', false,
 		[

+ 1 - 1
src/main/webapp/js/diagramly/sidebar/Sidebar.js

@@ -444,7 +444,7 @@
             			{title: mxResources.get('networking'),
             			entries: [{title: 'AWS17', id: 'aws3', image: IMAGE_PATH + '/sidebar-aws3.png'},
             			// TODO: Add isometric containers  		                          
-            				      {title: 'AWS18', id: 'aws4', image: IMAGE_PATH + '/sidebar-aws4.png'},
+            				      {title: 'AWS19', id: 'aws4', image: IMAGE_PATH + '/sidebar-aws4.png'},
             					  {title: 'Allied Telesis', id: 'allied_telesis', image: IMAGE_PATH + '/sidebar-allied_telesis.png'},
             			          {title: mxResources.get('aws3d'), id: 'aws3d', image: IMAGE_PATH + '/sidebar-aws3d.png'},
             			          {title: mxResources.get('azure'), id: 'azure', image: IMAGE_PATH + '/sidebar-azure.png'},

File diff suppressed because it is too large
+ 1 - 1
src/main/webapp/js/embed-static.min.js


File diff suppressed because it is too large
+ 10 - 0
src/main/webapp/js/mxgraph/Editor.js


+ 28 - 0
src/main/webapp/js/mxgraph/EditorUi.js

@@ -1477,6 +1477,8 @@ EditorUi.prototype.initCanvas = function()
 		// as this may be used in a viewer that has no CSS
 		if (urlParams['toolbar'] != '0')
 		{
+			var toolbarConfig = JSON.parse(decodeURIComponent(urlParams['toolbar-config'] || '{}'));
+			
 			this.chromelessToolbar = document.createElement('div');
 			this.chromelessToolbar.style.position = 'fixed';
 			this.chromelessToolbar.style.overflow = 'hidden';
@@ -1529,6 +1531,15 @@ EditorUi.prototype.initCanvas = function()
 				return a;
 			});
 			
+			if (toolbarConfig.backBtn != null)
+			{
+				addButton(mxUtils.bind(this, function(evt)
+				{
+					window.location.href = toolbarConfig.backBtn.url;
+					mxEvent.consume(evt);
+				}), Editor.backLargeImage, mxResources.get('goback', null, 'Go Back'));
+			}
+			
 			var prevButton = addButton(mxUtils.bind(this, function(evt)
 			{
 				this.actions.get('previousPage').funct();
@@ -1771,6 +1782,23 @@ EditorUi.prototype.initCanvas = function()
 				}), Editor.closeLargeImage, mxResources.get('close') + ' (Escape)');
 			}
 	
+			if (toolbarConfig.refreshBtn != null)
+			{
+				addButton(mxUtils.bind(this, function(evt)
+				{
+					if (toolbarConfig.refreshBtn.url)
+					{
+						window.location.href = toolbarConfig.refreshBtn.url;
+					}
+					else
+					{
+						window.location.reload();
+					}
+					
+					mxEvent.consume(evt);
+				}), Editor.refreshLargeImage, mxResources.get('refresh', null, 'Refresh'));
+			}
+			
 			// Initial state invisible
 			this.chromelessToolbar.style.display = 'none';
 			mxUtils.setPrefixedStyle(this.chromelessToolbar.style, 'transform', 'translate(-50%,0)');

File diff suppressed because it is too large
+ 1 - 1
src/main/webapp/js/reader.min.js


File diff suppressed because it is too large
+ 3 - 2
src/main/webapp/js/shapes.min.js


File diff suppressed because it is too large
+ 373 - 367
src/main/webapp/js/viewer.min.js


+ 19 - 0
src/main/webapp/shapes/mxAWS4.js

@@ -36,9 +36,24 @@ mxShapeAws4ProductIcon.prototype.paintVertexShape = function(c, x, y, w, h)
 {
 	c.translate(x, y);
 
+	var opacity = mxUtils.getValue(this.style, 'opacity', '100');
+	var op1 = opacity;
+	var op2 = opacity;
+	
+	if (fillColor == 'none')
+	{
+		op1 = 0;
+	}
+	
+	if (gradientColor == 'none')
+	{
+		op2 = 0;
+	}
+
 	var ind = 1;
 	var strokeColor = mxUtils.getValue(this.state.style, 'strokeColor', '#000000');
 	c.setFillColor(strokeColor);
+	c.setGradient(fillColor, fillColor, 0, 0, w, h, gradientDir, op1, op2);	
 
 	c.begin();
 	c.moveTo(0, 0);
@@ -50,7 +65,11 @@ mxShapeAws4ProductIcon.prototype.paintVertexShape = function(c, x, y, w, h)
 
 	c.setShadow(false);
 	var fillColor = mxUtils.getValue(this.state.style, 'fillColor', '#ffffff');
+	var gradientColor = mxUtils.getValue(this.state.style, 'gradientColor', fillColor);
+	var gradientDir = mxUtils.getValue(this.state.style, 'gradientDirection', 'south');
+	
 	c.setFillColor(fillColor);
+	c.setGradient(fillColor, gradientColor, 0, 0, w, h, gradientDir, op1, op2);	
 
 	c.begin();
 	c.moveTo(ind, ind);