Skip to content

Commit

Permalink
fix: Adjust the threshold for smaller font size in metric card. (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
bourquep authored Dec 22, 2024
1 parent bab7a2e commit a4849c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/CurrentMetricCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export default function CurrentMetricCard(props: CurrentMetricCardProps) {
<Stack direction="row" alignItems="center" spacing={1}>
{/* Current value */}
{props.metricKind === 'number' && (
<Typography variant={(formattedCurrentValue?.length ?? 0) < 5 ? 'h1' : 'h2'} sx={{ fontWeight: '500' }}>
<Typography variant={(formattedCurrentValue?.length ?? 0) <= 5 ? 'h1' : 'h2'} sx={{ fontWeight: '500' }}>
{formattedCurrentValue}
</Typography>
)}
Expand Down

0 comments on commit a4849c8

Please sign in to comment.