diff --git a/ui/chart/src/chart.ratingDistribution.ts b/ui/chart/src/chart.ratingDistribution.ts index dc352f5cdf861..f332ae7f81a0c 100644 --- a/ui/chart/src/chart.ratingDistribution.ts +++ b/ui/chart/src/chart.ratingDistribution.ts @@ -46,7 +46,7 @@ export async function initModule(data: DistributionData): Promise { ...seriesCommonData('#dddf0d'), data: cumul, yAxisID: 'y2', - label: data.i18n.cumulative, + label: i18n.site.cumulative, pointRadius: 0, datalabels: { display: false }, pointHitRadius: 200, @@ -57,7 +57,7 @@ export async function initModule(data: DistributionData): Promise { backgroundColor: gradient, yAxisID: 'y', fill: true, - label: data.i18n.players, + label: i18n.site.players, pointRadius: 4, datalabels: { display: false }, pointHitRadius: 200, @@ -85,7 +85,7 @@ export async function initModule(data: DistributionData): Promise { }, }); if (data.myRating && data.myRating <= maxRating) - pushLine('#55bf3b', data.myRating, `${data.i18n.yourRating} (${data.myRating})`); + pushLine('#55bf3b', data.myRating, `${i18n.site.yourRating} (${data.myRating})`); if (data.otherRating && data.otherPlayer) { pushLine('#eeaaee', Math.min(data.otherRating, maxRating), `${data.otherPlayer} (${data.otherRating})`); } @@ -114,7 +114,7 @@ export async function initModule(data: DistributionData): Promise { }, title: { display: true, - text: data.i18n.glicko2Rating, + text: i18n.site.glicko2Rating, }, }, y: { @@ -127,7 +127,7 @@ export async function initModule(data: DistributionData): Promise { }, title: { display: true, - text: data.i18n.players, + text: i18n.site.players, }, }, y2: { @@ -143,7 +143,7 @@ export async function initModule(data: DistributionData): Promise { }, title: { display: true, - text: data.i18n.cumulative, + text: i18n.site.cumulative, }, }, }, diff --git a/ui/chart/src/interface.ts b/ui/chart/src/interface.ts index 799f9593ea147..d9a122bfe8907 100644 --- a/ui/chart/src/interface.ts +++ b/ui/chart/src/interface.ts @@ -52,12 +52,6 @@ export interface ChartGame { export interface DistributionData { freq: number[]; - i18n: { - cumulative: string; - glicko2Rating: string; - players: string; - yourRating: string; - }; myRating: number | null; otherPlayer: string | null; otherRating: number | null;