fix: wrap animated pressure value in animated.span to prevent React error

This commit is contained in:
Thomas Hallock
2025-09-30 15:54:22 -05:00
parent 863a2e1319
commit 5c5954be74

View File

@@ -122,14 +122,17 @@ export function PressureGauge({ pressure }: PressureGaugeProps) {
</svg>
{/* Digital readout - animated */}
<animated.div style={{
<div style={{
textAlign: 'center',
fontSize: '20px',
fontWeight: 'bold',
color
fontWeight: 'bold'
}}>
{spring.pressure.to(p => Math.round(p))} <span style={{ fontSize: '12px' }}>PSI</span>
</animated.div>
<animated.span style={{ color }}>
{spring.pressure.to(p => Math.round(p))}
</animated.span>
{' '}
<span style={{ fontSize: '12px' }}>PSI</span>
</div>
</div>
)
}