pause method
void
pause()
Pauses the active timer and persists the current state.secondsRemaining
to local storage.
Implementation
void pause() {
_timer?.cancel();
storageManager.timerStorage.saveSeconds(state.secondsRemaining);
emit(
TimerState(
secondsRemaining: state.secondsRemaining,
isRunning: false,
isPaused: true,
),
);
}