Skip to content

Extract common components from BeatmapLeaderboardScore#37079

Open
LiquidPL wants to merge 5 commits intoppy:masterfrom
LiquidPL:leaderboard-common-component
Open

Extract common components from BeatmapLeaderboardScore#37079
LiquidPL wants to merge 5 commits intoppy:masterfrom
LiquidPL:leaderboard-common-component

Conversation

@LiquidPL
Copy link
Copy Markdown
Contributor

Specifically user (username, avatar, flag, team), rank (in the overlay
showing above the avatar when in compact mode) and date.

Depends on #37064.

This commit extracts the rank display component, along with its
highlight logic to a separate component, to be reused on the playlists
score component.
Specifically user (username, avatar, flag, team), rank (in the overlay
showing above the avatar when in compact mode) and date.
@peppy peppy self-requested a review March 25, 2026 09:15
Copy link
Copy Markdown
Member

@peppy peppy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

j


namespace osu.Game.Online.Leaderboards
{
public partial class LeaderboardCommonDisplay : Container
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dunno about naming here.

How about LeaderboardScoreUserInfo?

All these components may work better as partial classes inside LeaderboardScore given how they are all just pieces of that component (i think?)

See something like BeatmapTitleWedge and adjacent files as an example.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't it look awkward if I then reuse them on a potential PlaylistsLeaderboardScore and it'll have a bunch of references to BeatmapLeaderboardScore.<something>? I don't think it's that big of a deal but it would be at least a little eyebrow raising.

But then on the other hand I am already pulling in constants from it in some places so I guess it's fine?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants