From b4a4f386b87272b23b19151e2a068bae4e40febf Mon Sep 17 00:00:00 2001 From: Kermit Date: Sun, 20 Dec 2020 13:05:26 +0800 Subject: [PATCH] fix: decade panr --- src/panels/DecadePanel/DecadeBody.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/panels/DecadePanel/DecadeBody.tsx b/src/panels/DecadePanel/DecadeBody.tsx index e0e90f198..4a8020abf 100644 --- a/src/panels/DecadePanel/DecadeBody.tsx +++ b/src/panels/DecadePanel/DecadeBody.tsx @@ -16,7 +16,7 @@ export interface YearBodyProps { function DecadeBody(props: YearBodyProps) { const DECADE_UNIT_DIFF_DES = DECADE_UNIT_DIFF - 1; - const { prefixCls, viewDate, generateConfig, disabledDate } = props; + const { prefixCls, viewDate, generateConfig } = props; const cellPrefixCls = `${prefixCls}-cell`; @@ -35,13 +35,10 @@ function DecadeBody(props: YearBodyProps) { ); const getCellClassName = (date: DateType) => { - const disabled = disabledDate && disabledDate(date); - const startDecadeNumber = generateConfig.getYear(date); const endDecadeNumber = startDecadeNumber + DECADE_UNIT_DIFF_DES; return { - [`${cellPrefixCls}-disabled`]: disabled, [`${cellPrefixCls}-in-view`]: startDecadeYear <= startDecadeNumber && endDecadeNumber <= endDecadeYear, [`${cellPrefixCls}-selected`]: startDecadeNumber === decadeYearNumber,