Hiding trust level

Hello!

I couldn’t find how can I hidding the trust level 0 for the new members.

I want that new members don’t know that they are basic, just know the when they are in the next level.

Or, if not’s possible, hide notification.

1 curtida

I could be wrong, but I do not think that trust level 0 is displayed anywhere that users can see. When a user is granted trust level 1, Discourse sends a notification telling the user that they have been promoted to trust level 1. You can disable this notification by deselecting the send tl1 welcome message site setting.

You can also customize the message by going to your Admin / Customize / Text section and searching for welcome_tl1_user . This search will return three text templates. You would need to customize the system_messages.welcome_tl1_user.title to change the “Welcome TL1 User” text. You might also want to change the system_messages.welcome_tl1_user.text_body_template text.

When users achieve trust level 1, they are also granted the “Basic” badge. You can disable this badge on your Admin / Badges page. To disable the badge, scroll to the bottom of the Admin Basic badge form and deselect the “Enable badge” checkbox.

If you would like to keep the Basic badge enabled, but remove “Trust Level 1” from the badge description, you can customize the badge description by going to Admin / Customize / Text and searching for basic_user. This search will return three text strings. The one you will want to change is badges.basic_user.long_description.

When you visit a user’s profile page and see something like this, the user has trust level 1 (basic), not trust level 0:

The easiest way to remove this would be to hide this trust level field for all trust levels with CSS. Adding the following CSS to your theme should work:

.user-main .about .secondary dd.trust-level,
.user-main .about .secondary dt.trust-level {
    display: none;
}

This would hide the trust level field on the profile page for all trust levels. If you would like to display higher trust levels, but not display trust level 1 (basic), this could be accomplished with a theme component. Let us know if you only want to hide the trust level of basic users and we will try to help with that.

8 curtidas

Obrigado, isso chega perto do que eu preciso. (Eu definitivamente gosto de ter níveis de confiança, eu apenas não quero que os usuários saibam o que são, para evitar rivalidade e competição.) A única coisa é que seria útil para mim, como administrador, ver os níveis de confiança nos perfis de usuário. Isso poderia ser incluído como uma opção de configuração para mostrar ou ocultar para diferentes grupos de usuários?

Pelo que sei, o CSS acima ainda funciona, você só precisa envolvê-lo no que está abaixo para que ele não se aplique aos membros da equipe:

body:not(.staff) {
    .user-main .about .secondary dd.trust-level, .user-main .about .secondary dt.trust-level {
    display: none;
    }
}
1 curtida

Sim, posso confirmar que o CSS funciona, tanto o anterior quanto o seu ajuste para mim. Muito obrigado pela ajuda. Suponho que, se alguém realmente quisesse, ainda poderia inspecionar o HTML e ver esses elementos ocultos, certo? É por isso que eu estava pensando que uma opção de configuração para desativá-lo poderia ser melhor, mas isso realmente não é uma grande preocupação.