Treat 119.68 seconds as 1:59 instead of 1:60

This commit is contained in:
Travis Ralston 2021-04-27 23:07:45 -06:00
parent c2bcdae8a9
commit 617d74f9cd

View file

@ -42,7 +42,7 @@ export default class Clock extends React.Component<IProps, IState> {
public render() {
const minutes = Math.floor(this.props.seconds / 60).toFixed(0).padStart(2, '0');
const seconds = Math.round(this.props.seconds % 60).toFixed(0).padStart(2, '0'); // hide millis
const seconds = Math.floor(this.props.seconds % 60).toFixed(0).padStart(2, '0'); // hide millis
return <span className='mx_Clock'>{minutes}:{seconds}</span>;
}
}