How to solve the problem of different order of Badges in different languages

AI-generated summary

The discussion addresses an issue where the order of user badges changes inconsistently across different languages due to sorting by localized text strings rather than fixed internal IDs. Noble_Fish highlighted this behavior, noting that it disrupts the logical grouping of badges by type and level, and provided screenshots from both the Discourse Meta site and a self-hosted server to illustrate the problem. The user argued that, similar to practices in multilingual games, badge ordering should remain stable regardless of translation. Lilly initially misunderstood the request, suggesting a paid theme component to allow admins to manually re-order or re-group badges. After clarification from Noble_Fish that the goal was to prevent language-based reordering rather than enable customization, the conversation shifted toward a native solution. Ultimately, chapoi confirmed that the issue was categorized under UX and resolved via a pull request (#37895), ensuring that badge order now remains consistent across all languages.

Previously on

I came across a post asking about custom sorting, but it seems there has been no follow-up. I’m not particularly interested in customization myself, because the default scenarios are actually well-implemented. However, there’s something a bit odd: these are 3 types and their respective 3 levels of Badges, but… why isn’t each column a category?

The initial reason for considering this issue might just be my OCD, but from the perspective of the feature’s operational logic, if it were arranged first by level and then by type, the final result should also be a scenario where each column is a category and each row is a level. However, the meta clearly doesn’t show this…

I have the same issue on my self-hosted server as well.


Well, I just didn’t react in time. At the final step, it still sorts based on the name string of the badges…

It’s strange why it doesn’t arrange them according to a fixed ID or internal name, as this causes the Badges to appear in different orders due to translation reasons… :melting_face:

Can this problem be solved?

i think i can build a theme component that will allow an admin to re-order the badges (and maybe even re-group?). but it will probably be a bit tricky, and i cannot do it for free. :woman_shrugging:t2:

I think the thread you originally intended to reply to might be the one I quoted about wanting to customize badges?

oh i thought you wanted to re-order them on the badge page? sorry i misunderstood what you are trying to do. don’t you mean they change order based on the language and you are trying to override that behavior?

I think it’s a problem that badges use different orders due to different localized texts in different languages. On some sites and games I know, when dealing with multilingual issues, they generally keep their order unchanged. Even some older games, such as modern engine extension projects for “Command & Conquer”, are adding similar features to ensure that translated texts do not affect the order of icons and other elements.
As for custom order, um… it sounds good, but I have no need for it.

I classified this to Contribute > UX and fixed it here UX: fix order of badges to be less language-dependent - Pull Request #37895 - discourse/discourse - GitHub

Now the order of badges should no longer change between different languages.

3 Likes

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.