fix(badges): shrink punch-hole markers horizontally, add inset_x_mm config
Default horizontal inset increased from 1mm to 2mm per side (width shrinks by 4mm total) so markers stay inside the physical hole slot on all printers and badge stock with minor registration variance. Vertical stays at 1mm. The inset is now driven by punch_holes_inset_x (template_cfg.punch_holes .inset_x_mm, default 2) so it can be tuned per template without a code change. Added inset_x_mm field to AeBadgeTemplateCfg type with doc comment. All 9 slot marker divs (6 rainbow + 3 solid) updated via replace_all. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -76,6 +76,10 @@ export interface BadgeTemplateCfg {
|
||||
center_bg?: string;
|
||||
center_rainbow?: boolean;
|
||||
slow_pulse?: boolean; // when true: slow breathing pulse instead of fast linear cycle
|
||||
// Extra horizontal inset per side (mm) beyond the 1mm base safety margin.
|
||||
// Shrinks the visible marker width to keep it inside the physical hole on
|
||||
// printers or badge stock with variance. Default 2 when unset (see view component).
|
||||
inset_x_mm?: number;
|
||||
};
|
||||
|
||||
// Allow arbitrary extra keys to preserve forward-compatibility.
|
||||
|
||||
Reference in New Issue
Block a user