Skip to content

Commit

Permalink
24.5.3 release
Browse files Browse the repository at this point in the history
  • Loading branch information
davidjgraph committed Jun 11, 2024
1 parent cc6ac85 commit 7b523e5
Show file tree
Hide file tree
Showing 18 changed files with 2,303 additions and 2,264 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
strategy:
fail-fast: false
matrix:
language: [ 'javascript' ]
language: [ 'java', 'javascript' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://git.io/codeql-language-support

Expand Down Expand Up @@ -70,4 +70,4 @@ jobs:
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v2
6 changes: 3 additions & 3 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ name: Mark stale issues and pull requests

on:
schedule:
- cron: '45 20 * * *'
- cron: '42 11 * * *'

jobs:
stale:
Expand All @@ -26,7 +26,7 @@ jobs:
stale-issue-label: 'wonfix'
stale-pr-label: 'wonfix'
close-issue-label: 'declined'
days-before-stale: 200
days-before-stale: 300
days-before-close: 60
exempt-issue-labels: notstale
exempt-pr-labels: notstale
exempt-pr-labels: notstale
7 changes: 7 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
11-JUN-2024: 24.5.3

- Fixes show start screen option [drawio-desktop-1738]
- Fixes fallback text position [drawio-desktop-1624]
- Removes control characters in link check
- Uses current unit in line position (start, end) in Format panel - Arrange [drawio-1915]

07-JUN-2024: 24.5.2

- [conf cloud] Adds Drive file access and app check to embed macro
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
24.5.2
24.5.3
821 changes: 411 additions & 410 deletions src/main/webapp/js/app.min.js

Large diffs are not rendered by default.

26 changes: 18 additions & 8 deletions src/main/webapp/js/diagramly/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -3427,11 +3427,11 @@ App.prototype.start = function()
}
}));
}
else if (urlParams['splash'] != '0' || urlParams['mode'] != null)
else if (urlParams['splash'] != '0' || (urlParams['mode'] != null && !EditorUi.isElectronApp))
{
this.loadFile();
}
else if (!EditorUi.isElectronApp)
else
{
this.createFile(this.defaultFilename, this.getFileData(),
null, null, null, null, null, true);
Expand Down Expand Up @@ -3953,14 +3953,24 @@ App.prototype.loadFileSystemEntry = function(fileHandle, success, error)
error(e);
}
});

fileHandle.createWritable().then(mxUtils.bind(this, function(writable)
if (fileHandle.queryPermission)
{
doSuccess(true);
}), mxUtils.bind(this, function(e)
fileHandle.queryPermission({mode: 'readwrite'}).then(mxUtils.bind(this, function(permission)
{
doSuccess(permission !== 'denied');
}));
}
else
{
doSuccess(false);
}));
fileHandle.createWritable().then(mxUtils.bind(this, function()
{
doSuccess(true);
}), mxUtils.bind(this, function(e)
{
doSuccess(false);
}));
}
});

reader.onerror = error;
Expand Down
2 changes: 1 addition & 1 deletion src/main/webapp/js/diagramly/Dialogs.js
Original file line number Diff line number Diff line change
Expand Up @@ -3362,6 +3362,7 @@ var NewDialog = function(editorUi, compact, showName, callback, createOnly, canc
{
templateXml = modelXml;
lastAiXml = templateXml;
lastAiTitle = 'Smart Template: ' + title;
}
}));
}
Expand Down Expand Up @@ -3393,7 +3394,6 @@ var NewDialog = function(editorUi, compact, showName, callback, createOnly, canc
{
templateXml = xml;
lastAiXml = xml;
lastAiTitle = 'Smart Template: ' + title;
}

var magnify = magnifyImage.cloneNode(true);
Expand Down
3 changes: 2 additions & 1 deletion src/main/webapp/js/diagramly/EditorUi.js
Original file line number Diff line number Diff line change
Expand Up @@ -6100,7 +6100,8 @@
}

// Adds padding for font metrics
size.height += (parseInt(measure.style.fontSize) / 4);
size = new mxRectangle(x, y, size.width, size.height +
(parseInt(measure.style.fontSize) / 4));

// Sequence of async conversion to images
convert.push(mxUtils.bind(this, function(next)
Expand Down
33 changes: 17 additions & 16 deletions src/main/webapp/js/grapheditor/Format.js
Original file line number Diff line number Diff line change
Expand Up @@ -2764,6 +2764,7 @@ ArrangePanel.prototype.addEdgeGeometryHandler = function(input, fn)
*/
ArrangePanel.prototype.addEdgeGeometry = function(container)
{
var panel = this;
var ui = this.editorUi;
var graph = ui.editor.graph;
var rect = ui.getSelectionState();
Expand Down Expand Up @@ -2819,14 +2820,14 @@ ArrangePanel.prototype.addEdgeGeometry = function(container)
mxUtils.write(span, mxResources.get('linestart'));
divs.appendChild(span);

var xs = this.addUnitInput(divs, 'pt', 87, 52, function()
var xs = this.addUnitInput(divs, this.getUnit(), 87, 52, function()
{
xsUpdate.apply(this, arguments);
});
var ys = this.addUnitInput(divs, 'pt', 16, 52, function()
}, this.getUnitStep(), null, null, this.isFloatUnit());
var ys = this.addUnitInput(divs, this.getUnit(), 16, 52, function()
{
ysUpdate.apply(this, arguments);
});
}, this.getUnitStep(), null, null, this.isFloatUnit());

mxUtils.br(divs);
this.addLabel(divs, mxResources.get('left'), 87, 64);
Expand All @@ -2845,14 +2846,14 @@ ArrangePanel.prototype.addEdgeGeometry = function(container)
mxUtils.write(span, mxResources.get('lineend'));
divt.appendChild(span);

var xt = this.addUnitInput(divt, 'pt', 87, 52, function()
var xt = this.addUnitInput(divt, this.getUnit(), 87, 52, function()
{
xtUpdate.apply(this, arguments);
});
var yt = this.addUnitInput(divt, 'pt', 16, 52, function()
}, this.getUnitStep(), null, null, this.isFloatUnit());
var yt = this.addUnitInput(divt, this.getUnit(), 16, 52, function()
{
ytUpdate.apply(this, arguments);
});
}, this.getUnitStep(), null, null, this.isFloatUnit());

mxUtils.br(divt);
this.addLabel(divt, mxResources.get('left'), 87, 64);
Expand Down Expand Up @@ -2889,8 +2890,8 @@ ArrangePanel.prototype.addEdgeGeometry = function(container)
if (geo != null && geo.sourcePoint != null &&
graph.model.getTerminal(cell, true) == null)
{
xs.value = geo.sourcePoint.x;
ys.value = geo.sourcePoint.y;
xs.value = this.inUnit(geo.sourcePoint.x) + ' ' + this.getUnit();
ys.value = this.inUnit(geo.sourcePoint.y) + ' ' + this.getUnit();
}
else
{
Expand All @@ -2900,8 +2901,8 @@ ArrangePanel.prototype.addEdgeGeometry = function(container)
if (geo != null && geo.targetPoint != null &&
graph.model.getTerminal(cell, false) == null)
{
xt.value = geo.targetPoint.x;
yt.value = geo.targetPoint.y;
xt.value = this.inUnit(geo.targetPoint.x) + ' ' + this.getUnit();
yt.value = this.inUnit(geo.targetPoint.y) + ' ' + this.getUnit();
}
else
{
Expand All @@ -2917,22 +2918,22 @@ ArrangePanel.prototype.addEdgeGeometry = function(container)

xsUpdate = this.addEdgeGeometryHandler(xs, function(geo, value)
{
geo.sourcePoint.x = value;
geo.sourcePoint.x = panel.fromUnit(value);
});

ysUpdate = this.addEdgeGeometryHandler(ys, function(geo, value)
{
geo.sourcePoint.y = value;
geo.sourcePoint.y = panel.fromUnit(value);
});

xtUpdate = this.addEdgeGeometryHandler(xt, function(geo, value)
{
geo.targetPoint.x = value;
geo.targetPoint.x = panel.fromUnit(value);
});

ytUpdate = this.addEdgeGeometryHandler(yt, function(geo, value)
{
geo.targetPoint.y = value;
geo.targetPoint.y = panel.fromUnit(value);
});

graph.getModel().addListener(mxEvent.CHANGE, listener);
Expand Down
23 changes: 1 addition & 22 deletions src/main/webapp/js/grapheditor/Graph.js
Original file line number Diff line number Diff line change
Expand Up @@ -1681,28 +1681,7 @@ Graph.htmlToPng = function(html, w, h, fn, css, scale)
*/
Graph.zapGremlins = function(text)
{
var lastIndex = 0;
var checked = [];

for (var i = 0; i < text.length; i++)
{
var code = text.charCodeAt(i);

// Removes all control chars except TAB, LF and CR
if (!((code >= 32 || code == 9 || code == 10 || code == 13) &&
code != 0xFFFF && code != 0xFFFE))
{
checked.push(text.substring(lastIndex, i));
lastIndex = i + 1;
}
}

if (lastIndex > 0 && lastIndex < text.length)
{
checked.push(text.substring(lastIndex));
}

return (checked.length == 0) ? text : checked.join('');
return mxUtils.zapGremlins(text);
};

/**
Expand Down
Loading

0 comments on commit 7b523e5

Please sign in to comment.