chore: biome format
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user