feat(sticker): much bigger text + QR +30%

wkhtmltopdf renders CSS font-size at a smaller physical scale
than the em-square math predicts (a "30pt" cell text was only
~4mm tall visually). Pushing all type up significantly so it
actually reads at scan/print distance:

Text bumps:
- Body field text 30pt -> 50pt (+67%, label + value)
- WO# 56pt -> 72pt (+29%)
- Notes label 30pt -> 44pt
- Notes content 22pt -> 30pt (+36%)
- Muted rev tag 22pt -> 30pt
- Body cell padding 0 10px -> 0 8px (a touch more horizontal
  room for long values now that the font is bigger)

QR + 30% as asked:
- Wrapper 280 -> 365px (+30.4%). Image 368 -> 480px, offset
  -44 -> -58px (recomputed for the new quiet-zone crop).

Header re-balanced for the bigger content:
- Height 25% -> 32% (fits the +30% QR + bigger WO# + bigger
  logo at 135px)
- Body band: 75% -> 68% (rows now ~9.6mm tall; line-height
  1.0 keeps the 50pt body text snug inside)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
gsinghpal
2026-05-12 23:48:40 -04:00
parent 649b75d4a1
commit 64c61dcca8
2 changed files with 22 additions and 27 deletions

View File

@@ -3,7 +3,7 @@
# License OPL-1 (Odoo Proprietary License v1.0) # License OPL-1 (Odoo Proprietary License v1.0)
{ {
'name': 'Fusion Plating — Reports', 'name': 'Fusion Plating — Reports',
'version': '19.0.10.7.0', 'version': '19.0.10.8.0',
'category': 'Manufacturing/Plating', 'category': 'Manufacturing/Plating',
'summary': 'PDF reports for Fusion Plating: quote, SO, WO, packing, BoL, CoC, invoice, receipt, quality + compliance.', 'summary': 'PDF reports for Fusion Plating: quote, SO, WO, packing, BoL, CoC, invoice, receipt, quality + compliance.',
'depends': [ 'depends': [

View File

@@ -112,13 +112,11 @@
page-break-inside: avoid; page-break-inside: avoid;
} }
/* ---- HEADER band: 3 horizontal cells, divided by vertical /* ---- HEADER band: 3 horizontal cells, divided by vertical
rules. Logo / WO# / QR. Trimmed from 30% to 25% so rules. Logo / WO# / QR. 32% to fit the +30% QR. ---- */
the body band (which holds 7 rows) gets more vertical
room — needed for the bigger field font. ---- */
.fp-sticker-head-wrap { .fp-sticker-head-wrap {
position: absolute; position: absolute;
left: 0; right: 0; top: 0; left: 0; right: 0; top: 0;
height: 25%; height: 32%;
border-bottom: 2px solid #000; border-bottom: 2px solid #000;
box-sizing: border-box; box-sizing: border-box;
} }
@@ -140,13 +138,13 @@
td.fp-sticker-head-logo { border-right: 2px solid #000; padding: 0 6px; } td.fp-sticker-head-logo { border-right: 2px solid #000; padding: 0 6px; }
td.fp-sticker-head-wo { border-right: 2px solid #000; } td.fp-sticker-head-wo { border-right: 2px solid #000; }
.fp-sticker-logo { .fp-sticker-logo {
max-height: 105px; max-height: 135px;
max-width: 95%; max-width: 95%;
display: inline-block; display: inline-block;
vertical-align: middle; vertical-align: middle;
} }
.fp-sticker-wo { .fp-sticker-wo {
font-size: 56pt; font-size: 72pt;
font-weight: 900; font-weight: 900;
letter-spacing: 0.1mm; letter-spacing: 0.1mm;
line-height: 1; line-height: 1;
@@ -156,32 +154,29 @@
/* QR wrapper crops the ~12% quiet-zone the barcode generator /* QR wrapper crops the ~12% quiet-zone the barcode generator
adds around the QR pattern. We render the image larger than adds around the QR pattern. We render the image larger than
the wrapper and offset so the wrapper clips that border out. the wrapper and offset so the wrapper clips that border out.
Wrapper 280px = ~23.7mm at 300dpi → fits the 25% header Wrapper 365px = ~30.9mm at 300dpi (30% larger than the
band. High-def source (600x600) means it still prints previous 280px). 600x600 source = high-def at print scale. ---- */
crisp at this size. ---- */
.fp-sticker-qr-wrap { .fp-sticker-qr-wrap {
width: 280px; width: 365px;
height: 280px; height: 365px;
display: inline-block; display: inline-block;
position: relative; position: relative;
overflow: hidden; overflow: hidden;
} }
.fp-sticker-qr { .fp-sticker-qr {
width: 368px; width: 480px;
height: 368px; height: 480px;
position: absolute; position: absolute;
top: -44px; top: -58px;
left: -44px; left: -58px;
margin: 0; margin: 0;
display: block; display: block;
} }
/* ---- BODY band: left fields region + right Notes region. /* ---- BODY band: left fields region + right Notes region. ---- */
75% of page height so the 7 rows can each be ~10.6mm
tall, fitting 30pt field text with breathing room. ---- */
.fp-sticker-body-wrap { .fp-sticker-body-wrap {
position: absolute; position: absolute;
left: 0; right: 0; left: 0; right: 0;
top: 25%; bottom: 0; top: 32%; bottom: 0;
} }
.fp-body-left { .fp-body-left {
position: absolute; position: absolute;
@@ -209,8 +204,8 @@
col.fp-col-value { width: 62%; } col.fp-col-value { width: 62%; }
table.fp-sticker-body td { table.fp-sticker-body td {
vertical-align: middle; vertical-align: middle;
padding: 0 10px; padding: 0 8px;
font-size: 30pt; font-size: 50pt;
line-height: 1.0; line-height: 1.0;
} }
td.fp-sticker-label { td.fp-sticker-label {
@@ -225,16 +220,16 @@
white-space: nowrap; white-space: nowrap;
} }
.fp-sticker-strong { font-weight: 700; } .fp-sticker-strong { font-weight: 700; }
.fp-sticker-muted { color: #555; font-size: 22pt; } .fp-sticker-muted { color: #555; font-size: 30pt; }
/* Notes column on the right side of the body. */ /* Notes column on the right side of the body. */
.fp-notes-label { .fp-notes-label {
font-weight: 700; font-weight: 700;
font-size: 30pt; font-size: 44pt;
margin: 0 0 8px 0; margin: 0 0 10px 0;
} }
.fp-notes-content { .fp-notes-content {
font-size: 22pt; font-size: 30pt;
line-height: 1.2; line-height: 1.15;
white-space: pre-line; white-space: pre-line;
word-wrap: break-word; word-wrap: break-word;
overflow: hidden; overflow: hidden;