Skip to content

Commit

Permalink
24.4.4 release
Browse files Browse the repository at this point in the history
  • Loading branch information
davidjgraph committed May 17, 2024
1 parent e30be6f commit f883896
Show file tree
Hide file tree
Showing 97 changed files with 6,130 additions and 5,605 deletions.
23 changes: 23 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
17-MAY-2024: 24.4.4

- Improves diff sync for removed default layer

16-MAY-2024: 24.4.3

- [conf cloud] Updates CSP based on the deprecation notice https://developer.atlassian.com/cloud/confluence/changelog/#CHANGE-1601
- Improves diff sync and handles special cases

15-MAY-2024: 24.4.2

- Fixes possible NPE in StorageFile.getEtag

15-MAY-2024: 24.4.1

- Improves page switching performance
- Updates DOMPurify from 3.1.2 to 3.1.3
- Restores view and selection state after merge of local files
- Adds conflict handling for browser files for testing
- Fixes inactive escape listeners in sidebar [drawio-4379]
- Moves locking to file [drawio-desktop-1380]
- Adds automatic merge for browser files

10-MAY-2024: 24.4.0

- [vsdx] Fixes attribute labels [drawio-4299]
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
24.4.0
24.4.4
4 changes: 2 additions & 2 deletions etc/build/build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@
<file name="EditorUi.js" />
<file name="DiffSync.js" />
<file name="Settings.js" />
<file name="DrawioFilePuller.js" />
<file name="DrawioFilePolling.js" />
<file name="DrawioFileSync.js" />
<file name="App.js" />
<file name="Menus.js" />
Expand Down Expand Up @@ -385,7 +385,7 @@
<file name="EditorUi.js" />
<file name="DiffSync.js" />
<file name="Settings.js" />
<file name="DrawioFilePuller.js" />
<file name="DrawioFilePolling.js" />
<file name="DrawioFileSync.js" />
</sources>

Expand Down
2 changes: 1 addition & 1 deletion etc/dependencies/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"mermaid": "10.0.2",
"pako": "2.1.0",
"crypto-js": "3.1.2",
"dompurify": "3.1.2",
"dompurify": "3.1.3",
"spin.js": "2.0.0",
"roughjs": "4.6.6",
"mathjax": "3.2.2",
Expand Down
4 changes: 2 additions & 2 deletions src/main/webapp/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -325,14 +325,14 @@
});
});
}
else if (!supportedDomain)
else if (!supportedDomain || navigator.onLine)
{
mxscript('js/PostConfig.js');
}
});
};

if (!supportedDomain || mxIsElectron)
if (!supportedDomain || mxIsElectron || navigator.onLine)
{
mxscript('js/PreConfig.js', loadAppJS);
}
Expand Down
149 changes: 98 additions & 51 deletions src/main/webapp/js/diagramly/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ App.main = function(callback, createUi)
{
var content = mxUtils.getTextContent(bootstrap);

if (CryptoJS.MD5(content).toString() != 'e67d72090cb74390e6c8d29461b8a907')
if (CryptoJS.MD5(content).toString() != 'ff68e9badc5b6bcb8f482e0c64b103a7')
{
console.log('Change bootstrap script MD5 in the previous line:', CryptoJS.MD5(content).toString());
alert('[Dev] Bootstrap script change requires update of CSP');
Expand Down Expand Up @@ -1527,46 +1527,66 @@ App.prototype.init = function()
*/
this.descriptorChangedListener = mxUtils.bind(this, this.descriptorChanged);

this.addListener('currentThemeChanged', mxUtils.bind(this, function()
{
if (this.compactMode && this.isDefaultTheme(Editor.currentTheme))
{
this.toggleCompactMode(true);
}
}));

/**
* Creates github client.
*/
this.gitHub = (!mxClient.IS_IE || document.documentMode == 10 ||
mxClient.IS_IE11 || mxClient.IS_EDGE) &&
(urlParams['gh'] != '0' && (urlParams['embed'] != '1' ||
urlParams['gh'] == '1')) ? new GitHubClient(this) : null;

if (this.gitHub != null)
try
{
this.gitHub.addListener('userChanged', mxUtils.bind(this, function()
this.gitHub = (!mxClient.IS_IE || document.documentMode == 10 ||
mxClient.IS_IE11 || mxClient.IS_EDGE) &&
(urlParams['gh'] != '0' && (urlParams['embed'] != '1' ||
urlParams['gh'] == '1')) ? new GitHubClient(this) : null;

if (this.gitHub != null)
{
this.updateUserElement();
this.restoreLibraries();
}));
this.gitHub.addListener('userChanged', mxUtils.bind(this, function()
{
this.updateUserElement();
this.restoreLibraries();
}));
}
}

this.addListener('currentThemeChanged', mxUtils.bind(this, function()
catch (e)
{
if (this.compactMode && this.isDefaultTheme(Editor.currentTheme))
if (window.console != null)
{
this.toggleCompactMode(true);
console.log('GitHubClient disabled: ' + e.message);
}
}));
}

/**
* Creates gitlab client.
*/
this.gitLab = (!mxClient.IS_IE || document.documentMode == 10 ||
mxClient.IS_IE11 || mxClient.IS_EDGE) &&
(urlParams['gl'] != '0' && (urlParams['embed'] != '1' ||
urlParams['gl'] == '1')) ? new GitLabClient(this) : null;
try
{
this.gitLab = (!mxClient.IS_IE || document.documentMode == 10 ||
mxClient.IS_IE11 || mxClient.IS_EDGE) &&
(urlParams['gl'] != '0' && (urlParams['embed'] != '1' ||
urlParams['gl'] == '1')) ? new GitLabClient(this) : null;

if (this.gitLab != null)
if (this.gitLab != null)
{
this.gitLab.addListener('userChanged', mxUtils.bind(this, function()
{
this.updateUserElement();
this.restoreLibraries();
}));
}
}
catch (e)
{
this.gitLab.addListener('userChanged', mxUtils.bind(this, function()
if (window.console != null)
{
this.updateUserElement();
this.restoreLibraries();
}));
console.log('GitLabClient disabled: ' + e.message);
}
}

/**
Expand All @@ -1581,19 +1601,26 @@ App.prototype.init = function()
{
if (typeof OneDrive !== 'undefined')
{
/**
* Holds the x-coordinate of the point.
*/
this.oneDrive = new OneDriveClient(this);

this.oneDrive.addListener('userChanged', mxUtils.bind(this, function()
try
{
this.updateUserElement();
this.restoreLibraries();
}));

// Notifies listeners of new client
this.fireEvent(new mxEventObject('clientLoaded', 'client', this.oneDrive));
this.oneDrive = new OneDriveClient(this);

this.oneDrive.addListener('userChanged', mxUtils.bind(this, function()
{
this.updateUserElement();
this.restoreLibraries();
}));

// Notifies listeners of new client
this.fireEvent(new mxEventObject('clientLoaded', 'client', this.oneDrive));
}
catch (e)
{
if (window.console != null)
{
console.log('OneDriveClient disabled: ' + e.message);
}
}
}
else if (window.DrawOneDriveClientCallback == null)
{
Expand Down Expand Up @@ -1634,7 +1661,7 @@ App.prototype.init = function()
{
if (window.console != null)
{
console.error(e);
console.log('TrelloClient disabled: ' + e.message);
}
}
}
Expand All @@ -1661,17 +1688,27 @@ App.prototype.init = function()
{
var doInit = mxUtils.bind(this, function()
{
this.drive = new DriveClient(this);

this.drive.addListener('userChanged', mxUtils.bind(this, function()
try
{
this.updateUserElement();
this.restoreLibraries();
// this.checkLicense();
}))

// Notifies listeners of new client
this.fireEvent(new mxEventObject('clientLoaded', 'client', this.drive));
this.drive = new DriveClient(this);

this.drive.addListener('userChanged', mxUtils.bind(this, function()
{
this.updateUserElement();
this.restoreLibraries();
// this.checkLicense();
}))

// Notifies listeners of new client
this.fireEvent(new mxEventObject('clientLoaded', 'client', this.drive));
}
catch (e)
{
if (window.console != null)
{
console.log('DriveClient disabled: ' + e.message);
}
}
});

if (window.DrawGapiClientCallback != null)
Expand Down Expand Up @@ -1731,7 +1768,7 @@ App.prototype.init = function()
{
if (window.console != null)
{
console.error(e);
console.log('DropboxClient disabled: ' + e.message);
}
}
}
Expand Down Expand Up @@ -3276,7 +3313,17 @@ App.prototype.start = function()
}

this.fileLoaded(file);
this.getCurrentFile().setModified(!this.editor.chromeless);

if (!this.editor.chromeless)
{
// Handles possible copy of modified file
file.fileChanged();

window.setTimeout(mxUtils.bind(this, function()
{
this.actions.get('resetView').funct();
}), 0);
}
});

var parent = window.opener || window.parent;
Expand Down Expand Up @@ -6785,7 +6832,7 @@ App.prototype.descriptorChanged = function()
}

var graph = this.editor.graph;
var editable = file.isEditable() && !file.invalidChecksum;
var editable = file.isEditable();

if (graph.isEnabled() && !editable)
{
Expand Down
14 changes: 8 additions & 6 deletions src/main/webapp/js/diagramly/Devel.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ if (!mxIsElectron)
//----------------------------------------------------------//
//------------- Bootstrap script in index.html -------------//
//----------------------------------------------------------//
// Version 24.4.4
'\'sha256-f6cHSTUnCvbQqwa6rKcbWIpgN9dLl0ROfpEKTQUQPr8=\' ' +
// Version 24.3.2
'\'sha256-qgjuMiWd1HsOihB9Ppd7j72lY0gT8BpBkiRIJFO3sRQ=\' ' +
// Version 24.2.6
Expand Down Expand Up @@ -56,8 +58,8 @@ if (!mxIsElectron)
var directives = 'connect-src %connect-src% \'self\' https://*.draw.io https://*.diagrams.net ' +
'https://*.googleapis.com wss://app.diagrams.net wss://*.pusher.com https://*.pusher.com ' +
'https://api.github.com https://raw.githubusercontent.com https://gitlab.com ' +
'https://graph.microsoft.com https://*.sharepoint.com https://*.1drv.com https://api.onedrive.com ' +
'https://dl.dropboxusercontent.com https://api.openai.com https://drawio.dev ' +
'https://graph.microsoft.com https://my.microsoftpersonalcontent.com https://*.sharepoint.com https://*.1drv.com https://api.onedrive.com ' +
'https://dl.dropboxusercontent.com https://api.openai.com ' +
'https://*.google.com https://fonts.gstatic.com https://fonts.googleapis.com; ' +
// font-src about: is required for MathJax HTML-CSS output with STIX
'img-src * data: blob:; media-src * data:; font-src * data: about:; ' +
Expand Down Expand Up @@ -98,7 +100,7 @@ if (!mxIsElectron)
'connect-src *; ' +
'img-src * data: blob:; ' +
'media-src * data:; ' +
'font-src * about:; ' +
'font-src * data: about:; ' +
'style-src \'self\' https://fonts.googleapis.com \'unsafe-inline\'; ' +
'base-uri \'none\';' +
'object-src \'none\';' +
Expand All @@ -110,15 +112,15 @@ if (!mxIsElectron)

var ac_draw_io = csp.replace(/%script-src%/g, 'https://aui-cdn.atlassian.com https://connect-cdn.atl-paas.net').
replace(/%frame-src%/g, 'https://www.lucidchart.com https://app.lucidchart.com https://lucid.app blob:').
replace(/%style-src%/g, 'https://aui-cdn.atlassian.com https://*.atlassian.net').
replace(/%style-src%/g, 'https://aui-cdn.atlassian.com https://*.atlassian.net https://connect-cdn.atl-paas.net').
replace(/%connect-src%/g, '').
replace(/ /g, ' ') +
'worker-src https://ac.draw.io/service-worker.js;';
console.log('ac.draw.io:', ac_draw_io);

var aj_draw_io = csp.replace(/%script-src%/g, 'https://aui-cdn.atlassian.com https://connect-cdn.atl-paas.net').
replace(/%frame-src%/g, 'blob:').
replace(/%style-src%/g, 'https://aui-cdn.atlassian.com https://*.atlassian.net').
replace(/%style-src%/g, 'https://aui-cdn.atlassian.com https://*.atlassian.net https://connect-cdn.atl-paas.net').
replace(/%connect-src%/g, 'https://api.atlassian.com https://api.media.atlassian.com').
replace(/ /g, ' ') +
'worker-src https://aj.draw.io/service-worker.js;';
Expand Down Expand Up @@ -231,7 +233,7 @@ mxscript(drawDevUrl + 'js/diagramly/Editor.js');
mxscript(drawDevUrl + 'js/diagramly/EditorUi.js');
mxscript(drawDevUrl + 'js/diagramly/DiffSync.js');
mxscript(drawDevUrl + 'js/diagramly/Settings.js');
mxscript(drawDevUrl + 'js/diagramly/DrawioFilePuller.js');
mxscript(drawDevUrl + 'js/diagramly/DrawioFilePolling.js');
mxscript(drawDevUrl + 'js/diagramly/DrawioFileSync.js');

//Comments
Expand Down
Loading

0 comments on commit f883896

Please sign in to comment.