Calendar month picker: Disable/'gray out' past months

UI Components for Vue
Post Reply
PlacebO
Posts: 1
Joined: 01 Dec 2022, 11:01

01 Dec 2022, 11:22

Hey,

I am using a the calendar to select a month and year.

Code: Select all

      <Calendar
        v-model="flexibleDates.date"
        :show-button-bar="true"
        date-format="dd.mm.yy"
        :min-date="minDate".   // <= current date.
        :max-date="maxDate"
        :inline="true"
        view="month"
      />
Past months are already disabled, however if you click on a month in the past it will be highlighted for a split second before jumping to the current month (also january is always selected when the component is mounted even if it's out of the min/max-date range).
I was wondering if there is a way to gray out past months/make the user unable to even click on them.
Seems like there are no slotProps if you're using the month picker(?).

Any help is appreciated!

tugce.kucukoglu
Posts: 560
Joined: 23 Oct 2020, 09:28

14 Dec 2022, 15:44

Hi,

Could you send us a reproducer link?

Post Reply

Return to “PrimeVue”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 5 guests