File tree 2 files changed +16
-2
lines changed
2 files changed +16
-2
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,14 @@ const locale = {
8
8
weekdays : '星期日_星期一_星期二_星期三_星期四_星期五_星期六' . split ( '_' ) ,
9
9
weekdaysShort : '週日_週一_週二_週三_週四_週五_週六' . split ( '_' ) ,
10
10
weekdaysMin : '日_一_二_三_四_五_六' . split ( '_' ) ,
11
- ordinal : n => `${ n } 日` ,
11
+ ordinal : ( number , period ) => {
12
+ switch ( period ) {
13
+ case 'W' :
14
+ return `${ number } 週`
15
+ default :
16
+ return `${ number } 日`
17
+ }
18
+ } ,
12
19
formats : {
13
20
LT : 'HH:mm' ,
14
21
LTS : 'HH:mm:ss' ,
Original file line number Diff line number Diff line change @@ -8,7 +8,14 @@ const locale = {
8
8
weekdaysMin : '日_一_二_三_四_五_六' . split ( '_' ) ,
9
9
months : '一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月' . split ( '_' ) ,
10
10
monthsShort : '1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月' . split ( '_' ) ,
11
- ordinal : n => `${ n } 日` ,
11
+ ordinal : ( number , period ) => {
12
+ switch ( period ) {
13
+ case 'W' :
14
+ return `${ number } 週`
15
+ default :
16
+ return `${ number } 日`
17
+ }
18
+ } ,
12
19
formats : {
13
20
LT : 'HH:mm' ,
14
21
LTS : 'HH:mm:ss' ,
You can’t perform that action at this time.
0 commit comments