# Date 日期选择

日期选择器,支持日期和日期时间模式。

# 何时使用

  • 需要输入日期或日期范围时
  • 需要选择日期 + 时间时

# 代码演示

# API

参数 说明 类型 默认值
value 日期值 Moment \| string \| null -
format 日期格式 string 'YYYY-MM-DD HH:mm:ss'
showTime 是否显示时间选择 boolean false
mode 模式 'date' \| 'range' 'date'
placeholder 占位文本 string \| [string, string] -
disabled 是否禁用 boolean false
disabledDate 不可选择的日期 (current: Moment) => boolean -
allowClear 是否允许清除 boolean true

# 事件

事件名 说明 回调参数
change 日期变化时回调 (value: Moment \| null) => void