mirror of
https://gitee.com/ant-design-vue/ant-design-vue.git
synced 2024-12-02 12:07:54 +08:00
29 lines
939 B
Vue
29 lines
939 B
Vue
import type { Dayjs } from 'dayjs';
|
|
import createTimePicker from './time-picker';
|
|
import dayjsGenerateConfig from '../vc-picker/generate/dayjs';
|
|
import type { App } from 'vue';
|
|
import type { PickerTimeProps, RangePickerTimeProps } from '../date-picker/generatePicker';
|
|
|
|
const { TimePicker, TimeRangePicker } = createTimePicker<Dayjs>(dayjsGenerateConfig);
|
|
|
|
export interface TimeRangePickerProps extends Omit<RangePickerTimeProps<Dayjs>, 'picker'> {
|
|
popupClassName?: string;
|
|
valueFormat?: string;
|
|
}
|
|
export interface TimePickerProps extends Omit<PickerTimeProps<Dayjs>, 'picker'> {
|
|
popupClassName?: string;
|
|
valueFormat?: string;
|
|
}
|
|
|
|
/* istanbul ignore next */
|
|
export { TimePicker, TimeRangePicker };
|
|
export default Object.assign(TimePicker, {
|
|
TimePicker,
|
|
TimeRangePicker,
|
|
install: (app: App) => {
|
|
app.component(TimePicker.name, TimePicker);
|
|
app.component(TimeRangePicker.name, TimeRangePicker);
|
|
return app;
|
|
},
|
|
});
|