fix(thank-you): serve GiroCode as signed PNG URL instead of data URL

This commit is contained in:
Gerhard Scheikl
2026-05-09 21:14:47 +02:00
parent f59c981ff4
commit 3fb8600402
5 changed files with 141 additions and 12 deletions
+12
View File
@@ -61,3 +61,15 @@ export async function buildGiroCodeDataUrl(
width: 256,
});
}
export async function buildGiroCodePngBuffer(
input: GiroCodeInput,
): Promise<Buffer> {
const payload = buildGiroCodePayload(input);
return QRCode.toBuffer(payload, {
errorCorrectionLevel: "M",
margin: 1,
width: 256,
type: "png",
});
}