# Невозможно изменить цвет имени пользователя в зависимости от группы, к которой он принадлежит

**URL:** https://meta.discourse.org/t/unable-to-change-usernames-a-specific-color-based-on-the-group-they-are-in/392941
**Category:** Support
**Tags:** groups
**Created:** [08.Январь.2026 03:47:43 UTC](https://meta.discourse.org/t/unable-to-change-usernames-a-specific-color-based-on-the-group-they-are-in/392941 "2026-01-08T03:47:43Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![hipp0](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hipp0/32/537433_2.png) [@hipp0](https://meta.discourse.org/u/hipp0)
#### Post date: [08.Январь.2026 03:47:43 UTC](https://meta.discourse.org/t/unable-to-change-usernames-a-specific-color-based-on-the-group-they-are-in/392941/1 "2026-01-08T03:47:43Z")

</div>

Было бы действительно здорово, если бы это было встроено. Я вижу только цвет фона флейра.

Я установил эти два компонента, но не могу изменить цвет имени пользователя в зависимости от выбранной основной группы.

> **[GitHub - discourse/discourse-groups-css-classes-in-body](https://github.com/discourse/discourse-groups-css-classes-in-body)**
>
> Contribute to discourse/discourse-groups-css-classes-in-body development by creating an account on GitHub.

> **[GitHub - VaperinaDEV/name-color-by-group: This theme component allows to color the names of...](https://github.com/VaperinaDEV/name-color-by-group)**
>
> This theme component allows to color the names of users by group in posts.

---

<div class="post-metadata">

### Author: ![Lilly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilly/32/575047_2.png) [@Lilly](https://meta.discourse.org/u/Lilly)
#### Post date: [08.Январь.2026 04:16:16 UTC](https://meta.discourse.org/t/unable-to-change-usernames-a-specific-color-based-on-the-group-they-are-in/392941/2 "2026-01-08T04:16:16Z")

</div>

> [@hipp0](#):
>
> [GitHub - discourse/discourse-groups-css-classes-in-body · GitHub](https://github.com/discourse/discourse-groups-css-classes-in-body)

После установки этого достаточно сделать следующее:

```scss

body.group-GROUP-NAME .topic-meta-data .full-name a {
  color: COLOR;
}

```

где GROUP-NAME — название вашей группы, а COLOR — желаемый цвет в допустимом формате. Если группа называется `@dragons`, а имена пользователей должны быть фиолетовыми, то:

```scss
body.group-dragons .topic-meta-data .full-name a {
  color: purple;
}

```

---

<div class="post-metadata">

### Author: ![hipp0](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hipp0/32/537433_2.png) [@hipp0](https://meta.discourse.org/u/hipp0)
#### Post date: [08.Январь.2026 04:58:11 UTC](https://meta.discourse.org/t/unable-to-change-usernames-a-specific-color-based-on-the-group-they-are-in/392941/3 "2026-01-08T04:58:11Z")

</div>

Я не вижу, где применяется это изменение. Я пытаюсь изменить цвет для всех пользователей в определённой группе на цвет, установленный для этой группы.

Также я заменил аватары на имена пользователей в темах постов; здесь тоже нужно изменить цвета:

 ![image](https://global.discourse-cdn.com/meta/original/4X/4/c/c/4cce2c6a4e0b6950513e787a1f6bc390f3c2a694.png)
