fix: use fileName for the download file name in save image dialog
This commit is contained in:
parent
6996c9a310
commit
b395f9d00c
1 changed files with 1 additions and 1 deletions
|
|
@ -46,7 +46,7 @@ function SaveImage({ close }: DialogProps) {
|
||||||
|
|
||||||
const link = document.createElement("a");
|
const link = document.createElement("a");
|
||||||
link.href = URL.createObjectURL(blob);
|
link.href = URL.createObjectURL(blob);
|
||||||
link.download = "blockmatic.png";
|
link.download = `${fileName}.png`;
|
||||||
link.click();
|
link.click();
|
||||||
|
|
||||||
URL.revokeObjectURL(link.href);
|
URL.revokeObjectURL(link.href);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue