mirror of
https://github.com/element-plus/element-plus.git
synced 2026-03-13 07:51:17 +08:00
20 lines
554 B
TypeScript
20 lines
554 B
TypeScript
import DatePickPanel from './date-picker-com/panel-date-pick.vue'
|
|
import DateRangePickPanel from './date-picker-com/panel-date-range.vue'
|
|
import MonthRangePickPanel from './date-picker-com/panel-month-range.vue'
|
|
import type { IDatePickerType } from './date-picker.type'
|
|
|
|
export const getPanel = function (type: IDatePickerType) {
|
|
switch (type) {
|
|
case 'daterange':
|
|
case 'datetimerange': {
|
|
return DateRangePickPanel
|
|
}
|
|
case 'monthrange': {
|
|
return MonthRangePickPanel
|
|
}
|
|
default: {
|
|
return DatePickPanel
|
|
}
|
|
}
|
|
}
|