prevent the counter from wiggling when the time changes

This commit is contained in:
MarconLP 2023-04-19 00:46:23 +02:00
parent 4b46ed7b4b
commit 70a484a270
No known key found for this signature in database
GPG key ID: A08A9C8B623F5EA5

View file

@ -31,5 +31,9 @@ export default function StopTime({ running }: { running?: boolean }) {
return () => clearInterval(interval);
}, [running]);
return <span className="ml-1 text-sm">{calculateTimeDuration(secs)}</span>;
return (
<div className="ml-1 flex w-10 items-center justify-center">
<span className="text-sm">{calculateTimeDuration(secs)}</span>
</div>
);
}