diff --git a/components/calendar/generateCalendar.tsx b/components/calendar/generateCalendar.tsx index c3a866da6..9107d5634 100644 --- a/components/calendar/generateCalendar.tsx +++ b/components/calendar/generateCalendar.tsx @@ -86,7 +86,7 @@ function generateCalendar< ); } - const Calendar = defineComponent({ + const Calendar = defineComponent({ name: 'ACalendar', inheritAttrs: false, props: { @@ -120,7 +120,7 @@ function generateCalendar< onPanelChange: { type: Function as PropType, default: undefined }, onSelect: { type: Function as PropType, default: undefined }, valueFormat: { type: String, default: undefined }, - }, + } as any, slots: Object as CustomSlotsType<{ dateFullCellRender?: { current: DateType }; dateCellRender?: { current: DateType }; diff --git a/components/time-picker/time-picker.tsx b/components/time-picker/time-picker.tsx index 33c735247..a3d61ba11 100644 --- a/components/time-picker/time-picker.tsx +++ b/components/time-picker/time-picker.tsx @@ -85,15 +85,15 @@ function createTimePicker< }); const { TimePicker: InternalTimePicker, RangePicker: InternalRangePicker } = DatePicker as any; - const TimePicker = defineComponent({ + const TimePicker = defineComponent({ name: 'ATimePicker', inheritAttrs: false, props: { - ...commonProps(), - ...datePickerProps(), + ...commonProps(), + ...datePickerProps(), ...timePickerProps(), addon: { type: Function }, - }, + } as any, slots: Object as CustomSlotsType<{ addon?: any; renderExtraFooter?: any; @@ -163,15 +163,15 @@ function createTimePicker< }, }); - const TimeRangePicker = defineComponent({ + const TimeRangePicker = defineComponent({ name: 'ATimeRangePicker', inheritAttrs: false, props: { - ...commonProps(), - ...rangePickerProps(), + ...commonProps(), + ...rangePickerProps(), ...timePickerProps(), order: { type: Boolean, default: true }, - }, + } as any, slots: Object as CustomSlotsType<{ renderExtraFooter?: any; suffixIcon?: any;