chore: biome format

This commit is contained in:
Peter Steinberger
2025-12-20 18:38:56 +01:00
parent cdb2a0736a
commit 5687a03f0b
4 changed files with 42 additions and 30 deletions

View File

@@ -12,12 +12,12 @@ type QRCodeConstructor = new (
};
const require = createRequire(import.meta.url);
const QRCode = require(
"qrcode-terminal/vendor/QRCode",
) as QRCodeConstructor;
const QRErrorCorrectLevel = require(
"qrcode-terminal/vendor/QRCode/QRErrorCorrectLevel",
) as Record<string, unknown>;
const QRCode = require("qrcode-terminal/vendor/QRCode") as QRCodeConstructor;
const QRErrorCorrectLevel =
require("qrcode-terminal/vendor/QRCode/QRErrorCorrectLevel") as Record<
string,
unknown
>;
function createQrMatrix(input: string) {
const qr = new QRCode(-1, QRErrorCorrectLevel.L);
@@ -85,7 +85,9 @@ function encodePngRgba(buffer: Buffer, width: number, height: number) {
}
const compressed = deflateSync(raw);
const signature = Buffer.from([0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a]);
const signature = Buffer.from([
0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a,
]);
const ihdr = Buffer.alloc(13);
ihdr.writeUInt32BE(width, 0);
ihdr.writeUInt32BE(height, 4);