1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-18 03:33:39 +08:00

Hide daily challenge display when not selecting osu!

Also hide when no user is displayed.
This commit is contained in:
Salman Ahmed
2024-07-30 07:05:31 +03:00
Unverified
parent 8b910e59f6
commit 33fc6dfaff
@@ -93,9 +93,9 @@ namespace osu.Game.Overlays.Profile.Header.Components
private void updateDisplay()
{
if (User.Value == null)
if (User.Value == null || User.Value.Ruleset.OnlineID != 0)
{
dailyStreak.Text = "-";
Hide();
return;
}
@@ -103,6 +103,7 @@ namespace osu.Game.Overlays.Profile.Header.Components
// dailyStreak.Text = UsersStrings.ShowDailyChallengeUnitDay(statistics.DailyStreakCurrent);
dailyStreak.Text = $"{statistics.DailyStreakCurrent}d";
TooltipContent = new DailyChallengeStreakTooltipData(colourProvider, statistics);
Show();
}
public ITooltip<DailyChallengeStreakTooltipData> GetCustomTooltip() => new DailyChallengeStreakTooltip();