Skip to content

Commit

Permalink
small fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Gk0Wk committed Sep 21, 2023
1 parent a4fc0e3 commit 7f9f81c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/echarts/addons/Gk0Wk/GitHubHeatMap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,11 +133,12 @@ const GitHubHeatMapAddon: IScriptAddon<any> = {
return cache;
};
const darkMode = checkIfDarkMode();
const chinese = checkIfChinese();
myChart.setOption({
title: {
top: 0,
left: 'center',
text: checkIfChinese()
text: chinese
? `今年产出 ${total} 篇文章`
: `Produced ${total} tiddlers this year`,
},
Expand Down Expand Up @@ -184,11 +185,11 @@ const GitHubHeatMapAddon: IScriptAddon<any> = {
},
dayLabel: {
show: true,
nameMap: checkIfChinese() ? 'ZH' : 'EN',
nameMap: chinese ? 'ZH' : 'EN',
},
monthLabel: {
show: true,
nameMap: checkIfChinese() ? 'ZH' : 'EN',
nameMap: chinese ? 'ZH' : 'EN',
},
yearLabel: {
show: true,
Expand Down

0 comments on commit 7f9f81c

Please sign in to comment.