This commit is contained in:
Boof 2023-05-30 12:05:45 +02:00 committed by GitHub
parent 717153cb9e
commit 5357c2f2fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,7 +15,7 @@
img.onload = function (event) {
var canvas = document.createElement("canvas");
var ctx = canvas.getContext("2d");
ctx.drawImage(img, 0, 0, 300, 300);
ctx.drawImage(img, 0, 0, 48, 48);
var dataurl = canvas.toDataURL(imageFile.type);
document.getElementById("preview").src = dataurl;
}