Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add mui time picker for timer input field in timer dialog #399

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dostulataa
Copy link
Collaborator

use time picker for timer input (allows faster input of time

Issue: #201

Comment on lines +29 to +30
const [minutes, setMinutes] = useState(remainingMinutes);
const [seconds, setSeconds] = useState(remainingSeconds);
Copy link
Collaborator

@NearW NearW Jun 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This state is always changed together, therefore it should be combined.

Suggested change
const [minutes, setMinutes] = useState(remainingMinutes);
const [seconds, setSeconds] = useState(remainingSeconds);
const [time, setTime] = useState<{minutes, seconds}>({minutes: remainingMinutes, seconds: remainingSeconds});

Copy link
Collaborator

@NearW NearW left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codewise everything is fine to me, but I actually prefer the old time picker more than the new one. I felt it more intuitive to work with the old one. Maybe we can collect some feedback from more users here?

@NearW NearW force-pushed the feature/201/time_picker_timer_input branch from 883ef94 to 14579e1 Compare June 26, 2024 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants