Fix PDF status pill text centering for html2canvas

Replace flexbox-based centering (inline-flex, alignItems, justifyContent)
with explicit height + line-height matching (22px) for reliable rendering
in html2canvas. Flexbox properties don't render consistently when
converting HTML to canvas.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
michael 2026-01-27 14:54:48 -06:00
parent 5629d18df4
commit 1799902448

View file

@ -75,7 +75,7 @@ const RagStatusBadge: React.FC<{ status: RagStatus }> = ({ status }) => {
}
return (
<span style={{ backgroundColor: bgColor, color: textColor, padding: '4px 12px', borderRadius: '9999px', fontSize: '12px', fontWeight: 'bold', display: 'inline-flex', alignItems: 'center', justifyContent: 'center', minWidth: '50px', textAlign: 'center', lineHeight: 1 }}>
<span style={{ backgroundColor: bgColor, color: textColor, padding: '0 12px', borderRadius: '9999px', fontSize: '12px', fontWeight: 'bold', display: 'inline-block', minWidth: '50px', textAlign: 'center', height: '22px', lineHeight: '22px' }}>
{status}
</span>
);