Skip to content

bug: DateRangePicker calendar does not move ahead to the month of minSelectable date #727

@Abg4real

Description

@Abg4real

Describe the bug

When the date range provided by minSelectableDate and maxSelectableDate does not contain today's date, or next month's date in case of 2-months-view, the calendar does not move to months of that date range.

To Reproduce

  1. Add minSelectable date of 3 months from today.
  2. When selecting the date, calendar shows disabled dates.
  3. In order to select a valid date, the calendar needs to be forwarded to minSelectable month.
  4. If the minSelectable and maxSelectable are a month earlier than today's date, the error still persists.

Expected behavior

If the selectable date range starts in the previous or later month, then that month should be shown by default, when calendar selection is opened.

Screenshots

image

Package versions

  • @medly-components/core: 6.26.2
  • @medly-components/forms :
  • @medly-components/icons :
  • @medly-components/layout :
  • @medly-components/loaders :
  • @medly-components/theme :
  • @medly-components/utils :

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions