# Добавить текст в шапку рядом с логотипом

**URL:** https://meta.discourse.org/t/add-text-in-header-beside-logo/162670
**Category:** Development
**Created:** [01.Сентябрь.2020 15:19:54 UTC](https://meta.discourse.org/t/add-text-in-header-beside-logo/162670 "2020-09-01T15:19:54Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![Johani](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/johani/32/176920_2.png) [@Johani](https://meta.discourse.org/u/Johani)
#### Post date: [01.Сентябрь.2020 16:10:03 UTC](https://meta.discourse.org/t/add-text-in-header-beside-logo/162670/2 "2020-09-01T16:10:03Z")

</div>

Привет, Daniel 👋

Вы можете использовать что-то вроде этого, чтобы добавить текст рядом с логотипом в заголовке вашего сайта:

```markdown
<script type="text/discourse-plugin" version="0.8">
api.decorateWidget("home-logo:after", helper => {
  const titleVisible = helper.attrs.minimized;
  const headerText = "Текст, который вы хотите добавить"; // <--- измените этот текст

  if (!titleVisible) {
    return api.h("span.header-text", headerText);
  }
});
</script>

```

Добавьте этот код в секцию заголовка вашей темы или компонента. Подробнее о системе тем Discourse вы можете прочитать здесь:

> [@Beginner's guide to using Discourse Themes](https://meta.discourse.org/t/beginners-guide-to-using-discourse-themes/91966):
>
> This is a crash course in Discourse theme basics. The target audience is everyone who is not familiar with Discourse themes. If you’ve already used Discourse theme / theme components, this guide is probably not something you need to read. What are themes and theme components? A theme or theme component is a set of files packaged together designed to either modify Discourse visually or to add new features. Let’s start with themes. Themes In general, themes are not supposed to be compatible …

---

_[View the full topic](https://meta.discourse.org/t/add-text-in-header-beside-logo/162670)._
