better pdf spaces
All checks were successful
Build Images and Deploy / Update-PROD-Stack (push) Successful in 28s
All checks were successful
Build Images and Deploy / Update-PROD-Stack (push) Successful in 28s
This commit is contained in:
@@ -65,17 +65,20 @@ async function generateHuntPDF(hunt, packages, baseUrl, outputStream) {
|
|||||||
// Text column (monospace)
|
// Text column (monospace)
|
||||||
const textX = x + qrSize + 20;
|
const textX = x + qrSize + 20;
|
||||||
const textW = cardW - qrSize - 30;
|
const textW = cardW - qrSize - 30;
|
||||||
const textBlockH = 64;
|
const textBlockH = 80;
|
||||||
const textY = y + (cardH - textBlockH) / 2;
|
const textY = y + (cardH - textBlockH) / 2;
|
||||||
|
|
||||||
doc.fontSize(18).font('Helvetica-Bold').fillColor('#1a1a1a');
|
doc.fontSize(16).font('Helvetica-Bold').fillColor('#1a1a1a');
|
||||||
doc.text(`${pkg.card_number} of ${totalPackages}`, textX, textY, { width: textW, align: 'center' });
|
doc.text('LOOT HUNT', textX, textY, { width: textW, align: 'center' });
|
||||||
|
|
||||||
|
doc.fontSize(14).font('Helvetica').fillColor('#666666');
|
||||||
|
doc.text(`${pkg.card_number} of ${totalPackages}`, textX, textY + 20, { width: textW, align: 'center' });
|
||||||
|
|
||||||
doc.fontSize(12).font('Helvetica').fillColor('#666666');
|
doc.fontSize(12).font('Helvetica').fillColor('#666666');
|
||||||
doc.text(hunt.short_name, textX, textY + 24, { width: textW, align: 'center' });
|
doc.text(hunt.short_name, textX, textY + 50, { width: textW, align: 'center' });
|
||||||
|
|
||||||
doc.fontSize(14).font('Helvetica-Bold').fillColor('#333333');
|
doc.fontSize(14).font('Helvetica-Bold').fillColor('#333333');
|
||||||
doc.text(pkg.unique_code, textX, textY + 44, { width: textW, align: 'center' });
|
doc.text(pkg.unique_code, textX, textY + 66, { width: textW, align: 'center' });
|
||||||
}
|
}
|
||||||
|
|
||||||
// ──── BACK PAGE (mirrored column order for double-sided printing) ────
|
// ──── BACK PAGE (mirrored column order for double-sided printing) ────
|
||||||
@@ -84,7 +87,7 @@ async function generateHuntPDF(hunt, packages, baseUrl, outputStream) {
|
|||||||
const backLines = [
|
const backLines = [
|
||||||
'THIS CARD IS UNIQUE',
|
'THIS CARD IS UNIQUE',
|
||||||
'',
|
'',
|
||||||
'IF YOU DO NOT USE IT PLEASE',
|
'IF YOU DO NOT WANT TO PLAY',
|
||||||
'PUT IT SOMEWHERE INTERESTING',
|
'PUT IT SOMEWHERE INTERESTING',
|
||||||
'FOR THE NEXT PERSON TO FIND',
|
'FOR THE NEXT PERSON TO FIND',
|
||||||
'',
|
'',
|
||||||
|
|||||||
Reference in New Issue
Block a user