Make community IDs more easily selectable (#1306)

* Make community IDs more easily selectable

* Use T component for alert

* Use T component for alert

---------

Co-authored-by: SleeplessOne1917 <abias1122@gmail.com>
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
This commit is contained in:
Sunny 2023-06-16 15:00:01 +00:00 committed by GitHub
parent b228214cd0
commit 1c26a85fff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 4 deletions

View File

@ -1,4 +1,5 @@
import { Component, InfernoNode, linkEvent } from "inferno";
import { T } from "inferno-i18next-dess";
import { Link } from "inferno-router";
import {
AddModToCommunity,
@ -144,10 +145,15 @@ export class Sidebar extends Component<SidebarProps, SidebarState> {
{myUSerInfo && this.blockCommunity()}
{!myUSerInfo && (
<div className="alert alert-info" role="alert">
{i18n.t("community_not_logged_in_alert", {
community: name,
instance: hostname(actor_id),
})}
<T
i18nKey="community_not_logged_in_alert"
interpolation={{
community: name,
instance: hostname(actor_id),
}}
>
#<code className="user-select-all">#</code>#
</T>
</div>
)}
</div>