For AI agents: the complete documentation index is available at https://rickyshin93.github.io/tao-ui/zh/llms.txt, the full documentation bundle is available at https://rickyshin93.github.io/tao-ui/zh/llms-full.txt, and this page is available as Markdown at https://rickyshin93.github.io/tao-ui/zh/components/calendar.md.
v0.0.57
  • 简体中文
  • Calendar

    数据展示@rockshin/tao-ui

    展示月份或年份,支持日程单元格、自定义页头与可选范围。

    新增 API 对齐 Ant Design 6.7.0,外观、主题与 Semantic DOM 使用 tao-ui。既有组件 API 保持原样。

    代码演示

    完整月历

    完整月历适合在单元格中展示日程。

    SuMoTuWeThFrSa
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    TSX

    卡片月历

    fullscreen=false 使用适合侧栏与卡片的紧凑布局。

    SuMoTuWeThFrSa
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    TSX

    受控选择与来源

    onSelect 区分日期点击与页头切换;onChange 更新当前日期。

    SuMoTuWeThFrSa
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12

    2026-11-04 · initial

    TSX

    日程单元格

    cellRender 在默认单元格内显示日程,保留原有日期交互。

    SuMoTuWeThFrSa
    01
    02
    03
    04
    Design review
    05
    06
    07
    08
    09
    10
    11
    12
    Team sync
    13
    14
    15
    16
    17
    18
    19
    20
    Team sync
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    Design review
    05
    06
    07
    08
    09
    10
    11
    12
    Team sync
    TSX

    有效范围

    范围限制页头导航与日期选择。

    SuMoTuWeThFrSa
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    TSX

    禁用周末

    disabledDate 接收 Dayjs;返回 true 的日期无法选择。

    SuMoTuWeThFrSa
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    TSX

    年份与周序号

    切换月历与年历,或为月历显示周序号。

    Jan
    Feb
    Mar
    Apr
    May
    Jun
    Jul
    Aug
    Sep
    Oct
    Nov
    Dec
    TSX

    自定义页头

    页头回调提供值和模式更新方法,可接入自己的业务工具栏。

    2026-11
    SuMoTuWeThFrSa
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    01
    02
    03
    04
    05
    06
    07
    08
    09
    10
    11
    12
    TSX

    手机与语言

    中文语言与紧凑月历继承提供者配置。

    390 × 640
    TSX

    API

    Calendar

    属性说明类型默认值
    className节点类名string | undefined-
    style节点样式CSSProperties | undefined-