feat: Round start day time to nearest 15 minutes#53
Merged
Conversation
Create a reusable scroll-wheel time picker component that displays three scrollable columns (hour, minute, AM/PM) for intuitive time selection. Includes snap-to-item behavior, selection highlight band, fade overlays, and 24-hour format conversion. Also adds scrollbar-hide CSS utility for cross-browser hidden scrollbar support. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add 15-minute interval rounding to startDay function - Ensures first task aligns with rounded start time - Fix react-refresh linting warning in OfflineContext
Deploying timetrackerpro with
|
| Latest commit: |
e5b1f9f
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://5719eb26.timetrackerpro.pages.dev |
| Branch Preview URL: | https://date-time-picker-component.timetrackerpro.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds 15-minute interval rounding to the start day functionality, ensuring consistency with how new time entries are created.
Changes
startDayfunction that rounds to nearest 15-minute interval (0, 15, 30, or 45 minutes)react-refresh/only-export-componentslinting warningImplementation Details
The
startDayfunction now:Math.round(minutes / 15) * 15Examples
Testing
Since the first task automatically uses the
dayStartTime, it will also be aligned to the same 15-minute interval, maintaining consistency throughout the day.