Skip to content

Commit

Permalink
snapshot fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Brian Ondov committed Dec 20, 2021
1 parent 149f21a commit 710311b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions KronaTools/src/krona-2.0.js
Original file line number Diff line number Diff line change
Expand Up @@ -6077,10 +6077,10 @@ function snapshot()
snapshotMode = false;

svg += svgFooter();

var snapshotWindow = window.open('', '_blank', '', 'replace=false');
snapshotWindow.document.write('<html><body><a href="data:image/svg+xml,' + encodeURIComponent(svg) + '" download="snapshot.svg">Download Snapshot</a></html></body>');
snapshotWindow.document.write(svg);
var dataUri = 'data:image/svg+xml,' + encodeURIComponent(svg)
var string = '<html><body><iframe src="' + dataUri + '" frameborder="0" style="position:absolute; border:0; top:0px; left:0px; bottom:0px; right:0px; width:100%; height:100%;" allowfullscreen></iframe><a style="position:absolute" href="' + dataUri + '" download="snapshot.svg">Download Snapshot</a></html></body>';
var win = window.open();
win.document.write(string)
}

function save()
Expand Down

0 comments on commit 710311b

Please sign in to comment.