import { defineComponent , PropType } from 'vue' ; import { TimePickerProps } from '../../time-picker/interface' ; import { DisabledTimeProps , DatePickerProps } from '../interface' ; import Picker from '../picker.vue' ; export default defineComponent ( { name : 'DatePicker' , props : { zh en modelValue : { type : [ Object , String , Number ] as PropType < Date | string | number > } , zh en defaultValue : { type : [ Object , String , Number ] as PropType < Date | string | number > } , zh en format : { type : [ String , Function ] as PropType < string | ( ( current : Date ) => string ) > } , zh en type number dayStartOfWeek : { type : Number as PropType < 0 | 1 > , default : 0 } , zh en showTime : { type : Boolean } , zh en timepickerProps : { type : Object as PropType < Partial < TimePickerProps > > } , zh en disabledTime : { type : Function as PropType < ( current : Date ) => DisabledTimeProps > } , zh en showNowBtn : { type : Boolean , default : true } } , setup ( props , { attrs , slots } ) { return ( ) => < Picker { ... props } { ... attrs } mode = "date" v - slots = { slots } / > ; } } ) ;