diff --git a/netlify/edge-functions/bff-proxy.js b/netlify/edge-functions/bff-proxy.js index e0f2acb..79629eb 100644 --- a/netlify/edge-functions/bff-proxy.js +++ b/netlify/edge-functions/bff-proxy.js @@ -154,7 +154,7 @@ export default async (request, context) => { qr.make(); const moduleCount = qr.getModuleCount(); const cellSize = Math.max(1, Math.floor(numSize / (moduleCount + QR_MARGIN_MODULES))); - const qrcode = qr.createDataURL(cellSize, cellSize * 2); + const qrcode = qr.createDataURL(cellSize, cellSize * 4); const duration = Date.now() - qrStartTime; console.log(`[edge:qrcode-generate] Success: size=${numSize}, modules=${moduleCount}, cellSize=${cellSize}, duration=${duration}ms, qrcodeLength=${qrcode.length}`); diff --git a/src/js/modules/qrcode-generator.js b/src/js/modules/qrcode-generator.js index 618d143..2ef6b72 100644 --- a/src/js/modules/qrcode-generator.js +++ b/src/js/modules/qrcode-generator.js @@ -213,8 +213,8 @@ export async function generateQRCodeLocal(data, size = DEFAULT_QR_SIZE, labels = const cellSize = Math.max(1, Math.floor(safeSize / (moduleCount + QR_MARGIN_MODULES))); const largeCellSize = Math.max(1, Math.floor(LARGE_PREVIEW_SIZE / (moduleCount + QR_MARGIN_MODULES))); - const imageUrl = qr.createDataURL(cellSize, 2); - const largeImageUrl = qr.createDataURL(largeCellSize, 2); + const imageUrl = qr.createDataURL(cellSize, cellSize * 4); + const largeImageUrl = qr.createDataURL(largeCellSize, largeCellSize * 4); console.log(`[QRCode] Local generation success: size=${safeSize}, modules=${moduleCount}, cellSize=${cellSize}`);