From c4231aeb590fd4f37f694816861013e907536c84 Mon Sep 17 00:00:00 2001 From: Melloware Date: Tue, 12 Dec 2023 08:06:32 -0500 Subject: [PATCH] Fix #5574: Calendar Tailwind context.selected val (#5583) --- components/lib/calendar/Calendar.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/lib/calendar/Calendar.js b/components/lib/calendar/Calendar.js index 8d3a243d12..8d8ba5d4d1 100644 --- a/components/lib/calendar/Calendar.js +++ b/components/lib/calendar/Calendar.js @@ -3659,14 +3659,14 @@ export const Calendar = React.memo( className: cx('month', { isMonthSelected, isSelectable, i, currentYear }), onClick: (event) => onMonthSelect(event, i), onKeyDown: (event) => onMonthCellKeydown(event, i), - 'data-p-disabled': !m.selectable, + 'data-p-disabled': !isSelectable(0, i, currentYear), 'data-p-highlight': isMonthSelected(i) }, ptm('month', { context: { month: m, monthIndex: i, - disabled: !m.selectable, + disabled: !isSelectable(0, i, currentYear), selected: isMonthSelected(i) } })