1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 08:52:55 +08:00

Localise rank graph tooltip.

This commit is contained in:
Lucas A 2021-07-23 23:38:31 +02:00
parent 48c21674ed
commit 011fad167d

View File

@ -7,6 +7,7 @@ using System.Linq;
using Humanizer;
using osu.Framework.Bindables;
using osu.Framework.Graphics;
using osu.Framework.Localisation;
using osu.Game.Graphics;
using osu.Game.Graphics.Sprites;
using osu.Game.Resources.Localisation.Web;
@ -65,7 +66,7 @@ namespace osu.Game.Overlays.Profile.Header.Components
return new TooltipDisplayContent
{
Rank = $"#{rank:N0}",
Rank = rank.ToLocalisableString("\\##,##0"),
Time = days == 0 ? "now" : $"{"day".ToQuantity(days)} ago"
};
}
@ -92,7 +93,7 @@ namespace osu.Game.Overlays.Profile.Header.Components
private class TooltipDisplayContent
{
public string Rank;
public LocalisableString Rank;
public string Time;
}
}