afc163 3 years ago committed by GitHub
parent ad45f6c185
commit 4fe88a5577
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -14,14 +14,7 @@ When data is in the form of dates, such as schedules, timetables, prices calenda
## API
**Note:** Part of the Calendar's locale is read from `value`. So, please set the locale of `moment` correctly.
```jsx
// The default locale is en-US, if you want to use other locale, just set locale in entry file globally.
// import moment from 'moment';
// import 'moment/locale/zh-cn';
// moment.locale('zh-cn');
<Calendar
dateCellRender={dateCellRender}
monthCellRender={monthCellRender}
@ -51,3 +44,4 @@ When data is in the form of dates, such as schedules, timetables, prices calenda
## FAQ
- [How to use Calendar with customize date library like dayjs](/docs/react/replace-moment#Calendar)
- [How to set locale for date-related components](/components/date-picker/#Localization)

@ -15,14 +15,7 @@ cover: https://gw.alipayobjects.com/zos/antfincdn/dPQmLq08DI/Calendar.svg
## API
**注意:**Calendar 部分 locale 是从 value 中读取,所以请先正确设置 moment 的 locale。
```jsx
// 默认语言为 en-US所以如果需要使用其他语言推荐在入口文件全局设置 locale
// import moment from 'moment';
// import 'moment/locale/zh-cn';
// moment.locale('zh-cn');
<Calendar
dateCellRender={dateCellRender}
monthCellRender={monthCellRender}
@ -52,3 +45,4 @@ cover: https://gw.alipayobjects.com/zos/antfincdn/dPQmLq08DI/Calendar.svg
## FAQ
- [如何在 Calendar 中使用自定义日期库(如 dayjs ](/docs/react/replace-moment#Calendar)
- [如何给日期类组件配置国际化](/components/date-picker/#%E5%9B%BD%E9%99%85%E5%8C%96%E9%85%8D%E7%BD%AE)

Loading…
Cancel
Save