Introducing Dateslider and DateRangeSlider#177
Open
slootsjj wants to merge 6 commits intomathworks:masterfrom
Open
Introducing Dateslider and DateRangeSlider#177slootsjj wants to merge 6 commits intomathworks:masterfrom
slootsjj wants to merge 6 commits intomathworks:masterfrom
Conversation
- Fixed bugs for ValueIndex - Removed event LimitsChanged as it was not triggered.
Member
|
@slootsjj thank you for your contribution and my apologies I've not had a chance to review yet. It is still on my task list and I hopefully will have some time in a couple weeks. |
rjackey
requested changes
Feb 12, 2026
Member
rjackey
left a comment
There was a problem hiding this comment.
@slootsjj these are nice contributions, thank you!
In testing these out I am getting an issue with onSliderChanging of DateRangeSlider when dragging.
It seems the round() might put the date outside the limits?
Error using matlab.ui.control.DatePicker/set.Value (line 148)
'Value' must be a finite datetime object within the range of 'Limits' or NaT.
Error in wt.DateRangeSlider/onSliderChanging (line 452)
obj.DatepickerLeft.Value = changedDate(1);
^^^^^^^^^^^^^^^^^^^^^^^^
Error in wt.DateRangeSlider>@(h,e)obj.onSliderChanging(e) (line 274)
obj.Slider.ValueChangingFcn = @(h,e)obj.onSliderChanging(e);
Also just a note if you like you can add app designer metadata, or I can try to do so later.
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.
This PR introduces two date UI widgets. They combine native sliders with non-editable date pickers for day-level selection with consistent formatting and events.
New components
1. DateSlider — single-date selector with:
2. DateRangeSlider — two-date range selector with:
UX & behavior
Tick labels auto-scale from limits using the chosen DisplayFormat
Arrow buttons step by property Step (a calendarDuration) and auto-disable at bounds
Additional note
Rationale
Provides a consistent, accessible way to pick single dates or ranges with clear ticks, bounded interactions, and unified events.