-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29414 from smoogipoo/fix-daily-challenge-2
Add localisation for daily challenge day/week units
- Loading branch information
Showing
3 changed files
with
33 additions
and
8 deletions.
There are no files selected for viewing
24 changes: 24 additions & 0 deletions
24
osu.Game/Localisation/DailyChallengeStatsDisplayStrings.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the MIT Licence. | ||
// See the LICENCE file in the repository root for full licence text. | ||
|
||
using osu.Framework.Localisation; | ||
|
||
namespace osu.Game.Localisation | ||
{ | ||
public static class DailyChallengeStatsDisplayStrings | ||
{ | ||
private const string prefix = @"osu.Game.Resources.Localisation.DailyChallengeStatsDisplay"; | ||
|
||
/// <summary> | ||
/// "{0}d" | ||
/// </summary> | ||
public static LocalisableString UnitDay(LocalisableString count) => new TranslatableString(getKey(@"unit_day"), @"{0}d", count); | ||
|
||
/// <summary> | ||
/// "{0}w" | ||
/// </summary> | ||
public static LocalisableString UnitWeek(LocalisableString count) => new TranslatableString(getKey(@"unit_week"), @"{0}w", count); | ||
|
||
private static string getKey(string key) => $@"{prefix}:{key}"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters