- {{ t(globalConfig.monthTitle, { year: item.year, month: item.month }) }}
+ {{ t(globalConfig.monthTitle, { year: item.year, month: globalConfig.months[item.month] }) }}
diff --git a/src/config-provider/config-provider.en-US.md b/src/config-provider/config-provider.en-US.md
index 61b328974..1ae3057f0 100644
--- a/src/config-provider/config-provider.en-US.md
+++ b/src/config-provider/config-provider.en-US.md
@@ -1,8 +1,8 @@
---
-title: ConfigProvider
-description: The global attribute configuration contains the text language configuration of each component and other common configurations to reduce duplicate common configurations.
-spline: base
+title: "Global property configuration"
+description: "The global attribute configuration contains the text language configuration of each component and other common configurations to reduce duplicate common configurations."
isComponent: true
+tdDocTabs: [{ tab: 'demo', name: '示例' }, { tab: 'api', name: 'API' }]
toc: false
---
@@ -18,6 +18,10 @@ English | `en_US`
If you want to contribute more language packs, please refer to [How to add a language pack](https://github.com/Tencent/tdesign-common/blob/develop/js/global-config/locale/CONTRIBUTING.md) PR.
+### Upload
+
+{{ upload-en }}
+
### Table
{{ table-en }}
diff --git a/src/config-provider/config-provider.md b/src/config-provider/config-provider.md
index b77f95a5b..f99f238ed 100644
--- a/src/config-provider/config-provider.md
+++ b/src/config-provider/config-provider.md
@@ -1,8 +1,9 @@
---
-title: ConfigProvider 全局配置
+title: 全局特性配置
description: 全局特性配置包含各个组件的文本语言配置及其他通用配置,可以减少重复的通用配置。
spline: base
isComponent: true
+tdDocTabs: [{ tab: 'demo', name: '示例' }, { tab: 'api', name: 'API' }]
toc: false
---
diff --git a/src/config-provider/context.ts b/src/config-provider/context.ts
index 1861af1de..7c376353f 100644
--- a/src/config-provider/context.ts
+++ b/src/config-provider/context.ts
@@ -6,12 +6,6 @@ import defaultConfig from '../locale/default-config';
import defaultZhLocale from '../locale/zh_CN';
import { GlobalConfigProvider } from './type';
-export enum EAnimationType {
- ripple = 'ripple',
- expand = 'expand',
- fade = 'fade',
-}
-
export const defaultGlobalConfig = merge(defaultConfig, defaultZhLocale);
export type Locale = typeof defaultZhLocale;
diff --git a/src/config-provider/type.ts b/src/config-provider/type.ts
index 4753b24ee..4e55e1142 100644
--- a/src/config-provider/type.ts
+++ b/src/config-provider/type.ts
@@ -72,6 +72,7 @@ export interface CalendarConfig {
title?: string;
weekdays?: string[];
monthTitle?: string;
+ months?: string[];
}
export interface CascaderConfig {
title?: string;
diff --git a/src/locale/en_US.ts b/src/locale/en_US.ts
index 6c3b59edd..d122ae417 100644
--- a/src/locale/en_US.ts
+++ b/src/locale/en_US.ts
@@ -7,9 +7,23 @@ export default {
},
calendar: {
confirm: 'Confirm',
- title: 'Select date',
+ title: 'Select Date',
weekdays: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
- monthTitle: '{year} / {month}',
+ monthTitle: '{month} {year}',
+ months: [
+ 'January',
+ 'February',
+ 'March',
+ 'April',
+ 'May',
+ 'June',
+ 'July',
+ 'August',
+ 'September',
+ 'October',
+ 'November',
+ 'December',
+ ],
},
cascader: {
title: 'Title',
@@ -20,7 +34,7 @@ export default {
confirm: 'Confirm',
},
dateTimePicker: {
- title: 'Select date',
+ title: 'Select Date',
cancel: 'Cancel',
confirm: 'Confirm',
format: 'YYYY-MM-DD',
diff --git a/src/locale/zh_CN.ts b/src/locale/zh_CN.ts
index 51fd821ef..ed616202c 100644
--- a/src/locale/zh_CN.ts
+++ b/src/locale/zh_CN.ts
@@ -9,7 +9,8 @@ export default {
title: '请选择日期',
confirm: '确认',
weekdays: ['日', '一', '二', '三', '四', '五', '六'],
- monthTitle: '{year} 年 {month} 月',
+ monthTitle: '{year} 年 {month}',
+ months: ['1 月', '2 月', '3 月', '4 月', '5 月', '6 月', '7 月', '8 月', '9 月', '10 月', '11 月', '12 月'],
},
cascader: {
title: '标题',