chore: i18n
This commit is contained in:
@@ -7,6 +7,7 @@ import { cn } from '@/lib/utils'
|
|||||||
import { useSecondaryPage } from '@/PageManager'
|
import { useSecondaryPage } from '@/PageManager'
|
||||||
import { Event } from 'nostr-tools'
|
import { Event } from 'nostr-tools'
|
||||||
import { useMemo } from 'react'
|
import { useMemo } from 'react'
|
||||||
|
import { useTranslation } from 'react-i18next'
|
||||||
import Content from '../Content'
|
import Content from '../Content'
|
||||||
import ContentPreview from '../ContentPreview'
|
import ContentPreview from '../ContentPreview'
|
||||||
import UserAvatar from '../UserAvatar'
|
import UserAvatar from '../UserAvatar'
|
||||||
@@ -27,6 +28,7 @@ export default function Highlight({ event, className }: { event: Event; classNam
|
|||||||
}
|
}
|
||||||
|
|
||||||
function HighlightSource({ event }: { event: Event }) {
|
function HighlightSource({ event }: { event: Event }) {
|
||||||
|
const { t } = useTranslation()
|
||||||
const { push } = useSecondaryPage()
|
const { push } = useSecondaryPage()
|
||||||
const sourceTag = useMemo(() => {
|
const sourceTag = useMemo(() => {
|
||||||
let sourceTag: string[] | undefined
|
let sourceTag: string[] | undefined
|
||||||
@@ -84,7 +86,7 @@ function HighlightSource({ event }: { event: Event }) {
|
|||||||
if (sourceTag[0] === 'r') {
|
if (sourceTag[0] === 'r') {
|
||||||
return (
|
return (
|
||||||
<div className="truncate text-muted-foreground">
|
<div className="truncate text-muted-foreground">
|
||||||
{'From '}
|
{t('From')}{' '}
|
||||||
<a
|
<a
|
||||||
href={sourceTag[1]}
|
href={sourceTag[1]}
|
||||||
target="_blank"
|
target="_blank"
|
||||||
@@ -100,7 +102,7 @@ function HighlightSource({ event }: { event: Event }) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="flex items-center gap-2 text-muted-foreground">
|
<div className="flex items-center gap-2 text-muted-foreground">
|
||||||
<div>{'From'}</div>
|
<div>{t('From')}</div>
|
||||||
{pubkey && <UserAvatar userId={pubkey} size="xSmall" className="cursor-pointer" />}
|
{pubkey && <UserAvatar userId={pubkey} size="xSmall" className="cursor-pointer" />}
|
||||||
{referenceEvent && isSupportedKind(referenceEvent.kind) ? (
|
{referenceEvent && isSupportedKind(referenceEvent.kind) ? (
|
||||||
<ContentPreview
|
<ContentPreview
|
||||||
|
|||||||
@@ -230,6 +230,7 @@ export default {
|
|||||||
Preview: 'معاينة',
|
Preview: 'معاينة',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'أنت على وشك نشر حدث موقع من قبل [{{eventAuthorName}}]. أنت حالياً مسجل الدخول كـ [{{currentUsername}}]. هل أنت متأكد؟',
|
'أنت على وشك نشر حدث موقع من قبل [{{eventAuthorName}}]. أنت حالياً مسجل الدخول كـ [{{currentUsername}}]. هل أنت متأكد؟',
|
||||||
'Platinum Sponsors': 'الرعاة البلاتينيون'
|
'Platinum Sponsors': 'الرعاة البلاتينيون',
|
||||||
|
From: 'من'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -236,6 +236,7 @@ export default {
|
|||||||
Preview: 'Vorschau',
|
Preview: 'Vorschau',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Du bist dabei, ein Ereignis zu veröffentlichen, das von [{{eventAuthorName}}] signiert wurde. Du bist derzeit als [{{currentUsername}}] angemeldet. Bist du sicher?',
|
'Du bist dabei, ein Ereignis zu veröffentlichen, das von [{{eventAuthorName}}] signiert wurde. Du bist derzeit als [{{currentUsername}}] angemeldet. Bist du sicher?',
|
||||||
'Platinum Sponsors': 'Platin-Sponsoren'
|
'Platinum Sponsors': 'Platin-Sponsoren',
|
||||||
|
From: 'Von'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -230,6 +230,7 @@ export default {
|
|||||||
Preview: 'Preview',
|
Preview: 'Preview',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?',
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?',
|
||||||
'Platinum Sponsors': 'Platinum Sponsors'
|
'Platinum Sponsors': 'Platinum Sponsors',
|
||||||
|
From: 'From'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -235,6 +235,7 @@ export default {
|
|||||||
Preview: 'Vista previa',
|
Preview: 'Vista previa',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Estás a punto de publicar un evento firmado por [{{eventAuthorName}}]. Actualmente has iniciado sesión como [{{currentUsername}}]. ¿Estás seguro?',
|
'Estás a punto de publicar un evento firmado por [{{eventAuthorName}}]. Actualmente has iniciado sesión como [{{currentUsername}}]. ¿Estás seguro?',
|
||||||
'Platinum Sponsors': 'Patrocinadores Platino'
|
'Platinum Sponsors': 'Patrocinadores Platino',
|
||||||
|
From: 'De'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -235,6 +235,7 @@ export default {
|
|||||||
Preview: 'Aperçu',
|
Preview: 'Aperçu',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Vous êtes sur le point de publier un événement signé par [{{eventAuthorName}}]. Vous êtes actuellement connecté en tant que [{{currentUsername}}]. Êtes-vous sûr ?',
|
'Vous êtes sur le point de publier un événement signé par [{{eventAuthorName}}]. Vous êtes actuellement connecté en tant que [{{currentUsername}}]. Êtes-vous sûr ?',
|
||||||
'Platinum Sponsors': 'Sponsors Platine'
|
'Platinum Sponsors': 'Sponsors Platine',
|
||||||
|
From: 'De'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -234,6 +234,7 @@ export default {
|
|||||||
Preview: 'Anteprima',
|
Preview: 'Anteprima',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Stai per pubblicare un evento firmato da [{{eventAuthorName}}]. Attualmente sei connesso come [{{currentUsername}}]. Sei sicuro?',
|
'Stai per pubblicare un evento firmato da [{{eventAuthorName}}]. Attualmente sei connesso come [{{currentUsername}}]. Sei sicuro?',
|
||||||
'Platinum Sponsors': 'Sponsor Platino'
|
'Platinum Sponsors': 'Sponsor Platino',
|
||||||
|
From: 'Da'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -231,6 +231,7 @@ export default {
|
|||||||
Preview: 'プレビュー',
|
Preview: 'プレビュー',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'あなたは[{{eventAuthorName}}]によって署名されたイベントを公開しようとしています。現在[{{currentUsername}}]としてログインしています。よろしいですか?',
|
'あなたは[{{eventAuthorName}}]によって署名されたイベントを公開しようとしています。現在[{{currentUsername}}]としてログインしています。よろしいですか?',
|
||||||
'Platinum Sponsors': 'プラチナスポンサー'
|
'Platinum Sponsors': 'プラチナスポンサー',
|
||||||
|
From: 'から'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -233,6 +233,7 @@ export default {
|
|||||||
Preview: 'Podgląd',
|
Preview: 'Podgląd',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Zaraz opublikujesz zdarzenie podpisane przez [{{eventAuthorName}}]. Obecnie jesteś zalogowany jako [{{currentUsername}}]. Czy jesteś pewien?',
|
'Zaraz opublikujesz zdarzenie podpisane przez [{{eventAuthorName}}]. Obecnie jesteś zalogowany jako [{{currentUsername}}]. Czy jesteś pewien?',
|
||||||
'Platinum Sponsors': 'Sponsorzy Platynowi'
|
'Platinum Sponsors': 'Sponsorzy Platynowi',
|
||||||
|
From: 'Od'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -233,6 +233,7 @@ export default {
|
|||||||
Preview: 'Pré-visualização',
|
Preview: 'Pré-visualização',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Você está prestes a publicar um evento assinado por [{{eventAuthorName}}]. Você está atualmente logado como [{{currentUsername}}]. Tem certeza?',
|
'Você está prestes a publicar um evento assinado por [{{eventAuthorName}}]. Você está atualmente logado como [{{currentUsername}}]. Tem certeza?',
|
||||||
'Platinum Sponsors': 'Patrocinadores Platinum'
|
'Platinum Sponsors': 'Patrocinadores Platinum',
|
||||||
|
From: 'De'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -234,6 +234,7 @@ export default {
|
|||||||
Preview: 'Pré-visualização',
|
Preview: 'Pré-visualização',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Você está prestes a publicar um evento assinado por [{{eventAuthorName}}]. Você está atualmente logado como [{{currentUsername}}]. Tem certeza?',
|
'Você está prestes a publicar um evento assinado por [{{eventAuthorName}}]. Você está atualmente logado como [{{currentUsername}}]. Tem certeza?',
|
||||||
'Platinum Sponsors': 'Patrocinadores Platinum'
|
'Platinum Sponsors': 'Patrocinadores Platinum',
|
||||||
|
From: 'De'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -234,6 +234,7 @@ export default {
|
|||||||
Preview: 'Предварительный просмотр',
|
Preview: 'Предварительный просмотр',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'Вы собираетесь опубликовать событие, подписанное [{{eventAuthorName}}]. Вы в данный момент вошли как [{{currentUsername}}]. Вы уверены?',
|
'Вы собираетесь опубликовать событие, подписанное [{{eventAuthorName}}]. Вы в данный момент вошли как [{{currentUsername}}]. Вы уверены?',
|
||||||
'Platinum Sponsors': 'Платиновые спонсоры'
|
'Platinum Sponsors': 'Платиновые спонсоры',
|
||||||
|
From: 'От'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -231,6 +231,7 @@ export default {
|
|||||||
Preview: '预览',
|
Preview: '预览',
|
||||||
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
'You are about to publish an event signed by [{{eventAuthorName}}]. You are currently logged in as [{{currentUsername}}]. Are you sure?':
|
||||||
'您即将发布一条由 [{{eventAuthorName}}] 签名的事件。您当前以 [{{currentUsername}}] 登录。确定吗?',
|
'您即将发布一条由 [{{eventAuthorName}}] 签名的事件。您当前以 [{{currentUsername}}] 登录。确定吗?',
|
||||||
'Platinum Sponsors': '白金赞助商'
|
'Platinum Sponsors': '白金赞助商',
|
||||||
|
From: '来自'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user