feat(datepicker): Added a "week" date picker type #666
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 is a new feature. I've needed support for selecting a full week for a given date instead of an arbitrary range. Thought this might also be useful for others considering that various date picker libraries also support this.
What is the new behavior?
When picker property "type" is set to "week" hovering on a single date will highlight the full week that date belongs to (adhering to specified 'firstDayOfWeek' value).
Selecting a week this way will select all the dates in the week as opposed to the just the last and first dates as in the range date picker (see attached screenshot). This seemed more intuitive to me; i.e. if an user click on Wednesday only having Mon, Sun directly selected and just highlighting the days in between felt strange to me (also I needed a full list of dates in my use case anyway..). If others disagree I can make this behave the same way as the "range" picker.
Checklist:
No documentation, tests or support for locales other than 'en-US' will add that in an updated PR (assuming that you agree that this feature should be added at all

).