-
-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update WeekTimeline.vue #192
base: master
Are you sure you want to change the base?
Conversation
fix: When { locale: ‘zh-CN’ }, the weekly mode is displayed abnormally
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for adding this. I hadn't noticed that the day names are completely off in Chinese! I appreciate your contribution.
Here a couple of suggestions for improving semantic clarity.
Also this will need unit tests (in WeekTimeline.test.ts
). Do you want to add them yourself? If not, I can also do it.
@@ -89,6 +89,10 @@ export default defineComponent({ | |||
|
|||
return date; | |||
}, | |||
getWeekTimeStr(day: dayInterface) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
getWeekTimeStr(day: dayInterface) { | |
getDayName(day: dayInterface) { |
@@ -89,6 +89,10 @@ export default defineComponent({ | |||
|
|||
return date; | |||
}, | |||
getWeekTimeStr(day: dayInterface) { | |||
const isCN = this.config?.locale?.toLowerCase() === 'zh-cn'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const isCN = this.config?.locale?.toLowerCase() === 'zh-cn'; | |
const isChinese = this.config?.locale?.toLowerCase() === 'zh-cn'; |
fix: When { locale: ‘zh-CN’ }, the weekly mode is displayed abnormally
Checklist
Please put "X" in the below checkboxes that apply::
I have tested the following:
This PR solves the following problem**.
insert your description.
How to test this PR**.
For example: