= {
- [NoDataType.BattlesInPeriod]: 'No battles played in this period',
- [NoDataType.PlayersInPeriod]: 'No players in this period',
- [NoDataType.TanksFound]: 'No tanks found',
-};
+export default function NoData({ type, locale }: NoDataProps) {
+ const { translate } = translator(locale);
-export default function NoData({ type }: NoDataProps) {
return (
- {NO_DATA_MESSAGES[type]}
+ {translate(`bot.common.no_data.${type}`)}
);
diff --git a/src/lang/en-US.json b/src/lang/en-US.json
index be0637bba..efdf3ff25 100644
--- a/src/lang/en-US.json
+++ b/src/lang/en-US.json
@@ -90,6 +90,12 @@
"filters": {
"none": "No filters",
"tier": "Tier %s"
+ },
+
+ "no_data": {
+ "battles_in_period": "No battles played in this period",
+ "players_in_period": "No players in this period",
+ "tanks_found": "No tanks found"
}
},